@extends('layouts.app') @section('css') @endsection @section('content') @php $lang = $restaurant->default_lang; app()->setLocale($lang); if(session('app_lang') !==null){ $lang = session('app_lang'); app()->setLocale($lang); } @endphp
@if(isset($restaurant))

{!! $restaurant->name !!}

@endif
@csrf
@if(\Illuminate\Support\Facades\Auth::user()->role=="restaurant")

{{__('label.cover_image')}}

home_images) && !empty($restaurant->home_images->file_name)) style="background: url({!! $restaurant->home_images->file_name !!})" @endif>
@endif
@if(\Illuminate\Support\Facades\Auth::user()->role=="restaurant")
@endif
@if(\Illuminate\Support\Facades\Auth::user()->role=="restaurant")
@endif @if(\Illuminate\Support\Facades\Auth::user()->role=="restaurant") @if(isset($restaurant) && $restaurant->allow_whatsapp_notifications=="1")
@endif @endif
@php $countries = \App\Countries::whereNull('deleted_at')->get(); $outlet_countries = !empty($restaurant->outlet_countries)?explode(',',$restaurant->outlet_countries):[]; @endphp @if(\Illuminate\Support\Facades\Auth::user()->role=="administrator")
@endif @if(\Illuminate\Support\Facades\Auth::user()->role=="administrator")
@endif @if(\Illuminate\Support\Facades\Auth::user()->role=="restaurant")

@endif @php $resto_metas = \App\RestoMetaDefs::where('parent_meta_def_id',0)->get(); $colors = []; //dump($resto_metas); $existing_resto_meta = []; if(isset($restaurant)) $existing_resto_meta = \App\RestoMetas::where('bussiness_id',$restaurant->id)->whereNull('outlet_id')->pluck('meta_def_id')->toArray(); $existing_resto_meta = isset($existing_resto_meta )?$existing_resto_meta:[]; $existing_resto_meta_value = null; if(isset($restaurant)) $existing_resto_meta_value = \App\RestoMetas::where('bussiness_id',$restaurant->id)->whereNull('outlet_id')->get(); $v = []; if(isset($existing_resto_meta_value) && $existing_resto_meta_value->count() > 0){ foreach($existing_resto_meta_value as $value){ $v[$value->meta_def_id] = $value->meta_val; } } @endphp @if(isset($resto_metas) && $resto_metas->count() > 0) @foreach($resto_metas as $meta) @if($meta->for_role==\Illuminate\Support\Facades\Auth::user()->role) @if(($meta->meta_def_name=="DISPLAY_TAX_INFO" || $meta->meta_def_name=="TERM_AND_CONDITIONS") && $restaurant->countries->country_name=="Iraq" ) @continue @endif
@if($meta->input_type!="colors") @endif @if(isset($meta->childern) && $meta->childern->count() > 0 && $meta->input_type!="colors") @else @if($meta->input_type!="colors") @endif @if($meta->input_type=="text-field") meta_def_id])) value="{!! $v[$meta->meta_def_id] !!}" @endif @if($meta->is_required=="Yes") required @endif placeholder="{!! $meta->meta_def_desc !!}"> @endif @if($meta->input_type=="colors")
@if(isset($meta->childern) && $meta->childern->count() > 0) @foreach($meta->childern as $childern)

meta_def_id])) value="{!! $v[$childern->meta_def_id] !!}" @endif @if($childern->is_required=="Yes") required @endif placeholder="{!! str_replace('_',' ',$childern->meta_def_name) !!}">
@endforeach @endif
@endif @if($meta->input_type=="text-area") @endif @endif
@endif @endforeach @endif @php @endphp
@if(\Illuminate\Support\Facades\Auth::user()->role=="restaurant")
{{__('label.note_please_use_jpg_or_png_images')}}
@if(isset($restaurant) && isset($restaurant->photos))
{!! $restaurant->name !!}
@endif
@endif @if(\Illuminate\Support\Facades\Auth::user()->role=="restaurant") @if(isset($restaurant)) @endif @endif
@if(\Illuminate\Support\Facades\Auth::User()->role=="administrator")
active=="1") checked @endif name="active" type="checkbox"/>
@endif @if(\Illuminate\Support\Facades\Auth::User()->role=="administrator")
allow_whatsapp_notifications=="1") checked @endif name="allow_whatsapp_notifications" type="checkbox"/>
@endif
@if(isset($restaurant)) @endif
@if( isset($restaurant)) @endif @endsection @section('js') @endsection