<%@ Page Title="" Language="C#" MasterPageFile="~/Package/package.Master" AutoEventWireup="true" CodeBehind="CollectBoxesList.aspx.cs" Inherits="GxHub.Wms.Abroad.Web.Package.CollectBoxesList" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
     <title>
        集包列表
    </title>
     <script type="text/javascript">
         //使用checkbox当做全选反选
         function check_all_not() {
             var check = document.getElementById("checkboxAll").checked;
             //alert(check);
             if (check == true) {
                 checkAll();
             }
             else {
                 checkReverse();
             }

         }


         //选择
         function checkAll() {
             $(".check ").each(function () {
                 $(this).attr("checked", true);
             });
         }
         //反选
         function checkReverse() {
             $(".check ").each(function () {
                 $(this).attr("checked", !($(this).attr("checked")));
             });
         }
         function checkRemove() {
             $(".check ").each(function () {
                 $(this).attr("checked", false);
             });
         }

         function check_Click() {


             if ($(".check:checked").length == 0) {
                 alert("请先选择数据行");
                 return false;
             }
             var boxId = "";

             $(".check:checked").each(function () {
                 boxId += $(this).val() + ",";
             });

             $("#iframeBox").dialog("open");
             $("#BoxIframe").attr("src", "SendToAbroad.aspx?Id=" + boxId);
             return false;

         }

         function collect_click() {


             if ($(".check:checked").length == 0) {
                 alert("请先选择数据行");
                 return false;
             }
             var boxId = "";

             $(".check:checked").each(function () {
                 boxId += $(this).val() + ",";
             });
             $("#hfCollectUniqueId").val(boxId);
             // window.location.href = "CollectList.aspx?BoxId=" + boxId;
             // return false;

         }

         $(function () {
             $("#iframeBox").dialog({
                 title: '已发往海外',
                 autoOpen: false,
                 resizable: false,
                 //height: 600,
                 width: $("#iframeBox").width() + 20,
                 modal: true
             });
         });



    </script>
    <style type="text/css">
        #BoxIframe
        {
            width: 1200px;
            height: 500px;
        }
    </style>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
   <yee:MessageBox ID="msg" runat="server">
    </yee:MessageBox>
    <yee:PageTitle ID="pgTitle" runat="server"></yee:PageTitle>
    <div class="query">
        <table cellpadding="0" cellspacing="0" border="0">
            <tr>
                <td>
                    <%=GetText("重量") %>
                </td>
                <td>
                    <asp:TextBox ID="txtWeightStart" CssClass="sml_input" ClientIDMode="Static" runat="server"></asp:TextBox>
                    -
                    <asp:TextBox ID="txtWeightEnd" CssClass="sml_input" ClientIDMode="Static" runat="server"></asp:TextBox>
                </td>
                <td>
                    <%=GetText("国际订单号") %>
                </td>
                <td>
                    <asp:TextBox ID="txtCTWOrderNo" runat="server"></asp:TextBox>
                </td>
                <td>
                    <%=GetText("状态") %>
                </td>
                <td>
                    <asp:DropDownList ID="ddlCollectStatu" runat="server">
                    </asp:DropDownList>
                </td>
                
                <td>
                    <%=GetText("仓储中心") %>
                </td>
                <td>
                    <yee:UserWarehousesDropDownList ID="ddlTargetWarehouseId" runat="server" WarehouseType="海外仓储">
                    </yee:UserWarehousesDropDownList>
                </td>
            </tr>
            <tr>
                <td>
                    <%=GetText("体积") %>
                </td>
                <td>
                    <asp:TextBox ID="txtVolumeStart" CssClass="sml_input" ClientIDMode="Static" runat="server"></asp:TextBox>
                    -
                    <asp:TextBox ID="txtVolumeEnd" CssClass="sml_input" ClientIDMode="Static" runat="server"></asp:TextBox>
                </td>
                <td>
                    <%=GetText("集包流水") %>
                </td>
                <td>
                    <asp:TextBox ID="txtCollectSerialNo" runat="server"></asp:TextBox>
                </td>
                <td>
                    <%=GetText("运输方式") %>
                </td>
                <td colspan="3">
                   <asp:RadioButtonList ID="rblFreightType" runat="server" RepeatDirection="Horizontal" ></asp:RadioButtonList>
                </td>
               
            </tr>
            <tr>
                 <td>
                    <%=GetText("创建时间") %>
                </td>
                <td>
                    <yee:DatePicker ID="dpFromDate" runat="server" IsRequired="false" />
                    -
                    <yee:DatePicker ID="dpToDate" runat="server" IsRequired="false" />
                </td>
                 <td>
                   <%=GetText("快递单号") %>
                </td>
                <td>
                    <asp:TextBox ID="txtExpressNo" runat="server" ></asp:TextBox>
                </td>
                <td colspan="3">
                    </td>
                <td>
                    <yee:Button ID="btnSearch" runat="server" CssClass="button" Text="搜索" OnClick="btnSearch_Click" />
                </td>
            </tr>
        </table>
    </div>
    <asp:Repeater ID="rptList" runat="server" OnItemCommand="rptList_ItemCommand" OnItemDataBound="rptList_ItemDataBound">
        <HeaderTemplate>
            <table cellpadding="0" cellspacing="0" border="0" class="table">
                <tr>
                    
                    <td class="tbheader" width="100px">
                        <%=GetText("集包流水号") %>
                    </td> 
                    <td class="tbheader" width="150px">
                        <%=GetText("国际订单号") %>
                    </td>
                    <td class="tbheader" width="150px">
                        <%=GetText("发货时间") %>
                    </td>
                    <td class="tbheader">
                        <%=GetText("签收时间") %>
                    </td>
                     <td class="tbheader">
                        <%=GetText("签收人") %>
                    </td>
                    <td class="tbheader">
                        <%=GetText("打木箱费用") %>
                    </td>
                    <td class="tbheader">
                        <%=GetText("签收重量") %>
                    </td>
                    <td class="tbheader">
                        <%=GetText("签收体积") %>
                    </td>
                    <td class="tbheader">
                        <%=GetText("产品数量") %>
                    </td>
                   
                    <td class="tbheader">
                        <%=GetText("操作") %>
                    </td>
                </tr>
        </HeaderTemplate>
        <ItemTemplate>
            <tr class="tbrow">
                
                <td class="tbpost">
                    <%# Eval("CollectSerialNo")%>
                </td>
                 
                <td class="tbpost">
                    <%#Eval("CTWOrderNo")%>
                </td>
                <td class="tbpost">
                    <%# Eval("StockOutOn")%>
                </td>
                <td class="tbpost">
                    <%# Eval("AbroadSignInOn")%>
                </td>
                 <td class="tbpost">
                    <%# Eval("AbroadSignInByName")%>
                </td>
                 <td class="tbpost">
                    <%# Eval("BoxCost")%>
                </td>
                <td class="tbpost">
                    <%# Eval("AbroadSignWeight")%>
                </td>
                <td class="tbpost">
                    <%# Eval("AbroadSignVolume")%>
                </td>
                <td class="tbpost">
                    <%# Eval("TotalQuantity")%>
                </td>
                <td class="tbpost">
                    <asp:LinkButton ID="lbnDetail" runat="server" CommandArgument='<%#Eval("UniqueId")%>'
                        CommandName="Detail" ></asp:LinkButton>
                    
                </td>
            </tr>
        </ItemTemplate>
        <AlternatingItemTemplate>
            <tr class="tbrowalter">
                 
                <td class="tbpost">
                    <%# Eval("CollectSerialNo")%>
                </td>
                 
                <td class="tbpost">
                    <%#Eval("CTWOrderNo")%>
                </td>
                <td class="tbpost">
                    <%# Eval("StockOutOn")%>
                </td>
                <td class="tbpost">
                    <%# Eval("AbroadSignInOn")%>
                </td>
                 <td class="tbpost">
                    <%# Eval("AbroadSignInByName")%>
                </td>
                 <td class="tbpost">
                    <%# Eval("BoxCost")%>
                </td>
                <td class="tbpost">
                    <%# Eval("AbroadSignWeight")%>
                </td>
                <td class="tbpost">
                    <%# Eval("AbroadSignVolume")%>
                </td>
                <td class="tbpost">
                    <%# Eval("TotalQuantity")%>
                </td>
                <td class="tbpost">
                    <asp:LinkButton ID="lbnDetail" runat="server" CommandArgument='<%#Eval("UniqueId")%>'
                        CommandName="Detail" ></asp:LinkButton>
                    
                </td>
            </tr>
        </AlternatingItemTemplate>
        <FooterTemplate>
           
        </FooterTemplate>
    </asp:Repeater>
     <tr>
  
        <td class="tbpost" colspan="5"  style="text-align:right"><%=GetText("合计") %>：</td>
        <td class="tbpost" width="100px"><asp:Literal ID="litTotalWeight" runat="server" ></asp:Literal></td>
        <td class="tbpost"><asp:Literal ID="litTotalVolume" runat="server" ></asp:Literal></td>
        <td class="tbpost"><asp:Literal ID="litTotalProduct" runat="server" ></asp:Literal></td>
        <td class="tbpost"></td>

    </tr>
     </table>
      <yee:Pager ID="Pager1" runat="server" PageSize="20" PagerType="1" OnPageIndex_Changed="Pager1_PageIndex_Changed" />
</asp:Content>
