123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147 |
- <%@ page contentType="text/html;charset=UTF-8" %>
- <%@ include file="/WEB-INF/views/include/taglib.jsp"%>
- <html>
- <head>
- <title>兑换码优惠券</title>
- <meta name="decorator" content="default"/>
- <style type="text/css">
- .table th{text-align: center;}
- .table td{text-align: center;}
- </style>
- <script type="text/javascript">
- $(document).ready(function() {
- });
- function page(n,s){
- $("#pageNo").val(n);
- $("#pageSize").val(s);
- $("#searchForm").submit();
- return false;
- }
- </script>
- </head>
- <body>
- <ul class="nav nav-tabs">
- <li class="active"><a href="${ctx}/coupon/cmCoupon/codeCouponList">兑换码优惠券</a></li>
- </ul>
- <form:form id="searchForm" modelAttribute="cmCoupon" action="${ctx}/coupon/cmCoupon/codeCouponList" method="post" class="breadcrumb form-search">
- <input id="pageNo" name="pageNo" type="hidden" value="${page.pageNo}"/>
- <input id="pageSize" name="pageSize" type="hidden" value="${page.pageSize}"/>
- <div class="ul-form">
- <label>活动主题:</label>
- <form:input path="name" htmlEscape="false" maxlength="50" class="input-medium"/>
- <label>状态:</label>
- <form:select path="status" class="input-medium required">
- <form:option value="" label="所有"/>
- <form:option value="0" label="未生效"/>
- <form:option value="1" label="已生效"/>
- <form:option value="2" label="已关闭"/>
- <form:option value="3" label="已失效"/>
- </form:select>
- <label>优惠时间:</label>
- <input name="startDate" type="text" readonly="readonly" maxlength="20" class="input-medium Wdate"
- value="<fmt:formatDate value="${cmCoupon.startDate}" pattern="yyyy-MM-dd HH:mm:ss"/>"
- onclick="WdatePicker({dateFmt:'yyyy-MM-dd',isShowClear:false});"/> -
- <input name="endDate" type="text" readonly="readonly" maxlength="20" class="input-medium Wdate"
- value="<fmt:formatDate value="${cmCoupon.endDate}" pattern="yyyy-MM-dd HH:mm:ss"/>"
- onclick="WdatePicker({dateFmt:'yyyy-MM-dd',isShowClear:false});"/>
- <input id="btnSubmit" class="btn btn-primary" type="submit" value="查询"/>
- <input class="btn btn-primary" style="width: 120px" onclick="window.location='${ctx}/coupon/cmCoupon/codeCouponForm'" value="添加兑换码优惠券"/>
- <div class="clearfix"></div>
- </div>
- </form:form>
- <sys:message content="${message}"/>
- <table id="contentTable" class="table table-striped table-bordered table-condensed">
- <thead>
- <tr>
- <th>ID</th>
- <th>活动主题</th>
- <th>优惠券金额</th>
- <th>优惠条件</th>
- <th>已兑换数量</th>
- <th>上架时间</th>
- <th>下架时间</th>
- <th>使用期限</th>
- <th>状态</th>
- <th>添加时间</th>
- <th>操作</th>
- </tr>
- </thead>
- <tbody>
- <c:forEach items="${page.list}" var="cmCoupon">
- <tr>
- <td>
- ${cmCoupon.id}
- </td>
- <td>
- ${cmCoupon.name}
- </td>
- <td>
- ${cmCoupon.couponAmount}
- </td>
- <td>
- 满${cmCoupon.touchPrice}
- </td>
- <td>
- ${cmCoupon.codeNum}
- </td>
- <td>
- <fmt:formatDate value="${cmCoupon.startDate}" pattern="yyyy-MM-dd HH:mm:ss"/>
- </td>
- <td>
- <fmt:formatDate value="${cmCoupon.endDate}" pattern="yyyy-MM-dd HH:mm:ss"/>
- </td>
- <td>
- <c:if test="${cmCoupon.usePeriod > 0}">${cmCoupon.usePeriod}天</c:if>
- <c:if test="${empty cmCoupon.usePeriod || cmCoupon.usePeriod < 0}">--</c:if>
- </td>
- <td>
- <c:if test="${cmCoupon.status eq 0}">
- <font color="#800080">未生效</font>
- </c:if>
- <c:if test="${cmCoupon.status eq 1}">
- <font color="#00CC66">已生效</font>
- </c:if>
- <c:if test="${cmCoupon.status eq 2}">
- <font color="red">已关闭</font>
- </c:if>
- <c:if test="${cmCoupon.status eq 3}">
- <font color="#FF6600">已失效</font>
- </c:if>
- </td>
- <td>
- <fmt:formatDate value="${cmCoupon.createDate}" pattern="yyyy-MM-dd HH:mm:ss"/>
- </td>
- <td>
- <a href="${ctx}/coupon/cmCoupon/codeCouponForm?id=${cmCoupon.id}">编辑</a>
- <c:if test="${cmCoupon.status eq 2}">
- <a href="${ctx}/coupon/cmCoupon/open?id=${cmCoupon.id}" onclick="return confirmx('确定开启该活动吗?', this.href)">开启</a>
- </c:if>
- <c:if test="${cmCoupon.status ne 2}">
- <a href="${ctx}/coupon/cmCoupon/close?id=${cmCoupon.id}" onclick="return confirmx('确定关闭该活动吗?', this.href)">关闭</a>
- </c:if>
- <a href="${ctx}/coupon/cmCoupon/delete?id=${cmCoupon.id}" onclick="return confirmx('确定删除该活动吗?', this.href)">删除</a>
- <a href="javascript:void(0);" onclick="showSelect(${cmCoupon.id})">查看兑换码</a>
- </td>
- </tr>
- </c:forEach>
- </tbody>
- </table>
- <script>
- function showSelect(couponId) {
- var url = "${ctx}/coupon/cmCoupon/redemptionCode?couponId=" + couponId;
- var title = '';
- title = "查看兑换码";
- top.$.jBox("iframe:" + url, {
- iframeScrolling: 'yes',
- width: $(top.document).width() - 750,
- height: $(top.document).height() - 300,
- persistent: true,
- title: title,
- buttons: {"确定": '1'}
- });
- }
- </script>
- <div class="pagination">${page}</div>
- </body>
- </html>
|