diff --git a/app/common/service/FinReceiptService.php b/app/common/service/FinReceiptService.php index 1f1c731..52e3681 100644 --- a/app/common/service/FinReceiptService.php +++ b/app/common/service/FinReceiptService.php @@ -216,6 +216,9 @@ class FinReceiptService $query->whereNull('payment_apply_id'); } elseif (isset($param['payment_apply']) && $param['payment_apply'] == 'already') { $query->whereNotNull('payment_apply_id'); + } elseif (isset($param['payment_apply']) && $param['payment_apply'] == 'timeout') { //超时未认领 + $query->whereNull('payment_apply_id'); + $query->where('created_at', '<' ,time() - 24*60*60); } if (isset($param['scene']) && $param['scene'] == 'list') { @@ -301,19 +304,4 @@ class FinReceiptService $updated = $this->logicUpdateBy($config, $data); return $this->postProcess(ucfirst($scene), $data); } - - /** - * 收款记录统计 - * @return bool|int - */ - public function statistics() - { - $finReceipt = FinReceipt::find($id); - if(!empty($finReceipt->received_at)){ - throw new BusinessException('该记录已将确认入账'); - } - $res = $this->logic->credit($id); - $this->afterServiceUpdate(['id'=>$id]); - return $res; - } } \ No newline at end of file