|
|
|
@ -60,9 +60,23 @@ class CompanyStatementOfflineController extends ThinkController
|
|
|
|
|
$map['p.statement_num'] =["LIKE","%{$_REQUEST['statement_pool_num']}%"];
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
//条件end
|
|
|
|
|
if (isset($_REQUEST['export']) && $_REQUEST['export']==1) {
|
|
|
|
|
$map['c.company_type'] = $_REQUEST['export_company_type'];
|
|
|
|
|
$data = SM("company_statement_info","tab_")
|
|
|
|
|
->alias("c")
|
|
|
|
|
->field("c.*,p.statement_num,p.verify_status")
|
|
|
|
|
->where($map)
|
|
|
|
|
->where(['p.verify_status'=>['neq',6]])
|
|
|
|
|
->join("tab_company_statement_pool as p ON c.pool_id = p.id")
|
|
|
|
|
->order("id desc")
|
|
|
|
|
->select();
|
|
|
|
|
$ids = array_column($data, 'id');
|
|
|
|
|
$ids = implode(',', $ids);
|
|
|
|
|
$this->export($ids);
|
|
|
|
|
return ;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
$data = SM("company_statement_info","tab_")
|
|
|
|
|
->alias("c")
|
|
|
|
|
->field("c.*,p.statement_num,p.verify_status")
|
|
|
|
@ -287,9 +301,12 @@ class CompanyStatementOfflineController extends ThinkController
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public function export(){
|
|
|
|
|
if(!isset($_REQUEST['ids'])) $this->error("参数错误");
|
|
|
|
|
$ids = $_REQUEST['ids'];
|
|
|
|
|
public function export($ids=''){
|
|
|
|
|
if (!$ids) {
|
|
|
|
|
if (!isset($_REQUEST['ids'])) $this->error("参数错误");
|
|
|
|
|
$ids = $_REQUEST['ids'];
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
$dbres = SM("company_statement_info","tab_")->where("id in ({$ids})")->select();
|
|
|
|
|
|
|
|
|
|
$is_export= false;
|
|
|
|
@ -351,6 +368,7 @@ class CompanyStatementOfflineController extends ThinkController
|
|
|
|
|
"returnSetPayment"=>"<a class='butn' id='returnSetPayment'>打款信息确认撤回</a>",
|
|
|
|
|
"doPayment"=>"<a class='butn' id='doPayment'>打款确认</a>",
|
|
|
|
|
"export"=>"<a class='butn' id='export'>批量导出</a>",
|
|
|
|
|
"export_all"=>"<a class='butn' id='export_all'>导出所有</a>",
|
|
|
|
|
];
|
|
|
|
|
$resarr = [];
|
|
|
|
|
foreach ($mentBtn as $k => $v) {
|
|
|
|
|