optimize dates

pull/22/head
A1Gard 1 year ago
parent a9f5a13bfa
commit 2286c78545

@ -58,7 +58,7 @@
{{__('Expire date')}} {{__('Expire date')}}
</label> </label>
<input placeholder="{{__("Expire date")}}" type="text" data-reuslt="#exp-date" <input placeholder="{{__("Expire date")}}" type="text" data-reuslt="#exp-date"
class="form-control @error('expire') is-invalid @enderror dtp" @if(isset($discount)) value="{{\App\Helpers\time2persian($discount->expire)}}" @endif> class="form-control @error('expire') is-invalid @enderror dtp" @if(isset($discount)) value="{{$discount->expire->jdate('Y/m/d')}}" @endif>
<input type="hidden" name="expire" id="exp-date" @if(isset($discount)) value="{{strtotime($discount->expire)}}" @endif> <input type="hidden" name="expire" id="exp-date" @if(isset($discount)) value="{{strtotime($discount->expire)}}" @endif>
</div> </div>
</div> </div>

@ -65,7 +65,7 @@
@if($n->expire == null) @if($n->expire == null)
- -
@else @else
{{\App\Helpers\time2persian($n->expire)}} {{$n->expire->jdate('Y/m/d')}}
@endif @endif
</td> </td>
<td> <td>

@ -98,7 +98,7 @@
{{$dis->code}} {{$dis->code}}
</td> </td>
<td> <td>
{{\App\Helpers\time2persian($dis->expire)}} {{$dis->expire->jdate('Y/m/d')}}
</td> </td>
<td> <td>
<button type="button" class="btn btn-danger" data-id="{{$dis->id}}"> <button type="button" class="btn btn-danger" data-id="{{$dis->id}}">

@ -179,7 +179,7 @@
@endforeach @endforeach
</div> </div>
<div class="mb-1 text-muted"> <div class="mb-1 text-muted">
{{\App\Helpers\time2persian($p->created_at)}} {{$p->created_at->jdate('Y/m/d')}}
</div> </div>
<p> <p>
{{$p->subtitle}} {{$p->subtitle}}

@ -27,7 +27,7 @@
@endforeach @endforeach
</div> </div>
<div class="mb-1 text-muted"> <div class="mb-1 text-muted">
{{\App\Helpers\time2persian($p->created_at)}} {{$p->created_at->jdate('Y/m/d')}}
</div> </div>
<p> <p>
{{$p->subtitle}} {{$p->subtitle}}

Loading…
Cancel
Save