<%@ Page Language="C#" AutoEventWireup="true" MasterPageFile="../Global.Master" CodeBehind="MoneyCard.aspx.cs" Inherits="Web.AdminManager.Finance.MoneyCard" %>

<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
    <script src="../js/Finance.MoneyCard.js"></script>
    <script src="/Common/js/Common_Class.js" type="text/javascript"></script>
    <script src="/Common/UEditor/editor_config.js" type="text/javascript"></script>
    <script src="/Common/UEditor/editor_all_min.js" type="text/javascript"></script>
    <link href="/Common/jQuery/themes/jquery-ui.min.css" rel="stylesheet" />
    <link href="/Common/jQuery/themes/jquery.ui.datepicker.min.css" rel="stylesheet" />
    <script src="/Common/jQuery/ui/jquery-ui.min.js"></script>
    <script src="/Common/jQuery/ui/jquery.ui.datepicker.min.js"></script>
    <link rel="stylesheet" type="text/css" href="/Common/UEditor/themes/default/ueditor.css" />
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
    <div id="ui_Info" runat="server" visible="false">
        <table class="ui-table ui-table-bordered">
            <tr>
                <td style="width:100px;">卡号</td>
                <td><%=mmc.CardNO %> </td>
            </tr>
            <tr>
                <td>金额</td>
                <td><%=Math.Round(mmc.CardMoney,2)+"元" %></td>
            </tr>
            <tr>
                <td>添加时间</td>
                <td><%=mmc.AddTime.ToString("yyyy-MM-dd") %></td>
            </tr>
            <tr>
                <td>过期时间</td>
                <td><%=mmc.ExpireTime.ToString("yyyy-MM-dd") %></td>
            </tr>
            <tr>
                <td>状态</td>
                <td><%=mmc.ExpireTime<DateTime.Now?"已过期":mmc.IsUsed?"已用":"未用" %></td>
            </tr>
            <tr>
                <td>使用者</td>
                <td><%=mmc.UserName %></td>
            </tr>
            <tr>
                <td>使用时间</td>
                <td><%=mmc.UsedTime.ToString("yyyy-MM-dd") %></td>
            </tr>
            <tr>
                <td></td>
                <td><input type="button" class="ui-btn ui-btn-primary" onclick="history.back();" value="返回" /></td>
            </tr>
        </table>

    </div>
    <div id="ui_Edit" runat="server" visible="false">
        <form action="" method="post" class="ui-form ui-form-vertical">
            <fieldset>
                <legend>财务操作</legend>
                <div class="ui-form-group">
                    <label class="ui-form-label">生成价格</label><div class="ui-form-ctrls">
                        <input type="text" name="CardMoney" id="CardMoney"
                            class="ui-input-mini" value="" /><span
                                class="CardMoney ui-help-inline">充值卡金额</span>
                    </div>
                </div>
                <div class="ui-form-group">
                    <label class="ui-form-label">生成数量</label><div class="ui-form-ctrls">
                        <input type="text" name="CardNum" id="CardNum"
                            class="ui-input-mini" value="" /><span
                                class="CardNum ui-help-inline">充值卡数量</span>
                    </div>
                </div>
                <div class="ui-form-group">
                    <label class="ui-form-label">过期时间</label><div class="ui-form-ctrls">
                        <input type="text" name="ExpireTime" id="ExpireTime"
                            class="ui-input-small" value="" /><span
                                class="ExpireTime ui-help-inline">充值卡什么时候过期，正确格式如：<%=DateTime.Now.Date.ToString("yyyy-MM-dd") %></span>
                    </div>
                </div>
                <div class="ui-form-group">
                    <label class="ui-form-label">&nbsp;</label>
                    <div class="ui-form-ctrls">
                        <button type="submit" class="ui-btn ui-btn-primary">开始生成</button>&nbsp;&nbsp;<input type="button" class="ui-btn" value="返回" />
                    </div>
                </div>
            </fieldset>
        </form>
    </div>
    <div id="ui_List" runat="server" visible="false">
        <table class="ui-table ui-table-bordered">
            <thead>
                <tr>
                    <td colspan="6"><form action="" method="post">关键词：<input name="skey" class="ui-input-small" type="text" value="<%=sKey %>" />
                        查找方式：<select name="stype"><option value="0" <%=stype==0?"selected":"" %>>不限</option>
                            <option value="1" <%=stype==1?"selected":"" %>>卡号</option>
                            <option value="2" <%=stype==2?"selected":"" %>>用户名</option>
                        </select>
                        金额：<input name="CardMoney" class="ui-input-mini" type="text" value="<%=sCardMoney %>" />
                        状态：<select name="sstate"><option value="0" <%=sstate==0?"selected":"" %>>不限</option>
                            <option value="1" <%=sstate==1?"selected":"" %>>未用</option>
                            <option value="2" <%=sstate==2?"selected":"" %>>已用</option>
                            <option value="3">过期</option>
                        </select>
                        &nbsp;
                        <button id="btn_search" type="submit" class="icon-search ui-btn ui-btn-primary"></button></form>
                    </td>
                </tr>
                <tr>
                    <td colspan="6">
                        <a href="?Action=Add" class="ui-btn ui-btn-primary">生成充值卡</a>
                    </td>
                </tr>
                <tr>
                    <th>卡号
                    </th>
                    <th>金额
                    </th>
                    <th>状态
                    </th>
                    <th>操作
                    </th>
                </tr>
            </thead>
            <%=ShowList%>
            <tr>
                <td colspan="6" id="Pager" class="Pager" runat="server"></td>
            </tr>
        </table>
    </div>
</asp:Content>
