@extends('layouts.master')
@section('title', 'تفاصيل العرض')
@section('css')
@endsection
@section('content')
@php $loc = app()->getLocale(); @endphp
{{ $offer->offer_no }}
@switch($offer->scope)
@case('members')
الأعضاء
@break
@case('customers')
العملاء
@break
@case('coupons')
كوبونات
@break
@default
جميع الأعضاء/العملاء
@endswitch
{!! $offer->active
? ' نشط'
: ' غير نشط' !!}
{{-- ✅ Live status --}}
{!! $offer->is_live
? ' Live'
: ' Not Live' !!}
الفترة (ميلادي)
{{ $offer->start_date_g }} → {{ $offer->end_date_g }}
الفترة (هجري)
{{ $offer->start_date_h ?? '—' }} → {{ $offer->end_date_h ?? '—' }}
المدّة بالأيام
{{ $offer->duration_days }}
خصم عام
@if ($offer->discount_type === 'percent')
{{ number_format($offer->discount_value, 2) }}%
@else
{{ number_format($offer->discount_value, 2) }}
@endif
أيام إضافية للخدمات
{{ (int) $offer->extra_days }}
خدمات العرض
عدد الخدمات: {{ $offer->items->count() }}
| # |
الخدمة |
السعر الأساسي |
المدة الأساسية |
السعر النهائي |
المدة النهائية |
@foreach ($offer->items as $i => $it)
@php
$name =
$it->service?->getTranslation('name', $loc) ??
($it->service_name[$loc] ?? ($it->service_name['en'] ?? ''));
@endphp
| {{ $i + 1 }} |
{{ $name }}
|
{{ number_format($it->base_price, 2) }} |
{{ $it->base_duration_value }} {{ $it->base_duration_unit }} |
{{ number_format($it->final_price, 2) }} |
{{ $it->final_duration_value }} {{ $it->final_duration_unit }} |
@endforeach
@if ($offer->items->isEmpty())
| لا توجد خدمات مرتبطة بهذا العرض. |
@endif
@endsection