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. -->
|
2020-09-24 13:29:41 +02:00
|
|
|
@livewire('profile.settings.general')
|
2020-09-24 13:44:56 +02:00
|
|
|
|
2020-03-23 18:10:42 +01:00
|
|
|
<!-- Name, website & logo -->
|
2020-09-24 13:44:56 +02:00
|
|
|
@livewire('profile.settings.name-website-logo')
|
2020-03-23 18:10:42 +01:00
|
|
|
|
|
|
|
<!-- 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
|