@extends('layouts.admin') @section('content') @php $readonly=''; @endphp @if($action=='View') @php $readonly='readonly'; @endphp @endif

{{ __($title) }}

@if($action == 'Edit')
{{ method_field('PUT') }} @else @endif @csrf
@if(old('coupon_id')) @php $coupon_id = old('coupon_id'); @endphp @elseif(isset($record->coupon_id) && $record->coupon_id != '') @php $coupon_id = $record->coupon_id; @endphp @else @php $coupon_id = ''; @endphp @endif @error('coupon_id') {{ $message }} @enderror
@if(old('assign_to')) @php $assign_to = old('assign_to'); @endphp @elseif(isset($record->assign_to) && $record->assign_to != '') @php $assign_to = $record->assign_to; @endphp @else @php $assign_to = ''; @endphp @endif @error('assign_to') {{ $message }} @enderror
@if (isset($record)) @php $expiry_date=date('Y-m-d',strtotime($record->expiry_date)) @endphp @elseif(old('expiry_date')) @php $expiry_date=old('expiry_date') @endphp @else @php $expiry_date='' @endphp @endif @error('expiry_date') {{ $message }} @enderror
@if(isset($record->active)) @php $active = $record->active; @endphp @else @php $active = 1; @endphp @endif
@if($action!='View') @endif {!! ($action!='View') ? 'Cancel' : 'Back' !!}
@endsection @push('scripts') @endpush