소스 검색

from web add refill event control

stanley-king 1 년 전
부모
커밋
58964241f2
3개의 변경된 파일39개의 추가작업 그리고 26개의 파일을 삭제
  1. 15 1
      admin/control/refill_event.php
  2. 18 18
      admin/include/menu.php
  3. 6 7
      admin/templates/default/refill_event.index.php

+ 15 - 1
admin/control/refill_event.php

@@ -11,6 +11,20 @@ class refill_eventControl extends SystemControl
 
     public function indexOp()
     {
+        $channels_reader = function ($input)
+        {
+            $ches = [];
+            $data = explode(',', $input);
+            foreach ($data as $val)
+            {
+                $val = trim($val);
+                if (!empty($val)) {
+                    $ches[] = $val;
+                }
+            }
+            return implode(',', $ches);
+        };
+
         $cacher = Cache::getInstance('cacheredis');
         $cfgs = $cacher->get('event-config', 'refill-');
 
@@ -28,7 +42,7 @@ class refill_eventControl extends SystemControl
 
         if (chksubmit())
         {
-            $channels = trim($_POST['open_crash']);
+            $channels = $channels_reader($_POST['channels']);
             $cfgs['open_crash'] = boolval($_POST['open_crash'] ?? false);
             $cfgs['cfgs_crash'] = [
                 'channels' => $channels,

+ 18 - 18
admin/include/menu.php

@@ -100,47 +100,47 @@ $arr = array(
 				'nav' => 'goods',
 				'text' => $lang['nc_goods'],
 				'list' => array(
-					array('args'=>'goods_class,goods_class,goods',			'text'=>$lang['nc_class_manage']),
-					array('args'=>'brand,brand,goods',						'text'=>$lang['nc_brand_manage']),
-					array('args'=>'goods,goods,goods',						'text'=>$lang['nc_goods_manage']),
-					array('args'=>'type,type,goods',						'text'=>$lang['nc_type_manage']),
-					array('args'=>'spec,spec,goods',						'text'=>$lang['nc_spec_manage']),
-					array('args'=>'list,goods_album,goods',					'text'=>$lang['nc_album_manage']),
+					array('args'=>'goods_class,goods_class,goods',	'text'=>$lang['nc_class_manage']),
+					array('args'=>'brand,brand,goods',				'text'=>$lang['nc_brand_manage']),
+					array('args'=>'goods,goods,goods',				'text'=>$lang['nc_goods_manage']),
+					array('args'=>'type,type,goods',				'text'=>$lang['nc_type_manage']),
+					array('args'=>'spec,spec,goods',				'text'=>$lang['nc_spec_manage']),
+					array('args'=>'list,goods_album,goods',			'text'=>$lang['nc_album_manage']),
 				)
 			],
 			[
 				'nav' => 'refill',
 				'text' => '充值业务',
 				'list' => array(
-					array('args'=>'merchant,merchant,refill',				'text'=>'机构管理'),
-					array('args'=>'index,refill_evidence,refill',			'text'=>'充值申请'),
+					array('args'=>'merchant,merchant,refill',			'text'=>'机构管理'),
+					array('args'=>'index,refill_evidence,refill',		'text'=>'充值申请'),
 					array('args'=>'index,refill_order,refill',			'text'=>'订单列表'),
 					array('args'=>'index,provider,refill',				'text'=>'通道列表'),
 					array('args'=>'index,provider_ctl,refill',			'text'=>'通道控制'),
 					array('args'=>'index,refill_merchant_channel_cfg,refill', 'text'=>'机构通道配置'),
 					array('args'=>'index,provider_province_cfg,refill',	'text'=>'通道省份配置'),
-					array('args'=>'index,provider_group,refill',			'text'=>'通道组管理'),
+					array('args'=>'index,provider_group,refill',		'text'=>'通道组管理'),
 					array('args'=>'index,ordersendlist,refill',			'text'=>'订单监控'),
-					array('args'=>'index,orderstats,refill',				'text'=>'对账管理'),
-					array('args'=>'index,refill_event,refill',				'text'=>'订单事件管理'),
-					array('args'=>'index,refill_tax_stats,refill',	    'text'=>'带票对账统计'),
-					array('args'=>'index,refill_company,refill',			'text'=>'公司信息管理'),
+					array('args'=>'index,orderstats,refill',			'text'=>'对账管理'),
+					array('args'=>'index,refill_event,refill',			'text'=>'订单事件控制'),
+					array('args'=>'index,refill_company,refill',		'text'=>'公司信息管理'),
 					array('args'=>'intercept,refill_config,refill',		'text'=>'充值拦截设置'),
 					array('args'=>'stats,card_key,refill',				'text'=>'卡密管理'),
 					array('args'=>'index,refill_third,refill',			'text'=>'增值业务管理'),
 					array('args'=>'index,refill_stock,refill',			'text'=>'库存管理'),
-					array('args'=>'index,refill_analysis,refill',			'text'=>'成功率监控'),
-					array('args'=>'index,refill_order_manual,refill',		'text'=>'订单手动处理'),
+					array('args'=>'index,refill_analysis,refill',		'text'=>'成功率监控'),
+					array('args'=>'index,refill_order_manual,refill',	'text'=>'订单手动处理'),
 					array('args'=>'index,provider_info,refill',			'text'=>'上游信息管理'),
 					array('args'=>'index,merchant_info,refill',			'text'=>'机构信息管理'),
-					array('args'=>'index,refill_cron,refill',				'text'=>'订单排队查询'),
+					array('args'=>'index,refill_cron,refill',			'text'=>'订单排队查询'),
 					array('args'=>'index,refill_refund,refill',			'text'=>'退款信息管理'),
 					array('args'=>'index,order_search,refill',			'text'=>'客服订单查询'),
 					array('args'=>'index,refill_detail,refill',			'text'=>'接单查询'),
-					array('args'=>'index,provider_price,refill',			'text'=>'通道价格明细'),
+					array('args'=>'index,provider_price,refill',		'text'=>'通道价格明细'),
 					array('args'=>'index,task,refill',					'text'=>'任务列表'),
 					array('args'=>'index,refill_error,refill',			'text'=>'异常订单列表'),
-					array('args'=>'index,arw_monitor,refill',				'text'=>'服务器磁盘监控'),
+					array('args'=>'index,arw_monitor,refill',			'text'=>'服务器磁盘监控'),
+					array('args'=>'index,refill_tax_stats,refill',	    'text'=>'带票对账统计')
 				)
 			],
 			[

+ 6 - 7
admin/templates/default/refill_event.index.php

@@ -3,9 +3,9 @@
 <div class="page">
   <div class="fixed-bar">
     <div class="item-title">
-      <h3>充值事件管理</h3>
+      <h3>订单事件控制</h3>
       <ul class="tab-base">
-        <li><a href="JavaScript:void(0);" class="current"><span>防撞单控制</span></a></li>
+        <li><a href="JavaScript:void(0);" class="current"><span>防撞(卡号)单控制</span></a></li>
       </ul>
     </div>
   </div>
@@ -16,23 +16,22 @@
     <input type="hidden" name="form_submit" value="ok" />
     <div style="padding: 20px 0;border-bottom: 1px dotted #CBE9F3;">
       <label style="display:flex;align-items: center;">
-        <input type="checkbox" name="open_crash" style="margin-right: 8px;" value="true" <?php echo $output['open_crash'] ? 'checked' : '';?> >
+        <input type="checkbox" name="open_crash" style="margin-right: 8px;" value="true" <?php echo $output['cfgs']['open_crash'] ? 'checked' : '';?> >
         <span style="padding-right: 8px;">防撞单控制开关</span>
       </label>
     </div>
     <div style="display:flex;align-items: center;height: 80px;">
       <span style="margin-right: 8px;">撞单通道:</span>
-      <textarea rows="3" type="text" name="channels" placeholder="以逗号隔开" style="width: 300px;" id="channels"><?php echo $output['cfgs_crash']['channels'];?> </textarea>
+      <input type="text" name="channels" style="width: 600px;" value="<?php echo $output['cfgs']['cfgs_crash']['channels'];?>" id="channels"> 请以英文字符逗号隔开.</input>
     </div>
     <div style="margin-top: 10px;">
       <label>
-        <span style="padding-right: 8px;">最低进入时长: </span>
-        <input type="number" class="txt2" name="succ_interval" value="900" id="succ_interval"><?php echo $output['cfgs_crash']['succ_interval'];?></input>
+        <span style="padding-right: 8px;">订单睡眠: </span>
+        <input type="number" class="txt2" name="succ_interval" value="<?php echo $output['cfgs']['cfgs_crash']['succ_interval'];?>" id="succ_interval"> 秒</input>
       </label>
     </div>
     <a href="JavaScript:void(0);" class="btn" style="margin-top: 15px" id="submitBtn"><span>提交</span></a>
   </form>
-
 </div>
 
 <script>