Ver código fonte

refill order cron search

xiaoyu 3 anos atrás
pai
commit
c97608946d

+ 21 - 1
admin/control/refill_cron.php

@@ -1,7 +1,27 @@
 <?php
 
 
-class refill_cron
+class refill_cronControl extends SystemControl
 {
+    public function __construct()
+    {
+        parent::__construct();
+    }
 
+    public function indexOp()
+    {
+        $cron = [];
+        if(!empty($_GET['search'])) {
+            $search = $_GET['search'];
+            $mod = Model('cron');
+            $condition['params'] = ['like', '%'.$search.'%'];
+            $cron = $mod->getCronList($condition);
+            foreach ($cron as $key => $value) {
+                $cron[$key]['params'] = unserialize($value['params']);
+            }
+        }
+
+        Tpl::output('cron', $cron);
+        Tpl::showpage('refill.cron');
+    }
 }

+ 1 - 0
admin/include/limit.php

@@ -43,6 +43,7 @@ $_limit =  array(
         array('name'=> '订单手动处理', 'op'=>null, 'act'=>'refill_order_manual'),
         array('name'=> '上游信息管理', 'op'=>null, 'act'=>'provider_info'),
         array('name'=> '机构信息管理', 'op'=>null, 'act'=>'merchant_info'),
+        array('name'=> '订单排队查询', 'op'=>null, 'act'=>'refill_cron'),
     )),
 	array('name'=>$lang['nc_store'], 'child'=>array(
 		array('name'=>$lang['nc_store_manage'], 'op'=>null, 'act'=>'store'),

+ 1 - 0
admin/include/menu.php

@@ -106,6 +106,7 @@ $arr = array(
 					array('args'=>'index,refill_order_manual,merchant',		'text'=>'订单手动处理'),
 					array('args'=>'index,provider_info,merchant',			'text'=>'上游信息管理'),
 					array('args'=>'index,merchant_info,merchant',			'text'=>'机构信息管理'),
+					array('args'=>'index,refill_cron,merchant',				'text'=>'订单排队查询'),
 				)
 			),
 			4 => array(

+ 123 - 0
admin/templates/default/refill.cron.php

@@ -0,0 +1,123 @@
+<style>
+    th label { display: inline-block;width: 60px; }
+    .lineLi {
+        min-width: 150px;
+        font-size: 12px;
+        color:#000;
+    }
+    #prompt ul .noLineLi {
+        background:none; 
+    }
+    #prompt div {
+        display:inline-block;
+        background:none
+    }
+    #prompt ul .lineLi {
+        color:#000;
+    }
+    th {
+        width: 10px;
+    }
+    .txt2 {
+        position: relative;
+    }
+    .btn-search {
+        position: absolute;
+        left: 332px;
+        margin-top: 3px;
+    }
+    
+</style>
+
+<?php defined('InShopNC') or exit('Access Invalid!'); ?>
+<div class="page">
+    <div class="fixed-bar">
+        <div class="item-title">
+            <h3>队列查询</h3>
+            <ul class="tab-base">
+                <li><a href="JavaScript:void(0);" class="current"><span>管理</span></a></li>
+            </ul>
+        </div>
+    </div>
+    <div class="fixed-empty"></div>
+    <form method="get" action="index.php" name="formSearch" id="formSearch">
+        <input type="hidden" name="act" value="refill_cron"/>
+        <input type="hidden" name="op" value="index"/>
+        <table class="tb-type1 noborder search" style="min-width:1400px">
+            <tbody>
+            <tr>
+                <th><label>搜索内容</label></th>
+                <td><input class="txt2" type="text" name="search" value="<?php echo $_GET['search']; ?>"/></td>
+                <a href="javascript:void(0);" id="ncsubmit" class="btn-search"
+                       title="<?php echo $lang['nc_query']; ?>">&nbsp;
+                </a>
+            </tr>
+            </tbody>
+        </table>
+    </form>
+    <table class="table tb-type2 nobdb" style="min-width:1400px">
+        <thead>
+        <tr class="thead">
+            <th class="align-center">出队时间</th>
+            <th class="align-center">队列名称</th>
+            <th class="align-center">执行方法</th>
+            <th class="align-center">机构编码</th>
+            <th class="align-center">商家单号</th>
+            <th class="align-center">充值卡号</th>
+            <th class="align-center">面值</th>
+        </thead>
+        <tbody id="tbody">
+        <?php if (count($output['cron']) > 0) { ?>
+            <?php
+            foreach ($output['cron'] as $key => $cron) { ?>
+                <tr class="hover trFlex">
+                    <td class="align-center"><?php echo date('Y-m-d H:i:s', $cron['exetime']); ?></td>
+                    <td class="align-center"><?php echo array_key_first($cron['params']); ?></td>
+                    <?php foreach ($cron['params'] as $param){ ?>
+                        <td class="align-center"><?php echo $param['method']; ?></td>
+                        <td class="align-center"><?php echo $param['params']['mchid']; ?></td>
+                        <td class="align-center"><?php echo $param['params']['mch_order']; ?></td>
+                        <td class="align-center"><?php echo $param['params']['card_no']; ?></td>
+                        <td class="align-center"><?php echo $param['params']['amount']; ?></td>
+                    <?php }?>
+                </tr>
+            <?php } ?>
+        <?php } else { ?>
+            <tr class="no_data">
+                <td colspan="7"><?php echo $lang['nc_no_record']; ?></td>
+            </tr>
+        <?php } ?>
+        </tbody>
+        <tfoot>
+        <tr class="tfoot">
+            <td colspan="7" id="dataFuncs">
+                <div class="pagination"> <?php echo $output['show_page']; ?> </div>
+            </td>
+        </tr>
+        </tfoot>
+    </table>
+</div>
+<script type="text/javascript" src="<?php echo RESOURCE_SITE_URL; ?>/laydate/laydate.js"></script>
+<script type="text/javascript" src="<?php echo RESOURCE_SITE_URL; ?>/js/jquery-ui/jquery.ui.js"></script>
+<script type="text/javascript" src="<?php echo RESOURCE_SITE_URL; ?>/js/jquery-ui/i18n/zh-CN.js"
+        charset="utf-8"></script>
+<link rel="stylesheet" type="text/css"
+      href="<?php echo RESOURCE_SITE_URL; ?>/js/jquery-ui/themes/ui-lightness/jquery.ui.css"/>
+<script type="text/javascript" src="<?php echo ADMIN_TEMPLATES_URL;?>/js/xm-select.js"></script>
+<script type="text/javascript" src="<?php echo RESOURCE_SITE_URL;?>/refill/layer.js"></script>
+<script type="text/javascript">
+    $(function () {
+        $('#ncsubmit').click(function () {
+           
+            $('#formSearch').submit();
+        });
+        // 表格hover时背景
+        $('.trFlex').each(function () {
+            $(this).hover(function () {
+                $(this)[0].style.backgroundColor = '#cbe9f3'
+            },function() {
+                $(this)[0].style.backgroundColor = '#fff'
+            })
+        })
+    })
+</script>