{!! Form::label('code', __('labels.coupon.form.code')) !!} * {!! Form::text('code', old('code', $data['coupon']->code ?? ''), ['class' => 'form-control', 'required']) !!} @if ($errors->has('code'))
{{ $errors->first('code') }}
@endif
{!! Form::label('discount_amount', __('labels.coupon.form.discount_amount')) !!} * {!! Form::number('discount_amount', old('discount_amount', $data['coupon']->discount_amount ?? null), ['class' => 'form-control', 'required', 'step' => '0.01', 'min' => '0']) !!} @if ($errors->has('discount_amount'))
{{ $errors->first('discount_amount') }}
@endif
{!! Form::label('discount_type', __('labels.coupon.form.discount_type')) !!} * {!! Form::select('discount_type', [ 'fixed' => 'Fixed Amount', 'percentage' => 'Percentage' ], old('discount_type', $data['coupon']->discount_type ?? null), [ 'class' => 'form-control', 'required' ] ) !!} @if ($errors->has('discount_type'))
{{ $errors->first('discount_type') }}
@endif
{!! Form::label('max_uses', __('labels.coupon.form.max_uses')) !!} * {!! Form::number('max_uses', old('max_uses', $data['coupon']->max_uses ?? ''), ['class' => 'form-control', 'required', 'min' => '0', 'step' => '1']) !!} @if ($errors->has('max_uses'))
{{ $errors->first('max_uses') }}
@endif
{!! Form::label('start_date', __('labels.coupon.form.start_date')) !!} * {!! Form::text('start_date', old('start_date', $data['coupon']->start_date ?? ''), ['class' => 'form-control', 'required']) !!} @if ($errors->has('start_date'))
{{ $errors->first('start_date') }}
@endif
{!! Form::label('end_date', __('labels.coupon.form.end_date')) !!} * {!! Form::text('end_date', old('end_date', $data['coupon']->end_date ?? ''), ['class' => 'form-control', 'required']) !!} @if ($errors->has('end_date'))
{{ $errors->first('end_date') }}
@endif
{!! Form::label('is_active', __('labels.coupon.form.active')) !!} * {!! Form::checkbox('is_active', 1, old('is_active', $data['coupon']->is_active ?? 1), ['id' => 'is_active']) !!} @if ($errors->has('is_active'))
{{ $errors->first('is_active') }}
@endif