@extends('layouts/client') @section('title', __('client.profile.index')) @section('scripts') @endsection @section('content')
@include('shared/alerts')

{{ __('client.profile.index') }}

{{ __('client.profile.index_description') }}

@csrf
@include("shared.input", ["name" => "firstname", "label" => __('global.firstname'), "value" => auth('web')->user()->firstname ?? old("firstname")])
@include("shared.input", ["name" => "lastname", "label" => __('global.lastname'), "value" => auth('web')->user()->lastname ?? old("lastname")])
@include("shared/input", ["name" => "company_name", "label" => __('global.company_name') . ' (' . __('global.optional') . ')', "value" => auth('web')->user()->company_name ?? old("company_name")])
@include("shared.input", ["name" => "address", "label" => __('global.address'), "value" => auth('web')->user()->address ?? old("address")])
@include("shared.input", ["name" => "address2", "label" => __('global.address2'), "value" => auth('web')->user()->address2 ?? old("address2")])
@include("shared.input", ["name" => "zipcode", "label" => __('global.zip'), "value" => auth('web')->user()->zipcode ?? old("zipcode")])
@include("shared.input", ["name" => "email", "label" => __('global.email'), "type" => "email", "value" => auth('web')->user()->email ?? old("email"), "disabled"=> true])
@include("shared.input", ["name" => "phone", "label" => __('global.phone'), "value" => auth('web')->user()->phone ?? old("phone")])
@include("shared.select", ["name" => "country", "label" => __('global.country'), "options" => $countries,"value" => auth('web')->user()->country ?? old("country")])
@include("shared.input", ["name" => "city", "label" => __('global.city'), "value" => auth('web')->user()->city ?? old("city")])
@include("shared.input", ["name" => "region", "label" => __('global.region'), "value" => auth('web')->user()->region ?? old("region")])
@include("shared/select", ["name" => "locale", "label" => __('global.locale'), "options" => $locales, "value" => auth('web')->user()->locale ?? old("locale")] )
@include("shared/textarea", ["name" => "billing_details", "label" => __('global.billing_details'), "value" => auth('web')->user()->billing_details ?? old("billing_details"), "help" => __('global.billing_details_help')])

{{ __('client.profile.security.index') }}

{{ __('client.profile.security.index_description') }}

@csrf
@include("shared/password", ["name" => "currentpassword", "label" => __('client.profile.security.currentpassword')])
@include("shared/password", ["name" => "password", "label" => __('client.profile.security.newpassword')])
@include("shared/password", ["name" => "password_confirmation", "label" => __('global.password_confirmation')])
@if (auth('web')->user()->twoFactorEnabled())
@include("shared/input", ["name" => "2fa", "label" => __('client.profile.2fa.code')])
@endif

{{ __('client.profile.2fa.title') }}

@if (!auth('web')->user()->twoFactorEnabled())

{{ __('client.profile.2fa.info') }}

@else

{!! __('client.profile.2fa.download_codes', ['url' => route('front.profile.2fa_codes')]) !!}

@endif
@csrf @if (!auth('web')->user()->twoFactorEnabled()) {!! $qrcode !!} @include("shared/input", ["name" => "2fa", "label" => __('client.profile.2fa.code'), "help" => $code]) @else @include("shared/input", ["name" => "2fa", "label" => __('client.profile.2fa.code')]) @endif
@foreach ($providers ?? [] as $provider) @if ($provider->isSynced()) {{ $provider->provider()->title() }} {{ __('socialauth::messages.unlink', ['provider' => $provider->provider()->title()]) }} @else {{ $provider->provider()->title() }} {{ __('socialauth::messages.sync_with', ['provider' => $provider->provider()->title()]) }} @endif @endforeach
@endsection