<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="cmp_KR_cart.ascx.cs" Inherits="NKC_WF.WebUserControls.cmp_KR_cart" %>

<asp:HiddenField id="hfPackListID" runat="server" />
<asp:HiddenField runat="server" ID="hfShowFull" Value="false" />
<asp:GridView ID="grView" runat="server" AutoGenerateColumns="False" DataKeyNames="PackListID,CartID" DataSourceID="ods" Width="100%" CssClass="table table-sm table-striped">
    <Columns>
        <asp:BoundField DataField="CartIndex" HeaderText="#" SortExpression="CartIndex" />
        <asp:BoundField DataField="CartDtmx" HeaderText="Cart" ReadOnly="True" SortExpression="CartDtmx" />
        <asp:BoundField DataField="OrderExtCode" HeaderText="Order" SortExpression="OrderExtCode" />
        <asp:TemplateField HeaderText="Art" SortExpression="FamilyCode">
            <HeaderTemplate>
                <asp:label ID="FCHLabel" runat="server" Text='<%# traduci("FamilyCode") %>' />
            </HeaderTemplate>
            <ItemTemplate>
                <asp:Label ID="FamilyCodeLabel" runat="server" Text='<%# Eval("FamilyCode") %>'></asp:Label>
            </ItemTemplate>
        </asp:TemplateField>
        <asp:BoundField DataField="Started" HeaderText="Started" ReadOnly="True" SortExpression="Started" />
        <asp:BoundField DataField="Completed" HeaderText="Completed" ReadOnly="True" SortExpression="Completed" />
        <asp:TemplateField ShowHeader="False" ItemStyle-Width="2em">
            <HeaderTemplate>
            </HeaderTemplate>
            <ItemTemplate>
                <div class="text-left">
                    <asp:HyperLink runat="server" ID="hlShowDetail" Target="_blank" CssClass="btn btn-info"  NavigateUrl='<%# $"~/site/CartDetIRK?CartID={Eval("CartID")}" %>'><i class="fa fa-list-ol" aria-hidden="true"></i></asp:HyperLink>
                </div>
            </ItemTemplate>

<ItemStyle Width="2em"></ItemStyle>
        </asp:TemplateField>
    </Columns>
</asp:GridView>
<asp:ObjectDataSource ID="ods" runat="server" OldValuesParameterFormatString="original_{0}" SelectMethod="getByPackListId" TypeName="AppData.DS_AppTableAdapters.Pack2CartTableAdapter">
    <SelectParameters>
        <asp:ControlParameter ControlID="hfPackListID" Name="PackListID" PropertyName="Value" Type="Int32" />
    </SelectParameters>
</asp:ObjectDataSource>
