mirror of
https://gitlab.linphone.org/BC/public/flexisip-account-manager.git
synced 2026-01-17 10:08:05 +00:00
Fix FLEXIAPI-133 Use the correct breadcrumb on create and fix a password...
This commit is contained in:
parent
965d808932
commit
d6a6b6bce0
3 changed files with 11 additions and 4 deletions
|
|
@ -441,7 +441,7 @@ class Account extends Authenticatable
|
|||
return !empty($this->recovery_code) && $this->updated_at->greaterThan($oneHourAgo);
|
||||
}
|
||||
|
||||
public function updatePassword($newPassword, ?string $algorithm = null)
|
||||
public function updatePassword(string $newPassword, ?string $algorithm = null)
|
||||
{
|
||||
$algorithm = $algorithm ?? config('app.account_default_password_algorithm');
|
||||
|
||||
|
|
|
|||
|
|
@ -136,7 +136,10 @@ class AccountController extends Controller
|
|||
|
||||
$account->phone = $request->get('phone');
|
||||
|
||||
if ($request->get('password')) {
|
||||
$account->updatePassword($request->get('password'));
|
||||
}
|
||||
|
||||
$account->setRole($request->get('role'));
|
||||
|
||||
Log::channel('events')->info('Web Admin: Account updated', ['id' => $account->identifier]);
|
||||
|
|
|
|||
|
|
@ -2,8 +2,12 @@
|
|||
|
||||
@section('breadcrumb')
|
||||
@include('admin.account.parts.breadcrumb_accounts_index')
|
||||
@if ($account->id)
|
||||
@include('admin.account.parts.breadcrumb_accounts_edit', ['account' => $account])
|
||||
<li class="breadcrumb-item active" aria-current="page">Edit</li>
|
||||
@else
|
||||
<li class="breadcrumb-item active" aria-current="page">Create</li>
|
||||
@endif
|
||||
@endsection
|
||||
|
||||
@section('content')
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue