Commit bbd54c3a authored by hujun's avatar hujun

name

parent 82e5bd7f
......@@ -41,7 +41,7 @@ class Cost extends Basic
$field = 'a.id,a.count_time,a.source,a.type,a.create_time,a.agent_id,a.total_fee,a.fee_item,a.purpose,a.status,';
$field .= 'b.name as agent_name,a.site_id';
$fee_model = new FApplyForFee();
$cost_service = new CostService();
if (empty($this->params['excel'])) {
if (in_array($this->params['check_status'], [1,2,3,4])) {
$order = 'a.update_time DESC';
......@@ -49,13 +49,16 @@ class Cost extends Basic
$order = 'a.ID DESC';
}
$list = $fee_model->getJoinAgentList($pageNo, $pageSize, $order, $field, $where);
$data['list'] = &$list;
foreach($list as $k=>$v) {
$list[$k]['type_name'] = $cost_service->getFeeType($v['type']);
$list[$k]['fee_item_name'] = $cost_service->getFeeItem($v['fee_item']);
}
$data['list'] = $list;
$data['total'] = $fee_model->getJoinAgentListTotal($where);
return $this->response(200, '', $data);
} else {
$field .= ',a.card_name,a.card_no,a.store_id,a.office_id';
$list = $fee_model->getJoinAgentList(1, 100000, 'a.ID DESC', $field, $where);
$cost_service = new CostService();
$redis = new RedisCacheService();
$source = [
0=> 'app申请',
......@@ -132,7 +135,7 @@ class Cost extends Basic
if (isset($excel_data)) {
$export = new ExportExcelUntil();
$title = [ '费用总ID', '计入月份', '提交时间', '提交人', '费用总金额', '费用类型', '费用项目', '费用用途',
'来源','状态','收款户名','收款卡账号','费用承担门店','费用承担办公室' ];
'来源','状态','收款户名','收款卡账号','费用承担门店','费用承担办公室' ];
$export->exportTable('费用报销审核', $excel_data, 13, '费用报销审核', $title);
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment