<%@ page language="C#" autoeventwireup="true" validaterequest="false" inherits="Admin_PollView, App_Web_gqabgzwv" enableEventValidation="false" %>

<!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 runat="server">
    <title>调查内容管理</title>
    <link href="../css/style.css" rel="stylesheet" type="text/css" />
    <link href="../Admin/css/Layer.css" rel="stylesheet" type="text/css" />
</head>
<body>
    <form id="form1" runat="server">
        <div style="width:auto;">
            <asp:ScriptManager ID="ScriptManager1" runat="server">
            </asp:ScriptManager>
            <table width="100%" height="94" border="0" cellpadding="0" cellspacing="0">
          <tr>
            <td align="right" background="images/diaocha1.jpg"><table width="671" height="94" border="0" cellpadding="0" cellspacing="0">
              <tr>
                <td align="left" background="images/diaocha.jpg"><table width="162" height="19" border="0" cellpadding="0" cellspacing="0">
                  <tr>
                    <td align="right" class="biaoti18">在线调查</td>
                  </tr>
                </table></td>
              </tr>
            </table></td>
          </tr>
          <tr>
            <td>
             <hr />
                        
            </td>
          </tr>
        </table>
        </div>
        <asp:UpdatePanel ID="UpdatePanel1" runat="server" UpdateMode="Conditional">
            <ContentTemplate>
            <div style="width:720px;">
                <asp:Label ID="labPollCategoryTitle" runat="server" Text="Label"></asp:Label>
                <asp:HiddenField ID="hdPollCategoryID" runat="server" />
                <br />
                <asp:GridView ID="gvPollTitle" runat="server" AutoGenerateColumns="False" DataKeyNames="PollTitleId"
                    OnRowCommand="gvPollTitle_RowCommand" OnRowDeleting="gvPollTitle_RowDeleting"
                    OnRowEditing="gvPollTitle_RowEditing" OnSelectedIndexChanging="gvPollTitle_SelectedIndexChanging" CellPadding="4" ForeColor="#333333" GridLines="None" Width="100%">
                    <Columns>
                        <asp:BoundField DataField="PollTitleTitle" HeaderText="调查内容" >
                            <ItemStyle HorizontalAlign="Center" />
                        </asp:BoundField>
                        <asp:CheckBoxField DataField="PollTitleIsCheck" HeaderText="是否多选" >
                            <ItemStyle HorizontalAlign="Center" />
                        </asp:CheckBoxField>
                        <asp:CommandField ShowEditButton="True" DeleteText="删除本调查内容" EditText="修改本调查内容" SelectText="管理选项"
                            ShowDeleteButton="True" ShowSelectButton="True" >
                            <ItemStyle HorizontalAlign="Center" />
                        </asp:CommandField>
                    </Columns>
                    <FooterStyle BackColor="#637991" Font-Bold="True" ForeColor="White" />
                    <RowStyle BackColor="#D9EBFF" ForeColor="#333333" />
                    <SelectedRowStyle BackColor="#637991" Font-Bold="True" ForeColor="White" />
                    <PagerStyle BackColor="#637991" ForeColor="White" HorizontalAlign="Center" />
                    <HeaderStyle BackColor="#4a6b84" Font-Bold="True" ForeColor="White" />
                    <AlternatingRowStyle BackColor="White" />
                </asp:GridView>
                <asp:Panel ID="Panel1" runat="server" width="100%">
                    <table width="100%" border="0" cellpadding="1"  cellspacing="1" bgcolor="#d9ebff">
                        <tr>
                            <td align="right" bgcolor="#FFFFFF">
                                调查内容：</td>
                            <td bgcolor="#FFFFFF">
                                <asp:HiddenField ID="hdPollTitleID" runat="server" />
                                <asp:TextBox ID="txPollTitleName" runat="server"></asp:TextBox></td>
                        </tr>
                        <tr>
                            <td align="right" bgcolor="#FFFFFF">
                                是否多选：</td>
                            <td bgcolor="#FFFFFF">
                                <asp:CheckBox ID="chkPollTitleIsCheck" runat="server" Text="多选答案" /></td>
                        </tr>
                        <tr>
                             <td bgcolor="#FFFFFF"></td>
                            <td bgcolor="#FFFFFF">
                                <asp:Button ID="btnPollTitleSave" runat="server" OnClick="btnPollTitleSave_Click1"
                                    Text="添加新的调查内容" /></td>
                        </tr>
                    </table>
                </asp:Panel>
                </div>
            </ContentTemplate>
        </asp:UpdatePanel>
        <br />
        <br />
        <asp:UpdatePanel ID="UpdatePanel2" runat="server">
            <ContentTemplate>
            <div style="width:720px;">
                <asp:GridView Visible="False" ID="gvPollItem" runat="server" AutoGenerateColumns="False"
                    OnRowDeleting="gvPollItem_RowDeleting" OnRowEditing="gvPollItem_RowEditing" DataKeyNames="PollTitleItemId" CellPadding="4" ForeColor="#333333" GridLines="None" Width="100%">
                    <Columns>
                        <asp:BoundField DataField="PollTitleItemName" HeaderText="选项名称" >
                            <ItemStyle HorizontalAlign="Center" />
                        </asp:BoundField>
                        <asp:BoundField DataField="PollTitleItemCount" HeaderText="当前得票数" >
                            <ItemStyle HorizontalAlign="Center" />
                        </asp:BoundField>
                        <asp:CommandField EditText="修改" ShowDeleteButton="True" ShowEditButton="True" >
                            <ItemStyle HorizontalAlign="Center" />
                        </asp:CommandField>
                    </Columns>
                   <FooterStyle BackColor="#637991" Font-Bold="True" ForeColor="White" />
                    <RowStyle BackColor="#D9EBFF" ForeColor="#333333" />
                    <SelectedRowStyle BackColor="#637991" Font-Bold="True" ForeColor="White" />
                    <PagerStyle BackColor="#637991" ForeColor="White" HorizontalAlign="Center" />
                    <HeaderStyle BackColor="#4a6b84" Font-Bold="True" ForeColor="White" />
                    <AlternatingRowStyle BackColor="White" />
                </asp:GridView>
                <asp:HiddenField ID="hdSelectedPollTitleID" runat="server" />
                <asp:Panel ID="Panel2" runat="server" Visible="false" width="100%">
                    <table width="100%" border="0" cellpadding="1" cellspacing="1" bgcolor="#d9ebff">
                        <tr>
                            <td align="right" bgcolor="#FFFFFF">
                                答案选项：</td>
                            <td bgcolor="#FFFFFF">
                                <asp:HiddenField ID="hdPollTitleItemID" runat="server" />
                                <asp:TextBox ID="txtPollTitleItemName" runat="server"></asp:TextBox></td>
                        </tr>
                        <tr>
                            <td bgcolor="#FFFFFF"></td>
                            <td bgcolor="#FFFFFF">
                                <asp:Button ID="btnPollTitleItemSave" runat="server" OnClick="btnPollTitleItemSave_Click1"
                                    Text="保存新的调查选项" /></td>
                        </tr>
                    </table>
                </asp:Panel>
                </div>
            </ContentTemplate>
        </asp:UpdatePanel>
    </form>
</body>
</html>
