| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110 |
- <?php
- use yii\widgets\LinkPager;
- ?>
- <?php
- use backend\widgets\TabWidget;
- echo TabWidget::widget(['list' => $this->context->menuList, 'currentMenu' => $this->context->id]);
- ?>
- <div class="panel panel-default">
- <?php
- use backend\widgets\SubTabWidget;
-
- echo SubTabWidget::widget(['list' => $this->context->subMenuList, 'currentMenu' => $this->context->action->id]);
- ?>
- <div class="panel-body">
- <div class="dataTables_wrapper form-inline dt-bootstrap no-footer">
- <!--
- <div style="margin-bottom:10px;">
- <button class="btn btn-secondary btn-single" onclick="addToShowCoupon(0,0,'')">通用卷设置</button>
- </div>
- -->
- <div class="table-responsive">
- <table class="table table-bordered table-striped table-hover">
- <thead>
- <tr class="active">
- <th class="no-sorting hidden-xs"><input type="checkbox"></th>
- <th class="hidden-xs">优先级</th>
- <th class="hidden-xs">类型编号</th>
- <th>适用范围</th>
- <th>优惠金额</th>
- <th>最底消费</th>
- <th>新人用卷奖励</th>
- <th class="hidden-xs">领卷有效期</th>
- <th>发卷人数</th>
- <th>领卷数</th>
- <th class="hidden-xs">状态</th>
- <th>操作</th>
- </tr>
- </thead>
- <tbody class="middle-align">
- <?php if (!empty($list)) {
- foreach ($list as $key => $val) { ?>
- <tr>
- <td class="hidden-xs"><input type="checkbox"></td>
- <td><?= $val['level']; ?></td>
- <td class="hidden-xs"><?= $val['id']; ?></td>
- <td>
- <?php
- //0通用卷 1商品分类卷 2商品用途卷
- if ($val['type'] == 0) {
- if($val['targetId'] == 0){
- echo '<span style="color:green;font-weight:bold;">通用型</span>';
- }elseif($val['targetId'] == 1){
- echo '<span style="color:green;font-weight:bold;">通用型(二次)</span>';
- }elseif($val['targetId'] == 2){
- echo '<span style="color:green;font-weight:bold;">通用型(三次)</span>';
- }else{
- echo '<span style="color:green;font-weight:bold;">通用型(未知)</span>';
- }
- } elseif ($val['type'] == 1) {
- echo isset($categoryList[$val['targetId']]) ? $categoryList[$val['targetId']]['name'] : '';
- } elseif ($val['type'] == 2) {
- echo isset($usageList[$val['targetId']]) ? $usageList[$val['targetId']]['name'] : '';
- } else {
- }
- ?>
- </td>
- <td><?= $val['amount']; ?></td>
- <td><?= $val['meetAmount']; ?></td>
- <td><?= $val['reward']; ?></td>
- <td><?= $val['validTime'] ?>天</td>
- <td><?= $val['rightNum'] ?></td>
- <td><?= $val['getNum'] ?></td>
- <td>
- <?php if ($val['status'] == 0) {
- echo '停用';
- } ?>
- </td>
- <td>
- <!--
- <a href="javascript:void(0);" onclick="modifyToShowCoupon(<?= $val['id']; ?>)" style="color:blue;">修改</a>
- -->
- </td>
- </tr>
- <?php }
- } ?>
- </tbody>
- </table>
- </div>
- <div class="row">
- <div>
- <div class="dataTables_paginate paging_simple_numbers" style="float:right;padding-top:0px;margin-right:15px;">
- <?= LinkPager::widget(['pagination' => $pages]); ?>
- </div>
- </div>
- </div>
- </div>
- </div>
- </div>
- <!-- footer -->
- <?php
- use backend\widgets\FooterWidget;
- ?>
- <?= FooterWidget::widget() ?>
- <!-- footer -->
|