<%@ page language="C#" masterpagefile="AdminIndexMaster.master" inherits="HL_Admin_Admin_ShopManagePromotion, HoWaveVGO" title="促销方案管理" enableEventValidation="false" %>
<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">
<asp:ScriptManager ID="ScriptManager1" runat="server" EnablePartialRendering="true"/>
  <script type="text/jscript">
     
     function OpenWin(){ 
             var str=window.showModalDialog('Shop_commonpage.aspx',document.getElementById('ctl00_ContentPlaceHolder1_txthidenValue').value,'dialogHeight:600px;dialogWidth:850px;status:no;') ;
          if(str!=null)document.getElementById('ctl00_ContentPlaceHolder1_txthidenValue').value=str ;
          } 
    </script> 
           <table width="100%"  class="adminform">
        <tr>
            <td style="height: 14px">
                <span style="font-size: 30px">促销方案管理</span>
                <br />
                <table class="adminlist">
                    <tr>
                        <td>
                            卖家名称：
                        </td>
                        <td  >
                            <asp:TextBox ID="TextBox1" runat="server" AutoPostBack="True"></asp:TextBox></td>
                        <td >
                            卖家列表</td>
                        <td  >
                            <asp:UpdatePanel ID="UpdatePanel11" runat="server" >
                                <ContentTemplate>
                                
                                    <asp:DropDownList ID="DropDownList1" runat="server" AutoPostBack="True" DataSourceID="ObjectDataSource2"
                                        DataTextField="username" DataValueField="userid">
                                    </asp:DropDownList>
                                </ContentTemplate>
                                <%--<Triggers>
                                    <asp:AsyncPostBackTrigger ControlID="TextBox1" PropertyName="Text" />
                                </Triggers>--%>
                            </asp:UpdatePanel>
                            <asp:ObjectDataSource ID="ObjectDataSource2" runat="server" SelectMethod="GetUserLikeUserName"
                                TypeName="UserBLL">
                                <SelectParameters>
                                    <asp:ControlParameter ControlID="TextBox1" Name="UserName" PropertyName="Text" Type="String" />
                                </SelectParameters>
                            </asp:ObjectDataSource>
                        </td>
                    </tr>
                </table>
            </td>
        </tr>
        <tr>
            <td style="height: 232px">
                &nbsp;<asp:ObjectDataSource ID="ObjectDataSource1" runat="server" SelectMethod="GetPromoteProjectSalerID"
                    TypeName="Shop_PromoteProject" UpdateMethod="GetPromoteProjectSalerID" DeleteMethod="DeleteProject" OldValuesParameterFormatString="original_{0}">
                    <UpdateParameters>
                        <asp:Parameter Name="SalerID" Type="Int32" />
                    </UpdateParameters>
                    <SelectParameters>
                       <asp:ControlParameter ControlID="DropDownList1" DefaultValue="-1" Name="SalerID"
                PropertyName="SelectedValue" Type="Int32" />
                    </SelectParameters>
                    <DeleteParameters>
                        <asp:Parameter Name="ProjectID" Type="Int32" />
                    </DeleteParameters>
                </asp:ObjectDataSource>
                <asp:UpdatePanel ID="UpdatePanel1" runat="server" >
                    <ContentTemplate>
                <asp:GridView ID="GridView1" class="adminlist"  runat="server" AutoGenerateColumns="False" DataSourceID="ObjectDataSource1" DataKeyNames="ProjectID" AllowPaging="True" Width="100%">
                 <Columns>
                        <asp:BoundField DataField="ProjectName" HeaderText="方案名称" >
                            <HeaderStyle Width="10%" Wrap="False" />
                        </asp:BoundField>
                     <asp:TemplateField HeaderText="价格区间">
                          
                         <HeaderStyle Width="10%" Wrap="False" />
                         <ItemTemplate>
                            从 <asp:Label ID="LabelMinMoney" runat="server" Text='<%# Bind("MinMoney") %>'></asp:Label>到
                  <asp:Label ID="LabelMaxMoney" runat="server" Text='<%# Bind("MaxMoney") %>'></asp:Label>
                         </ItemTemplate>
                     </asp:TemplateField>
                     <asp:TemplateField HeaderText="有效期">
                         
                         <HeaderStyle Width="10%" Wrap="False" />
                         <ItemTemplate>
                            从 <asp:Label ID="LabelBeginDate" runat="server" Text='<%# Bind("BeginDate") %>'></asp:Label>到
                  <asp:Label ID="LabelEndDate" runat="server" Text='<%# Bind("EndDate") %>'></asp:Label>
                         </ItemTemplate>
                     </asp:TemplateField>
                     <asp:TemplateField HeaderText="有效">
                         <HeaderStyle Width="10%" Wrap="False" />
                         <ItemTemplate>
                             <asp:CheckBox ID="CheckEffective" runat="server" Text="是" />
                         </ItemTemplate>
                     </asp:TemplateField>
                        <asp:BoundField DataField="PresentContent" HeaderText="方案内容" >
                            <HeaderStyle Width="30%" Wrap="False" />
                        </asp:BoundField>
                     <asp:CommandField ShowDeleteButton="True" HeaderText="删除" />
                    </Columns>
                </asp:GridView>
                    </ContentTemplate>
                   <%-- <Triggers>
                        <asp:AsyncPostBackTrigger ControlID="DropDownList1" PropertyName="SelectedValue" /></Triggers>--%>
                </asp:UpdatePanel>
               
                <span style="color: #ff0000"></span>
            </td>
        </tr>
    </table>
   
</asp:Content>

