From 5afd0ffd631408a985db7d5ebfe96de2c02fab84 Mon Sep 17 00:00:00 2001 From: chenxiaojun <956334972@qq.com> Date: Fri, 8 Nov 2019 14:45:57 +0800 Subject: [PATCH 1/7] =?UTF-8?q?=E7=AE=A1=E7=90=86=E5=90=8E=E5=8F=B0->?= =?UTF-8?q?=E6=8E=A8=E5=B9=BF=E5=91=98->=E7=BB=93=E7=AE=97=E7=AE=A1?= =?UTF-8?q?=E7=90=86->=E6=8E=A8=E5=B9=BF=E6=8F=90=E7=8E=B0->=E4=B8=8A?= =?UTF-8?q?=E4=BC=A0=E6=B1=87=E6=AC=BE=E8=AF=81=E6=98=8E--=E6=9B=B4?= =?UTF-8?q?=E6=96=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Admin/Controller/QueryController.class.php | 17 ++++++++++++++++- Data/update.sql | 5 ++++- 2 files changed, 20 insertions(+), 2 deletions(-) diff --git a/Application/Admin/Controller/QueryController.class.php b/Application/Admin/Controller/QueryController.class.php index 63e4428a5..bf3e8232c 100644 --- a/Application/Admin/Controller/QueryController.class.php +++ b/Application/Admin/Controller/QueryController.class.php @@ -801,11 +801,26 @@ class QueryController extends ThinkController $data['msg'] = '请上传汇款证明'; return $data; } + $downloadId = M('document_download')->where(array('file_id' => $transferProof))->getField('id'); + if (empty($downloadId)) { + $fileData = M('File')->field('size,ext')->find($transferProof); + $downloadSave['content'] = '推广员提现订单汇款证明'; + $downloadSave['file_id'] = $transferProof; + $downloadSave['size'] = $fileData['size']; + $downloadSave['parse'] = $fileData['ext']; + $downloadRes = M('document_download')->add($downloadSave); + if (!$downloadRes) { + $data['status'] = 0; + $data['msg'] = '保存失败'; + return $data; + } + $downloadId = $downloadRes; + } $map['id'] = $ids; $map['status'] = 1; $save['audit_time'] = time(); $save['status'] = $status; - $save['transfer_proof'] = $transferProof; + $save['transfer_proof'] = $downloadId; $res = $withdraw->where($map)->save($save); if ($res === false) { $data['status'] = 0; diff --git a/Data/update.sql b/Data/update.sql index b22117111..536f2c757 100644 --- a/Data/update.sql +++ b/Data/update.sql @@ -365,4 +365,7 @@ ALTER TABLE `sys_shift_task` ADD COLUMN `remark` varchar(255) NOT NULL DEFAULT ' -- 2019-11-07 cxj -ALTER TABLE `platform_query`.`tab_withdraw` ADD COLUMN `transfer_proof` int(11) NOT NULL DEFAULT 0 COMMENT '汇款证明' AFTER `settlement_end_time`; \ No newline at end of file +ALTER TABLE `platform_query`.`tab_withdraw` ADD COLUMN `transfer_proof` int(11) NOT NULL DEFAULT 0 COMMENT '汇款证明' AFTER `settlement_end_time`; + +-- 2019-11-08 cxj +ALTER TABLE `platform`.`sys_document_download` MODIFY COLUMN `id` int(10) NOT NULL AUTO_INCREMENT COMMENT '文档ID' FIRST; \ No newline at end of file From 4ecb391d74b5b31b67bd330b20cf388c99741faa Mon Sep 17 00:00:00 2001 From: chenxiaojun <956334972@qq.com> Date: Fri, 8 Nov 2019 14:47:03 +0800 Subject: [PATCH 2/7] =?UTF-8?q?=E7=AE=A1=E7=90=86=E5=90=8E=E5=8F=B0->?= =?UTF-8?q?=E6=8E=A8=E5=B9=BF=E5=91=98->=E7=BB=93=E7=AE=97=E7=AE=A1?= =?UTF-8?q?=E7=90=86->=E6=8E=A8=E5=B9=BF=E6=8F=90=E7=8E=B0->=E4=B8=8A?= =?UTF-8?q?=E4=BC=A0=E6=B1=87=E6=AC=BE=E8=AF=81=E6=98=8E--=E6=9B=B4?= =?UTF-8?q?=E6=96=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Data/update.sql | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Data/update.sql b/Data/update.sql index 536f2c757..15b22eb0d 100644 --- a/Data/update.sql +++ b/Data/update.sql @@ -365,7 +365,7 @@ ALTER TABLE `sys_shift_task` ADD COLUMN `remark` varchar(255) NOT NULL DEFAULT ' -- 2019-11-07 cxj -ALTER TABLE `platform_query`.`tab_withdraw` ADD COLUMN `transfer_proof` int(11) NOT NULL DEFAULT 0 COMMENT '汇款证明' AFTER `settlement_end_time`; +ALTER TABLE `tab_withdraw` ADD COLUMN `transfer_proof` int(11) NOT NULL DEFAULT 0 COMMENT '汇款证明' AFTER `settlement_end_time`; -- 2019-11-08 cxj -ALTER TABLE `platform`.`sys_document_download` MODIFY COLUMN `id` int(10) NOT NULL AUTO_INCREMENT COMMENT '文档ID' FIRST; \ No newline at end of file +ALTER TABLE `sys_document_download` MODIFY COLUMN `id` int(10) NOT NULL AUTO_INCREMENT COMMENT '文档ID' FIRST; \ No newline at end of file From c8281d2bb2b5605874b9c6a788a2804522fed89b Mon Sep 17 00:00:00 2001 From: chenxiaojun <956334972@qq.com> Date: Fri, 8 Nov 2019 15:09:26 +0800 Subject: [PATCH 3/7] =?UTF-8?q?=E7=AE=A1=E7=90=86=E5=90=8E=E5=8F=B0->?= =?UTF-8?q?=E6=8E=A8=E5=B9=BF=E5=91=98->=E7=BB=93=E7=AE=97=E7=AE=A1?= =?UTF-8?q?=E7=90=86->=E6=8E=A8=E5=B9=BF=E6=8F=90=E7=8E=B0->=E4=B8=8A?= =?UTF-8?q?=E4=BC=A0=E6=B1=87=E6=AC=BE=E8=AF=81=E6=98=8E--=E6=9B=B4?= =?UTF-8?q?=E6=96=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Application/Admin/Controller/QueryController.class.php | 1 - 1 file changed, 1 deletion(-) diff --git a/Application/Admin/Controller/QueryController.class.php b/Application/Admin/Controller/QueryController.class.php index bf3e8232c..83d911277 100644 --- a/Application/Admin/Controller/QueryController.class.php +++ b/Application/Admin/Controller/QueryController.class.php @@ -807,7 +807,6 @@ class QueryController extends ThinkController $downloadSave['content'] = '推广员提现订单汇款证明'; $downloadSave['file_id'] = $transferProof; $downloadSave['size'] = $fileData['size']; - $downloadSave['parse'] = $fileData['ext']; $downloadRes = M('document_download')->add($downloadSave); if (!$downloadRes) { $data['status'] = 0; From 4fff44e0f8fca770dbbb1eeaa3314f6fccca95b8 Mon Sep 17 00:00:00 2001 From: sunke <18850253506@163.com> Date: Fri, 8 Nov 2019 15:12:31 +0800 Subject: [PATCH 4/7] =?UTF-8?q?=E6=B1=87=E6=AC=BE=E8=AF=81=E6=98=8E?= =?UTF-8?q?=E4=B8=8B=E8=BD=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Controller/DownloadController.class.php | 44 +++++++++++++++++++ .../View/default/Finance/withdrawRecord.html | 2 +- 2 files changed, 45 insertions(+), 1 deletion(-) diff --git a/Application/Home/Controller/DownloadController.class.php b/Application/Home/Controller/DownloadController.class.php index 6987c0714..eccd40bbe 100644 --- a/Application/Home/Controller/DownloadController.class.php +++ b/Application/Home/Controller/DownloadController.class.php @@ -1712,6 +1712,10 @@ class DownloadController extends BaseController { break; case "提现明细": $this->withdrawDtlExcelInfo($id,$map); + break; + case "汇款证明": + $this->remitCerDownLoad($id,$map); + break; default: break; } @@ -2201,6 +2205,13 @@ class DownloadController extends BaseController { } + public function remitCerDownLoad($id,$map) { + $proof_id = $map['id']; + $file = new FileController(); + $file->download($proof_id); + $this->backSuccessExport($id); + } + public function withdrawDtlExcelInfo($id,$map) { $xlsName = "提现记录"; $xlsCell = array( @@ -2625,6 +2636,39 @@ class DownloadController extends BaseController { } } + /* + * 汇款证明 + * */ + public function Remittancecer() { + $id = $_REQUEST["id"]; + $model = M("withdraw","tab_"); + $res = $model->where(['id'=>$id])->field('transfer_proof,status')->find(); + $transfer_proof = intval($res["transfer_proof"]); + $map = ['id'=>$transfer_proof]; + $addtime = time(); + $conditions = json_encode($map,TRUE); + $data = [ + 'logid' => 'remitrecord_'.time(), + 'admin_id' => PID, + 'type' => '/Home/Finance/withdrawRecord', + 'dataname' => '汇款证明', + 'status' => 0, + 'addtime' => $addtime, + 'begintime' => 0, + 'content' => '', + 'conditions' =>$conditions, + ]; + $log = M('downloadlog','tab_')->add($data); + if (!$log) { + $this->error('添加下载失败'); + } + $this->success('添加下载成功',U('listsIndex')); + + + } + + + public function encryptDecrypt($key, $string, $decrypt){ diff --git a/Application/Home/View/default/Finance/withdrawRecord.html b/Application/Home/View/default/Finance/withdrawRecord.html index 120f3428e..dd4c7872f 100644 --- a/Application/Home/View/default/Finance/withdrawRecord.html +++ b/Application/Home/View/default/Finance/withdrawRecord.html @@ -172,7 +172,7 @@ 提现明细 - 汇款证明 + 汇款证明 结算单 From 52dafe9ed36f2e26f34bd92cfffeb0b72c9a3664 Mon Sep 17 00:00:00 2001 From: sunke <18850253506@163.com> Date: Fri, 8 Nov 2019 15:15:12 +0800 Subject: [PATCH 5/7] remit --- Application/Home/View/default/Finance/withdrawRecord.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Application/Home/View/default/Finance/withdrawRecord.html b/Application/Home/View/default/Finance/withdrawRecord.html index dd4c7872f..f7fc8acd7 100644 --- a/Application/Home/View/default/Finance/withdrawRecord.html +++ b/Application/Home/View/default/Finance/withdrawRecord.html @@ -172,7 +172,7 @@ 提现明细 - 汇款证明 + 汇款证明 结算单 From d2b1a474fb391e89a84f08f9d4ad54dcad8ae708 Mon Sep 17 00:00:00 2001 From: sunke <18850253506@163.com> Date: Fri, 8 Nov 2019 15:18:05 +0800 Subject: [PATCH 6/7] ajax-get --- Application/Home/View/default/Finance/withdrawRecord.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Application/Home/View/default/Finance/withdrawRecord.html b/Application/Home/View/default/Finance/withdrawRecord.html index f7fc8acd7..4f7eeebe0 100644 --- a/Application/Home/View/default/Finance/withdrawRecord.html +++ b/Application/Home/View/default/Finance/withdrawRecord.html @@ -172,7 +172,7 @@ 提现明细 - 汇款证明 + 汇款证明 结算单 From b94f7b50c2d192ead7b374fba75d25346c30c26e Mon Sep 17 00:00:00 2001 From: sunke <18850253506@163.com> Date: Fri, 8 Nov 2019 15:35:00 +0800 Subject: [PATCH 7/7] ajax-get --- Application/Home/View/default/Finance/withdrawRecord.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Application/Home/View/default/Finance/withdrawRecord.html b/Application/Home/View/default/Finance/withdrawRecord.html index 4f7eeebe0..819bfe48a 100644 --- a/Application/Home/View/default/Finance/withdrawRecord.html +++ b/Application/Home/View/default/Finance/withdrawRecord.html @@ -172,7 +172,7 @@ 提现明细 - 汇款证明 + 汇款证明 结算单