diff --git a/app/setting/controller/MobileMnp.php b/app/setting/controller/MobileMnp.php new file mode 100644 index 0000000..ee65735 --- /dev/null +++ b/app/setting/controller/MobileMnp.php @@ -0,0 +1,112 @@ +title = '卡号黑名单'; + $query = $this->_query($this->table); + $query->equal('status,id,is_mnp,mobile,old_isp,new_isp')->dateBetween('create_at'); + // 加载对应数据列表 + $this->type = input('is_mnp', 'all'); + // 列表排序并显示 +// $query->order('status desc,id desc')->page(); + $query->order('status desc,id desc')->layTable(function(QueryHelper $query){ + // 前置操作,处理 HTML 模型 + },function(QueryHelper $query){ +// $vo['isp_name'] = $this->isp[$vo['isp']]; + // 后置操作,处理表格数据 + }); + } + + /** + * 添加携转号码 + * @auth true + * @throws \think\db\exception\DataNotFoundException + * @throws \think\db\exception\DbException + * @throws \think\db\exception\ModelNotFoundException + */ + public function add() + { + $this->_applyFormToken(); + $this->_form($this->table, 'form'); + } + + /** + * 编辑携转号码检测 + * @auth true + * @throws \think\db\exception\DataNotFoundException + * @throws \think\db\exception\DbException + * @throws \think\db\exception\ModelNotFoundException + */ + public function edit() + { + $this->_applyFormToken(); + $this->_form($this->table, 'form'); + } + + /** + * 修改携转号码检测 + * @auth true + * @throws \think\db\exception\DbException + */ + public function state() + { + $this->_applyFormToken(); + $this->_save($this->table, $this->_vali([ + 'status.in:0,1' => '状态值范围异常!', + 'status.require' => '状态值不能为空!', + ])); + } + + /** + * 删除携转号码检测 + * @auth true + * @throws \think\db\exception\DbException + */ + public function remove() + { +// $this->_applyFormToken(); + $this->_delete($this->table); + } + + +} diff --git a/app/setting/service/AccountLogService.php b/app/setting/service/AccountLogService.php index 30f8be3..e4357e5 100644 --- a/app/setting/service/AccountLogService.php +++ b/app/setting/service/AccountLogService.php @@ -10,6 +10,7 @@ use app\channel\service\ChannelService; use app\merchant\service\MerchantService; use app\merchant\service\MerchantLogService; use app\merchant\service\OrderLastHistoryService; +use app\merchant\service\OrderLastweekHistoryService; use app\merchant\service\OrderService; use app\merchant\service\OrderHistoryService; @@ -83,6 +84,7 @@ use app\setting\service\MerchantAccountService; $day = date('Y-m-d', strtotime('-1 day')); } + $this->merchantLogService = MerchantLogService::instance(); $accountService = AccountService::instance(); $merchantAccountService = MerchantAccountService::instance(); @@ -103,7 +105,7 @@ use app\setting\service\MerchantAccountService; $this->history = true; // $this->orderService = OrderHistoryService::instance(); - $this->orderService = OrderLastHistoryService::instance(); + $this->orderService = OrderLastweekHistoryService::instance(); $begin = $day . ' 00:00:00'; $after = $day . ' 23:59:59'; diff --git a/app/setting/service/ChannelAccountService.php b/app/setting/service/ChannelAccountService.php index db630d2..25c12ae 100644 --- a/app/setting/service/ChannelAccountService.php +++ b/app/setting/service/ChannelAccountService.php @@ -8,6 +8,7 @@ use app\channel\service\AccountService; use app\merchant\service\MerchantService; use app\merchant\service\MerchantLogService; use app\merchant\service\OrderLastHistoryService; +use app\merchant\service\OrderLastweekHistoryService; use app\merchant\service\OrderService; use app\merchant\service\OrderHistoryService; use dever\Log; @@ -77,7 +78,7 @@ class ChannelAccountService extends Service if ($product) { $order_data = $account_data = array(); // $orderHistoryService = OrderHistoryService::instance(); - $orderHistoryService = OrderLastHistoryService::instance(); + $orderHistoryService = OrderLastweekHistoryService::instance(); $merchantLogService = MerchantLogService::instance(); $accountService = AccountService::instance(); diff --git a/app/setting/view/mobile_mnp/form.html b/app/setting/view/mobile_mnp/form.html new file mode 100644 index 0000000..333c75c --- /dev/null +++ b/app/setting/view/mobile_mnp/form.html @@ -0,0 +1,136 @@ +
+
+ +
+
+ +
+
+ +
+ +
+ +
+ +
+
+ +
+
+ +
+
+ +
+
+ +
+
+ + +
+ + +
+ {notempty name='vo.id'}{/notempty} +
+ + +
+
+ + + + \ No newline at end of file diff --git a/app/setting/view/mobile_mnp/index.html b/app/setting/view/mobile_mnp/index.html new file mode 100644 index 0000000..dc4eb51 --- /dev/null +++ b/app/setting/view/mobile_mnp/index.html @@ -0,0 +1,111 @@ +{extend name="../../admin/view/table"} +{block name="button"} + + + +{/block} + +{block name="content"} + + + + +
+ + {include file='mobile_mnp/index_search'} +
+
+
+
+ + + + + + +{/block} + +{block name='script'} + + + +{/block} diff --git a/app/setting/view/mobile_mnp/index_search.html b/app/setting/view/mobile_mnp/index_search.html new file mode 100644 index 0000000..1843a3a --- /dev/null +++ b/app/setting/view/mobile_mnp/index_search.html @@ -0,0 +1,88 @@ +
+ {:lang('条件搜索')} + +
\ No newline at end of file diff --git a/app/task/controller/OrderTask.php b/app/task/controller/OrderTask.php index 40c1970..279d780 100644 --- a/app/task/controller/OrderTask.php +++ b/app/task/controller/OrderTask.php @@ -155,6 +155,9 @@ class OrderTask extends Core exit('ok'); } + # 商户对账 + + # 直接对数据库中的订单数据进行处理 如果队列失效,就使用这个方法进行操作,谨慎使用该方法,会和队列同时执行,已取消 /* public function runAll() diff --git a/app/task/controller/Task.php b/app/task/controller/Task.php index 81017cd..d97fadf 100644 --- a/app/task/controller/Task.php +++ b/app/task/controller/Task.php @@ -9,6 +9,7 @@ use app\gateway\service\RedisService; use app\merchant\service\MerchantLogHistoryService; use app\merchant\service\OrderHistoryService; use app\merchant\service\OrderLastHistoryService; +use app\merchant\service\OrderLastweekHistoryService; use app\merchant\service\OrderService; use app\merchant\service\RebateService; use app\setting\service\ChannelAccountService; @@ -335,8 +336,8 @@ class Task extends Core if (!$day) { $day = date('Y-m-d', strtotime('-1 day')); } -// $orderHistoryService = OrderHistoryService::instance(); - $orderHistoryService = OrderLastHistoryService::instance(); +// $orderHistoryService = OrderLastHistoryService::instance(); + $orderHistoryService = OrderLastweekHistoryService::instance(); $data = $orderHistoryService->getTotalData($day); // var_dump($data); if ($data) {