@if(session()->has('user_updated')) @endif @include('includes.form_errors') {!! Form::model($user, ['method'=>'patch', 'action'=>['ManageCustomersController@update', $user->id], 'files'=>true, 'onsubmit'=>'submit_button.disabled = true; submit_button.value = "' . __('Please Wait...') . '"; return true;']) !!} @if($user->photo) Profile
@endif
{!! Form::label('name', __('Name:')) !!} {!! Form::text('name', null, ['class'=>'form-control', 'placeholder'=>__('Enter name'), 'required'])!!}
{!! Form::label('mobile', __('Mobile:')) !!} {!! Form::text('mobile', null, ['class'=>'form-control', 'placeholder'=>__('Enter Mobile'), 'required'])!!}
{!! Form::label('email',__('Email:')) !!} {!! Form::email('email', null, ['class'=>'form-control', 'placeholder'=>__('Enter email'), 'required']) !!}
@if($user->id !== 1) @can('update', App\User::class) @if(!$user->location || $user->location->id == Auth::user()->location_id)
{!! Form::label('role', __('Role:')) !!} {!! Form::select('role', ['0'=>__('None')] + $roles, $user->role_id, ['class'=>'form-control selectpicker', 'data-style'=>'btn-default']) !!}
@endif @endcan
{!! Form::label('verified', __('Email Status:')) !!} {!! Form::select('verified', [true=>__('verified'), false=>__('unverified')], $user->verified, ['class'=>'form-control selectpicker', 'data-style'=>'btn-default']) !!}
{!! Form::label('status', __('Status:')) !!} {!! Form::select('status', [0=>__('inactive'), 1=>__('active')], $user->is_active, ['class'=>'form-control selectpicker', 'data-style'=>'btn-default']) !!}
@endif
{!! Form::label('password', __('Password:')) !!} {!! Form::password('password', ['class'=>'form-control', 'placeholder'=>__('Enter password')]) !!}
{!! Form::label('password_confirmation', __('Confirm Password:')) !!} {!! Form::password('password_confirmation', ['class'=>'form-control', 'placeholder'=>__('Enter password again')]) !!}
{!! Form::label('photo', __('Choose photo (100px*100px)'), ['class'=>'btn btn-default btn-file']) !!} {!! Form::file('photo',['class'=>'form-control', 'style'=>'display: none;','onchange'=>'$("#upload-file-info").html(files[0].name)']) !!} @lang('No photo chosen')
{!! Form::submit(__('Update Customer'), ['class'=>'btn btn-primary btn-block', 'name'=>'submit_button']) !!}
{!! Form::close() !!}

@lang('Shipping Addresses')


@if(session()->has('address_deleted')) @endif @foreach($customers as $key => $customer)

{{$key+1}}. @lang('Shipping Address')

{{$customer->first_name . ' ' . $customer->last_name}},
{{$customer->address}}
{{$customer->city . ', ' . $customer->state . ' - ' . $customer->zip}}
{{$customer->country}}.
@lang('Phone:') {{$customer->phone}}
@lang('Email:') {{$customer->email}}
@lang('Edit') {!! Form::model($customer, ['method'=>'delete', 'action'=>['ManageAddressesController@destroy', $customer->id], 'id'=> 'delete-form-'.$customer->id, 'style'=>'display: none;']) !!} {!! Form::close() !!}    @lang('Remove')
@endforeach