提交 71a7a6a6 authored 作者: chengye's avatar chengye

test

上级 30be55b1
...@@ -350,7 +350,7 @@ class Payment extends Base ...@@ -350,7 +350,7 @@ class Payment extends Base
$paymentModel->staff_id = $data['staff_id']; $paymentModel->staff_id = $data['staff_id'];
$paymentModel->cid = $this->uid; $paymentModel->cid = $this->uid;
$paymentModel->payment_type = $em->em_type_id; $paymentModel->payment_type = $em->em_type_id;
$paymentModel->is_check = $em->em_type_id == 2 || $em->em_type_id == 4 ? 0 : 1; // $paymentModel->is_check = $em->em_type_id == 2 || $em->em_type_id == 4 ? 0 : 1;
$paymentModel->status = 0; $paymentModel->status = 0;
if($paymentModel->save($data)) if($paymentModel->save($data))
...@@ -365,7 +365,7 @@ class Payment extends Base ...@@ -365,7 +365,7 @@ class Payment extends Base
public function checkPayment(){ public function checkPayment(){
$payment_id = Request::param('payment_id'); $payment_id = Request::param('payment_id');
$payment = EmPayment::get(['payment_id'=>$payment_id]); $payment = EmPayment::get(['payment_id'=>$payment_id]);
if($payment->is_check !== 0) return json(['status'=>0,'message'=>'单据已经审核过,不能再次审核']); if($payment->status !== 0) return json(['status'=>0,'message'=>'单据已经审核过,不能再次审核']);
//如果是驳回则记录驳回状态 //如果是驳回则记录驳回状态
$checkType = Request::param('checkType'); $checkType = Request::param('checkType');
...@@ -376,7 +376,7 @@ class Payment extends Base ...@@ -376,7 +376,7 @@ class Payment extends Base
return json(['status'=>0,'message'=>'单据已经驳回']); return json(['status'=>0,'message'=>'单据已经驳回']);
} }
$payment->status = 1; $payment->status = 1;
$payment->is_check = 1; // $payment->is_check = 1;
$payment->save(); $payment->save();
return json(['status'=>1,'message'=>'已审核']); return json(['status'=>1,'message'=>'已审核']);
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论