2020-03-23 18:10:42 +01:00
|
|
|
@extends('portal.ninja2020.layout.app')
|
|
|
|
|
|
|
|
@section('meta_title', ctrans('texts.client_information'))
|
|
|
|
|
|
|
|
@section('header')
|
2020-03-26 22:43:57 +01:00
|
|
|
<p class="leading-5 text-gray-500">{{ ctrans('texts.update_your_personal_info') }}</p>
|
2020-03-23 18:10:42 +01:00
|
|
|
@endsection
|
|
|
|
|
|
|
|
@section('body')
|
|
|
|
|
|
|
|
<!-- Basic information: first & last name, e-mail address etc. -->
|
|
|
|
<div class="mt-2 sm:mt-6">
|
|
|
|
<div class="md:grid md:grid-cols-3 md:gap-6">
|
|
|
|
<div class="md:col-span-1">
|
|
|
|
<div class="sm:px-0">
|
2020-03-26 22:43:57 +01:00
|
|
|
<h3 class="text-lg font-medium leading-6 text-gray-900">{{ ctrans('texts.profile') }}</h3>
|
2020-03-23 18:10:42 +01:00
|
|
|
<p class="mt-1 text-sm leading-5 text-gray-500">
|
|
|
|
@lang('texts.client_information_text')
|
|
|
|
</p>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div class="mt-5 md:mt-0 md:col-span-2">
|
|
|
|
<form action="{{ route('client.profile.update', auth()->user()->hashed_id) }}" method="POST"
|
|
|
|
id="update_contact">
|
|
|
|
@csrf
|
|
|
|
@method('PUT')
|
|
|
|
<div class="shadow overflow-hidden rounded">
|
|
|
|
<div class="px-4 py-5 bg-white sm:p-6">
|
|
|
|
<div class="grid grid-cols-6 gap-6">
|
|
|
|
<div class="col-span-6 sm:col-span-3">
|
|
|
|
<label for="first_name" class="input-label">@lang('texts.first_name')</label>
|
2020-04-25 01:17:37 +02:00
|
|
|
<input id="first_name" class="input w-full" name="first_name"
|
2020-03-23 18:10:42 +01:00
|
|
|
value="{{ auth()->user()->first_name }}"/>
|
|
|
|
@error('first_name')
|
|
|
|
<div class="validation validation-fail">
|
|
|
|
{{ $message }}
|
|
|
|
</div>
|
|
|
|
@enderror
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="col-span-6 sm:col-span-3">
|
|
|
|
<label for="last_name" class="input-label">@lang('texts.last_name')</label>
|
2020-04-25 01:17:37 +02:00
|
|
|
<input id="last_name" class="input w-full" name="last_name"
|
2020-03-23 18:10:42 +01:00
|
|
|
value="{{ auth()->user()->last_name }}"/>
|
|
|
|
@error('last_name')
|
|
|
|
<div class="validation validation-fail">
|
|
|
|
{{ $message }}
|
|
|
|
</div>
|
|
|
|
@enderror
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="col-span-6 sm:col-span-4">
|
|
|
|
<label for="email_address" class="input-label">@lang('texts.email_address')</label>
|
2020-04-25 01:17:37 +02:00
|
|
|
<input id="email_address" class="input w-full" type="email" name="email"
|
2020-03-23 18:10:42 +01:00
|
|
|
value="{{ auth()->user()->email }}"/>
|
|
|
|
@error('email')
|
|
|
|
<div class="validation validation-fail">
|
|
|
|
{{ $message }}
|
|
|
|
</div>
|
|
|
|
@enderror
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="col-span-6 sm:col-span-4">
|
|
|
|
<label for="phone" class="input-label">@lang('texts.phone')</label>
|
2020-04-25 01:17:37 +02:00
|
|
|
<input id="phone" class="input w-full" name="phone" value="{{ auth()->user()->phone }}"/>
|
2020-03-23 18:10:42 +01:00
|
|
|
@error('phone')
|
|
|
|
<div class="validation validation-fail">
|
|
|
|
{{ $message }}
|
|
|
|
</div>
|
|
|
|
@enderror
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="col-span-6 sm:col-span-6 lg:col-span-3">
|
|
|
|
<label for="password" class="input-label">@lang('texts.password')</label>
|
2020-04-25 01:17:37 +02:00
|
|
|
<input id="password" class="input w-full" name="password" type="password"/>
|
2020-03-23 18:10:42 +01:00
|
|
|
@error('password')
|
|
|
|
<div class="validation validation-fail">
|
|
|
|
{{ $message }}
|
|
|
|
</div>
|
|
|
|
@enderror
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="col-span-6 sm:col-span-3 lg:col-span-3">
|
|
|
|
<label for="state" class="input-label">@lang('texts.confirm_password')</label>
|
2020-04-25 01:17:37 +02:00
|
|
|
<input id="state" class="input w-full" name="password_confirmation" type="password"/>
|
2020-03-23 18:10:42 +01:00
|
|
|
@error('password_confirmation')
|
|
|
|
<div class="validation validation-fail">
|
|
|
|
{{ $message }}
|
|
|
|
</div>
|
|
|
|
@enderror
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div class="px-4 py-3 bg-gray-50 text-right sm:px-6">
|
|
|
|
<button class="button button-primary">
|
|
|
|
@lang('texts.save')
|
|
|
|
</button>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</form>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<!-- Name, website & logo -->
|
|
|
|
<div class="mt-10 sm:mt-6">
|
|
|
|
<div class="md:grid md:grid-cols-3 md:gap-6">
|
|
|
|
<div class="md:col-span-1">
|
|
|
|
<div class="sm:px-0">
|
|
|
|
<h3 class="text-lg font-medium leading-6 text-gray-900">{{ ctrans('texts.name_website_logo') }}</h3>
|
2020-03-26 22:43:57 +01:00
|
|
|
<p class="mt-1 text-sm leading-5 text-gray-500">
|
|
|
|
{{ ctrans('texts.make_sure_use_full_link') }}
|
2020-03-23 18:10:42 +01:00
|
|
|
</p>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div class="mt-5 md:mt-0 md:col-span-2">
|
|
|
|
<form action="{{ route('client.profile.edit_client', auth()->user()->hashed_id) }}" method="POST"
|
|
|
|
id="update_contact">
|
|
|
|
@csrf
|
|
|
|
@method('PUT')
|
|
|
|
<div class="shadow overflow-hidden rounded">
|
|
|
|
<div class="px-4 py-5 bg-white sm:p-6">
|
|
|
|
<div class="grid grid-cols-6 gap-6">
|
|
|
|
<div class="col-span-6 sm:col-span-3">
|
|
|
|
<label for="street" class="input-label">@lang('texts.name')</label>
|
2020-04-25 01:17:37 +02:00
|
|
|
<input id="name" class="input w-full" name="name"
|
2020-05-27 06:46:19 +02:00
|
|
|
value="{{ auth()->user()->client->present()->name }}"/>
|
2020-03-23 18:10:42 +01:00
|
|
|
@error('name')
|
|
|
|
<div class="validation validation-fail">
|
|
|
|
{{ $message }}
|
|
|
|
</div>
|
|
|
|
@enderror
|
|
|
|
</div>
|
|
|
|
<div class="col-span-6 sm:col-span-3">
|
|
|
|
<label for="website" class="input-label">@lang('texts.website')</label>
|
2020-08-17 18:38:20 +02:00
|
|
|
<input id="website" class="input w-full" name="last_name"
|
2020-03-23 18:10:42 +01:00
|
|
|
value="{{ auth()->user()->client->website }}"/>
|
|
|
|
@error('website')
|
|
|
|
<div class="validation validation-fail">
|
|
|
|
{{ $message }}
|
|
|
|
</div>
|
|
|
|
@enderror
|
|
|
|
</div>
|
|
|
|
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div class="px-4 py-3 bg-gray-50 text-right sm:px-6">
|
|
|
|
<button class="button button-primary">
|
|
|
|
@lang('texts.save')
|
|
|
|
</button>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</form>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<!-- Client personal address -->
|
|
|
|
<div class="mt-10 sm:mt-6">
|
|
|
|
<div class="md:grid md:grid-cols-3 md:gap-6">
|
|
|
|
<div class="md:col-span-1">
|
|
|
|
<div class="sm:px-0">
|
|
|
|
<h3 class="text-lg font-medium leading-6 text-gray-900">{{ ctrans('texts.personal_address') }}</h3>
|
2020-03-26 22:43:57 +01:00
|
|
|
<p class="mt-1 text-sm leading-5 text-gray-500">
|
|
|
|
{{ ctrans('texts.enter_your_personal_address') }}
|
2020-03-23 18:10:42 +01:00
|
|
|
</p>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div class="mt-5 md:mt-0 md:col-span-2">
|
|
|
|
<form action="{{ route('client.profile.edit_client', auth()->user()->hashed_id) }}" method="POST"
|
|
|
|
id="update_contact">
|
|
|
|
@csrf
|
|
|
|
@method('PUT')
|
|
|
|
<div class="shadow overflow-hidden rounded">
|
|
|
|
<div class="px-4 py-5 bg-white sm:p-6">
|
|
|
|
<div class="grid grid-cols-6 gap-6">
|
|
|
|
<div class="col-span-6 sm:col-span-4">
|
|
|
|
<label for="address1" class="input-label">@lang('texts.address1')</label>
|
2020-04-25 01:17:37 +02:00
|
|
|
<input id="address1" class="input w-full" name="address1"
|
2020-03-23 18:10:42 +01:00
|
|
|
value="{{ auth()->user()->client->address1 }}"/>
|
|
|
|
@error('address1')
|
|
|
|
<div class="validation validation-fail">
|
|
|
|
{{ $message }}
|
|
|
|
</div>
|
|
|
|
@enderror
|
|
|
|
</div>
|
|
|
|
<div class="col-span-6 sm:col-span-3">
|
|
|
|
<label for="address2" class="input-label">@lang('texts.address2')</label>
|
2020-04-25 01:17:37 +02:00
|
|
|
<input id="address2" class="input w-full" name="address2"
|
2020-03-23 18:10:42 +01:00
|
|
|
value="{{ auth()->user()->client->address2 }}"/>
|
|
|
|
@error('address2')
|
|
|
|
<div class="validation validation-fail">
|
|
|
|
{{ $message }}
|
|
|
|
</div>
|
|
|
|
@enderror
|
|
|
|
</div>
|
|
|
|
<div class="col-span-6 sm:col-span-3">
|
|
|
|
<label for="city" class="input-label">@lang('texts.city')</label>
|
2020-04-25 01:17:37 +02:00
|
|
|
<input id="city" class="input w-full" name="city"
|
2020-03-23 18:10:42 +01:00
|
|
|
value="{{ auth()->user()->client->city }}"/>
|
|
|
|
@error('city')
|
|
|
|
<div class="validation validation-fail">
|
|
|
|
{{ $message }}
|
|
|
|
</div>
|
|
|
|
@enderror
|
|
|
|
</div>
|
|
|
|
<div class="col-span-6 sm:col-span-2">
|
|
|
|
<label for="state" class="input-label">@lang('texts.state')</label>
|
2020-04-25 01:17:37 +02:00
|
|
|
<input id="state" class="input w-full" name="state"
|
2020-03-23 18:10:42 +01:00
|
|
|
value="{{ auth()->user()->client->state }}"/>
|
|
|
|
@error('state')
|
|
|
|
<div class="validation validation-fail">
|
|
|
|
{{ $message }}
|
|
|
|
</div>
|
|
|
|
@enderror
|
|
|
|
</div>
|
|
|
|
<div class="col-span-6 sm:col-span-2">
|
|
|
|
<label for="postal_code" class="input-label">@lang('texts.postal_code')</label>
|
2020-04-25 01:17:37 +02:00
|
|
|
<input id="postal_code" class="input w-full" name="postal_code"
|
2020-03-23 18:10:42 +01:00
|
|
|
value="{{ auth()->user()->client->postal_code }}"/>
|
|
|
|
@error('postal_code')
|
|
|
|
<div class="validation validation-fail">
|
|
|
|
{{ $message }}
|
|
|
|
</div>
|
|
|
|
@enderror
|
|
|
|
</div>
|
|
|
|
<div class="col-span-6 sm:col-span-2">
|
|
|
|
<label for="country" class="input-label">@lang('texts.country')</label>
|
2020-08-17 18:38:20 +02:00
|
|
|
<select id="country" class="input w-full form-select" name="country">
|
2020-03-23 18:10:42 +01:00
|
|
|
@foreach($countries as $country)
|
|
|
|
<option
|
2020-08-17 18:38:20 +02:00
|
|
|
{{ $country == isset(auth()->user()->client->country->id) ? 'selected' : null }} value="{{ $country->id }}">
|
2020-04-25 01:17:37 +02:00
|
|
|
{{ $country->iso_3166_2 }}
|
|
|
|
({{ $country->name }})
|
|
|
|
</option>
|
2020-03-23 18:10:42 +01:00
|
|
|
@endforeach
|
|
|
|
</select>
|
|
|
|
@error('country')
|
|
|
|
<div class="validation validation-fail">
|
|
|
|
{{ $message }}
|
|
|
|
</div>
|
|
|
|
@enderror
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div class="px-4 py-3 bg-gray-50 text-right sm:px-6">
|
|
|
|
<button class="button button-primary">
|
|
|
|
@lang('texts.save')
|
|
|
|
</button>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</form>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<!-- Client shipping address -->
|
|
|
|
<div class="mt-10 sm:mt-6">
|
|
|
|
<div class="md:grid md:grid-cols-3 md:gap-6">
|
|
|
|
<div class="md:col-span-1">
|
|
|
|
<div class="sm:px-0">
|
|
|
|
<h3 class="text-lg font-medium leading-6 text-gray-900">{{ ctrans('texts.shipping_address') }}</h3>
|
2020-03-26 22:43:57 +01:00
|
|
|
<p class="mt-1 text-sm leading-5 text-gray-500">
|
|
|
|
{{ ctrans('texts.enter_your_shipping_address') }}
|
2020-03-23 18:10:42 +01:00
|
|
|
</p>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div class="mt-5 md:mt-0 md:col-span-2">
|
|
|
|
<form action="{{ route('client.profile.edit_client', auth()->user()->hashed_id) }}" method="POST"
|
|
|
|
id="update_contact">
|
|
|
|
@csrf
|
|
|
|
@method('PUT')
|
|
|
|
<div class="shadow overflow-hidden rounded">
|
|
|
|
<div class="px-4 py-5 bg-white sm:p-6">
|
|
|
|
<div class="grid grid-cols-6 gap-6">
|
|
|
|
<div class="col-span-6 sm:col-span-4">
|
|
|
|
<label for="shipping_address1"
|
|
|
|
class="input-label">@lang('texts.shipping_address1')</label>
|
2020-04-25 01:17:37 +02:00
|
|
|
<input id="shipping_address1" class="input w-full" name="shipping_address1"
|
2020-03-23 18:10:42 +01:00
|
|
|
value="{{ auth()->user()->client->shipping_address1 }}"/>
|
|
|
|
@error('shipping_address1')
|
|
|
|
<div class="validation validation-fail">
|
|
|
|
{{ $message }}
|
|
|
|
</div>
|
|
|
|
@enderror
|
|
|
|
</div>
|
|
|
|
<div class="col-span-6 sm:col-span-3">
|
|
|
|
<label for="shipping_address2"
|
|
|
|
class="input-label">@lang('texts.shipping_address2')</label>
|
2020-04-25 01:17:37 +02:00
|
|
|
<input id="shipping_address2" class="input w-full" name="shipping_address2"
|
2020-03-23 18:10:42 +01:00
|
|
|
value="{{ auth()->user()->client->shipping_address2 }}"/>
|
|
|
|
@error('shipping_address2')
|
|
|
|
<div class="validation validation-fail">
|
|
|
|
{{ $message }}
|
|
|
|
</div>
|
|
|
|
@enderror
|
|
|
|
</div>
|
|
|
|
<div class="col-span-6 sm:col-span-3">
|
|
|
|
<label for="shipping_city" class="input-label">@lang('texts.shipping_city')</label>
|
2020-04-25 01:17:37 +02:00
|
|
|
<input id="shipping_city" class="input w-full" name="shipping_city"
|
2020-03-23 18:10:42 +01:00
|
|
|
value="{{ auth()->user()->client->shipping_city }}"/>
|
|
|
|
@error('shipping_city')
|
|
|
|
<div class="validation validation-fail">
|
|
|
|
{{ $message }}
|
|
|
|
</div>
|
|
|
|
@enderror
|
|
|
|
</div>
|
|
|
|
<div class="col-span-6 sm:col-span-2">
|
|
|
|
<label for="shipping_state"
|
|
|
|
class="input-label">@lang('texts.shipping_state')</label>
|
2020-04-25 01:17:37 +02:00
|
|
|
<input id="shipping_state" class="input w-full" name="shipping_state"
|
2020-03-23 18:10:42 +01:00
|
|
|
value="{{ auth()->user()->client->shipping_state }}"/>
|
|
|
|
@error('shipping_state')
|
|
|
|
<div class="validation validation-fail">
|
|
|
|
{{ $message }}
|
|
|
|
</div>
|
|
|
|
@enderror
|
|
|
|
</div>
|
|
|
|
<div class="col-span-6 sm:col-span-2">
|
|
|
|
<label for="shipping_postal_code"
|
|
|
|
class="input-label">@lang('texts.shipping_postal_code')</label>
|
2020-04-25 01:17:37 +02:00
|
|
|
<input id="shipping_postal_code" class="input w-full" name="shipping_postal_code"
|
2020-03-23 18:10:42 +01:00
|
|
|
value="{{ auth()->user()->client->shipping_postal_code }}"/>
|
|
|
|
@error('shipping_postal_code')
|
|
|
|
<div class="validation validation-fail">
|
|
|
|
{{ $message }}
|
|
|
|
</div>
|
|
|
|
@enderror
|
|
|
|
</div>
|
2020-04-25 01:17:37 +02:00
|
|
|
<div class="col-span-4 sm:col-span-2">
|
2020-03-23 18:10:42 +01:00
|
|
|
<label for="shipping_country"
|
|
|
|
class="input-label">@lang('texts.shipping_country')</label>
|
2020-08-17 18:38:20 +02:00
|
|
|
<select id="shipping_country" class="input w-full form-select" name="shipping_country">
|
2020-03-23 18:10:42 +01:00
|
|
|
@foreach($countries as $country)
|
|
|
|
<option
|
2020-08-17 18:38:20 +02:00
|
|
|
{{ $country == isset(auth()->user()->client->shipping_country->id) ? 'selected' : null }} value="{{ $country->id }}">
|
2020-04-25 01:17:37 +02:00
|
|
|
{{ $country->iso_3166_2 }}
|
|
|
|
({{ $country->name }})
|
2020-03-23 18:10:42 +01:00
|
|
|
</option>
|
|
|
|
@endforeach
|
|
|
|
</select>
|
|
|
|
@error('country')
|
|
|
|
<div class="validation validation-fail">
|
|
|
|
{{ $message }}
|
|
|
|
</div>
|
|
|
|
@enderror
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div class="px-4 py-3 bg-gray-50 text-right sm:px-6">
|
|
|
|
<button class="button button-primary">
|
|
|
|
@lang('texts.save')
|
|
|
|
</button>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</form>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
@endsection
|