|
@@ -678,8 +678,17 @@ class CheckService extends Service
|
|
|
list($status, $msg) = (new SalesOrderService())->salesOrderDel(['id' => $value['id']]);
|
|
|
if(! $status) return [false,$msg];
|
|
|
|
|
|
- list($status, $msg) = (new PaymentReceiptService())->customerDel(['id' => $value['id']]);
|
|
|
- if(! $status) return [false,$msg];
|
|
|
+ $info = PaymentReceiptInfo::where('del_time',0)
|
|
|
+ ->where('type',PaymentReceiptInfo::type_three)
|
|
|
+ ->where('data_order_no', $value['order_number'])
|
|
|
+ ->select('payment_receipt_id')
|
|
|
+ ->first();
|
|
|
+ if(! empty($info)){
|
|
|
+ $payment_id = $info->payment_receipt_id;
|
|
|
+ list($status, $msg) = (new PaymentReceiptService())->customerDel(['id' => $payment_id]);
|
|
|
+ if(! $status) return [false,$msg];
|
|
|
+ }
|
|
|
+
|
|
|
}
|
|
|
|
|
|
return [true, ''];
|