From 1e67b1d1a1f982f6d113ea8abd828f3d41b71b9d Mon Sep 17 00:00:00 2001 From: zhengyongxing Date: Mon, 28 Sep 2020 10:57:04 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B1=87=E6=80=BBbug=E4=BF=AE=E6=AD=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- ...regateFinanceStatementController.class.php | 27 ++++++------- .../AggregateRelationController.class.php | 2 +- ...AggregateStatementLackController.class.php | 5 ++- .../Admin/Controller/ToolController.class.php | 8 ++++ Application/Admin/View/Tool/company_add.html | 30 +++++++++++++++ Application/Admin/View/Tool/company_edit.html | 38 ++++++++++++++++--- Data/update.sql | 6 ++- 7 files changed, 95 insertions(+), 21 deletions(-) diff --git a/Application/Admin/Controller/AggregateFinanceStatementController.class.php b/Application/Admin/Controller/AggregateFinanceStatementController.class.php index 88e6404ce..f9b6a2824 100644 --- a/Application/Admin/Controller/AggregateFinanceStatementController.class.php +++ b/Application/Admin/Controller/AggregateFinanceStatementController.class.php @@ -1060,9 +1060,9 @@ class AggregateFinanceStatementController extends ThinkController "company_name"=>$company_info['partner'], 'company_belong_name'=>$company_info_other['partner'], "company_info"=>json_encode($company_info,JSON_UNESCAPED_UNICODE), - "statement_money"=>$va['ratio_money'], - "pay_amount"=>$va['pay_money'], - "platform_amount"=>$va['pay_money'], + "statement_money"=>$va['statement_money'], + "pay_amount"=>$va['pay_amount'], + "platform_amount"=>$va['platform_amount'], "fine"=>$va['fine'], "reward"=>$va['reward'], "statement_begin_time"=>$v['statement_begin_time'], @@ -1075,6 +1075,7 @@ class AggregateFinanceStatementController extends ThinkController //整合数据 $lsres = $LackStatement->where("company_name='{$company_info['partner']}' and is_pool = 0")->select(); + $del_lack_ids = []; if(count($lsres) > 0){ //进行聚合 @@ -1093,15 +1094,15 @@ class AggregateFinanceStatementController extends ThinkController // dump($no_pool_money); // dump($va); // dump($k);die(); - if($va['platform_amount'] < $no_pool_money){ - //依旧小于不结算金额存旧版 - if($lackcompany['pay_amount'] != 0){ - $lask_id = $LackStatement->add($lackcompany); - $v['create_lack_ids'][] =$lask_id; - $v['lack_statement_money'] +=$lackcompany['statement_money']; - $v['lack_platform_amount'] +=$lackcompany['platform_amount']; - } - }else{ +// if($va['platform_amount'] < $no_pool_money){ +// //依旧小于不结算金额存旧版 +// if($lackcompany['pay_amount'] != 0){ +// $lask_id = $LackStatement->add($lackcompany); +// $v['create_lack_ids'][] =$lask_id; +// $v['lack_statement_money'] +=$lackcompany['statement_money']; +// $v['lack_platform_amount'] +=$lackcompany['platform_amount']; +// } +// }else{ if($va['pay_amount'] != 0){ //存成功 $company =[ @@ -1131,7 +1132,7 @@ class AggregateFinanceStatementController extends ThinkController $v['fine'] +=$va['fine']; $v['reward'] +=$va['reward']; } - } +// } } //结算单规则 protected function updatePoolVerifyStatus($ids,$old_status,$change_status,$op_pre,$num){ diff --git a/Application/Admin/Controller/AggregateRelationController.class.php b/Application/Admin/Controller/AggregateRelationController.class.php index 7a87b93d2..fdc140a1e 100644 --- a/Application/Admin/Controller/AggregateRelationController.class.php +++ b/Application/Admin/Controller/AggregateRelationController.class.php @@ -640,7 +640,7 @@ class AggregateRelationController extends AdminController $companyInfo = []; if($type == 0){ //己方公司 - $companyInfo = M("CompanyInfo","tab_")->field("id,partner company_name,partner,link_man,link_phone,address,company_tax_no,payee_name,bank_account,opening_bank,'' invoice_item,'' invoice_type")->where("status='1' AND id='{$id}'")->find(); + $companyInfo = M("CompanyInfo","tab_")->field("id,partner company_name,partner,link_man,link_phone,address,company_tax_no,payee_name,bank_account,opening_bank,invoice_item,invoice_type,register_phone,register_address")->where("status='1' AND id='{$id}'")->find(); } if($type == 1){ //上游 diff --git a/Application/Admin/Controller/AggregateStatementLackController.class.php b/Application/Admin/Controller/AggregateStatementLackController.class.php index 5cfe2abd4..2f8ac5645 100644 --- a/Application/Admin/Controller/AggregateStatementLackController.class.php +++ b/Application/Admin/Controller/AggregateStatementLackController.class.php @@ -205,6 +205,7 @@ class AggregateStatementLackController extends ThinkController } } } + $Pool = M("aggregate_statement_pool","tab_"); $Statemen = M("aggregate_statement","tab_"); foreach ($datas as $k => $v) { @@ -266,7 +267,8 @@ class AggregateStatementLackController extends ThinkController "statement_end_time"=>$v['statement_end_time'], "statement_info"=>json_encode($va['statement_info'],JSON_UNESCAPED_UNICODE), "statement_num"=>$va['statement_num'], - "verify_status"=>$verify_status + "verify_status"=>$verify_status, + "company_belong_name"=>$va['company_belong_name'] ]; $companyid = $StatementInfo->add($company); $v['info_ids'][] =$companyid; @@ -303,6 +305,7 @@ class AggregateStatementLackController extends ThinkController $tdata = [ "company_info"=>$v['company_info'], "company_name"=>$v['company_name'], + "company_belong_name"=>$v['company_belong_name'], "platform_amount"=>$v['platform_amount'], "pay_amount"=>$v['pay_amount'], "statement_money"=>$v['statement_money'], diff --git a/Application/Admin/Controller/ToolController.class.php b/Application/Admin/Controller/ToolController.class.php index b93ad68cf..ddd263015 100644 --- a/Application/Admin/Controller/ToolController.class.php +++ b/Application/Admin/Controller/ToolController.class.php @@ -810,6 +810,10 @@ class ToolController extends ThinkController { $save['opening_bank'] = I('opening_bank'); $save['fax_ratio'] = I('fax_ratio'); $save['ali_account'] = I('ali_account'); + $save['invoice_item'] = I('invoice_item'); + $save['invoice_type'] = I('invoice_type'); + $save['register_address'] = I('register_address'); + $save['register_phone'] = I('register_phone'); $save['uid'] = UID; $save['create_time'] = $time; @@ -894,6 +898,10 @@ class ToolController extends ThinkController { $save['fax_ratio'] = I('fax_ratio'); $save['ali_account'] = I('ali_account'); + $save['invoice_item'] = I('invoice_item'); + $save['invoice_type'] = I('invoice_type'); + $save['register_address'] = I('register_address'); + $save['register_phone'] = I('register_phone'); $save['status'] = $status; $save['last_up_time'] = $time; diff --git a/Application/Admin/View/Tool/company_add.html b/Application/Admin/View/Tool/company_add.html index d346367e6..11d229cf9 100644 --- a/Application/Admin/View/Tool/company_add.html +++ b/Application/Admin/View/Tool/company_add.html @@ -50,6 +50,22 @@ + + 注册地址 + + + + + + + + 注册电话 + + + + + + 邮寄地址: @@ -93,6 +109,20 @@ % + + 开票类型: + + + + + + + 开票内容: + + + + + 支付宝登陆账号: diff --git a/Application/Admin/View/Tool/company_edit.html b/Application/Admin/View/Tool/company_edit.html index 84584b29a..d50a35ce4 100644 --- a/Application/Admin/View/Tool/company_edit.html +++ b/Application/Admin/View/Tool/company_edit.html @@ -45,6 +45,22 @@ + + 注册地址 + + + + + + + + 注册电话 + + + + + + 邮寄地址 @@ -91,6 +107,20 @@ % + + 开票类型: + + + + + + + 开票内容: + + + + + 支付宝登陆账号: @@ -105,12 +135,10 @@ @@ -155,7 +183,7 @@ //导航高亮 highlight_subnav('{:U('Tool/company_info')}'); - Think.setValue('status','{$company_info_data.status|default=0}'); + // Think.setValue('status','{$company_info_data.status|default=0}'); $(function(){ diff --git a/Data/update.sql b/Data/update.sql index fae38c04d..200f13b31 100644 --- a/Data/update.sql +++ b/Data/update.sql @@ -2622,4 +2622,8 @@ CREATE TABLE `tab_aggregate_statement_pool` ( INDEX `statement_end_time`(`statement_end_time`) USING BTREE, INDEX `statement_begin_time`(`statement_begin_time`) USING BTREE, INDEX `statement_num`(`statement_num`) USING BTREE -) ENGINE = InnoDB CHARACTER SET = utf8 COLLATE = utf8_general_ci COMMENT = '对账单汇总' ROW_FORMAT = Dynamic; \ No newline at end of file +) ENGINE = InnoDB CHARACTER SET = utf8 COLLATE = utf8_general_ci COMMENT = '对账单汇总' ROW_FORMAT = Dynamic; + +ALTER TABLE `tab_company_info` +ADD COLUMN `invoice_item` varchar(255) NULL DEFAULT '' COMMENT '开票内容' AFTER `fax_ratio`, +ADD COLUMN `invoice_type` varchar(255) NULL DEFAULT '' COMMENT '开票类型' AFTER `invoice_item`; \ No newline at end of file