@extends('layouts.admin', ['title' => 'فهرست سفارشات']) @php $setting = App\Models\Setting::first(); $tax = $setting->tax; $cartDefaultSMS = App\Models\CartDefaultSMS::get(); @endphp @section('content') @if($mode == 'list')
@if(isset($search))

نتیجه جستجو عبارت «{{ $search }}» بازگشت

@else

فهرست سفارشات تلگرامی

@endif
{!! $errors->first('first_name', ':message') !!}
@if(count($data)==0) @else @php $num=1; @endphp @foreach($data as $item) @if(isset($search)) @else @endif @php $num+=1; @endphp @endforeach
ردیف شماره‌ پیگیری تاریخ نام شماره همراه جمع وضعیت
{{ $num }} DT-{{ $item->id }} {{ GetShamsiDate($item->created_at) }}{{ $item->flname }} {{ $item->mobile }}{{ $item->User->flname }} {{ $item->User->mobile }}@php $total = 0 ; @endphp @foreach(\DB::select('select *,(select title from products where id=tg_cart_items.product_id) as title,(select link from products where id=tg_cart_items.product_id) as link,(select tax from products where id=tg_cart_items.product_id) as tax from tg_cart_items where tg_cart_id = ' . $item->id,array()) as $item_p) @php $amount = $item_p->amount; $amount_num = $item_p->amount * $item_p->num ; //if($item_p->tax == 0 ){ // $amount += $tax * $amount / 100; // $amount_num += $tax * $amount_num / 100; // } @endphp @php $total +=$amount_num ; //$item->paid @endphp @endforeach {{ number_format($total, 0, '', ',') }} تومان {{ $AdminTelegramOrdersController->getStatusTitle($item->status) }} مشاهده
@if(!isset($search)) {!! $data->render(); !!} @endif
@endif @elseif($mode == "single") @php $current_status = 0; @endphp

مشاهده جزئیات سفارش - {{ $data->User->flname . " " . $data->User->mobile }} تاریخچه سفارشات

@php $total = 0 @endphp @php $num=1; @endphp @foreach(\DB::select('select * from tg_carts where id ='. $cid .' and status<>0',array()) as $item) @php $current_status = $item->status; @endphp @php $num++; @endphp @endforeach
ردیف شماره‌ پیگیری تاریخ جمع وضعیت
{{ $num }} DT-{{ $item->id }} @if($item->status== 6){{ GetShamsiDate($item->created_at) }}@else{{ $item->paid_at != '0000-00-00 00:00:00' && $item->paid_at != '' ? GetShamsiDate($item->paid_at) : GetShamsiDate($item->updated_at) }}@endif @php $total = 0 ; @endphp @foreach(\DB::select('select *,(select title from products where id=tg_cart_items.product_id) as title,(select link from products where id=tg_cart_items.product_id) as link,(select tax from products where id=tg_cart_items.product_id) as tax from tg_cart_items where tg_cart_id = ' . $item->id,array()) as $item_p) @php $amount = $item_p->amount; $amount_num = $item_p->amount * $item_p->num ; //if($item_p->tax == 0 ){ // $amount += $tax * $amount / 100; // $amount_num += $tax * $amount_num / 100; //} @endphp @php $total +=$amount_num ; //$item->paid @endphp @endforeach {{ number_format($total, 0, '', ',') }} تومان {{ $AdminTelegramOrdersController->getStatusTitle($item->status) }} مدارک
@foreach(\DB::select('select *,(select title from products where id=tg_cart_items.product_id) as title,(select link from products where id=tg_cart_items.product_id) as link,(select tax from products where id=tg_cart_items.product_id) as tax from tg_cart_items where tg_cart_id =' . $item->id,array()) as $item2) @php $amount = $item2->amount; $amount_num = $item2->amount * $item2->num ; //if($item2->tax == 0 ){ // $amount += $tax * $amount / 100; // $amount_num += $tax * $amount_num / 100; //} @endphp @endforeach
شرح محصول تعداد قیمت واحد قیمت کل
{{ $item2->title }} {{ ($item2->color !="" ? " - " . $item2->color : "" ) }} {{ $item2->num }}{{ number_format( $amount, 0, '', ',') }} تومان {{ number_format($amount_num, 0, '', ',') }} تومان
هزینه ارسال {{ $item->shipping_amount }} تومان

تحویل گیرنده : {{ $item->first_name . " " . $item->last_name }}
آدرس:{{ $item->address }}
کدپستی:{{ $item->zipcode }}
شماره تماس:{{ $item->phone }}
همراه:{{ $item->mobile }}
کدملی:{{ $item->pcode }}
نظام پزشکی:{{ $item->medical_number }}

کپی اطلاعات به پروفایل کاربر
@if( $data->User->image_medical != '') کارت نظام‌پزشکی @endif @if($data->image_request !='') تصویر درخواست کتبی @endif @if( $data->image_other != '') سایر مدارک @endif
چاپ فاکتور چاپ فاکتور رسمی برگه ارسال
بازگشت ویرایش حذف
@endif @stop