|
|
@ -110,7 +110,7 @@ class AggregateFinanceStatementController extends ThinkController
|
|
|
|
|
|
|
|
|
|
|
|
$data[$key]['oplist'] = $this->OpAuth($value);
|
|
|
|
$data[$key]['oplist'] = $this->OpAuth($value);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
$count = M("aggregate_statement","tab_")->field("count(id) count,SUM(ratio_money) ratio_money")->where($map)->find();
|
|
|
|
$count = M("aggregate_statement","tab_")->field("count(id) count,SUM(ratio_money) ratio_money,SUM(pay_money) pay_money")->where($map)->find();
|
|
|
|
|
|
|
|
|
|
|
|
//分页
|
|
|
|
//分页
|
|
|
|
$parameter['p'] = $page;
|
|
|
|
$parameter['p'] = $page;
|
|
|
@ -123,6 +123,7 @@ class AggregateFinanceStatementController extends ThinkController
|
|
|
|
$this->assign('menubtn',$this->menuAuth());
|
|
|
|
$this->assign('menubtn',$this->menuAuth());
|
|
|
|
$this->assign('data',$data);
|
|
|
|
$this->assign('data',$data);
|
|
|
|
$this->assign('total',$count['ratio_money']);
|
|
|
|
$this->assign('total',$count['ratio_money']);
|
|
|
|
|
|
|
|
$this->assign('pay_money',$count['pay_money']);
|
|
|
|
$this->assign('channel',$this->getAggChannel());
|
|
|
|
$this->assign('channel',$this->getAggChannel());
|
|
|
|
$this->assign('verify_status',$this->verify_status);
|
|
|
|
$this->assign('verify_status',$this->verify_status);
|
|
|
|
$this->display();
|
|
|
|
$this->display();
|
|
|
@ -347,11 +348,21 @@ class AggregateFinanceStatementController extends ThinkController
|
|
|
|
public function delVoucher(){
|
|
|
|
public function delVoucher(){
|
|
|
|
if(!isset($_REQUEST['id'])) $this->error("参数错误");
|
|
|
|
if(!isset($_REQUEST['id'])) $this->error("参数错误");
|
|
|
|
$id = $_REQUEST['id'];
|
|
|
|
$id = $_REQUEST['id'];
|
|
|
|
$info = M("aggregate_statement","tab_")->field("id,ext_field")->where("id = '{$id}'")->find();
|
|
|
|
$info = M("aggregate_statement","tab_")->field("id,ext_field,verify_status")->where("id = '{$id}'")->find();
|
|
|
|
if(!empty($info['ext_field'])){
|
|
|
|
if(!empty($info['ext_field'])){
|
|
|
|
unlink("./".$info['ext_field']);
|
|
|
|
unlink("./".$info['ext_field']);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
M("aggregate_statement","tab_")->where("id = '{$id}'")->save(['ext_field'=>'']);
|
|
|
|
$save = [
|
|
|
|
|
|
|
|
"ext_field"=>'',
|
|
|
|
|
|
|
|
];
|
|
|
|
|
|
|
|
//如果是已上传凭证状态就回退到审核通过
|
|
|
|
|
|
|
|
if($info["verify_status"] == 4){
|
|
|
|
|
|
|
|
$save['verify_status'] = 3;
|
|
|
|
|
|
|
|
$save['create_time'] = time();
|
|
|
|
|
|
|
|
$save["admin_name"]=$this->admininfo["username"];
|
|
|
|
|
|
|
|
$save["admin_id"]=$this->admininfo["uid"];
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
M("aggregate_statement","tab_")->where("id = '{$id}'")->save($save);
|
|
|
|
$this->doAddOperationLog($id,"删除凭证");
|
|
|
|
$this->doAddOperationLog($id,"删除凭证");
|
|
|
|
$this->ajaxReturn(array(
|
|
|
|
$this->ajaxReturn(array(
|
|
|
|
'status' => 1,
|
|
|
|
'status' => 1,
|
|
|
|