Fichier app/User.php :

/**
 * The attributes that are mass assignable.
 *
 * @var array
 */
protected $fillable = [
    'name', 'email', 'password', 'last_name'
];

/**
 * Run the migrations.
 *
 * @return void
 */
public function up()
{
    Schema::table('users', function (Blueprint $table) {
        $table->string('last_name');
    });
}
/**
 * Reverse the migrations.
 *
 * @return void
 */
public function down()
{
    Schema::table('users', function (Blueprint $table) {
        $table->dropColumn('last_name');
    });
}

Fichier /app/Http/Controllers/Auth/RegisterController.php

/**
 * Get a validator for an incoming registration request.
 *
 * @param  array  $data
 * @return \Illuminate\Contracts\Validation\Validator
 */
protected function validator(array $data)
{
    return Validator::make($data, [
        'name' => ['required', 'string', 'max:255'],
        'last_name' => ['required', 'string', 'max:255'],
        'email' => ['required', 'string', 'email', 'max:255', 'unique:users'],
        'password' => ['required', 'string', 'min:8', 'confirmed'],
    ]);
}
/**
 * Create a new user instance after a valid registration.
 *
 * @param  array  $data
 * @return \App\User
 */
protected function create(array $data)
{
    return User::create([
        'name' => $data['name'],
        'last_name' => $data['last_name'],
        'email' => $data['email'],
        'password' => Hash::make($data['password']),
    ]);
}

<div class="form-group row">
    <label for="name" class="col-md-4 col-form-label text-md-right">{{ __('Last name') }}</label>
    <div class="col-md-6">
        <input id="last_name" type="text" class="form-control @error('last_name') is-invalid @enderror" name="last_name" value="{{ old('last_name') }}" required autocomplete="last_name" autofocus>
        @error('last_name')
            <span class="invalid-feedback" role="alert">
                <strong>{{ $message }}</strong>
            </span>
        @enderror
    </div>
</div>

class AddUuidToUsersTable extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::table('users', function (Blueprint $table) {
            $table->uuid('uuid');
        });
    }
    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
        Schema::table('users', function (Blueprint $table) {
            $table->dropColumn('uuid');
        });
    }
}

 
<?php

namespace App;

use Illuminate\Notifications\Notifiable;
use Illuminate\Contracts\Auth\MustVerifyEmail;
use Illuminate\Foundation\Auth\User as Authenticatable;
use Emadadly\LaravelUuid\Uuids;

class User extends Authenticatable
{
    use Notifiable;
    use Uuids;
    /**
     * The attributes that are mass assignable.
     *
     * @var array
     */
    protected $fillable = [
        'name', 'email', 'password', 'last_name',
    ];
    /**
     * The attributes that should be hidden for arrays.
     *
     * @var array
     */
    protected $hidden = [
        'password', 'remember_token', 'uuid',
    ];
    /**
     * The attributes that should be cast to native types.
     *
     * @var array
     */
    protected $casts = [
        'email_verified_at' => 'datetime',
    ];
}

@extends('layouts.app')
@section('content')
<div class="container">
    <div class="row justify-content-center">
        <div class="col-md-8">
            <div class="card">
                <div class="card-header">Dashboard</div>
                <div class="card-body">
                    @if (session('status'))
                        <div class="alert alert-success" role="alert">
                            {{ session('status') }}
                        </div>
                    @endif
                    You are logged in as: {{ Auth::user()->name }}
                </div>
                <h2>Users list</h2>
                <ul>
                    @foreach ($users as $user)
                        <li> <a href="{{route('users_show', ['uuid' => $user->uuid])}}">[{{$user->uuid}}] {{$user->name}}</a> </li>
                    @endforeach
                </ul>
            </div>
        </div>
    </div>
</div>
@endsection
laravel/resources/views/users_show.blade.php
@extends('layouts.app')
@section('content')
<div class="container">
    <div class="row justify-content-center">
        <div class="col-md-8">
            <div class="card">
                <div class="card-header">Dashboard</div>
                <div class="card-body">
                    @if (session('status'))
                        <div class="alert alert-success" role="alert">
                            {{ session('status') }}
                        </div>
                    @endif
                    You are logged in as: {{ Auth::user()->name }}
                </div>
                <h2>Users show</h2>
                {{ $user_details->name }} - {{ $user_details->last_name }} - {{ $user_details->email }}
            </div>
        </div>
    </div>
</div>
@endsection

/**
 * Display a listing of the resource.
 *
 * @return \Illuminate\Http\Response
 */
public function index()
{
    $users = User::all();

    return view('users_index', ['users' => $users]);
}

/**  * Display the specified resource.  * @param string $uuid  *  * @return \Illuminate\Http\Response  */
public function show($uuid)
{
      // $user = User::where('uuid', $uuid)→first();
	// les deux fonctionnent, ci dessous on utilise la méthode mise à 	
	// disposition par le package UUID
	$user = User::uuid($uuid);
    return view('users_show', ['user_details' => $user]);
}

<?php

namespace App\Http\Controllers;

class EuropePmcController extends Controller
{
   public function showMethodsAvailable()
    {
        $client = new \SoapClient('https://www.ebi.ac.uk/europepmc/webservices/soap?wsdl', ['trace' => 1]);
        $methods = $client->__getFunctions();
        return view('europepmc_methods', ['methods' => $methods]);
    }

    public function searchPublications()
    {
        $client = new \SoapClient('https://www.ebi.ac.uk/europepmc/webservices/soap?wsdl', ['trace' => 1]);
        $response = $client->searchPublications([
            'queryString' => 'acouphène',
            'cursorMark' => '*'
        ]);
        return view('europepmc_search_publication', ['response' => $response]);
    }
}

<!DOCTYPE html>
<html lang="{{ str_replace('_', '-', app()->getLocale()) }}">
    <head>
        <meta charset="utf-8">
        <title>Available methods for Europe PMC API</title>
    </head>
    <body>
        <h1>Avalaible methods for Europe PMC API</h1>
        <div class="row">
            <ul>
                @foreach ($methods as $method)
                    <li>{{ $method }}</li>
                @endforeach
            </ul>
        </div>
    </body>
</html>

<!DOCTYPE html>
<html lang="{{ str_replace('_', '-', app()->getLocale()) }}">
    <head>
        <meta charset="utf-8">
        <title>Europe PMC API Search</title>
    </head>
    <body>
        <h1>"Accouphènes" on Europe PMC API</h1>
        <div class="row">
            <ul>
                @foreach ($response->return->resultList->result as $result)
                    <li>[{{ $result-> id }}] - {{ $result->title }} - {{ $result->authorString }}</li>
                @endforeach
            </ul>
        </div>
    </body>
</html>