From 8b33a52cd000fa69985ad6eb03a7d5c289227841 Mon Sep 17 00:00:00 2001 From: zhengchanglong Date: Thu, 6 Feb 2020 16:08:47 +0800 Subject: [PATCH 1/4] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E5=A5=96=E7=BD=9A?= =?UTF-8?q?=E8=AE=B0=E5=BD=95=E5=AD=97=E6=AE=B5=E9=A1=BA=E5=BA=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Data/update.sql | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Data/update.sql b/Data/update.sql index ef1c96aeb..9cc0cdb92 100644 --- a/Data/update.sql +++ b/Data/update.sql @@ -1124,10 +1124,10 @@ CREATE TABLE `tab_reward_record` ( `relation_game_id` int(11) unsigned NOT NULL DEFAULT '0' COMMENT '游戏id', `content` varchar(1000) COLLATE utf8mb4_bin NOT NULL DEFAULT '' COMMENT '事件内容', `money` double(11,2) unsigned NOT NULL DEFAULT '0.00' COMMENT '金额', + `reward_time` int(11) unsigned NOT NULL DEFAULT '0' COMMENT '奖惩时间', `remark` varchar(255) COLLATE utf8mb4_bin NOT NULL DEFAULT '' COMMENT '备注', `create_time` int(11) unsigned NOT NULL DEFAULT '0' COMMENT '创建时间', `creater_id` int(11) unsigned NOT NULL DEFAULT '0' COMMENT '创建者ID', - `reward_time` int(11) unsigned NOT NULL DEFAULT '0' COMMENT '奖惩时间', PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=4 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_bin; From 51d2d916711ecf0dff368e1a1f10af86811cfc48 Mon Sep 17 00:00:00 2001 From: liuweiwen <529520975@qq.com> Date: Thu, 6 Feb 2020 16:45:02 +0800 Subject: [PATCH 2/4] =?UTF-8?q?=E9=AA=8C=E8=AF=81=E6=89=8B=E6=9C=BA?= =?UTF-8?q?=E5=8F=B7=E7=A0=81=E6=A0=BC=E5=BC=8F=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Application/Admin/Common/function.php | 8 ++++++++ Application/Admin/Controller/ToolController.class.php | 4 ++-- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/Application/Admin/Common/function.php b/Application/Admin/Common/function.php index 7916130e1..cca1ec6e1 100644 --- a/Application/Admin/Common/function.php +++ b/Application/Admin/Common/function.php @@ -854,3 +854,11 @@ function convertAmountToCn($num) { return $daxie . '整'; } + +/** + * @param $phone + * @return false|int + */ +function checkPhone($phone) { + return preg_match("/^1[3456789]\d{9}$/",$phone); +} diff --git a/Application/Admin/Controller/ToolController.class.php b/Application/Admin/Controller/ToolController.class.php index d5aee52fc..056c6c1ec 100644 --- a/Application/Admin/Controller/ToolController.class.php +++ b/Application/Admin/Controller/ToolController.class.php @@ -726,7 +726,7 @@ class ToolController extends ThinkController { $this->error('公司名称已存在'); } - if(!preg_match("/^1[358][0-9]{9}$/u",I('link_phone'))) { + if(!checkPhone(I('link_phone'))) { $this->error('联系电话格式不正确'); } $res2 = $model->where(['link_phone' => I('link_phone')])->getField('id'); @@ -798,7 +798,7 @@ class ToolController extends ThinkController { $this->error('公司名称已存在'); } - if(!preg_match("/^1[358][0-9]{9}$/u",I('link_phone'))) { + if(!checkPhone(I('link_phone'))) { $this->error('联系电话格式不正确'); } $res2 = $model->where([ From a7891d6b575416f710c459eecf5858093195fc88 Mon Sep 17 00:00:00 2001 From: chenxiaojun <956334972@qq.com> Date: Thu, 6 Feb 2020 17:57:53 +0800 Subject: [PATCH 3/4] =?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--=E9=83=A8?= =?UTF-8?q?=E5=88=86=E5=8A=9F=E8=83=BD=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Admin/Controller/QueryController.class.php | 16 +++++++++++----- Application/Admin/View/Query/settlement.html | 4 +--- Application/Admin/View/Query/withdraw.html | 3 ++- 3 files changed, 14 insertions(+), 9 deletions(-) diff --git a/Application/Admin/Controller/QueryController.class.php b/Application/Admin/Controller/QueryController.class.php index a28fb5f2e..544d7eb71 100644 --- a/Application/Admin/Controller/QueryController.class.php +++ b/Application/Admin/Controller/QueryController.class.php @@ -1194,11 +1194,10 @@ class QueryController extends ThinkController $this->ajaxReturn(['msg' => $msg]); } - public function set_withdraw_status() + public function set_withdraw_status($status = 1) { $withdraw = M('withdraw', "tab_"); $ids = I('ids', 0); - $status = 1; if (empty($ids)) { $this->error('参数异常'); } @@ -1207,14 +1206,21 @@ class QueryController extends ThinkController } else { $map['id'] = $ids; } - $map['status'] = 0; + switch ($status) { + case 1: + $map['status'] = 0; + break; + case 2: + $map['status'] = 1; + break; + } $save['audit_time'] = time(); $save['status'] = $status; $res = $withdraw->where($map)->save($save); if ($res === false) { - $this->error('审核失败'); + $this->error('操作失败'); } else { - $this->success('审核成功', U('withdraw')); + $this->success('操作成功', U('withdraw')); } } diff --git a/Application/Admin/View/Query/settlement.html b/Application/Admin/View/Query/settlement.html index 4f1e6ad94..74123ec83 100644 --- a/Application/Admin/View/Query/settlement.html +++ b/Application/Admin/View/Query/settlement.html @@ -219,9 +219,7 @@ {$record.status_text} {$record.respond} - - 汇款证明 - + 重新审核 diff --git a/Application/Admin/View/Query/withdraw.html b/Application/Admin/View/Query/withdraw.html index afb677218..2946f9515 100644 --- a/Application/Admin/View/Query/withdraw.html +++ b/Application/Admin/View/Query/withdraw.html @@ -59,6 +59,7 @@ 通 过 驳 回 自动审核管理 + 确认汇款 @@ -187,7 +188,7 @@ 通过 驳回 - 上传汇款证明 + 确认汇款 From 9e9a925429474662c5e17ad2f6189e215f8d1fb8 Mon Sep 17 00:00:00 2001 From: liuweiwen <529520975@qq.com> Date: Thu, 6 Feb 2020 18:47:10 +0800 Subject: [PATCH 4/4] =?UTF-8?q?=E5=A5=96=E7=BD=9A=E8=AE=B0=E5=BD=95?= =?UTF-8?q?=E7=AE=A1=E7=90=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../StatementMangementController.class.php | 12 +++ .../StatementMangement/rewardManageList.html | 91 +++++++++++++++++++ 2 files changed, 103 insertions(+) diff --git a/Application/Admin/Controller/StatementMangementController.class.php b/Application/Admin/Controller/StatementMangementController.class.php index 86f9e9afb..fd663c8da 100644 --- a/Application/Admin/Controller/StatementMangementController.class.php +++ b/Application/Admin/Controller/StatementMangementController.class.php @@ -233,6 +233,18 @@ class StatementMangementController extends ThinkController public function rewardManageList($row = 10, $p = 1) { $map = []; + if (!empty(I("game_name"))) { + $game_ids = array_column(getGameByName(I("game_name")), 'id'); + if ($game_ids) { + $map['relation_game_id'] = ['in', $game_ids]; + } + } + if (!empty(I('partner_id'))) { + $map['company_id'] = I('partner_id'); + } + if (!empty(I('account'))) { + $map['accounts'] = ['like', '%' . I('account') . '%']; + } $list = M('reward_record', 'tab_')->where($map)->page($p, $row)->select(); if ($list) { $companys[1] = array_column(M('partner', 'tab_')->field('id, partner as name')->select(), 'name', 'id'); diff --git a/Application/Admin/View/StatementMangement/rewardManageList.html b/Application/Admin/View/StatementMangement/rewardManageList.html index 5eff7bb53..6b79eaee0 100644 --- a/Application/Admin/View/StatementMangement/rewardManageList.html +++ b/Application/Admin/View/StatementMangement/rewardManageList.html @@ -52,12 +52,54 @@

上下游奖罚记录管理

+ + +
+ + +
+ +
+ +
+
+ +
+ +
+ +   +
+ + +
+ 搜索 + +
+ + + +
+
+
@@ -150,5 +192,54 @@ $(".select_gallery").select2(); highlight_subnav("{:U('StatementMangement/rewardManageList')}"); + + function get_game_list() + { + var game_name = $('#game_name').val(); + var partner_id = $("#partner_id option:selected").val(); + var sdk_type = $("#sdk_version1 option:selected").val(); + $.ajax({ + url:"{:U('Finance/getGameList')}", + type:"post", + data:{ + partner_id:partner_id, + sdk_type:sdk_type + }, + dataType:'json', + success:function(data){ + var str = ""; + for (var i in data){ + str += "" + } + // console.log(str); + $("#game_name").empty(); + $("#game_name").append(str); + $("#game_name").select2(); + + } + }) + } + $(function(){ + $("#partner_id").change(function(){ + get_game_list(); + }); + //搜索功能 + $("#search").click(function(){ + var url = $(this).attr('url'); + var query = $('.jssearch').find('input').serialize(); + console.log(url); + query += "&" + $('.jssearch').find('select').serialize(); + console.log(query); + query = query.replace(/(&|^)(\w*?\d*?\-*?_*?)*?=?((?=&)|(?=$))/g,''); + query = query.replace(/^&/g,''); + if( url.indexOf('?')>0 ){ + url += '&' + query; + }else{ + url += '?' + query; + } + window.location.replace(url); + }); + }); +