Merge branch 'master' of http://192.168.10.111:8383/SIG
This commit is contained in:
@@ -174,6 +174,8 @@ Partial Class Acumuladores_CatFoliosGarantia
|
||||
|
||||
ObjAcum.Dispose()
|
||||
|
||||
GlobalDTAcumGarantiasTipoUsoMeses(UsuarioActual.CveEmpresa, -1, -1, -1) = Nothing
|
||||
|
||||
End Sub
|
||||
|
||||
Public Sub Remove_ClickFolioGarantia(sender As Object, e As EventArgs)
|
||||
@@ -196,6 +198,8 @@ Partial Class Acumuladores_CatFoliosGarantia
|
||||
|
||||
CveGarantiaMes = -1
|
||||
|
||||
GlobalDTAcumGarantiasTipoUsoMeses(UsuarioActual.CveEmpresa, -1, -1, -1) = Nothing
|
||||
|
||||
End Sub
|
||||
|
||||
Public Sub Edit_ClickFolioGarantia(sender As Object, e As EventArgs)
|
||||
|
||||
@@ -1540,6 +1540,22 @@ Public Class ClsInventarios
|
||||
Return Retorno
|
||||
|
||||
End Function
|
||||
Public Function GetRepResumenMovimientosDiario(Fecha As Date, CveUsuario As Integer, CveEmpresa As Integer) As Boolean
|
||||
Dim retorno As Boolean = False
|
||||
DataAdapter("PA_Inv_RepResumenMovimientosDiarioGet", CommandType.StoredProcedure)
|
||||
With SqlAdapter.SelectCommand.Parameters
|
||||
.Add("@Fecha", SqlDbType.Date).Value = Fecha
|
||||
.Add("@CveUsuario", SqlDbType.Int).Value = CveUsuario
|
||||
.Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa
|
||||
End With
|
||||
Try
|
||||
SqlAdapter.Fill(Data)
|
||||
retorno = True
|
||||
Catch ex As Exception
|
||||
OnError("Ocurrió un error al obtener el reporte de metas por vendedores", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo)
|
||||
End Try
|
||||
Return retorno
|
||||
End Function
|
||||
Public Function GetKardexAlmacen(CvePS As Integer, FechaI As String, FechaF As String, CveAlmacen As Integer, CveUnidadMedida As Integer, CveUsuario As Integer, CveEmpresa As Integer) As Boolean
|
||||
Dim Retorno As Boolean = False
|
||||
|
||||
|
||||
@@ -10424,6 +10424,7 @@ Public Class ClsPaginas
|
||||
PaginaDict.Add("/Inventarios/RepEntregaAlmacenRuta.aspx".ToUpper(), 1319)
|
||||
PaginaDict.Add("/Inventarios/CartaPorteManual.aspx".ToUpper(), 1321)
|
||||
PaginaDict.Add("/Inventarios/EntradasSalidas.aspx?AL=1".ToUpper(), 1334)
|
||||
PaginaDict.Add("/Inventarios/RepResumenMovimientosDiario.aspx".ToUpper(), 896)
|
||||
#End Region
|
||||
#Region "MF"
|
||||
PaginaDict.Add("/MF/BitacoraDiaria.aspx".ToUpper(), 801)
|
||||
|
||||
@@ -415,7 +415,7 @@ Public Class ClsProductosServicios
|
||||
Optional RegistroRSCO As String = "-1", Optional FechaVigenciaRSCO As Date = MinFecha, Optional VigenciaIndeterminadaRSCO As Boolean = False, Optional CveTipoEmpacado As Integer = -1, Optional CveTipoOrganico As Integer = -1,
|
||||
Optional NombreComercial As String = "", Optional NotasAdicionales As String = "", Optional EcommerceEtiquetas As String = "", Optional ActivoEcommerce As Boolean = False, Optional EcommercePrecio As Decimal = 0,
|
||||
Optional CveClasificacionEcommerce As Integer = -1, Optional EcommerceCantidad As Decimal = 0, Optional CodigoAlterno As String = "-1", Optional PSAlterno As String = "-1", Optional ProductoExhibicion As Boolean = False,
|
||||
Optional Imagen As String = "") As Integer
|
||||
Optional Imagen As String = "", Optional PorcentajeMinimoUtilidad As Decimal = 0) As Integer
|
||||
Dim Retorno As Integer = -1
|
||||
|
||||
DataAdapter("PA_ProductosServiciosAdd")
|
||||
@@ -525,6 +525,7 @@ Public Class ClsProductosServicios
|
||||
.Add("@PSAlterno", SqlDbType.VarChar).Value = PSAlterno
|
||||
.Add("@ProductoExhibicion", SqlDbType.Bit).Value = ProductoExhibicion
|
||||
.Add("@Imagen", SqlDbType.VarChar).Value = Imagen
|
||||
.Add("@PorcentajeMinimoUtilidad", SqlDbType.Decimal).Value = PorcentajeMinimoUtilidad
|
||||
End With
|
||||
|
||||
Try
|
||||
@@ -681,7 +682,7 @@ Public Class ClsProductosServicios
|
||||
Optional CveMaterialPeligroso As Integer = -1, Optional CveEmbalaje As Integer = -1, Optional PesoKg As Decimal = -1, Optional Dimensiones As String = "", Optional CveObjetoImpuesto As Integer = 0,
|
||||
Optional RegistroRSCO As String = "-1", Optional FechaVigenciaRSCO As Date = MinFecha, Optional VigenciaIndeterminadaRSCO As Boolean = False, Optional CveTipoEmpacado As Integer = -1, Optional CveTipoOrganico As Integer = -1,
|
||||
Optional NombreComercial As String = "", Optional NotasAdicionales As String = "", Optional EcommerceEtiquetas As String = "", Optional ActivoEcommerce As Boolean = False, Optional EcommercePrecio As Decimal = 0,
|
||||
Optional CveClasificacionEcommerce As Integer = -1, Optional EcommerceCantidad As Decimal = 0, Optional CodigoAlterno As String = "-1", Optional PSAlterno As String = "-1", Optional ProductoExhibicion As Boolean = False, Optional Imagen As String = "") As Boolean
|
||||
Optional CveClasificacionEcommerce As Integer = -1, Optional EcommerceCantidad As Decimal = 0, Optional CodigoAlterno As String = "-1", Optional PSAlterno As String = "-1", Optional ProductoExhibicion As Boolean = False, Optional Imagen As String = "", Optional PorcentajeMinimoUtilidad As Decimal = 0) As Boolean
|
||||
|
||||
Dim Retorno As Boolean = False
|
||||
|
||||
@@ -790,6 +791,7 @@ Public Class ClsProductosServicios
|
||||
.Add("@PSAlterno", SqlDbType.VarChar).Value = PSAlterno
|
||||
.Add("@ProductoExhibicion", SqlDbType.Bit).Value = ProductoExhibicion
|
||||
.Add("@Imagen", SqlDbType.VarChar).Value = Imagen
|
||||
.Add("@PorcentajeMinimoUtilidad", SqlDbType.Decimal).Value = PorcentajeMinimoUtilidad
|
||||
End With
|
||||
|
||||
Try
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
|
||||
.infomov .col-md-1, .infomov .col-md-2, .infomov .col-md-6 {
|
||||
float: left;
|
||||
padding-right: 5px;
|
||||
padding-right: 5px;
|
||||
}
|
||||
|
||||
.infomov .col-md-1 {
|
||||
@@ -74,7 +74,7 @@
|
||||
<li>
|
||||
<asp:HyperLink ID="HplCartaPorte" runat="server" Visible="false"><i class="fa fa-ad-pdf"></i> Descargar Carta Porte</asp:HyperLink>
|
||||
</li>
|
||||
<li>
|
||||
<li>
|
||||
<asp:HyperLink ID="HplCartaPorteTimbre" runat="server" Visible="false"><i class="fa fa-ad-pdf"></i> Descargar Carta Porte Timbrado</asp:HyperLink>
|
||||
</li>
|
||||
<li>
|
||||
@@ -86,7 +86,7 @@
|
||||
</li>
|
||||
<li>
|
||||
<asp:HyperLink ID="HplPrePoliza" Target="_blank" runat="server" Visible="false"> Ver PrePóliza</asp:HyperLink>
|
||||
</li>
|
||||
</li>
|
||||
<li>
|
||||
<asp:LinkButton runat="server" ID="LnkCambioVigencia" Visible="false" CssClass="" data-toggle="tooltip" data-placement="left" OnClick="LnkCambioVigencia_Click"
|
||||
Text="<i class='fa fa-truck'></i> Cambiar Vigencias"></asp:LinkButton>
|
||||
@@ -105,7 +105,7 @@
|
||||
<asp:LinkButton runat="server" ID="LnkGenerarVirtual" Visible="false" CssClass="" data-toggle="tooltip" data-placement="left" OnClick="LnkGenerarVirtual_Click"
|
||||
title="Generar Movimiento Virtual" Text="<i class='fa fa-server'></i> Generar Movimiento Virtual"></asp:LinkButton>
|
||||
</li>
|
||||
<li>
|
||||
<li>
|
||||
<asp:LinkButton runat="server" ID="LnkCambioInventarioFisico" Visible="false" CssClass="" data-toggle="tooltip" data-placement="left" OnClick="LnkCambioInventarioFisico_Click"
|
||||
Text="<i class='fa fa-truck'></i> Inventario Fisico"></asp:LinkButton>
|
||||
</li>
|
||||
@@ -119,7 +119,7 @@
|
||||
<asp:Content ID="Content6" ContentPlaceHolderID="C" runat="Server">
|
||||
<asp:UpdatePanel runat="server">
|
||||
<ContentTemplate>
|
||||
|
||||
|
||||
<div class="row" style="margin-left: 0px; margin-right: 0px;">
|
||||
|
||||
<asp:UpdatePanel ID="UpGenerales" runat="server" UpdateMode="Conditional">
|
||||
@@ -141,26 +141,26 @@
|
||||
<div class="row">
|
||||
<label class="col-md-1 truncate" style="width: 110px">Almacén:</label>
|
||||
<div class="col-md-4">
|
||||
<asp:DropDownList ID="DdlAlmacen" AutoPostBack="true" AppendDataBoundItems="true" OnSelectedIndexChanged="DdlAlmacen_SelectedIndexChanged" runat="server" CssClass="form-control input-sm select2me" DataTextField="Almacen" DataValueField="CveAlmacen"></asp:DropDownList>
|
||||
<asp:DropDownList ID="DdlAlmacen" AutoPostBack="true" AppendDataBoundItems="true" OnSelectedIndexChanged="DdlAlmacen_SelectedIndexChanged" runat="server" CssClass="form-control input-sm select2me" DataTextField="Almacen" DataValueField="CveAlmacen"></asp:DropDownList>
|
||||
<asp:RequiredFieldValidator InitialValue="-1" ID="RfvAlmacen" Display="None" ValidationGroup="GrpGuardar" runat="server" ControlToValidate="DdlAlmacen" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Almacen''</b> es necesario, por favor seleccione uno."></asp:RequiredFieldValidator>
|
||||
<ajax:ValidatorCalloutExtender ID="ValidatorCalloutExtender1" runat="server" HighlightCssClass="vco" TargetControlID="RfvAlmacen" Width="350px"></ajax:ValidatorCalloutExtender>
|
||||
</div>
|
||||
<label class="col-md-1 truncate" style="width: 110px" id="DivConcepto1" runat="server">Concepto:</label>
|
||||
<div class="col-md-4 " id="DivConcepto2" runat="server">
|
||||
<asp:DropDownList ID="DdlConcepto" DataTextField="Concepto" CssClass="form-control input-sm select2me" AutoPostBack="true" DataValueField="CveConcepto" runat="server" ></asp:DropDownList>
|
||||
<asp:DropDownList ID="DdlConcepto" DataTextField="Concepto" CssClass="form-control input-sm select2me" AutoPostBack="true" DataValueField="CveConcepto" runat="server"></asp:DropDownList>
|
||||
<asp:RequiredFieldValidator InitialValue="-1" ID="RfvConcepto" Display="None" ValidationGroup="GrpGuardar" runat="server" ControlToValidate="DdlConcepto" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Concepto''</b> es necesario, por favor seleccione uno."></asp:RequiredFieldValidator>
|
||||
<ajax:ValidatorCalloutExtender ID="VcoConcepto" runat="server" HighlightCssClass="vco" TargetControlID="RfvConcepto" Width="350px"></ajax:ValidatorCalloutExtender>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<label class="col-md-1 truncate" style="width: 110px">Fecha:</label>
|
||||
<div class="col-md-4">
|
||||
|
||||
|
||||
<asp:TextBox ID="TxtFecha" type="datetime-local" runat="server" CssClass="form-control" CausesValidation="true" Style="width: 100%" step="1"></asp:TextBox>
|
||||
|
||||
<%--<div class="input-group input-sm input-small date date-picker " data-date-format="dd/mm/yyyy" style="width: 120px !important; padding: 0px;">
|
||||
|
||||
|
||||
<asp:TextBox ID="TxtFecha" type="datetime-local" runat="server" CssClass="form-control" CausesValidation="true" Style="width: 100%" step="1"></asp:TextBox>
|
||||
|
||||
<%--<div class="input-group input-sm input-small date date-picker " data-date-format="dd/mm/yyyy" style="width: 120px !important; padding: 0px;">
|
||||
<asp:TextBox ID="TxtFecha" runat="server" CssClass="form-control" CausesValidation="true" Style="width: 118px" MaxLength="10"></asp:TextBox>
|
||||
<span class="input-group-btn ">
|
||||
<asp:LinkButton ID="ImgFecha" class="btn default " Text="<i class='fa fa-calendar'></i>" runat="server"></asp:LinkButton>
|
||||
@@ -176,10 +176,9 @@
|
||||
<ajax:ValidatorCalloutExtender ID="VCOFecha3" runat="server" HighlightCssClass="vco" TargetControlID="RVFecha" Width="350px"></ajax:ValidatorCalloutExtender>
|
||||
|
||||
</div>--%>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
<%-- <label class="col-md-1 truncate" style="display: none">Hora:</label>
|
||||
<%-- <label class="col-md-1 truncate" style="display: none">Hora:</label>
|
||||
<div class="col-md-1" style="display:none" >
|
||||
<div style="width: 85px;">
|
||||
<asp:TextBox ID="TxtHora" type="time" runat="server" CssClass="form-control" CausesValidation="true" Style=" padding: 0px 0px 0px 0px; width: 53px" MaxLength="10"></asp:TextBox>
|
||||
@@ -188,7 +187,7 @@
|
||||
|
||||
<label class="col-md-1 truncate" style="width: 110px" id="DivFolio1" runat="server">Folio:</label>
|
||||
<div class="col-md-4" id="DivFolio2" runat="server">
|
||||
<asp:TextBox ID="TxtFolio" runat="server" style="text-align:left;" CssClass="TextBoxAsLabel" Font-Bold="true" Width="110px"></asp:TextBox>
|
||||
<asp:TextBox ID="TxtFolio" runat="server" Style="text-align: left;" CssClass="TextBoxAsLabel" Font-Bold="true" Width="110px"></asp:TextBox>
|
||||
<ajax:FilteredTextBoxExtender ID="SoloNumerosFolio" runat="server" TargetControlID="TxtFolio" FilterType="Numbers" />
|
||||
</div>
|
||||
</div>
|
||||
@@ -200,8 +199,8 @@
|
||||
<asp:Literal ID="LtlAlmacenDestino" runat="server"></asp:Literal>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row" id="DivCliente" runat="server" visible="false">
|
||||
<div >
|
||||
<div class="row" id="DivCliente" runat="server" visible="false">
|
||||
<div>
|
||||
<label class="col-md-1 truncate" style="width: 110px">Cliente:</label>
|
||||
<div class="col-md-4">
|
||||
<asp:DropDownList ID="DdlClientes" AutoPostBack="true" OnSelectedIndexChanged="DdlClientes_SelectedIndexChanged" AppendDataBoundItems="true" runat="server" CssClass="form-control input-sm select2me" DataTextField="NombreComercial" DataValueField="CveCliente"></asp:DropDownList>
|
||||
@@ -219,13 +218,13 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="row" id="DivVendedor" runat="server" visible="false">
|
||||
<label class="col-md-1 truncate" style="width: 110px">Vendedor:</label>
|
||||
<div class="col-md-2">
|
||||
<asp:Label ID="LblVendedor" runat="server" Text=""></asp:Label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="row" id="DivDepartamentoEntrega" runat="server" visible="False">
|
||||
<label class="col-md-1 truncate" style="width: 110px">
|
||||
@@ -252,7 +251,7 @@
|
||||
<div class="col-md-2">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="row" id="divGuia" runat="server" visible="False">
|
||||
<label class="col-md-1 truncate" style="width: 110px">
|
||||
<asp:Label runat="server" ID="LblGuia">Guía:</asp:Label>
|
||||
@@ -260,15 +259,15 @@
|
||||
<div class="col-md-2">
|
||||
<asp:TextBox ID="TxtGuia" runat="server" MaxLength="20" Width="100%"></asp:TextBox>
|
||||
</div>
|
||||
<div class="col-md-6" runat="server" id="TrResponsable">
|
||||
<label class="col-md-1" style="width: 110px">Recibe:</label>
|
||||
<div class="col-md-3">
|
||||
<asp:TextBox runat="server" Text="" ID="TxtResponsable" Width="100%" />
|
||||
<%--<asp:DropDownList ID="DdlResponsable" runat="server" DataTextField="Nombre" DataValueField="CveUsuario" CssClass="form-control input-sm" Style="width: 200px !important;"></asp:DropDownList>--%>
|
||||
</div>
|
||||
<div class="col-md-6" runat="server" id="TrResponsable">
|
||||
<label class="col-md-1" style="width: 110px">Recibe:</label>
|
||||
<div class="col-md-3">
|
||||
<asp:TextBox runat="server" Text="" ID="TxtResponsable" Width="100%" />
|
||||
<%--<asp:DropDownList ID="DdlResponsable" runat="server" DataTextField="Nombre" DataValueField="CveUsuario" CssClass="form-control input-sm" Style="width: 200px !important;"></asp:DropDownList>--%>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="row">
|
||||
<label class="col-md-1 truncate" style="width: 110px">
|
||||
Observaciones:
|
||||
@@ -326,7 +325,7 @@
|
||||
|
||||
</ContentTemplate>
|
||||
</asp:UpdatePanel>
|
||||
|
||||
|
||||
<asp:UpdatePanel runat="server" ID="UpRegistroTipoCambio" UpdateMode="Conditional">
|
||||
<ContentTemplate>
|
||||
<div class="col-md-4">
|
||||
@@ -371,7 +370,7 @@
|
||||
<asp:HyperLink ID="HplPoliza" Target="_blank" runat="server" Visible="False" CssClass="Texto">Ver Póliza</asp:HyperLink>
|
||||
<asp:HyperLink ID="HplOrdenCompra" Target="_blank" runat="server" Visible="False" CssClass="Texto">Ver Orden Compra</asp:HyperLink>
|
||||
<asp:HiddenField ID="HdnCveOrdenCompra" runat="server" />
|
||||
<asp:HiddenField ID="HdnCveCompra" runat="server" />
|
||||
<asp:HiddenField ID="HdnCveCompra" runat="server" />
|
||||
</div>
|
||||
</div>
|
||||
<div class="row" runat="server" id="RowConsignacion" visible="false" style="margin-top: 5px;">
|
||||
@@ -486,136 +485,135 @@
|
||||
|
||||
|
||||
<%--CARTA PORTE INICIO--%>
|
||||
<asp:UpdatePanel ID="UpEmitirTransitorio" runat="server" UpdateMode="Conditional">
|
||||
<ContentTemplate>
|
||||
<div id="DivEmitirTransitorio" class="col-md-3 " runat="server" visible="false">
|
||||
<div class="portlet smmallpadding light bordered infomov">
|
||||
<div class="portlet-title">
|
||||
<div class="caption uppercase" style="position: relative;">
|
||||
<asp:UpdatePanel ID="UpEmitirTransitorio" runat="server" UpdateMode="Conditional">
|
||||
<ContentTemplate>
|
||||
<div id="DivEmitirTransitorio" class="col-md-3 " runat="server" visible="false">
|
||||
<div class="portlet smmallpadding light bordered infomov">
|
||||
<div class="portlet-title">
|
||||
<div class="caption uppercase" style="position: relative;">
|
||||
<i class="fa fa-info-circle"></i>Carta Porte
|
||||
</div>
|
||||
<div class="actions">
|
||||
<div class="btn-group">
|
||||
</div>
|
||||
</div>
|
||||
<div class="actions">
|
||||
<div class="btn-group">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="tools">
|
||||
<a href="javascript:;" class="collapse"></a>
|
||||
</div>
|
||||
</div>
|
||||
<div class="portlet-body ">
|
||||
<div class="rowpadding">
|
||||
<div class="row rowpadding" id="divEmitir" runat="server">
|
||||
<label class="col-md-3">Emitir:</label>
|
||||
<div class="col-md-9">
|
||||
<table>
|
||||
<tr>
|
||||
<td>
|
||||
<asp:CheckBox ID="ChkEmitirTimbrado" runat="server" CssClass="chksino" Text=" " OnCheckedChanged="ChkEmitirTimbrado_CheckedChanged" AutoPostBack="true" />
|
||||
</td>
|
||||
<td>
|
||||
<asp:CheckBox ID="ChkEmitirCartaPorte" runat="server" Text="Carta Porte" Visible="false" /></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row rowpadding">
|
||||
<label class="col-md-3">Chofer:</label>
|
||||
<div class="col-md-9">
|
||||
<asp:DropDownList ID="DdlChofer" runat="server" DataTextField="ChoferLicencia" DataValueField="CveChofer" OnSelectedIndexChanged="DldChofer_SelectedIndexChanged" AutoPostBack="true" CssClass="form-control input-sm select2me" Width="100%"></asp:DropDownList>
|
||||
<asp:RequiredFieldValidator ID="RfvDdlChofer" runat="server" Enabled="false" ControlToValidate="DdlChofer" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Chofer''</b> es necesario, por favor seleccione uno." InitialValue="-1" ValidationGroup="GrpGuardar"></asp:RequiredFieldValidator>
|
||||
<ajax:ValidatorCalloutExtender ID="VceDdlChofer" runat="server" HighlightCssClass="vco" TargetControlID="RfvDdlChofer" Width="350px"></ajax:ValidatorCalloutExtender>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row rowpadding">
|
||||
<label class="col-md-3">Unidad:</label>
|
||||
<div class="col-md-9">
|
||||
<asp:DropDownList runat="server" ID="DdlUnidadCamion" AutoPostBack="true" Width="100%" CssClass="form-control input-sm select2me" DataValueField="CveCamion" DataTextField="CamionPlaca" OnSelectedIndexChanged="DdlUnidadCamionActivoFijo_SelectedIndexChanged"></asp:DropDownList>
|
||||
<asp:RequiredFieldValidator ID="RfvDdlUnidadCamion" runat="server" Enabled="false" ControlToValidate="DdlUnidadCamion" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Unidad''</b> es necesario, por favor seleccione uno." InitialValue="-1" ValidationGroup="GrpGuardar"></asp:RequiredFieldValidator>
|
||||
<ajax:ValidatorCalloutExtender ID="VceDdlUnidadCamion" runat="server" HighlightCssClass="vco" TargetControlID="RfvDdlUnidadCamion" Width="350px"></ajax:ValidatorCalloutExtender>
|
||||
</div>
|
||||
</div>
|
||||
<div class="tools">
|
||||
<a href="javascript:;" class="collapse"></a>
|
||||
</div>
|
||||
</div>
|
||||
<div class="portlet-body ">
|
||||
<div class="rowpadding">
|
||||
<div class="row rowpadding" id="divEmitir" runat="server">
|
||||
<label class="col-md-3">Emitir:</label>
|
||||
<div class="col-md-9">
|
||||
<table>
|
||||
<tr>
|
||||
<td>
|
||||
<asp:CheckBox ID="ChkEmitirTimbrado" runat="server" CssClass="chksino" Text=" " OnCheckedChanged="ChkEmitirTimbrado_CheckedChanged" AutoPostBack="true" />
|
||||
</td>
|
||||
<td>
|
||||
<asp:CheckBox ID="ChkEmitirCartaPorte" runat="server" Text="Carta Porte" Visible="false" /></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row rowpadding">
|
||||
<label class="col-md-3">Chofer:</label>
|
||||
<div class="col-md-9">
|
||||
<asp:DropDownList ID="DdlChofer" runat="server" DataTextField="ChoferLicencia" DataValueField="CveChofer" OnSelectedIndexChanged="DldChofer_SelectedIndexChanged" AutoPostBack="true" CssClass="form-control input-sm select2me" Width="100%"></asp:DropDownList>
|
||||
<asp:RequiredFieldValidator ID="RfvDdlChofer" runat="server" Enabled="false" ControlToValidate="DdlChofer" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Chofer''</b> es necesario, por favor seleccione uno." InitialValue="-1" ValidationGroup="GrpGuardar"></asp:RequiredFieldValidator>
|
||||
<ajax:ValidatorCalloutExtender ID="VceDdlChofer" runat="server" HighlightCssClass="vco" TargetControlID="RfvDdlChofer" Width="350px"></ajax:ValidatorCalloutExtender>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row rowpadding">
|
||||
<label class="col-md-3">Unidad:</label>
|
||||
<div class="col-md-9">
|
||||
<asp:DropDownList runat="server" ID="DdlUnidadCamion" AutoPostBack="true" Width="100%" CssClass="form-control input-sm select2me" DataValueField="CveCamion" DataTextField="CamionPlaca" OnSelectedIndexChanged="DdlUnidadCamionActivoFijo_SelectedIndexChanged"></asp:DropDownList>
|
||||
<asp:RequiredFieldValidator ID="RfvDdlUnidadCamion" runat="server" Enabled="false" ControlToValidate="DdlUnidadCamion" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Unidad''</b> es necesario, por favor seleccione uno." InitialValue="-1" ValidationGroup="GrpGuardar"></asp:RequiredFieldValidator>
|
||||
<ajax:ValidatorCalloutExtender ID="VceDdlUnidadCamion" runat="server" HighlightCssClass="vco" TargetControlID="RfvDdlUnidadCamion" Width="350px"></ajax:ValidatorCalloutExtender>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="row rowpadding" runat="server" id="DvConfiguracionVeiculo" visible="false">
|
||||
<label class="col-md-3">Configuración:</label>
|
||||
<div class="col-md-9">
|
||||
<%--<asp:DropDownList runat="server" ID="DropDownList1" AutoPostBack="true" Width="100%" AppendDataBoundItems="true" CssClass="form-control input-sm select2me" DataValueField="CveActivoFijo" DataTextField="CodigoDescripcion"></asp:DropDownList>--%>
|
||||
<asp:DropDownList ID="DdlConfigAuto" CssClass="form-control input-sm select2me" Width="100%" runat="server" AutoPostBack="true" OnSelectedIndexChanged="DdlConfigAuto_SelectedIndexChanged" CausesValidation="true" DataTextField="ClaveConfigAutoTransporteDescripcion" DataValueField="CveConfigAutoTransporte" Style="padding: 0px">
|
||||
</asp:DropDownList>
|
||||
<asp:RequiredFieldValidator ID="RfvDdlConfigAuto" runat="server" Enabled="false" ControlToValidate="DdlConfigAuto" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Configuración Carta Porte''</b> es necesario, por favor seleccione uno." InitialValue="-1" ValidationGroup="GrpGuardar"></asp:RequiredFieldValidator>
|
||||
<ajax:ValidatorCalloutExtender ID="VCERfvDdlConfigAuto" runat="server" HighlightCssClass="vco" TargetControlID="RfvDdlConfigAuto" Width="350px"></ajax:ValidatorCalloutExtender>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row rowpadding" runat="server" id="DvRemolque1" visible="false">
|
||||
<label class="col-md-3">Remolque 1:</label>
|
||||
<div class="col-md-9">
|
||||
<asp:DropDownList runat="server" ID="DdlRemolque1" AutoPostBack="true" Width="100%" CssClass="form-control input-sm select2me" DataValueField="CveCamion" DataTextField="CamionPlaca" OnSelectedIndexChanged="DdlRemolque1_SelectedIndexChanged"></asp:DropDownList>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row rowpadding" runat="server" id="DvRemolque2" visible="false">
|
||||
<label class="col-md-3">Remolque 2:</label>
|
||||
<div class="col-md-9">
|
||||
<asp:DropDownList runat="server" ID="DdlRemolque2" AutoPostBack="true" Width="100%" CssClass="form-control input-sm select2me" DataValueField="CveCamion" DataTextField="CamionPlaca"></asp:DropDownList>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row rowpadding">
|
||||
<label class="col-md-3">F. Salida:</label>
|
||||
<div class="col-md-9" style="padding-top: 0px;">
|
||||
<div class="input-group input-sm input-small date date-picker" data-date-format="dd/mm/yyyy" style="width: 125px !important;">
|
||||
<asp:TextBox ID="TxtFechaEntrega" runat="server" CssClass="form-control" CausesValidation="true" MaxLength="10" Width="80px" ClientIDMode="Static"></asp:TextBox>
|
||||
<span class="input-group-btn ">
|
||||
<asp:LinkButton runat="server" ID="ImgFechaEntrega" class="btn default"> <i class="fa fa-calendar"></i> </asp:LinkButton>
|
||||
</span>
|
||||
<ajax:MaskedEditExtender ID="MaskedEditExtender2" runat="server" TargetControlID="TxtFechaEntrega" Mask="99/99/9999" MaskType="Date" DisplayMoney="Left" AcceptNegative="Left"></ajax:MaskedEditExtender>
|
||||
<ajax:CalendarExtender runat="server" ID="CalendarExtender2" TargetControlID="TxtFechaEntrega" PopupButtonID="ImgFechaEntrega" PopupPosition="BottomRight" Enabled="True"></ajax:CalendarExtender>
|
||||
<asp:CompareValidator ID="CompareValidator1" runat="server" ControlToValidate="TxtFechaEntrega" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Fecha Entrega''</b> no tiene el formato correcto, por favor intente de nuevo con el siguiente formato: (dd/mm/yyyy)." Operator="DataTypeCheck" Type="Date"></asp:CompareValidator>
|
||||
<ajax:ValidatorCalloutExtender ID="ValidatorCalloutExtender2" runat="server" HighlightCssClass="vco" TargetControlID="CompareValidator1" Width="350px"></ajax:ValidatorCalloutExtender>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row rowpadding" runat="server" id="divFechaLlegada">
|
||||
<label class="col-md-3">F. Llegada:</label>
|
||||
<div class="col-md-4" style="padding-top: 0px;">
|
||||
<div class="input-group input-sm input-small date date-picker" data-date-format="dd/mm/yyyy" style="width: 125px !important;">
|
||||
<asp:TextBox ID="TxtFechaLlegada" runat="server" CssClass="form-control" CausesValidation="true" MaxLength="10" Width="80px" ClientIDMode="Static"></asp:TextBox>
|
||||
<span class="input-group-btn ">
|
||||
<asp:LinkButton runat="server" ID="ImgFechaEnvio" class="btn default"> <i class="fa fa-calendar"></i> </asp:LinkButton>
|
||||
</span>
|
||||
<ajax:MaskedEditExtender ID="MaskedEditExtender3" runat="server" TargetControlID="TxtFechaLlegada" Mask="99/99/9999" MaskType="Date" DisplayMoney="Left" AcceptNegative="Left"></ajax:MaskedEditExtender>
|
||||
<ajax:CalendarExtender runat="server" ID="CalendarExtender3" TargetControlID="TxtFechaLlegada" PopupButtonID="ImgFechaEnvio" PopupPosition="BottomRight" Enabled="True"></ajax:CalendarExtender>
|
||||
<asp:CompareValidator ID="CompareValidator2" runat="server" ControlToValidate="TxtFechaLlegada" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Fecha Envío''</b> no tiene el formato correcto, por favor intente de nuevo con el siguiente formato: (dd/mm/yyyy)." Operator="DataTypeCheck" Type="Date"></asp:CompareValidator>
|
||||
<ajax:ValidatorCalloutExtender ID="ValidatorCalloutExtender5" runat="server" HighlightCssClass="vco" TargetControlID="CompareValidator2" Width="350px"></ajax:ValidatorCalloutExtender>
|
||||
</div>
|
||||
</div>
|
||||
<label class="col-md-1">Dist:</label>
|
||||
<div class="col-md-3">
|
||||
<asp:TextBox ID="TxtDistancia" runat="server" CssClass="form-control input-sm" Width="100%" Text="1"></asp:TextBox>
|
||||
<ajax:TextBoxWatermarkExtender ID="TBWEDistancia" runat="server" TargetControlID="TxtDistancia" WatermarkText="Distancia" WatermarkCssClass="watermarked" />
|
||||
</div>
|
||||
</div>
|
||||
<div class="row rowpadding" >
|
||||
<label class="col-md-3">Cliente:</label>
|
||||
<div class="col-md-9">
|
||||
<%-- <ads:DropDownLost ID="s" AutoPostBack="true" OnSelectedIndexChanged="DdlClienteCarta_SelectedIndexChanged" AppendDataBoundItems="true" runat="server" CssClass="form-control input-sm select2me" DataTextField="NombreComercial" DataValueField="CveCliente"></ads:DropDownLost>--%>
|
||||
<ADS:Dropdownlost CssClassDdl="select2me" ID="DdlClienteCarta" Width="100%" data-metodo="getcliente" Onselectedindexchange="DdlClienteCarta_SelectedIndexChanged" runat="server" DataTextField="NombreComercial" DataValueField="CveCliente" CssStyle="width: 100%;"></ADS:Dropdownlost>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row rowpadding" >
|
||||
<label class="col-md-3">Direccón:</label>
|
||||
<div class="col-md-9">
|
||||
<asp:DropDownList ID="DdlDireccionEnvio" runat="server" CssClass="form-control input-sm select2me" AppendDataBoundItems="true" DataTextField="SucursalClienteVentaDireccion" DataValueField="CveDireccionEnvio" Width="180px" Visible="true" >
|
||||
<asp:ListItem Selected="true" Text="Seleccione" Value="-1"></asp:ListItem>
|
||||
</asp:DropDownList>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</ContentTemplate>
|
||||
</asp:UpdatePanel>
|
||||
<div class="row rowpadding" runat="server" id="DvConfiguracionVeiculo" visible="false">
|
||||
<label class="col-md-3">Configuración:</label>
|
||||
<div class="col-md-9">
|
||||
<%--<asp:DropDownList runat="server" ID="DropDownList1" AutoPostBack="true" Width="100%" AppendDataBoundItems="true" CssClass="form-control input-sm select2me" DataValueField="CveActivoFijo" DataTextField="CodigoDescripcion"></asp:DropDownList>--%>
|
||||
<asp:DropDownList ID="DdlConfigAuto" CssClass="form-control input-sm select2me" Width="100%" runat="server" AutoPostBack="true" OnSelectedIndexChanged="DdlConfigAuto_SelectedIndexChanged" CausesValidation="true" DataTextField="ClaveConfigAutoTransporteDescripcion" DataValueField="CveConfigAutoTransporte" Style="padding: 0px">
|
||||
</asp:DropDownList>
|
||||
<asp:RequiredFieldValidator ID="RfvDdlConfigAuto" runat="server" Enabled="false" ControlToValidate="DdlConfigAuto" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Configuración Carta Porte''</b> es necesario, por favor seleccione uno." InitialValue="-1" ValidationGroup="GrpGuardar"></asp:RequiredFieldValidator>
|
||||
<ajax:ValidatorCalloutExtender ID="VCERfvDdlConfigAuto" runat="server" HighlightCssClass="vco" TargetControlID="RfvDdlConfigAuto" Width="350px"></ajax:ValidatorCalloutExtender>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row rowpadding" runat="server" id="DvRemolque1" visible="false">
|
||||
<label class="col-md-3">Remolque 1:</label>
|
||||
<div class="col-md-9">
|
||||
<asp:DropDownList runat="server" ID="DdlRemolque1" AutoPostBack="true" Width="100%" CssClass="form-control input-sm select2me" DataValueField="CveCamion" DataTextField="CamionPlaca" OnSelectedIndexChanged="DdlRemolque1_SelectedIndexChanged"></asp:DropDownList>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row rowpadding" runat="server" id="DvRemolque2" visible="false">
|
||||
<label class="col-md-3">Remolque 2:</label>
|
||||
<div class="col-md-9">
|
||||
<asp:DropDownList runat="server" ID="DdlRemolque2" AutoPostBack="true" Width="100%" CssClass="form-control input-sm select2me" DataValueField="CveCamion" DataTextField="CamionPlaca"></asp:DropDownList>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row rowpadding">
|
||||
<label class="col-md-3">F. Salida:</label>
|
||||
<div class="col-md-9" style="padding-top: 0px;">
|
||||
<div class="input-group input-sm input-small date date-picker" data-date-format="dd/mm/yyyy" style="width: 125px !important;">
|
||||
<asp:TextBox ID="TxtFechaEntrega" runat="server" CssClass="form-control" CausesValidation="true" MaxLength="10" Width="80px" ClientIDMode="Static"></asp:TextBox>
|
||||
<span class="input-group-btn ">
|
||||
<asp:LinkButton runat="server" ID="ImgFechaEntrega" class="btn default"> <i class="fa fa-calendar"></i> </asp:LinkButton>
|
||||
</span>
|
||||
<ajax:MaskedEditExtender ID="MaskedEditExtender2" runat="server" TargetControlID="TxtFechaEntrega" Mask="99/99/9999" MaskType="Date" DisplayMoney="Left" AcceptNegative="Left"></ajax:MaskedEditExtender>
|
||||
<ajax:CalendarExtender runat="server" ID="CalendarExtender2" TargetControlID="TxtFechaEntrega" PopupButtonID="ImgFechaEntrega" PopupPosition="BottomRight" Enabled="True"></ajax:CalendarExtender>
|
||||
<asp:CompareValidator ID="CompareValidator1" runat="server" ControlToValidate="TxtFechaEntrega" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Fecha Entrega''</b> no tiene el formato correcto, por favor intente de nuevo con el siguiente formato: (dd/mm/yyyy)." Operator="DataTypeCheck" Type="Date"></asp:CompareValidator>
|
||||
<ajax:ValidatorCalloutExtender ID="ValidatorCalloutExtender2" runat="server" HighlightCssClass="vco" TargetControlID="CompareValidator1" Width="350px"></ajax:ValidatorCalloutExtender>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row rowpadding" runat="server" id="divFechaLlegada">
|
||||
<label class="col-md-3">F. Llegada:</label>
|
||||
<div class="col-md-4" style="padding-top: 0px;">
|
||||
<div class="input-group input-sm input-small date date-picker" data-date-format="dd/mm/yyyy" style="width: 125px !important;">
|
||||
<asp:TextBox ID="TxtFechaLlegada" runat="server" CssClass="form-control" CausesValidation="true" MaxLength="10" Width="80px" ClientIDMode="Static"></asp:TextBox>
|
||||
<span class="input-group-btn ">
|
||||
<asp:LinkButton runat="server" ID="ImgFechaEnvio" class="btn default"> <i class="fa fa-calendar"></i> </asp:LinkButton>
|
||||
</span>
|
||||
<ajax:MaskedEditExtender ID="MaskedEditExtender3" runat="server" TargetControlID="TxtFechaLlegada" Mask="99/99/9999" MaskType="Date" DisplayMoney="Left" AcceptNegative="Left"></ajax:MaskedEditExtender>
|
||||
<ajax:CalendarExtender runat="server" ID="CalendarExtender3" TargetControlID="TxtFechaLlegada" PopupButtonID="ImgFechaEnvio" PopupPosition="BottomRight" Enabled="True"></ajax:CalendarExtender>
|
||||
<asp:CompareValidator ID="CompareValidator2" runat="server" ControlToValidate="TxtFechaLlegada" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Fecha Envío''</b> no tiene el formato correcto, por favor intente de nuevo con el siguiente formato: (dd/mm/yyyy)." Operator="DataTypeCheck" Type="Date"></asp:CompareValidator>
|
||||
<ajax:ValidatorCalloutExtender ID="ValidatorCalloutExtender5" runat="server" HighlightCssClass="vco" TargetControlID="CompareValidator2" Width="350px"></ajax:ValidatorCalloutExtender>
|
||||
</div>
|
||||
</div>
|
||||
<label class="col-md-1">Dist:</label>
|
||||
<div class="col-md-3">
|
||||
<asp:TextBox ID="TxtDistancia" runat="server" CssClass="form-control input-sm" Width="100%" Text="1"></asp:TextBox>
|
||||
<ajax:TextBoxWatermarkExtender ID="TBWEDistancia" runat="server" TargetControlID="TxtDistancia" WatermarkText="Distancia" WatermarkCssClass="watermarked" />
|
||||
</div>
|
||||
</div>
|
||||
<div class="row rowpadding">
|
||||
<label class="col-md-3">Cliente:</label>
|
||||
<div class="col-md-9">
|
||||
<%-- <ads:DropDownLost ID="s" AutoPostBack="true" OnSelectedIndexChanged="DdlClienteCarta_SelectedIndexChanged" AppendDataBoundItems="true" runat="server" CssClass="form-control input-sm select2me" DataTextField="NombreComercial" DataValueField="CveCliente"></ads:DropDownLost>--%>
|
||||
<ADS:Dropdownlost CssClassDdl="select2me" ID="DdlClienteCarta" Width="100%" data-metodo="getcliente" Onselectedindexchange="DdlClienteCarta_SelectedIndexChanged" runat="server" DataTextField="NombreComercial" DataValueField="CveCliente" CssStyle="width: 100%;"></ADS:Dropdownlost>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row rowpadding">
|
||||
<label class="col-md-3">Direccón:</label>
|
||||
<div class="col-md-9">
|
||||
<asp:DropDownList ID="DdlDireccionEnvio" runat="server" CssClass="form-control input-sm select2me" AppendDataBoundItems="true" DataTextField="SucursalClienteVentaDireccion" DataValueField="CveDireccionEnvio" Width="180px" Visible="true">
|
||||
<asp:ListItem Selected="true" Text="Seleccione" Value="-1"></asp:ListItem>
|
||||
</asp:DropDownList>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</ContentTemplate>
|
||||
</asp:UpdatePanel>
|
||||
<%--CARTA PORTE FIN--%>
|
||||
|
||||
</div>
|
||||
|
||||
<asp:UpdatePanel runat="server">
|
||||
@@ -635,13 +633,13 @@
|
||||
</div>
|
||||
<br />--%>
|
||||
|
||||
<div class="row">
|
||||
<div class="row">
|
||||
<div class="col-md-10" align="right">
|
||||
<asp:Label ID="LbTotalMovimientos" Text="Total de Movimientos: 0" runat="server" />
|
||||
<input type="text" id="TxtBusqueda" class="form-control input-sm" onkeyup="<%= String.Format("FiltrarTabla('TxtBusqueda','{0}')", GvM.ClientID) %>" style="display: inline-block; margin-right: -20px; width: 150px;" />
|
||||
<a href="javascript:;" onclick="<%= String.Format("FiltrarTabla('TxtBusqueda','{0}')", GvM.ClientID) %>" style="margin-top: -3px;" class="btn btn-circle btn-sm label-info"><i class="icon-magnifier"></i></a>
|
||||
</div>
|
||||
<div class="col-md-2 pull-right" runat="server" id="DivCodigoSeriePS" visible="false">
|
||||
<div class="col-md-2 pull-right" runat="server" id="DivCodigoSeriePS" visible="false">
|
||||
<table style="float: right;">
|
||||
<tr>
|
||||
<td><i class="fa fa-barcode" style="font-size: 1.8em; margin-top: 8px;" aria-hidden="true" data-toggle="tooltip" title="Código Barras"></i></td>
|
||||
@@ -675,8 +673,8 @@
|
||||
<asp:Button ID="BtnVinculaAFEdit" ClientIDMode="Static" OnClick="BtnVinculaAFEdit_Click" Style="display: none;" runat="server" />
|
||||
<asp:HiddenField runat="server" ID="HdnCodAFEdit" Value="-1" ClientIDMode="Static" />
|
||||
|
||||
<asp:GridView ID="GvM" runat="server" GridLines="none" CssClass="table table-striped table-advance table-hover Widthall mysmallbtn" EmptyDataText="Aún no hay registros."
|
||||
DataKeyNames="No,CveMovimientoDetalle,Cantidad,CvePS,CveUM,PU,Observaciones,CodigoPS,UnidadMedida,CveAF,Serie,Lote,FechaCaducidad,CveSeccionAlmacen,Codigo" AutoGenerateColumns="False" AllowPaging="False" ShowFooter="True" >
|
||||
<asp:GridView ID="GvM" runat="server" GridLines="none" CssClass="table table-striped table-advance table-hover Widthall mysmallbtn" EmptyDataText="Aún no hay registros."
|
||||
DataKeyNames="No,CveMovimientoDetalle,Cantidad,CvePS,CveUM,PU,Observaciones,CodigoPS,UnidadMedida,CveAF,Serie,Lote,FechaCaducidad,CveSeccionAlmacen,Codigo" AutoGenerateColumns="False" AllowPaging="False" ShowFooter="True">
|
||||
<Columns>
|
||||
<asp:TemplateField HeaderText="" ItemStyle-Font-Size="6pt">
|
||||
<EditItemTemplate>
|
||||
@@ -742,7 +740,8 @@
|
||||
<asp:Literal ID="LtCI" runat="server" Text='<%# Eval("CostoIndirecto", "{0:N2}")%>'></asp:Literal>
|
||||
</ItemTemplate>
|
||||
<FooterTemplate>
|
||||
<b><asp:Literal ID="LtTotCI" runat="server" Text=""></asp:Literal></b>
|
||||
<b>
|
||||
<asp:Literal ID="LtTotCI" runat="server" Text=""></asp:Literal></b>
|
||||
</FooterTemplate>
|
||||
</asp:TemplateField>
|
||||
<%--<asp:BoundField DataField="CostoIndirecto" DataFormatString="{0:N2}" ItemStyle-HorizontalAlign="Right" Visible="false" ItemStyle-Width="63px"/>--%>
|
||||
@@ -760,13 +759,13 @@
|
||||
</ItemTemplate>
|
||||
<ItemStyle Width="60px" />
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="Serie" Visible="false">
|
||||
<asp:TemplateField HeaderText="Serie" Visible="false">
|
||||
<ItemTemplate>
|
||||
<asp:Literal ID="lbSerie" runat="server" Text='<%# Eval("Serie")%>'></asp:Literal>
|
||||
</ItemTemplate>
|
||||
<ItemStyle></ItemStyle>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="Lote" Visible="false">
|
||||
<asp:TemplateField HeaderText="Lote" Visible="false">
|
||||
<ItemTemplate>
|
||||
<asp:Literal ID="LbLote" runat="server" Text='<%# Eval("Lote")%>'></asp:Literal>
|
||||
</ItemTemplate>
|
||||
@@ -777,31 +776,31 @@
|
||||
<asp:Literal ID="LbCaducidad" runat="server" Text='<%# Eval("FechaCaducidad", "{0:d}") %>'></asp:Literal>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="Sección" Visible="false">
|
||||
<asp:TemplateField HeaderText="Sección" Visible="false">
|
||||
<ItemTemplate>
|
||||
<asp:Literal ID="LbSeccionAlmacen" runat="server" Text='<%# Eval("SeccionAlmacen")%>'></asp:Literal>
|
||||
</ItemTemplate>
|
||||
<ItemStyle Width="90px"></ItemStyle>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="Observaciones">
|
||||
<asp:TemplateField HeaderText="Observaciones">
|
||||
<ItemTemplate>
|
||||
<asp:Literal ID="lblObservaciones" runat="server" Text='<%# Eval("Observaciones")%>'></asp:Literal>
|
||||
</ItemTemplate>
|
||||
<ItemStyle ></ItemStyle>
|
||||
<ItemStyle></ItemStyle>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField>
|
||||
<EditItemTemplate>
|
||||
<div class="row" style="max-width:80px!important">
|
||||
<EditItemTemplate>
|
||||
<div class="row" style="max-width: 80px!important">
|
||||
<div class="col-md-6">
|
||||
<asp:LinkButton ID="imgU" runat="server" AlternateText="Actualizar" CausesValidation="True" CommandName="Update" CssClass="btn btn-circle btn-sm green" Text="<i class='fa fa-check'></i>" ValidationGroup="GrpGV" />
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<asp:LinkButton ID="imgC" runat="server" AlternateText="Cancelar" CausesValidation="False" CommandName="Cancel" CssClass="btn btn-circle btn-sm red" Text="<i class='fa fa-times'></i>" />
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</EditItemTemplate>
|
||||
<ItemTemplate>
|
||||
<asp:LinkButton ID="imgE" runat="server" AlternateText="Editar" CausesValidation="False" OnClick="imgE_Click" CssClass="btn btn-circle btn-sm green" Text="<i class='fa fa-pencil'></i>" />
|
||||
<asp:LinkButton ID="imgE" runat="server" AlternateText="Editar" CausesValidation="False" OnClick="imgE_Click" CssClass="btn btn-circle btn-sm green" Text="<i class='fa fa-pencil'></i>" />
|
||||
<asp:LinkButton ID="lnkRemove" runat="server" AlternateText="Eliminar" OnClick="DeleteRow" CommandArgument='<%# Eval("No")%>' CssClass="btn btn-circle btn-sm red" Text="<i class='icon-trash'></i>" data-toggle="confirmation" data-popout="true" data-original-title="¿Seguro que desea eliminar el concepto?" data-btn-ok-label="si" />
|
||||
<asp:LinkButton ID="lnkDividir" runat="server" AlternateText="Eliminar" OnClick="DividirRow" CommandArgument='<%# Eval("No")%>' Style="font-size: 9px" CssClass="btn btn-circle btn-sm red" Text="<i class='fas fa-chart-pie-alt'></i>" data-toggle="confirmation" data-popout="true" data-original-title="¿Seguro que desea dividir el concepto en unidades?" data-btn-ok-label="si" />
|
||||
</ItemTemplate>
|
||||
@@ -856,9 +855,10 @@
|
||||
</div>
|
||||
<div class="actions">
|
||||
<div class="btn-group">
|
||||
<asp:HyperLink Visible="false" ID="ImgAddObs" CssClass="caption-subject bold font-green" data-toggle="modal" data-target="#ModalBitacora" runat="server" Text=" <i class='fa fa-commenting font-green' ></i><span class='caption-subject bold'>Agregar</span>" Style="font-weight: 700 !important;cursor: pointer;" ToolTip="Observaciones"></asp:HyperLink><br />
|
||||
<asp:HyperLink ID="HlEvento" CssClass="thickbox caption-subject bold font-green" runat="server" Text=" <i class='fa fa-calendar-plus-o font-green' ></i>Agendar" Visible="false" Style="font-weight: 700 !important;cursor: pointer;" ToolTip="Agendar"></asp:HyperLink>
|
||||
<br /><asp:Literal ID="LtlTareaNueva" runat="server"></asp:Literal>
|
||||
<asp:HyperLink Visible="false" ID="ImgAddObs" CssClass="caption-subject bold font-green" data-toggle="modal" data-target="#ModalBitacora" runat="server" Text=" <i class='fa fa-commenting font-green' ></i><span class='caption-subject bold'>Agregar</span>" Style="font-weight: 700 !important; cursor: pointer;" ToolTip="Observaciones"></asp:HyperLink><br />
|
||||
<asp:HyperLink ID="HlEvento" CssClass="thickbox caption-subject bold font-green" runat="server" Text=" <i class='fa fa-calendar-plus-o font-green' ></i>Agendar" Visible="false" Style="font-weight: 700 !important; cursor: pointer;" ToolTip="Agendar"></asp:HyperLink>
|
||||
<br />
|
||||
<asp:Literal ID="LtlTareaNueva" runat="server"></asp:Literal>
|
||||
<UserControl:TareaNueva runat="server" ID="TareaNueva" />
|
||||
<script>
|
||||
function OnAddedTareaNueva() {
|
||||
@@ -1146,42 +1146,39 @@
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<label class="col-md-1 truncate" style="width: 120px">Fecha:</label>
|
||||
<div class="col-md-2">
|
||||
<div style="display: inline-block; vertical-align: text-bottom;">
|
||||
<div class="input-group input-sm input-small date date-picker " data-date-format="dd/mm/yyyy" style="width: 120px !important; padding: 0px; text-align: center">
|
||||
<asp:TextBox ID="TxtFechaInvFisico" runat="server" CssClass="form-control" CausesValidation="true" Style="width: 118px" MaxLength="10"></asp:TextBox>
|
||||
<span class="input-group-btn ">
|
||||
<asp:LinkButton ID="ImgFechaInvFisico" class="btn default " Text="<i class='fa fa-calendar'></i>" runat="server"></asp:LinkButton>
|
||||
</span>
|
||||
<div class="row">
|
||||
<label class="col-md-1 truncate" style="width: 120px">Fecha:</label>
|
||||
<div class="col-md-3">
|
||||
<div style="display: inline-block; vertical-align: text-bottom;">
|
||||
<div class="input-group input-sm input-small date date-picker " data-date-format="dd/mm/yyyy" style="width: 120px !important; padding: 0px; text-align: center">
|
||||
<asp:TextBox ID="TxtFechaInvFisico" runat="server" CssClass="form-control" CausesValidation="true" Style="width: 118px" MaxLength="10"></asp:TextBox>
|
||||
<span class="input-group-btn ">
|
||||
<asp:LinkButton ID="ImgFechaInvFisico" class="btn default " Text="<i class='fa fa-calendar'></i>" runat="server"></asp:LinkButton>
|
||||
</span>
|
||||
<asp:RequiredFieldValidator ID="RFVTxtFechaInvFisico" runat="server" ControlToValidate="TxtFechaInvFisico" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Fecha''</b> es necesario, por favor ingréselo." ValidationGroup="InvFisico"></asp:RequiredFieldValidator>
|
||||
<ajax:ValidatorCalloutExtender ID="CERFVTxtFechaInvFisico" runat="server" HighlightCssClass="vco" TargetControlID="RFVTxtFechaInvFisico" Width="350px"></ajax:ValidatorCalloutExtender>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<asp:RequiredFieldValidator ID="RFVTxtFechaInvFisico" runat="server" ControlToValidate="TxtFechaInvFisico" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Fecha''</b> es necesario, por favor ingréselo." ValidationGroup="InvFisico"></asp:RequiredFieldValidator>
|
||||
<ajax:ValidatorCalloutExtender ID="CERFVTxtFechaInvFisico" runat="server" HighlightCssClass="vco" TargetControlID="RFVTxtFechaInvFisico" Width="350px"></ajax:ValidatorCalloutExtender>
|
||||
|
||||
|
||||
|
||||
<ajax:MaskedEditExtender ID="MEFechaInv" runat="server" TargetControlID="TxtFechaInvFisico" Mask="99/99/9999" MaskType="Date" DisplayMoney="Left" AcceptNegative="Left"></ajax:MaskedEditExtender>
|
||||
<ajax:CalendarExtender runat="server" ID="CalEFehcInv" TargetControlID="TxtFechaInvFisico" PopupButtonID="ImgFechaInvFisico" PopupPosition="BottomRight" Enabled="True"></ajax:CalendarExtender>
|
||||
<asp:CompareValidator ID="CvFechaInv" runat="server" ControlToValidate="TxtFechaInvFisico" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Fecha''</b> no tiene el formato correcto, por favor intente de nuevo con el siguiente formato: (dd/mm/yyyy)." Operator="DataTypeCheck" Type="Date" ValidationGroup="InvFisico"></asp:CompareValidator>
|
||||
<ajax:ValidatorCalloutExtender ID="VCFechaInvFormat" runat="server" HighlightCssClass="vco" TargetControlID="CvFechaInv" Width="350px"></ajax:ValidatorCalloutExtender>
|
||||
<ajax:MaskedEditExtender ID="MEFechaInv" runat="server" TargetControlID="TxtFechaInvFisico" Mask="99/99/9999" MaskType="Date" DisplayMoney="Left" AcceptNegative="Left"></ajax:MaskedEditExtender>
|
||||
<ajax:CalendarExtender runat="server" ID="CalEFehcInv" TargetControlID="TxtFechaInvFisico" PopupButtonID="ImgFechaInvFisico" PopupPosition="BottomRight" Enabled="True"></ajax:CalendarExtender>
|
||||
<asp:CompareValidator ID="CvFechaInv" runat="server" ControlToValidate="TxtFechaInvFisico" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Fecha''</b> no tiene el formato correcto, por favor intente de nuevo con el siguiente formato: (dd/mm/yyyy)." Operator="DataTypeCheck" Type="Date" ValidationGroup="InvFisico"></asp:CompareValidator>
|
||||
<ajax:ValidatorCalloutExtender ID="VCFechaInvFormat" runat="server" HighlightCssClass="vco" TargetControlID="CvFechaInv" Width="350px"></ajax:ValidatorCalloutExtender>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6" style="text-align: center;">
|
||||
<asp:Button ID="BtnModalExcelAjuste" runat="server" Visible="false" CssClass="btn btn-primary" data-toggle="modal" data-target="#DivCargaAjuste" Text="Cargar Excel Ajuste" />
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
<label class="col-md-1 truncate" style="width: 120px">Descripción:</label>
|
||||
<div class="col-md-12">
|
||||
<asp:TextBox ID="TxtIFDescripcion" runat="server" Width="100%" CssClass="form-control input-sm"></asp:TextBox>
|
||||
|
||||
<div class="col-md-6">
|
||||
<div class="row">
|
||||
<label class="col-md-1 truncate" style="width: 120px">Descripción:</label>
|
||||
<div class="col-md-11">
|
||||
<asp:TextBox ID="TxtIFDescripcion" runat="server" Width="100%" CssClass="form-control input-sm"></asp:TextBox>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -1241,7 +1238,7 @@
|
||||
<asp:ListItem Selected="True" Text="Seleccione" Value="-1"></asp:ListItem>
|
||||
</asp:DropDownList>
|
||||
</td>
|
||||
<td runat="server" id="TrSerieEntrada" visible="false" >
|
||||
<td runat="server" id="TrSerieEntrada" visible="false">
|
||||
<asp:TextBox ID="TxtSerieEntrada" runat="server" Width="50px" CssClass="form-control input-sm"></asp:TextBox>
|
||||
</td>
|
||||
<td runat="server" id="TrLoteEntrada" visible="false">
|
||||
@@ -1249,7 +1246,7 @@
|
||||
</td>
|
||||
<td runat="server" id="TrCaducidadEntrada" visible="false">
|
||||
<asp:TextBox ID="TxtCaducidadEntrada" runat="server" Width="80px" CssClass="form-control input-sm"></asp:TextBox>
|
||||
<asp:LinkButton ID="ImgFechaCadEntrada" class="btn default " Text="<i class='fa fa-calendar'></i>" runat="server"></asp:LinkButton>
|
||||
<asp:LinkButton ID="ImgFechaCadEntrada" class="btn default " Text="<i class='fa fa-calendar'></i>" runat="server"></asp:LinkButton>
|
||||
<asp:RequiredFieldValidator ID="RFVFechaCadEntrada" runat="server" ControlToValidate="TxtCaducidadEntrada" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Fecha''</b> es necesario, por favor ingréselo." ValidationGroup="AddPSInvFisico"></asp:RequiredFieldValidator>
|
||||
<ajax:ValidatorCalloutExtender ID="VCFechaCadEntrada" runat="server" HighlightCssClass="vco" TargetControlID="RFVFechaCadEntrada" Width="350px"></ajax:ValidatorCalloutExtender>
|
||||
<ajax:MaskedEditExtender ID="MEEFechaCadEntrada" runat="server" TargetControlID="TxtCaducidadEntrada" Mask="99/99/9999" MaskType="Date" DisplayMoney="Left" AcceptNegative="Left"></ajax:MaskedEditExtender>
|
||||
@@ -1349,7 +1346,7 @@
|
||||
</td>
|
||||
<td runat="server" id="TrCaducidadSalida" visible="false">
|
||||
<asp:TextBox ID="TxtCaducidadSalida" runat="server" Width="75px" CssClass="form-control input-sm"></asp:TextBox>
|
||||
<asp:LinkButton ID="ImgFechaCadSalida" class="btn default input-sm" Text="<i class='fa fa-calendar'></i>" runat="server" ></asp:LinkButton>
|
||||
<asp:LinkButton ID="ImgFechaCadSalida" class="btn default input-sm" Text="<i class='fa fa-calendar'></i>" runat="server"></asp:LinkButton>
|
||||
<asp:RequiredFieldValidator ID="RFVFechaCadSalida" runat="server" ControlToValidate="TxtCaducidadSalida" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Fecha''</b> es necesario, por favor ingréselo." ValidationGroup="AddPSInvFisicoSalida"></asp:RequiredFieldValidator>
|
||||
<ajax:ValidatorCalloutExtender ID="VCFechaCadSalida" runat="server" HighlightCssClass="vco" TargetControlID="RFVFechaCadSalida" Width="350px"></ajax:ValidatorCalloutExtender>
|
||||
<ajax:MaskedEditExtender ID="MEEFechaCadSalida" runat="server" TargetControlID="TxtCaducidadSalida" Mask="99/99/9999" MaskType="Date" DisplayMoney="Left" AcceptNegative="Left"></ajax:MaskedEditExtender>
|
||||
@@ -1442,7 +1439,7 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<br />
|
||||
<div class="row">
|
||||
<label class="col-md-2 truncate" style="width: 120px">Descripción:</label>
|
||||
@@ -1670,12 +1667,12 @@
|
||||
<div runat="server" id="divCantidad" class="form-group form-md-line-input input-iconright">
|
||||
<asp:TextBox ID="txtCantidad" CssClass="form-control" MaxLength="15" runat="server" ValidationGroup="GrpAgregarPS" ClientIDMode="Static" onkeyup="calcularTotal()"></asp:TextBox>
|
||||
<ajax:FilteredTextBoxExtender ID="SoloNumerosCantidad" runat="server" TargetControlID="txtCantidad" FilterType="Custom, Numbers" ValidChars="." />
|
||||
<asp:RequiredFieldValidator ID="RFVCantidad" runat="server" ControlToValidate="txtCantidad" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Cantidad''</b> es necesario, por favor ingréselo."
|
||||
<asp:RequiredFieldValidator ID="RFVCantidad" runat="server" ControlToValidate="txtCantidad" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Cantidad''</b> es necesario, por favor ingréselo."
|
||||
ValidationGroup="GrpAgregarPS"></asp:RequiredFieldValidator>
|
||||
<ajax:ValidatorCalloutExtender ID="VCOCantidad1" runat="server" HighlightCssClass="vco" TargetControlID="RFVCantidad" Width="300px"></ajax:ValidatorCalloutExtender>
|
||||
|
||||
<asp:CustomValidator ID="CVCantidad" runat="server" ClientValidationFunction="ValidaDecimal6digitsM0" ControlToValidate="TxtCantidad" Display="None"
|
||||
ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Cantidad''</b> no tiene el formato correcto (6 decimales) y mayor a cero. Por favor rectifique y vuelva a intentar."
|
||||
|
||||
<asp:CustomValidator ID="CVCantidad" runat="server" ClientValidationFunction="ValidaDecimal6digitsM0" ControlToValidate="TxtCantidad" Display="None"
|
||||
ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Cantidad''</b> no tiene el formato correcto (6 decimales) y mayor a cero. Por favor rectifique y vuelva a intentar."
|
||||
ValidateEmptyText="True" ValidationGroup="GrpAgregarPS"></asp:CustomValidator>
|
||||
|
||||
<ajax:ValidatorCalloutExtender ID="VCECantidad" runat="server" HighlightCssClass="vco" TargetControlID="CVCantidad" Width="300px"></ajax:ValidatorCalloutExtender>
|
||||
@@ -1686,7 +1683,7 @@
|
||||
<div class="col-md-6">
|
||||
<div runat="server" id="divUnidadMedida" class="form-group form-md-line-input input-iconright">
|
||||
<asp:DropDownList ID="DdlUnidad" runat="server" Class="form-control select2me" Style="width: 100px !important;" DataTextField="UnidadMedida" DataValueField="CveUnidadMedida" Width="100%"></asp:DropDownList>
|
||||
<label for="<%= DdlUnidad.ClientID.ToString()%>">U.M.</label>
|
||||
<label for="<%= DdlUnidad.ClientID.ToString()%>">U.M.</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -1696,34 +1693,34 @@
|
||||
|
||||
<div runat="server" id="divClasificacionProducto" class="form-group form-md-line-input input-iconright">
|
||||
<ADS:Dropdownlost runat="server" ID="DdlProducto2" CssClass="form-control select2me" CssStyle="width: 100%;" CssClassDdl="select2me" DataTextField="PSCodigo" DataValueField="CvePS" Width="100%" />
|
||||
<label style="line-height: 0.8" for="<%= DdlProducto2.ClientID.ToString()%>">Producto</label>
|
||||
<label style="line-height: 0.8" for="<%= DdlProducto2.ClientID.ToString()%>">Producto</label>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<div runat="server" id="divPrecio" class="form-group form-md-line-input input-iconright" visible="false">
|
||||
<asp:TextBox ID="txtPrecio" CssClass="form-control " runat="server" Width="50%" Visible="true" ClientIDMode="Static" onkeyup="calcularTotal()" ></asp:TextBox>
|
||||
<asp:TextBox ID="txtPrecio" CssClass="form-control " runat="server" Width="50%" Visible="true" ClientIDMode="Static" onkeyup="calcularTotal()"></asp:TextBox>
|
||||
<ajax:FilteredTextBoxExtender ID="FilteredTextBoxExtender1" runat="server" TargetControlID="txtPrecio" FilterType="Custom" ValidChars=".1234567890" />
|
||||
<asp:RequiredFieldValidator ID="RfvtxtPrecio" runat="server" ControlToValidate="txtPrecio" Display="None"
|
||||
ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Precio unitario''</b> es necesario, por favor ingréselo."
|
||||
ValidationGroup="GrpAgregarPS"></asp:RequiredFieldValidator>
|
||||
<asp:RequiredFieldValidator ID="RfvtxtPrecio" runat="server" ControlToValidate="txtPrecio" Display="None"
|
||||
ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Precio unitario''</b> es necesario, por favor ingréselo."
|
||||
ValidationGroup="GrpAgregarPS"></asp:RequiredFieldValidator>
|
||||
<ajax:ValidatorCalloutExtender ID="VCRfvtxtPrecio" runat="server" HighlightCssClass="vco" TargetControlID="RfvtxtPrecio" Width="300px"></ajax:ValidatorCalloutExtender>
|
||||
|
||||
<label for="<%= txtPrecio.ClientID.ToString()%>">Precio unitario</label>
|
||||
|
||||
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="col-md-6" runat="server" id="divSerie" visible="false">
|
||||
<div class="col-md-6" runat="server" id="divSerie" visible="false">
|
||||
<div class="form-group form-md-line-input input-iconright">
|
||||
<asp:TextBox ID="TxtnSerie" CssClass="form-control " runat="server" Width="120px"></asp:TextBox>
|
||||
<asp:Button Text="" ID="BtnSerieAddNew" OnClick="BtnSerieAddNew_Click" Style="display: none" runat="server" />
|
||||
<label for="<%= TxtnSerie.ClientID.ToString()%>">Serie</label>
|
||||
|
||||
<asp:RequiredFieldValidator ID="RfvTxtnSerie" runat="server" ControlToValidate="TxtnSerie" Display="None"
|
||||
ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Serie''</b> es necesario, por favor ingréselo."
|
||||
|
||||
<asp:RequiredFieldValidator ID="RfvTxtnSerie" runat="server" ControlToValidate="TxtnSerie" Display="None"
|
||||
ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Serie''</b> es necesario, por favor ingréselo."
|
||||
ValidationGroup="GrpAgregarPS"></asp:RequiredFieldValidator>
|
||||
<ajax:ValidatorCalloutExtender ID="VCRfvTxtnSerie" runat="server" HighlightCssClass="vco" TargetControlID="RfvTxtnSerie" Width="300px"></ajax:ValidatorCalloutExtender>
|
||||
|
||||
@@ -1731,7 +1728,7 @@
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6" runat="server" id="divSeccionAlmacen" visible="false">
|
||||
<div class="form-group form-md-line-input input-iconright" >
|
||||
<div class="form-group form-md-line-input input-iconright">
|
||||
<asp:DropDownList ID="DdlSeccionAlmacen" DataTextField="SeccionAlmacen" AppendDataBoundItems="true" DataValueField="CveSeccionAlmacen" Class="form-control input-sm select2me" Style="width: 95% !important" runat="server" CausesValidation="true">
|
||||
<asp:ListItem Selected="True" Text="Seleccione" Value="-1"></asp:ListItem>
|
||||
</asp:DropDownList>
|
||||
@@ -1740,39 +1737,40 @@
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<div class="row">
|
||||
<div class="col-md-6" runat="server" id="divLote" visible="false">
|
||||
<div class="col-md-6" runat="server" id="divLote" visible="false">
|
||||
<div class="form-group form-md-line-input input-iconright">
|
||||
<asp:TextBox ID="TxtnLote" CssClass="form-control" runat="server" Width="120px"></asp:TextBox>
|
||||
|
||||
<asp:RequiredFieldValidator ID="RfvTxtnLote" runat="server" ControlToValidate="TxtnLote" Display="None"
|
||||
ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Serie''</b> es necesario, por favor ingréselo."
|
||||
<asp:RequiredFieldValidator ID="RfvTxtnLote" runat="server" ControlToValidate="TxtnLote" Display="None"
|
||||
ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Serie''</b> es necesario, por favor ingréselo."
|
||||
ValidationGroup="GrpAgregarPS"></asp:RequiredFieldValidator>
|
||||
<ajax:ValidatorCalloutExtender ID="VCRfvTxtnLote" runat="server" HighlightCssClass="vco" TargetControlID="RfvTxtnLote" Width="300px"></ajax:ValidatorCalloutExtender>
|
||||
|
||||
<label for="<%= TxtnLote.ClientID.ToString()%>">Lote</label>
|
||||
<label for="<%= TxtnLote.ClientID.ToString()%>">Lote</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6" runat="server" id="divCaducidad" visible="false">
|
||||
<div class="col-md-6" runat="server" id="divCaducidad" visible="false">
|
||||
|
||||
<div class="form-group form-md-line-input input-iconright date date-picker date date-picker" style="min-width: 135px; margin-top: -10px !important;">
|
||||
<div class="form-group form-md-line-input input-iconright date date-picker date date-picker" style="min-width: 135px; margin-top: -10px !important;">
|
||||
<label for="<%= TxtnFechaCaducidad.ClientID.ToString()%>" style="color: #888888;">Fecha Caducidad: </label>
|
||||
<div class="input-group input-sm input-small date date-picker " data-date-format="dd/mm/yyyy" style="width: 120px !important; padding: 0px; margin-top: -5px !important;">
|
||||
<asp:TextBox ID="TxtnFechaCaducidad" CssClass="form-control" MaxLength="10" runat="server" Width="100px" Height="28px"></asp:TextBox> <span class="input-group-btn ">
|
||||
<asp:LinkButton ID="LnkFechaCaducidad" class="btn default" Text="<i class='fa fa-calendar'></i>" runat="server"></asp:LinkButton>
|
||||
<asp:TextBox ID="TxtnFechaCaducidad" CssClass="form-control" MaxLength="10" runat="server" Width="100px" Height="28px"></asp:TextBox>
|
||||
<span class="input-group-btn ">
|
||||
<asp:LinkButton ID="LnkFechaCaducidad" class="btn default" Text="<i class='fa fa-calendar'></i>" runat="server"></asp:LinkButton>
|
||||
</span>
|
||||
</div>
|
||||
|
||||
|
||||
<ajax:MaskedEditExtender ID="MEEFechaCaducidad" runat="server" TargetControlID="TxtnFechaCaducidad" Mask="99/99/9999" MaskType="Date" DisplayMoney="Left" AcceptNegative="Left"></ajax:MaskedEditExtender>
|
||||
<ajax:CalendarExtender runat="server" ID="CEFechaCaducidad" TargetControlID="TxtnFechaCaducidad" PopupButtonID="LnkFechaCaducidad" PopupPosition="BottomRight" Enabled="True"></ajax:CalendarExtender>
|
||||
<asp:CompareValidator ID="CVFechaCaducidad" runat="server" ControlToValidate="TxtnFechaCaducidad" Display="None"
|
||||
ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Fecha Caducidad''</b> no tiene el formato correcto, por favor intente de nuevo con el siguiente formato: (dd/mm/yyyy)."
|
||||
<asp:CompareValidator ID="CVFechaCaducidad" runat="server" ControlToValidate="TxtnFechaCaducidad" Display="None"
|
||||
ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Fecha Caducidad''</b> no tiene el formato correcto, por favor intente de nuevo con el siguiente formato: (dd/mm/yyyy)."
|
||||
Operator="DataTypeCheck" Type="Date" ValidationGroup="GrpAgregarPS"></asp:CompareValidator>
|
||||
<ajax:ValidatorCalloutExtender ID="VCEFEchaCaducidad" runat="server" HighlightCssClass="vco" TargetControlID="CVFechaCaducidad" Width="350px"></ajax:ValidatorCalloutExtender>
|
||||
<ajax:ValidatorCalloutExtender ID="VCEFEchaCaducidad" runat="server" HighlightCssClass="vco" TargetControlID="CVFechaCaducidad" Width="350px"></ajax:ValidatorCalloutExtender>
|
||||
|
||||
<asp:RequiredFieldValidator ID="RfvTxtnFechaCaducidad" runat="server" ControlToValidate="TxtnFechaCaducidad" Display="None"
|
||||
ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Fecha Caducidad''</b> es necesario, por favor ingréselo."
|
||||
<asp:RequiredFieldValidator ID="RfvTxtnFechaCaducidad" runat="server" ControlToValidate="TxtnFechaCaducidad" Display="None"
|
||||
ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Fecha Caducidad''</b> es necesario, por favor ingréselo."
|
||||
ValidationGroup="GrpAgregarPS"></asp:RequiredFieldValidator>
|
||||
<ajax:ValidatorCalloutExtender ID="VCRfvTxtnFechaCaducidad" runat="server" HighlightCssClass="vco" TargetControlID="RfvTxtnFechaCaducidad" Width="300px"></ajax:ValidatorCalloutExtender>
|
||||
|
||||
@@ -1780,13 +1778,13 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<div class="form-group form-md-line-input input-iconright">
|
||||
<asp:TextBox ID="TxtObservacionesdetalle" CssClass="form-control" runat="server" MaxLength="200"></asp:TextBox>
|
||||
<label for="<%= TxtObservacionesdetalle.ClientID.ToString()%>">Observaciones</label>
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
<div runat="server" id="tdPUExtranjero" class="form-group form-md-line-input input-iconright" visible="false">
|
||||
@@ -1816,7 +1814,7 @@
|
||||
</div>
|
||||
<div runat="server" id="ThTotal" class="form-group form-md-line-input input-iconright" visible="false">
|
||||
<label for="<%= TdTotal.ClientID.ToString()%>">Total</label>
|
||||
<asp:Label ID="TdTotal" runat="server" Visible="false" ClientIDMode="Static"></asp:Label>
|
||||
<asp:Label ID="TdTotal" runat="server" Visible="false" ClientIDMode="Static"></asp:Label>
|
||||
</div>
|
||||
|
||||
<div runat="server" id="DVCultivosCuadro" class="form-group form-md-line-input input-iconright" visible="false">
|
||||
@@ -1831,7 +1829,7 @@
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="col-md-12" style="text-align:right">
|
||||
<div class="col-md-12" style="text-align: right">
|
||||
<asp:CheckBox runat="server" ID="ChkContinuarRegistrando" Checked="true" Text="Seguir Registrando" TextAlign="Left" />
|
||||
</div>
|
||||
</div>
|
||||
@@ -1873,6 +1871,41 @@
|
||||
</asp:UpdatePanel>
|
||||
</div>
|
||||
|
||||
<%--CARGA EXCEL--%>
|
||||
<div id="DivCargaAjuste" class="modal ADS fade" role="dialog">
|
||||
<div class="modal-dialog">
|
||||
<!-- Modal content-->
|
||||
<asp:UpdatePanel class="modal-content" runat="server" ID="UpModalAjuste" UpdateMode="Conditional">
|
||||
<ContentTemplate>
|
||||
<div class="modal-header ">
|
||||
<button type="button" class="close" data-dismiss="modal">×</button>
|
||||
<h4 class="modal-title">Agregar Excel</h4>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
<h3>Arraste o haga click para subir el archivo Excel</h3>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-11" style="margin-left: 30px; margin-right: 30px;">
|
||||
<asp:TextBox ID="TxtExcelAjuste" CssClass="ADSdropzone hidden" Text="" data-maxFile="1" runat="server"></asp:TextBox>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<div class="row">
|
||||
<div class="col-md-10" style="text-align: right">
|
||||
<asp:Button ID="BtnCargaExcelAjuste" runat="server" CssClass="btn btn-success" Text="Aceptar" OnClick="BtnCargaExcelAjuste_Click"></asp:Button>
|
||||
<button type="button" class="btn btn-danger" data-dismiss="modal">Cancelar</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</ContentTemplate>
|
||||
</asp:UpdatePanel>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content7" ContentPlaceHolderID="JS" runat="Server">
|
||||
<script type="text/javascript">
|
||||
@@ -1979,13 +2012,13 @@
|
||||
}
|
||||
$('#<%= GvM.ClientID%>').ADScroll({ 'height': Alto });
|
||||
|
||||
|
||||
|
||||
|
||||
});
|
||||
|
||||
|
||||
|
||||
function ValidaDecimal6digitsM0(val, args) {
|
||||
|
||||
function ValidaDecimal6digitsM0(val, args) {
|
||||
if (args.Value.match(/^(0|[1-9]\d*)(\.\d{1,6})?$/))
|
||||
args.IsValid = true;
|
||||
else
|
||||
|
||||
@@ -4,6 +4,7 @@ Option Strict On
|
||||
Imports System.Data
|
||||
Imports System.IO
|
||||
Imports Extensiones
|
||||
Imports GemBox.Spreadsheet
|
||||
|
||||
Partial Class Inventarios_EntradasSalidas
|
||||
Inherits ClsPaginas
|
||||
@@ -421,6 +422,9 @@ Partial Class Inventarios_EntradasSalidas
|
||||
'ImgFecha.Visible = False
|
||||
End If
|
||||
|
||||
If UsuarioActual.Empresa.Funcionalidad(382) = "1" Then
|
||||
BtnModalExcelAjuste.Visible = True
|
||||
End If
|
||||
|
||||
CantidadTotal = 0
|
||||
IndexSeccionAlmacen = 0
|
||||
@@ -4129,8 +4133,11 @@ Partial Class Inventarios_EntradasSalidas
|
||||
AddPSEntrada(DdlPS.SelectedValue.ToEntero, TxtCantidadInvFisico.Text.ToDouble, TxtCostoPromedio.Text.ToDecimal)
|
||||
End Sub
|
||||
|
||||
Protected Sub AddPSEntrada(CvePS As Integer, Cantidad As Double, CostoPromedio As Double)
|
||||
If DdlAlmacenInventarioFisico.SelectedValue.ToEntero <= 0 Then Alert("Seleccione un almacen", TipoMensaje.MsgAdvertencia) : RegistraScript("playsonidito('142608__autistic-lucario__error.wav')") : DdlPS.SelectedText = "" : Exit Sub
|
||||
Protected Sub AddPSEntrada(CvePS As Integer, Cantidad As Double, CostoPromedio As Double, Optional Sonido As Boolean = True, Optional CargaGV As Boolean = True)
|
||||
|
||||
If Sonido Then
|
||||
If DdlAlmacenInventarioFisico.SelectedValue.ToEntero <= 0 Then Alert("Seleccione un almacen", TipoMensaje.MsgAdvertencia) : RegistraScript("playsonidito('142608__autistic-lucario__error.wav')") : DdlPS.SelectedText = "" : Exit Sub
|
||||
End If
|
||||
|
||||
Dim Valido As Boolean = True
|
||||
|
||||
@@ -4169,8 +4176,15 @@ Partial Class Inventarios_EntradasSalidas
|
||||
registro.Item("FechaCaducidad") = Caducidad
|
||||
|
||||
DtMovimientosEntradaInvFisico.Rows.Add(registro)
|
||||
CargaGvEntradas(DtMovimientosEntradaInvFisico)
|
||||
RegistraScript("playsonidito('beep-07.wav')")
|
||||
|
||||
If CargaGV Then
|
||||
CargaGvEntradas(DtMovimientosEntradaInvFisico)
|
||||
End If
|
||||
|
||||
If Sonido Then
|
||||
RegistraScript("playsonidito('beep-07.wav')")
|
||||
End If
|
||||
|
||||
End If
|
||||
End Sub
|
||||
|
||||
@@ -4267,8 +4281,10 @@ Partial Class Inventarios_EntradasSalidas
|
||||
|
||||
End Sub
|
||||
|
||||
Protected Sub AddPSSalida(CvePS As Integer, Cantidad As Double)
|
||||
If DdlAlmacenInventarioFisico.SelectedValue.ToEntero <= 0 Then Alert("Seleccione un almacen", TipoMensaje.MsgAdvertencia) : RegistraScript("playsonidito('142608__autistic-lucario__error.wav')") : DdlPSSalida.SelectedText = "" : Exit Sub
|
||||
Protected Sub AddPSSalida(CvePS As Integer, Cantidad As Double, Optional Sonido As Boolean = True, Optional CargaGV As Boolean = True)
|
||||
If Sonido Then
|
||||
If DdlAlmacenInventarioFisico.SelectedValue.ToEntero <= 0 Then Alert("Seleccione un almacen", TipoMensaje.MsgAdvertencia) : RegistraScript("playsonidito('142608__autistic-lucario__error.wav')") : DdlPSSalida.SelectedText = "" : Exit Sub
|
||||
End If
|
||||
|
||||
Dim Valido As Boolean = True
|
||||
|
||||
@@ -4307,8 +4323,15 @@ Partial Class Inventarios_EntradasSalidas
|
||||
registro.Item("FechaCaducidad") = Caducidad
|
||||
|
||||
DtMovimientosSalidaInvFisico.Rows.Add(registro)
|
||||
CargaGvSalidas(DtMovimientosSalidaInvFisico)
|
||||
RegistraScript("playsonidito('beep-07.wav')")
|
||||
|
||||
If CargaGV Then
|
||||
CargaGvSalidas(DtMovimientosSalidaInvFisico)
|
||||
End If
|
||||
|
||||
If Sonido Then
|
||||
RegistraScript("playsonidito('beep-07.wav')")
|
||||
End If
|
||||
|
||||
End If
|
||||
End Sub
|
||||
|
||||
@@ -6054,8 +6077,87 @@ Partial Class Inventarios_EntradasSalidas
|
||||
Public Property TieneError As Boolean
|
||||
End Class
|
||||
|
||||
Protected Sub BtnCargaExcelAjuste_Click(sender As Object, e As EventArgs)
|
||||
If TxtExcelAjuste.getfiles().Archivos.Count > 0 Then
|
||||
Dim file As Archivo = TxtExcelAjuste.getfiles().Archivos(0)
|
||||
Dim Directorio As String = AppDomain.CurrentDomain.BaseDirectory & file.path
|
||||
CargarArchivo(Directorio, file.filename)
|
||||
Else
|
||||
Alert("No existe el archivo. Favor de subir un archivo excel a la plataforma.", TipoMensaje.MsgError)
|
||||
End If
|
||||
End Sub
|
||||
|
||||
Private Sub CargarArchivo(Ruta As String, FileName As String)
|
||||
SpreadsheetInfo.SetLicense(ModExtensiones.SerialGemBoxSpreadsheet)
|
||||
Dim Tipo As String = "EXCEL"
|
||||
Dim dt As DataTable = Nothing
|
||||
Dim ErrorArchivo As Boolean = False
|
||||
|
||||
Try
|
||||
dt = ReadExcelFile(Ruta + FileName, True)
|
||||
Catch ex As Exception
|
||||
ErrorArchivo = True
|
||||
OnError("Ocurrio un error al leer el archivo <br/>" & ex.Message, ex)
|
||||
End Try
|
||||
|
||||
If Not ErrorArchivo AndAlso dt IsNot Nothing Then
|
||||
|
||||
dt.TableName = "Datos"
|
||||
|
||||
Dim TieneError As Boolean = False
|
||||
Try
|
||||
If DdlAlmacenInventarioFisico.SelectedValue.ToEntero <= 0 Then Alert("Seleccione un almacen", TipoMensaje.MsgAdvertencia) : RegistraScript("playsonidito('142608__autistic-lucario__error.wav')") : DdlPS.SelectedText = "" : Exit Sub
|
||||
|
||||
For Each row As DataRow In dt.Rows
|
||||
Dim DrPS As DataRow = GlobalDTPSSimplificado(UsuarioActual.CveEmpresa, Codigo:=row("Codigo").ToString(), Estatus:=-1).FiltroPrimero("")
|
||||
Dim CvePS As Integer = DrPS("CvePS").ToString().ToEntero()
|
||||
|
||||
If row("EntradaSalida").ToString() = "1" Then
|
||||
AddPSEntrada(CvePS, row("Diferencia").ToString().ToDecimal(), row("Costo").ToString().ToDecimal(), Sonido:=False, CargaGV:=False)
|
||||
Else
|
||||
AddPSSalida(CvePS, row("Diferencia").ToString().ToDecimal(), Sonido:=False, CargaGV:=False)
|
||||
End If
|
||||
|
||||
Next
|
||||
|
||||
CargaGvSalidas(DtMovimientosSalidaInvFisico)
|
||||
CargaGvEntradas(DtMovimientosEntradaInvFisico)
|
||||
Catch ex As Exception
|
||||
TieneError = True
|
||||
OnError("Ocurrió un error al cargar los precios.", ex)
|
||||
Finally
|
||||
|
||||
If TieneError Then
|
||||
If DtMovimientosEntradaInvFisico IsNot Nothing Then
|
||||
DtMovimientosEntradaInvFisico.Clear()
|
||||
End If
|
||||
If DtMovimientosSalidaInvFisico IsNot Nothing Then
|
||||
DtMovimientosSalidaInvFisico.Clear()
|
||||
End If
|
||||
|
||||
CargaGvSalidas(DtMovimientosSalidaInvFisico)
|
||||
CargaGvEntradas(DtMovimientosEntradaInvFisico)
|
||||
|
||||
Alert("Ocurrió un error al cargar los datos", TipoMensaje.MsgError)
|
||||
Else
|
||||
If DtMovimientosEntradaInvFisico.Rows.Count <> dt.FiltraParametros("EntradaSalida = 1").Rows.Count Then
|
||||
Alert("No se cargaron todas las entradas.", TipoMensaje.MsgAdvertencia)
|
||||
Else
|
||||
If DtMovimientosSalidaInvFisico.Rows.Count <> dt.FiltraParametros("EntradaSalida = 0").Rows.Count Then
|
||||
Alert("No se cargaron todas las salidas.", TipoMensaje.MsgAdvertencia)
|
||||
Else
|
||||
Alert("Los datos se cargaron correctamente.")
|
||||
End If
|
||||
End If
|
||||
|
||||
RegistraScript("$('#DivCargaAjuste').modal('hide')")
|
||||
End If
|
||||
|
||||
|
||||
End Try
|
||||
|
||||
End If
|
||||
|
||||
UpModalAjuste.Update()
|
||||
End Sub
|
||||
End Class
|
||||
|
||||
@@ -437,6 +437,7 @@
|
||||
<asp:HyperLink ID="hlFolio" runat="server" Text='<%# Eval("Folio")%>' CssClass="Texto" NavigateUrl='<%# Eval("CveMovimiento", "/Inventarios/EntradasSalidas.aspx?CveMovimiento={0}")%>' Target="_blank" />
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:BoundField DataField="AlmacenDestino" HeaderText="A.Destino" ItemStyle-HorizontalAlign="Left" ItemStyle-Width="120px" />
|
||||
<asp:TemplateField ItemStyle-HorizontalAlign="Left" HeaderText="Folio Doc.">
|
||||
<ItemTemplate>
|
||||
<asp:HyperLink runat="server" Target="_blank" ID="hlFolioD" Text='<%# Eval("FolioDocto")%>' CssClass="Texto" />
|
||||
|
||||
@@ -79,11 +79,11 @@ Partial Class Inventarios_Kardex
|
||||
Private Sub CargaPermisos()
|
||||
If UsuarioActual.CveRol = 1 Then ChkAgruparAlmacen.Visible = True
|
||||
Dim TienePermisoImportes As Boolean = UsuarioActual.TienePermisoProceso(201)
|
||||
GvM.Columns(14).Visible = TienePermisoImportes ' costo
|
||||
GvM.Columns(15).Visible = TienePermisoImportes ' importe
|
||||
GvM.Columns(17).Visible = TienePermisoImportes ' valor
|
||||
GvM.Columns(15).Visible = TienePermisoImportes ' costo
|
||||
GvM.Columns(16).Visible = TienePermisoImportes ' importe
|
||||
GvM.Columns(18).Visible = TienePermisoImportes ' valor
|
||||
|
||||
GvM.Columns(18).Visible = UsuarioActual.CveEmpresa = 172 AndAlso UsuarioActual.CveRol = 1
|
||||
GvM.Columns(19).Visible = UsuarioActual.CveEmpresa = 172 AndAlso UsuarioActual.CveRol = 1
|
||||
|
||||
If UsuarioActual.Empresa.Funcionalidad(574).ToEntero = 1 Then
|
||||
DVFiltroCodigo.Visible = True
|
||||
@@ -259,19 +259,21 @@ Partial Class Inventarios_Kardex
|
||||
|
||||
If DtTemp IsNot Nothing AndAlso DtTemp.Rows.Count > 0 Then
|
||||
|
||||
Dim AplicaSeccion, AplicaLote, AplicaCaducidad, AplicaSerie As Boolean
|
||||
Dim AplicaSeccion, AplicaLote, AplicaCaducidad, AplicaSerie, AplicaAlmacenDestino As Boolean
|
||||
AplicaSerie = DtTemp.MAX("Serie") <> ""
|
||||
AplicaSeccion = DtTemp.MAX("SeccionAlmacen") <> ""
|
||||
AplicaLote = DtTemp.MAX("Lote") <> ""
|
||||
AplicaCaducidad = DtTemp.MAX("FechaCaducidad") <> ""
|
||||
AplicaAlmacenDestino = DtTemp.MAX("AlmacenDestino") <> "" AndAlso UsuarioActual.Empresa.Funcionalidad(382) = "1"
|
||||
|
||||
GvM.Columns(6).Visible = DtTemp.MAX("FolioRelacionEntrada") <> ""
|
||||
GvM.Columns(5).Visible = AplicaAlmacenDestino
|
||||
GvM.Columns(7).Visible = DtTemp.MAX("FolioRelacionEntrada") <> ""
|
||||
|
||||
If AplicaSeccion Then GvM.Columns(8).Visible = True
|
||||
If AplicaSerie Then GvM.Columns(9).Visible = True
|
||||
If AplicaLote Then GvM.Columns(10).Visible = True
|
||||
If AplicaCaducidad Then GvM.Columns(11).Visible = True
|
||||
If Not String.IsNullOrWhiteSpace(UsuarioActual.Empresa.Funcionalidad(147)) Then GvM.Columns(11).HeaderText = UsuarioActual.Empresa.Funcionalidad(147)
|
||||
If AplicaSeccion Then GvM.Columns(9).Visible = True
|
||||
If AplicaSerie Then GvM.Columns(10).Visible = True
|
||||
If AplicaLote Then GvM.Columns(11).Visible = True
|
||||
If AplicaCaducidad Then GvM.Columns(12).Visible = True
|
||||
If Not String.IsNullOrWhiteSpace(UsuarioActual.Empresa.Funcionalidad(147)) Then GvM.Columns(12).HeaderText = UsuarioActual.Empresa.Funcionalidad(147)
|
||||
|
||||
|
||||
Dim Drp As DataRow = GlobalDTPS(UsuarioActual.CveEmpresa, CvePS:=CveProducto).FiltroPrimero("")
|
||||
@@ -480,7 +482,7 @@ Partial Class Inventarios_Kardex
|
||||
Private Sub GenerarPDF(Optional Formato As String = "PDF")
|
||||
If GvM.Rows.Count > 0 Then
|
||||
If ddlProducto2.SelectedValue.ToEntero > 0 Then
|
||||
Dim Movimientos As New ClsInventarios
|
||||
|
||||
Dim CvePS As Integer = ddlProducto2.SelectedValue.ToEntero
|
||||
Dim Entrada As Boolean = cbEntrada.Checked
|
||||
Dim Salida As Boolean = cbSalida.Checked
|
||||
@@ -523,12 +525,20 @@ Partial Class Inventarios_Kardex
|
||||
Dim Serie As String = If(TxtSerie.Text <> "", TxtSerie.Text, "-1")
|
||||
|
||||
Dim SerieAgrupado As String = If(TxtSerie.Text = "", "", $"<b>Existencia y costos calculada por numero de serie:</b> {TxtSerie.Text} ")
|
||||
Dim dt As DataTable = Nothing
|
||||
|
||||
If Movimientos.GetKardex(Entrada, Salida, CvePS, FechaI, FechaF, CveAlmacen, CveTiposAlmacen.Substring(0, CveTiposAlmacen.Length - 1), DdlUnidadMedida.SelectedValue.ToEntero, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, ChkAgruparAlmacen.Checked, Serie, CveAlmacenes) Then
|
||||
Using ObjInv As New ClsInventarios
|
||||
If ObjInv.GetKardex(Entrada, Salida, CvePS, FechaI, FechaF, CveAlmacen, CveTiposAlmacen.Substring(0, CveTiposAlmacen.Length - 1), DdlUnidadMedida.SelectedValue.ToEntero, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, ChkAgruparAlmacen.Checked, Serie, CveAlmacenes) Then
|
||||
dt = ObjInv.DtResultados.Copy()
|
||||
Else
|
||||
Alert("No hay datos consultados", TipoMensaje.MsgAdvertencia)
|
||||
End If
|
||||
End Using
|
||||
|
||||
If dt IsNot Nothing Then
|
||||
Dim Imagen As New System.IO.FileInfo($"{UsuarioActual.Empresa.Ruta}/Logo.png")
|
||||
Dim logouri = String.Format("{0}://{1}:{2}/Empresas/{3}/Logo.png", Request.Url.Scheme, Request.Url.Host, Request.Url.Port, UsuarioActual.CveEmpresa)
|
||||
Dim dt As DataTable = Movimientos.DtResultados
|
||||
|
||||
Dim params As New List(Of ReportParameter)
|
||||
params.Add(New ReportParameter("NombreEmpresa", UsuarioActual.Empresa.Empresa))
|
||||
params.Add(New ReportParameter("FechaInicio", FechaI))
|
||||
@@ -541,9 +551,8 @@ Partial Class Inventarios_Kardex
|
||||
params.Add(New ReportParameter("LogoPath", If(Imagen.Exists, $"file://{Imagen.FullName}", "")))
|
||||
params.Add(New ReportParameter("OcultarImportes", UsuarioActual.TienePermisoProceso(201).ToString))
|
||||
ImprimirPDF("Empresas/Grales/Formatos/RepKardex.rdlc", dt, params, "ReporteKardex", Formato)
|
||||
Else
|
||||
Alert("No hay datos consultados", TipoMensaje.MsgAdvertencia)
|
||||
End If
|
||||
|
||||
Else
|
||||
Alert("Debes seleccionar un Producto/Servicio", TipoMensaje.MsgAdvertencia)
|
||||
End If
|
||||
|
||||
@@ -75,10 +75,10 @@
|
||||
Reporte de Inventario Fisico
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content5" ContentPlaceHolderID="H" runat="Server">
|
||||
|
||||
|
||||
|
||||
<asp:UpdatePanel runat="server" id="UPAcciones" UpdateMode="Conditional">
|
||||
|
||||
|
||||
<asp:UpdatePanel runat="server" ID="UPAcciones" UpdateMode="Conditional">
|
||||
<ContentTemplate>
|
||||
|
||||
|
||||
@@ -95,6 +95,16 @@
|
||||
<li>
|
||||
<asp:LinkButton ID="ImgExcelProdcutosCoinciden" runat="server"><i class="fa fa-ad-excel"></i> Exporta a Excel Productos Coincidentes</asp:LinkButton>
|
||||
</li>
|
||||
<asp:UpdatePanel ID="UpExportarExcel" runat="server">
|
||||
<ContentTemplate>
|
||||
<li>
|
||||
<asp:LinkButton ID="LnkExportarFormatoAjuste" runat="server" Visible="false"><i class="fa fa-ad-excel"></i> Generar formato para ajuste</asp:LinkButton>
|
||||
</li>
|
||||
</ContentTemplate>
|
||||
<Triggers>
|
||||
<asp:PostBackTrigger ControlID="LnkExportarFormatoAjuste" />
|
||||
</Triggers>
|
||||
</asp:UpdatePanel>
|
||||
<li>
|
||||
<asp:LinkButton ID="LnkDescarExcelGrupos" runat="server"><i class="fa fa-ad-excel"></i> Exporta a Excel </asp:LinkButton>
|
||||
</li>
|
||||
@@ -110,17 +120,17 @@
|
||||
</ContentTemplate>
|
||||
<Triggers>
|
||||
<asp:AsyncPostBackTrigger ControlID="btnFin" />
|
||||
<asp:PostBackTrigger ControlID="LnkPDF" />
|
||||
<asp:PostBackTrigger ControlID="ImgExcel" />
|
||||
<asp:PostBackTrigger ControlID="ImgExcel2" />
|
||||
<asp:PostBackTrigger ControlID="ImgExcelProdcutosCoinciden" />
|
||||
<asp:PostBackTrigger ControlID="LnkDescarExcelGrupos" />
|
||||
<asp:PostBackTrigger ControlID="LnkPDF" />
|
||||
<asp:PostBackTrigger ControlID="ImgExcel" />
|
||||
<asp:PostBackTrigger ControlID="ImgExcel2" />
|
||||
<asp:PostBackTrigger ControlID="ImgExcelProdcutosCoinciden" />
|
||||
<asp:PostBackTrigger ControlID="LnkDescarExcelGrupos" />
|
||||
</Triggers>
|
||||
</asp:UpdatePanel>
|
||||
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content6" ContentPlaceHolderID="C" runat="Server">
|
||||
<asp:UpdatePanel ID="UpFiltros" runat="server" RenderMode="Inline" ViewStateMode="Inherit" UpdateMode="Conditional">
|
||||
<asp:UpdatePanel ID="UpFiltros" runat="server" RenderMode="Inline" ViewStateMode="Inherit" UpdateMode="Conditional">
|
||||
<ContentTemplate>
|
||||
<div class="portlet solid grey-cascade portlet-filter" style="">
|
||||
<div class="portlet-title portlet-filterT smalltitle " style="">
|
||||
@@ -213,13 +223,13 @@
|
||||
<tr>
|
||||
<td colspan="3"> <label><b>Clasificaciones:</b></label> <asp:Label ID="LblClasif" runat="server" Text="Todas"></asp:Label>
|
||||
<br />
|
||||
<label><b>Clasificaciones Excluidas:</b></label> <asp:Label ID="LblClasificacionesExcluidas" runat="server" Text=""></asp:Label>
|
||||
<label><b>Clasificaciones Excluidas:</b></label> <asp:Label ID="LblClasificacionesExcluidas" runat="server" Text=""></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="3"> <label><b>Productos:</b></label> <asp:Label ID="LblProductos" runat="server" Text="Todos"></asp:Label>
|
||||
<br />
|
||||
<label><b>Productos Excluidos:</b></label> <asp:Label ID="LblProductosExcluidos" runat="server" Text=""></asp:Label>
|
||||
<br />
|
||||
<label><b>Productos Excluidos:</b></label> <asp:Label ID="LblProductosExcluidos" runat="server" Text=""></asp:Label>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
@@ -232,10 +242,10 @@
|
||||
</ContentTemplate>
|
||||
</asp:UpdatePanel>
|
||||
<br />
|
||||
|
||||
|
||||
|
||||
<asp:UpdatePanel runat="server" ID="UpGeneral" UpdateMode="Conditional">
|
||||
|
||||
|
||||
<asp:UpdatePanel runat="server" ID="UpGeneral" UpdateMode="Conditional">
|
||||
<ContentTemplate>
|
||||
|
||||
<div runat="server" id="DVNormal">
|
||||
@@ -258,7 +268,7 @@
|
||||
</div>
|
||||
<asp:GridView ID="GvF" data-sort="true" runat="server" EmptyDataText="Aun no hay registros." AutoGenerateColumns="False"
|
||||
CssClass="table table-striped table-hover Widthall ScrollAD" Style="text-align: center;"
|
||||
GridLines="None" DataKeyNames="CvePS">
|
||||
GridLines="None" DataKeyNames="CvePS,Codigo,PS,Diferencia,Abreviatura,Costo">
|
||||
<Columns>
|
||||
<asp:TemplateField Visible="false">
|
||||
<HeaderTemplate>
|
||||
@@ -272,10 +282,10 @@
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="LblC" runat="server" Font-Size="6pt"></asp:Label>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:BoundField HeaderText="Clasificación" DataField="Clasificacion" ItemStyle-HorizontalAlign="Left" />
|
||||
</asp:TemplateField>
|
||||
<asp:BoundField HeaderText="Clasificación" DataField="Clasificacion" ItemStyle-HorizontalAlign="Left" />
|
||||
<asp:BoundField HeaderText="Proveedor" DataField="NombreComercial" ItemStyle-HorizontalAlign="Left" Visible="false" />
|
||||
<asp:BoundField HeaderText="Código" DataField="Codigo" ItemStyle-HorizontalAlign="Left"/>
|
||||
<asp:BoundField HeaderText="Código" DataField="Codigo" ItemStyle-HorizontalAlign="Left" />
|
||||
<asp:BoundField HeaderText="Producto" DataField="PS" ItemStyle-HorizontalAlign="Left" />
|
||||
<asp:BoundField HeaderText="Sección Almacén" DataField="SeccionAlmacen" />
|
||||
<asp:BoundField HeaderText="Serie" DataField="Serie" ItemStyle-HorizontalAlign="Left" />
|
||||
@@ -283,7 +293,7 @@
|
||||
<asp:BoundField HeaderText="Fecha Caducidad" DataField="FechaCaducidad" ItemStyle-HorizontalAlign="Left" DataFormatString="{0:d}" />
|
||||
<asp:BoundField HeaderText="Existencia" DataField="CantidadAlmacen" DataFormatString="{0:#,###.##}" ItemStyle-HorizontalAlign="Right" />
|
||||
<asp:BoundField HeaderText="U. Medida" DataField="Abreviatura" ItemStyle-HorizontalAlign="Left" />
|
||||
|
||||
|
||||
<asp:BoundField HeaderText="Buen Estado" DataField="BuenEstado" DataFormatString="{0:#,###.##}" ItemStyle-HorizontalAlign="Right" />
|
||||
<asp:BoundField HeaderText="ME.Vendible" DataField="MalEstado" DataFormatString="{0:#,###.##}" ItemStyle-HorizontalAlign="Right" />
|
||||
<asp:BoundField HeaderText="ME.No vendible" DataField="NoVendible" DataFormatString="{0:#,###.##}" ItemStyle-HorizontalAlign="Right" />
|
||||
@@ -316,7 +326,7 @@
|
||||
</div>
|
||||
</div>
|
||||
<asp:GridView ID="GvS" data-sort="true" runat="server" EmptyDataText="Aun no hay registros." AutoGenerateColumns="False"
|
||||
CssClass="table table-striped table-hover Widthall ScrollAD" Style="text-align: center;" GridLines="None" DataKeyNames="CvePS">
|
||||
CssClass="table table-striped table-hover Widthall ScrollAD" Style="text-align: center;" GridLines="None" DataKeyNames="CvePS,Codigo,PS,Diferencia,Abreviatura,Costo">
|
||||
<Columns>
|
||||
<asp:TemplateField Visible="false">
|
||||
<HeaderTemplate>
|
||||
@@ -331,7 +341,7 @@
|
||||
<asp:Label ID="LblC" runat="server" Font-Size="6pt"></asp:Label>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:BoundField HeaderText="Clasificación" DataField="Clasificacion" ItemStyle-HorizontalAlign="Left" />
|
||||
<asp:BoundField HeaderText="Clasificación" DataField="Clasificacion" ItemStyle-HorizontalAlign="Left" />
|
||||
<asp:BoundField HeaderText="Proveedor" DataField="NombreComercial" ItemStyle-HorizontalAlign="Left" Visible="false" />
|
||||
<asp:BoundField HeaderText="Código" DataField="Codigo" ItemStyle-HorizontalAlign="Left" />
|
||||
<asp:BoundField HeaderText="Producto" DataField="PS" ItemStyle-HorizontalAlign="Left" />
|
||||
@@ -342,7 +352,7 @@
|
||||
<asp:BoundField HeaderText="Existencia" DataField="CantidadAlmacen" DataFormatString="{0:#,###.##}" ItemStyle-HorizontalAlign="Right" />
|
||||
<asp:BoundField HeaderText="U. Medida" DataField="Abreviatura" ItemStyle-HorizontalAlign="Left" />
|
||||
|
||||
<asp:BoundField HeaderText="Buen Estado" DataField="BuenEstado" DataFormatString="{0:#,###.##}" ItemStyle-HorizontalAlign="Right" />
|
||||
<asp:BoundField HeaderText="Buen Estado" DataField="BuenEstado" DataFormatString="{0:#,###.##}" ItemStyle-HorizontalAlign="Right" />
|
||||
<asp:BoundField HeaderText="ME.Vendible" DataField="MalEstado" DataFormatString="{0:#,###.##}" ItemStyle-HorizontalAlign="Right" />
|
||||
<asp:BoundField HeaderText="ME.No vendible" DataField="NoVendible" DataFormatString="{0:#,###.##}" ItemStyle-HorizontalAlign="Right" />
|
||||
|
||||
@@ -381,8 +391,8 @@
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="LblC" runat="server" Font-Size="6pt"></asp:Label>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:BoundField HeaderText="Clasificación" DataField="Clasificacion" ItemStyle-HorizontalAlign="Left" />
|
||||
</asp:TemplateField>
|
||||
<asp:BoundField HeaderText="Clasificación" DataField="Clasificacion" ItemStyle-HorizontalAlign="Left" />
|
||||
<asp:BoundField HeaderText="Proveedor" DataField="NombreComercial" ItemStyle-HorizontalAlign="Left" Visible="false" />
|
||||
<asp:BoundField HeaderText="Código" DataField="Codigo" ItemStyle-HorizontalAlign="Left" />
|
||||
<asp:BoundField HeaderText="Producto" DataField="PS" ItemStyle-HorizontalAlign="Left" />
|
||||
@@ -393,11 +403,11 @@
|
||||
<asp:BoundField HeaderText="Existencia" DataField="CantidadAlmacen" DataFormatString="{0:#,###.##}" ItemStyle-HorizontalAlign="Right" />
|
||||
<asp:BoundField HeaderText="U. Medida" DataField="Abreviatura" ItemStyle-HorizontalAlign="Left" />
|
||||
|
||||
<asp:BoundField HeaderText="Buen Estado" DataField="BuenEstado" DataFormatString="{0:#,###.##}" ItemStyle-HorizontalAlign="Right" />
|
||||
<asp:BoundField HeaderText="Buen Estado" DataField="BuenEstado" DataFormatString="{0:#,###.##}" ItemStyle-HorizontalAlign="Right" />
|
||||
<asp:BoundField HeaderText="ME.Vendible" DataField="MalEstado" DataFormatString="{0:#,###.##}" ItemStyle-HorizontalAlign="Right" />
|
||||
<asp:BoundField HeaderText="ME.No vendible" DataField="NoVendible" DataFormatString="{0:#,###.##}" ItemStyle-HorizontalAlign="Right" />
|
||||
|
||||
<%--<asp:BoundField HeaderText="Existencia" DataField="CantidadReal" ItemStyle-HorizontalAlign="Right" />--%>
|
||||
<%--<asp:BoundField HeaderText="Existencia" DataField="CantidadReal" ItemStyle-HorizontalAlign="Right" />--%>
|
||||
<asp:BoundField HeaderText="Inv. Físico" DataField="CantidadInventarioFisico" DataFormatString="{0:#,###.##}" ItemStyle-HorizontalAlign="Right" />
|
||||
<asp:BoundField HeaderText="Diferencia" DataField="Diferencia" DataFormatString="{0:#,###.##}" ItemStyle-Font-Bold="true" />
|
||||
<asp:BoundField HeaderText="Costo" DataField="Costo" DataFormatString="{0:#,##0.00}" ItemStyle-HorizontalAlign="Right" />
|
||||
@@ -425,12 +435,12 @@
|
||||
<asp:RequiredFieldValidator ID="RFVTitulos" runat="server" CssClass="help-block errorimput" ControlToValidate="TxtTitulo" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Titulo''</b> es necesario, por favor ingréselo." ValidationGroup="GrpObligatorio"></asp:RequiredFieldValidator>
|
||||
<label for="<%= TxtTitulo.ClientID.ToString()%>">Titulo:</label>
|
||||
|
||||
|
||||
|
||||
|
||||
</div>
|
||||
<div class="form-group form-md-line-input input-iconright">
|
||||
<asp:CheckBox runat="server" ID="ChkRelacionarInventario" CssClass="form-control" Text="Relacionar Inventario Físico" />
|
||||
</div>
|
||||
<div class="form-group form-md-line-input input-iconright">
|
||||
<asp:CheckBox runat="server" ID="ChkRelacionarInventario" CssClass="form-control" Text="Relacionar Inventario Físico" />
|
||||
</div>
|
||||
</ContentTemplate>
|
||||
</asp:UpdatePanel>
|
||||
</div>
|
||||
@@ -478,7 +488,7 @@
|
||||
|
||||
|
||||
<asp:GridView ID="GvGrupos" data-sort="true" runat="server" EmptyDataText="Aun no hay registros." AutoGenerateColumns="False"
|
||||
CssClass="table table-striped table-hover Widthall ScrollAD"
|
||||
CssClass="table table-striped table-hover Widthall ScrollAD"
|
||||
GridLines="None" DataKeyNames="CvePS,PS,Grupo,Orden">
|
||||
<Columns>
|
||||
<asp:TemplateField Visible="False">
|
||||
@@ -488,70 +498,74 @@
|
||||
<ItemTemplate>
|
||||
<asp:CheckBox ID="ChkPSFaltante" runat="server" />
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:BoundField HeaderText="Clasificación" DataField="Clasificacion" ItemStyle-HorizontalAlign="Left" Visible="false" >
|
||||
<ItemStyle HorizontalAlign="Left" />
|
||||
</asp:TemplateField>
|
||||
<asp:BoundField HeaderText="Clasificación" DataField="Clasificacion" ItemStyle-HorizontalAlign="Left" Visible="false">
|
||||
<ItemStyle HorizontalAlign="Left" />
|
||||
</asp:BoundField>
|
||||
<asp:BoundField HeaderText="Proveedor" DataField="NombreComercial" ItemStyle-HorizontalAlign="Left" Visible="false" >
|
||||
<ItemStyle HorizontalAlign="Left" />
|
||||
<asp:BoundField HeaderText="Proveedor" DataField="NombreComercial" ItemStyle-HorizontalAlign="Left" Visible="false">
|
||||
<ItemStyle HorizontalAlign="Left" />
|
||||
</asp:BoundField>
|
||||
<asp:BoundField HeaderText="Código" DataField="Codigo" ItemStyle-HorizontalAlign="Left" DataFormatString=" {0}" >
|
||||
<ItemStyle HorizontalAlign="Left" />
|
||||
<asp:BoundField HeaderText="Código" DataField="Codigo" ItemStyle-HorizontalAlign="Left" DataFormatString=" {0}">
|
||||
<ItemStyle HorizontalAlign="Left" />
|
||||
</asp:BoundField>
|
||||
<asp:BoundField HeaderText="Producto" DataField="PS" ItemStyle-HorizontalAlign="Left" >
|
||||
<ItemStyle HorizontalAlign="Left" />
|
||||
<asp:BoundField HeaderText="Producto" DataField="PS" ItemStyle-HorizontalAlign="Left">
|
||||
<ItemStyle HorizontalAlign="Left" />
|
||||
</asp:BoundField>
|
||||
<asp:BoundField HeaderText="Sección Almacén" DataField="SeccionAlmacen" />
|
||||
<asp:BoundField HeaderText="Serie" DataField="Serie" ItemStyle-HorizontalAlign="Left" >
|
||||
<ItemStyle HorizontalAlign="Left" />
|
||||
<asp:BoundField HeaderText="Serie" DataField="Serie" ItemStyle-HorizontalAlign="Left">
|
||||
<ItemStyle HorizontalAlign="Left" />
|
||||
</asp:BoundField>
|
||||
<asp:BoundField HeaderText="Lote" DataField="Lote" ItemStyle-HorizontalAlign="Left" >
|
||||
<ItemStyle HorizontalAlign="Left" />
|
||||
<asp:BoundField HeaderText="Lote" DataField="Lote" ItemStyle-HorizontalAlign="Left">
|
||||
<ItemStyle HorizontalAlign="Left" />
|
||||
</asp:BoundField>
|
||||
<asp:BoundField HeaderText="Fecha Caducidad" DataField="FechaCaducidad" ItemStyle-HorizontalAlign="Left" DataFormatString="{0:d}" >
|
||||
<ItemStyle HorizontalAlign="Left" />
|
||||
<asp:BoundField HeaderText="Fecha Caducidad" DataField="FechaCaducidad" ItemStyle-HorizontalAlign="Left" DataFormatString="{0:d}">
|
||||
<ItemStyle HorizontalAlign="Left" />
|
||||
</asp:BoundField>
|
||||
<asp:TemplateField HeaderText="">
|
||||
<HeaderTemplate>Conteo <br /> Anterior</HeaderTemplate>
|
||||
<HeaderTemplate>Conteo
|
||||
<br />
|
||||
Anterior</HeaderTemplate>
|
||||
<ItemTemplate>
|
||||
<asp:Literal ID="Label3" runat="server" Text='<%# Eval("CantidadPrevio", "{0:#,###.##}") %>'></asp:Literal>
|
||||
</ItemTemplate>
|
||||
<ItemStyle HorizontalAlign="Right" />
|
||||
</asp:TemplateField>
|
||||
<asp:BoundField HeaderText="Existencia" DataField="CantidadAlmacen" DataFormatString="{0:#,###.##}" ItemStyle-HorizontalAlign="Right" >
|
||||
<ItemStyle HorizontalAlign="Right" />
|
||||
</asp:TemplateField>
|
||||
<asp:BoundField HeaderText="Existencia" DataField="CantidadAlmacen" DataFormatString="{0:#,###.##}" ItemStyle-HorizontalAlign="Right">
|
||||
<ItemStyle HorizontalAlign="Right" />
|
||||
</asp:BoundField>
|
||||
<asp:BoundField HeaderText="U. Medida" DataField="Abreviatura" ItemStyle-HorizontalAlign="Left" >
|
||||
<asp:BoundField HeaderText="U. Medida" DataField="Abreviatura" ItemStyle-HorizontalAlign="Left">
|
||||
|
||||
<ItemStyle HorizontalAlign="Left" />
|
||||
<ItemStyle HorizontalAlign="Left" />
|
||||
</asp:BoundField>
|
||||
<asp:BoundField HeaderText="Buen Estado" DataField="BuenEstado" DataFormatString="{0:#,###.##}" ItemStyle-HorizontalAlign="Right" >
|
||||
<ItemStyle HorizontalAlign="Right" />
|
||||
<asp:BoundField HeaderText="Buen Estado" DataField="BuenEstado" DataFormatString="{0:#,###.##}" ItemStyle-HorizontalAlign="Right">
|
||||
<ItemStyle HorizontalAlign="Right" />
|
||||
</asp:BoundField>
|
||||
<asp:TemplateField HeaderText="">
|
||||
<HeaderTemplate>ME.<br/>Vendible</HeaderTemplate>
|
||||
<HeaderTemplate>ME.<br />
|
||||
Vendible</HeaderTemplate>
|
||||
<ItemTemplate>
|
||||
<asp:Literal ID="Label1" runat="server" Text='<%# Eval("MalEstado", "{0:#,###.##}") %>'></asp:Literal>
|
||||
</ItemTemplate>
|
||||
<ItemStyle HorizontalAlign="Right" />
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="">
|
||||
<HeaderTemplate>ME.<br/>No vendible</HeaderTemplate>
|
||||
<HeaderTemplate>ME.<br />
|
||||
No vendible</HeaderTemplate>
|
||||
<ItemTemplate>
|
||||
<asp:Literal ID="Label2" runat="server" Text='<%# Eval("NoVendible", "{0:#,###.##}") %>'></asp:Literal>
|
||||
</ItemTemplate>
|
||||
<ItemStyle HorizontalAlign="Right" />
|
||||
</asp:TemplateField>
|
||||
|
||||
<asp:BoundField HeaderText="Inv. Físico" DataField="CantidadInventarioFisico" DataFormatString="{0:#,###.##}" ItemStyle-HorizontalAlign="Right" >
|
||||
<ItemStyle HorizontalAlign="Right" />
|
||||
<asp:BoundField HeaderText="Inv. Físico" DataField="CantidadInventarioFisico" DataFormatString="{0:#,###.##}" ItemStyle-HorizontalAlign="Right">
|
||||
<ItemStyle HorizontalAlign="Right" />
|
||||
</asp:BoundField>
|
||||
<asp:BoundField HeaderText="Diferencia" DataField="Diferencia" DataFormatString="{0:#,###.##}" ItemStyle-Font-Bold="true" >
|
||||
<asp:BoundField HeaderText="Diferencia" DataField="Diferencia" DataFormatString="{0:#,###.##}" ItemStyle-Font-Bold="true">
|
||||
|
||||
<ItemStyle Font-Bold="True" />
|
||||
<ItemStyle Font-Bold="True" />
|
||||
</asp:BoundField>
|
||||
<asp:BoundField HeaderText="Costo" DataField="Costo" DataFormatString="{0:#,##0.00}" ItemStyle-HorizontalAlign="Right" >
|
||||
<ItemStyle HorizontalAlign="Right" />
|
||||
<asp:BoundField HeaderText="Costo" DataField="Costo" DataFormatString="{0:#,##0.00}" ItemStyle-HorizontalAlign="Right">
|
||||
<ItemStyle HorizontalAlign="Right" />
|
||||
</asp:BoundField>
|
||||
</Columns>
|
||||
</asp:GridView>
|
||||
@@ -561,9 +575,9 @@
|
||||
|
||||
</ContentTemplate>
|
||||
</asp:UpdatePanel>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</asp:Content>
|
||||
|
||||
@@ -3,6 +3,7 @@ Imports System.IO
|
||||
Imports Extensiones
|
||||
Imports GemBox.Spreadsheet
|
||||
Imports Microsoft.Reporting.WebForms
|
||||
Imports Stimulsoft.Base.StiDbType
|
||||
|
||||
Partial Class Inventarios_RepAnomalias
|
||||
Inherits ClsPaginas
|
||||
@@ -99,6 +100,9 @@ Partial Class Inventarios_RepAnomalias
|
||||
Dim Inventario As New ClsInventarios
|
||||
Dim dt As DataTable = Nothing
|
||||
|
||||
If UsuarioActual.Empresa.Funcionalidad(382) = "1" Then
|
||||
LnkExportarFormatoAjuste.Visible = True
|
||||
End If
|
||||
|
||||
If UsuarioActual.CveEmpresa.Contiene(119, 158) Then
|
||||
GvF.Columns(2).Visible = True 'clasificación
|
||||
@@ -1094,6 +1098,58 @@ Partial Class Inventarios_RepAnomalias
|
||||
|
||||
End Sub
|
||||
|
||||
Private Sub LnkExportarFormatoAjuste_Click(sender As Object, e As EventArgs) Handles LnkExportarFormatoAjuste.Click
|
||||
|
||||
Dim DtFaltantes As DataTable = (From row As GridViewRow In GvF.Rows.Cast(Of GridViewRow)
|
||||
Where row.RowType = DataControlRowType.DataRow
|
||||
Select New With
|
||||
{
|
||||
.Codigo = row.DataKey("Codigo"),
|
||||
.Producto = row.DataKey("PS"),
|
||||
.Unidad = row.DataKey("Abreviatura"),
|
||||
.Diferencia = row.DataKey("Diferencia").ToDecimal() * -1,
|
||||
.Costo = row.DataKey("Costo").ToDecimal(),
|
||||
.EntradaSalida = 1 'ENTRADA
|
||||
}).QueryToDataTable(True)
|
||||
|
||||
Dim DtSobrantes As DataTable = (From row As GridViewRow In GvS.Rows.Cast(Of GridViewRow)
|
||||
Where row.RowType = DataControlRowType.DataRow
|
||||
Select New With
|
||||
{
|
||||
.Codigo = row.DataKey("Codigo"),
|
||||
.Producto = row.DataKey("PS"),
|
||||
.Unidad = row.DataKey("Abreviatura"),
|
||||
.Diferencia = row.DataKey("Diferencia").ToDecimal(),
|
||||
.Costo = row.DataKey("Costo").ToDecimal(),
|
||||
.EntradaSalida = 0 'SALIDA
|
||||
}).QueryToDataTable(True)
|
||||
|
||||
Dim DtExcel As DataTable = DtFaltantes.AsEnumerable().Union(DtSobrantes.AsEnumerable()).OrderBy(Function(x) x.Field(Of Integer)("EntradaSalida") = 1).CopyToDataTable()
|
||||
DtExcel.TableName = "Existencias"
|
||||
|
||||
SpreadsheetInfo.SetLicense(ModExtensiones.SerialGemBoxSpreadsheet)
|
||||
|
||||
Dim FileExcel As New ExcelFile()
|
||||
|
||||
Dim worksheet As ExcelWorksheet = FileExcel.Worksheets.Add(DtExcel.TableName)
|
||||
worksheet.InsertDataTable(DtExcel, New InsertDataTableOptions() With
|
||||
{
|
||||
.ColumnHeaders = True,
|
||||
.StartRow = 0,
|
||||
.StartColumn = 0
|
||||
})
|
||||
worksheet.Rows(0).Style.FillPattern.SetPattern(FillPatternStyle.Solid, SpreadsheetColor.FromArgb(75, 119, 190), SpreadsheetColor.FromArgb(255, 255, 255))
|
||||
worksheet.Rows(0).Style.Font.Color = SpreadsheetColor.FromArgb(255, 255, 255)
|
||||
|
||||
Dim columnCount As Integer = worksheet.CalculateMaxUsedColumns()
|
||||
For i As Integer = 0 To columnCount
|
||||
worksheet.Columns(i).AutoFit(1, worksheet.Rows(0), worksheet.Rows(worksheet.Rows.Count - 1))
|
||||
Next
|
||||
|
||||
FileExcel.Save(Response, "FormatoAjusteInventario.xlsx", SaveOptions.XlsxDefault)
|
||||
|
||||
End Sub
|
||||
|
||||
|
||||
|
||||
End Class
|
||||
|
||||
211
Inventarios/RepResumenMovimientosDiario.aspx
Normal file
211
Inventarios/RepResumenMovimientosDiario.aspx
Normal file
@@ -0,0 +1,211 @@
|
||||
<%@ Page Title="" Language="VB" MasterPageFile="~/Site.master" AutoEventWireup="false" CodeFile="RepResumenMovimientosDiario.aspx.vb" Inherits="Inventarios_RepResumenMovimientosDiario" %>
|
||||
|
||||
<asp:Content ID="Content1" ContentPlaceHolderID="CP" runat="Server">
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content2" ContentPlaceHolderID="Css" runat="Server">
|
||||
<style>
|
||||
.select2-selection__rendered {
|
||||
margin-top: 0px;
|
||||
height: 25px;
|
||||
}
|
||||
|
||||
.dataTables_scrollBody table th {
|
||||
padding: 0px !important;
|
||||
padding-right: 4px !important;
|
||||
padding-left: 4px !important;
|
||||
}
|
||||
|
||||
.table-scrollable {
|
||||
margin: 0px !important;
|
||||
}
|
||||
|
||||
.dataTables_scrollFoot {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.dataTables_scroll {
|
||||
margin-bottom: 0px;
|
||||
}
|
||||
|
||||
.table.dataTable {
|
||||
margin-top: 0px !important;
|
||||
}
|
||||
|
||||
.table table-striped table-hover dataTable no-footer {
|
||||
margin-top: 0px !important;
|
||||
}
|
||||
|
||||
.Excede {
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
}
|
||||
|
||||
.psagregar > div.comboxes {
|
||||
display: inline-block;
|
||||
width: 250px;
|
||||
}
|
||||
|
||||
.psagregar > div.codigo input {
|
||||
width: 79px;
|
||||
}
|
||||
|
||||
.psagregar > div.codigo {
|
||||
display: inline-block;
|
||||
width: 80px;
|
||||
}
|
||||
|
||||
.psagregar > div.codigo > input[type="submit"] {
|
||||
display: none;
|
||||
}
|
||||
|
||||
|
||||
|
||||
.widget-thumb {
|
||||
padding: 15px;
|
||||
border-radius: 4px;
|
||||
}
|
||||
|
||||
.widget-thumb.bordered {
|
||||
border: 3px solid whitesmoke;
|
||||
}
|
||||
|
||||
.widget-thumb .widget-thumb-heading {
|
||||
font-size: 14px;
|
||||
font-weight: 700;
|
||||
color: #8e9daa;
|
||||
margin: 0px 5px;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.widget-thumb .widget-thumb-wrap {
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.widget-thumb .widget-thumb-wrap .widget-thumb-icon {
|
||||
float: left;
|
||||
width: 60px;
|
||||
height: 60px;
|
||||
display: inline-block;
|
||||
font-size: 20px;
|
||||
line-height: 41px;
|
||||
color: #fff;
|
||||
text-align: center;
|
||||
padding: 10px;
|
||||
margin-right: 15px;
|
||||
}
|
||||
|
||||
.widget-thumb .widget-thumb-body {
|
||||
overflow: hidden;
|
||||
padding: 5px;
|
||||
}
|
||||
|
||||
.widget-thumb .widget-thumb-body .widget-thumb-subtitle {
|
||||
padding-top: 2px;
|
||||
display: block;
|
||||
font-size: 14px;
|
||||
font-weight: 600;
|
||||
color: #8e9daa;
|
||||
}
|
||||
|
||||
.widget-thumb .widget-thumb-body .widget-thumb-body-stat {
|
||||
display: block;
|
||||
font-size: 20px;
|
||||
font-weight: 600;
|
||||
color: #3e4f5e;
|
||||
}
|
||||
</style>
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content3" ContentPlaceHolderID="E" runat="Server">
|
||||
Resumen de movimientos del cierre del dia
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content4" ContentPlaceHolderID="HB" runat="Server">
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content5" ContentPlaceHolderID="H" runat="Server">
|
||||
<asp:UpdatePanel runat="server" ID="UpAcciones" UpdateMode="Conditional">
|
||||
<ContentTemplate>
|
||||
<li>
|
||||
<asp:LinkButton ID="LnkImprimir" runat="server" OnClick="LnkImprimir_Click"><i class="fa fa-file-pdf-o" style="font-weight: bold;"></i>Exportar a PDF</asp:LinkButton>
|
||||
</li>
|
||||
</ContentTemplate>
|
||||
<Triggers>
|
||||
<asp:PostBackTrigger ControlID="LnkImprimir" />
|
||||
</Triggers>
|
||||
</asp:UpdatePanel>
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content6" ContentPlaceHolderID="HA" runat="Server">
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content7" ContentPlaceHolderID="C" runat="Server">
|
||||
<asp:UpdatePanel runat="server" ID="UpFiltros">
|
||||
<ContentTemplate>
|
||||
<div class="portlet solid grey-cascade portlet-filter">
|
||||
<div class="portlet-title portlet-filterT smalltitle" style="min-height: 45px; position: relative;">
|
||||
<div class="tools">
|
||||
<asp:Button ID="btConsultar" CssClass="btn btn-primary" runat="server" ValidationGroup="GrpConsultar" Text="Consultar" /></td>
|
||||
</div>
|
||||
<div class="titlefiltros caption magindate">
|
||||
<div class="row">
|
||||
<div class="col-md-1 truncate text-right">Fecha del mes: </div>
|
||||
<div class="col-md-3">
|
||||
<div class="input-group input-sm input-small date date-picker " data-date-format="dd/mm/yyyy" style="width: 95px !important; padding: 0px;">
|
||||
<asp:TextBox Style="width: 80px !important;" ID="TxtFechaMes" runat="server" CssClass="form-control" CausesValidation="true" MaxLength="10"></asp:TextBox>
|
||||
<span class="input-group-btn ">
|
||||
<asp:LinkButton ID="ImgFechaMes" class="btn default " Text="<i class='fa fa-calendar'></i>" runat="server"></asp:LinkButton>
|
||||
</span>
|
||||
</div>
|
||||
<ajax:MaskedEditExtender ID="MaskedEditExtender1" runat="server" TargetControlID="TxtFechaMes" Mask="99/99/9999" MaskType="Date" DisplayMoney="Left" AcceptNegative="Left"></ajax:MaskedEditExtender>
|
||||
<ajax:CalendarExtender runat="server" ID="CalendarExtender1" TargetControlID="TxtFechaMes" PopupButtonID="ImgFechaMes" PopupPosition="BottomRight" Enabled="True"></ajax:CalendarExtender>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</ContentTemplate>
|
||||
</asp:UpdatePanel>
|
||||
<div class="text-right" style="margin: 5px 0px;">
|
||||
<input type="text" id="TxtBusqueda" class="form-control input-sm" onkeyup="<%= String.Format("FiltrarTabla('TxtBusqueda','{0}')", GvDatos.ClientID) %>" style="display: inline-block; margin-right: -20px; width: 150px;" />
|
||||
<a href="javascript:;" onclick="<%= String.Format("FiltrarTabla('TxtBusqueda','{0}')", GvDatos.ClientID) %>" style="margin-top: -3px;" class="btn btn-circle btn-sm label-info"><i class="icon-magnifier"></i></a>
|
||||
</div>
|
||||
|
||||
<asp:UpdatePanel ID="UPDatos" runat="server" UpdateMode="Conditional" RenderMode="Inline">
|
||||
<ContentTemplate>
|
||||
<asp:GridView ID="GvDatos" Width="100%" runat="server" ShowHeader="true" EmptyDataText="No hay registros." AutoGenerateColumns="False" AllowPaging="False"
|
||||
ShowFooter="True" ShowHeaderWhenEmpty="True" CssClass="table table-striped table-hover Widthall ScrollAD mysmallbtn" GridLines="None" DataKeyNames="CveMovimiento,FechaMovto">
|
||||
<Columns>
|
||||
<asp:BoundField DataField="FechaMovto" DataFormatString="{0:dd/MM/yyyy HH:mm:ss}" ItemStyle-Width="90px" HeaderText="Fecha" />
|
||||
<asp:BoundField DataField="Almacen" HeaderText="Almacén" ItemStyle-Width="150px" ItemStyle-HorizontalAlign="Left" />
|
||||
<asp:BoundField DataField="Concepto" HeaderText="Movimiento" ItemStyle-Width="150px" ItemStyle-HorizontalAlign="Left" />
|
||||
<asp:HyperLinkField DataTextField="CodigoPS" DataNavigateUrlFields="CvePS" DataNavigateUrlFormatString="/Ventas/ProductosServicios.aspx?CvePS={0}" HeaderText="Descripción" ItemStyle-HorizontalAlign="Left" />
|
||||
<asp:BoundField DataField="TipoMovimiento" HeaderText="Tipo" ItemStyle-Width="100px" ItemStyle-HorizontalAlign="Left" />
|
||||
<asp:TemplateField ItemStyle-Width="70px" HeaderText="Folio">
|
||||
<ItemTemplate>
|
||||
<asp:HyperLink ID="hlFolio" runat="server" Text='<%# Eval("Folio")%>' CssClass="Texto" NavigateUrl='<%# Eval("CveMovimiento", "/Inventarios/EntradasSalidas.aspx?CveMovimiento={0}")%>' Target="_blank" />
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField ItemStyle-Width="75px" ItemStyle-HorizontalAlign="Right" HeaderText="Entrada">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="lbEntrada" runat="server"
|
||||
Text='<%# Eval("Entrada", "{0:###,###.####}")%>'></asp:Label>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField ItemStyle-Width="75px" ItemStyle-HorizontalAlign="Right" HeaderText="Salida">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="lbSalida" runat="server"
|
||||
Text='<%# Eval("Salida", "{0:###,###.####}")%>'></asp:Label>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:BoundField DataField="ClienteProveedor" HeaderText="Cliente/Proveedor" ItemStyle-HorizontalAlign="Left" />
|
||||
</Columns>
|
||||
<RowStyle CssClass="Texto" />
|
||||
<AlternatingRowStyle CssClass="TextoAlterno" />
|
||||
</asp:GridView>
|
||||
</div>
|
||||
|
||||
</ContentTemplate>
|
||||
<Triggers>
|
||||
<asp:AsyncPostBackTrigger ControlID="btConsultar" EventName="Click" />
|
||||
</Triggers>
|
||||
</asp:UpdatePanel>
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content8" ContentPlaceHolderID="JS" runat="Server">
|
||||
</asp:Content>
|
||||
|
||||
63
Inventarios/RepResumenMovimientosDiario.aspx.vb
Normal file
63
Inventarios/RepResumenMovimientosDiario.aspx.vb
Normal file
@@ -0,0 +1,63 @@
|
||||
Option Strict On
|
||||
Option Explicit On
|
||||
|
||||
Imports System.Data
|
||||
Imports Extensiones
|
||||
Imports Microsoft.Reporting.WebForms
|
||||
Partial Class Inventarios_RepResumenMovimientosDiario
|
||||
Inherits ClsPaginas
|
||||
|
||||
Private Property DtDatos As DataTable
|
||||
Get
|
||||
DtDatos = DirectCast(ViewState("DtDatos"), DataTable)
|
||||
End Get
|
||||
|
||||
Set(ByVal value As DataTable)
|
||||
ViewState("DtDatos") = value
|
||||
End Set
|
||||
End Property
|
||||
Protected Sub Page_Load(sender As Object, e As System.EventArgs) Handles Me.Load
|
||||
If Not IsPostBack Then
|
||||
TxtFechaMes.Text = NowADS().ToString("dd/MM/yyyy")
|
||||
End If
|
||||
End Sub
|
||||
|
||||
Private Sub CargarDatos()
|
||||
Dim ObjInventarios As New ClsInventarios
|
||||
If ObjInventarios.GetRepResumenMovimientosDiario(TxtFechaMes.Text.ToDate, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa) Then
|
||||
DtDatos = ObjInventarios.DtResultados.Copy()
|
||||
GvDatos.DataSource = DtDatos
|
||||
End If
|
||||
ObjInventarios.Dispose()
|
||||
GvDatos.DataBind()
|
||||
End Sub
|
||||
|
||||
Protected Sub btConsultar_Click(sender As Object, e As EventArgs) Handles btConsultar.Click
|
||||
CargarDatos()
|
||||
UPDatos.Update()
|
||||
End Sub
|
||||
|
||||
Private Sub GenerarPDF(Optional Formato As String = "PDF")
|
||||
If GvDatos.Rows.Count > 0 Then
|
||||
If DtDatos IsNot Nothing Then
|
||||
Dim Imagen As New System.IO.FileInfo($"{UsuarioActual.Empresa.Ruta}/Logo.png")
|
||||
Dim logouri = String.Format("{0}://{1}:{2}/Empresas/{3}/Logo.png", Request.Url.Scheme, Request.Url.Host, Request.Url.Port, UsuarioActual.CveEmpresa)
|
||||
|
||||
Dim params As New List(Of ReportParameter)
|
||||
params.Add(New ReportParameter("NombreEmpresa", UsuarioActual.Empresa.Empresa))
|
||||
params.Add(New ReportParameter("Fecha", TxtFechaMes.Text))
|
||||
params.Add(New ReportParameter("UsuarioImprimio", UsuarioActual.Nombre))
|
||||
params.Add(New ReportParameter("FechaImpresion", NowADS().ToDateTime.ToShortDateString))
|
||||
params.Add(New ReportParameter("LogoPath", If(Imagen.Exists, $"file://{Imagen.FullName}", "")))
|
||||
ImprimirPDF("Empresas/Grales/Formatos/RepResumenMovimientosDiario.rdlc", DtDatos, params, "Reporte Diario", Formato)
|
||||
End If
|
||||
Else
|
||||
Alert("No hay informacion cargada", TipoMensaje.MsgAdvertencia)
|
||||
End If
|
||||
|
||||
End Sub
|
||||
|
||||
Protected Sub LnkImprimir_Click(sender As Object, e As EventArgs)
|
||||
GenerarPDF("PDF")
|
||||
End Sub
|
||||
End Class
|
||||
@@ -66,17 +66,22 @@ Partial Class ListadoContratos
|
||||
End If
|
||||
ObjContratos.Dispose()
|
||||
|
||||
'Generamos Folio - NumeroContrato
|
||||
Dim CveSubProyecto As Integer = GlobalDTSubProyectos(UsuarioActual.CveEmpresa).FiltroPrimeroValor("CveSubProyecto", "TipoSucursal = 1").ToEntero
|
||||
|
||||
UpTitulos.Update()
|
||||
End Sub
|
||||
|
||||
Private Sub CargaFolio()
|
||||
|
||||
Dim ObjFolio As New ClsGralFolios
|
||||
If ObjFolio.GetFolios("Con", UsuarioActual.CveEmpresa, CveSubProyecto:=CveSubProyecto) Then
|
||||
If ObjFolio.GetFolios("Con", UsuarioActual.CveEmpresa, CveSubProyecto:=-1) Then
|
||||
If ObjFolio.DtResultados.Rows.Count > 0 Then
|
||||
Dim drr As DataRow = ObjFolio.DtResultados.FiltroPrimero("")
|
||||
LbFolio.Text = $"{drr("Serie").ToString}-{drr("FActual").ToString}"
|
||||
End If
|
||||
End If
|
||||
ObjFolio.Dispose()
|
||||
|
||||
UpTitulos.Update()
|
||||
UpModal.Update()
|
||||
End Sub
|
||||
#End Region
|
||||
#Region "Contrato"
|
||||
@@ -116,7 +121,7 @@ Partial Class ListadoContratos
|
||||
Alert("Debe seleccionar al cliente", TipoMensaje.MsgAdvertencia)
|
||||
Exit Sub
|
||||
End If
|
||||
'Dim CveSubProyecto As Integer = GlobalDTSubProyectos(UsuarioActual.CveEmpresa).FiltroPrimeroValor("CveSubProyecto", "TipoSucursal = 1").ToEntero
|
||||
|
||||
|
||||
'Agregamos Contrato
|
||||
|
||||
@@ -189,11 +194,12 @@ Partial Class ListadoContratos
|
||||
ErrorProceso = True
|
||||
End If
|
||||
|
||||
|
||||
'Aumentamos Folio
|
||||
Dim ObjFolios As New ClsGralFolios(ObjContratos.IniciaTransacSQL())
|
||||
If Not ObjFolios.UpdateFolioActual(DdlSubProyectoModal.SelectedValue.ToEntero, "Con", True, UsuarioActual.CveEmpresa) Then
|
||||
ErrorProceso = True
|
||||
If Not ErrorProceso Then
|
||||
'Aumentamos Folio
|
||||
Dim ObjFolios As New ClsGralFolios(ObjContratos.IniciaTransacSQL())
|
||||
If Not ObjFolios.UpdateFolioActual(-1, "Con", True, UsuarioActual.CveEmpresa) Then
|
||||
ErrorProceso = True
|
||||
End If
|
||||
End If
|
||||
|
||||
|
||||
@@ -400,7 +406,11 @@ Partial Class ListadoContratos
|
||||
#End Region
|
||||
|
||||
Protected Sub LnkAgregarContrato_Click(sender As Object, e As EventArgs)
|
||||
CargaFolio()
|
||||
RegistraScript("$('#ModalAgregar').modal({ backdrop: 'static', keyboard: false });")
|
||||
UpTitulos.Update()
|
||||
End Sub
|
||||
|
||||
|
||||
|
||||
End Class
|
||||
|
||||
@@ -269,6 +269,14 @@
|
||||
<i></i>
|
||||
</div>
|
||||
|
||||
<div class="form-group form-md-line-input input-iconright col-xs-3" id="DivPorMinimoUtilidad" runat="server" visible="false">
|
||||
<asp:TextBox ID="TxtPorMinimoUtilidad" CssClass="form-control" runat="server"></asp:TextBox>
|
||||
<asp:RangeValidator ID="RVPorMinUtilidad" runat="server" Type="Double" MinimumValue="0" MaximumValue="99" ErrorMessage="El campo <b>''% Minimo de utilidad''</b> debe tener un valor entre 0 y 99, por favor ingréselo." ControlToValidate="TxtPorMinimoUtilidad" Display="None" ValidationGroup="GrpGuardar"></asp:RangeValidator>
|
||||
<ajax:ValidatorCalloutExtender ID="VCEPorMinUtilidad" runat="server" HighlightCssClass="vco" TargetControlID="RVPorMinUtilidad" Width="300px"></ajax:ValidatorCalloutExtender>
|
||||
<label class="truncate" style="padding-left: 1px;" for="<%= TxtPorMinimoUtilidad.ClientID.ToString()%>">% Minimo de utilidad:</label>
|
||||
<i></i>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class=" col-md-12">
|
||||
<div runat="server" id="DivCompuesto" class="form-group form-md-line-input input-iconright" visible="false">
|
||||
@@ -1828,11 +1836,11 @@
|
||||
|
||||
<asp:TemplateField HeaderText="Editar" ItemStyle-Width="40px">
|
||||
<EditItemTemplate>
|
||||
<center>
|
||||
<asp:LinkButton ID="imgU" runat="server" AlternateText="Actualizar" CausesValidation="True" CommandName="Update"
|
||||
CssClass="btn btn-circle btn-sm green" Text="<i class='fa fa-check'></i>" ValidationGroup="GrpGV" />
|
||||
<asp:LinkButton ID="imgC" runat="server" AlternateText="Cancelar" CausesValidation="False" CommandName="Cancel"
|
||||
CssClass="btn btn-circle btn-sm red" Text="<i class='fa fa-times'></i>" />
|
||||
<center>
|
||||
<asp:LinkButton ID="imgU" runat="server" AlternateText="Actualizar" CausesValidation="True" CommandName="Update"
|
||||
CssClass="btn btn-circle btn-sm green" Text="<i class='fa fa-check'></i>" ValidationGroup="GrpGV" />
|
||||
<asp:LinkButton ID="imgC" runat="server" AlternateText="Cancelar" CausesValidation="False" CommandName="Cancel"
|
||||
CssClass="btn btn-circle btn-sm red" Text="<i class='fa fa-times'></i>" />
|
||||
</center>
|
||||
</EditItemTemplate>
|
||||
<ItemTemplate>
|
||||
@@ -2340,17 +2348,17 @@
|
||||
<ContentTemplate>
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group form-md-line-input input-iconright">
|
||||
|
||||
<ADS:Dropdownlost runat="server" ID="DdlPSAdicional" CssClass="form-control input-sm DdlPS" CssClassDdl="select2me" CssStyle="width:100%" DataTextField="PSCodigo" DataValueField="CvePS" />
|
||||
<label for="<%= DdlPSAdicional.ClientID.ToString()%>" >Producto/Servicio:</label>
|
||||
|
||||
|
||||
<div class="form-group form-md-line-input input-iconright">
|
||||
|
||||
<ADS:Dropdownlost runat="server" ID="DdlPSAdicional" CssClass="form-control input-sm DdlPS" CssClassDdl="select2me" CssStyle="width:100%" DataTextField="PSCodigo" DataValueField="CvePS" />
|
||||
<label for="<%= DdlPSAdicional.ClientID.ToString()%>">Producto/Servicio:</label>
|
||||
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6" id="DivTipoAdicional" runat="server" visible="false">
|
||||
<div class="form-group form-md-line-input input-iconright">
|
||||
<label style="top: 0;margin-bottom: 0; font-size: 13px; color: #888888;opacity: 1;">Tipo:</label>
|
||||
<label style="top: 0; margin-bottom: 0; font-size: 13px; color: #888888; opacity: 1;">Tipo:</label>
|
||||
<asp:RadioButtonList ID="RblTipoAdicional" runat="server" RepeatDirection="Horizontal">
|
||||
<asp:ListItem Value="1" Selected="True">Adicional</asp:ListItem>
|
||||
<asp:ListItem Value="2">Similar</asp:ListItem>
|
||||
@@ -2363,7 +2371,7 @@
|
||||
<div class="form-group form-md-line-input input-iconright" style="width: 200px!important;">
|
||||
<asp:UpdatePanel ID="UpdatePanel2" runat="server" UpdateMode="Conditional">
|
||||
<ContentTemplate>
|
||||
<label style="top: 0;margin-bottom: 0; font-size: 13px; color: #888888;opacity: 1;">Cantidad:</label>
|
||||
<label style="top: 0; margin-bottom: 0; font-size: 13px; color: #888888; opacity: 1;">Cantidad:</label>
|
||||
<asp:RadioButtonList ID="RBLCantidad" runat="server" RepeatDirection="Horizontal" AutoPostBack="True" OnSelectedIndexChanged="RBLCantidad_SelectedIndexChanged1">
|
||||
<asp:ListItem Value="1" Selected="True">Depende del PS</asp:ListItem>
|
||||
<asp:ListItem Value="2">Fijo</asp:ListItem>
|
||||
|
||||
@@ -449,6 +449,7 @@ Partial Class ProductosyServicios
|
||||
If UsuarioActual.Empresa.Funcionalidad(382) = "1" Then
|
||||
DivPSAdicionales.Visible = True
|
||||
DivTipoAdicional.Visible = True
|
||||
DivPorMinimoUtilidad.Visible = True
|
||||
End If
|
||||
|
||||
CvePSAdicional = -1
|
||||
@@ -1148,6 +1149,10 @@ Partial Class ProductosyServicios
|
||||
DivPSExhibicion.Visible = True
|
||||
ChkPSExhibicion.Checked = CBool(ObjProductosServicios.DtResultados.Rows(0)("ProductoExhibicion").ToString)
|
||||
End If
|
||||
|
||||
If UsuarioActual.Empresa.Funcionalidad(382) = "1" Then
|
||||
TxtPorMinimoUtilidad.Text = ObjProductosServicios.DtResultados.Rows(0)("PorcentajeMinimoUtilidad").ToString
|
||||
End If
|
||||
Else
|
||||
Alert("El Producto o Servicio Solicitado no existe, por favor revise su búsqueda.", TipoMensaje.MsgAdvertencia)
|
||||
RegistraScript("$('#C_Tab_TabPaquetes_tab').css('display' , 'none')")
|
||||
@@ -1543,8 +1548,9 @@ Partial Class ProductosyServicios
|
||||
CvePSAdicionalVigencia:=DdlPSAdicionalVigencia.SelectedValue.ToEntero(), PrecioLibre:=ChkPrecioLibre.Checked,
|
||||
CveMaterialPeligroso:=DdlMaterialPeligroso.SelectedValue.ToEntero, CveEmbalaje:=DdlEmbalaje.SelectedValue.ToEntero, PesoKg:=TxtPesoKg.Text.ToDecimal, Dimensiones:=TxtDimensiones.Text.Trim,
|
||||
CveObjetoImpuesto:=DdlObjetoImpuesto.SelectedValue.ToEntero, Litraje:=TxtLitraje.Text.ToDecimal, RegistroRSCO:=TxtRegistroRSCO.Text, FechaVigenciaRSCO:=TxtFechaVigenciaRSCO.Text.ToDate, VigenciaIndeterminadaRSCO:=ChkFechaIndeterminadaRSCO.Checked,
|
||||
NombreComercial:=TxtNombreComercial.Text.Trim, NotasAdicionales:=TxtEcommerceNota.Text.Trim, EcommerceEtiquetas:=TxtEcommerceEtiquetas.Text.Trim.Replace(".", ""), EcommercePrecio:=TxtEcommercePrecio.Text.Trim.ToDecimal,
|
||||
CveClasificacionEcommerce:=DdlEcommerceClasificacion.SelectedValue.ToEntero, EcommerceCantidad:=TxtEcommerceCantidad.Text.Trim.ToDecimal, CodigoAlterno:=TxtCodigoAlterno.Text.Trim, PSAlterno:=TxtPSAlterno.Text.Trim, ProductoExhibicion:=ChkPSExhibicion.Checked) > 0 Then
|
||||
NombreComercial:=TxtNombreComercial.Text.Trim, NotasAdicionales:=TxtEcommerceNota.Text.Trim, EcommerceEtiquetas:=TxtEcommerceEtiquetas.Text.Trim.Replace(".", ""), EcommercePrecio:=TxtEcommercePrecio.Text.Trim.ToDecimal,
|
||||
CveClasificacionEcommerce:=DdlEcommerceClasificacion.SelectedValue.ToEntero, EcommerceCantidad:=TxtEcommerceCantidad.Text.Trim.ToDecimal, CodigoAlterno:=TxtCodigoAlterno.Text.Trim, PSAlterno:=TxtPSAlterno.Text.Trim, ProductoExhibicion:=ChkPSExhibicion.Checked,
|
||||
PorcentajeMinimoUtilidad:=TxtPorMinimoUtilidad.Text.ToDecimal()) > 0 Then
|
||||
ViewState("CvePS") = ObjProductosServicios.CvePS
|
||||
For Each GVR As GridViewRow In GvImpuestosLocales.Rows
|
||||
If GVR.FCCheckBox("ChkDeduccion").Checked Then
|
||||
@@ -1618,7 +1624,7 @@ Partial Class ProductosyServicios
|
||||
RegistroRSCO:=TxtRegistroRSCO.Text, FechaVigenciaRSCO:=TxtFechaVigenciaRSCO.Text.ToDate, VigenciaIndeterminadaRSCO:=ChkFechaIndeterminadaRSCO.Checked,
|
||||
NombreComercial:=TxtNombreComercial.Text.Trim, NotasAdicionales:=TxtEcommerceNota.Text.Trim, EcommerceEtiquetas:=TxtEcommerceEtiquetas.Text.Trim.Replace(".", ""), ActivoEcommerce:=ChkActivoEcommerce.Checked,
|
||||
EcommercePrecio:=TxtEcommercePrecio.Text.Trim.ToDecimal, CveClasificacionEcommerce:=DdlEcommerceClasificacion.SelectedValue.ToEntero, EcommerceCantidad:=TxtEcommerceCantidad.Text.Trim.ToDecimal,
|
||||
CodigoAlterno:=TxtCodigoAlterno.Text.Trim, PSAlterno:=TxtPSAlterno.Text.Trim, ProductoExhibicion:=ChkPSExhibicion.Checked) Then
|
||||
CodigoAlterno:=TxtCodigoAlterno.Text.Trim, PSAlterno:=TxtPSAlterno.Text.Trim, ProductoExhibicion:=ChkPSExhibicion.Checked, PorcentajeMinimoUtilidad:=TxtPorMinimoUtilidad.Text.ToDecimal()) Then
|
||||
|
||||
If Not ObjProductosServicios.LimpiaImpuestosLocales(CvePS) Then
|
||||
TieneError = True
|
||||
|
||||
@@ -281,7 +281,6 @@
|
||||
<asp:UpdatePanel runat="server">
|
||||
<ContentTemplate>
|
||||
<asp:Button ID="BtnGuardar" Text="Guardar" CssClass="btn btn-primary" ValidationGroup="GrpGuardar" OnClick="BtnGuardar_Click" runat="server" />
|
||||
|
||||
<asp:Button ID="ButBtnEliminar" Text="Eliminar" CssClass="btn btn-danger" OnClick="BtnEliminar_Click" runat="server" Visible="false"
|
||||
data-toggle="confirmation" data-popout="true" data-original-title="Confirmar" data-btn-ok-label="si"
|
||||
/>
|
||||
|
||||
@@ -7,6 +7,7 @@ Imports DocumentFormat.OpenXml.Drawing.Diagrams
|
||||
Imports Extensiones
|
||||
Imports iText.StyledXmlParser.Css.Resolve.Shorthand.Impl
|
||||
Imports Microsoft.Owin.Security.Provider
|
||||
Imports Telerik.Web.UI
|
||||
|
||||
Partial Class Ventas_Promociones
|
||||
Inherits ClsPaginas
|
||||
@@ -84,18 +85,18 @@ Partial Class Ventas_Promociones
|
||||
End Property
|
||||
|
||||
|
||||
Private Property DTPSUltimoCosto As DataTable
|
||||
Get
|
||||
If ViewState("DTPSUltimoCosto") Is Nothing Then
|
||||
ViewState("DTPSUltimoCosto") = New DataTable
|
||||
End If
|
||||
'Private Property DTPSUltimoCosto As DataTable
|
||||
' Get
|
||||
' If ViewState("DTPSUltimoCosto") Is Nothing Then
|
||||
' ViewState("DTPSUltimoCosto") = New DataTable
|
||||
' End If
|
||||
|
||||
Return CType(ViewState("DTPSUltimoCosto"), DataTable)
|
||||
End Get
|
||||
Set(value As DataTable)
|
||||
ViewState("DTPSUltimoCosto") = value
|
||||
End Set
|
||||
End Property
|
||||
' Return CType(ViewState("DTPSUltimoCosto"), DataTable)
|
||||
' End Get
|
||||
' Set(value As DataTable)
|
||||
' ViewState("DTPSUltimoCosto") = value
|
||||
' End Set
|
||||
'End Property
|
||||
|
||||
Private Property PermisoAutorizPromocionPorcentaje As Boolean
|
||||
Get
|
||||
@@ -158,7 +159,7 @@ Partial Class Ventas_Promociones
|
||||
PorMinMasCostoVentaFnc129 = UsuarioActual.Empresa.Funcionalidad(129).ToDecimal
|
||||
PermisoAutorizPromocionPorcentaje = UsuarioActual.TienePermisoProceso(386)
|
||||
|
||||
EmpresaFnc382 = If(UsuarioActual.Empresa.Funcionalidad(352) = "1", True, False) 'Grupo díaz
|
||||
EmpresaFnc382 = If(UsuarioActual.Empresa.Funcionalidad(382) = "1", True, False) 'Grupo díaz
|
||||
'EmpresaFnc382 = True ''Para pruebas
|
||||
|
||||
CvePromocion = -1
|
||||
@@ -173,7 +174,6 @@ Partial Class Ventas_Promociones
|
||||
LnkAgrgarPlantillaPS.Visible = False
|
||||
|
||||
|
||||
|
||||
ValidaPromosiones(False)
|
||||
If EmpresaFnc382 AndAlso ChkEstatus.Checked = False AndAlso BloqueadoPromocionPorcentaje AndAlso Not PermisoAutorizPromocionPorcentaje Then
|
||||
ChkEstatus.Enabled = False
|
||||
@@ -345,20 +345,20 @@ Partial Class Ventas_Promociones
|
||||
|
||||
Private Sub CargaDTUltimoCosto()
|
||||
|
||||
If Not EmpresaFnc382 Then
|
||||
Exit Sub
|
||||
If EmpresaFnc382 Then
|
||||
Dim DTPSUltimoCosto = New DataTable
|
||||
|
||||
Dim ObjInv As New ClsInventarios
|
||||
|
||||
If ObjInv.GetUltimoCosto(UsuarioActual.CveEmpresa) Then
|
||||
DTPSUltimoCosto = ObjInv.DtResultados
|
||||
End If
|
||||
|
||||
ObjInv.Dispose()
|
||||
End If
|
||||
|
||||
|
||||
DTPSUltimoCosto = New DataTable
|
||||
|
||||
Dim ObjInv As New ClsInventarios
|
||||
|
||||
If ObjInv.GetUltimoCosto(UsuarioActual.CveEmpresa) Then
|
||||
DTPSUltimoCosto = ObjInv.DtResultados
|
||||
End If
|
||||
|
||||
ObjInv.Dispose()
|
||||
|
||||
|
||||
End Sub
|
||||
@@ -619,6 +619,16 @@ Partial Class Ventas_Promociones
|
||||
End If
|
||||
|
||||
|
||||
Dim DTPSUltimoCosto = New DataTable
|
||||
|
||||
Dim ObjInv As New ClsInventarios
|
||||
If ObjInv.GetUltimoCosto(UsuarioActual.CveEmpresa) Then
|
||||
DTPSUltimoCosto = ObjInv.DtResultados
|
||||
End If
|
||||
ObjInv.Dispose()
|
||||
|
||||
|
||||
|
||||
If PorMinMasCostoVentaFnc129 > 0 Then
|
||||
|
||||
For Each dRow As DataRow In TempDT.Rows
|
||||
@@ -792,6 +802,11 @@ Partial Class Ventas_Promociones
|
||||
End If
|
||||
|
||||
ObjVentas.Dispose()
|
||||
|
||||
If Not TieneError AndAlso BloqueadoPromocionPorcentaje Then
|
||||
MandaCorreoNotificacionPromocionBloqueo(CvePromocion, TxtPromocion.Text.Trim)
|
||||
End If
|
||||
|
||||
End Sub
|
||||
|
||||
|
||||
@@ -847,24 +862,6 @@ Partial Class Ventas_Promociones
|
||||
|
||||
If Not TieneError Then
|
||||
|
||||
'366 Estatus
|
||||
|
||||
'367 CvePS
|
||||
'368 PUPromocion
|
||||
'369 CveTipoPromocion
|
||||
'370 Cantidad Minima
|
||||
'371 AplicaRestriccion
|
||||
'372 HoraInicio
|
||||
'373 HoraFin
|
||||
|
||||
'374 AplicaLunes
|
||||
'375 AplicaMartes
|
||||
'376 AplicaMiercoles
|
||||
'377 AplicaJueves
|
||||
'378 AplicaViernes
|
||||
'379 AplicaSabado
|
||||
'380 AplicaDomingo
|
||||
'381 IncluyeImpuestos
|
||||
|
||||
|
||||
Dim Dr2 As DataRow = TempDTOrigial.FiltraParametros($"CvePromocionDetalle = {Dr("CvePromocionDetalle").ToString}").Rows(0)
|
||||
@@ -893,12 +890,7 @@ Partial Class Ventas_Promociones
|
||||
End If
|
||||
|
||||
|
||||
'If Not TieneError And Dr("AplicaRestriccion").ToString <> Dr2("AplicaRestriccion").ToString Then
|
||||
' If Not ObjGral.AddHistorialBitacora(371, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Dr2("AplicaRestriccion").ToString, $"{Dr("CodigoPS").ToString} - {Dr("AplicaRestriccion").ToString}", UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, 1, "Se elimino " & Dr("CodigoPS").ToString, "PS", "", CvePromocion:=CvePromocion) Then
|
||||
' TieneError = True
|
||||
' Exit For
|
||||
' End If
|
||||
'End If
|
||||
|
||||
|
||||
If Not TieneError And Dr("HoraInicio").ToString <> Dr2("HoraInicio").ToString Then
|
||||
If Not ObjGral.AddHistorialBitacora(372, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Nothing, Dr("HoraInicio").ToString, $"{Dr("CodigoPS").ToString} - {Dr2("HoraInicio").ToString}", UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, 1, "Se elimino " & Dr("CodigoPS").ToString, "PS", "", CvePromocion:=CvePromocion) Then
|
||||
@@ -1043,7 +1035,7 @@ Partial Class Ventas_Promociones
|
||||
If EmpresaFnc382 AndAlso EstatusOriginal = False AndAlso ChkEstatus.Checked And BloqueadoPromocionPorcentaje Then
|
||||
|
||||
Dim objGeneral As New ClsGenerales(ObjVentas.IniciaTransacSQL)
|
||||
If Not objGeneral.AddHistorialBitacora(360, -1, -1, -1, -1, -1, -1, -1, "Si Autoriza con bloqueo", "No", UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, 0, "", "", "", CvePromocion:=CvePromocion) Then
|
||||
If Not objGeneral.AddHistorialBitacora(360, -1, -1, -1, -1, -1, -1, -1, "Se Autorizo con bloqueo", "No", UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, 0, "", "", "", CvePromocion:=CvePromocion) Then
|
||||
TieneError = True
|
||||
End If
|
||||
|
||||
@@ -1069,6 +1061,51 @@ Partial Class Ventas_Promociones
|
||||
End Sub
|
||||
#End Region
|
||||
|
||||
#Region "ENVIAR CORREO PROMOSION BLOQUEADA"
|
||||
|
||||
|
||||
Private Sub MandaCorreoNotificacionPromocionBloqueo(CvePromocionNueva As Integer, PromocionNueva As String)
|
||||
Dim Asunto, Para, ArrayCC, Body, URL As String
|
||||
Asunto = $"Promoción {PromocionNueva} requiere autorización"
|
||||
Para = ""
|
||||
ArrayCC = ""
|
||||
URL = ""
|
||||
|
||||
If Request.Url.Port = 80 Then
|
||||
URL = $"{Request.Url.Scheme}://{Request.Url.Host}{Request.Url.AbsolutePath}?CvePromocion={CvePromocionNueva}"
|
||||
Else
|
||||
URL = $"{Request.Url.Scheme}://{Request.Url.Host}:{Request.Url.Port}{Request.Url.AbsolutePath}?CvePromocion={CvePromocionNueva}"
|
||||
End If
|
||||
|
||||
Body = $"Se a registrado promoción que requiere autorización <a href='{URL}' >{PromocionNueva}</a>"
|
||||
|
||||
Dim objUsu As New ClsSisUsuarios
|
||||
Dim ListaCorreos As New List(Of String)
|
||||
If objUsu.GetPermisosPorUsuarioProcesos(-1, -1, -1, -1, 386, CveEmpresa:=UsuarioActual.CveEmpresa) Then
|
||||
For Each dRow As DataRow In objUsu.DtResultados.Rows
|
||||
If dRow("Correo").ToString.Trim.Length > 0 Then
|
||||
ListaCorreos.Add(dRow("Correo").ToString)
|
||||
End If
|
||||
Next
|
||||
End If
|
||||
objUsu.Dispose()
|
||||
|
||||
If ListaCorreos.Count > 0 Then
|
||||
|
||||
Para = String.Join(";", ListaCorreos)
|
||||
|
||||
Dim Mail As New ClsSisMail()
|
||||
Dim LSRutasMail As New List(Of ClsSisMail.ArchivoMail)
|
||||
Mail.SendMail(ClsPaginas.EmpresaNotificaciones, Para, Asunto, Body, ArrayCC, LSRutasMail)
|
||||
|
||||
End If
|
||||
|
||||
|
||||
End Sub
|
||||
|
||||
|
||||
#End Region
|
||||
|
||||
|
||||
#Region " ELIMINAR "
|
||||
Protected Sub BtnEliminar_Click(sender As Object, e As EventArgs)
|
||||
@@ -1114,22 +1151,6 @@ Partial Class Ventas_Promociones
|
||||
End Sub
|
||||
#End Region
|
||||
|
||||
'Protected Sub DdlTipoPromocion_SelectedIndexChanged(sender As Object, e As EventArgs) Handles DdlTipoPromocion.SelectedIndexChanged
|
||||
' If DdlTipoPromocion.SelectedValue = "3" Then
|
||||
' DivCantMinima.Visible = True
|
||||
' Else
|
||||
' DivCantMinima.Visible = False
|
||||
' End If
|
||||
'End Sub
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
Protected Sub GvDatos_RowDataBound(sender As Object, e As GridViewRowEventArgs)
|
||||
|
||||
@@ -1294,11 +1315,6 @@ Partial Class Ventas_Promociones
|
||||
ObjPS.Dispose()
|
||||
|
||||
|
||||
'Dim ObjGral As New ClsGenerales
|
||||
'If ObjGral.GetRinTamanios(UsuarioActual.CveEmpresa) Then
|
||||
' DTRines = ObjGral.DtResultados
|
||||
'End If
|
||||
'ObjGral.Dispose()
|
||||
DTRines = GlobalDTPSRinTamaños(UsuarioActual.CveEmpresa)
|
||||
|
||||
Dim RegistroActual As Integer = 1
|
||||
@@ -1308,8 +1324,6 @@ Partial Class Ventas_Promociones
|
||||
|
||||
Dim ClasificacionStr, CodigoStr, TipoPromocionStr, PromocionStr, CantidadMinimaStr, RinStr, IncluyeImpuestosStr As String
|
||||
|
||||
|
||||
|
||||
ClasificacionStr = dRow("Clasificacion").ToString.Trim
|
||||
CodigoStr = dRow("Codigo").ToString.Trim
|
||||
TipoPromocionStr = dRow("TipoPromocion").ToString.Trim
|
||||
@@ -1387,7 +1401,6 @@ Partial Class Ventas_Promociones
|
||||
|
||||
Next
|
||||
|
||||
|
||||
If Errores.ToString.Length = 0 Then
|
||||
DTPlantilla.AcceptChanges()
|
||||
Return True
|
||||
@@ -1396,20 +1409,23 @@ Partial Class Ventas_Promociones
|
||||
Return False
|
||||
End If
|
||||
|
||||
|
||||
|
||||
|
||||
End Function
|
||||
|
||||
Protected Sub DdlPS_selectedindexchange(sender As Object, e As EventArgs)
|
||||
|
||||
Dim DTPSUltimoCosto = New DataTable
|
||||
|
||||
Dim ObjInv As New ClsInventarios
|
||||
If ObjInv.GetUltimoCosto(UsuarioActual.CveEmpresa) Then
|
||||
DTPSUltimoCosto = ObjInv.DtResultados
|
||||
End If
|
||||
ObjInv.Dispose()
|
||||
|
||||
LblUltimoCosto.Text = DTPSUltimoCosto.FiltroPrimeroValor("UltimoCosto", $"CvePS = {DdlPS.SelectedValue}").FormatoNumero
|
||||
LblCostoPromedio.Text = DTPSUltimoCosto.FiltroPrimeroValor("CostoPromedio", $"CvePS = {DdlPS.SelectedValue}").FormatoNumero
|
||||
|
||||
UpAgregar.Update()
|
||||
|
||||
End Sub
|
||||
|
||||
|
||||
End Class
|
||||
@@ -242,7 +242,9 @@
|
||||
<asp:HyperLinkField ItemStyle-HorizontalAlign="Left" Target="_blank" HeaderText="Grupo" DataTextField="GPO" DataNavigateUrlFields="FechaI,FechaF,CveSubProyecto,CveCliente,CveVendedor,Grupo,GPO,CvePS,CveClasificacion,CveMarca,CveCategoria" DataNavigateUrlFormatString="RepVentasUtilidad.aspx?FechaI={0}&FechaF={1}&CveSubProyecto={2}&CveCliente={3}&CveVendedor={4}&Gpo={5}&CveGpo={6}&CvePS={7}&CveClasificacion={8}&CveMarca={9}&CveCategoria={10}" />
|
||||
<asp:BoundField ItemStyle-HorizontalAlign="Right" HeaderText="Ventas" DataField="Ventas" DataFormatString="{0:N2}" />
|
||||
<asp:BoundField ItemStyle-HorizontalAlign="Right" HeaderText="Crédito" DataField="Credito" DataFormatString="{0:N2}" />
|
||||
<asp:BoundField ItemStyle-HorizontalAlign="Right" HeaderText="% Crédito" DataField="PorcentajeCredito" ItemStyle-Width="30px" />
|
||||
<asp:BoundField ItemStyle-HorizontalAlign="Right" HeaderText="Contado" DataField="Contado" DataFormatString="{0:N2}" />
|
||||
<asp:BoundField ItemStyle-HorizontalAlign="Right" HeaderText="% Contado" DataField="PorcentajeCredito" ItemStyle-Width="30px" />
|
||||
|
||||
<asp:BoundField ItemStyle-HorizontalAlign="Right" HeaderText="%" DataField="ProcentajeVentas" DataFormatString="{0:N2}" ItemStyle-Width="30px" />
|
||||
<asp:BoundField ItemStyle-HorizontalAlign="Right" HeaderText="Descuento" DataField="Descuento" DataFormatString="{0:N2}" />
|
||||
|
||||
@@ -32,6 +32,11 @@ Partial Class Ventas_RepVentasUtilidadPadre
|
||||
|
||||
Protected Sub Page_Load(sender As Object, e As System.EventArgs) Handles Me.Load
|
||||
If Not IsPostBack Then
|
||||
If UsuarioActual.Empresa.Funcionalidad(382) <> "1" Then
|
||||
GvDatos.Columns(3).Visible = False
|
||||
GvDatos.Columns(5).Visible = False
|
||||
End If
|
||||
|
||||
CargaCombos()
|
||||
End If
|
||||
End Sub
|
||||
|
||||
@@ -1131,6 +1131,7 @@
|
||||
<th></th>
|
||||
<th runat="server" visible="false" id="nomostrar2"></th>
|
||||
<th runat="server" visible="false" id="thProntoPago2"></th>
|
||||
<th runat="server" visible="false" id="thCosto2"></th>
|
||||
</tr>
|
||||
<tr class="TextTab" runat="server" id="TrEdit">
|
||||
<th>
|
||||
@@ -1254,9 +1255,10 @@
|
||||
<%--<th style="text-align: center;">
|
||||
<asp:LinkButton ID="LbVerInventario" ClientIDMode="Static" runat="server" CssClass="btn btn-circle btn-sm purple" Text="<i class='icon-magnifier'></i>"></asp:LinkButton>
|
||||
</th>--%>
|
||||
<th runat="server" id="thOrden"></th>
|
||||
<th runat="server" visible="false" id="nomostrar"></th>
|
||||
<th runat="server" visible="false" id="thProntoPago"></th>
|
||||
|
||||
<th runat="server" visible="false" id="thCosto"></th>
|
||||
</tr>
|
||||
</table>
|
||||
<%--</asp:Panel>--%>
|
||||
@@ -1519,6 +1521,8 @@
|
||||
</asp:TemplateField>
|
||||
<%--22--%>
|
||||
<asp:BoundField DataField="TieneProntoPago" HeaderText="Pronto Pago" ItemStyle-Width="5%" ItemStyle-HorizontalAlign="Center" ReadOnly="true" Visible="false" />
|
||||
<%--23--%>
|
||||
<asp:BoundField DataField="Costo" HeaderText="Costo" DataFormatString="{0:0.######}" ItemStyle-Width="5%" ItemStyle-HorizontalAlign="Right" ReadOnly="true" Visible="false" />
|
||||
</Columns>
|
||||
<RowStyle CssClass="Texto" />
|
||||
<AlternatingRowStyle CssClass="TextoAlterno" />
|
||||
|
||||
@@ -1370,6 +1370,15 @@ Partial Class Ventas
|
||||
End Set
|
||||
End Property
|
||||
|
||||
Private Property ListaDevolucionesAplicadas As List(Of Modelos.MAnticipoRelacionado)
|
||||
Get
|
||||
Return If(IsNothing(ViewState("ListaDevolucionesAplicadas")), Nothing, CType(ViewState("ListaDevolucionesAplicadas"), List(Of Modelos.MAnticipoRelacionado)))
|
||||
End Get
|
||||
Set(value As List(Of Modelos.MAnticipoRelacionado))
|
||||
ViewState("ListaDevolucionesAplicadas") = value
|
||||
End Set
|
||||
End Property
|
||||
|
||||
Private Property CveTimbreCartaPorteVenta As Integer
|
||||
Get
|
||||
Return If(IsNothing(ViewState("CveTimbreCartaPorteVenta")), -1, ViewState("CveTimbreCartaPorteVenta").ToString().ToEntero())
|
||||
@@ -2805,6 +2814,9 @@ Partial Class Ventas
|
||||
TmpDT.Columns.Add("NumeroPedimento", GetType(String))
|
||||
TmpDT.Columns.Add("CodigoAlterno", GetType(String))
|
||||
TmpDT.Columns.Add("PSAlterno", GetType(String))
|
||||
TmpDT.Columns.Add("Costo", GetType(Decimal))
|
||||
TmpDT.Columns("Costo").DefaultValue = 0D
|
||||
|
||||
GvPS.DataSource = ObjVentas.DtResultados
|
||||
GvPS.DataBind()
|
||||
|
||||
@@ -2823,6 +2835,9 @@ Partial Class Ventas
|
||||
If ObjCGame.ManifiestoForVtaGet(UsuarioActual.CveEmpresa, UsuarioActual.CveUsuario, Request("CveManifiesto").ToEntero()) Then
|
||||
GvPS.DataSource = ObjCGame.DtResultados
|
||||
TmpDT = ObjCGame.DtResultados
|
||||
TmpDT.Columns.Add("Costo", GetType(Decimal))
|
||||
TmpDT.Columns("Costo").DefaultValue = 0D
|
||||
|
||||
GvPS.DataBind()
|
||||
End If
|
||||
|
||||
@@ -2866,6 +2881,8 @@ Partial Class Ventas
|
||||
TmpDT.Columns.Add("NumeroPedimento", GetType(String))
|
||||
TmpDT.Columns.Add("CodigoAlterno", GetType(String))
|
||||
TmpDT.Columns.Add("PSAlterno", GetType(String))
|
||||
TmpDT.Columns.Add("Costo", GetType(Decimal))
|
||||
TmpDT.Columns("Costo").DefaultValue = 0D
|
||||
GvPS.DataSource = ObjVentas.DtResultados
|
||||
GvPS.DataBind()
|
||||
|
||||
@@ -4922,6 +4939,9 @@ Partial Class Ventas
|
||||
TmpDT.Columns.Add("ImporteProntoPago", GetType(Decimal))
|
||||
TmpDT.Columns.Add("AFDepreciacion", GetType(Decimal))
|
||||
TmpDT.Columns.Add("AFValorInicial", GetType(Decimal))
|
||||
|
||||
TmpDT.Columns.Add("Costo", GetType(Decimal))
|
||||
TmpDT.Columns("Costo").DefaultValue = 0D
|
||||
End If
|
||||
|
||||
CargaAFVenta()
|
||||
@@ -5844,6 +5864,7 @@ Partial Class Ventas
|
||||
'Ocultamos los botones Clonar y Ordenar
|
||||
GvPS.Columns(19).Visible = False
|
||||
GvPS.Columns(20).Visible = False
|
||||
thOrden.Visible = False
|
||||
|
||||
GvFirmas.DataSource = DTmpF
|
||||
GvFirmas.DataBind()
|
||||
@@ -9125,8 +9146,18 @@ Partial Class Ventas
|
||||
Dim CostoMenor As Decimal = 0
|
||||
Dim CostoMayor As Decimal = 0
|
||||
|
||||
Dim PorcentajeMinimoCostoEmpresa = UsuarioActual.Empresa.Funcionalidad(129).ToDecimal
|
||||
|
||||
If UsuarioActual.Empresa.Funcionalidad(382) = "1" Then
|
||||
If DatarowPS IsNot Nothing Then
|
||||
If DatarowPS("PorcentajeMinimoUtilidad").ToString().ToDecimal() > 0 Then
|
||||
PorcentajeMinimoCostoEmpresa = DatarowPS("PorcentajeMinimoUtilidad").ToString().ToDecimal()
|
||||
End If
|
||||
End If
|
||||
End If
|
||||
|
||||
'PRECIO MINIMO
|
||||
If UsuarioActual.Empresa.Funcionalidad(129).ToEntero() > 0 AndAlso UsuarioActual.CveUsuario <> 1560 Then
|
||||
If PorcentajeMinimoCostoEmpresa > 0 AndAlso UsuarioActual.CveUsuario <> 1560 Then
|
||||
'' NOTA. si tiene preciominimo, debe de validarlos e ignorar el costo, pero se debe de considerar el TC, para el costo
|
||||
If PrecioMinimo > 0 Then
|
||||
'SI EL PRECIO ES MAYOR AL COSTO, SI PASA
|
||||
@@ -9134,7 +9165,7 @@ Partial Class Ventas
|
||||
EsValido = True
|
||||
End If
|
||||
Else
|
||||
CostoMenor = Costo + ((UsuarioActual.Empresa.Funcionalidad(129).ToDecimal / 100) * Costo)
|
||||
CostoMenor = Costo + ((PorcentajeMinimoCostoEmpresa / 100) * Costo)
|
||||
'SI EL PRECIO ES MAYOR AL COSTO, SI PASA
|
||||
If PU * If(DdlMoneda.SelectedValue.ToEntero() = 1, 1, TxtTipoCambio.Text.ToDecimal) >= CostoMenor Then
|
||||
EsValido = True
|
||||
@@ -9172,7 +9203,7 @@ Partial Class Ventas
|
||||
MensajeCosto.AppendFormat("El Producto <b>{0}</b>. No se puede vender a un precio menor de su Costo <br/>", DatarowPS("PS").ToString())
|
||||
If TienePermisoImportes Then
|
||||
MensajeCosto.AppendFormat("El costo del producto es: <b>${0:#,###.00}</b> <br/>", Costo)
|
||||
MensajeCosto.AppendFormat("El rango menor aceptado es: {0:#,###.00}% <b>${1}</b> <br/>", UsuarioActual.Empresa.Funcionalidad(129).ToEntero(), CostoMenor)
|
||||
MensajeCosto.AppendFormat("El rango menor aceptado es: {0:#,###.00}% <b>${1}</b> <br/>", PorcentajeMinimoCostoEmpresa, CostoMenor)
|
||||
MensajeCosto.AppendFormat("El precio indicado es: <b>${0:#,###.00}</b> ({1}% de ganancia) <br/>", PU.FormatoNumero, (If(Costo > 0, ((PU - Costo) * 100) / Costo, 0)).FormatoNumero)
|
||||
End If
|
||||
|
||||
@@ -10103,8 +10134,19 @@ Partial Class Ventas
|
||||
|
||||
End If
|
||||
|
||||
Dim PorcentajeMinimoCostoEmpresa = UsuarioActual.Empresa.Funcionalidad(129).ToDecimal
|
||||
|
||||
If UsuarioActual.Empresa.Funcionalidad(382) = "1" Then
|
||||
Dim DrPSCosto As DataRow = GlobalDTPS(UsuarioActual.CveEmpresa, CvePS:=dr("CvePS").ToString().ToEntero()).Rows(0)
|
||||
If DrPSCosto IsNot Nothing Then
|
||||
If DrPSCosto("PorcentajeMinimoUtilidad").ToString().ToDecimal() > 0 Then
|
||||
PorcentajeMinimoCostoEmpresa = DrPSCosto("PorcentajeMinimoUtilidad").ToString().ToDecimal()
|
||||
End If
|
||||
End If
|
||||
End If
|
||||
|
||||
'PRECIO MINIMO
|
||||
If UsuarioActual.Empresa.Funcionalidad(129).ToEntero() > 0 AndAlso UsuarioActual.CveUsuario <> 1560 Then
|
||||
If PorcentajeMinimoCostoEmpresa > 0 AndAlso UsuarioActual.CveUsuario <> 1560 Then
|
||||
'' NOTA. si tiene preciominimo, debe de validarlos e ignorar el costo, pero se debe de considerar el TC, para el costo
|
||||
If PrecioMinimo > 0 Then
|
||||
'SI EL PRECIO ES MAYOR AL COSTO, SI PASA
|
||||
@@ -10112,7 +10154,7 @@ Partial Class Ventas
|
||||
EsValido = True
|
||||
End If
|
||||
Else
|
||||
CostoMenor = Costo + ((UsuarioActual.Empresa.Funcionalidad(129).ToDecimal / 100) * Costo)
|
||||
CostoMenor = Costo + ((PorcentajeMinimoCostoEmpresa / 100) * Costo)
|
||||
'SI EL PRECIO ES MAYOR AL COSTO, SI PASA
|
||||
If PU * If(DdlMoneda.SelectedValue.ToEntero() = 1, 1, TxtTipoCambio.Text.ToDecimal) >= CostoMenor Then
|
||||
EsValido = True
|
||||
@@ -10151,7 +10193,7 @@ Partial Class Ventas
|
||||
MensajeCosto.AppendFormat("El Producto <b>{0}</b>. No se puede vender a un precio menor de su Costo ni a un precio mayor de su rango aceptado<br/>", dr("PS").ToString())
|
||||
If TienePermisoImportes Then
|
||||
MensajeCosto.AppendFormat("El costo del producto es: <b>{0:#,###.00}$</b> <br/>", Costo)
|
||||
MensajeCosto.AppendFormat("El rango menor aceptado es: {0} <b>{1:#,###.00}$</b> <br/>", UsuarioActual.Empresa.Funcionalidad(129).ToEntero(), CostoMenor)
|
||||
MensajeCosto.AppendFormat("El rango menor aceptado es: {0} <b>{1:#,###.00}$</b> <br/>", PorcentajeMinimoCostoEmpresa, CostoMenor)
|
||||
MensajeCosto.AppendFormat("El precio indicado es: <b>{0:#,###.00}$</b> ({1}% de ganancia) <br/>", PU.FormatoNumero, If(Costo > 0, ((PU - Costo) * 100) / Costo, 0))
|
||||
End If
|
||||
End If
|
||||
@@ -10948,6 +10990,10 @@ Partial Class Ventas
|
||||
ListaAnticiposAplicados.Clear()
|
||||
End If
|
||||
|
||||
If ListaDevolucionesAplicadas IsNot Nothing Then
|
||||
ListaDevolucionesAplicadas.Clear()
|
||||
End If
|
||||
|
||||
'ENVIAR POLIZA VIRTUAL
|
||||
If ErrorList.Count = 0 Then
|
||||
If UsuarioActual.Empresa.Funcionalidad(576) = "1" AndAlso EsProduccion Then
|
||||
@@ -13472,6 +13518,26 @@ Partial Class Ventas
|
||||
Next
|
||||
End If
|
||||
|
||||
'DEVOLUCIONES DE OTRA VENTA, APLICADAS EN UNA NUEVA
|
||||
If UsuarioActual.CveEmpresa.Contiene(1, 189) AndAlso Obj.TipoDocto = "Ing" AndAlso DdlTipoAmortizacionAnticipo.SelectedValue = "4" Then
|
||||
If ListaDevolucionesAplicadas IsNot Nothing AndAlso ListaDevolucionesAplicadas.Count > 0 Then
|
||||
Timbre.CFDIRelacionados.UUID.Clear()
|
||||
For Each Dev As Modelos.MAnticipoRelacionado In ListaDevolucionesAplicadas
|
||||
Timbre.CFDIRelacionados.UUID.Add(Dev.FolioFiscal)
|
||||
Next
|
||||
|
||||
'TEMPORAL- DEBE SER TIPO RELACION "01 - Nota de crédito de los documentos relacionados"
|
||||
Dim CveTipoRelacion As Integer = 1
|
||||
|
||||
Obj.CveTipoRelacion = CveTipoRelacion
|
||||
|
||||
Dim RowTipoRelacion As DataRow = GlobalDTVtaTiposRelacion().FiltroPrimero($"CveTipoRelacion = {CveTipoRelacion}")
|
||||
|
||||
Timbre.CFDIRelacionados.TipoRelacion = RowTipoRelacion("SATClaveTipoRelacion").ToString()
|
||||
Timbre.CFDIRelacionados.TipoRelacionTexto = RowTipoRelacion("SATTipoRelacion").ToString()
|
||||
End If
|
||||
End If
|
||||
|
||||
Dim totSubTotal As Decimal = Obj.SubTotal
|
||||
Dim totIVA As Decimal = Obj.IVA
|
||||
Dim totRetIVA As Decimal = Obj.RetIVA
|
||||
@@ -17438,6 +17504,12 @@ Partial Class Ventas
|
||||
ListaAnticiposAplicados = New List(Of Modelos.MAnticipoRelacionado)
|
||||
End If
|
||||
|
||||
If ListaDevolucionesAplicadas IsNot Nothing Then
|
||||
ListaDevolucionesAplicadas.Clear()
|
||||
Else
|
||||
ListaDevolucionesAplicadas = New List(Of Modelos.MAnticipoRelacionado)
|
||||
End If
|
||||
|
||||
HdnIVACalculado.Value = HdnIVAOriginal.Value
|
||||
For Each gvr As GridViewRow In GVAnticipos.Rows
|
||||
If gvr.FCCheckBox("Chk" & gvr.RowIndex) IsNot Nothing AndAlso gvr.FCCheckBox("Chk" & gvr.RowIndex).Checked AndAlso gvr.DataKey("CveConceptoContable").ToEntero().Contiene(3) Then
|
||||
@@ -17448,6 +17520,13 @@ Partial Class Ventas
|
||||
|
||||
'CvePSAmortizacion = GlobalDTPS(UsuarioActual.CveEmpresa).FiltroPrimeroValor("CvePS", "CveConceptoContable = 11").ToEntero()
|
||||
End If
|
||||
|
||||
'AGREGAR LAS DEV
|
||||
If UsuarioActual.CveEmpresa.Contiene(1, 189) AndAlso DdlTipoAmortizacionAnticipo.SelectedValue.Contiene("4") Then
|
||||
If gvr.FCCheckBox("Chk" & gvr.RowIndex) IsNot Nothing AndAlso gvr.FCCheckBox("Chk" & gvr.RowIndex).Checked AndAlso gvr.DataKey("CveConceptoContable").ToEntero().Contiene(12) Then
|
||||
ListaDevolucionesAplicadas.Add(New Modelos.MAnticipoRelacionado() With {.CveVenta = gvr.DataKey("CveVenta").ToEntero(), .FolioFiscal = gvr.DataKey("FolioFiscal")})
|
||||
End If
|
||||
End If
|
||||
Next
|
||||
'Amortizacion += TmpDTImpuestos.SUM("Importe").ToDecimal 'RMF. 2018.12.20- saque de la jugada en la amortización los impuestos locales
|
||||
|
||||
@@ -19300,8 +19379,19 @@ Partial Class Ventas
|
||||
Dim CostoMenor As Decimal = 0.0D
|
||||
Dim CostoMayor As Decimal = 0.0D
|
||||
|
||||
Dim PorcentajeMinimoCostoEmpresa = UsuarioActual.Empresa.Funcionalidad(129).ToDecimal
|
||||
|
||||
If UsuarioActual.Empresa.Funcionalidad(382) = "1" Then
|
||||
Dim DrPSCosto As DataRow = GlobalDTPS(UsuarioActual.CveEmpresa, CvePS:=CvePS).Rows(0)
|
||||
If DrPSCosto IsNot Nothing Then
|
||||
If DrPSCosto("PorcentajeMinimoUtilidad").ToString().ToDecimal() > 0 Then
|
||||
PorcentajeMinimoCostoEmpresa = DrPSCosto("PorcentajeMinimoUtilidad").ToString().ToDecimal()
|
||||
End If
|
||||
End If
|
||||
End If
|
||||
|
||||
'PRECIO MINIMO
|
||||
If UsuarioActual.Empresa.Funcionalidad(129).ToEntero() > 0 AndAlso UsuarioActual.CveUsuario <> 1560 Then
|
||||
If PorcentajeMinimoCostoEmpresa > 0 AndAlso UsuarioActual.CveUsuario <> 1560 Then
|
||||
'' NOTA. si tiene preciominimo, debe de validarlos e ignorar el costo, pero se debe de considerar el TC, para el costo
|
||||
If PrecioMinimo > 0 Then
|
||||
'SI EL PRECIO ES MAYOR AL COSTO, SI PASA
|
||||
@@ -19309,7 +19399,7 @@ Partial Class Ventas
|
||||
EsValido = True
|
||||
End If
|
||||
Else
|
||||
CostoMenor = Costo + ((UsuarioActual.Empresa.Funcionalidad(129).ToDecimal / 100) * Costo)
|
||||
CostoMenor = Costo + ((PorcentajeMinimoCostoEmpresa / 100) * Costo)
|
||||
'SI EL PRECIO ES MAYOR AL COSTO, SI PASA
|
||||
If PU * If(DdlMoneda.SelectedValue.ToEntero() = 1, 1, TxtTipoCambio.Text.ToDecimal) >= CostoMenor Then
|
||||
EsValido = True
|
||||
@@ -19363,7 +19453,7 @@ Partial Class Ventas
|
||||
MensajeCosto.AppendFormat("El Producto <b>{0}-{1}</b>. No se puede vender a un precio menor de su Costo <br/>", HdnCodigoPS.Value, HdnPS.Value)
|
||||
If TienePermisoImportes Then
|
||||
MensajeCosto.AppendFormat("El costo del producto es: <b>${0:#,###.00}</b> <br/>", Costo)
|
||||
MensajeCosto.AppendFormat("El rango menor aceptado es: {0}% <b>${1:#,###.00}</b> <br/>", UsuarioActual.Empresa.Funcionalidad(129).ToEntero(), CostoMenor)
|
||||
MensajeCosto.AppendFormat("El rango menor aceptado es: {0}% <b>${1:#,###.00}</b> <br/>", PorcentajeMinimoCostoEmpresa, CostoMenor)
|
||||
MensajeCosto.AppendFormat("El precio indicado es: <b>${0:#,###.00}</b> ({1}% de ganancia) <br/>", PU.FormatoNumero, (If(Costo > 0, ((PU - Costo) * 100) / Costo, 0)).FormatoNumero)
|
||||
End If
|
||||
|
||||
@@ -19677,11 +19767,23 @@ Partial Class Ventas
|
||||
NumTurnos = TxtNumTurnos.Text.ToDecimal()
|
||||
End If
|
||||
|
||||
'SI TIENE PERMISO PARA VER COSTO, QUE LO AGREGUE AL TMPDT
|
||||
Dim Costo As Decimal = 0
|
||||
If UsuarioActual.Empresa.Funcionalidad(382) = "1" AndAlso UsuarioActual.TienePermisoProceso(385) Then
|
||||
Dim ObjInventarios As New ClsInventarios
|
||||
|
||||
Costo = ObjInventarios.GetCostoPS(CvePS, TxtCantidad.Text.Trim.ToDecimal, -1, "-1", TxtFecha.Text.ToDate, DdlSubProyectoDatos.SelectedValue.ToEntero(), CveTipoAlmacen:=1)
|
||||
'si el costo es cero, puede ser que no halla movimientos del producto, en esa sucursal. y se volverá a sacar sin especificar sucursal
|
||||
If Costo <= 0 Then Costo = ObjInventarios.GetCostoPS(CvePS, TxtCantidad.Text.Trim.ToDecimal, -1, "-1", TxtFecha.Text.ToDate, -1, CveTipoAlmacen:=1)
|
||||
|
||||
ObjInventarios.Dispose()
|
||||
End If
|
||||
|
||||
AgregarProductoServicio(Cantidad, DdlUnidadMedida.SelectedValue.ToEntero(), DdlUnidadMedida.SelectedItem.Text, DdlClasificacion.SelectedValue.ToEntero(), DdlClasificacion.SelectedItem.Text,
|
||||
CvePS, "", TxtObsPS.Text.TrimEnd, PU, ObjDescuento.ImporteDescuento,
|
||||
DdlProyecto.SelectedValue.ToEntero(), DdlProyecto.SelectedItem.Text, DdlSubProyecto.SelectedValue.ToEntero(), DdlSubProyecto.SelectedItem.Text,
|
||||
Serie:=If(DIVCod.Visible, TxtCodigoSerie.Text.Trim, ""), TiempoEntrega:=TxtTiempoEntrega.Text, CuentaPredial:=TxtCuentaPredial.Text.Trim, RegeneraIEPS:=ClienteDesglosaIEPS, CvePromocionDetalle:=ObjDescuento.CvePromocionDetalle,
|
||||
ImporteProntoPago:=ObjDescuento.ImporteProntoPago, ObjDescuento:=ObjDescuento, CvePrecioLista:=CvePrecioListaPS, PrecioLista:=PrecioListaPS, NumTurnos:=NumTurnos)
|
||||
ImporteProntoPago:=ObjDescuento.ImporteProntoPago, ObjDescuento:=ObjDescuento, CvePrecioLista:=CvePrecioListaPS, PrecioLista:=PrecioListaPS, NumTurnos:=NumTurnos, Costo:=Costo)
|
||||
|
||||
CalculaUsados()
|
||||
|
||||
@@ -19833,7 +19935,8 @@ Partial Class Ventas
|
||||
Optional CveOrdenCompraDetalle As Integer = 0, Optional CveVentaDetalleRemision As Integer = 0, Optional CveVentaDetalleCotizacion As Integer = 0, Optional CuentaPredial As String = "",
|
||||
Optional RegeneraIEPS As Boolean = True, Optional CveVentaDetallePedido2 As Integer = 0, Optional SeActualiza As Boolean = False, Optional CvePromocionDetalle As Integer = -1, Optional EsCargo As Boolean = False,
|
||||
Optional ImporteProntoPago As Decimal = 0, Optional ByRef ObjDescuento As Modelos.VentaDescuentos = Nothing, Optional CvePrecioLista As Integer = -1, Optional PrecioLista As String = "",
|
||||
Optional CveActivoFijo As Integer = -1, Optional AFDepreciacion As Decimal = 0D, Optional AFValorInicial As Decimal = 0D, Optional NumTurnos As Decimal = 0D, Optional CantidadConversion As Decimal = 0) As Boolean
|
||||
Optional CveActivoFijo As Integer = -1, Optional AFDepreciacion As Decimal = 0D, Optional AFValorInicial As Decimal = 0D, Optional NumTurnos As Decimal = 0D, Optional CantidadConversion As Decimal = 0,
|
||||
Optional Costo As Decimal = 0) As Boolean
|
||||
|
||||
Dim Retorno As Boolean = False
|
||||
Try
|
||||
@@ -20090,6 +20193,7 @@ Partial Class Ventas
|
||||
Row("AFValorInicial") = AFValorInicial
|
||||
|
||||
Row("NumTurnos") = NumTurnos
|
||||
Row("Costo") = Costo
|
||||
|
||||
Row("CodigoAlterno") = DrPS("CodigoAlterno")
|
||||
Row("PSAlterno") = DrPS("PSAlterno")
|
||||
@@ -20356,6 +20460,9 @@ Partial Class Ventas
|
||||
TmpDT.Columns("CantidadConversion").DefaultValue = 0
|
||||
|
||||
TmpDT.Columns.Add("TotalConImpuestos", GetType(Decimal))
|
||||
|
||||
TmpDT.Columns.Add("Costo", GetType(Decimal))
|
||||
TmpDT.Columns("Costo").DefaultValue = 0D
|
||||
End Sub
|
||||
Private Sub CreaDTmpC()
|
||||
DTmpC = New DataTable
|
||||
@@ -21305,6 +21412,16 @@ Partial Class Ventas
|
||||
HlAgregarExcel.Visible = True
|
||||
End If
|
||||
|
||||
If (CveVenta <= 0 OrElse EsCreaApartirDe) AndAlso UsuarioActual.Empresa.Funcionalidad(382) = "1" AndAlso DdlTipoComprobante.SelectedValue = "Cot" Then
|
||||
GvPS.Columns(23).Visible = True
|
||||
thCosto.Visible = True
|
||||
thCosto2.Visible = True
|
||||
Else
|
||||
GvPS.Columns(23).Visible = False
|
||||
thCosto.Visible = False
|
||||
thCosto2.Visible = False
|
||||
End If
|
||||
UpPS.Update()
|
||||
UpCargaExceles.Update()
|
||||
|
||||
UpFacturar.Update()
|
||||
@@ -24425,7 +24542,7 @@ Partial Class Ventas
|
||||
'SI ES AMORTIZACION POR NOTA DE CREDITO DEBE SUMAR LA TOTALIDAD PARA COMPARAR EL PAGO
|
||||
If DdlTipoComprobante.SelectedValue.Contiene("Ing", "Ant") AndAlso DdlTipoAmortizacionAnticipo.SelectedValue.Contiene("2", "4") Then
|
||||
For Each gvr As GridViewRow In GVAnticipos.Rows
|
||||
If gvr.FCCheckBox("Chk" & gvr.RowIndex) IsNot Nothing AndAlso gvr.FCCheckBox("Chk" & gvr.RowIndex).Checked AndAlso gvr.DataKey("CveConceptoContable").ToEntero().Contiene(3, 12) Then
|
||||
If gvr.FCCheckBox("Chk" & gvr.RowIndex) IsNot Nothing AndAlso gvr.FCCheckBox("Chk" & gvr.RowIndex).Checked AndAlso gvr.DataKey("CveConceptoContable").ToEntero().Contiene(3, 12, 66) Then
|
||||
AmortizacionNC += gvr.FCTextBox(String.Format("TxtAnticipo{0}", gvr.RowIndex)).Text.ToDecimal
|
||||
End If
|
||||
Next
|
||||
@@ -27045,6 +27162,7 @@ Partial Class Ventas
|
||||
GvPS.Columns(17).Visible = False
|
||||
GvPS.Columns(19).Visible = False
|
||||
GvPS.Columns(20).Visible = False
|
||||
thOrden.Visible = False
|
||||
|
||||
DdlVendedor.SelectedValue = DbRowVenta("CveVendedor").ToString()
|
||||
DdlTipoComprobante.Enabled = False
|
||||
@@ -30920,6 +31038,8 @@ Partial Class Ventas
|
||||
'TmpDT.Columns.Add("CveActivoFijo", GetType(Integer))
|
||||
TmpDT.Columns.Add("AFDepreciacion", GetType(Decimal))
|
||||
TmpDT.Columns.Add("AFValorInicial", GetType(Decimal))
|
||||
TmpDT.Columns.Add("Costo", GetType(Decimal))
|
||||
TmpDT.Columns("Costo").DefaultValue = 0D
|
||||
End If
|
||||
Dim FechaFactura As DateTime = NowADS()
|
||||
|
||||
@@ -31562,6 +31682,8 @@ Partial Class Ventas
|
||||
GvPS.Columns(18).Visible = False
|
||||
GvPS.Columns(19).Visible = False
|
||||
GvPS.Columns(20).Visible = False
|
||||
thOrden.Visible = False
|
||||
|
||||
DivRemisionesFacturadas.Visible = False
|
||||
DivAnticiposVinculados.Visible = False
|
||||
|
||||
@@ -36366,6 +36488,8 @@ Partial Class Ventas
|
||||
TmpDT.Columns.Add("CveMovimientoDetallePedido", GetType(Integer))
|
||||
TmpDT.Columns.Add("AFDepreciacion", GetType(Decimal))
|
||||
TmpDT.Columns.Add("AFValorInicial", GetType(Decimal))
|
||||
TmpDT.Columns.Add("Costo", GetType(Decimal))
|
||||
TmpDT.Columns("Costo").DefaultValue = 0D
|
||||
End If
|
||||
|
||||
If ObjVentas.GetVenta(CveVentaNC, UsuarioActual.CveEmpresa, VerificaAlmacen:=False) Then
|
||||
@@ -36530,6 +36654,8 @@ Partial Class Ventas
|
||||
TmpDT.Columns("NumTurnos").DefaultValue = 0D
|
||||
TmpDT.Columns.Add("NumeroPedimento", GetType(String))
|
||||
TmpDT.Columns.Add("TotalConImpuestos", GetType(Decimal))
|
||||
TmpDT.Columns.Add("Costo", GetType(Decimal))
|
||||
TmpDT.Columns("Costo").DefaultValue = 0D
|
||||
|
||||
Return TmpDT
|
||||
End Function
|
||||
|
||||
Reference in New Issue
Block a user