From d7b9a0ac1a1a0cebb252e04adb2787d86cef869d Mon Sep 17 00:00:00 2001 From: chenzhi Date: Tue, 1 Sep 2020 16:28:18 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BC=98=E5=8C=96=E5=85=81=E8=AE=B8=E6=92=A4?= =?UTF-8?q?=E9=94=80=E6=B1=87=E6=80=BB=E8=BF=9B=E8=A1=8C=E7=9B=B4=E6=8E=A5?= =?UTF-8?q?=E6=B1=87=E6=80=BB?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../CompanyStatementController.class.php | 27 ++++++++++--------- .../Admin/View/CompanyStatement/lists.html | 6 ++--- 2 files changed, 17 insertions(+), 16 deletions(-) diff --git a/Application/Admin/Controller/CompanyStatementController.class.php b/Application/Admin/Controller/CompanyStatementController.class.php index d9a98773a..042994766 100644 --- a/Application/Admin/Controller/CompanyStatementController.class.php +++ b/Application/Admin/Controller/CompanyStatementController.class.php @@ -710,16 +710,17 @@ class CompanyStatementController extends ThinkController } foreach ($dbres as $k=>$v) { - if($v['verify_status'] != 1) continue; - if($v['company_belong'] == 9){ - //上游 - $this->setDf($datas['up'],$v); - } elseif($v['withdraw_type'] == 3&&$v['company_type']==1){ - $this->setDf($datas['complement_down'],$v); - } elseif($v['withdraw_type'] == 3&&$v['company_type']==2){ - $this->setDf($datas['complement_user'],$v); - } else { - $this->setDf($datas['down'],$v); + if($v['verify_status'] == 1 || $v['verify_status'] == -2){ + if($v['company_belong'] == 9){ + //上游 + $this->setDf($datas['up'],$v); + } elseif($v['withdraw_type'] == 3&&$v['company_type']==1){ + $this->setDf($datas['complement_down'],$v); + } elseif($v['withdraw_type'] == 3&&$v['company_type']==2){ + $this->setDf($datas['complement_user'],$v); + } else { + $this->setDf($datas['down'],$v); + } } } @@ -770,7 +771,7 @@ class CompanyStatementController extends ThinkController M("company_lack_statement_info","tab_")->where("id in ({$v['del_lack_ids']})")->save(["is_pool"=>1]); } //修改结算单规则 - $this->updatePoolVerifyStatus($v['statement_ids'],1,2,"pool",$v['statement_num']); + $this->updatePoolVerifyStatus($v['statement_ids'],2,"pool",$v['statement_num']); } $this->ajaxReturn(array( 'status' => 1, @@ -778,10 +779,10 @@ class CompanyStatementController extends ThinkController )); } //结算单规则 - protected function updatePoolVerifyStatus($ids,$old_status,$change_status,$op_pre,$num){ + protected function updatePoolVerifyStatus($ids,$change_status,$op_pre,$num){ $dbres = $this->DBModel->field("id,verify_status,verify_log")->where("id in ({$ids})")->select(); foreach($dbres as $k=>&$v){ - if($v['verify_status'] != $old_status) continue; + // if($v['verify_status'] != $old_status) continue; $v['verify_log'] = json_decode($v['verify_log'],true); $v['verify_log'][$op_pre.'_user']=$this->admininfo["username"]; $v['verify_log'][$op_pre.'_time']=date("Y.m.d H:i:s"); diff --git a/Application/Admin/View/CompanyStatement/lists.html b/Application/Admin/View/CompanyStatement/lists.html index 8147dc3f2..bc77a6907 100644 --- a/Application/Admin/View/CompanyStatement/lists.html +++ b/Application/Admin/View/CompanyStatement/lists.html @@ -475,8 +475,8 @@ }else if(id=="pool"){ var opname = "发起汇总"; var opurl = "{:U('pool')}"; - var opst ="[审批通过]"; - var status = [1]; + var opst ="[审批通过,汇总撤销]"; + var status = [1,-2]; }else if(id=="updateStatement"){ var opname = "重算金额"; var opurl = "{:U('updateStatement')}"; @@ -510,7 +510,7 @@ return; } text = text.join(","); - + console.log(text); if(flag){ layer.confirm(opname+"仅会对"+opst+"的申请进行处理,选择中包含其他的状态的申请将被忽略,点击取消停止操作",{title:false}, function(index){ layer.close(index);