@extends('EcomAuthViews::layouts.authentication.layout' , ['title' => 'Register Account']) @section('content') @php $country_code = $data['phone_country_code']; $phone_value = $data['phone']; $email = $data['email']; @endphp
@csrf {{-- --}} @foreach($fields as $field) @php $value = isset($data[$field['name']]) ? $data[$field['name']] : ""; @endphp @switch($field['type']) @case('text') @component('EcomGeneralViews::components.form.input', [ "parentClass" => "", "size" => $field['size'], "type" => "text", "label" => ___($field['label']). " ". ( $field['required'] ? "*" : "") ]) @error($field['name']) {{$message}} @enderror @endcomponent @break @case('password') @component('EcomGeneralViews::components.form.input', [ "parentClass" => "", "size" => $field['size'], "type" => "text", "label" => ___($field['label']). " ". ( $field['required'] ? "*" : "") ])
@error($field['name']) {{$message}} @enderror @endcomponent @break @case('phone') @php $country_code = isset($data[$field['name'].'_country_code']) ? $data[$field['name'].'_country_code'] : ""; @endphp @component('EcomAuthViews::components.phone' , ['phone_value' => $value , 'country_code' =>$country_code ] ) @endcomponent @break @endswitch @endforeach @component('EcomGeneralViews::components.form.input', [ "parentClass" => "", "size" => "full", "type" => "submit", "label" => "" ]) @endcomponent {{-- @component('EcomGeneralViews::components.form.input', [ "parentClass" => "", "size" => "full", "type" => "text", "label" => ___('authentication.last_name'). " *" ])--}} {{-- --}} {{-- @error('last_name') {{$message}} @enderror --}} {{-- @endcomponent--}} {{-- @switch($type)--}} {{-- @case("phone")--}} {{-- @component('EcomGeneralViews::components.form.input', [ "parentClass" => "", "size" => "full", "type" => "text", "label" => ___('authentication.phone_number') . " *" ])--}} {{-- --}} {{-- --}} {{-- @error('phone') {{$message}} @enderror --}} {{-- @endcomponent--}} {{-- @break--}} {{-- @case("email")--}} {{-- @component('EcomGeneralViews::components.form.input', [ "parentClass" => "", "size" => "full", "type" => "text", "label" => ___('authentication.email'). " *" ])--}} {{-- --}} {{-- @error('email') {{$message}} @enderror --}} {{-- @endcomponent--}} {{-- @break--}} {{-- @endswitch--}} {{-- @if($type == "phone" && in_array($type,array_diff($config['auth_types'] , $config['auth_verifications'])))--}} {{-- @component('EcomGeneralViews::components.form.input', [ "parentClass" => "", "size" => "full", "type" => "text", "label" => ___('authentication.phone_number') . " *" ])--}} {{-- --}} {{-- --}} {{-- @error('phone') {{$message}} @enderror --}} {{-- @endcomponent--}} {{-- @endif--}} {{-- @if($type == "email" && in_array($type,array_diff($config['auth_types'] , $config['auth_verifications'])))--}} {{-- @component('EcomGeneralViews::components.form.input', [ "parentClass" => "", "size" => "full", "type" => "text", "label" => ___('authentication.email'). " *" ])--}} {{-- --}} {{-- @error('email') {{$message}} @enderror --}} {{-- @endcomponent--}} {{-- @endif--}} {{-- @component('EcomGeneralViews::components.form.input', [ "parentClass" => "", "size" => "full", "type" => "text", "label" => ___('authentication.password') . " *" ])--}} {{-- --}} {{-- @error('password') {{$message}} @enderror --}} {{-- @endcomponent--}} {{-- @component('EcomGeneralViews::components.form.input', [ "parentClass" => "", "size" => "full", "type" => "text", "label" => ___('authentication.confirm_password'). " *" ])--}} {{-- --}} {{-- @error('confirm_password') {{$message}} @enderror --}} {{-- @endcomponent--}} {{--
--}} {{-- @component('EcomGeneralViews::components.form.input', [ "parentClass" => "", "size" => "full", "type" => "submit", "label" => "" ])--}} {{-- --}} {{-- @endcomponent--}}
{{ ___('authentication.or') }}
{{ ___('authentication.already_have_account') }} {{ ___('authentication.login') }}
@endsection @section('scripts') @endsection