<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="PointsManage.aspx.cs" Inherits="MTCUN.Affairs.PointsManage"
    Title="积分管理-教务" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head id="Head1" runat="server">
    <title></title>
    <link id="linkStyle" runat="server" href="../Themes/Blue/css.css" rel="stylesheet"
        type="text/css" />
</head>
<body>
    <form id="form1" runat="server">
        <div class="divpanel" runat="server">
            <table class="table" cellspacing="0">
                <tr>
                    <th>提示信息
                    </th>
                </tr>
                <tr>
                    <td>学员：<asp:Label ID="labStudentName" runat="server"></asp:Label>
                        &nbsp;拥有积分：<asp:Label ID="labPoints" runat="server" ForeColor="Red"></asp:Label>
                    </td>
                </tr>
            </table>
        </div>
        <div class="tool_Search">
            积分：<asp:TextBox ID="tbxPoints" runat="server" Width="80px"></asp:TextBox>
            原因：<asp:TextBox ID="tbxRemark" runat="server"></asp:TextBox>
            <label class="lab_button">
                <asp:Button ID="btnPost" runat="server" Text="增加" OnClick="btnPost_Click" />
            </label>
        </div>
        <div class="both">
        </div>
        <div class="divpanel">
            <asp:GridView ID="GridView1" runat="server" AutoGenerateColumns="False" CssClass="gridview"
                OnRowDeleting="GridView1_RowDeleting" DataKeyNames="StuPointsID" OnRowCancelingEdit="GridView1_RowCancelingEdit"
                OnRowDataBound="GridView1_RowDataBound" OnRowEditing="GridView1_RowEditing" OnRowUpdating="GridView1_RowUpdating"
                EnableModelValidation="True">
                <Columns>
                    <asp:BoundField DataField="StuPointsID" HeaderText="编号" ReadOnly="True" />
                    <asp:TemplateField HeaderText="积分">
                        <ItemTemplate>
                            <asp:Label ID="labPoints" runat="server" Text='<%# Bind("Points") %>'></asp:Label>
                        </ItemTemplate>
                        <EditItemTemplate>
                            <asp:TextBox ID="tbxPoints" runat="server" Width="80px" Text='<%# Bind("Points") %>'></asp:TextBox>
                        </EditItemTemplate>
                    </asp:TemplateField>
                    <asp:TemplateField HeaderText="原因">
                        <ItemTemplate>
                            <asp:Label ID="labRemark" runat="server" Text='<%# Bind("Remark") %>'></asp:Label>
                        </ItemTemplate>
                        <EditItemTemplate>
                            <asp:TextBox ID="tbxRemark" runat="server" Width="200px" Text='<%# Bind("Remark") %>'></asp:TextBox>
                        </EditItemTemplate>
                    </asp:TemplateField>
                    <asp:BoundField DataField="DateAndTime" HeaderText="日期" ReadOnly="True" />
                    <asp:BoundField DataField="TrueName" HeaderText="经办人" ReadOnly="True" />
                    <%--<asp:CommandField HeaderText="编辑" EditText="编辑" CancelText="取消" UpdateText="更新" ShowEditButton="true" />--%>
                    <asp:TemplateField HeaderText="编辑">
                        <ItemTemplate>
                            <div class="lab_button_sub" id="divEdit" runat="server">
                                <asp:LinkButton ID="lbnEdit" runat="server" Text="编辑" CommandName="Edit"></asp:LinkButton>
                            </div>
                        </ItemTemplate>
                        <EditItemTemplate>
                            <div class="lab_button_sub">
                                <asp:LinkButton ID="lbnUpdate" runat="server" Text="更新" CommandName="Update"></asp:LinkButton>
                            </div>
                            <div class="lab_button_sub">
                                <asp:LinkButton ID="lbnCancel" runat="server" Text="取消" CommandName="Cancel"></asp:LinkButton>
                            </div>
                        </EditItemTemplate>
                    </asp:TemplateField>
                    <asp:TemplateField HeaderText="删除">
                        <ItemTemplate>
                            <div class="lab_button_sub" id="divDelete" runat="server">
                                <asp:LinkButton ID="lbnDelete" runat="server" Text="删除" CommandName="Delete" OnClientClick="return confirm('你是否确定删除这条记录？');"></asp:LinkButton>
                            </div>
                        </ItemTemplate>
                    </asp:TemplateField>
                </Columns>
            </asp:GridView>
        </div>
        <div class="divpanel">
            <asp:Literal ID="litPagerButton" runat="server"></asp:Literal>
        </div>
        <div class="backpanel">
            <label class="lab_button" id="__mt_labBack" runat="server">
                <input id="Button1" causesvalidation="false" type="button" runat="server" onclick="back(this)"
                    value="返回" />
            </label>
        </div>
    </form>
</body>
</html>
