优化重算需重新确认

master
chenzhi 4 years ago
parent fb9deff8b7
commit 0e8730b810

@ -395,7 +395,7 @@ class CompanyStatementController extends ThinkController
$ids = $_REQUEST['ids']; $ids = $_REQUEST['ids'];
$dbres = $this->DBModel->field("id,verify_status,verify_log")->where("id in ({$ids})")->select(); $dbres = $this->DBModel->field("id,verify_status,verify_log")->where("id in ({$ids})")->select();
foreach($dbres as $k=>&$v){ foreach($dbres as $k=>&$v){
if(in_array($v['verify_status'],[3,4])) continue; //合作方确认后不进行重算 // if(in_array($v['verify_status'],[3,4])) continue; //合作方确认后不进行重算
//重算 //重算
$res = A("CompanyStatementSet")->updateCompanyStatementData($v['id'],$this->admininfo["username"]); $res = A("CompanyStatementSet")->updateCompanyStatementData($v['id'],$this->admininfo["username"]);
if($res === false){ if($res === false){

@ -1175,6 +1175,8 @@ class CompanyStatementSetController extends Controller {
//重写用户 //重写用户
$savedata['verify_log'] = json_encode(["create_user"=>$admin_user,"create_time"=>date("Y-m-d H:i:s")]); $savedata['verify_log'] = json_encode(["create_user"=>$admin_user,"create_time"=>date("Y-m-d H:i:s")]);
$savedata['verify_status'] = 0; $savedata['verify_status'] = 0;
$savedata['confirm_status'] = 0;
$savedata['confirm_log'] = '';
$savedata['id'] = $dbres['id']; $savedata['id'] = $dbres['id'];
return $StatementDb->save($savedata); return $StatementDb->save($savedata);
} }

Loading…
Cancel
Save