Merge branch 'master' of http://192.168.10.111:8383/SIG
This commit is contained in:
@@ -9562,6 +9562,7 @@ Public Class ClsPaginas
|
|||||||
Public Property CveCompraAmortizacion As Integer = 0
|
Public Property CveCompraAmortizacion As Integer = 0
|
||||||
Public Property OtroGastoIngreso As Decimal = 0
|
Public Property OtroGastoIngreso As Decimal = 0
|
||||||
Public Property CveConceptoPago As Integer = -1 'no definido de inicio
|
Public Property CveConceptoPago As Integer = -1 'no definido de inicio
|
||||||
|
Public Property CveCreditoDetalle As Integer = -1
|
||||||
|
|
||||||
End Class
|
End Class
|
||||||
|
|
||||||
|
|||||||
@@ -860,6 +860,9 @@ Public Class ClsVentas
|
|||||||
|
|
||||||
Return Retorno
|
Return Retorno
|
||||||
End Function
|
End Function
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
Public Function UpdateVentaRNCUsado(CveVentaRNC As Integer, CveVenta As Integer) As Boolean
|
Public Function UpdateVentaRNCUsado(CveVentaRNC As Integer, CveVenta As Integer) As Boolean
|
||||||
Dim Retorno As Boolean = False
|
Dim Retorno As Boolean = False
|
||||||
|
|
||||||
@@ -5544,6 +5547,29 @@ Public Class ClsVentas
|
|||||||
|
|
||||||
#End Region
|
#End Region
|
||||||
|
|
||||||
|
Public Function GetListadoCartaPorteRep(FechaI As Date, FechaF As Date, CveSubProyecto As String, CveUsuarioConsulta As Integer, CveEmpresa As Integer) As Boolean
|
||||||
|
|
||||||
|
Dim Retorno As Boolean = False
|
||||||
|
DataAdapter("PA_Vta_RepListadoCartaPorteGet")
|
||||||
|
With SqlAdapter.SelectCommand.Parameters
|
||||||
|
.Add("@FechaI", SqlDbType.Date).Value = FechaI
|
||||||
|
.Add("@FechaF", SqlDbType.Date).Value = FechaF
|
||||||
|
.Add("@CveSubProyecto", SqlDbType.VarChar).Value = CveSubProyecto
|
||||||
|
.Add("@CveUsuarioConsulta", SqlDbType.Int).Value = CveUsuarioConsulta
|
||||||
|
.Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa
|
||||||
|
End With
|
||||||
|
Try
|
||||||
|
SqlAdapter.Fill(Data)
|
||||||
|
Retorno = True
|
||||||
|
Catch ex As Exception
|
||||||
|
OnError("Ocurrió un error obtener el listado de carta porte.", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo())
|
||||||
|
End Try
|
||||||
|
Return Retorno
|
||||||
|
|
||||||
|
|
||||||
|
End Function
|
||||||
|
|
||||||
|
|
||||||
#Region "IDisposable Support"
|
#Region "IDisposable Support"
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -4832,7 +4832,7 @@ Public Class Timbrado
|
|||||||
|
|
||||||
If ObjCFDITimbre.Conceptos IsNot Nothing AndAlso ObjCFDITimbre.Conceptos.Count > 0 Then
|
If ObjCFDITimbre.Conceptos IsNot Nothing AndAlso ObjCFDITimbre.Conceptos.Count > 0 Then
|
||||||
For Each concep As CFDIConceptos In ObjCFDITimbre.Conceptos
|
For Each concep As CFDIConceptos In ObjCFDITimbre.Conceptos
|
||||||
cfdi.Concepto(concep.ClaveProdServ, concep.Noidentificacion, concep.Cantidad, concep.ClaveUnidad, concep.Unidad, concep.Descripcion, concep.ValorUnitario, concep.Importe, concep.Descuento, concep.ObjetoImpuesto)
|
cfdi.Concepto(concep.ClaveProdServ, concep.Noidentificacion, concep.Cantidad.ToString("0.00####"), concep.ClaveUnidad, concep.Unidad, concep.Descripcion, concep.ValorUnitario.ToString("0.00####"), concep.Importe, concep.Descuento, concep.ObjetoImpuesto)
|
||||||
For Each imp As CFDIConceptosImpuestos In concep.Impuestos
|
For Each imp As CFDIConceptosImpuestos In concep.Impuestos
|
||||||
If imp.TrasladooRetencion = "T" Then
|
If imp.TrasladooRetencion = "T" Then
|
||||||
cfdi.ConceptoTraslado(imp.Base, imp.Impuesto, imp.TipoFactor, imp.TasaOCuota, imp.Importe)
|
cfdi.ConceptoTraslado(imp.Base, imp.Impuesto, imp.TipoFactor, imp.TasaOCuota, imp.Importe)
|
||||||
|
|||||||
@@ -5957,19 +5957,31 @@ Partial Class Compras_Compras
|
|||||||
ErrorPrepoliza = True
|
ErrorPrepoliza = True
|
||||||
End If
|
End If
|
||||||
|
|
||||||
If TipoCreditoInteres Then
|
If importeMovimiento <> 0 Then
|
||||||
|
Dim Pago As New CompraPago
|
||||||
|
Pago.ImportePago = importeMovimiento
|
||||||
|
Pago.CveIE = CveIE
|
||||||
|
Pago.CveMonedaPago = 1
|
||||||
|
Pago.CveCompraAmortizacion = -1
|
||||||
|
Pago.CveCreditoDetalle = CveCreditoDetalle
|
||||||
|
|
||||||
Dim importeMovimientoIn As Decimal = ImporteIECredito - importeMovimiento
|
ErrorMovtosCxP = AplicaPrePolizaPago(CompraActual, Pago, CvePrePoliza, ObjConta)
|
||||||
Dim importeMNIn As Decimal = importeMovimientoIn * tipoCambioActual * Multiplicador
|
|
||||||
|
|
||||||
If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, True, importeMovimientoIn, importeMNIn, 41, Referencia, Concepto, CtaProveedorAcreedores, CveCompra:=CveCompra, CveProveedor:=CveProveedorConcepto, CveIE:=CveIE, CveCreditoDetalle:=CveCreditoDetalle, CveClasificacion:=CveClasificacionDT, CveSubProyecto:=CveSubProyectoDT, ImporteME:=If(tipoCambioActual = 1, 0, importeMovimientoIn), CveTipoGasto:=CveTipoGastoDT, TipoCambio:=tipoCambioActual, Contabilizable:=SeContabiliza) Then
|
|
||||||
ErrorPrepoliza = True
|
|
||||||
End If
|
|
||||||
If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, False, importeMovimientoIn, importeMNIn, 50, Referencia, Concepto, ViewState("IdCtaContDocsXPagar").ToString.ToEntero(), CveCompra:=CveCompra, CveProveedor:=CveProveedorConcepto, CveIE:=CveIE, CveCreditoDetalle:=CveCreditoDetalle, CveClasificacion:=CveClasificacionDT, CveSubProyecto:=CveSubProyectoDT, ImporteME:=If(tipoCambioActual = 1, 0, importeMovimientoIn), CveTipoGasto:=CveTipoGastoDT, TipoCambio:=tipoCambioActual, Contabilizable:=SeContabiliza) Then
|
|
||||||
ErrorPrepoliza = True
|
|
||||||
|
|
||||||
End If
|
|
||||||
End If
|
End If
|
||||||
|
|
||||||
|
'If TipoCreditoInteres Then
|
||||||
|
|
||||||
|
' Dim importeMovimientoIn As Decimal = ImporteIECredito - importeMovimiento
|
||||||
|
' Dim importeMNIn As Decimal = importeMovimientoIn * tipoCambioActual * Multiplicador
|
||||||
|
|
||||||
|
' If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, True, importeMovimientoIn, importeMNIn, 41, Referencia, Concepto, CtaProveedorAcreedores, CveCompra:=CveCompra, CveProveedor:=CveProveedorConcepto, CveIE:=CveIE, CveCreditoDetalle:=CveCreditoDetalle, CveClasificacion:=CveClasificacionDT, CveSubProyecto:=CveSubProyectoDT, ImporteME:=If(tipoCambioActual = 1, 0, importeMovimientoIn), CveTipoGasto:=CveTipoGastoDT, TipoCambio:=tipoCambioActual, Contabilizable:=SeContabiliza) Then
|
||||||
|
' ErrorPrepoliza = True
|
||||||
|
' End If
|
||||||
|
' If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, False, importeMovimientoIn, importeMNIn, 50, Referencia, Concepto, ViewState("IdCtaContDocsXPagar").ToString.ToEntero(), CveCompra:=CveCompra, CveProveedor:=CveProveedorConcepto, CveIE:=CveIE, CveCreditoDetalle:=CveCreditoDetalle, CveClasificacion:=CveClasificacionDT, CveSubProyecto:=CveSubProyectoDT, ImporteME:=If(tipoCambioActual = 1, 0, importeMovimientoIn), CveTipoGasto:=CveTipoGastoDT, TipoCambio:=tipoCambioActual, Contabilizable:=SeContabiliza) Then
|
||||||
|
' ErrorPrepoliza = True
|
||||||
|
|
||||||
|
' End If
|
||||||
|
'End If
|
||||||
End If
|
End If
|
||||||
importeMovimiento = 0 : importeMN = 0
|
importeMovimiento = 0 : importeMN = 0
|
||||||
If TipoCambioCompra > 1 AndAlso DdlMoneda.SelectedValue.ToEntero <> 1 Then Concepto += $" TC{TipoCambioCompra} ${importeMovimiento.FormatoNumero(2)}"
|
If TipoCambioCompra > 1 AndAlso DdlMoneda.SelectedValue.ToEntero <> 1 Then Concepto += $" TC{TipoCambioCompra} ${importeMovimiento.FormatoNumero(2)}"
|
||||||
|
|||||||
@@ -63,8 +63,8 @@
|
|||||||
<asp:LinkButton ID="lbDescargar" runat="server"><i class="fa fa-download"></i>
|
<asp:LinkButton ID="lbDescargar" runat="server"><i class="fa fa-download"></i>
|
||||||
Descarga Facturas SAT</asp:LinkButton>
|
Descarga Facturas SAT</asp:LinkButton>
|
||||||
</li>--%>
|
</li>--%>
|
||||||
<li>
|
<li>
|
||||||
<asp:LinkButton ID="LnkShowSolicitudes" OnClick="LnkShowSolicitudes_Click" runat="server">Solicitudes SAT</asp:LinkButton>
|
<asp:LinkButton ID="LnkShowSolicitudes" OnClick="LnkShowSolicitudes_Click" runat="server"> <i class="fa fa-external-link"></i> Solicitudes SAT</asp:LinkButton>
|
||||||
</li>
|
</li>
|
||||||
<li>
|
<li>
|
||||||
<asp:LinkButton ID="LnkBitacotaFacturas" runat="server" OnClick="LnkBitacotaFacturas_Click"><i class="fa fa-book" ></i> Bitácora Facturas</asp:LinkButton>
|
<asp:LinkButton ID="LnkBitacotaFacturas" runat="server" OnClick="LnkBitacotaFacturas_Click"><i class="fa fa-book" ></i> Bitácora Facturas</asp:LinkButton>
|
||||||
@@ -1008,202 +1008,275 @@
|
|||||||
</ContentTemplate>
|
</ContentTemplate>
|
||||||
</asp:UpdatePanel>
|
</asp:UpdatePanel>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="ModalViewSolicitudes" class="modal ADS fade" role="dialog">
|
|
||||||
<asp:UpdatePanel ID="UPModalViewSolicitudes" class="modal-dialog rowpadding" tabindex="-1" runat="server" UpdateMode="Conditional">
|
|
||||||
<contenttemplate>
|
<div id="ModalViewSolicitudes" class="modal ADS fade" role="dialog">
|
||||||
|
<asp:UpdatePanel ID="UPModalViewSolicitudes" class="modal-dialog rowpadding xspadding" tabindex="-1" runat="server" UpdateMode="Conditional">
|
||||||
|
<ContentTemplate>
|
||||||
<div class="modal-content">
|
<div class="modal-content">
|
||||||
<div class="modal-header">
|
<div class="modal-header">
|
||||||
<button type="button" class="close" data-dismiss="modal">×</button>
|
<button type="button" class="close" data-dismiss="modal">×</button>
|
||||||
<h4 class="modal-title">Solicitudes CFDI</h4>
|
<h4 class="modal-title">Solicitudes CFDI</h4>
|
||||||
</div>
|
</div>
|
||||||
<div class="modal-body">
|
<div class="modal-body">
|
||||||
<br />
|
|
||||||
<div class="portlet light xspadding bordered " id="PnlAgregar">
|
|
||||||
<div class="portlet-title">
|
|
||||||
<div class="caption ">
|
|
||||||
<i class="fa fa-bookmark font-yellow-gold"></i>
|
<div class="row">
|
||||||
<span class="caption-subject font-yellow-gold bold uppercase">Solicitar información al sat</span>
|
<div class="col-md-12" style="text-align: right">
|
||||||
</div>
|
<asp:LinkButton ID="LnkAgregarSolictud" runat="server" data-toggle="tooltip" data-placement="right" OnClick="LnkAgregarSolictud_Click" title="Agregar Solicitud." CssClass="btn btn-circle btn-default" Text="<i class='fa fa-plus'></i> Agregar Solicitud"></asp:LinkButton>
|
||||||
<div class="tools">
|
|
||||||
<a href="javascript:;" class="expand" data-original-title="" title=""></a>
|
|
||||||
<a href="javascript:;" class="fullscreen" data-original-title="" title=""></a>
|
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
<div class="portlet-body nomarginleftright form-horizontal form-row-sepe formnombottom " style="display: none">
|
</div>
|
||||||
<div class="row">
|
|
||||||
<div class="col-md-4">
|
|
||||||
|
|
||||||
<asp:Label runat="server" Text="Fecha Inicio" AssociatedControlID="txtFechaIAdd"></asp:Label>
|
|
||||||
</div>
|
|
||||||
<div class="col-md-4">
|
|
||||||
|
|
||||||
<asp:Label runat="server" Text="Fecha Fin" AssociatedControlID="txtFechaFAdd"></asp:Label>
|
<ajax:TabContainer runat="server" ID="TabPanel" ActiveTabIndex="0">
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div class="row">
|
|
||||||
<div class="col-md-4">
|
|
||||||
<div class="input-group input-sm input-small date date-picker " data-date-format="dd/mm/yyyy" style="width: 138px !important; padding: 0px; margin-bottom: -10px;">
|
|
||||||
<asp:TextBox ID="txtFechaIAdd" CssClass="form-control input-sm ADSMaskDate" Style="" runat="server"></asp:TextBox>
|
|
||||||
<span class="input-group-btn ">
|
|
||||||
<asp:LinkButton ID="LnkFechaIAdd" class="btn default " Text="<i class='fa fa-calendar'></i>" runat="server"></asp:LinkButton>
|
|
||||||
</span>
|
|
||||||
<ajax:maskededitextender id="MEEFechaIAdd" runat="server" targetcontrolid="txtFechaIAdd" mask="99/99/9999" masktype="Date" displaymoney="Left" acceptnegative="Left"></ajax:maskededitextender>
|
|
||||||
<ajax:calendarextender runat="server" id="CalendarExtender1" targetcontrolid="txtFechaIAdd" popupbuttonid="LnkFechaIAdd" popupposition="BottomRight" enabled="True"></ajax:calendarextender>
|
|
||||||
<asp:RequiredFieldValidator ID="rfvFechaIAdd" runat="server" ControlToValidate="txtFechaIAdd" Display="None" ErrorMessage="El campo <b>''Fecha Inicial''</b> es requerido por la aplicación, por favor ingrese una fecha." ValidationGroup="VGAdd"></asp:RequiredFieldValidator>
|
|
||||||
<asp:CompareValidator ID="cvFechaIAdd" runat="server" ControlToValidate="txtFechaIAdd" Display="None" ErrorMessage="El campo <b>''Fecha Inicial''</b> no tienes el formato correcto, por favor intente de nuevo con el siguiente formato: (dd/mm/yyyy)." Operator="DataTypeCheck" Type="Date" ValidationGroup="Valida"></asp:CompareValidator>
|
|
||||||
<ajax:validatorcalloutextender id="ValidatorCalloutExtender3" runat="server" highlightcssclass="vco" targetcontrolid="rfvFechaIAdd" width="350px"></ajax:validatorcalloutextender>
|
|
||||||
<ajax:validatorcalloutextender id="ValidatorCalloutExtender4" runat="server" highlightcssclass="vco" targetcontrolid="cvFechaIAdd" width="350px"></ajax:validatorcalloutextender>
|
|
||||||
|
|
||||||
|
<ajax:TabPanel runat="server" HeaderText="Pendientes" ID="TabPendientes">
|
||||||
|
<ContentTemplate>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<div class="row">
|
||||||
|
<div class="col-md-12">
|
||||||
|
<asp:GridView ID="GVSolicitudesPendientes" runat="server" GridLines="None" CssClass="table table-striped table-hover Widthall ScrollAD mysmallbtn" AutoGenerateColumns="False"
|
||||||
|
ShowHeaderWhenEmpty="true" EmptyDataText="No se encontraron registros"
|
||||||
|
DataKeyNames="CveSolicitud,CveSolicitudCFDI,CveSolicitudMetadata,Estatus,Observaciones,FechaInicio,FechaFin,FechaIng,CveUsuarioIng,CveEmpresa,ArchivoXML,idSolicitud,CveSolicitudDetalle,Folio,CveTipoSolicitud">
|
||||||
|
<Columns>
|
||||||
|
<asp:TemplateField HeaderText="Folio">
|
||||||
|
<ItemTemplate>
|
||||||
|
<asp:Label runat="server" Text='<%# Eval("Folio")%>'></asp:Label>
|
||||||
|
</ItemTemplate>
|
||||||
|
</asp:TemplateField>
|
||||||
|
<asp:TemplateField HeaderText="Fecha Inicio">
|
||||||
|
<ItemTemplate>
|
||||||
|
<asp:Label ID="lblfechaInicio" runat="server" Text='<%# Eval("FechaInicio", "{0:dd/MM/yyyy}")%>'></asp:Label>
|
||||||
|
</ItemTemplate>
|
||||||
|
</asp:TemplateField>
|
||||||
|
<asp:TemplateField HeaderText="Fecha Fin">
|
||||||
|
<ItemTemplate>
|
||||||
|
<asp:Label ID="lblfechaFin" runat="server" Text='<%# Eval("FechaFin", "{0:dd/MM/yyyy}")%>'></asp:Label>
|
||||||
|
</ItemTemplate>
|
||||||
|
</asp:TemplateField>
|
||||||
|
<asp:TemplateField HeaderText="Estatus">
|
||||||
|
<ItemTemplate>
|
||||||
|
<asp:Label ID="lblestatus" runat="server" Text='<%# Eval("EstatusText")%>'></asp:Label>
|
||||||
|
</ItemTemplate>
|
||||||
|
</asp:TemplateField>
|
||||||
|
<asp:TemplateField HeaderText="Observaciones">
|
||||||
|
<ItemTemplate>
|
||||||
|
<asp:Label ID="lblobservaciones" runat="server" Text='<%# Eval("Observaciones")%>'></asp:Label>
|
||||||
|
</ItemTemplate>
|
||||||
|
</asp:TemplateField>
|
||||||
|
|
||||||
|
|
||||||
|
<asp:TemplateField HeaderText="Tipo" ItemStyle-HorizontalAlign="Center">
|
||||||
|
<ItemTemplate>
|
||||||
|
<asp:Label runat="server" ID="lBLTipoDescarga" Text='<%# Eval("TipoDescarga")%>'></asp:Label>
|
||||||
|
</ItemTemplate>
|
||||||
|
</asp:TemplateField>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<asp:TemplateField HeaderText="Fecha solicitud">
|
||||||
|
<ItemTemplate>
|
||||||
|
<asp:Label runat="server" Text='<%# Eval("FechaIng", "{0:dd/MM/yyyy}")%>'></asp:Label>
|
||||||
|
</ItemTemplate>
|
||||||
|
</asp:TemplateField>
|
||||||
|
<asp:TemplateField HeaderText="Solicitó">
|
||||||
|
<ItemTemplate>
|
||||||
|
<asp:Label runat="server" Text='<%# Eval("UsuarioIng")%>'></asp:Label>
|
||||||
|
</ItemTemplate>
|
||||||
|
</asp:TemplateField>
|
||||||
|
</Columns>
|
||||||
|
</asp:GridView>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="col-md-4">
|
<div class="row">
|
||||||
<div class="input-group input-sm input-small date date-picker " data-date-format="dd/mm/yyyy" style="width: 138px !important; padding: 0px; margin-bottom: -10px;">
|
<div class="col-md-12" style="text-align: center">
|
||||||
<asp:TextBox ID="txtFechaFAdd" CssClass="form-control input-sm ADSMaskDate" Style="" runat="server"></asp:TextBox>
|
<asp:LinkButton ID="LnkverificarSolicitudes" CssClass="btn btn-primary" OnClick="LnkverificarSolicitudes_Click" runat="server">Verificar pendientes</asp:LinkButton>
|
||||||
<span class="input-group-btn ">
|
|
||||||
<asp:LinkButton ID="LnkFechaFAdd" class="btn default " Text="<i class='fa fa-calendar'></i>" runat="server"></asp:LinkButton>
|
|
||||||
</span>
|
|
||||||
<ajax:maskededitextender id="MEEFechaFAdd" runat="server" targetcontrolid="txtFechaFAdd" mask="99/99/9999" masktype="Date" displaymoney="Left" acceptnegative="Left"></ajax:maskededitextender>
|
|
||||||
<ajax:calendarextender runat="server" id="CalendarExtender2" targetcontrolid="txtFechaFAdd" popupbuttonid="LnkFechaFAdd" popupposition="BottomRight" enabled="True"></ajax:calendarextender>
|
|
||||||
<asp:RequiredFieldValidator ID="rfvFechaFAdd" runat="server" ControlToValidate="txtFechaFAdd" Display="None" ErrorMessage="El campo <b>''Fecha Final''</b> es requerido por la aplicación, por favor ingrese una fecha." ValidationGroup="VGAdd"></asp:RequiredFieldValidator>
|
|
||||||
<asp:CompareValidator ID="cvFechaFAdd" runat="server" ControlToValidate="txtFechaFAdd" Display="None" ErrorMessage="El campo <b>''Fecha Final''</b> no tienes el formato correcto, por favor intente de nuevo con el siguiente formato: (dd/mm/yyyy)." Operator="DataTypeCheck" Type="Date" ValidationGroup="Valida"></asp:CompareValidator>
|
|
||||||
<ajax:validatorcalloutextender id="ValidatorCalloutExtender5" runat="server" highlightcssclass="vco" targetcontrolid="rfvFechaFAdd" width="350px"></ajax:validatorcalloutextender>
|
|
||||||
<ajax:validatorcalloutextender id="ValidatorCalloutExtender6" runat="server" highlightcssclass="vco" targetcontrolid="cvFechaFAdd" width="350px"></ajax:validatorcalloutextender>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div class="col-md-4">
|
|
||||||
|
|
||||||
<div class="text-right">
|
|
||||||
<asp:LinkButton ID="LnkSolicitarSat" CssClass="btn btn-primary" OnClick="LnkSolicitarSat_Click" runat="server">Solicitar</asp:LinkButton>
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div class="portlet light xspadding bordered " id="PnlPendientes">
|
|
||||||
<div class="portlet-title">
|
|
||||||
<div class="caption ">
|
|
||||||
<i class="fa fa-bookmark font-yellow-gold"></i>
|
|
||||||
<span class="caption-subject font-yellow-gold bold uppercase">Solicitudes pendientes de respuesta del SAT </span>
|
|
||||||
</div>
|
|
||||||
<div class="tools">
|
|
||||||
<a href="javascript:;" class="collapse" data-original-title="" title=""></a>
|
|
||||||
<a href="javascript:;" class="fullscreen" data-original-title="" title=""></a>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div class="portlet-body nomarginleftright form-horizontal form-row-sepe formnombottom ">
|
|
||||||
|
|
||||||
<asp:GridView ID="GVSolicitudesPendientes" runat="server" GridLines="None" CssClass="table table-hover table-striped ScrollAD Widthall" AutoGenerateColumns="False"
|
|
||||||
ShowHeaderWhenEmpty="true" EmptyDataText="No se encontraron registros"
|
|
||||||
DataKeyNames="CveSolicitud,CveSolicitudCFDI,CveSolicitudMetadata,Estatus,Observaciones,FechaInicio,FechaFin,FechaIng,CveUsuarioIng,CveEmpresa">
|
|
||||||
<columns>
|
</ContentTemplate>
|
||||||
<asp:TemplateField HeaderText="Folio">
|
</ajax:TabPanel>
|
||||||
<itemtemplate>
|
|
||||||
<asp:Label runat="server" Text='<%# Eval("CveSolicitud")%>'></asp:Label>
|
|
||||||
</itemtemplate>
|
<ajax:TabPanel runat="server" HeaderText="Historial" ID="TabHistorial">
|
||||||
</asp:TemplateField>
|
<ContentTemplate>
|
||||||
<asp:TemplateField HeaderText="Fecha Inicio">
|
|
||||||
<itemtemplate>
|
|
||||||
<asp:Label ID="lblfechaInicio" runat="server" Text='<%# Eval("FechaInicio","{0:dd/MM/yyyy}")%>'></asp:Label>
|
|
||||||
</itemtemplate>
|
|
||||||
</asp:TemplateField>
|
<div class="row">
|
||||||
<asp:TemplateField HeaderText="Fecha Fin">
|
<div class="col-md-12">
|
||||||
<itemtemplate>
|
<asp:GridView ID="GVSolicitudesNominas" runat="server" GridLines="None" CssClass="table table-striped table-hover Widthall ScrollAD mysmallbtn" AutoGenerateColumns="False" OnRowDataBound="GVSolicitudesNominas_RowDataBound"
|
||||||
<asp:Label ID="lblfechaFin" runat="server" Text='<%# Eval("FechaFin","{0:dd/MM/yyyy}")%>'></asp:Label>
|
ShowHeaderWhenEmpty="true" EmptyDataText="No se encontraron registros"
|
||||||
</itemtemplate>
|
DataKeyNames="CveSolicitudDetalle,CveSolicitud,idSolicitudCFDI,idSolicitudMetadata,Estatus,Observaciones,FechaInicio,FechaFin,FechaIng,CveUsuarioIng,CveEmpresa,ArchivoXML,Folio,CveTipoSolicitud,TipoDescargaStr">
|
||||||
</asp:TemplateField>
|
<Columns>
|
||||||
<asp:TemplateField HeaderText="Estatus">
|
<asp:TemplateField HeaderText="Folio">
|
||||||
<itemtemplate>
|
<ItemTemplate>
|
||||||
<asp:Label ID="lblestatus" runat="server" Text='<%# Eval("EstatusText")%>'></asp:Label>
|
<asp:Label runat="server" Text='<%# Eval("Folio")%>'></asp:Label>
|
||||||
</itemtemplate>
|
</ItemTemplate>
|
||||||
</asp:TemplateField>
|
</asp:TemplateField>
|
||||||
<asp:TemplateField HeaderText="Observaciones">
|
<asp:TemplateField HeaderText="Fecha Inicio">
|
||||||
<itemtemplate>
|
<ItemTemplate>
|
||||||
<asp:Label ID="lblobservaciones" runat="server" Text='<%# Eval("Observaciones")%>'></asp:Label>
|
<asp:Label ID="lblfechaInicio" runat="server" Text='<%# Eval("FechaInicio", "{0:dd/MM/yyyy}")%>'></asp:Label>
|
||||||
</itemtemplate>
|
</ItemTemplate>
|
||||||
</asp:TemplateField>
|
</asp:TemplateField>
|
||||||
<asp:TemplateField HeaderText="Fecha solicitud">
|
<asp:TemplateField HeaderText="Fecha Fin">
|
||||||
<itemtemplate>
|
<ItemTemplate>
|
||||||
<asp:Label runat="server" Text='<%# Eval("FechaIng","{0:dd/MM/yyyy HH:mm}")%>'></asp:Label>
|
<asp:Label ID="lblfechaFin" runat="server" Text='<%# Eval("FechaFin", "{0:dd/MM/yyyy}")%>'></asp:Label>
|
||||||
</itemtemplate>
|
</ItemTemplate>
|
||||||
</asp:TemplateField>
|
</asp:TemplateField>
|
||||||
<asp:TemplateField HeaderText="Solicitó">
|
<asp:TemplateField HeaderText="No CFDI" ItemStyle-HorizontalAlign="Right">
|
||||||
<itemtemplate>
|
<ItemTemplate>
|
||||||
<asp:Label runat="server" Text='<%# Eval("UsuarioIng")%>'></asp:Label>
|
<asp:Label ID="LblnumeroCFDIs" runat="server" Text='<%# Eval("numeroCFDIs")%>'></asp:Label>
|
||||||
</itemtemplate>
|
</ItemTemplate>
|
||||||
</asp:TemplateField>
|
</asp:TemplateField>
|
||||||
</columns>
|
<asp:TemplateField HeaderText="Observaciones">
|
||||||
</asp:GridView>
|
<ItemTemplate>
|
||||||
</div>
|
<asp:Label ID="lblobservaciones" runat="server" Text='<%# Eval("Observaciones")%>' ItemStyle-Width="150px" ControlStyle-Width="150px" CssClass="truncate" ></asp:Label>
|
||||||
</div>
|
</ItemTemplate>
|
||||||
<div class="portlet light xspadding bordered " id="PnlTerminads">
|
</asp:TemplateField>
|
||||||
<div class="portlet-title">
|
<asp:TemplateField HeaderText="Tipo" ItemStyle-HorizontalAlign="Center">
|
||||||
<div class="caption ">
|
<ItemTemplate>
|
||||||
<i class="fa fa-bookmark font-yellow-gold"></i>
|
<asp:Label runat="server" ID="lBLTipoDescarga" Text='<%# Eval("TipoDescarga")%>'></asp:Label>
|
||||||
<span class="caption-subject font-yellow-gold bold uppercase">solicitudes respondidas por el sat</span>
|
</ItemTemplate>
|
||||||
</div>
|
</asp:TemplateField>
|
||||||
<div class="tools">
|
<asp:TemplateField HeaderText="Fecha solicitud">
|
||||||
<a href="javascript:;" class="collapse" data-original-title="" title=""></a>
|
<ItemTemplate>
|
||||||
<a href="javascript:;" class="fullscreen" data-original-title="" title=""></a>
|
<asp:Label runat="server" Text='<%# Eval("FechaIng", "{0:dd/MM/yyyy}")%>'></asp:Label>
|
||||||
</div>
|
</ItemTemplate>
|
||||||
</div>
|
</asp:TemplateField>
|
||||||
<div class="portlet-body nomarginleftright form-horizontal form-row-sepe formnombottom ">
|
|
||||||
<asp:GridView ID="GVSolicitudesNominas" runat="server" GridLines="None" CssClass="table table-hover table-striped ScrollAD Widthall" AutoGenerateColumns="False"
|
<asp:TemplateField HeaderText="Solicitó" ItemStyle-Width="100px" ControlStyle-Width="100px">
|
||||||
ShowHeaderWhenEmpty="true" EmptyDataText="No se encontraron registros"
|
<ItemTemplate>
|
||||||
DataKeyNames="CveSolicitud,idSolicitudCFDI,idSolicitudMetadata,Estatus,Observaciones,FechaInicio,FechaFin,FechaIng,CveUsuarioIng,CveEmpresa">
|
<asp:Label runat="server" Text='<%# Eval("UsuarioIng")%>' CssClass="truncate"></asp:Label>
|
||||||
<columns>
|
</ItemTemplate>
|
||||||
<asp:TemplateField HeaderText="Folio">
|
</asp:TemplateField>
|
||||||
<itemtemplate>
|
|
||||||
<asp:Label runat="server" Text='<%# Eval("CveSolicitud")%>'></asp:Label>
|
<asp:TemplateField ItemStyle-HorizontalAlign="Right" ItemStyle-Width="50px" HeaderText="XML">
|
||||||
</itemtemplate>
|
<ItemTemplate>
|
||||||
</asp:TemplateField>
|
<asp:LinkButton ID="LnkDescargaXML" CssClass="btn btn-circle btn-sm blue" OnClick="LnkDescargaXML_Click" runat="server" ToolTip="Descargar archivo"
|
||||||
<asp:TemplateField HeaderText="Fecha Inicio">
|
Text="<i class='fa fa-download' style='color:white' title='Descargar Documento'></i>" CausesValidation="False" Visible="false" />
|
||||||
<itemtemplate>
|
</ItemTemplate>
|
||||||
<asp:Label ID="lblfechaInicio" runat="server" Text='<%# Eval("FechaInicio","{0:dd/MM/yyyy}")%>'></asp:Label>
|
</asp:TemplateField>
|
||||||
</itemtemplate>
|
<%--
|
||||||
</asp:TemplateField>
|
<asp:TemplateField HeaderText="R Nombres" Visible="false">
|
||||||
<asp:TemplateField HeaderText="Fecha Fin">
|
<ItemTemplate>
|
||||||
<itemtemplate>
|
<asp:LinkButton ID="LnkRenombrarArchivos" CssClass="btn btn-circle btn-sm blue" OnClick="LnkRenombrarArchivos_Click" runat="server" ToolTip="Renombrar Archivos"
|
||||||
<asp:Label ID="lblfechaFin" runat="server" Text='<%# Eval("FechaFin","{0:dd/MM/yyyy}")%>'></asp:Label>
|
Text="Renombrar" />
|
||||||
</itemtemplate>
|
</ItemTemplate>
|
||||||
</asp:TemplateField>
|
</asp:TemplateField>--%>
|
||||||
<asp:TemplateField HeaderText="No CFDI">
|
|
||||||
<itemtemplate>
|
</Columns>
|
||||||
<asp:Label ID="lblobservaciones" runat="server" Text='<%# Eval("numeroCFDIs")%>'></asp:Label>
|
</asp:GridView>
|
||||||
</itemtemplate>
|
</div>
|
||||||
</asp:TemplateField>
|
</div>
|
||||||
<asp:TemplateField HeaderText="Observaciones">
|
|
||||||
<itemtemplate>
|
|
||||||
<asp:Label ID="lblobservaciones" runat="server" Text='<%# Eval("Observaciones")%>'></asp:Label>
|
|
||||||
</itemtemplate>
|
|
||||||
</asp:TemplateField>
|
|
||||||
<asp:TemplateField HeaderText="Fecha solicitud">
|
|
||||||
<itemtemplate>
|
</ContentTemplate>
|
||||||
<asp:Label runat="server" Text='<%# Eval("FechaIng","{0:dd/MM/yyyy HH:mm}")%>'></asp:Label>
|
</ajax:TabPanel>
|
||||||
</itemtemplate>
|
|
||||||
</asp:TemplateField>
|
|
||||||
<asp:TemplateField HeaderText="Solicitó">
|
|
||||||
<itemtemplate>
|
|
||||||
<asp:Label runat="server" Text='<%# Eval("UsuarioIng")%>'></asp:Label>
|
|
||||||
</itemtemplate>
|
</ajax:TabContainer>
|
||||||
</asp:TemplateField>
|
|
||||||
</columns>
|
|
||||||
</asp:GridView>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
<div class="modal-footer">
|
<div class="modal-footer">
|
||||||
<asp:LinkButton ID="LnkverificarSolicitudes" CssClass="btn btn-primary" OnClick="LnkverificarSolicitudes_Click" runat="server">Verificar pendientes</asp:LinkButton>
|
|
||||||
<button type="button" class="btn btn-default" data-dismiss="modal">Cerrar</button>
|
<button type="button" class="btn btn-default" data-dismiss="modal">Cerrar</button>
|
||||||
</div>
|
</div>
|
||||||
</contenttemplate>
|
</div>
|
||||||
|
</ContentTemplate>
|
||||||
</asp:UpdatePanel>
|
</asp:UpdatePanel>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<div id="ModalAgregarSolicitud" class="modal ADS fade" role="dialog">
|
||||||
|
<asp:UpdatePanel ID="UPModalViewSolicitudesAgregar" class="modal-dialog rowpadding" tabindex="-1" runat="server" UpdateMode="Conditional">
|
||||||
|
<ContentTemplate>
|
||||||
|
|
||||||
|
<div class="modal-content">
|
||||||
|
<div class="modal-header">
|
||||||
|
<button type="button" class="close" data-dismiss="modal">×</button>
|
||||||
|
<h4 class="modal-title">Agregar Solicitud CFDI</h4>
|
||||||
|
</div>
|
||||||
|
<div class="modal-body">
|
||||||
|
|
||||||
|
<div class="row">
|
||||||
|
<div class="col-md-4">
|
||||||
|
<div class="form-group form-md-line-input input-iconright" style="width: 125px!important;height:28px!important">
|
||||||
|
<asp:TextBox ID="txtFechaIAdd" CssClass="form-control" MaxLength="20" runat="server" Width="100px" Height="28px"></asp:TextBox>
|
||||||
|
<span class="input-group-btn " style="position: absolute; right: 41px; top: -5px;">
|
||||||
|
<asp:LinkButton ID="LnkFechaIAdd" class="btn default" Style="margin-top: 15px; margin-left: 6px" Text="<i Style='margin-left: -6px;margin-top: -5px' class='fa fa-calendar'></i>" runat="server" Width="25px" Height="27px" ></asp:LinkButton>
|
||||||
|
</span>
|
||||||
|
<ajax:MaskedEditExtender ID="MEEFechaIAdd" runat="server" TargetControlID="txtFechaIAdd" Mask="99/99/9999" MaskType="Date" DisplayMoney="Left" AcceptNegative="Left"></ajax:MaskedEditExtender>
|
||||||
|
<ajax:CalendarExtender runat="server" ID="CalendarExtender1" TargetControlID="txtFechaIAdd" PopupButtonID="LnkFechaIAdd" PopupPosition="BottomRight" Enabled="True"></ajax:CalendarExtender>
|
||||||
|
<asp:RequiredFieldValidator ID="rfvFechaIAdd" runat="server" ControlToValidate="txtFechaIAdd" Display="None" ErrorMessage="El campo <b>''Fecha Inicial''</b> es requerido por la aplicación, por favor ingrese una fecha." ValidationGroup="GrpAddSolicitud"></asp:RequiredFieldValidator>
|
||||||
|
<asp:CompareValidator ID="cvFechaIAdd" runat="server" ControlToValidate="txtFechaIAdd" Display="None" ErrorMessage="El campo <b>''Fecha Inicial''</b> no tienes el formato correcto, por favor intente de nuevo con el siguiente formato: (dd/mm/yyyy)." Operator="DataTypeCheck" Type="Date" ValidationGroup="GrpAddSolicitud"></asp:CompareValidator>
|
||||||
|
<ajax:ValidatorCalloutExtender ID="ValidatorCalloutExtender3" runat="server" HighlightCssClass="vco" TargetControlID="rfvFechaIAdd" Width="350px"></ajax:ValidatorCalloutExtender>
|
||||||
|
<ajax:ValidatorCalloutExtender ID="ValidatorCalloutExtender4" runat="server" HighlightCssClass="vco" TargetControlID="cvFechaIAdd" Width="350px"></ajax:ValidatorCalloutExtender>
|
||||||
|
<label for="<%= txtFechaIAdd.ClientID.ToString() %>" style="margin-top: -6px">Fecha Inicio:</label>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="col-md-4">
|
||||||
|
<div class="form-group form-md-line-input input-iconright" style="width: 125px!important">
|
||||||
|
<asp:TextBox ID="txtFechaFAdd" CssClass="form-control" MaxLength="20" runat="server" Width="100px" Height="28px"></asp:TextBox>
|
||||||
|
<span class="input-group-btn " style="position: absolute; right: 41px; top: -5px;">
|
||||||
|
<asp:LinkButton ID="LnkFechaFAdd" class="btn default" Style="margin-top: 15px; margin-left: 6px" Text="<i Style='margin-left: -6px;margin-top: -5px' class='fa fa-calendar'></i>" runat="server" Width="25px" Height="27px" ></asp:LinkButton>
|
||||||
|
</span>
|
||||||
|
<ajax:MaskedEditExtender ID="MEEFechaFAdd" runat="server" TargetControlID="txtFechaFAdd" Mask="99/99/9999" MaskType="Date" DisplayMoney="Left" AcceptNegative="Left"></ajax:MaskedEditExtender>
|
||||||
|
<ajax:CalendarExtender runat="server" ID="CalendarExtender2" TargetControlID="txtFechaFAdd" PopupButtonID="LnkFechaFAdd" PopupPosition="BottomRight" Enabled="True"></ajax:CalendarExtender>
|
||||||
|
<asp:RequiredFieldValidator ID="rfvFechaFAdd" runat="server" ControlToValidate="txtFechaFAdd" Display="None" ErrorMessage="El campo <b>''Fecha Final''</b> es requerido por la aplicación, por favor ingrese una fecha." ValidationGroup="GrpAddSolicitud"></asp:RequiredFieldValidator>
|
||||||
|
<asp:CompareValidator ID="cvFechaFAdd" runat="server" ControlToValidate="txtFechaFAdd" Display="None" ErrorMessage="El campo <b>''Fecha Final''</b> no tienes el formato correcto, por favor intente de nuevo con el siguiente formato: (dd/mm/yyyy)." Operator="DataTypeCheck" Type="Date" ValidationGroup="GrpAddSolicitud"></asp:CompareValidator>
|
||||||
|
<ajax:ValidatorCalloutExtender ID="ValidatorCalloutExtender5" runat="server" HighlightCssClass="vco" TargetControlID="rfvFechaFAdd" Width="350px"></ajax:ValidatorCalloutExtender>
|
||||||
|
<ajax:ValidatorCalloutExtender ID="ValidatorCalloutExtender6" runat="server" HighlightCssClass="vco" TargetControlID="cvFechaFAdd" Width="350px"></ajax:ValidatorCalloutExtender>
|
||||||
|
<label for="<%= txtFechaFAdd.ClientID.ToString() %>" style="margin-top: -6px">Fecha Fin:</label>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="col-md-4" runat="server" visible="false">
|
||||||
|
<asp:CheckBox runat="server" ID="ChkMetaDatos" Text="Validación de Estatus" />
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
</div>
|
||||||
|
<div class="modal-footer">
|
||||||
|
<asp:LinkButton ID="LnkSolicitarSat" CssClass="btn btn-primary" OnClick="LnkSolicitarSat_Click" runat="server" ValidationGroup="GrpAddSolicitud">Solicitar</asp:LinkButton>
|
||||||
|
<button type="button" class="btn btn-default" data-dismiss="modal">Cerrar</button>
|
||||||
|
</div>
|
||||||
|
</ContentTemplate>
|
||||||
|
</asp:UpdatePanel>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -2552,51 +2552,160 @@ Partial Class Compras_eFacturas
|
|||||||
DTConceptos.Columns.Add("Total", GetType(Double))
|
DTConceptos.Columns.Add("Total", GetType(Double))
|
||||||
End Sub
|
End Sub
|
||||||
#End Region
|
#End Region
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
#Region "Sat descargamasiva"
|
#Region "Sat descargamasiva"
|
||||||
Private Sub cargasolicitudes()
|
Private Sub cargasolicitudes()
|
||||||
|
|
||||||
|
LnkverificarSolicitudes.Visible = False
|
||||||
|
|
||||||
Using nom As ClsNominas = New ClsNominas()
|
Using nom As ClsNominas = New ClsNominas()
|
||||||
|
|
||||||
If nom.SolicitudesGet(-1, UsuarioActual.CveEmpresa, 2) Then
|
If nom.SolicitudesGet(-1, UsuarioActual.CveEmpresa, CveTipoSolicitud:=2, Estatus:=0, Top:=50) Then
|
||||||
GVSolicitudesPendientes.DataSource = nom.DtResultados.FiltraParametros("Estatus =0")
|
GVSolicitudesPendientes.DataSource = nom.DtResultados
|
||||||
|
|
||||||
|
If nom.DtResultados.Rows.Count > 0 Then
|
||||||
|
LnkverificarSolicitudes.Visible = True
|
||||||
|
End If
|
||||||
|
|
||||||
GVSolicitudesPendientes.DataBind()
|
GVSolicitudesPendientes.DataBind()
|
||||||
GVSolicitudesNominas.DataSource = nom.DtResultados.FiltraParametros("Estatus =1")
|
End If
|
||||||
|
|
||||||
|
If nom.SolicitudesGet(-1, UsuarioActual.CveEmpresa, CveTipoSolicitud:=2, Estatus:=1, Top:=50) Then
|
||||||
|
GVSolicitudesNominas.DataSource = nom.DtResultados
|
||||||
GVSolicitudesNominas.DataBind()
|
GVSolicitudesNominas.DataBind()
|
||||||
End If
|
End If
|
||||||
End Using
|
End Using
|
||||||
|
|
||||||
UPModalViewSolicitudes.Update()
|
UPModalViewSolicitudes.Update()
|
||||||
|
|
||||||
|
|
||||||
End Sub
|
End Sub
|
||||||
Protected Sub LnkShowSolicitudes_Click(ByVal sender As Object, ByVal e As EventArgs)
|
Protected Sub LnkShowSolicitudes_Click(ByVal sender As Object, ByVal e As EventArgs)
|
||||||
|
|
||||||
|
TabPanel.ActiveTabIndex = 0
|
||||||
cargasolicitudes()
|
cargasolicitudes()
|
||||||
Me.RegistraScript("$('#ModalViewSolicitudes').modal();")
|
Me.RegistraScript("$('#ModalViewSolicitudes').modal();")
|
||||||
|
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
|
'Protected Sub LnkSolicitarSat_Click(ByVal sender As Object, ByVal e As EventArgs)
|
||||||
|
' 'Dim idSolicitudCFDI As Integer = 0
|
||||||
|
' 'Dim idSolicitudMetadata As Integer = 0
|
||||||
|
' 'Dim estatus As Integer = 0
|
||||||
|
' 'Dim observaciones As String = ""
|
||||||
|
' 'Dim fechaInicio As DateTime = txtFechaIAdd.Text.ToDateTime()
|
||||||
|
' 'Dim fechaFin As DateTime = txtFechaFAdd.Text.ToDateTime()
|
||||||
|
' 'Dim cveUsuarioIng As Integer = UsuarioActual.CveUsuario
|
||||||
|
' 'Dim cveEmpresa As Integer = UsuarioActual.CveEmpresa
|
||||||
|
' 'Dim Continuar As Boolean = False
|
||||||
|
|
||||||
|
' 'Using nom As ClsNominas = New ClsNominas()
|
||||||
|
' ' Continuar = nom.SolicitudesAdd(idSolicitudCFDI, idSolicitudMetadata, estatus, observaciones, fechaInicio, fechaFin, cveUsuarioIng, cveEmpresa, 2)
|
||||||
|
' ' Dim api = New GeneralesAPIeFacturas()
|
||||||
|
' ' api.GeneraSolicitud()
|
||||||
|
' ' api.VerificaSolicitudesNominas()
|
||||||
|
' 'End Using
|
||||||
|
|
||||||
|
' 'If Continuar Then
|
||||||
|
' ' txtFechaIAdd.Text = ""
|
||||||
|
' ' txtFechaFAdd.Text = ""
|
||||||
|
' ' Me.RegistraScript("$('#DModalSolicitudesNominas').modal('hide');")
|
||||||
|
' ' cargasolicitudes()
|
||||||
|
' ' Me.Alert("se a envia la solicitud al sat, le enviaremos un correo en cuanto tengamos una respuesta", ModExtensiones.TipoMensaje.ToastInformacion)
|
||||||
|
' 'End If
|
||||||
|
|
||||||
|
' Dim idSolicitudCFDI As Integer = 0
|
||||||
|
' Dim idSolicitudMetadata As Integer = 0
|
||||||
|
' Dim estatus As Integer = 0
|
||||||
|
' Dim observaciones As String = ""
|
||||||
|
' Dim fechaInicio As DateTime = txtFechaIAdd.Text.ToDateTime()
|
||||||
|
' Dim fechaFin As DateTime = txtFechaFAdd.Text.ToDateTime()
|
||||||
|
' Dim cveUsuarioIng As Integer = UsuarioActual.CveUsuario
|
||||||
|
' Dim cveEmpresa As Integer = UsuarioActual.CveEmpresa
|
||||||
|
' Dim Continuar As Boolean = False
|
||||||
|
|
||||||
|
' Using nom As ClsNominas = New ClsNominas()
|
||||||
|
' Continuar = nom.SolicitudesAdd(idSolicitudCFDI, idSolicitudMetadata, estatus, observaciones, fechaInicio, fechaFin, cveUsuarioIng, cveEmpresa, CveTipoSolicitud:=3)
|
||||||
|
' End Using
|
||||||
|
|
||||||
|
' If Continuar Then
|
||||||
|
' Dim sbResultado As StringBuilder = New StringBuilder()
|
||||||
|
' Dim api = New GeneralesAPIeFacturas()
|
||||||
|
' Dim ObjApiSolicitud As JToken = CType(api.GeneraSolicitud(UsuarioActual.CveEmpresa, 3), JToken)
|
||||||
|
' Dim resultSolicitud As List(Of String) = New List(Of String)()
|
||||||
|
' Dim resultVerificacion As List(Of String) = New List(Of String)()
|
||||||
|
' Dim ResultadoVerificaionOK = False
|
||||||
|
' Dim SeVerifico = False
|
||||||
|
' Dim TipoMensaje = ModExtensiones.TipoMensaje.MsgInformacion
|
||||||
|
' Dim ResultadoSolicitudOK = False
|
||||||
|
|
||||||
|
' If Not (ObjApiSolicitud Is Nothing) Then
|
||||||
|
' resultSolicitud = ObjApiSolicitud.[Select](Function(token) token.Values().Aggregate(Function(i, j) $"{i}|{j}").Value(Of String)()).ToList()
|
||||||
|
' ResultadoSolicitudOK = Boolean.Parse(resultSolicitud(0))
|
||||||
|
' Else
|
||||||
|
' TipoMensaje = ModExtensiones.TipoMensaje.MsgAdvertencia
|
||||||
|
' End If
|
||||||
|
|
||||||
|
' If ResultadoSolicitudOK Then
|
||||||
|
' Dim ObjApiVerificacion As JToken = CType(api.VerificaSolicitudesNominas(UsuarioActual.CveEmpresa, 3), JToken)
|
||||||
|
|
||||||
|
' If Not (ObjApiVerificacion Is Nothing) Then
|
||||||
|
' resultVerificacion = ObjApiVerificacion.[Select](Function(token) token.Values().Aggregate(Function(i, j) $"{i}|{j}").Value(Of String)()).ToList()
|
||||||
|
' ResultadoVerificaionOK = Boolean.Parse(resultVerificacion(0))
|
||||||
|
' SeVerifico = True
|
||||||
|
' Else
|
||||||
|
' TipoMensaje = ModExtensiones.TipoMensaje.MsgAdvertencia
|
||||||
|
' End If
|
||||||
|
' End If
|
||||||
|
|
||||||
|
' If resultSolicitud.Count = 4 Then
|
||||||
|
|
||||||
|
' If ResultadoSolicitudOK Then
|
||||||
|
|
||||||
|
' If resultSolicitud(1).ToString().Trim().Length > 0 Then
|
||||||
|
' sbResultado.Append($"{resultSolicitud(1)}<br/>")
|
||||||
|
' Else
|
||||||
|
' sbResultado.Append($"Solicitud Generada Correctamente")
|
||||||
|
' sbResultado.Append($"Se presento un error al verificar las solicitudes <br/> {resultSolicitud(1)} <br>")
|
||||||
|
' End If
|
||||||
|
' Else
|
||||||
|
' sbResultado.Append($"{resultSolicitud(1)}")
|
||||||
|
' TipoMensaje = ModExtensiones.TipoMensaje.MsgAdvertencia
|
||||||
|
' End If
|
||||||
|
' Else
|
||||||
|
' sbResultado.AppendLine("Se presento un error al generar la solicitud (API) <br/>")
|
||||||
|
' TipoMensaje = ModExtensiones.TipoMensaje.MsgAdvertencia
|
||||||
|
' End If
|
||||||
|
|
||||||
|
' If SeVerifico AndAlso resultVerificacion.Count = 4 Then
|
||||||
|
|
||||||
|
' If ResultadoVerificaionOK Then
|
||||||
|
' sbResultado.Append($"{resultVerificacion(1)}<br>")
|
||||||
|
' Else
|
||||||
|
' sbResultado.Append($"Se presento un error al verificar las solicitudes {resultVerificacion(1)}<br>")
|
||||||
|
' TipoMensaje = ModExtensiones.TipoMensaje.MsgAdvertencia
|
||||||
|
' End If
|
||||||
|
' Else
|
||||||
|
' sbResultado.AppendLine("Se presento un error al verificar las solicitudes (API) <br/>")
|
||||||
|
' TipoMensaje = ModExtensiones.TipoMensaje.MsgAdvertencia
|
||||||
|
' End If
|
||||||
|
|
||||||
|
' Alert(sbResultado.ToString(), TipoMensaje)
|
||||||
|
' End If
|
||||||
|
|
||||||
|
' If Continuar Then
|
||||||
|
' txtFechaIAdd.Text = ""
|
||||||
|
' txtFechaFAdd.Text = ""
|
||||||
|
' Me.RegistraScript("$('#ModalViewSolicitudes').modal('hide');")
|
||||||
|
' cargasolicitudes()
|
||||||
|
' End If
|
||||||
|
|
||||||
|
'End Sub
|
||||||
|
|
||||||
Protected Sub LnkSolicitarSat_Click(ByVal sender As Object, ByVal e As EventArgs)
|
Protected Sub LnkSolicitarSat_Click(ByVal sender As Object, ByVal e As EventArgs)
|
||||||
'Dim idSolicitudCFDI As Integer = 0
|
Dim sbResultado As StringBuilder = New StringBuilder()
|
||||||
'Dim idSolicitudMetadata As Integer = 0
|
|
||||||
'Dim estatus As Integer = 0
|
|
||||||
'Dim observaciones As String = ""
|
|
||||||
'Dim fechaInicio As DateTime = txtFechaIAdd.Text.ToDateTime()
|
|
||||||
'Dim fechaFin As DateTime = txtFechaFAdd.Text.ToDateTime()
|
|
||||||
'Dim cveUsuarioIng As Integer = UsuarioActual.CveUsuario
|
|
||||||
'Dim cveEmpresa As Integer = UsuarioActual.CveEmpresa
|
|
||||||
'Dim Continuar As Boolean = False
|
|
||||||
|
|
||||||
'Using nom As ClsNominas = New ClsNominas()
|
|
||||||
' Continuar = nom.SolicitudesAdd(idSolicitudCFDI, idSolicitudMetadata, estatus, observaciones, fechaInicio, fechaFin, cveUsuarioIng, cveEmpresa, 2)
|
|
||||||
' Dim api = New GeneralesAPIeFacturas()
|
|
||||||
' api.GeneraSolicitud()
|
|
||||||
' api.VerificaSolicitudesNominas()
|
|
||||||
'End Using
|
|
||||||
|
|
||||||
'If Continuar Then
|
|
||||||
' txtFechaIAdd.Text = ""
|
|
||||||
' txtFechaFAdd.Text = ""
|
|
||||||
' Me.RegistraScript("$('#DModalSolicitudesNominas').modal('hide');")
|
|
||||||
' cargasolicitudes()
|
|
||||||
' Me.Alert("se a envia la solicitud al sat, le enviaremos un correo en cuanto tengamos una respuesta", ModExtensiones.TipoMensaje.ToastInformacion)
|
|
||||||
'End If
|
|
||||||
|
|
||||||
Dim idSolicitudCFDI As Integer = 0
|
Dim idSolicitudCFDI As Integer = 0
|
||||||
Dim idSolicitudMetadata As Integer = 0
|
Dim idSolicitudMetadata As Integer = 0
|
||||||
Dim estatus As Integer = 0
|
Dim estatus As Integer = 0
|
||||||
@@ -2605,20 +2714,23 @@ Partial Class Compras_eFacturas
|
|||||||
Dim fechaFin As DateTime = txtFechaFAdd.Text.ToDateTime()
|
Dim fechaFin As DateTime = txtFechaFAdd.Text.ToDateTime()
|
||||||
Dim cveUsuarioIng As Integer = UsuarioActual.CveUsuario
|
Dim cveUsuarioIng As Integer = UsuarioActual.CveUsuario
|
||||||
Dim cveEmpresa As Integer = UsuarioActual.CveEmpresa
|
Dim cveEmpresa As Integer = UsuarioActual.CveEmpresa
|
||||||
Dim Continuar As Boolean = False
|
Dim CveSolicitudAgregada As Integer = -1
|
||||||
|
Dim Folio As Integer = -1
|
||||||
|
|
||||||
Using nom As ClsNominas = New ClsNominas()
|
Using nom As ClsNominas = New ClsNominas()
|
||||||
Continuar = nom.SolicitudesAdd(idSolicitudCFDI, idSolicitudMetadata, estatus, observaciones, fechaInicio, fechaFin, cveUsuarioIng, cveEmpresa, CveTipoSolicitud:=3)
|
Dim CveTipoSolicitud As Integer = If(ChkMetaDatos.Checked, 202, 2)
|
||||||
|
CveSolicitudAgregada = nom.SolicitudesAdd2(idSolicitudCFDI, idSolicitudMetadata, estatus, observaciones, fechaInicio, fechaFin, cveUsuarioIng, cveEmpresa, CveTipoSolicitud:=CveTipoSolicitud)
|
||||||
|
|
||||||
|
If CveSolicitudAgregada > 0 Then
|
||||||
|
Folio = nom.FolioSolicitud
|
||||||
|
End If
|
||||||
End Using
|
End Using
|
||||||
|
|
||||||
If Continuar Then
|
If CveSolicitudAgregada > 0 Then
|
||||||
Dim sbResultado As StringBuilder = New StringBuilder()
|
|
||||||
Dim api = New GeneralesAPIeFacturas()
|
Dim api = New GeneralesAPIeFacturas()
|
||||||
Dim ObjApiSolicitud As JToken = CType(api.GeneraSolicitud(UsuarioActual.CveEmpresa, 3), JToken)
|
Dim ObjApiSolicitud As JToken = CType(api.GeneraSolicitud(UsuarioActual.CveEmpresa, 2, CveSolicitudAgregada), JToken)
|
||||||
Dim resultSolicitud As List(Of String) = New List(Of String)()
|
Dim resultSolicitud As List(Of String) = New List(Of String)()
|
||||||
Dim resultVerificacion As List(Of String) = New List(Of String)()
|
Dim resultVerificacion As List(Of String) = New List(Of String)()
|
||||||
Dim ResultadoVerificaionOK = False
|
|
||||||
Dim SeVerifico = False
|
|
||||||
Dim TipoMensaje = ModExtensiones.TipoMensaje.MsgInformacion
|
Dim TipoMensaje = ModExtensiones.TipoMensaje.MsgInformacion
|
||||||
Dim ResultadoSolicitudOK = False
|
Dim ResultadoSolicitudOK = False
|
||||||
|
|
||||||
@@ -2630,134 +2742,246 @@ Partial Class Compras_eFacturas
|
|||||||
End If
|
End If
|
||||||
|
|
||||||
If ResultadoSolicitudOK Then
|
If ResultadoSolicitudOK Then
|
||||||
Dim ObjApiVerificacion As JToken = CType(api.VerificaSolicitudesNominas(UsuarioActual.CveEmpresa, 3), JToken)
|
sbResultado.Append($"Solicitud registrada. {resultSolicitud(1)}<br> Folio: {Folio}")
|
||||||
|
|
||||||
If Not (ObjApiVerificacion Is Nothing) Then
|
|
||||||
resultVerificacion = ObjApiVerificacion.[Select](Function(token) token.Values().Aggregate(Function(i, j) $"{i}|{j}").Value(Of String)()).ToList()
|
|
||||||
ResultadoVerificaionOK = Boolean.Parse(resultVerificacion(0))
|
|
||||||
SeVerifico = True
|
|
||||||
Else
|
|
||||||
TipoMensaje = ModExtensiones.TipoMensaje.MsgAdvertencia
|
|
||||||
End If
|
|
||||||
End If
|
|
||||||
|
|
||||||
If resultSolicitud.Count = 4 Then
|
|
||||||
|
|
||||||
If ResultadoSolicitudOK Then
|
|
||||||
|
|
||||||
If resultSolicitud(1).ToString().Trim().Length > 0 Then
|
|
||||||
sbResultado.Append($"{resultSolicitud(1)}<br/>")
|
|
||||||
Else
|
|
||||||
sbResultado.Append($"Solicitud Generada Correctamente")
|
|
||||||
sbResultado.Append($"Se presento un error al verificar las solicitudes <br/> {resultSolicitud(1)} <br>")
|
|
||||||
End If
|
|
||||||
Else
|
|
||||||
sbResultado.Append($"{resultSolicitud(1)}")
|
|
||||||
TipoMensaje = ModExtensiones.TipoMensaje.MsgAdvertencia
|
|
||||||
End If
|
|
||||||
Else
|
Else
|
||||||
sbResultado.AppendLine("Se presento un error al generar la solicitud (API) <br/>")
|
|
||||||
TipoMensaje = ModExtensiones.TipoMensaje.MsgAdvertencia
|
|
||||||
End If
|
|
||||||
|
|
||||||
If SeVerifico AndAlso resultVerificacion.Count = 4 Then
|
If ObjApiSolicitud IsNot Nothing AndAlso resultSolicitud.Count = 4 Then
|
||||||
|
sbResultado.Append($"Solicitud registrada, pendiente de verificar en SAT <br> Folio: {Folio} <br>({resultSolicitud(1)})<br>")
|
||||||
If ResultadoVerificaionOK Then
|
|
||||||
sbResultado.Append($"{resultVerificacion(1)}<br>")
|
|
||||||
Else
|
Else
|
||||||
sbResultado.Append($"Se presento un error al verificar las solicitudes {resultVerificacion(1)}<br>")
|
sbResultado.Append($"Solicitud registrada, pendiente de verificar en SAT <br> Folio: {Folio}")
|
||||||
TipoMensaje = ModExtensiones.TipoMensaje.MsgAdvertencia
|
|
||||||
End If
|
End If
|
||||||
Else
|
|
||||||
sbResultado.AppendLine("Se presento un error al verificar las solicitudes (API) <br/>")
|
|
||||||
TipoMensaje = ModExtensiones.TipoMensaje.MsgAdvertencia
|
TipoMensaje = ModExtensiones.TipoMensaje.MsgAdvertencia
|
||||||
End If
|
End If
|
||||||
|
|
||||||
Alert(sbResultado.ToString(), TipoMensaje)
|
Alert(sbResultado.ToString(), TipoMensaje)
|
||||||
|
Else
|
||||||
|
Alert("No se puedo registrar la solictud".ToString(), ModExtensiones.TipoMensaje.MsgAdvertencia)
|
||||||
End If
|
End If
|
||||||
|
|
||||||
If Continuar Then
|
If CveSolicitudAgregada > 0 Then
|
||||||
txtFechaIAdd.Text = ""
|
txtFechaIAdd.Text = ""
|
||||||
txtFechaFAdd.Text = ""
|
txtFechaFAdd.Text = ""
|
||||||
Me.RegistraScript("$('#ModalViewSolicitudes').modal('hide');")
|
ChkMetaDatos.Checked = False
|
||||||
|
Me.RegistraScript("$('#ModalAgregarSolicitud').modal('hide');")
|
||||||
cargasolicitudes()
|
cargasolicitudes()
|
||||||
End If
|
End If
|
||||||
|
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
|
'Protected Sub LnkverificarSolicitudes_Click(ByVal sender As Object, ByVal e As EventArgs)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
' Dim sbResultado As StringBuilder = New StringBuilder()
|
||||||
|
' Dim api = New GeneralesAPIeFacturas()
|
||||||
|
' Dim ObjApiSolicitud As JToken = CType(api.GeneraSolicitud(UsuarioActual.CveEmpresa, 3), JToken)
|
||||||
|
' Dim resultSolicitud As List(Of String) = New List(Of String)()
|
||||||
|
' Dim resultVerificacion As List(Of String) = New List(Of String)()
|
||||||
|
' Dim ResultadoVerificaionOK = False
|
||||||
|
' Dim SeVerifico = False
|
||||||
|
' Dim TipoMensaje = ModExtensiones.TipoMensaje.MsgInformacion
|
||||||
|
' Dim ResultadoSolicitudOK = False
|
||||||
|
|
||||||
|
' If Not (ObjApiSolicitud Is Nothing) Then
|
||||||
|
' resultSolicitud = ObjApiSolicitud.[Select](Function(token) token.Values().Aggregate(Function(i, j) $"{i}|{j}").Value(Of String)()).ToList()
|
||||||
|
' ResultadoSolicitudOK = Boolean.Parse(resultSolicitud(0))
|
||||||
|
' Else
|
||||||
|
' TipoMensaje = ModExtensiones.TipoMensaje.MsgAdvertencia
|
||||||
|
' End If
|
||||||
|
|
||||||
|
' If ResultadoSolicitudOK Then
|
||||||
|
' Dim ObjApiVerificacion As JToken = CType(api.VerificaSolicitudesNominas(UsuarioActual.CveEmpresa, 3), JToken)
|
||||||
|
|
||||||
|
' If Not (ObjApiVerificacion Is Nothing) Then
|
||||||
|
' resultVerificacion = ObjApiVerificacion.[Select](Function(token) token.Values().Aggregate(Function(i, j) $"{i}|{j}").Value(Of String)()).ToList()
|
||||||
|
' ResultadoVerificaionOK = Boolean.Parse(resultVerificacion(0))
|
||||||
|
' SeVerifico = True
|
||||||
|
' Else
|
||||||
|
' TipoMensaje = ModExtensiones.TipoMensaje.MsgAdvertencia
|
||||||
|
' End If
|
||||||
|
' End If
|
||||||
|
|
||||||
|
' If resultSolicitud.Count = 4 Then
|
||||||
|
|
||||||
|
' If ResultadoSolicitudOK Then
|
||||||
|
|
||||||
|
' If resultSolicitud(2).ToString().Trim().Length > 0 Then
|
||||||
|
' sbResultado.Append($"{resultSolicitud(2)}<br/>")
|
||||||
|
' Else
|
||||||
|
' sbResultado.Append($"Solicitud Generada Correctamente")
|
||||||
|
' sbResultado.Append($"Se presento un error al verificar las solicitudes <br/> {resultSolicitud(1)} <br>")
|
||||||
|
' End If
|
||||||
|
' Else
|
||||||
|
' sbResultado.Append($"{resultSolicitud(1)}")
|
||||||
|
' TipoMensaje = ModExtensiones.TipoMensaje.MsgAdvertencia
|
||||||
|
' End If
|
||||||
|
' Else
|
||||||
|
' sbResultado.AppendLine("Se presento un error al generar la solicitud (API) <br/>")
|
||||||
|
' TipoMensaje = ModExtensiones.TipoMensaje.MsgAdvertencia
|
||||||
|
' End If
|
||||||
|
|
||||||
|
' If SeVerifico AndAlso resultVerificacion.Count = 4 Then
|
||||||
|
|
||||||
|
' If ResultadoVerificaionOK Then
|
||||||
|
' sbResultado.Append($"{resultVerificacion(1)}<br>")
|
||||||
|
' Else
|
||||||
|
' sbResultado.Append($"Se presento un error al verificar las solicitudes {resultVerificacion(1)}<br>")
|
||||||
|
' TipoMensaje = ModExtensiones.TipoMensaje.MsgAdvertencia
|
||||||
|
' End If
|
||||||
|
' Else
|
||||||
|
' sbResultado.AppendLine("Se presento un error al verificar las solicitudes (API) <br/>")
|
||||||
|
' TipoMensaje = ModExtensiones.TipoMensaje.MsgAdvertencia
|
||||||
|
' End If
|
||||||
|
|
||||||
|
' Alert(sbResultado.ToString(), TipoMensaje)
|
||||||
|
' cargasolicitudes()
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
'End Sub
|
||||||
|
|
||||||
|
|
||||||
Protected Sub LnkverificarSolicitudes_Click(ByVal sender As Object, ByVal e As EventArgs)
|
Protected Sub LnkverificarSolicitudes_Click(ByVal sender As Object, ByVal e As EventArgs)
|
||||||
|
Try
|
||||||
|
Dim sbResultado As StringBuilder = New StringBuilder()
|
||||||
|
|
||||||
|
For Each GvRow As GridViewRow In GVSolicitudesPendientes.Rows
|
||||||
|
Dim CveSolicitudActual As Integer = GvRow.DataKey("CveSolicitud").ToEntero()
|
||||||
|
Dim idSolicitud As String = GvRow.DataKey("idSolicitud").Trim()
|
||||||
|
Dim CveTipoSolicitud As Integer = GvRow.DataKey("CveTipoSolicitud").ToEntero()
|
||||||
|
Dim Folio As Integer = GvRow.DataKey("Folio").ToEntero()
|
||||||
|
Dim resultSolicitud As List(Of String) = New List(Of String)()
|
||||||
|
Dim resultVerificacion As List(Of String) = New List(Of String)()
|
||||||
|
Dim ResultadoVerificaionOK = False
|
||||||
|
Dim SeVerifico = False
|
||||||
|
Dim TipoMensaje = ModExtensiones.TipoMensaje.MsgInformacion
|
||||||
|
Dim ResultadoSolicitudOK = False
|
||||||
|
Dim api = New GeneralesAPIeFacturas()
|
||||||
|
|
||||||
|
If idSolicitud.Length = 0 Then
|
||||||
|
Dim ObjApiSolicitud As JToken = CType(api.GeneraSolicitud(UsuarioActual.CveEmpresa, CveTipoSolicitud, CveSolicitudActual), JToken)
|
||||||
|
|
||||||
|
If Not (ObjApiSolicitud Is Nothing) Then
|
||||||
Dim sbResultado As StringBuilder = New StringBuilder()
|
resultSolicitud = ObjApiSolicitud.[Select](Function(token) token.Values().Aggregate(Function(i, j) $"{i}|{j}").Value(Of String)()).ToList()
|
||||||
Dim api = New GeneralesAPIeFacturas()
|
ResultadoSolicitudOK = Boolean.Parse(resultSolicitud(0))
|
||||||
Dim ObjApiSolicitud As JToken = CType(api.GeneraSolicitud(UsuarioActual.CveEmpresa, 3), JToken)
|
sbResultado.Append($"Solicitud {Folio} solicitada a SAT.<br>")
|
||||||
Dim resultSolicitud As List(Of String) = New List(Of String)()
|
Else
|
||||||
Dim resultVerificacion As List(Of String) = New List(Of String)()
|
TipoMensaje = ModExtensiones.TipoMensaje.MsgAdvertencia
|
||||||
Dim ResultadoVerificaionOK = False
|
End If
|
||||||
Dim SeVerifico = False
|
|
||||||
Dim TipoMensaje = ModExtensiones.TipoMensaje.MsgInformacion
|
|
||||||
Dim ResultadoSolicitudOK = False
|
|
||||||
|
|
||||||
If Not (ObjApiSolicitud Is Nothing) Then
|
|
||||||
resultSolicitud = ObjApiSolicitud.[Select](Function(token) token.Values().Aggregate(Function(i, j) $"{i}|{j}").Value(Of String)()).ToList()
|
|
||||||
ResultadoSolicitudOK = Boolean.Parse(resultSolicitud(0))
|
|
||||||
Else
|
|
||||||
TipoMensaje = ModExtensiones.TipoMensaje.MsgAdvertencia
|
|
||||||
End If
|
|
||||||
|
|
||||||
If ResultadoSolicitudOK Then
|
|
||||||
Dim ObjApiVerificacion As JToken = CType(api.VerificaSolicitudesNominas(UsuarioActual.CveEmpresa, 3), JToken)
|
|
||||||
|
|
||||||
If Not (ObjApiVerificacion Is Nothing) Then
|
|
||||||
resultVerificacion = ObjApiVerificacion.[Select](Function(token) token.Values().Aggregate(Function(i, j) $"{i}|{j}").Value(Of String)()).ToList()
|
|
||||||
ResultadoVerificaionOK = Boolean.Parse(resultVerificacion(0))
|
|
||||||
SeVerifico = True
|
|
||||||
Else
|
|
||||||
TipoMensaje = ModExtensiones.TipoMensaje.MsgAdvertencia
|
|
||||||
End If
|
|
||||||
End If
|
|
||||||
|
|
||||||
If resultSolicitud.Count = 4 Then
|
|
||||||
|
|
||||||
If ResultadoSolicitudOK Then
|
|
||||||
|
|
||||||
If resultSolicitud(2).ToString().Trim().Length > 0 Then
|
|
||||||
sbResultado.Append($"{resultSolicitud(2)}<br/>")
|
|
||||||
Else
|
Else
|
||||||
sbResultado.Append($"Solicitud Generada Correctamente")
|
resultSolicitud = New List(Of String)()
|
||||||
sbResultado.Append($"Se presento un error al verificar las solicitudes <br/> {resultSolicitud(1)} <br>")
|
resultSolicitud.Add("true")
|
||||||
|
resultSolicitud.Add("")
|
||||||
|
resultSolicitud.Add("")
|
||||||
|
resultSolicitud.Add("")
|
||||||
|
ResultadoSolicitudOK = True
|
||||||
End If
|
End If
|
||||||
Else
|
|
||||||
sbResultado.Append($"{resultSolicitud(1)}")
|
|
||||||
TipoMensaje = ModExtensiones.TipoMensaje.MsgAdvertencia
|
|
||||||
End If
|
|
||||||
Else
|
|
||||||
sbResultado.AppendLine("Se presento un error al generar la solicitud (API) <br/>")
|
|
||||||
TipoMensaje = ModExtensiones.TipoMensaje.MsgAdvertencia
|
|
||||||
End If
|
|
||||||
|
|
||||||
If SeVerifico AndAlso resultVerificacion.Count = 4 Then
|
If ResultadoSolicitudOK Then
|
||||||
|
Dim ObjApiVerificacion As JToken = CType(api.VerificaSolicitudesNominas(UsuarioActual.CveEmpresa, CveTipoSolicitud, CveSolicitudActual), JToken)
|
||||||
|
|
||||||
If ResultadoVerificaionOK Then
|
If Not (ObjApiVerificacion Is Nothing) Then
|
||||||
sbResultado.Append($"{resultVerificacion(1)}<br>")
|
resultVerificacion = ObjApiVerificacion.[Select](Function(token) token.Values().Aggregate(Function(i, j) $"{i}|{j}").Value(Of String)()).ToList()
|
||||||
Else
|
ResultadoVerificaionOK = Boolean.Parse(resultVerificacion(0))
|
||||||
sbResultado.Append($"Se presento un error al verificar las solicitudes {resultVerificacion(1)}<br>")
|
SeVerifico = True
|
||||||
TipoMensaje = ModExtensiones.TipoMensaje.MsgAdvertencia
|
Else
|
||||||
End If
|
TipoMensaje = ModExtensiones.TipoMensaje.MsgAdvertencia
|
||||||
Else
|
End If
|
||||||
sbResultado.AppendLine("Se presento un error al verificar las solicitudes (API) <br/>")
|
Else
|
||||||
TipoMensaje = ModExtensiones.TipoMensaje.MsgAdvertencia
|
|
||||||
End If
|
|
||||||
|
|
||||||
Alert(sbResultado.ToString(), TipoMensaje)
|
If resultSolicitud.Count = 4 Then
|
||||||
cargasolicitudes()
|
sbResultado.Append($"({resultSolicitud(1)})<br> Folio:{Folio} <br> ")
|
||||||
|
Else
|
||||||
|
sbResultado.Append($"Solicitud pendiente de verificar en SAT <br> Folio:{Folio} <br>")
|
||||||
|
End If
|
||||||
|
|
||||||
|
TipoMensaje = ModExtensiones.TipoMensaje.MsgAdvertencia
|
||||||
|
End If
|
||||||
|
|
||||||
|
If SeVerifico AndAlso resultVerificacion.Count = 4 Then
|
||||||
|
|
||||||
|
If ResultadoVerificaionOK Then
|
||||||
|
sbResultado.Append($"Solicitud procesada.<br> Folio: {Folio} <br> {resultVerificacion(1)}")
|
||||||
|
Else
|
||||||
|
sbResultado.Append($"Solicitud no verificada <br> Folio: {Folio}{resultVerificacion(1)}.<br>")
|
||||||
|
TipoMensaje = ModExtensiones.TipoMensaje.MsgAdvertencia
|
||||||
|
End If
|
||||||
|
Else
|
||||||
|
sbResultado.Append($"Se presento un error al verificar la solicitud <br> Folio: {Folio}.")
|
||||||
|
TipoMensaje = ModExtensiones.TipoMensaje.MsgAdvertencia
|
||||||
|
End If
|
||||||
|
|
||||||
|
Alert(sbResultado.ToString(), TipoMensaje)
|
||||||
|
Next
|
||||||
|
|
||||||
|
cargasolicitudes()
|
||||||
|
Catch ex As Exception
|
||||||
|
Alert(ex.StackTrace)
|
||||||
|
End Try
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
|
|
||||||
|
Protected Sub LnkAgregarSolictud_Click(ByVal sender As Object, ByVal e As EventArgs)
|
||||||
|
txtFechaIAdd.Text = ""
|
||||||
|
txtFechaFAdd.Text = ""
|
||||||
|
ChkMetaDatos.Checked = False
|
||||||
|
UPModalViewSolicitudesAgregar.Update()
|
||||||
|
Me.RegistraScript("$('#ModalAgregarSolicitud').modal('show');")
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Protected Sub GVSolicitudesNominas_RowDataBound(ByVal sender As Object, ByVal e As GridViewRowEventArgs)
|
||||||
|
If e.Row.RowType = DataControlRowType.DataRow Then
|
||||||
|
|
||||||
|
|
||||||
|
If e.Row.DataKey("ArchivoXML").Length > 0 Then
|
||||||
|
Dim UrlDescarga = $"{UsuarioActual.Empresa.Ruta}NomXMLSAT\\Descargas\\{e.Row.DataKey("ArchivoXML")}"
|
||||||
|
|
||||||
|
If System.IO.File.Exists(UrlDescarga) Then
|
||||||
|
Dim LnkDescargaXML As LinkButton = e.Row.FCLinkButton("LnkDescargaXML")
|
||||||
|
ScriptManager.GetCurrent(Me).RegisterPostBackControl(LnkDescargaXML)
|
||||||
|
LnkDescargaXML.Visible = True
|
||||||
|
End If
|
||||||
|
End If
|
||||||
|
|
||||||
|
Dim lblobservaciones As Label = e.Row.FCLabel("lblobservaciones")
|
||||||
|
Dim lBLTipoDescarga As Label = e.Row.FCLabel("lBLTipoDescarga")
|
||||||
|
|
||||||
|
lblobservaciones.Attributes.Add("data-html", "true")
|
||||||
|
lblobservaciones.Attributes.Add("data-toggle", "tooltip")
|
||||||
|
lblobservaciones.Attributes.Add("data-placement", "top")
|
||||||
|
lblobservaciones.Attributes.Add("title", e.Row.DataKey("Observaciones"))
|
||||||
|
lBLTipoDescarga.Attributes.Add("data-html", "true")
|
||||||
|
lBLTipoDescarga.Attributes.Add("data-toggle", "tooltip")
|
||||||
|
lBLTipoDescarga.Attributes.Add("data-placement", "top")
|
||||||
|
lBLTipoDescarga.Attributes.Add("title", e.Row.DataKey("TipoDescargaStr"))
|
||||||
|
|
||||||
|
End If
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
|
||||||
|
Protected Sub LnkDescargaXML_Click(ByVal sender As Object, ByVal e As EventArgs)
|
||||||
|
Dim GvRow As GridViewRow = CType((CType(sender, LinkButton)).NamingContainer, GridViewRow)
|
||||||
|
Dim UrlDescarga = $"{UsuarioActual.Empresa.Ruta}NomXMLSAT\\Descargas\\{GvRow.DataKey("ArchivoXML")}"
|
||||||
|
Dim Archivo = New System.IO.FileInfo(UrlDescarga)
|
||||||
|
|
||||||
|
If Archivo.Exists Then
|
||||||
|
Response.Clear()
|
||||||
|
Response.AddHeader("Content-Disposition", "attachment; filename=" & Archivo.Name)
|
||||||
|
Response.AddHeader("Content-Length", Archivo.Length.ToString())
|
||||||
|
Response.ContentType = "text/octet-stream"
|
||||||
|
Response.Flush()
|
||||||
|
Response.TransmitFile(Archivo.FullName)
|
||||||
|
Response.[End]()
|
||||||
|
End If
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
|
||||||
#End Region
|
#End Region
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
#Region "D E S C A R G A R - F A C T U R A "
|
#Region "D E S C A R G A R - F A C T U R A "
|
||||||
'Protected Sub lbDescargar_Click(sender As Object, e As EventArgs) Handles lbDescargar.Click
|
'Protected Sub lbDescargar_Click(sender As Object, e As EventArgs) Handles lbDescargar.Click
|
||||||
|
|
||||||
@@ -4196,8 +4420,6 @@ Partial Class Compras_eFacturas
|
|||||||
Alert("no se pudo procesar el archivo xml")
|
Alert("no se pudo procesar el archivo xml")
|
||||||
End If
|
End If
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
|
|
||||||
Private Sub VinculacionMasivaComplementos()
|
Private Sub VinculacionMasivaComplementos()
|
||||||
|
|
||||||
Dim CountVinculados As Integer = 0
|
Dim CountVinculados As Integer = 0
|
||||||
@@ -4546,15 +4768,10 @@ Partial Class Compras_eFacturas
|
|||||||
|
|
||||||
|
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
|
|
||||||
Protected Sub LnkVinculacionMasivaComplementos_Click(sender As Object, e As EventArgs)
|
Protected Sub LnkVinculacionMasivaComplementos_Click(sender As Object, e As EventArgs)
|
||||||
VinculacionMasivaComplementos()
|
VinculacionMasivaComplementos()
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
#Region "TRASLADOS"
|
#Region "TRASLADOS"
|
||||||
|
|
||||||
|
|
||||||
@@ -4733,7 +4950,6 @@ Partial Class Compras_eFacturas
|
|||||||
|
|
||||||
#End Region
|
#End Region
|
||||||
|
|
||||||
|
|
||||||
Protected Sub LnkModalPersonalizar_Click(sender As Object, e As EventArgs)
|
Protected Sub LnkModalPersonalizar_Click(sender As Object, e As EventArgs)
|
||||||
|
|
||||||
GvD.Columns(11).Visible = ChkModalPersonalzarFolioFiscal.Checked
|
GvD.Columns(11).Visible = ChkModalPersonalzarFolioFiscal.Checked
|
||||||
@@ -4748,9 +4964,6 @@ Partial Class Compras_eFacturas
|
|||||||
RegistraScript("$('#DvmodalPersonalizar').modal('hide');")
|
RegistraScript("$('#DvmodalPersonalizar').modal('hide');")
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
Protected Sub LnkPersonalizar_Click(sender As Object, e As EventArgs)
|
Protected Sub LnkPersonalizar_Click(sender As Object, e As EventArgs)
|
||||||
|
|
||||||
RegistraScript("$('#DvmodalPersonalizar').modal('show');")
|
RegistraScript("$('#DvmodalPersonalizar').modal('show');")
|
||||||
@@ -4768,12 +4981,12 @@ Public Class GeneralesAPIeFacturas
|
|||||||
MyBase.New(domainApi, token)
|
MyBase.New(domainApi, token)
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Public Function GeneraSolicitud(CveEmpresa As Integer, CveTipoSolicitud As Integer) As Object
|
Public Function GeneraSolicitud(CveEmpresa As Integer, CveTipoSolicitud As Integer, CveSolicitud As Integer) As Object
|
||||||
Return getData(Of Object)($"GeneraSolicitud/{CveEmpresa}/{CveTipoSolicitud}", Nothing, ADSNetLibraryzdE.HelpersE.ConexionesE.SIGAPIE.requestMethod.[GET], False)
|
Return getData(Of Object)($"GeneraSolicitud/{CveEmpresa}/{CveTipoSolicitud}/{CveSolicitud}", Nothing, ADSNetLibraryzdE.HelpersE.ConexionesE.SIGAPIE.requestMethod.[GET], False)
|
||||||
End Function
|
End Function
|
||||||
|
|
||||||
Public Function VerificaSolicitudesNominas(CveEmpresa As Integer, CveTipoSolicitud As Integer) As Object
|
Public Function VerificaSolicitudesNominas(CveEmpresa As Integer, CveTipoSolicitud As Integer, CveSolicitud As Integer) As Object
|
||||||
Return getData(Of Object)($"VerificaSolicitudesNominas/{CveEmpresa}/{CveTipoSolicitud}", Nothing, ADSNetLibraryzdE.HelpersE.ConexionesE.SIGAPIE.requestMethod.[GET], False)
|
Return getData(Of Object)($"VerificaSolicitudesNominas/{CveEmpresa}/{CveTipoSolicitud}/{CveSolicitud}", Nothing, ADSNetLibraryzdE.HelpersE.ConexionesE.SIGAPIE.requestMethod.[GET], False)
|
||||||
End Function
|
End Function
|
||||||
End Class
|
End Class
|
||||||
|
|
||||||
|
|||||||
@@ -1514,7 +1514,6 @@
|
|||||||
<PaddingBottom>2pt</PaddingBottom>
|
<PaddingBottom>2pt</PaddingBottom>
|
||||||
</Style>
|
</Style>
|
||||||
</Textbox>
|
</Textbox>
|
||||||
<rd:Selected>true</rd:Selected>
|
|
||||||
</CellContents>
|
</CellContents>
|
||||||
</TablixCell>
|
</TablixCell>
|
||||||
<TablixCell>
|
<TablixCell>
|
||||||
@@ -1869,7 +1868,6 @@
|
|||||||
<PaddingBottom>2pt</PaddingBottom>
|
<PaddingBottom>2pt</PaddingBottom>
|
||||||
</Style>
|
</Style>
|
||||||
</Textbox>
|
</Textbox>
|
||||||
<rd:Selected>true</rd:Selected>
|
|
||||||
</CellContents>
|
</CellContents>
|
||||||
</TablixCell>
|
</TablixCell>
|
||||||
<TablixCell>
|
<TablixCell>
|
||||||
@@ -2224,7 +2222,6 @@
|
|||||||
<PaddingBottom>2pt</PaddingBottom>
|
<PaddingBottom>2pt</PaddingBottom>
|
||||||
</Style>
|
</Style>
|
||||||
</Textbox>
|
</Textbox>
|
||||||
<rd:Selected>true</rd:Selected>
|
|
||||||
</CellContents>
|
</CellContents>
|
||||||
</TablixCell>
|
</TablixCell>
|
||||||
<TablixCell>
|
<TablixCell>
|
||||||
@@ -2579,7 +2576,6 @@
|
|||||||
<PaddingBottom>2pt</PaddingBottom>
|
<PaddingBottom>2pt</PaddingBottom>
|
||||||
</Style>
|
</Style>
|
||||||
</Textbox>
|
</Textbox>
|
||||||
<rd:Selected>true</rd:Selected>
|
|
||||||
</CellContents>
|
</CellContents>
|
||||||
</TablixCell>
|
</TablixCell>
|
||||||
<TablixCell>
|
<TablixCell>
|
||||||
@@ -2934,7 +2930,6 @@
|
|||||||
<PaddingBottom>2pt</PaddingBottom>
|
<PaddingBottom>2pt</PaddingBottom>
|
||||||
</Style>
|
</Style>
|
||||||
</Textbox>
|
</Textbox>
|
||||||
<rd:Selected>true</rd:Selected>
|
|
||||||
</CellContents>
|
</CellContents>
|
||||||
</TablixCell>
|
</TablixCell>
|
||||||
<TablixCell>
|
<TablixCell>
|
||||||
@@ -4948,7 +4943,7 @@
|
|||||||
<Paragraph>
|
<Paragraph>
|
||||||
<TextRuns>
|
<TextRuns>
|
||||||
<TextRun>
|
<TextRun>
|
||||||
<Value>EXPLORACIONES MINERAS DEL DESIERTO S.A. DE C.V. RFC: EMD950206SRA </Value>
|
<Value>EXPLORACIONES MINERAS DEL DESIERTO S.A. DE C.V. </Value>
|
||||||
<Style>
|
<Style>
|
||||||
<FontStyle>Normal</FontStyle>
|
<FontStyle>Normal</FontStyle>
|
||||||
<FontSize>8pt</FontSize>
|
<FontSize>8pt</FontSize>
|
||||||
@@ -4965,7 +4960,7 @@
|
|||||||
<Paragraph>
|
<Paragraph>
|
||||||
<TextRuns>
|
<TextRuns>
|
||||||
<TextRun>
|
<TextRun>
|
||||||
<Value>Tipo de Comprobante: I - Ingreso </Value>
|
<Value>RFC: EMD950206SRA </Value>
|
||||||
<Style>
|
<Style>
|
||||||
<FontStyle>Normal</FontStyle>
|
<FontStyle>Normal</FontStyle>
|
||||||
<FontSize>8pt</FontSize>
|
<FontSize>8pt</FontSize>
|
||||||
|
|||||||
@@ -361,8 +361,7 @@
|
|||||||
<th width="100px">
|
<th width="100px">
|
||||||
<asp:Literal ID="LtCantidad" Text="Cantidad" runat="server" />
|
<asp:Literal ID="LtCantidad" Text="Cantidad" runat="server" />
|
||||||
</th>
|
</th>
|
||||||
<th width="300px">Clasificación
|
<th width="300px">
|
||||||
<br />
|
|
||||||
Producto
|
Producto
|
||||||
</th>
|
</th>
|
||||||
<th width="90px">Unidad</th>
|
<th width="90px">Unidad</th>
|
||||||
@@ -390,14 +389,18 @@
|
|||||||
<td style="text-align: left;" align="center">
|
<td style="text-align: left;" align="center">
|
||||||
<div class="psagregar">
|
<div class="psagregar">
|
||||||
<div class="comboxes">
|
<div class="comboxes">
|
||||||
<asp:DropDownList ID="DdlClasificacion" runat="server" AppendDataBoundItems="true" AutoPostBack="true" DataTextField="Clasificacion" DataValueField="CveClasificacion" Class="form-control input-sm select2me">
|
<%-- <asp:DropDownList ID="DdlClasificacion" runat="server" AppendDataBoundItems="true" AutoPostBack="true" DataTextField="Clasificacion" DataValueField="CveClasificacion" Class="form-control input-sm select2me">
|
||||||
<asp:ListItem Selected="True" Text="Seleccione la Clasificación (Todas)" Value="-1"></asp:ListItem>
|
<asp:ListItem Selected="True" Text="Seleccione la Clasificación (Todas)" Value="-1"></asp:ListItem>
|
||||||
</asp:DropDownList>
|
</asp:DropDownList>
|
||||||
<br />
|
<br />--%>
|
||||||
<asp:DropDownList ID="DdlProducto" runat="server" DataTextField="PSCodigo" AutoPostBack="true" DataValueField="CvePS" Class="form-control input-sm select2me"></asp:DropDownList>
|
<%--<asp:DropDownList ID="DdlProducto" runat="server" DataTextField="PSCodigo" AutoPostBack="true" DataValueField="CvePS" Class="form-control input-sm select2me"></asp:DropDownList>--%>
|
||||||
<select id="DdlProductows" runat="server" class="form-control"></select><asp:Button ID="myhidenbutton" runat="server" Text="Button" Style="display: none;" />
|
|
||||||
|
<ADS:Dropdownlost Onselectedindexchange="DdlProducto_selectedindexchange" runat="server" ID="DdlProducto" CssStyle="width:100%%;" CssClass="DdlPS" CssClassDdl="select2me " DataTextField="PSCodigo" DataValueField="CvePS" />
|
||||||
|
|
||||||
|
|
||||||
|
<%-- <select id="DdlProductows" runat="server" class="form-control"></select><asp:Button ID="myhidenbutton" runat="server" Text="Button" Style="display: none;" />
|
||||||
<asp:HiddenField ID="HFProducto" runat="server" />
|
<asp:HiddenField ID="HFProducto" runat="server" />
|
||||||
<asp:HiddenField ID="HFTProducto" runat="server" />
|
<asp:HiddenField ID="HFTProducto" runat="server" />--%>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</td>
|
</td>
|
||||||
@@ -725,7 +728,8 @@
|
|||||||
<script type="text/javascript">
|
<script type="text/javascript">
|
||||||
|
|
||||||
function AddItem(Text, Value, idproductows) {
|
function AddItem(Text, Value, idproductows) {
|
||||||
// Create an Option object <%= DdlProductows.ClientID%>
|
|
||||||
|
<%-- Create an Option object <%= DdlProductows.ClientID%> --%>
|
||||||
|
|
||||||
var opt = document.createElement("option");
|
var opt = document.createElement("option");
|
||||||
|
|
||||||
@@ -741,7 +745,7 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
Sys.Application.add_load(function (s, e) {
|
<%-- Sys.Application.add_load(function (s, e) {
|
||||||
|
|
||||||
var Tam = TamañoVentana();
|
var Tam = TamañoVentana();
|
||||||
var Alto = Tam.height - 300;
|
var Alto = Tam.height - 300;
|
||||||
@@ -805,73 +809,73 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
});
|
});--%>
|
||||||
|
|
||||||
var DdlProductows = '-1';
|
var DdlProductows = '-1';
|
||||||
var DdlProducto = '-1';
|
var DdlProducto = '-1';
|
||||||
var HFProducto = '-1';
|
var HFProducto = '-1';
|
||||||
var HFTProducto = '-1';
|
var HFTProducto = '-1';
|
||||||
var Myhidenbutton = '-1';
|
var Myhidenbutton = '-1';
|
||||||
function Asigna105(tDdlProductows, tDdlProducto, tHFProducto, tHFTProducto, tsMyhidenbutton) {
|
//function Asigna105(tDdlProductows, tDdlProducto, tHFProducto, tHFTProducto, tsMyhidenbutton) {
|
||||||
|
|
||||||
|
|
||||||
DdlProductoWS = tDdlProductows;
|
// DdlProductoWS = tDdlProductows;
|
||||||
DdlProducto = tDdlProducto;
|
// DdlProducto = tDdlProducto;
|
||||||
HFProducto = tHFProducto;
|
// HFProducto = tHFProducto;
|
||||||
tHFTProducto = tHFTProducto;
|
// tHFTProducto = tHFTProducto;
|
||||||
Myhidenbutton = tsMyhidenbutton;
|
// Myhidenbutton = tsMyhidenbutton;
|
||||||
|
|
||||||
Asigna1052(DdlProductows, DdlProducto, HFProducto, HFTProducto, sMyhidenbutton);
|
// Asigna1052(DdlProductows, DdlProducto, HFProducto, HFTProducto, sMyhidenbutton);
|
||||||
}
|
//}
|
||||||
|
|
||||||
function Asigna1052(DdlProductows, DdlProducto, HFProducto, HFTProducto, sMyhidenbutton) {
|
//function Asigna1052(DdlProductows, DdlProducto, HFProducto, HFTProducto, sMyhidenbutton) {
|
||||||
|
|
||||||
if ($(DdlProductows)) {
|
// if ($(DdlProductows)) {
|
||||||
if (!($(HFProducto).val() === '')) {
|
// if (!($(HFProducto).val() === '')) {
|
||||||
AddItem($(HFTProducto).val(), $(HFProducto).val(), DdlProductows.replace('#', ''));
|
// AddItem($(HFTProducto).val(), $(HFProducto).val(), DdlProductows.replace('#', ''));
|
||||||
}
|
// }
|
||||||
}
|
// }
|
||||||
if ($(DdlProductows).data('creado') === '1') { } else {
|
// if ($(DdlProductows).data('creado') === '1') { } else {
|
||||||
$(DdlProductows).data('creado', '1')
|
// $(DdlProductows).data('creado', '1')
|
||||||
$(DdlProductows).select2({
|
// $(DdlProductows).select2({
|
||||||
ajax: {
|
// ajax: {
|
||||||
url: "/Ashx/SIGWeb.ashx",
|
// url: "/Ashx/SIGWeb.ashx",
|
||||||
dataType: 'json',
|
// dataType: 'json',
|
||||||
delay: 250,
|
// delay: 250,
|
||||||
data: function (params) {
|
// data: function (params) {
|
||||||
return {
|
// return {
|
||||||
Name: params.term, // search term
|
// Name: params.term, // search term
|
||||||
Metodo: 'getps'
|
// Metodo: 'getps'
|
||||||
};
|
// };
|
||||||
},
|
// },
|
||||||
processResults: function (data, params) {
|
// processResults: function (data, params) {
|
||||||
params.page = params.page || 1;
|
// params.page = params.page || 1;
|
||||||
|
|
||||||
return {
|
// return {
|
||||||
results: data,
|
// results: data,
|
||||||
pagination: {
|
// pagination: {
|
||||||
more: (params.page * 30) < data.total_count
|
// more: (params.page * 30) < data.total_count
|
||||||
}
|
// }
|
||||||
};
|
// };
|
||||||
},
|
// },
|
||||||
cache: true
|
// cache: true
|
||||||
},
|
// },
|
||||||
escapeMarkup: function (markup) { return markup; }, // let our custom formatter work
|
// escapeMarkup: function (markup) { return markup; }, // let our custom formatter work
|
||||||
minimumInputLength: 3
|
// minimumInputLength: 3
|
||||||
});
|
// });
|
||||||
}
|
// }
|
||||||
if ($(DdlProductows)) {
|
// if ($(DdlProductows)) {
|
||||||
if (!($(HFProducto).val() === '')) {
|
// if (!($(HFProducto).val() === '')) {
|
||||||
AddItem($(HFTProducto).val(), $(HFProducto).val(), DdlProductows.replace('#', ''));
|
// AddItem($(HFTProducto).val(), $(HFProducto).val(), DdlProductows.replace('#', ''));
|
||||||
}
|
// }
|
||||||
$(DdlProductows).on("select2:select", function (e) { console.log(e); $(HFProducto).val(e.params.data.id); $(HFTProducto).val(e.params.data.text); $(sMyhidenbutton).click(); });
|
// $(DdlProductows).on("select2:select", function (e) { console.log(e); $(HFProducto).val(e.params.data.id); $(HFTProducto).val(e.params.data.text); $(sMyhidenbutton).click(); });
|
||||||
}
|
// }
|
||||||
if ($(DdlProducto)) {
|
// if ($(DdlProducto)) {
|
||||||
$(DdlProducto).on("select2:select", function (e) { console.log(e); $(HFProducto).val(e.params.data.id); $(HFTProducto).val(e.params.data.text); });
|
// $(DdlProducto).on("select2:select", function (e) { console.log(e); $(HFProducto).val(e.params.data.id); $(HFTProducto).val(e.params.data.text); });
|
||||||
|
|
||||||
}
|
// }
|
||||||
|
|
||||||
}
|
//}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -88,6 +88,24 @@ Partial Class Inventarios_Consignaciones
|
|||||||
TxtFechaTraspaso.Text = Now.ToShortDateString
|
TxtFechaTraspaso.Text = Now.ToShortDateString
|
||||||
TxtFechaDevolucion.Text = Now.ToShortDateString
|
TxtFechaDevolucion.Text = Now.ToShortDateString
|
||||||
SoloLectura = False
|
SoloLectura = False
|
||||||
|
|
||||||
|
'Carga Productos
|
||||||
|
DdlProducto.setEsWebService(UsuarioActual.Empresa.Funcionalidad(105) = "1")
|
||||||
|
|
||||||
|
If UsuarioActual.Empresa.Funcionalidad(105) = "1" Then
|
||||||
|
DdlProducto.ddlWS.Attributes.Add("data-cveclasificacion", "-1")
|
||||||
|
DdlProducto.SelectedText = ""
|
||||||
|
DdlProducto.SelectedValue = "-1"
|
||||||
|
DdlProducto.ddl.Visible = False
|
||||||
|
|
||||||
|
Else
|
||||||
|
DdlProducto.ddl.Items.Clear()
|
||||||
|
DdlProducto.ddl.DataSource = GlobalDTPSSimplificado(UsuarioActual.CveEmpresa, CveClasificacion:=-1)
|
||||||
|
DdlProducto.ddl.DataBind()
|
||||||
|
DdlProducto.ddl.Items.Insert(0, New ListItem("Seleccione el Producto", "-1"))
|
||||||
|
DdlProducto.ddlWS.Visible = False
|
||||||
|
End If
|
||||||
|
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Protected Sub CreaDT()
|
Protected Sub CreaDT()
|
||||||
@@ -136,12 +154,12 @@ Partial Class Inventarios_Consignaciones
|
|||||||
Private Sub CargaCombos()
|
Private Sub CargaCombos()
|
||||||
|
|
||||||
'Llenar Clasificaciones
|
'Llenar Clasificaciones
|
||||||
If UsuarioActual.CveEmpresa = 66 Then
|
'If UsuarioActual.CveEmpresa = 66 Then
|
||||||
DdlClasificacion.DataSource = GlobalDTSubFamilias(UsuarioActual.CveEmpresa).FiltraParametros("", Orderby:="Clasificacion")
|
' DdlClasificacion.DataSource = GlobalDTSubFamilias(UsuarioActual.CveEmpresa).FiltraParametros("", Orderby:="Clasificacion")
|
||||||
Else
|
'Else
|
||||||
DdlClasificacion.DataSource = GlobalDTClasificaciones(UsuarioActual.CveEmpresa).FiltraParametros(" Codigo = '' OR Codigo IS NULL ", Orderby:="Clasificacion")
|
' DdlClasificacion.DataSource = GlobalDTClasificaciones(UsuarioActual.CveEmpresa).FiltraParametros(" Codigo = '' OR Codigo IS NULL ", Orderby:="Clasificacion")
|
||||||
End If
|
'End If
|
||||||
DdlClasificacion.DataBind()
|
'DdlClasificacion.DataBind()
|
||||||
|
|
||||||
|
|
||||||
'Llena unidades de medida
|
'Llena unidades de medida
|
||||||
@@ -168,15 +186,19 @@ Partial Class Inventarios_Consignaciones
|
|||||||
DdlProveedorFiltro.SelectedValue = "-1"
|
DdlProveedorFiltro.SelectedValue = "-1"
|
||||||
DdlProveedorFiltro.SelectedText = "Seleccione el Proveedor"
|
DdlProveedorFiltro.SelectedText = "Seleccione el Proveedor"
|
||||||
|
|
||||||
'Llenar el dropdownlist de Productos y servicios
|
''Llenar el dropdownlist de Productos y servicios
|
||||||
If UsuarioActual.Empresa.Funcionalidad(105) = "1" Then
|
'If UsuarioActual.Empresa.Funcionalidad(105) = "1" Then
|
||||||
DdlProducto.DataSource = GlobalDTPSSimplificado(UsuarioActual.CveEmpresa)
|
' DdlProducto.DataSource = GlobalDTPSSimplificado(UsuarioActual.CveEmpresa)
|
||||||
DdlProducto.DataBind()
|
' DdlProducto.DataBind()
|
||||||
DdlProducto.Items.Insert(0, New ListItem("----", "-1"))
|
' DdlProducto.Items.Insert(0, New ListItem("----", "-1"))
|
||||||
DdlProductows.Visible = False
|
' DdlProductows.Visible = False
|
||||||
Else
|
'Else
|
||||||
DdlProducto.Visible = False
|
' DdlProducto.Visible = False
|
||||||
End If
|
'End If
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
DdlSeccionAlmacen.DataSource = GlobalDTSeccionAlmacen(UsuarioActual.CveEmpresa, -1)
|
DdlSeccionAlmacen.DataSource = GlobalDTSeccionAlmacen(UsuarioActual.CveEmpresa, -1)
|
||||||
DdlSeccionAlmacen.DataBind()
|
DdlSeccionAlmacen.DataBind()
|
||||||
@@ -411,9 +433,9 @@ Partial Class Inventarios_Consignaciones
|
|||||||
ImgFecha.Enabled = Not Accion
|
ImgFecha.Enabled = Not Accion
|
||||||
|
|
||||||
TxtCantidad.Enabled = Not Accion
|
TxtCantidad.Enabled = Not Accion
|
||||||
DdlClasificacion.Enabled = Not Accion
|
'DdlClasificacion.Enabled = Not Accion
|
||||||
DdlProducto.Enabled = Not Accion
|
DdlProducto.Enabled = Not Accion
|
||||||
DdlProductows.Disabled = Accion
|
' DdlProductows.Disabled = Accion
|
||||||
DdlUnidad.Enabled = Not Accion
|
DdlUnidad.Enabled = Not Accion
|
||||||
TxtPU.Enabled = Not Accion
|
TxtPU.Enabled = Not Accion
|
||||||
LbAgregar.Visible = Not Accion
|
LbAgregar.Visible = Not Accion
|
||||||
@@ -486,7 +508,7 @@ Partial Class Inventarios_Consignaciones
|
|||||||
Else
|
Else
|
||||||
e.Row.FCDropDownList("DdlClasificacion").DataSource = GlobalDTClasificaciones(UsuarioActual.CveEmpresa).FiltraParametros("", Orderby:="Clasificacion")
|
e.Row.FCDropDownList("DdlClasificacion").DataSource = GlobalDTClasificaciones(UsuarioActual.CveEmpresa).FiltraParametros("", Orderby:="Clasificacion")
|
||||||
End If
|
End If
|
||||||
DdlClasificacion.DataBind()
|
'DdlClasificacion.DataBind()
|
||||||
e.Row.FCDropDownList("DdlClasificacion").DataBind()
|
e.Row.FCDropDownList("DdlClasificacion").DataBind()
|
||||||
e.Row.FCDropDownList("DdlClasificacion").SelectedValue = e.Row.DBCampo("CveClasificacion")
|
e.Row.FCDropDownList("DdlClasificacion").SelectedValue = e.Row.DBCampo("CveClasificacion")
|
||||||
|
|
||||||
@@ -585,7 +607,7 @@ Partial Class Inventarios_Consignaciones
|
|||||||
AddNew()
|
AddNew()
|
||||||
End Sub
|
End Sub
|
||||||
Protected Sub AddNew()
|
Protected Sub AddNew()
|
||||||
Dim PSSelected As Integer = HFProducto.Value.ToEntero
|
Dim PSSelected As Integer = DdlProducto.SelectedValue.ToEntero
|
||||||
|
|
||||||
If PSSelected > 0 Then
|
If PSSelected > 0 Then
|
||||||
|
|
||||||
@@ -632,7 +654,7 @@ Partial Class Inventarios_Consignaciones
|
|||||||
registro.Item("CveUM") = DdlUnidad.SelectedValue.ToEntero
|
registro.Item("CveUM") = DdlUnidad.SelectedValue.ToEntero
|
||||||
registro.Item("UnidadMedida") = DdlUnidad.SelectedItem.Text
|
registro.Item("UnidadMedida") = DdlUnidad.SelectedItem.Text
|
||||||
registro.Item("CvePS") = PSSelected
|
registro.Item("CvePS") = PSSelected
|
||||||
registro.Item("PS") = HFTProducto.Value
|
registro.Item("PS") = DdlProducto.txtText.Value
|
||||||
registro.Item("PSCodigo") = PSCodigo
|
registro.Item("PSCodigo") = PSCodigo
|
||||||
registro.Item("CveClasificacion") = CveClasificacion
|
registro.Item("CveClasificacion") = CveClasificacion
|
||||||
registro.Item("EstatusExistencia") = "1"
|
registro.Item("EstatusExistencia") = "1"
|
||||||
@@ -838,10 +860,13 @@ Partial Class Inventarios_Consignaciones
|
|||||||
DdlMoneda_SelectedIndexChanged(DdlMoneda, EventArgs.Empty)
|
DdlMoneda_SelectedIndexChanged(DdlMoneda, EventArgs.Empty)
|
||||||
|
|
||||||
TxtCantidad.Text = ""
|
TxtCantidad.Text = ""
|
||||||
DdlClasificacion.SelectedValueExist(-1)
|
'DdlClasificacion.SelectedValueExist(-1)
|
||||||
DdlProducto.SelectedValueExist(-1)
|
|
||||||
DdlProductows.Items.Clear()
|
DdlProducto.txtText.Value = ""
|
||||||
DdlProductows.DataBind()
|
DdlProducto.txtValue.Value = ""
|
||||||
|
|
||||||
|
'DdlProductows.Items.Clear()
|
||||||
|
'DdlProductows.DataBind()
|
||||||
TxtPU.Text = ""
|
TxtPU.Text = ""
|
||||||
|
|
||||||
'DEVOLUCION
|
'DEVOLUCION
|
||||||
@@ -916,7 +941,7 @@ Partial Class Inventarios_Consignaciones
|
|||||||
End If
|
End If
|
||||||
|
|
||||||
'AGREGAMOS MOVTOS DETALLE
|
'AGREGAMOS MOVTOS DETALLE
|
||||||
If Not ObjInventario.AddMovimientoDetalle(CveMovimiento, Gvr.FCTextBox("TxtCantidadDevolucion").Text.ToString.ToDouble, Gvr.DataKey("CveUM").ToString.ToEntero, Gvr.DataKey("CvePS").ToString.ToEntero, Gvr.DataKey("PU").ToString.ToDecimal, -1, -1, "", "") Then
|
If Not ObjInventario.AddMovimientoDetalle(CveMovimiento, Gvr.FCTextBox("TxtCantidadDevolucion").Text.ToString.ToDouble, Gvr.DataKey("CveUM").ToString.ToEntero, Gvr.DataKey("CvePS").ToString.ToEntero, Gvr.DataKey("PU").ToString.ToDecimal, -1, -1, Gvr.DataKey("Serie").ToString, Gvr.DataKey("Lote").ToString) Then
|
||||||
ErrorMovInv = True
|
ErrorMovInv = True
|
||||||
TextoError = "Ocurrió un Error al guardar los movimientos"
|
TextoError = "Ocurrió un Error al guardar los movimientos"
|
||||||
Exit For
|
Exit For
|
||||||
@@ -1555,31 +1580,29 @@ Partial Class Inventarios_Consignaciones
|
|||||||
|
|
||||||
|
|
||||||
#Region "DDL CLASIFICACION"
|
#Region "DDL CLASIFICACION"
|
||||||
Protected Sub DdlClasificacion_SelectedIndexChanged(sender As Object, e As System.EventArgs) Handles DdlClasificacion.SelectedIndexChanged
|
'Protected Sub DdlClasificacion_SelectedIndexChanged(sender As Object, e As System.EventArgs) Handles DdlClasificacion.SelectedIndexChanged
|
||||||
ChangeDdlProducto()
|
' ChangeDdlProducto()
|
||||||
End Sub
|
'End Sub
|
||||||
Private Sub ChangeDdlProducto()
|
'Private Sub ChangeDdlProducto()
|
||||||
If UsuarioActual.Empresa.Funcionalidad(105) = "" Then
|
' If UsuarioActual.Empresa.Funcionalidad(105) = "" Then
|
||||||
DdlProducto.DataSource = GlobalDTPSSimplificado(UsuarioActual.CveEmpresa, CveClasificacion:=DdlClasificacion.SelectedValue.ToEntero)
|
' DdlProducto.DataSource = GlobalDTPSSimplificado(UsuarioActual.CveEmpresa, CveClasificacion:=DdlClasificacion.SelectedValue.ToEntero)
|
||||||
DdlProducto.DataBind()
|
' DdlProducto.DataBind()
|
||||||
DdlProducto.Items.Insert(0, New ListItem("----", "-1"))
|
' DdlProducto.Items.Insert(0, New ListItem("----", "-1"))
|
||||||
End If
|
' End If
|
||||||
HFProducto.Value = ""
|
' HFProducto.Value = ""
|
||||||
HFTProducto.Value = ""
|
' HFTProducto.Value = ""
|
||||||
End Sub
|
'End Sub
|
||||||
|
|
||||||
Protected Sub DdlProducto_ValueChanged(sender As Object, e As EventArgs) Handles DdlProducto.SelectedIndexChanged
|
'Protected Sub DdlProducto_ValueChanged(sender As Object, e As EventArgs) Handles DdlProducto.SelectedIndexChanged
|
||||||
ElProductoChange()
|
' ElProductoChange()
|
||||||
End Sub
|
'End Sub
|
||||||
Protected Sub HFProducto_ValueChanged(sender As Object, e As EventArgs) Handles HFProducto.ValueChanged
|
'Protected Sub HFProducto_ValueChanged(sender As Object, e As EventArgs) Handles HFProducto.ValueChanged
|
||||||
ElProductoChange()
|
' ElProductoChange()
|
||||||
End Sub
|
'End Sub
|
||||||
Private Sub ElProductoChange()
|
Private Sub ElProductoChange()
|
||||||
If HFProducto.Value = "" Then
|
|
||||||
HFProducto.Value = DdlProducto.SelectedValue
|
|
||||||
End If
|
|
||||||
|
|
||||||
DdlUnidad.DataSource = GlobalDTProductosServiciosEquivalencias(HFProducto.Value.ToEntero, -1, UsuarioActual.CveEmpresa)
|
|
||||||
|
DdlUnidad.DataSource = GlobalDTProductosServiciosEquivalencias(DdlProducto.txtValue.Value.ToEntero, -1, UsuarioActual.CveEmpresa)
|
||||||
DdlUnidad.DataBind()
|
DdlUnidad.DataBind()
|
||||||
UpDatos.Update()
|
UpDatos.Update()
|
||||||
End Sub
|
End Sub
|
||||||
@@ -1599,25 +1622,25 @@ Partial Class Inventarios_Consignaciones
|
|||||||
Private Function isWhitFamily() As Boolean
|
Private Function isWhitFamily() As Boolean
|
||||||
Return (UsuarioActual.CveEmpresa = 66)
|
Return (UsuarioActual.CveEmpresa = 66)
|
||||||
End Function
|
End Function
|
||||||
Protected Sub DdlProducto_SelectedIndexChanged(sender As Object, e As System.EventArgs) Handles DdlProducto.SelectedIndexChanged
|
'Protected Sub DdlProducto_SelectedIndexChanged(sender As Object, e As System.EventArgs) Handles DdlProducto.SelectedIndexChanged
|
||||||
If Not DdlProducto.SelectedValue = "" Then
|
' If Not DdlProducto.SelectedValue = "" Then
|
||||||
'If DtPS.FiltraParametros( string.Format("CvePS = {0} AND Inv_CveMetodoInventario = 3 ",DdlProducto.SelectedValue)).Rows.Count > 0 Then
|
' 'If DtPS.FiltraParametros( string.Format("CvePS = {0} AND Inv_CveMetodoInventario = 3 ",DdlProducto.SelectedValue)).Rows.Count > 0 Then
|
||||||
' LblSerieLote.Visible = True
|
' ' LblSerieLote.Visible = True
|
||||||
' TxtnSerieLote.Visible = True
|
' ' TxtnSerieLote.Visible = True
|
||||||
'Else
|
' 'Else
|
||||||
' LblSerieLote.Visible = False
|
' ' LblSerieLote.Visible = False
|
||||||
' TxtnSerieLote.Visible = False
|
' ' TxtnSerieLote.Visible = False
|
||||||
'End If
|
' 'End If
|
||||||
End If
|
' End If
|
||||||
Dim dtpse As DataTable
|
' Dim dtpse As DataTable
|
||||||
dtpse = GlobalDTProductosServiciosEquivalencias(DdlProducto.SelectedValue.ToEntero, -1, UsuarioActual.CveEmpresa)
|
' dtpse = GlobalDTProductosServiciosEquivalencias(DdlProducto.SelectedValue.ToEntero, -1, UsuarioActual.CveEmpresa)
|
||||||
'dtpse.Columns("UM").ColumnName = "UnidadMedida"
|
' 'dtpse.Columns("UM").ColumnName = "UnidadMedida"
|
||||||
'dtpse.Columns("CveUM").ColumnName = "CveUnidadMedida"
|
' 'dtpse.Columns("CveUM").ColumnName = "CveUnidadMedida"
|
||||||
DdlUnidad.DataSource = dtpse
|
' DdlUnidad.DataSource = dtpse
|
||||||
DdlUnidad.DataBind()
|
' DdlUnidad.DataBind()
|
||||||
|
|
||||||
|
|
||||||
End Sub
|
'End Sub
|
||||||
#End Region
|
#End Region
|
||||||
|
|
||||||
|
|
||||||
@@ -1680,7 +1703,8 @@ Partial Class Inventarios_Consignaciones
|
|||||||
|
|
||||||
#Region "Columnas Opcionales en PS"
|
#Region "Columnas Opcionales en PS"
|
||||||
|
|
||||||
Protected Sub DdlProducto_Click(sender As Object, e As EventArgs) Handles DdlProducto.SelectedIndexChanged
|
|
||||||
|
Protected Sub DdlProducto_selectedindexchange(sender As Object, e As EventArgs)
|
||||||
If DdlProducto.SelectedValue.ToEntero > 0 Then
|
If DdlProducto.SelectedValue.ToEntero > 0 Then
|
||||||
Dim drp As DataRow = GlobalDTPS(UsuarioActual.CveEmpresa, CvePS:=DdlProducto.SelectedValue.ToEntero).FiltroPrimero("")
|
Dim drp As DataRow = GlobalDTPS(UsuarioActual.CveEmpresa, CvePS:=DdlProducto.SelectedValue.ToEntero).FiltroPrimero("")
|
||||||
|
|
||||||
@@ -1710,9 +1734,14 @@ Partial Class Inventarios_Consignaciones
|
|||||||
End If
|
End If
|
||||||
UpDatos.Update()
|
UpDatos.Update()
|
||||||
End If
|
End If
|
||||||
|
ElProductoChange()
|
||||||
|
|
||||||
|
|
||||||
End Sub
|
End Sub
|
||||||
#End Region
|
#End Region
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
End Class
|
End Class
|
||||||
|
|||||||
@@ -718,19 +718,28 @@ Partial Class Inventarios_EntregaAlmacen
|
|||||||
|
|
||||||
If TipoMovimiento = 2 Then ' cuando es cancelación
|
If TipoMovimiento = 2 Then ' cuando es cancelación
|
||||||
Dim Filtro As String '= If(ObjInventario.DtResultados.Rows(0)("TipoDocto").ToString().Contiene({"Ing", "Dev", "Ped"}), "CveConcepto = 3", "CveConcepto = 9")
|
Dim Filtro As String '= If(ObjInventario.DtResultados.Rows(0)("TipoDocto").ToString().Contiene({"Ing", "Dev", "Ped"}), "CveConcepto = 3", "CveConcepto = 9")
|
||||||
|
Dim FiltroPS As String = ""
|
||||||
Select Case ObjInventario.DtResultados.Rows(0)("TipoDocto").ToString()
|
Select Case ObjInventario.DtResultados.Rows(0)("TipoDocto").ToString()
|
||||||
Case "Ing", "Ped"
|
Case "Ing", "Ped"
|
||||||
Filtro = "CveConcepto IN (3,40)"
|
Filtro = "CveConcepto IN (3,40)"
|
||||||
Case "Dev"
|
Case "Dev"
|
||||||
'cuand es devolucionventa=1, es cancelación de la devolución
|
'cuand es devolucionventa=1, es cancelación de la devolución
|
||||||
If EsDevolucionVenta = 1 Then Filtro = "CveConcepto = 18" Else Filtro = "CveConcepto IN (3,40)"
|
If EsDevolucionVenta = 1 Then
|
||||||
|
Filtro = "CveConcepto = 18"
|
||||||
|
Else
|
||||||
|
Filtro = "CveConcepto IN (3,40)" 'cuando es devolución
|
||||||
|
For Each drr As DataRow In ObjInventario.DtResultados.Rows
|
||||||
|
FiltroPS = FiltroPS + "," + drr("CvePS").ToString
|
||||||
|
Next
|
||||||
|
FiltroPS = "AND CvePS IN (" & FiltroPS.Substring(1) & ")" 'elimino la primer comma
|
||||||
|
End If
|
||||||
Case "DPe"
|
Case "DPe"
|
||||||
Filtro = "CveConcepto = 9"
|
Filtro = "CveConcepto = 9"
|
||||||
Case Else
|
Case Else
|
||||||
Filtro = "CveConcepto = 9"
|
Filtro = "CveConcepto = 9"
|
||||||
End Select
|
End Select
|
||||||
If ObjInventario.GetInv_Mov(ObjInventario.DtResultados.Rows(0)("CveVentaPadre").ToString().ToEntero(), UsuarioActual.CveEmpresa) Then
|
If ObjInventario.GetInv_Mov(ObjInventario.DtResultados.Rows(0)("CveVentaPadre").ToString().ToEntero(), UsuarioActual.CveEmpresa) Then
|
||||||
DtExistencias = ObjInventario.DtResultados.FiltraParametros($"CvePS Is Not NULL AND {Filtro}")
|
DtExistencias = ObjInventario.DtResultados.FiltraParametros($"CvePS Is Not NULL AND {Filtro} " & FiltroPS)
|
||||||
|
|
||||||
If Not DtExistencias.Rows.Count > 0 Then
|
If Not DtExistencias.Rows.Count > 0 Then
|
||||||
Alert("La Venta original de la Devolución no tiene salida de Almacén.", TipoMensaje.MsgAdvertencia)
|
Alert("La Venta original de la Devolución no tiene salida de Almacén.", TipoMensaje.MsgAdvertencia)
|
||||||
@@ -2067,64 +2076,23 @@ Partial Class Inventarios_EntregaAlmacen
|
|||||||
Next
|
Next
|
||||||
End If
|
End If
|
||||||
|
|
||||||
If Not ErrorMovInv Then
|
If Not ErrorMovInv AndAlso CveMovimientoSalida > 0 Then
|
||||||
Dim CvePrePolizaSinCosto As Integer = ObjConta.AddPrePolizas("EA/SinCost", 53, 0, 0, 1, TxtFecha.Text.ToDate, "Entrega", UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa)
|
Dim CvePrePolizaSinCosto As Integer = ObjConta.AddPrePolizas("EA/SinCost", 53, 0, 0, 1, TxtFecha.Text.ToDate, "Entrega", UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa)
|
||||||
If CvePrePolizaSinCosto > 0 Then
|
If CvePrePolizaSinCosto > 0 Then
|
||||||
|
|
||||||
|
If Not ErrorMovInv AndAlso Not ObjConta.AddPrePolizasDetalle(CvePrePolizaSinCosto, True, 0, 0, 68, TxtObservaciones.Text, TxtObservaciones.Text, -1, -1, CveMovimientoAlmacen:=CveMovimientoSalida, Contabilizable:=False) Then
|
||||||
|
ErrorMovInv = True
|
||||||
|
End If
|
||||||
|
|
||||||
If Not ObjConta.AddPrePolizasDetalle(CvePrePolizaSinCosto, False, 0, 0, 68, TxtObservaciones.Text, TxtObservaciones.Text, -1, -1, CveMovimientoAlmacen:=CveMovimientoEntrada, Contabilizable:=False) Then
|
If Not ObjConta.AddPrePolizasDetalle(CvePrePolizaSinCosto, False, 0, 0, 68, TxtObservaciones.Text, TxtObservaciones.Text, -1, -1, CveMovimientoAlmacen:=CveMovimientoEntrada, Contabilizable:=False) Then
|
||||||
ErrorMovInv = True
|
ErrorMovInv = True
|
||||||
End If
|
End If
|
||||||
|
|
||||||
If Not ErrorMovInv AndAlso Not ObjConta.AddPrePolizasDetalle(CvePrePolizaSinCosto, True, 0, 0, 68, TxtObservaciones.Text, TxtObservaciones.Text, -1, -1, CveMovimientoAlmacen:=CveMovimientoSalida, Contabilizable:=False) Then
|
|
||||||
ErrorMovInv = True
|
|
||||||
End If
|
|
||||||
Else
|
Else
|
||||||
ErrorMovInv = True
|
ErrorMovInv = True
|
||||||
End If
|
End If
|
||||||
End If
|
End If
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
Dim ImportePrePoliza As Decimal = 0D
|
|
||||||
|
|
||||||
If ObjInventario.GetMovimientosDetalle(CveMovimientoEntrada, UsuarioActual.CveEmpresa) Then
|
|
||||||
ImportePrePoliza = ObjInventario.DtResultados.SUMD("Total")
|
|
||||||
End If
|
|
||||||
|
|
||||||
|
|
||||||
Dim MovAlmacen As Boolean = True
|
|
||||||
|
|
||||||
Dim OrigenMov As Integer = GlobalDTInvConceptos.FiltroPrimeroValor("Origen", "CveConcepto = " & 9).ToEntero
|
|
||||||
|
|
||||||
If OrigenMov = 1 Then
|
|
||||||
MovAlmacen = True
|
|
||||||
Else
|
|
||||||
MovAlmacen = False
|
|
||||||
End If
|
|
||||||
|
|
||||||
Dim ObjConta2 As New ClsContabilidad(ObjInventario.IniciaTransacSQL)
|
|
||||||
|
|
||||||
Dim Concepto As String = "ARMPAQ2"
|
|
||||||
Dim CvePrePoliza = ObjConta2.AddPrePolizas("RE/GSC1/GSC3/RE/G4", 74, ImportePrePoliza, ImportePrePoliza, 1, TxtFecha.Text.ToDate, Concepto, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa)
|
|
||||||
'Dim tCveSubProyecto = GlobalDTAlmacen(UsuarioActual.CveEmpresa).FiltroPrimeroValor("CveSubProyecto", $"CveAlmacen={CveAlmacen}").ToEntero
|
|
||||||
|
|
||||||
If Not ObjConta2.AddPrePolizasDetalle(CvePrePoliza, Not MovAlmacen, ImportePrePoliza, "RE/G4", 68, "RE/G4", TxtFecha.Text.ToDate, -1, -1, CveVenta:=-1, CveMovimientoAlmacen:=CveMovimientoEntradaApartado, ImporteMX:=ImportePrePoliza, CveSubProyecto:=-1, Contabilizable:=False) Then
|
|
||||||
ErrorMovInv = True
|
|
||||||
End If
|
|
||||||
|
|
||||||
If Not ObjConta2.AddPrePolizasDetalle(CvePrePoliza, MovAlmacen, ImportePrePoliza, "RE/GSC1/GSC3", 68, "RE/GSC1/GSC3", TxtFecha.Text.ToDate, -1, -1, CveVenta:=-1, CveMovimientoAlmacen:=CveMovimientoSalida, ImporteMX:=ImportePrePoliza, Contabilizable:=False) Then
|
|
||||||
ErrorMovInv = True
|
|
||||||
End If
|
|
||||||
|
|
||||||
|
|
||||||
If ObjConta2.ValidacionPrePolizaCuadre(CvePrePoliza, 6) Then
|
|
||||||
If ObjConta2.ValorPolizaDescuadre > 0 Then
|
|
||||||
GuardaLogAD($"Inventarios/RecepcionAlmacen-PPCompOC | Error:{ObjConta2.MensajePolizaDescuadre} Diferencia:{ObjConta2.ValorDiferencia} | CvePrePoliza:{CvePrePoliza}", "LogPrePolizas")
|
|
||||||
ErrorMovInv = True
|
|
||||||
End If
|
|
||||||
End If
|
|
||||||
|
|
||||||
|
|
||||||
End If
|
End If
|
||||||
|
|
||||||
If Not ErrorMovInv Then
|
If Not ErrorMovInv Then
|
||||||
|
|||||||
@@ -82,7 +82,7 @@
|
|||||||
</asp:Content>
|
</asp:Content>
|
||||||
|
|
||||||
<asp:Content ID="Content3" ContentPlaceHolderID="E" runat="Server">
|
<asp:Content ID="Content3" ContentPlaceHolderID="E" runat="Server">
|
||||||
Kardex Almacén Horizontal
|
Existencias Almacen
|
||||||
</asp:Content>
|
</asp:Content>
|
||||||
|
|
||||||
<asp:Content ID="Content4" ContentPlaceHolderID="HB" runat="Server">
|
<asp:Content ID="Content4" ContentPlaceHolderID="HB" runat="Server">
|
||||||
|
|||||||
@@ -599,7 +599,7 @@
|
|||||||
<div class="col-md-12">
|
<div class="col-md-12">
|
||||||
<asp:GridView ID="GVSolicitudesNominas" runat="server" GridLines="None" CssClass="table table-striped table-hover Widthall ScrollAD mysmallbtn" AutoGenerateColumns="False" OnRowDataBound="GVSolicitudesNominas_RowDataBound"
|
<asp:GridView ID="GVSolicitudesNominas" runat="server" GridLines="None" CssClass="table table-striped table-hover Widthall ScrollAD mysmallbtn" AutoGenerateColumns="False" OnRowDataBound="GVSolicitudesNominas_RowDataBound"
|
||||||
ShowHeaderWhenEmpty="true" EmptyDataText="No se encontraron registros"
|
ShowHeaderWhenEmpty="true" EmptyDataText="No se encontraron registros"
|
||||||
DataKeyNames="CveSolicitudDetalle,CveSolicitud,idSolicitudCFDI,idSolicitudMetadata,Estatus,Observaciones,FechaInicio,FechaFin,FechaIng,CveUsuarioIng,CveEmpresa,ArchivoXML,Folio,CveTipoSolicitud">
|
DataKeyNames="CveSolicitudDetalle,CveSolicitud,idSolicitudCFDI,idSolicitudMetadata,Estatus,Observaciones,FechaInicio,FechaFin,FechaIng,CveUsuarioIng,CveEmpresa,ArchivoXML,Folio,CveTipoSolicitud,TipoDescargaStr">
|
||||||
<Columns>
|
<Columns>
|
||||||
<asp:TemplateField HeaderText="Folio">
|
<asp:TemplateField HeaderText="Folio">
|
||||||
<ItemTemplate>
|
<ItemTemplate>
|
||||||
|
|||||||
@@ -255,12 +255,10 @@ public partial class SAT_SolicitudesIngresoSat : ClsPaginas
|
|||||||
}
|
}
|
||||||
|
|
||||||
protected void LnkverificarSolicitudes_Click(object sender, EventArgs e)
|
protected void LnkverificarSolicitudes_Click(object sender, EventArgs e)
|
||||||
{
|
{
|
||||||
|
|
||||||
|
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
StringBuilder sbResultado = new StringBuilder();
|
StringBuilder sbResultado = new StringBuilder();
|
||||||
@@ -581,10 +579,18 @@ public partial class SAT_SolicitudesIngresoSat : ClsPaginas
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
e.Row.Attributes.Add("data-html", "true");
|
Label lblobservaciones = e.Row.FCLabel("lblobservaciones");
|
||||||
e.Row.Attributes.Add("data-toggle", "tooltip");
|
Label lBLTipoDescarga = e.Row.FCLabel("lBLTipoDescarga");
|
||||||
e.Row.Attributes.Add("data-placement", "top");
|
|
||||||
e.Row.Attributes.Add("title", e.Row.DataKey("Observaciones"));
|
lblobservaciones.Attributes.Add("data-html", "true");
|
||||||
|
lblobservaciones.Attributes.Add("data-toggle", "tooltip");
|
||||||
|
lblobservaciones.Attributes.Add("data-placement", "top");
|
||||||
|
lblobservaciones.Attributes.Add("title", e.Row.DataKey("Observaciones"));
|
||||||
|
|
||||||
|
lBLTipoDescarga.Attributes.Add("data-html", "true");
|
||||||
|
lBLTipoDescarga.Attributes.Add("data-toggle", "tooltip");
|
||||||
|
lBLTipoDescarga.Attributes.Add("data-placement", "top");
|
||||||
|
lBLTipoDescarga.Attributes.Add("title", e.Row.DataKey("TipoDescargaStr"));
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -72,7 +72,7 @@
|
|||||||
<li>
|
<li>
|
||||||
<asp:HyperLink NavigateUrl="#" data-toggle="modal" data-target="#DivPersonalizar" ID="ImgPersonalizar" runat="server"> <i class="fa fa-pencil"></i> Personalizar</asp:HyperLink>
|
<asp:HyperLink NavigateUrl="#" data-toggle="modal" data-target="#DivPersonalizar" ID="ImgPersonalizar" runat="server"> <i class="fa fa-pencil"></i> Personalizar</asp:HyperLink>
|
||||||
</li>
|
</li>
|
||||||
</ContentTemplate>
|
</ContentTemplate>
|
||||||
</asp:UpdatePanel>
|
</asp:UpdatePanel>
|
||||||
<asp:UpdatePanel ID="UpLnkHP" runat="server" UpdateMode="Conditional">
|
<asp:UpdatePanel ID="UpLnkHP" runat="server" UpdateMode="Conditional">
|
||||||
<ContentTemplate>
|
<ContentTemplate>
|
||||||
@@ -89,7 +89,15 @@
|
|||||||
<li>
|
<li>
|
||||||
<asp:LinkButton ID="LnkVerGrafica" OnClick="LnkVerGrafica_Click" runat="server"><i class="fa fa-signal"></i> Ver Grafica</asp:LinkButton>
|
<asp:LinkButton ID="LnkVerGrafica" OnClick="LnkVerGrafica_Click" runat="server"><i class="fa fa-signal"></i> Ver Grafica</asp:LinkButton>
|
||||||
</li>
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<asp:LinkButton ID="LnkDescargaCartaPorte" OnClick="LnkDescargaCartaPorte_Click" runat="server" Visible="false"> <i class="fa fa-file-excel-o" style="font-weight:bold;"></i> Descarga Carta Porte</asp:LinkButton>
|
||||||
|
</li>
|
||||||
|
|
||||||
</ContentTemplate>
|
</ContentTemplate>
|
||||||
|
<Triggers>
|
||||||
|
<asp:PostBackTrigger ControlID="LnkDescargaCartaPorte" />
|
||||||
|
</Triggers>
|
||||||
</asp:UpdatePanel>
|
</asp:UpdatePanel>
|
||||||
</asp:Content>
|
</asp:Content>
|
||||||
<asp:Content ID="Content4" ContentPlaceHolderID="E" runat="Server">
|
<asp:Content ID="Content4" ContentPlaceHolderID="E" runat="Server">
|
||||||
|
|||||||
@@ -120,6 +120,11 @@ Partial Class Ventas_RepVentas
|
|||||||
DdlVendedor.Attributes.Add("disabled", "disabled")
|
DdlVendedor.Attributes.Add("disabled", "disabled")
|
||||||
DdlVendedor.Enabled = False
|
DdlVendedor.Enabled = False
|
||||||
End If
|
End If
|
||||||
|
|
||||||
|
If UsuarioActual.CveEmpresa.Contiene(13, 83) Then
|
||||||
|
LnkDescargaCartaPorte.Visible = True
|
||||||
|
End If
|
||||||
|
|
||||||
End If
|
End If
|
||||||
|
|
||||||
End Sub
|
End Sub
|
||||||
@@ -936,4 +941,26 @@ Partial Class Ventas_RepVentas
|
|||||||
Context.Response.End()
|
Context.Response.End()
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
|
|
||||||
|
Protected Sub LnkDescargaCartaPorte_Click(sender As Object, e As EventArgs)
|
||||||
|
|
||||||
|
|
||||||
|
Dim ObjVentas As New ClsVentas
|
||||||
|
Dim DTDataos As New DataTable
|
||||||
|
Dim CveSubProyectos As String = If(DdlSubProyecto.GetSelectedValuesM = "", "-1", DdlSubProyecto.GetSelectedValuesM)
|
||||||
|
|
||||||
|
|
||||||
|
If ObjVentas.GetListadoCartaPorteRep(txtFechaI.Text.ToDate, txtFechaF.Text.ToDate, CveSubProyectos, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa) Then
|
||||||
|
DTDataos = ObjVentas.DtResultados
|
||||||
|
End If
|
||||||
|
|
||||||
|
ObjVentas.Dispose()
|
||||||
|
|
||||||
|
|
||||||
|
DTDataos.ExportToExcel("RepCartasPorte.xls")
|
||||||
|
|
||||||
|
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
|
||||||
End Class
|
End Class
|
||||||
|
|||||||
Reference in New Issue
Block a user