@extends('layouts.app') @section('content')

{{ $store->name }}

{{-- Add Wallet Amount --}}
{{ trans('lang.restaurant_details') }}
{{-- {{ trans('lang.restaurant_details') }} --}}
@if ($store->getFirstMediaUrl('logo_image')) Store Logo @else

No logo uploaded.

@endif
{{--
Reviews
--}}
{{ $store->name }}
{{ $store->email }}
{{ $store->phone_code }}-{{ $store->phone }}
{{ $store->address }}
{{ $store->description }}
@php $shop_categories = $store->categories->whereNotNull('parent_id')->whereNull('vendor_id'); @endphp
@if ($shop_categories->count()) @foreach ($shop_categories as $category) {{ $category->name }} @endforeach @else - @endif
{{--
--}}
{{ trans('lang.gallery') }}
@if ($store->getMedia('banner_image')->count()) {{-- --}} @foreach ($store->getMedia('banner_image') as $media) {{-- --}} @endforeach
{{ trans('lang.image') }}{{ trans('lang.actions') }}
gallery
@endif
{{-- @dd($store->vendor) --}} {{ trans('lang.vendor_details') }}
{{ $store->vendor?->business_name }}
{{ $store->vendor?->email }}
{{ $store->is_active ? 'Open' : 'Closed' }}
{{ $store->vendor?->phone_code }}- {{ $store->vendor?->phone }}
{{ trans('lang.working_hours') }} @php use Carbon\Carbon; $days = [ 'Sunday', 'Monday', 'Tuesday', 'Wednesday', 'Thursday', 'Friday', 'Saturday', ]; $workingHours = collect($store->workingHours ?? []); @endphp @foreach ($days as $day) @php $entry = $workingHours->firstWhere('day', $day); $from = $entry['from'] ?? null; $to = $entry['to'] ?? null; try { $fromFormatted = $from ? Carbon::createFromFormat( 'H:i:s', $from, )->format('h:i A') : null; $toFormatted = $to ? Carbon::createFromFormat( 'H:i:s', $to, )->format('h:i A') : null; } catch (\Exception $e) { $fromFormatted = $from; $toFormatted = $to; } @endphp
{{ trans('lang.' . strtolower($day)) }}
@if (!$fromFormatted || !$toFormatted) Closed @else {{ $fromFormatted }} - {{ $toFormatted }} @endif
@endforeach
Other Stores From This Vendor
@if ($vendorStores->isEmpty())

No other stores found for this vendor.

@else
@foreach ($vendorStores as $vendorStore) @endforeach
Store Name Email Phone Actions
{{ $vendorStore->name }} {{ $vendorStore->email }} {{ $vendorStore->phone }} View
@endif
@php $productMode = $productMode ?? 'list'; $categoryFilterId = request('category_id'); $returnTab = request('return_tab'); $clearTab = $returnTab === 'menu' ? 'menu' : 'products_list'; $activeCategory = $categoryFilterId && $menuCategories ? $menuCategories->firstWhere('id', (int) $categoryFilterId) : null; @endphp @if ($productMode === 'list') @if ($activeCategory)
Showing products in category: {{ $activeCategory->name }} Clear filter
@endif
{{ trans('lang.product_create') }} {{ trans('lang.product_import') }} @php $productListUrl = route('products.list', array_filter([ 'store_id' => $store->id, 'edit_context' => 'store', 'category_id' => $categoryFilterId, 'return_tab' => $returnTab, ], function ($value) { return $value !== null && $value !== ''; })); @endphp @include('products.partials.listing_table', [ 'productListUrl' => $productListUrl, ])
@elseif ($productMode === 'import_product')
@php $storeId = $store->id; $redirectUrl = route('stores.show', [ 'id' => $store->id, 'tab' => 'products_list', ]) ; @endphp @include('products.partials.import', [ 'store_id' => $store->id, 'redirectUrl'=>$redirectUrl ])
@elseif ($productMode === 'create')
@php $formMode = 'create'; $formAction = route('products.store'); $formMethod = 'POST'; $product = null; $productAttributes = []; $brands = collect(); $categories = collect(); $storeId = $store->id; $redirectUrl = route('stores.show', [ 'id' => $store->id, 'product_mode' => 'list', ]) . '#review_attributes'; $formIdPrefix = 'product_create'; @endphp @include('products.partials.form')
@elseif ($productMode === 'edit')
@if ($editProduct) @php $formMode = 'edit'; $formAction = route('products.update', $editProduct->id); $formMethod = 'PUT'; $product = $editProduct; $allProducts = $allProducts; $categories = $editCategories; $storeId = $store->id; $editProductId = $product->id ?? ''; $redirectUrl = route('stores.show', [ 'id' => $store->id, 'product_mode' => 'list', ]) . '#review_attributes'; $formIdPrefix = 'product_edit'; @endphp @include('products.partials.form') @else

{{ trans('lang.no_record_found') }}

@endif
@endif
@php $comboMode = $comboMode ?? 'list'; @endphp @if ($comboMode === 'list') {{ trans('lang.combo_create') }}