<%@ page language="C#" masterpagefile="AdminIndexMaster.master" autoeventwireup="true" inherits="Admin_Admin_ShopComplain, mallz" title="投诉处理" enableEventValidation="false" %>
<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">
 <script type="text/javascript">
      
       function SetNewColor(source,source1)
       { 
          source.style.position="absolute";
          source.style.display="";

       }
       function SetOldColor(source,source1)
       { 
           source.style.display="none";
       }
       
       function SetNewColor1(source,source1)
       { 
           source.style.display="block";
       }
       function SetOldColor1(source,source1)
       { 
          source.style.display="none";
           
       }
    </script>

<table class="adminheading" width="100%">
    <tr>
        <th class="user" align="left" style="width: 19%;">投诉/举报管理</th>
        <td align="right">
        </td>
        <td class="rtdw"></td>
   </tr>
</table>
 
<asp:Panel ID="sreachbar" runat="server">
    <table class="nick"><tr><td colspan="4" class="tit">高级搜索</td></tr>
    <tr><td class="ltd">类型：</td><td class="rtd" style="width:35%">
            <asp:DropDownList ID="DropType1" runat="server" AutoPostBack="True" OnSelectedIndexChanged="DropType1_Change" >
                <asp:ListItem Value="-1">投诉／举报</asp:ListItem>
                <asp:ListItem Value="0">投诉</asp:ListItem>
                <asp:ListItem Value="1">举报</asp:ListItem>
              </asp:DropDownList></td>
             <td class="ltd">状态：</td><td class="rtd" style="width:35%">
             <asp:DropDownList ID="DropStatus1" runat="server" AutoPostBack="True" OnSelectedIndexChanged="DropStatus1_Change" >
                 <asp:ListItem Value="-1">处理状态</asp:ListItem>
                 <asp:ListItem Value="0">等待处理</asp:ListItem>
                 <asp:ListItem Value="1">处理完毕</asp:ListItem>
             </asp:DropDownList>          
             <asp:DropDownList ID="DropStartTime1" runat="server" AutoPostBack="True" OnSelectedIndexChanged="DropStartTime1_Change" >
                 <asp:ListItem Value="0">查看近期记录</asp:ListItem>
                 <asp:ListItem Value="1">查看历史记录</asp:ListItem>
             </asp:DropDownList></td></tr>
            <tr><td class="ltd">发起人帐号：</td><td class="rtd" style="width:35%"><asp:TextBox ID="salername" runat="server" AutoPostBack="True" Width="120" OnTextChanged="salername_Change"/> </td>
            <td class="ltd">用户列表：</td><td class="rtd" style="width:35%"><asp:DropDownList ID="DropDownList1" runat="server" AppendDataBoundItems="True" AutoPostBack="True"
                 DataTextField="username" DataValueField="userid" OnSelectedIndexChanged="DropDownList1_Change" >
                <asp:ListItem Selected="True" Value="0">所有</asp:ListItem>
            </asp:DropDownList></td></tr>
        </table>
</asp:Panel>
        
       <asp:GridView  CssClass="adminlist" ID="GridView2" runat="server" AllowPaging="True" AutoGenerateColumns="False"  
              OnDataBound="GridView2_DataBound" PageSize="20" EnableTheming="False" 
              OnRowDataBound="GridView2_RowDataBound" DataKeyNames="ComplainID"  EnableViewState="true">                               
                <Columns>
                    <asp:BoundField DataField="ComplainID" HeaderText="编号" /> 
                    <asp:HyperLinkField DataNavigateUrlFields="UserID" DataNavigateUrlFormatString="Admin_UserDetail.aspx?UserID={0}" HeaderText="投诉／举报人"  DataTextField="UserName"/> 
                    <asp:HyperLinkField DataNavigateUrlFields="ComplainUserID" DataNavigateUrlFormatString="Admin_UserDetail.aspx?UserID={0}" HeaderText="被投诉／举报人"  DataTextField="ComplainUserName"/>
                    <asp:BoundField DataField="ComplainType" HeaderText="类型"/>
                    <asp:TemplateField HeaderText="处理结果">
                        <ItemTemplate>
                            <asp:Literal ID="litstatus" runat="server" Text='<%#(Eval("status").ToString()=="True")?"已处理":"未处理" %>' />
                        </ItemTemplate>
                    </asp:TemplateField>
                    <asp:TemplateField HeaderText="投诉原因" ItemStyle-HorizontalAlign="Left">
                        <ItemTemplate>
                            <asp:Label ID="Label5" style="position:absolute;" runat="server" Text="显示详细" class="msg_tit"/>
                            <asp:Label ID="Label3" style="position:absolute; background-color:White;z-index:2; padding:5px; text-align:left; border:1px #ccc solid; width:300px; height:100px; display:none;" runat="server" onmouseover="this.style.display=''" onmouseout="this.style.display='none'" Text='<%# Bind("reason") %>'></asp:Label>
                        </ItemTemplate>
                    </asp:TemplateField>                    
                    <asp:TemplateField HeaderText="处理结果" ItemStyle-HorizontalAlign="Left">                         
                        <ItemStyle Width="20%" />
                        <ItemTemplate>
                              <asp:Label ID="Label6" style="position:absolute;" runat="server"  Text="显示详细" class="msg_tit"/>
                              <asp:Label ID="Label4" style="position:absolute; background-color:White;z-index:2; height:100px; padding:5px; text-align:left; border:1px #ccc solid; width:300px;display:none;" runat="server" onmouseover="this.style.display=''" onmouseout="this.style.display='none'"  Text='<%# Bind("result") %>'></asp:Label>
                        </ItemTemplate>
                    </asp:TemplateField>
                    <asp:BoundField DataField="StartTime" HeaderText="日期" HeaderStyle-Width="15%" />
                    <asp:TemplateField HeaderText="操作" >
                      <ItemTemplate>
                        <asp:HyperLink runat="server" ID="butc" NavigateUrl='<%# "?ReviewComplainID=" + Eval("ComplainID") %>' Text="处理" />
                        <asp:LinkButton ID="cl" runat="server" CommandArgument='<%#Eval("ComplainID") %>' OnCommand="Delete_CommandName" OnClientClick="if(confirm('确定删除吗？'))return true;return false;" Text="删除">
                        </asp:LinkButton>
                      </ItemTemplate>
                    </asp:TemplateField>
                </Columns>
                <EmptyDataTemplate>
                        <tr>
                            <th>编号</th>
                            <th>投诉／举报人</th>
                            <th>被投诉／举报人</th>
                            <th>投诉类型</th>
                            <th>处理状态</th>
                            <th>投诉原因</th>
                            <th>处理结果</th>
                            <th>日期</th>
                            <th>操作</th>
                        </tr>
                        <tr><td colspan="9">暂无信息！</td></tr>
                </EmptyDataTemplate>
             </asp:GridView>
              
              <div class="page">
                <asp:Label ID="PagePanel" runat="server" />
              </div>
              
              <div class="div_btm">
                  <asp:Panel ID="Panel1" runat="server" Width="639px">
                   处理结果：<asp:TextBox ID="TextBox1" runat="server" Height="69px" Width="623px" TextMode="MultiLine"/><br />
                      <asp:Button ID="Button1" runat="server" OnClick="Button1_Click" Text=" 提 交 " />
                      <input value=" 取 消 " type="button" onclick="history.back()" />
                      <asp:RequiredFieldValidator ID="rv" runat="server" ErrorMessage="请输入内容！" ControlToValidate="TextBox1"></asp:RequiredFieldValidator>
                  </asp:Panel>
             </div>
             
             
</asp:Content>

