Cambios ExpDetalle

This commit is contained in:
Luis Carlos Quijada
2025-07-04 16:40:21 -06:00
parent 635f757742
commit a6694558fc
2 changed files with 181 additions and 149 deletions

View File

@@ -1,23 +1,22 @@
<%@ Page Title="" Language="C#" MasterPageFile="~/Site.master" AutoEventWireup="true" CodeFile="ExpDetalle.aspx.cs" Inherits="Export_ExpDetalle" %>
<asp:Content ID="Content1" ContentPlaceHolderID="CP" Runat="Server">
<asp:Content ID="Content1" ContentPlaceHolderID="CP" runat="Server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="Css" Runat="Server">
<asp:Content ID="Content2" ContentPlaceHolderID="Css" runat="Server">
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="E" Runat="Server">
Exportación:
<asp:Label runat="server" Text="Exportación" ID="LblExp"></asp:Label>
<asp:Content ID="Content3" ContentPlaceHolderID="E" runat="Server">
<asp:Label runat="server" ID="LblExp"></asp:Label>
</asp:Content>
<asp:Content ID="Content4" ContentPlaceHolderID="HB" Runat="Server">
<asp:Content ID="Content4" ContentPlaceHolderID="HB" runat="Server">
<li id="liImprimir" runat="server">
<asp:LinkButton ID="LBImprimir" runat="server" OnClick="LBImprimir_Click"><i style="font-weight:bold" class="fa fa-file-pdf-o"></i> Exportar PDF</asp:LinkButton>
</li>
</asp:Content>
<asp:Content ID="Content5" ContentPlaceHolderID="H" Runat="Server">
<asp:Content ID="Content5" ContentPlaceHolderID="H" runat="Server">
</asp:Content>
<asp:Content ID="Content6" ContentPlaceHolderID="HA" Runat="Server">
<asp:Content ID="Content6" ContentPlaceHolderID="HA" runat="Server">
</asp:Content>
<asp:Content ID="Content7" ContentPlaceHolderID="C" Runat="Server">
<asp:Content ID="Content7" ContentPlaceHolderID="C" runat="Server">
<div class="whitoutcol" style="width: 100%;">
<div class="portlet light xspadding bordered" style="width: 100%; padding-left: 7px">
<asp:UpdatePanel ID="UpFactura" runat="server">
@@ -41,7 +40,7 @@
</asp:DropDownList>
<asp:RequiredFieldValidator ID="RFVTipoExp" runat="server" ControlToValidate="DdlTipoExp" Display="None" InitialValue="-1" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Tipo Exportación''</b> es necesario, por favor ingréselo." ValidationGroup="GrpGuardar"></asp:RequiredFieldValidator>
<ajax:ValidatorCalloutExtender ID="VCETipoExp" runat="server" HighlightCssClass="vco" TargetControlID="RFVTipoExp" Width="350px"></ajax:ValidatorCalloutExtender>
<label for="<%= DdlTipoExp.ClientID.ToString()%>">Tipo Exportación:</label>
<label id="LblTipoExp" runat="server" for="<%= DdlTipoExp.ClientID.ToString()%>">Tipo Exportación:</label>
</div>
<div class="form-group form-md-line-input input-iconright" style="width: 180px; margin-bottom: 5px;">
<asp:DropDownList ID="DdlExpEstatus" runat="server" CssClass="select2me form-control">
@@ -65,7 +64,7 @@
<div class="form-group form-md-line-input input-iconright" style="width: 150px;">
<asp:TextBox ID="TxtNumPed" CssClass="form-control" runat="server" MaxLength="50"></asp:TextBox>
<ajaxToolkit:MaskedEditExtender ID="meeTxtPedimento" runat="server"
ClearMaskOnLostFocus="false"
ClearMaskOnLostFocus="false"
TargetControlID="TxtNumPed"
Mask="99--99--9999--9999999"
MaskType="Number"
@@ -78,22 +77,22 @@
<tr>
<td align="Center" style="width: 100px">Fecha de Pedimento:</td>
<td align="left" style="width: 100px">
<div class="input-group input-sm input-small date date-picker" data-date-format="dd/mm/yyyy">
<asp:UpdatePanel runat="server">
<ContentTemplate>
<asp:TextBox ID="TxtFechaPedim" runat="server" CssClass="form-control" CausesValidation="true" MaxLength="10" ValidationGroup="GrpGuardar" Width="100px" ClientIDMode="Static"></asp:TextBox>
<ajax:MaskedEditExtender ID="MaskedEditExtender1" runat="server" TargetControlID="TxtFechaPedim" Mask="99/99/9999" MaskType="Date" DisplayMoney="Left" AcceptNegative="Left"></ajax:MaskedEditExtender>
<ajax:CalendarExtender runat="server" ID="CEFechaPedim" TargetControlID="TxtFechaPedim" PopupButtonID="ImgFechaPedim" PopupPosition="BottomRight" Enabled="True"></ajax:CalendarExtender>
<asp:RequiredFieldValidator ID="RFVFechaPedim" runat="server" ControlToValidate="TxtFechaPedim" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Fecha de Pedimento''</b> es necesario, por favor ingréselo." ValidationGroup="GrpGuardar"></asp:RequiredFieldValidator>
<asp:CompareValidator ID="CVFechaPedim" runat="server" ControlToValidate="TxtFechaPedim" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Fecha de Pedimento''</b> no tiene el formato correcto, por favor intente de nuevo con el siguiente formato: (dd/mm/yyyy)." Operator="DataTypeCheck" Type="Date" ValidationGroup="GrpGuardar"></asp:CompareValidator>
<ajax:ValidatorCalloutExtender ID="ValidatorCalloutExtender1" runat="server" HighlightCssClass="vco" TargetControlID="RFVFechaPedim" Width="350px"></ajax:ValidatorCalloutExtender>
<ajax:ValidatorCalloutExtender ID="ValidatorCalloutExtender2" runat="server" HighlightCssClass="vco" TargetControlID="CVFechaPedim" Width="350px"></ajax:ValidatorCalloutExtender>
</ContentTemplate>
</asp:UpdatePanel>
<span class="input-group-btn ">
<asp:LinkButton runat="server" ID="ImgFechaPedim" class="btn default"> <i class="fa fa-calendar"></i> </asp:LinkButton>
</span>
</div>
<div class="input-group input-sm input-small date date-picker" data-date-format="dd/mm/yyyy">
<asp:UpdatePanel runat="server">
<ContentTemplate>
<asp:TextBox ID="TxtFechaPedim" runat="server" CssClass="form-control" CausesValidation="true" MaxLength="10" ValidationGroup="GrpGuardar" Width="100px" ClientIDMode="Static"></asp:TextBox>
<ajax:MaskedEditExtender ID="MaskedEditExtender1" runat="server" TargetControlID="TxtFechaPedim" Mask="99/99/9999" MaskType="Date" DisplayMoney="Left" AcceptNegative="Left"></ajax:MaskedEditExtender>
<ajax:CalendarExtender runat="server" ID="CEFechaPedim" TargetControlID="TxtFechaPedim" PopupButtonID="ImgFechaPedim" PopupPosition="BottomRight" Enabled="True"></ajax:CalendarExtender>
<asp:RequiredFieldValidator ID="RFVFechaPedim" runat="server" ControlToValidate="TxtFechaPedim" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Fecha de Pedimento''</b> es necesario, por favor ingréselo." ValidationGroup="GrpGuardar"></asp:RequiredFieldValidator>
<asp:CompareValidator ID="CVFechaPedim" runat="server" ControlToValidate="TxtFechaPedim" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Fecha de Pedimento''</b> no tiene el formato correcto, por favor intente de nuevo con el siguiente formato: (dd/mm/yyyy)." Operator="DataTypeCheck" Type="Date" ValidationGroup="GrpGuardar"></asp:CompareValidator>
<ajax:ValidatorCalloutExtender ID="ValidatorCalloutExtender1" runat="server" HighlightCssClass="vco" TargetControlID="RFVFechaPedim" Width="350px"></ajax:ValidatorCalloutExtender>
<ajax:ValidatorCalloutExtender ID="ValidatorCalloutExtender2" runat="server" HighlightCssClass="vco" TargetControlID="CVFechaPedim" Width="350px"></ajax:ValidatorCalloutExtender>
</ContentTemplate>
</asp:UpdatePanel>
<span class="input-group-btn ">
<asp:LinkButton runat="server" ID="ImgFechaPedim" class="btn default"> <i class="fa fa-calendar"></i> </asp:LinkButton>
</span>
</div>
</td>
</tr>
</table>
@@ -155,7 +154,7 @@
<a href="javascript:;" class="collapse"></a>
</div>
</div>
<div class="portlet-body form-horizontal form-row-sepe formnombottom" style="padding-left:8px">
<div class="portlet-body form-horizontal form-row-sepe formnombottom" style="padding-left: 8px">
<div class="form-group row" style="width: 100%;">
<asp:Label runat="server" class="col-sm-4" Text="Nombre Exportador:"></asp:Label>
<div class="whitoutcol whitoutcol" style="width: 300px;">
@@ -200,7 +199,7 @@
<a href="javascript:;" class="collapse"></a>
</div>
</div>
<div class="portlet-body form-horizontal form-row-sepe formnombottom" style="padding-left:8px">
<div class="portlet-body form-horizontal form-row-sepe formnombottom" style="padding-left: 8px">
<div class="form-group row" style="width: 100%;">
<asp:Label runat="server" CssClass="col-sm-4" Text="Clave Dir. Exportador:"></asp:Label>
<div class="whitoutcol whitoutcol" style="width: 300px;">
@@ -220,7 +219,7 @@
<div class="form-group row" style="width: 100%;">
<asp:Label runat="server" CssClass="col-sm-4" Text="Vinculación:"></asp:Label>
<div class="form-group form-md-line-input linewhitsize" style="width: 300px;">
<asp:CheckBox ID="CkbVinculacion" runat="server"/>
<asp:CheckBox ID="CkbVinculacion" runat="server" />
<label for="<%= CkbVinculacion.ClientID.ToString()%>"></label>
</div>
</div>
@@ -253,7 +252,7 @@
<a href="javascript:;" class="collapse"></a>
</div>
</div>
<div class="portlet-body form-horizontal form-row-sepe formnombottom" style="padding-left:8px">
<div class="portlet-body form-horizontal form-row-sepe formnombottom" style="padding-left: 8px">
<div class="form-group row" style="width: 100%;">
<asp:Label runat="server" CssClass="col-sm-4" Text="Agente A. Mexicano:"></asp:Label>
<div class="whitoutcol whitoutcol" style="width: 300px;">
@@ -291,7 +290,7 @@
<a href="javascript:;" class="collapse"></a>
</div>
</div>
<div class="portlet-body form-horizontal form-row-sepe formnombottom" style="padding-left:8px">
<div class="portlet-body form-horizontal form-row-sepe formnombottom" style="padding-left: 8px">
<div class="form-group row" style="width: 100%;">
<asp:Label runat="server" CssClass="col-sm-2" Text="Patente:"></asp:Label>
<div class="whitoutcol whitoutcol" style="width: 300px;">
@@ -337,7 +336,7 @@
<a href="javascript:;" class="collapse"></a>
</div>
</div>
<div class="portlet-body form-horizontal form-row-sepe formnombottom" style="padding-left:8px">
<div class="portlet-body form-horizontal form-row-sepe formnombottom" style="padding-left: 8px">
<div class="form-group row" style="width: 100%;">
<asp:Label runat="server" CssClass="col-sm-4" Text="Descripción Contenedor:"></asp:Label>
<div class="whitoutcol whitoutcol" style="width: 300px;">
@@ -390,7 +389,7 @@
<a href="javascript:;" class="collapse"></a>
</div>
</div>
<div class="portlet-body form-horizontal form-row-sepe formnombottom" style="padding-left:8px">
<div class="portlet-body form-horizontal form-row-sepe formnombottom" style="padding-left: 8px">
<div class="form-group row" style="width: 100%;">
<asp:Label runat="server" CssClass="col-sm-3" Text="Medio Transporte:"></asp:Label>
<div class="whitoutcol whitoutcol" style="width: 300px;">
@@ -446,7 +445,7 @@
<a href="javascript:;" class="collapse"></a>
</div>
</div>
<div class="portlet-body form-horizontal form-row-sepe formnombottom" style="padding-left:8px">
<div class="portlet-body form-horizontal form-row-sepe formnombottom" style="padding-left: 8px">
<div class="form-group row" style="width: 100%;">
<div class="col-md-6">
<div class="whitoutcol" style="width: 100%;">
@@ -465,7 +464,7 @@
<a href="javascript:;" class="collapse"></a>
</div>
</div>
<div class="portlet-body form-horizontal form-row-sepe formnombottom" style="padding-left:8px">
<div class="portlet-body form-horizontal form-row-sepe formnombottom" style="padding-left: 8px">
<div class="form-group row" style="width: 100%;">
<asp:Label runat="server" CssClass="col-sm-6" Text="Gastos Transp.:"></asp:Label>
<div class="form-group form-md-line-input linewhitsize col-md-5">
@@ -533,7 +532,7 @@
<a href="javascript:;" class="collapse"></a>
</div>
</div>
<div class="portlet-body form-horizontal form-row-sepe formnombottom" style="padding-left:8px">
<div class="portlet-body form-horizontal form-row-sepe formnombottom" style="padding-left: 8px">
<div class="form-group row" style="width: 100%;">
<asp:Label runat="server" CssClass="col-sm-6" Text="Gastos Transp.:"></asp:Label>
<div class="form-group form-md-line-input linewhitsize col-md-5">
@@ -613,7 +612,7 @@
<ContentTemplate>
<asp:UpdatePanel ID="UpPartidas" runat="server" UpdateMode="Conditional">
<ContentTemplate>
<asp:Button runat="server" ID="BtnAgregarPartida" OnClick="BtnAgregarPartida_Click" Text="Agregar Partida" CssClass="btn btn-primary" style="margin-top: 5px;" />
<asp:Button runat="server" ID="BtnAgregarPartida" OnClick="BtnAgregarPartida_Click" Text="Agregar Partida" CssClass="btn btn-primary" Style="margin-top: 5px;" />
<br />
<br />
<asp:GridView ID="GVPartidas" runat="server" data-sort="true" AutoGenerateColumns="False" DataKeyNames="CveExportacionDetalle" OnRowCommand="GVPartidas_RowCommand" ShowFooter="true" OnRowDataBound="GVPartidas_RowDataBound" Width="100%" EmptyDataText="No se encontraron Partidas" ToolTip="Partidas" CssClass="table table-striped table-advance table-hover Widthall ScrollAD mysmallbtn" GridLines="None">
@@ -638,14 +637,19 @@
<asp:Label ID="lblUM" runat="server" Text='<%# Eval("UnidadMedida")%>'> </asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Valor Total USD" ItemStyle-HorizontalAlign="Left">
<asp:TemplateField HeaderText="Valor Total USD" ItemStyle-HorizontalAlign="Right">
<ItemTemplate>
<asp:Label ID="lblPrecio" runat="server" Text='<%# Eval("Precio", "{0:#,###.####}")%>'> </asp:Label>
<asp:Label ID="lblPrecio" runat="server" Text='<%# Eval("Precio", "{0:N2}")%>'> </asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Valor Total MXP" ItemStyle-HorizontalAlign="Left">
<asp:TemplateField HeaderText="Valor Total MXP" ItemStyle-HorizontalAlign="Right">
<ItemTemplate>
<asp:Label ID="lblValorTotalMXP" runat="server" Text='<%# Eval("ValorTotalMXP", "{0:#,###.####}")%>'> </asp:Label>
<asp:Label ID="lblValorTotalMXP" runat="server" Text='<%# Eval("ValorTotalMXP", "{0:N2}")%>'> </asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Tasa IVA" ItemStyle-HorizontalAlign="Right">
<ItemTemplate>
<asp:Label ID="lblTasaIVA" runat="server" Text='<%# Eval("IVA", "{0:N2}") %>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Total de Empaque" ItemStyle-HorizontalAlign="Left">
@@ -679,14 +683,31 @@
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Editar" ItemStyle-HorizontalAlign="Center" ItemStyle-Width="100px">
<asp:TemplateField HeaderText="Acciones" ItemStyle-HorizontalAlign="Center" ItemStyle-Width="160px">
<ItemTemplate>
<asp:LinkButton data-toggle="tooltip" title="Editar" ID="LnkEditarPartida" CommandName="EditarPartida" CommandArgument='<%# Eval("CveExportacionDetalle") %>' CssClass="btn btn-circle btn-sm green" runat="server" Text="<i class='fa fa-pencil'></i>"></asp:LinkButton>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Eliminar" ItemStyle-HorizontalAlign="Center" ItemStyle-Width="100px">
<ItemTemplate>
<asp:LinkButton ID="LnkEliminarPartida" runat="server" CommandName="EliminarPartida" CommandArgument='<%# Eval("CveExportacionDetalle") %>' CssClass="btn btn-circle btn-sm red" Text="<i class='icon-trash'></i>" data-toggle="confirmation" data-popout="true" data-original-title="¿Está seguro que desea eliminar la Partida?" data-btn-ok-label="Sí" />
<asp:LinkButton
data-toggle="tooltip"
title="Editar"
ID="LnkEditarPartida"
CommandName="EditarPartida"
CommandArgument='<%# Eval("CveExportacionDetalle") %>'
CssClass="btn btn-circle btn-sm green"
runat="server"
Text="<i class='fa fa-pencil'></i>">
</asp:LinkButton>
&nbsp;
<asp:LinkButton
ID="LnkEliminarPartida"
runat="server"
CommandName="EliminarPartida"
CommandArgument='<%# Eval("CveExportacionDetalle") %>'
CssClass="btn btn-circle btn-sm red"
Text="<i class='icon-trash'></i>"
data-toggle="confirmation"
data-popout="true"
data-original-title="¿Está seguro que desea eliminar la Partida?"
data-btn-ok-label="Sí">
</asp:LinkButton>
</ItemTemplate>
</asp:TemplateField>
</Columns>
@@ -710,115 +731,115 @@
</table>
<div id="DModalPartida" class="modal ADS fade" role="dialog">
<asp:UpdatePanel ID="UpPSS" class="modal-dialog" tabindex="-1" runat="server" UpdateMode="Conditional">
<ContentTemplate>
<div class="modal-content">
<div class="modal-header">
<button type="button" class="close" data-dismiss="modal" aria-label="Close">
<span aria-hidden="true">&times;</span>
</button>
<h4 class="modal-title" id="H1" runat="server">Agregar Partida</h4>
</div>
<div id="DVBodyAddProducto" style="overflow: auto!important">
<div class="modal-body">
<asp:UpdatePanel ID="UpBodyAddProducto" UpdateMode="Conditional" runat="server">
<ContentTemplate>
<div class="row">
<div class="col-md-6">
<asp:UpdatePanel ID="UPPClasificacion" runat="server" UpdateMode="Conditional" RenderMode="Inline">
<ContentTemplate>
<div class="form-group form-md-line-input input-iconright">
<asp:DropDownList ID="DdlPS" runat="server" CssClass=" form-control input-sm select2me" AppendDataBoundItems="true" AutoPostBack="true" OnSelectedIndexChanged="DdlPS_SelectedIndexChanged" DataTextField="PSCodigo" DataValueField="CvePS" Width="100%" ValidationGroup="GprAgregaPS"></asp:DropDownList></td>
<label for="<%= DdlPS.ClientID.ToString()%>">Productos / Servicio:</label>
<asp:RequiredFieldValidator ID="RFVDdlPS" runat="server" ControlToValidate="DdlPS" Display="None" InitialValue="-1" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Productos / Servicio''</b> es necesario, por favor ingréselo." ValidationGroup="GprAgregaPS"></asp:RequiredFieldValidator>
<ajax:ValidatorCalloutExtender ID="VCEDdlPS" runat="server" HighlightCssClass="vco" TargetControlID="RFVDdlPS" Width="350px"></ajax:ValidatorCalloutExtender>
</div>
</ContentTemplate>
<Triggers>
<asp:AsyncPostBackTrigger ControlID="DdlPS" EventName="SelectedIndexChanged" />
</Triggers>
</asp:UpdatePanel>
</div>
</div>
<br />
<div class="row">
<div class="col-md-6">
<asp:UpdatePanel ID="UPPUM" runat="server" UpdateMode="Conditional" RenderMode="Inline">
<ContentTemplate>
<div class="form-group form-md-line-input input-iconright">
<asp:DropDownList ID="DdlUM" runat="server" CssClass=" form-control input-sm select2me" AppendDataBoundItems="true" DataTextField="UnidadMedida" DataValueField="CveUnidadMedida" Width="100"></asp:DropDownList></td>
<label for="<%= DdlUM.ClientID.ToString()%>">Unidad de Medida:</label>
</div>
</ContentTemplate>
</asp:UpdatePanel>
</div>
</div>
<br />
<div class="row">
<div class="col-md-6">
<div class="form-group form-md-line-input input-iconright">
<asp:DropDownList ID="DdlPaisOrigen" runat="server" CssClass=" form-control input-sm select2me" AppendDataBoundItems="true" DataTextField="ClaveSATPais" DataValueField="CvePais" Width="100"></asp:DropDownList></td>
<label for="<%= DdlPaisOrigen.ClientID.ToString()%>">País de Origen:</label>
</div>
</div>
</div>
<br />
<div class="row">
<div class="col-md-4">
<div class="form-group form-md-line-input input-iconright">
<asp:TextBox ID="TxtPrecio" ClientIDMode="Static" runat="server" CssClass=" form-control " CausesValidation="true" MaxLength="12" ValidationGroup="GprAgregaPS"></asp:TextBox>
<ajax:FilteredTextBoxExtender ID="SoloNumerosTxtPrecio" runat="server" TargetControlID="TxtPrecio" FilterType="Custom, Numbers" ValidChars="." />
<label for="<%= TxtPrecio.ClientID.ToString()%>">Valor Total USD:</label>
</div>
</div>
</div>
<br />
<div class="row">
<div class="col-md-4">
<div class="form-group form-md-line-input input-iconright">
<asp:TextBox ID="TxtCantidad" ClientIDMode="Static" runat="server" CssClass=" form-control " CausesValidation="true" MaxLength="12" ValidationGroup="GprAgregaPS"></asp:TextBox>
<ajax:FilteredTextBoxExtender ID="FTECantidad" runat="server" TargetControlID="TxtCantidad" FilterType="Custom, Numbers" ValidChars="." />
<label for="<%= TxtCantidad.ClientID.ToString()%>">Cantidad Exportada:</label>
</div>
</div>
<div class="col-md-4">
<div class="form-group form-md-line-input input-iconright">
<asp:TextBox ID="TxtPesoUnitario" ClientIDMode="Static" runat="server" CssClass=" form-control " CausesValidation="true" MaxLength="12" ValidationGroup="GprAgregaPS"></asp:TextBox>
<ajax:FilteredTextBoxExtender ID="FTEPesoUnitario" runat="server" TargetControlID="TxtPesoUnitario" FilterType="Custom, Numbers" ValidChars="." />
<label for="<%= TxtPesoUnitario.ClientID.ToString()%>">Peso Unitario KG:</label>
</div>
</div>
</div>
<div class="row">
<div class="col-md-12">
<div class="form-group form-md-line-input input-iconright" align="right" id="DivAgregarOtraPartida" runat="server">
<label>Continuar agregando:</label>
<asp:CheckBox ID="ChkSeguirAgregandoPartidas" runat="server" Checked="true" />
</div>
</div>
</div>
</ContentTemplate>
</asp:UpdatePanel>
</div>
</div>
<div class="modal-footer">
<asp:UpdatePanel ID="UpAddProductoBotones" runat="server" UpdateMode="Conditional">
<ContentTemplate>
<div class="modal-content">
<div class="modal-header">
<button type="button" class="close" data-dismiss="modal" aria-label="Close">
<span aria-hidden="true">&times;</span>
</button>
<h4 class="modal-title" id="H1" runat="server">Agregar Partida</h4>
</div>
<div id="DVBodyAddProducto" style="overflow: auto!important">
<div class="modal-body">
<asp:UpdatePanel ID="UpBodyAddProducto" UpdateMode="Conditional" runat="server">
<ContentTemplate>
<div class="row">
<div class="col-md-6">
<asp:UpdatePanel ID="UPPClasificacion" runat="server" UpdateMode="Conditional" RenderMode="Inline">
<ContentTemplate>
<div class="form-group form-md-line-input input-iconright">
<asp:DropDownList ID="DdlPS" runat="server" CssClass=" form-control input-sm select2me" AppendDataBoundItems="true" AutoPostBack="true" OnSelectedIndexChanged="DdlPS_SelectedIndexChanged" DataTextField="PSCodigo" DataValueField="CvePS" Width="100%" ValidationGroup="GprAgregaPS"></asp:DropDownList></td>
<label for="<%= DdlPS.ClientID.ToString()%>">Productos / Servicio:</label>
<asp:RequiredFieldValidator ID="RFVDdlPS" runat="server" ControlToValidate="DdlPS" Display="None" InitialValue="-1" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Productos / Servicio''</b> es necesario, por favor ingréselo." ValidationGroup="GprAgregaPS"></asp:RequiredFieldValidator>
<ajax:ValidatorCalloutExtender ID="VCEDdlPS" runat="server" HighlightCssClass="vco" TargetControlID="RFVDdlPS" Width="350px"></ajax:ValidatorCalloutExtender>
</div>
</ContentTemplate>
<Triggers>
<asp:AsyncPostBackTrigger ControlID="DdlPS" EventName="SelectedIndexChanged" />
</Triggers>
</asp:UpdatePanel>
</div>
</div>
<br />
<div class="row">
<div class="col-md-6">
<asp:UpdatePanel ID="UPPUM" runat="server" UpdateMode="Conditional" RenderMode="Inline">
<ContentTemplate>
<div class="form-group form-md-line-input input-iconright">
<asp:DropDownList ID="DdlUM" runat="server" CssClass=" form-control input-sm select2me" AppendDataBoundItems="true" DataTextField="UnidadMedida" DataValueField="CveUnidadMedida" Width="100"></asp:DropDownList></td>
<label for="<%= DdlUM.ClientID.ToString()%>">Unidad de Medida:</label>
</div>
</ContentTemplate>
</asp:UpdatePanel>
</div>
</div>
<br />
<div class="row">
<div class="col-md-6">
<div class="form-group form-md-line-input input-iconright">
<asp:DropDownList ID="DdlPaisOrigen" runat="server" CssClass=" form-control input-sm select2me" AppendDataBoundItems="true" DataTextField="ClaveSATPais" DataValueField="CvePais" Width="100"></asp:DropDownList></td>
<label for="<%= DdlPaisOrigen.ClientID.ToString()%>">País de Origen:</label>
</div>
</div>
</div>
<br />
<div class="row">
<div class="col-md-4">
<div class="form-group form-md-line-input input-iconright">
<asp:TextBox ID="TxtPrecio" ClientIDMode="Static" runat="server" CssClass=" form-control " CausesValidation="true" MaxLength="12" ValidationGroup="GprAgregaPS"></asp:TextBox>
<ajax:FilteredTextBoxExtender ID="SoloNumerosTxtPrecio" runat="server" TargetControlID="TxtPrecio" FilterType="Custom, Numbers" ValidChars="." />
<label for="<%= TxtPrecio.ClientID.ToString()%>">Valor Total USD:</label>
</div>
</div>
</div>
<br />
<div class="row">
<div class="col-md-4">
<div class="form-group form-md-line-input input-iconright">
<asp:TextBox ID="TxtCantidad" ClientIDMode="Static" runat="server" CssClass=" form-control " CausesValidation="true" MaxLength="12" ValidationGroup="GprAgregaPS"></asp:TextBox>
<ajax:FilteredTextBoxExtender ID="FTECantidad" runat="server" TargetControlID="TxtCantidad" FilterType="Custom, Numbers" ValidChars="." />
<label for="<%= TxtCantidad.ClientID.ToString()%>">Cantidad Exportada:</label>
</div>
</div>
<div class="col-md-4">
<div class="form-group form-md-line-input input-iconright">
<asp:TextBox ID="TxtPesoUnitario" ClientIDMode="Static" runat="server" CssClass=" form-control " CausesValidation="true" MaxLength="12" ValidationGroup="GprAgregaPS"></asp:TextBox>
<ajax:FilteredTextBoxExtender ID="FTEPesoUnitario" runat="server" TargetControlID="TxtPesoUnitario" FilterType="Custom, Numbers" ValidChars="." />
<label for="<%= TxtPesoUnitario.ClientID.ToString()%>">Peso Unitario KG:</label>
</div>
</div>
</div>
<div class="row">
<div class="col-md-12">
<asp:Button ID="BtnPartidaGuardar" OnClick="BtnPartidaGuardar_Click" runat="server" Text="Agregar" CssClass="btn btn-primary" ValidationGroup="GprAgregaPS" />
<asp:Button ID="BtnPartidaActualizar" OnClick="BtnPartidaGuardar_Click" runat="server" Text="Actualizar" CssClass="btn btn-primary" ValidationGroup="GprAgregaPS" />
<button type="button" class="btn btn-default" data-dismiss="modal">Cancelar</button>
<div class="form-group form-md-line-input input-iconright" align="right" id="DivAgregarOtraPartida" runat="server">
<label>Continuar agregando:</label>
<asp:CheckBox ID="ChkSeguirAgregandoPartidas" runat="server" Checked="true" />
</div>
</div>
</div>
</ContentTemplate>
</asp:UpdatePanel>
</div>
</div>
</ContentTemplate>
</asp:UpdatePanel>
<div class="modal-footer">
<asp:UpdatePanel ID="UpAddProductoBotones" runat="server" UpdateMode="Conditional">
<ContentTemplate>
<div class="row">
<div class="col-md-12">
<asp:Button ID="BtnPartidaGuardar" OnClick="BtnPartidaGuardar_Click" runat="server" Text="Agregar" CssClass="btn btn-primary" ValidationGroup="GprAgregaPS" />
<asp:Button ID="BtnPartidaActualizar" OnClick="BtnPartidaGuardar_Click" runat="server" Text="Actualizar" CssClass="btn btn-primary" ValidationGroup="GprAgregaPS" />
<button type="button" class="btn btn-default" data-dismiss="modal">Cancelar</button>
</div>
</div>
</ContentTemplate>
</asp:UpdatePanel>
</div>
</div>
</ContentTemplate>
</asp:UpdatePanel>
</div>
</asp:Content>
<asp:Content ID="Content8" ContentPlaceHolderID="JS" Runat="Server">
<asp:Content ID="Content8" ContentPlaceHolderID="JS" runat="Server">
</asp:Content>

View File

@@ -54,6 +54,17 @@ public partial class Export_ExpDetalle : ClsPaginas
EsImportacion = true;
}
LblTipoExp.InnerText = EsImportacion ? "Tipo Importación:" : "Tipo Exportación:";
if (EsImportacion)
{
LblExp.Text = "Importaciones";
}
else
{
LblExp.Text = "Exportación";
}
CveExportacion = !string.IsNullOrEmpty(Request["CveExportacion"]) ? Request["CveExportacion"].ToEntero() : -1;
InicializarValores();
CargaDatos();
@@ -456,7 +467,7 @@ public partial class Export_ExpDetalle : ClsPaginas
}
//string Liga = "document.location.href=\"/Export/RepExportaciones.aspx\";";
string liga = EsImportacion
string liga = EsImportacion
? $"document.location.href=\"/Export/ExpDetalle.aspx?CveExportacion={ExportacionGuardada}&Opcion=I\";"
: $"document.location.href=\"/Export/ExpDetalle.aspx?CveExportacion={ExportacionGuardada}\";";
Alert("La Exportación se ha agregado correctamente.", JSBtnAceptar: liga);