|
|
@ -253,13 +253,29 @@ class Order extends OrderModel |
|
|
|
$filter[] = ['pay_status', '=', PayStatusEnum::PENDING]; |
|
|
|
$filter[] = ['pay_status', '=', PayStatusEnum::PENDING]; |
|
|
|
$filter[] = ['order_status', '=', OrderStatusEnum::NORMAL]; |
|
|
|
$filter[] = ['order_status', '=', OrderStatusEnum::NORMAL]; |
|
|
|
break; |
|
|
|
break; |
|
|
|
|
|
|
|
//待付款 |
|
|
|
|
|
|
|
case 'pay': |
|
|
|
|
|
|
|
$filter[] = ['pay_status', '=', PayStatusEnum::PENDING]; |
|
|
|
|
|
|
|
$filter[] = ['order_status', '=', OrderStatusEnum::NORMAL]; |
|
|
|
|
|
|
|
break; |
|
|
|
|
|
|
|
//待发货 |
|
|
|
case 'delivery': |
|
|
|
case 'delivery': |
|
|
|
$filter = [ |
|
|
|
$filter = [ |
|
|
|
['pay_status', '=', PayStatusEnum::SUCCESS], |
|
|
|
['pay_status', '=', PayStatusEnum::SUCCESS], |
|
|
|
['delivery_status', '<>', DeliveryStatusEnum::DELIVERED], |
|
|
|
['delivery_status', '<>', DeliveryStatusEnum::DELIVERED], |
|
|
|
['order_status', 'in', [OrderStatusEnum::NORMAL, OrderStatusEnum::APPLY_CANCEL]] |
|
|
|
['order_status', 'in', [OrderStatusEnum::NORMAL, OrderStatusEnum::APPLY_CANCEL]] |
|
|
|
]; |
|
|
|
]; |
|
|
|
break; |
|
|
|
break; |
|
|
|
|
|
|
|
//待收货 |
|
|
|
|
|
|
|
case 'receipt': |
|
|
|
|
|
|
|
$filter = [ |
|
|
|
|
|
|
|
['pay_status', '=', PayStatusEnum::SUCCESS], |
|
|
|
|
|
|
|
['delivery_status', '=', DeliveryStatusEnum::DELIVERED], |
|
|
|
|
|
|
|
['receipt_status', '=', ReceiptStatusEnum::NOT_RECEIVED], |
|
|
|
|
|
|
|
['order_status', '=', OrderStatusEnum::NORMAL] |
|
|
|
|
|
|
|
]; |
|
|
|
|
|
|
|
break; |
|
|
|
|
|
|
|
//待收货 |
|
|
|
case 'received': |
|
|
|
case 'received': |
|
|
|
$filter = [ |
|
|
|
$filter = [ |
|
|
|
['pay_status', '=', PayStatusEnum::SUCCESS], |
|
|
|
['pay_status', '=', PayStatusEnum::SUCCESS], |
|
|
@ -268,6 +284,25 @@ class Order extends OrderModel |
|
|
|
['order_status', '=', OrderStatusEnum::NORMAL] |
|
|
|
['order_status', '=', OrderStatusEnum::NORMAL] |
|
|
|
]; |
|
|
|
]; |
|
|
|
break; |
|
|
|
break; |
|
|
|
|
|
|
|
//已完成 |
|
|
|
|
|
|
|
case 'complete': |
|
|
|
|
|
|
|
$filter = [ |
|
|
|
|
|
|
|
['order_status', '=', OrderStatusEnum::COMPLETED] |
|
|
|
|
|
|
|
]; |
|
|
|
|
|
|
|
break; |
|
|
|
|
|
|
|
//待取消 |
|
|
|
|
|
|
|
case 'apply_cancel': |
|
|
|
|
|
|
|
$filter = [ |
|
|
|
|
|
|
|
['order_status', '=', OrderStatusEnum::APPLY_CANCEL] |
|
|
|
|
|
|
|
]; |
|
|
|
|
|
|
|
break; |
|
|
|
|
|
|
|
//已取消 |
|
|
|
|
|
|
|
case 'cancel': |
|
|
|
|
|
|
|
$filter = [ |
|
|
|
|
|
|
|
['order_status', '=', OrderStatusEnum::CANCELLED] |
|
|
|
|
|
|
|
]; |
|
|
|
|
|
|
|
break; |
|
|
|
|
|
|
|
//已评价 |
|
|
|
case 'comment': |
|
|
|
case 'comment': |
|
|
|
$filter = [ |
|
|
|
$filter = [ |
|
|
|
['is_comment', '=', 0], |
|
|
|
['is_comment', '=', 0], |
|
|
|