123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358 |
- <style>
- th label {
- display: inline-block;
- width: 60px;
- margin-left: 10px;
- }
- .page .fixed-bar .item-title h3 {
- margin-top: 18px !important;
- margin-bottom: 10px !important;
- font-weight: 700 !important;
- }
- .tab-base li span {
- font-size: 12px !important;
- }
- .query_ors {
- width: 125px;
- }
- 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;
- }
- #selest_nc {
- width: 220px
- }
- tbody {
- font-size: 12px;
- }
- .layui-form-select .layui-input {
- padding: 13px 5px;
- }
- .selection .layui-form-selected dl {
- display: flex !important;
- flex-wrap: wrap !important;
- }
- .selection .layui-form-select dl {
- top: 29px !important;
- min-width: 883% !important;
- max-height: 280px !important;
- padding: 14px 0 !important;
- left: 0 !important;
- }
- .layui-form-select {
- width: 45%;
- }
- .layui-select-title {
- width: 104%;
- }
- .selection .layui-form-select .layui-input {
- padding-left: 11px;
- }
- .page .fixed-bar .item-title h3 {
- margin-top: 18px !important;
- margin-bottom: 10px !important;
- font-weight: 700 !important;
- }
- .tab-base li span {
- font-size: 12px !important;
- }
- .layui-form-select .layui-input {
- height: 26px;
- }
- input::placeholder {
- color: #333;
- }
- .xm-tips {
- color: #333 !important;
- font-size: 12px;
- }
- .layui-form-select dl dd.layui-this {
- display: none;
- }
- .layui-form-select dl dd {
- cursor: pointer;
- width: 130px;
- }
- .tb-type1 td select {
- width: 201px;
- }
- .tb-type1 td input[type="text"],
- .tb-type1 td select {
- margin-right: 4px;
- margin-left: 0;
- width: 195px;
- }
- .layui-form-select .layui-edge {
- right: -91px !important;
- }
- .type .layui-form-select dl {
- top: 29px !important;
- width: 214% !important;
- }
- </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="index.php?act=OrderStats&op=index&type=system"><span>上游对账记录</span></a></li>
- <li><a href="index.php?act=OrderStats&op=index&type=provider"><span>上游对账记录</span></a></li>
- <li><a href="index.php?act=OrderStats&op=index&type=merchant"><span>下游对账记录</span></a></li>
- <li><a href="JavaScript:void(0);" class="current"><span>任务列表</span></a></li>
- <li><a href="index.php?act=OrderStats&op=task_add"><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="orderstats"/>
- <input type="hidden" name="op" value="refill_task"/>
- <table class="tb-type1 noborder search">
- <tr>
- <th><label>主体类型</label></th>
- <td class="layui-form type">
- <select name="type" id="type" lay-filter="type">
- <option value="">请选择</option>
- <?php foreach ($output['type'] as $key => $value){?>
- <option value="<?php echo $key;?>" <?php if($_GET['type'] === $key) { echo 'selected'; }?>><?php echo $value;?></option>
- <?php }?>
- </select>
- </td>
- <th><label>主体选择</label></th>
- <td class="layui-form selection">
- <select name="cid" id="cid" lay-filter="cid" lay-search></select>
- </td>
- <td>
- <a href="javascript:void(0);" id="ncsubmit" class="btn-search "
- title="<?php echo $lang['nc_query']; ?>">
- </a>
- </td>
- </tr>
- </table>
- </form>
- <table class="table tb-type2 nobdb">
- <thead>
- <tr class="thead">
- <th class="align-center">编号</th>
- <th class="align-center">任务ID</th>
- <th class="align-center">任务类型</th>
- <th class="align-center">主体类型</th>
- <th class="align-center">主体ID</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>
- <th class="align-center">处理结果</th>
- </tr>
- </thead>
- <tbody id="tbody">
- <?php if (count($output['list']) > 0) { ?>
- <?php
- foreach ($output['list'] as $key => $value) { ?>
- <tr class="hover trFlex">
- <td class="align-center"><?php echo $key + 1; ?></td>
- <td class="align-center"><?php echo $value['task_id']; ?></td>
- <td class="align-center"><?php echo $output['task_type'][$value['task_type']]; ?></td>
- <td class="align-center"><?php echo $output['type'][$value['type']]; ?></td>
- <td class="align-center"><?php echo $value['cid']; ?></td>
- <td class="align-center"><?php echo $value['cname']; ?></td>
- <td class="align-center">
- <p>统计日期类型:<?php echo $output['order_time_type'][$value['condition']['order_time_type']];?></p>
- <p>
- 统计日期范围:<?php echo date("Y-m-d H:i:s", $value['condition']['start_unixtime'])?>
- <?php if (!empty($value['condition']['end_unixtime'])) {
- echo '~' . date("Y-m-d H:i:s", $value['condition']['end_unixtime']);
- }
- ?>
- </p>
- <p>订单状态:
- <?php if ($value['condition']['order_state'] === '') {
- echo '/';
- } else {
- echo orderState($value['condition']);
- }
- ?>
- </p>
- </td>
- <td class="align-center"><?php echo $output['task_state'][$value['task_state']]; ?></td>
- <td class="align-center"><?php echo $value['add_time'] ? date('Y-m-d H:i:s', $value['add_time']) : '/'; ?></td>
- <td class="align-center"><?php echo $value['dispose_time'] ? date('Y-m-d H:i:s', $value['dispose_time']) : '/'; ?></td>
- <td class="align-center"><?php echo $value['finish_time'] ? date('Y-m-d H:i:s', $value['finish_time']) : '/'; ?></td>
- <td class="align-center">
- <?php if($value['task_state'] == 3 && !empty($value['task_result'])){?>
- <a target="_blank" href="<?php echo UPLOAD_SITE_URL . '/' . ATTACH_TASK . DS . $value['task_result']; ?>">下载</a>
- <?php }?>
- </td>
- </tr>
- <?php } ?>
- <?php } else { ?>
- <tr class="no_data">
- <td colspan="11"><?php echo $lang['nc_no_record']; ?></td>
- </tr>
- <?php } ?>
- </tbody>
- <tfoot>
- <tr class="tfoot">
- <td colspan="11" id="dataFuncs">
- <div class="pagination"> <?php echo $output['show_page']; ?> </div>
- </td>
- </tr>
- </tfoot>
- </table>
- <!-- 预警提示 -->
- <audio id="auto" src="<?php echo RESOURCE_SITE_URL; ?>/warning.mp3"></audio>
- </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;?>/layui/layui.js"></script>
- <link rel="stylesheet" type="text/css" href="<?php echo ADMIN_TEMPLATES_URL; ?>/layui/css/layui.css"/>
- <script type="text/javascript">
- $(function () {
- $('#ncsubmit').click(function () {
- $('#formSearch').submit();
- });
- $('#query_start_time').datepicker({dateFormat: 'yy-mm-dd'});
- $('#query_end_time').datepicker({dateFormat: 'yy-mm-dd'});
- // 日期选择器
- laydate.render({
- elem: '#startTime',
- type: 'datetime'
- });
- laydate.render({
- elem: '#endTime',
- type: 'datetime'
- });
- // 表格hover时背景
- $('.trFlex').each(function () {
- $(this).hover(function () {
- $(this)[0].style.backgroundColor = '#cbe9f3'
- }, function () {
- $(this)[0].style.backgroundColor = '#fff'
- })
- })
- // 供方名称颜色
- $('.textColor').each(function () {
- let color = $(this).attr('data-color')
- if (color == '1') {
- $(this).css('color', 'green')
- } else {
- $(this).css('color', 'red')
- }
- })
-
- let selectValue = ''
- let selectRes = {}
-
- let selectNew = $("#cid").next().find("input")
-
- for (let i = 0; i < selectRes.length; i++) {
- if (selectRes[i].value == selectValue) {
- console.log(selectValue, 12333);
- $(selectNew).val(selectRes[i].value)
- selectRes[i].selected = true
- }
- }
- //主体选择
- layui.use(['form'], function () {
- let form = layui.form;
- let default_type = $('select[name="type"]').val();
- if (default_type === 'merchant') {
- $.get('index.php?act=refill_order&op=merchant_data', function(res) {
- res = JSON.parse(res)
- let html = '';
- res.forEach(item => {
- html += `<option value="${item.value}">${item.name}</option>`;
- })
- let select_type = `<select>${html}</select>`
- $('#cid').html(select_type);
- form.render('select')
- })
- } else if (default_type === 'provider'){
- $.get('index.php?act=refill_order&op=provider_data', function(res) {
- res = JSON.parse(res)
- let html = '';
- res.forEach(item => {
- html += `<option value="${item.value}">${item.name}</option>`;
- })
- let select_type = `<select>${html}</select>`
- $('#cid').html(select_type);
- form.render('select')
- })
- } else {
- $('#cid').html('');
- form.render('select')
- }
- form.on('select(type)', function (data) {
- let form_type = data.value;
- selectValue = data.value
- form.render('select')
- if (form_type === 'merchant') {
- $.get('index.php?act=refill_order&op=merchant_data', function(res) {
- res = JSON.parse(res)
- let html = '';
- res.forEach(item => {
- html += `<option value="${item.value}">${item.name}</option>`;
- })
- let select_type = `<select>${html}</select>`
- $('#cid').html(select_type);
- form.render('select')
-
- })
- } else if (form_type === 'provider'){
- $.get('index.php?act=refill_order&op=provider_data', function(res) {
- res = JSON.parse(res)
- selectRes = res
- let html = '';
- res.forEach(item => {
- html += `<option value="${item.value}">${item.name}</option>`;
- })
- let select_type = `<select>${html}</select>`
- $('#cid').html(select_type);
- form.on('select(cid)', function (data) {
- let form_type = data.value;
- console.log('xuang',form_type);
- $("#cid dl").find("dd[lay-value=" +form_type+"]").attr("selected",true);
- form.render('select')
-
- })
- form.render('select')
- })
- } else {
- $('#cid').html('');
- form.render('select')
- }
- })
- })
- });
- </script>
|