Merge branch 'master' of http://192.168.10.111:8383/SIG
This commit is contained in:
@@ -1855,15 +1855,15 @@ Public Class ClsInventarios
|
||||
Return Retorno
|
||||
End Function
|
||||
|
||||
Public Function RepAlmacenCompras(CveAlmacen As Integer, FechaI As Date, FechaF As Date, CveEmpresa As Integer) As Boolean
|
||||
Public Function RepAlmacenCompras(CveAlmacen As Integer, FechaI As Date, FechaF As Date, CveSubProyecto As Integer, CveEmpresa As Integer) As Boolean
|
||||
Dim Retorno As Boolean = False
|
||||
DataAdapter("PA_Inv_RepAlmacenCompras")
|
||||
|
||||
|
||||
With SqlAdapter.SelectCommand.Parameters
|
||||
.Add("@CveAlmacen", SqlDbType.Int).Value = CveAlmacen
|
||||
.Add("@FechaI", SqlDbType.Date).Value = FechaI
|
||||
.Add("@FechaF", SqlDbType.Date).Value = FechaF
|
||||
.Add("@CveSubProyecto", SqlDbType.Int).Value = CveSubProyecto
|
||||
.Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa
|
||||
End With
|
||||
|
||||
@@ -4997,7 +4997,7 @@ Public Class ClsInventarios
|
||||
|
||||
Public Function GetFletesRep(CveEmpresa As Integer, Optional CveFlete As Integer = -1, Optional Folio As String = "-1", Optional CveProveedor As Integer = -1,
|
||||
Optional CveOC As Integer = -1, Optional CveCompra As Integer = -1, Optional FechaInicio As Date = MinFecha,
|
||||
Optional FechaFin As Date = MaxFecha, Optional TipoGasto As Integer = -1) As Boolean
|
||||
Optional FechaFin As Date = MaxFecha, Optional TipoGasto As Integer = -1, Optional CveEstatus As Integer = -1) As Boolean
|
||||
Dim Retorno As Boolean = False
|
||||
DataAdapter("PA_Inv_FletesRep")
|
||||
With SqlAdapter.SelectCommand.Parameters
|
||||
@@ -5010,6 +5010,7 @@ Public Class ClsInventarios
|
||||
.Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa
|
||||
.Add("@CveFlete", SqlDbType.Int).Value = CveFlete
|
||||
.Add("@TipoGasto", SqlDbType.Int).Value = TipoGasto
|
||||
.Add("@CveEstatus", SqlDbType.Int).Value = CveEstatus
|
||||
End With
|
||||
Try
|
||||
SqlAdapter.Fill(Data)
|
||||
|
||||
@@ -3297,13 +3297,14 @@ Public Class ClsVentas
|
||||
Return Retorno
|
||||
End Function
|
||||
|
||||
Public Function GetCortesDetalleVentasResumen(CveCorte As Integer, CveEmpresa As Integer) As Boolean
|
||||
Public Function GetCortesDetalleVentasResumen(CveCorte As Integer, CveSubProyecto As Integer, CveEmpresa As Integer) As Boolean
|
||||
Dim Retorno As Boolean = False
|
||||
|
||||
DataAdapter("PA_Vta_CortesDetalleVentasResumenGet")
|
||||
|
||||
With SqlAdapter.SelectCommand.Parameters
|
||||
.Add("@CveCorte", SqlDbType.Int).Value = CveCorte
|
||||
.Add("@CveSubProyecto", SqlDbType.Int).Value = CveSubProyecto
|
||||
.Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa
|
||||
End With
|
||||
|
||||
|
||||
@@ -4816,7 +4816,7 @@ Namespace Modelos
|
||||
Dim MensajeError As String = ""
|
||||
Dim ObjCancelacion As New Timbrado
|
||||
Dim TotalT As Decimal = ObjFactura.Total
|
||||
Dim RFCReceptor As String = ObjFactura.Cliente.RFC
|
||||
Dim RFCReceptor As String = If(String.IsNullOrEmpty(ObjFactura.RFCReceptor), ObjFactura.Cliente.RFC, ObjFactura.RFCReceptor)
|
||||
Dim CvePACCancelacion As Integer = ObjFactura.CvePAC
|
||||
|
||||
If CvePACCancelacion <= 0 Then
|
||||
@@ -4917,7 +4917,7 @@ Namespace Modelos
|
||||
CancelacionFecha = ObjCancelacion.CancelacionFecha
|
||||
CveEstatus = 5
|
||||
End If
|
||||
CancelacionAcuse = ObjCancelacion.CancelacionAcuse
|
||||
CancelacionAcuse = Resp.CancelacionAcuse
|
||||
SolicitudCancelacionAcuse = Resp.SolicitudCancelacionAcuse
|
||||
Else
|
||||
Retorno.Mensaje = "Los servicios de cancelación del SAT no se encuentran disponibles o presentan time out. Intente de nuevo en unos minutos.<br/>Origen del error: WebService www.sat.gob.mx"
|
||||
@@ -5000,7 +5000,7 @@ Namespace Modelos
|
||||
'End If
|
||||
CveEstatus = Resp.CveEstatus
|
||||
CancelacionFecha = Resp.CancelacionFecha
|
||||
CancelacionAcuse = ObjCancelacion.CancelacionAcuse
|
||||
CancelacionAcuse = Resp.CancelacionAcuse
|
||||
SolicitudCancelacionAcuse = Resp.SolicitudCancelacionAcuse
|
||||
Else
|
||||
Retorno.Mensaje = "Los servicios de cancelación del SAT no se encuentran disponibles o presentan time out. Intente de nuevo en unos minutos.<br/>Origen del error: WebService www.sat.gob.mx"
|
||||
@@ -5042,7 +5042,13 @@ Namespace Modelos
|
||||
|
||||
Dim msgBitacora As String = "Solicitud de cancelación de factura"
|
||||
If EsRefacturacion Then
|
||||
msgBitacora = "Solicitud de cancelación por refacturación"
|
||||
If Not String.IsNullOrEmpty(CancelacionAcuse) Then
|
||||
msgBitacora = $"Solicitud de cancelación por refacturación. SelloSAT: {CancelacionAcuse}"
|
||||
ElseIf Not String.IsNullOrEmpty(SolicitudCancelacionAcuse) Then
|
||||
msgBitacora = $"Solicitud de cancelación por refacturación. SelloSAT: {SolicitudCancelacionAcuse}"
|
||||
Else
|
||||
msgBitacora = "Solicitud de cancelación por refacturación."
|
||||
End If
|
||||
End If
|
||||
|
||||
Dim ObjE As New ClsOIEventos()
|
||||
@@ -5154,7 +5160,7 @@ Namespace Modelos
|
||||
Dim EstatusDevolucion = 1
|
||||
If Not ObjVentas.UpdateVentasDevolucionAlmacen(EstatusDevolucion, CveVenta) Then
|
||||
ErrorCancelar = True
|
||||
MensajeError = "Ocurrió un error al solicitar la devolucion de almacen."
|
||||
MensajeError = "Ocurrió un error al solicitar la devolución de almacen."
|
||||
End If
|
||||
End If
|
||||
|
||||
|
||||
@@ -775,22 +775,29 @@ Public Class Timbrado
|
||||
End Select
|
||||
|
||||
'valida que si se halla cancelado
|
||||
Dim VigenciaExtra = VerificarVigenciaSAT(FolioFiscal, RFCEmisor, RFCReceptor, Total.ToString(), True)
|
||||
If Retorno.Verificado AndAlso VigenciaExtra IsNot Nothing Then
|
||||
If VigenciaExtra.Estado.ToUpper = "VIGENTE" AndAlso Not VigenciaExtra.EstatusCancelacion.ToUpper.Contiene("EN PROCESO") Then
|
||||
Retorno.Estado = "VIGENTE"
|
||||
Retorno.CveEstatus = 23
|
||||
End If
|
||||
If VigenciaExtra.Estado.ToUpper = "VIGENTE" AndAlso VigenciaExtra.EstatusCancelacion.ToUpper.Contiene("EN PROCESO") Then
|
||||
Retorno.Estado = "EN PROCESO"
|
||||
Retorno.CveEstatus = 20
|
||||
Retorno.SolicitudCancelacionAcuse = Retorno.CancelacionAcuse
|
||||
End If
|
||||
If VigenciaExtra.Estado.ToUpper = "CANCELADO" Then
|
||||
Retorno.Estado = "CANCELADO"
|
||||
Retorno.CveEstatus = 5
|
||||
End If
|
||||
|
||||
If Retorno.Verificado Then
|
||||
Dim VigenciaExtra = VerificarVigenciaSAT(FolioFiscal, RFCEmisor, RFCReceptor, Total.ToString(), True)
|
||||
If VigenciaExtra IsNot Nothing Then
|
||||
If VigenciaExtra.Estado.ToUpper = "VIGENTE" AndAlso VigenciaExtra.EstatusCancelacion.ToUpper.Contiene("EN PROCESO") Then
|
||||
Retorno.Estado = "EN PROCESO"
|
||||
Retorno.CveEstatus = 20
|
||||
'CUANDO ESTA EN PROCESO EL ACUSE DEBE SER DE SOLICITUD DE CANCELACION
|
||||
Retorno.SolicitudCancelacionAcuse = Retorno.CancelacionAcuse
|
||||
Retorno.CancelacionAcuse = ""
|
||||
ElseIf VigenciaExtra.Estado.ToUpper = "CANCELADO" Then
|
||||
Retorno.Estado = "CANCELADO"
|
||||
Retorno.CveEstatus = 5
|
||||
Else
|
||||
Retorno.Estado = "VIGENTE"
|
||||
Retorno.CveEstatus = 23
|
||||
'SI HAY UN ACUSE, GUARDARLO COMO ACUSE DE SOLICITUD
|
||||
If Not String.IsNullOrEmpty(Retorno.CancelacionAcuse) Then
|
||||
Retorno.SolicitudCancelacionAcuse = Retorno.CancelacionAcuse
|
||||
Retorno.CancelacionAcuse = ""
|
||||
End If
|
||||
End If
|
||||
End If
|
||||
End If
|
||||
|
||||
If Not Retorno.Verificado Then
|
||||
|
||||
@@ -1568,6 +1568,7 @@ Partial Class Bancos_ProveedoresAbonar
|
||||
End If
|
||||
|
||||
If gvr.FCTextBox("TxtComision").Text.ToDecimal < 0 Then
|
||||
ConceptoContable = 78
|
||||
TipoMovimiento = True
|
||||
ImporteMovimiento = ImporteMovimiento * -1
|
||||
importeMX = importeMX * -1
|
||||
@@ -1577,8 +1578,8 @@ Partial Class Bancos_ProveedoresAbonar
|
||||
IdCtaContable = UsuarioActual.Empresa.Funcionalidad(266).ToEntero()
|
||||
End If
|
||||
|
||||
ImporteMovimiento = Math.Round(ImporteMovimiento, 2, MidpointRounding.AwayFromZero)
|
||||
importeMX = Math.Round(importeMX, 2, MidpointRounding.AwayFromZero)
|
||||
ImporteMovimiento = ImporteMovimiento.RoundSQL
|
||||
importeMX = importeMX.RoundSQL
|
||||
TipoCambioGeneral = TipoCambioPago
|
||||
|
||||
End If
|
||||
@@ -2862,14 +2863,20 @@ Partial Class Bancos_ProveedoresAbonar
|
||||
End If
|
||||
|
||||
Saldo = Saldo - IEPS
|
||||
|
||||
End If
|
||||
|
||||
' se manda al ot ingresos, los impuestos por acreditar
|
||||
If MsgError = "" AndAlso Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, True, Saldo, gr.DataKey("SerieFolio").ToString, 78, ConceptoPartida, Now, IdCtaContable:=UsuarioActual.Empresa.IdCuentaOtrosIngresos, CveIE:=-1, IdSegmentoNegocio:=-1, CveProveedor:=gr.DataKey("CveProveedor").ToEntero, CveCompra:=gr.DataKey("CveCompra").ToEntero, ImporteMX:=If(CveMoneda = 1, Saldo, Saldo * TCPago), TipoCambio:=TCCompra, TipoCambioPago:=TCPago, CveSubProyecto:=CveSubProyecto) Then
|
||||
MsgError = "Ocurrio un error al saldar el movimiento"
|
||||
If MsgError = "" Then
|
||||
Dim tcvecon As Integer = 78
|
||||
If Saldo < 0 Then
|
||||
tcvecon = 211
|
||||
End If
|
||||
If MsgError = "" AndAlso Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, True, Saldo, gr.DataKey("SerieFolio").ToString, tcvecon, ConceptoPartida, Now, IdCtaContable:=UsuarioActual.Empresa.IdCuentaOtrosIngresos, CveIE:=-1, IdSegmentoNegocio:=-1, CveProveedor:=gr.DataKey("CveProveedor").ToEntero, CveCompra:=gr.DataKey("CveCompra").ToEntero, ImporteMX:=If(CveMoneda = 1, Saldo, Saldo * TCPago), TipoCambio:=TCCompra, TipoCambioPago:=TCPago, CveSubProyecto:=CveSubProyecto) Then
|
||||
MsgError = "Ocurrio un error al saldar el movimiento"
|
||||
End If
|
||||
End If
|
||||
|
||||
|
||||
'fluctuación.
|
||||
If CveMoneda > 1 Then
|
||||
Dim ImporteFluctuacion As Decimal = 0
|
||||
@@ -2879,7 +2886,6 @@ Partial Class Bancos_ProveedoresAbonar
|
||||
MsgError = "No se pudo obtener el sub proyecto o centro de costo"
|
||||
End If
|
||||
|
||||
|
||||
If TCCompra > TCPago Then
|
||||
If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, True, Math.Abs(ImporteFluctuacion), gr.DataKey("SerieFolio").ToString, 64, ConceptoPartida, TxtFechaIncobrable.Text.ToDate, IdCtaContable:=UsuarioActual.Empresa.IdCuentaGananciaCambiaria, CveIE:=-1, IdSegmentoNegocio:=-1, CveSubProyecto:=CveSubProyecto, CveProveedor:=gr.DataKey("CveProveedor").ToEntero, CveCompra:=gr.DataKey("CveCompra").ToEntero, ImporteMX:=Math.Abs(ImporteFluctuacion), TipoCambio:=TCCompra, TipoCambioPago:=TCPago) Then
|
||||
MsgError = "Ocurrio un error al saldar el movimiento"
|
||||
@@ -2889,12 +2895,8 @@ Partial Class Bancos_ProveedoresAbonar
|
||||
MsgError = "Ocurrio un error al saldar el movimiento"
|
||||
End If
|
||||
End If
|
||||
|
||||
|
||||
End If
|
||||
|
||||
|
||||
|
||||
If MsgError = "" AndAlso ObjConta.ValidacionPrePolizaCuadre(CvePrePoliza, 5) Then
|
||||
If ObjConta.ValorPolizaDescuadre > 0 Then
|
||||
MsgError = ObjConta.MensajePolizaDescuadre + " " + ObjConta.ValorDiferencia
|
||||
@@ -2906,7 +2908,6 @@ Partial Class Bancos_ProveedoresAbonar
|
||||
|
||||
If ObjConta.ContabilizarPrePoliza(CvePrePoliza, UsuarioActual.CveUsuario, UsuarioActual.Empresa) Then
|
||||
' Alert(alertaContabilizacion, ModExtensiones.TipoMensaje.MsgInformacion)
|
||||
|
||||
Else
|
||||
'Alert("Ocurrio un error al contabilizar, pongase en contacto con Soporte Técnico", TipoMensaje.MsgError)
|
||||
MsgError = "Ocurrio un error al contabilizar, pongase en contacto con Soporte Técnico"
|
||||
|
||||
@@ -151,11 +151,11 @@ Partial Class Bancos_RepCortes
|
||||
Nombre = gvr.DataKey("Nombre").ToString
|
||||
Dim Vent As New ClsPuntoVenta
|
||||
Dim Vn As New ClsVentas
|
||||
If Vn.GetCortesDetalleVentasResumen(CveCorte, UsuarioActual.CveEmpresa) Then
|
||||
If Vn.GetCortesDetalleVentasResumen(CveCorte, DdlSubProyectos.SelectedValue.ToEntero, UsuarioActual.CveEmpresa) Then
|
||||
GvP.DataSource = Vn.DtResultados
|
||||
DtCortesVentasResumen = Vn.DtResultados
|
||||
End If
|
||||
If Vent.GetCortesDetalleVentas(CveCorte, UsuarioActual.CveEmpresa) Then
|
||||
If Vent.GetCortesDetalleVentas(CveCorte, DdlSubProyectos.SelectedValue.ToEntero, UsuarioActual.CveEmpresa) Then
|
||||
GvD.DataSource = Vent.DtResultados
|
||||
DtCortesVentas = Vent.DtResultados
|
||||
divDetalle.Visible = True
|
||||
|
||||
@@ -2194,9 +2194,8 @@ Partial Class Compras_Compras
|
||||
DdlRetISRConcepto.Items.Clear()
|
||||
DdlRetISRConcepto.Items.Insert(0, New ListItem("Honorarios", "1"))
|
||||
DdlRetISRConcepto.Items.Insert(1, New ListItem("Arrendamiento", "2"))
|
||||
If UsuarioActual.CveEmpresa.Contiene(119, 7, 11, 12, 122, 145) Then
|
||||
DdlRetISRConcepto.Items.Insert(1, New ListItem("Resico", "3"))
|
||||
End If
|
||||
DdlRetISRConcepto.Items.Insert(1, New ListItem("Resico", "3"))
|
||||
|
||||
End If
|
||||
UpPS.Update()
|
||||
End Sub
|
||||
@@ -14675,7 +14674,7 @@ Partial Class Compras_Compras
|
||||
Protected Sub BtnRefacturacionVer_Click(sender As Object, e As EventArgs) Handles BtnRefacturacionVer.Click
|
||||
Dim Opcion As Integer = 1
|
||||
|
||||
If UsuarioActual.CveEmpresa.Contiene(119, 1) Then Opcion = 2
|
||||
If UsuarioActual.CveEmpresa.Contiene(119, 1, 140) Then Opcion = 2
|
||||
|
||||
Dim ObjCompras As New ClsCompras
|
||||
|
||||
@@ -20315,10 +20314,14 @@ Partial Class Compras_Compras
|
||||
ObjCompras.Dispose()
|
||||
|
||||
Dim ObjInv As New ClsInventarios
|
||||
If ObjInv.GetFletes(UsuarioActual.CveEmpresa, OpcionInventario:=1) Then
|
||||
DdlFletes.DataSource = ObjInv.DtResultados
|
||||
If ObjInv.GetFletesRep(UsuarioActual.CveEmpresa, -1, "-1", -1, -1, -1, MinFecha, MaxFecha, TipoGasto:=1, CveEstatus:=0) Then
|
||||
DdlFletes.DataSource = ObjInv.DtResultados.FiltraParametros("CveFlete > 0")
|
||||
DdlFletes.Items.Insert(0, New ListItem("Seleccione", "-1"))
|
||||
End If
|
||||
'If ObjInv.GetFletes(UsuarioActual.CveEmpresa, OpcionInventario:=1) Then
|
||||
' DdlFletes.DataSource = ObjInv.DtResultados
|
||||
' DdlFletes.Items.Insert(0, New ListItem("Seleccione", "-1"))
|
||||
'End If
|
||||
ObjInv.Dispose()
|
||||
|
||||
DdlImportaciones.DataBind()
|
||||
|
||||
@@ -1524,22 +1524,22 @@
|
||||
<asp:Literal ID="LtlDiasVencido" runat="server" Text='<%# Eval("DiasVencidos", "{0}") %>'></asp:Literal>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="Total">
|
||||
<asp:TemplateField HeaderText="Total" ItemStyle-HorizontalAlign="Right">
|
||||
<ItemTemplate>
|
||||
<asp:Literal ID="LtlSaldoOriginal" runat="server" Text='<%# Eval("Original", "{0:N2}") %>'></asp:Literal>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="Abonado">
|
||||
<asp:TemplateField HeaderText="Abonado" ItemStyle-HorizontalAlign="Right">
|
||||
<ItemTemplate>
|
||||
<asp:Literal ID="LtlAbonado" runat="server" Text='<%# Eval("Abonado", "{0:N2}") %>'></asp:Literal>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="% Abonado">
|
||||
<asp:TemplateField HeaderText="% Abonado" ItemStyle-HorizontalAlign="Right">
|
||||
<ItemTemplate>
|
||||
<asp:Literal ID="LtlPorRecuperado" runat="server" Text='<%# Eval("PorPagado", "{0:N2}%") %>'></asp:Literal>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="Saldo">
|
||||
<asp:TemplateField HeaderText="Saldo" ItemStyle-HorizontalAlign="Right">
|
||||
<ItemTemplate>
|
||||
<asp:Literal ID="LtlSaldo" runat="server" Text='<%# Eval("Saldo", "{0:N2}") %>'></asp:Literal>
|
||||
</ItemTemplate>
|
||||
@@ -1602,37 +1602,37 @@
|
||||
</div>
|
||||
<asp:GridView ID="GvCxPHistorial" runat="server" AutoGenerateColumns="False" EmptyDataText="No se encontró Historial de Cuentas X Pagar" CssClass="table table-striped table-hover Widthall ScrollAD" data-sort="true" GridLines="None" BorderColor="#D3D3D3" BorderWidth="1">
|
||||
<Columns>
|
||||
<asp:TemplateField HeaderText="Factura">
|
||||
<asp:TemplateField HeaderText="SerieFolio">
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="LtlFactura" runat="server"></asp:Label>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="Fecha Compra">
|
||||
<asp:TemplateField HeaderText="Fecha">
|
||||
<ItemTemplate>
|
||||
<asp:Literal ID="LtlFecha" runat="server" Text='<%# Eval("Fecha", "{0:d}") %>'></asp:Literal>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="Fecha Vencimiento">
|
||||
<asp:TemplateField HeaderText="F. Vencimiento">
|
||||
<ItemTemplate>
|
||||
<asp:Literal ID="LtlFechaVenci" runat="server" Text='<%# Eval("FechaVencimiento", "{0:d}") %>'></asp:Literal>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="Días Vencidos">
|
||||
<asp:TemplateField HeaderText="Días Venc.">
|
||||
<ItemTemplate>
|
||||
<asp:Literal ID="LtlDiasVencido" runat="server" Text='<%# Eval("DiasVencidos", "{0}") %>'></asp:Literal>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="Monto Compra (Saldo Orig)">
|
||||
<asp:TemplateField HeaderText="Total" ItemStyle-HorizontalAlign="Right">
|
||||
<ItemTemplate>
|
||||
<asp:Literal ID="LtlSaldoOriginal" runat="server" Text='<%# Eval("Original", "{0:N2}") %>'></asp:Literal>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="Abonado">
|
||||
<asp:TemplateField HeaderText="Abonado" ItemStyle-HorizontalAlign="Right">
|
||||
<ItemTemplate>
|
||||
<asp:Literal ID="LtlAbonado" runat="server" Text='<%# Eval("Abonado", "{0:N2}") %>'></asp:Literal>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="% Pagado">
|
||||
<asp:TemplateField HeaderText="% Pagado" ItemStyle-HorizontalAlign="Right">
|
||||
<ItemTemplate>
|
||||
<asp:Literal ID="LtlPorRecuperado" runat="server" Text='<%# Eval("PorPagado", "{0:N2}%") %>'></asp:Literal>
|
||||
</ItemTemplate>
|
||||
|
||||
@@ -2613,12 +2613,6 @@ Partial Class Compras_Proveedores
|
||||
|
||||
End If
|
||||
|
||||
e.Row.Cells(5).HorizontalAlign = HorizontalAlign.Right
|
||||
e.Row.Cells(6).HorizontalAlign = HorizontalAlign.Right
|
||||
e.Row.Cells(7).HorizontalAlign = HorizontalAlign.Right
|
||||
e.Row.Cells(8).HorizontalAlign = HorizontalAlign.Right
|
||||
|
||||
|
||||
|
||||
If e.Row.DBCampo("Saldo").ToDouble < 0 Then e.Row.Cells(6).ForeColor = Drawing.Color.Red
|
||||
If e.Row.DBCampo("DiasVencidos").ToDouble > 0 AndAlso CType(sender, GridView).ID = "GvCxP" Then e.Row.Cells(4).ForeColor = Drawing.Color.Red
|
||||
|
||||
@@ -546,7 +546,7 @@ Partial Class ContabilidadC_RegPrePolizaS
|
||||
End If
|
||||
|
||||
|
||||
If dr("FolioPoliza").ToString = "" Then
|
||||
If dr("FolioPoliza").ToString = "" OrElse dr("FolioPoliza").ToString = "0" Then
|
||||
BtnContabilizar.Visible = True
|
||||
End If
|
||||
|
||||
@@ -1099,7 +1099,7 @@ Partial Class ContabilidadC_RegPrePolizaS
|
||||
|
||||
End If
|
||||
|
||||
If gvr.DataKey("CveConcepto").ToEntero <> 30 Then
|
||||
If Not gvr.DataKey("CveConcepto").Contiene("30", "10") Then ' 30-bancos, 10-anticipos proveedores
|
||||
|
||||
If gvr.DataKey("CveConcepto").ToEntero = 41 Then
|
||||
CveIE = gvr.FCDropDownList("DdlSaldos").SelectedValue.ToEntero
|
||||
@@ -2696,7 +2696,12 @@ Partial Class ContabilidadC_RegPrePolizaS
|
||||
End If
|
||||
|
||||
If ObjConta.ContabilizarPrePoliza(CvePrePoliza, UsuarioActual.CveUsuario, UsuarioActual.Empresa, pIDPoliza:=If(IdPoliza > 0, IdPoliza, -1), Concepto:=TxtConcepto.Text, Fecha:=TxtFechaDocumento.Text.ToDateTime()) Then
|
||||
Alert(String.Format("Prepóliza contabilizada. <br/><br/>Folio:<a Class=""Texto"" target='_blank' href=""/Contabilidad/RegPoliza.aspx?IdPoliza={0}"">Ver Póliza</a>", ObjConta.ContaIdPoliza), ModExtensiones.TipoMensaje.MsgInformacion)
|
||||
If UsuarioActual.Empresa.TipoContabilizacion = 1 Then
|
||||
Alert(String.Format("Prepóliza contabilizada. <br/><br/>Folio: <b>{0}</b> ", ObjConta.FolioPoliza), ModExtensiones.TipoMensaje.MsgInformacion)
|
||||
Else
|
||||
Alert(String.Format("Prepóliza contabilizada. <br/><br/>Folio:<a Class=""Texto"" target='_blank' href=""/Contabilidad/RegPoliza.aspx?IdPoliza={0}"">Ver Póliza</a>", ObjConta.ContaIdPoliza), ModExtensiones.TipoMensaje.MsgInformacion)
|
||||
End If
|
||||
|
||||
Else
|
||||
|
||||
Alert($"Ocurrio un error al contabilizar {ObjConta.AlertaMensaje}", TipoMensaje.MsgAdvertencia)
|
||||
|
||||
@@ -70,7 +70,7 @@ Partial Class Contabilidad2_CatCuentasAsignaciones
|
||||
|
||||
If ObjConta.GetConta_ConceptosContables() Then
|
||||
DdlCconceptosContables.DataSource = ObjConta.DtResultados.FiltraParametros("EsSistema = True ")
|
||||
DdlConceptoGlobal.DataSource = ObjConta.DtResultados.FiltraParametros("EsCuentaUnica = false AND EsSistema = True AND EsGlobal = True")
|
||||
DdlConceptoGlobal.DataSource = ObjConta.DtResultados.FiltraParametros(" EsSistema = True AND EsGlobal = True")
|
||||
End If
|
||||
|
||||
If ObjConta.GetCuentas(-1, "-1", 1, UsuarioActual.CveEmpresa) Then
|
||||
@@ -145,6 +145,7 @@ Partial Class Contabilidad2_CatCuentasAsignaciones
|
||||
DdlCuentaBancaria.SelectedValueExist(GvRow.DataKey("CveBancoCuenta"))
|
||||
DdlSubProyectos.SelectedValueExist(GvRow.DataKey("CveSubProyecto").ToEntero)
|
||||
DdlTipoGasto.SelectedValueExist(GvRow.DataKey("CveTipoGasto").ToEntero)
|
||||
DdlActivoFijo.SelectedValueExist(GvRow.DataKey("CveActivoFijo").ToEntero)
|
||||
|
||||
Dim CveCliente As Integer = GvRow.DataKey("CveCliente").ToEntero
|
||||
Dim CvePersonal As Integer = GvRow.DataKey("CvePersonal").ToEntero
|
||||
|
||||
@@ -246,6 +246,10 @@ Partial Class RepCxCDetalle
|
||||
|
||||
'CargaClientes
|
||||
'CargaClientes
|
||||
'txtFechaI.Text = Now.AddMonths(-12).FirstDayOfMonth.ToShortDateString
|
||||
txtFechaF.Text = Now.LastDayOfMonth.ToShortDateString
|
||||
|
||||
|
||||
If UsuarioActual.Empresa.Funcionalidad(105) = "1" Then
|
||||
DdlClientesWS.setEsWebService(True)
|
||||
Else
|
||||
|
||||
@@ -17,6 +17,13 @@
|
||||
<li>
|
||||
<asp:HyperLink ID="HlAgregarExcel" NavigateUrl="#" Visible="true" data-toggle="modal" data-target="#DivCargaExcel" runat="server"><i class='fa fa-server'></i> Cargar Excel</asp:HyperLink>
|
||||
</li>
|
||||
|
||||
<asp:UpdatePanel ID="uppCargaBitacora" runat="server" UpdateMode="Conditional" RenderMode="Inline"><ContentTemplate>
|
||||
<li>
|
||||
<asp:Linkbutton ID="HplCargaBitacora" runat="server" Visible="false" OnClick="HplCargaBitacora_Click" Style="color: #686868;"><i class="fa fa-file-load-o" style="color: #686868;"></i> Cargar Bitácora</asp:Linkbutton>
|
||||
</li>
|
||||
</ContentTemplate></asp:UpdatePanel>
|
||||
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content4" ContentPlaceHolderID="E" runat="Server">
|
||||
Recepción Almacén
|
||||
|
||||
@@ -144,14 +144,7 @@ Partial Class Inventarios_RecepcionAlmacen
|
||||
ViewState("CantidadTotal") = value
|
||||
End Set
|
||||
End Property
|
||||
Private Property IndexSeccionAlmacen As Integer
|
||||
Get
|
||||
Return CType(ViewState("IndexSeccionAlmacen"), Integer)
|
||||
End Get
|
||||
Set(value As Integer)
|
||||
ViewState("IndexSeccionAlmacen") = value
|
||||
End Set
|
||||
End Property
|
||||
|
||||
Private Property PUSerie As Decimal
|
||||
Get
|
||||
Return CType(ViewState("PUSerie"), Decimal)
|
||||
@@ -416,15 +409,22 @@ Partial Class Inventarios_RecepcionAlmacen
|
||||
ViewState("ValidarRecepcionUsados") = Value
|
||||
End Set
|
||||
End Property
|
||||
|
||||
'Private Property DtDocumentos As DataTable
|
||||
' Get
|
||||
' Return CType(ViewState("DtDocumentos"), DataTable)
|
||||
' End Get
|
||||
' Set(value As DataTable)
|
||||
' ViewState("DtDocumentos") = value
|
||||
' End Set
|
||||
'End Property
|
||||
Private Property ArchivoBitacora As String
|
||||
Get
|
||||
Return CType(ViewState("ArchivoBitacora"), String)
|
||||
End Get
|
||||
Set(value As String)
|
||||
ViewState("ArchivoBitacora") = value
|
||||
End Set
|
||||
End Property
|
||||
Private Property ArchivoBitacoraDetalle As String
|
||||
Get
|
||||
Return CType(ViewState("ArchivoBitacoraDetalle"), String)
|
||||
End Get
|
||||
Set(value As String)
|
||||
ViewState("ArchivoBitacoraDetalle") = value
|
||||
End Set
|
||||
End Property
|
||||
|
||||
#End Region
|
||||
|
||||
@@ -480,7 +480,6 @@ Partial Class Inventarios_RecepcionAlmacen
|
||||
TipoMovimiento = 1
|
||||
RealizarTraspasoAlmacenDevolucion = False
|
||||
CantidadTotal = 0
|
||||
IndexSeccionAlmacen = 0
|
||||
|
||||
ddlAlmacenAdd.DataSource = GlobalDTAlmacen(UsuarioActual.CveEmpresa).FiltraParametros("CveTipoAlmacen NOT IN (9)")
|
||||
ddlAlmacenAdd.DataBind()
|
||||
@@ -549,15 +548,23 @@ Partial Class Inventarios_RecepcionAlmacen
|
||||
DdlAlmacen.Items.Insert(0, New ListItem(" Seleccione ", "-1"))
|
||||
DdlAlmacen.SelectedValue = "-1"
|
||||
DdlAlmacen.DataBind()
|
||||
DdlAlmacen.SelectedValueExist(UsuarioActual.CveAlmacen)
|
||||
If UsuarioActual.CveAlmacen > 0 Then
|
||||
DdlAlmacen.SelectedValueExist(UsuarioActual.CveAlmacen)
|
||||
RecargaporAlmacenes()
|
||||
End If
|
||||
|
||||
UpGenerales.Update()
|
||||
End Sub
|
||||
|
||||
Protected Sub DdlAlmacen_SelectedIndexChanged(sender As Object, e As EventArgs)
|
||||
Recargaporalmacenes()
|
||||
End Sub
|
||||
|
||||
Private Sub RecargaporAlmacenes()
|
||||
|
||||
If DdlAlmacen.SelectedValue <> "-1" Then
|
||||
|
||||
Dim CveSubProyecto As Integer = GlobalDTAlmacen(UsuarioActual.CveEmpresa, CveAlmacen:=DdlAlmacen.selectedvalue.toentero).FiltroPrimeroValor("CveSubProyecto").ToEntero
|
||||
Dim CveSubProyecto As Integer = GlobalDTAlmacen(UsuarioActual.CveEmpresa, CveAlmacen:=DdlAlmacen.SelectedValue.ToEntero).FiltroPrimeroValor("CveSubProyecto").ToEntero
|
||||
'RMF condición temporal
|
||||
If UsuarioActual.CveEmpresa = 119 AndAlso CveSubProyecto.ToString.Contiene(UsuarioActual.Empresa.Funcionalidad(347).Split(","c)) Then
|
||||
ValidaLoteCaducidad = True
|
||||
@@ -754,7 +761,7 @@ Partial Class Inventarios_RecepcionAlmacen
|
||||
|
||||
Dim ObjInventarios As New ClsInventarios
|
||||
If ddlProveedor.SelectedValue.ToEntero > 0 Then
|
||||
If ObjInventarios.GetFletes(UsuarioActual.CveEmpresa, CveProveedor:=ddlProveedor.SelectedValue.ToEntero) Then
|
||||
If ObjInventarios.GetFletes(UsuarioActual.CveEmpresa, CveProveedor:=ddlProveedor.SelectedValue.ToEntero, OpcionInventario:=1) Then
|
||||
DdlFletes.DataSource = ObjInventarios.DtResultados.FiltraParametros("CantRest > 0")
|
||||
Else
|
||||
Alert("Ocurrió un error al obtener las ordenes de compra pendientes de recibir del proveedor. Por favor vuelva a intentar", TipoMensaje.MsgError)
|
||||
@@ -997,6 +1004,16 @@ Partial Class Inventarios_RecepcionAlmacen
|
||||
Dim NumProductos = ObjInventario.DtResultados.COUNT("EsUsado", "EsUsado = False").ToEntero()
|
||||
Dim CveSubProyecto As Integer
|
||||
|
||||
ArchivoBitacora = String.Format("{0}Temp\RecepcionDT_{1}_{2}.xml", UsuarioActual.Empresa.Ruta, UsuarioActual.CveUsuario, pCveCompra)
|
||||
ArchivoBitacoraDetalle = String.Format("{0}Temp\RecepcionDTD_{1}_{2}.xml", UsuarioActual.Empresa.Ruta, UsuarioActual.CveUsuario, pCveCompra)
|
||||
If ArchivoBitacora <> "" Then
|
||||
Dim Archivo = New System.IO.FileInfo(ArchivoBitacora)
|
||||
If Archivo.Exists() Then
|
||||
HplCargaBitacora.Visible = True
|
||||
uppCargaBitacora.Update()
|
||||
End If
|
||||
End If
|
||||
|
||||
If UsuarioActual.Empresa.Funcionalidad(531) = "1" Then
|
||||
'SI LA COMPRA TIENE PRODUCTOS Y USADOS SOLO MOSTRAR LOS PRODUCTOS
|
||||
If NumProductos > 0 AndAlso NumUsados > 0 Then
|
||||
@@ -1100,7 +1117,6 @@ Partial Class Inventarios_RecepcionAlmacen
|
||||
CveCliente = DtRecepcion.Rows(0)("CveCliente").ToString.ToEntero
|
||||
CveVendedor = DtRecepcion.Rows(0)("CveVendedor").ToString.ToEntero
|
||||
|
||||
|
||||
If DtInv.COUNT("EntregaDirecta") <> DtInv.Rows.Count Then
|
||||
Alert("Todos los conceptos deben estar facturados.", TipoMensaje.MsgAdvertencia)
|
||||
BtnGuardar.Enabled = False
|
||||
@@ -1166,8 +1182,6 @@ Partial Class Inventarios_RecepcionAlmacen
|
||||
End If
|
||||
End If
|
||||
|
||||
|
||||
|
||||
DivBitacora.Visible = True
|
||||
|
||||
If UsuarioActual.Empresa.Funcionalidad(132) = "1" Then
|
||||
@@ -1181,7 +1195,6 @@ Partial Class Inventarios_RecepcionAlmacen
|
||||
BtnGuardar.Visible = False
|
||||
End If
|
||||
|
||||
|
||||
ObjCompras.Dispose()
|
||||
ObjInventario.Dispose()
|
||||
|
||||
@@ -1392,22 +1405,6 @@ Partial Class Inventarios_RecepcionAlmacen
|
||||
GvInv.Columns(14).Visible = True
|
||||
End If
|
||||
|
||||
'For Each item As DataRow In DtInv.Rows
|
||||
' Dim Dr As DataRow = GlobalDTPS(UsuarioActual.CveEmpresa, item("CvePS").ToString.ToEntero).FiltroPrimero("")
|
||||
' If Dr IsNot Nothing Then
|
||||
' item("AplicaSeccion") = CBool(Dr("AplicaSeccion"))
|
||||
' If CBool(Dr("AplicaSeccion")) Then GvInv.Columns(10).Visible = True
|
||||
' item("AplicaSerie") = CBool(Dr("AplicaSerie"))
|
||||
' item("AplicaLote") = CBool(Dr("AplicaLote"))
|
||||
' If CBool(Dr("AplicaLote")) Then GvInv.Columns(11).Visible = True
|
||||
' item("AplicaCaducidad") = CBool(Dr("AplicaCaducidad"))
|
||||
' If CBool(Dr("AplicaCaducidad")) Then GvInv.Columns(12).Visible = True
|
||||
' If CBool(Dr("AplicaSeccion")) Or CBool(Dr("AplicaLote")) Or CBool(Dr("AplicaCaducidad")) Or CBool(Dr("AplicaSerie")) Then
|
||||
' GvInv.Columns(15).Visible = True
|
||||
' End If
|
||||
' End If
|
||||
'Next
|
||||
|
||||
GvInv.DataSource = DtInv
|
||||
GvInv.DataBind()
|
||||
UPInv.Update()
|
||||
@@ -1501,7 +1498,6 @@ Partial Class Inventarios_RecepcionAlmacen
|
||||
|
||||
End If
|
||||
|
||||
|
||||
e.Row.FCButton("BtnDividir").Attributes.Add("onclick", String.Format("Dividir('{0}');", e.Row.FCTextBox("TxtDividir").ClientID))
|
||||
e.Row.FCButton("BtnDividir").CommandArgument = e.Row.RowIndex.ToString
|
||||
e.Row.FCTextBox("TxtDividir").Attributes.Add("onkeyup", String.Format("LimitaCantidad({0},this,'{1}');", e.Row.DBCampo("CantidadF"), e.Row.FCButton("BtnDividir").ClientID))
|
||||
@@ -1694,20 +1690,6 @@ Partial Class Inventarios_RecepcionAlmacen
|
||||
'RegistraScript("document.getElementById(""TxtSerie"").focus();")
|
||||
RegistraScript("$('#DivSerie').modal();", "ModalLote")
|
||||
|
||||
'Dim AplicaCaducidad = False
|
||||
'If GlobalDTPS(UsuarioActual.CveEmpresa, CvePS:=CvePSSerie).FiltraParametros("").Rows(0) IsNot Nothing Then
|
||||
' AplicaCaducidad = If(GlobalDTPS(UsuarioActual.CveEmpresa, CvePS:=CvePSSerie).FiltraParametros("").Rows(0)("AplicaCaducidad").ToString = "True", True, False)
|
||||
'End If
|
||||
|
||||
'If AplicaCaducidad Then
|
||||
' GvSerie.Columns(1).Visible = True
|
||||
' TdCaducidad1.Visible = True
|
||||
' TdCaducidad2.Visible = True
|
||||
'Else
|
||||
' GvSerie.Columns(1).Visible = False
|
||||
' TdCaducidad1.Visible = False
|
||||
' TdCaducidad2.Visible = False
|
||||
'End If
|
||||
|
||||
GvSerie.DataSource = DtDatosDetalle.FiltraParametros(String.Format("ConsecId = {0}", CveConsecSerie), "Consec DESC")
|
||||
GvSerie.DataBind()
|
||||
@@ -1859,6 +1841,7 @@ Partial Class Inventarios_RecepcionAlmacen
|
||||
Row("FechaCaducidad") = MinFecha.ToShortDateString
|
||||
|
||||
DtDatosDetalle.Rows.Add(Row)
|
||||
ActualizaBitacora()
|
||||
End If
|
||||
Next
|
||||
ObjInventarios.Dispose()
|
||||
@@ -1881,6 +1864,40 @@ Partial Class Inventarios_RecepcionAlmacen
|
||||
|
||||
End Sub
|
||||
|
||||
#Region "Bitacora"
|
||||
Private Sub ActualizaBitacora(Optional Eliminar As Boolean = False)
|
||||
If Not Eliminar Then
|
||||
DtInv.TableName = "DtDatos"
|
||||
DtDatosDetalle.TableName = "DtDatosDetalle"
|
||||
DtInv.WriteXml(ArchivoBitacora, XmlWriteMode.WriteSchema)
|
||||
DtDatosDetalle.WriteXml(ArchivoBitacoraDetalle, XmlWriteMode.WriteSchema)
|
||||
Else
|
||||
File.Delete(ArchivoBitacora)
|
||||
End If
|
||||
|
||||
End Sub
|
||||
|
||||
Protected Sub HplCargaBitacora_Click(sender As Object, e As EventArgs)
|
||||
|
||||
If IO.File.Exists(ArchivoBitacora) Then
|
||||
'DtInv.Clear()
|
||||
'DtDatosDetalle.Clear()
|
||||
DtInv.ReadXml(ArchivoBitacora)
|
||||
If IO.File.Exists(ArchivoBitacoraDetalle) Then
|
||||
Dim dtt As New DataTable
|
||||
dtt.ReadXml(ArchivoBitacoraDetalle)
|
||||
DtDatosDetalle = dtt
|
||||
Alert("Registro(s) Recuperados", TipoMensaje.ToastInformacion)
|
||||
End If
|
||||
CargaGVInv()
|
||||
|
||||
Else
|
||||
Alert("No hay bitácora para recuperar.", TipoMensaje.ToastInformacion)
|
||||
End If
|
||||
|
||||
End Sub
|
||||
#End Region
|
||||
|
||||
Protected Sub GvSerie_RowDeleting(ByVal sender As Object, ByVal e As System.Web.UI.WebControls.GridViewDeleteEventArgs) Handles GvSerie.RowDeleting
|
||||
Dim keySerieLote As String = e.Keys("Serie").ToString
|
||||
Try
|
||||
@@ -1894,6 +1911,7 @@ Partial Class Inventarios_RecepcionAlmacen
|
||||
End Try
|
||||
|
||||
DtDatosDetalle.AcceptChanges()
|
||||
ActualizaBitacora()
|
||||
CargaSerie(1)
|
||||
End Sub
|
||||
|
||||
@@ -4971,68 +4989,6 @@ Partial Class Inventarios_RecepcionAlmacen
|
||||
|
||||
#End Region
|
||||
|
||||
'Protected Sub BtnGuardarDocumento_Click(sender As Object, e As EventArgs)
|
||||
|
||||
' Dim Filesgral As List(Of Archivo) = TxtDocumento.getfiles().Archivos
|
||||
' If Filesgral Is Nothing OrElse Filesgral.Count = 0 Then
|
||||
' Alert("No se agregó ningun archivo", TipoMensaje.MsgAdvertencia)
|
||||
' Exit Sub
|
||||
' End If
|
||||
|
||||
' If DtDocumentos Is Nothing Then
|
||||
' DtDocumentos = New DataTable()
|
||||
|
||||
' Dim column As DataColumn = New DataColumn("No")
|
||||
' column.DataType = Type.GetType("System.Int32")
|
||||
' With column
|
||||
' .AutoIncrement = True
|
||||
' .AutoIncrementSeed = 1
|
||||
' .AutoIncrementStep = 1
|
||||
' End With
|
||||
|
||||
' DtDocumentos.Columns.Add(column)
|
||||
' DtDocumentos.Columns.Add("DocumentoOrignal", GetType(String))
|
||||
' DtDocumentos.Columns.Add("Documento", GetType(String))
|
||||
' DtDocumentos.Columns.Add("FileExtension", GetType(String))
|
||||
' End If
|
||||
|
||||
' Dim row As DataRow = DtDocumentos.NewRow()
|
||||
|
||||
' Dim archivo = Filesgral.FirstOrDefault()
|
||||
|
||||
' row("DocumentoOrignal") = archivo.filenameO
|
||||
' row("Documento") = archivo.filename
|
||||
' row("FileExtension") = IO.Path.GetExtension(String.Format("{0}Temp\{1}", AppDomain.CurrentDomain.BaseDirectory, archivo.filename))
|
||||
|
||||
' DtDocumentos.Rows.Add(row)
|
||||
|
||||
' 'GvDocumentos.DataSource = DtDocumentos
|
||||
' 'GvDocumentos.DataBind()
|
||||
|
||||
' UpDocumentos.Update()
|
||||
|
||||
' RegistraScript("$('#ModalBitacoraDoc').modal('hide');")
|
||||
'End Sub
|
||||
'Protected Sub LnkEliminarDoc_Click(sender As Object, e As EventArgs)
|
||||
' Dim lnkRemove As LinkButton = DirectCast(sender, LinkButton)
|
||||
|
||||
' If DtDocumentos.Rows.Count > 0 And lnkRemove.CommandArgument.ToString.Length > 0 Then
|
||||
' Dim i As Integer
|
||||
' i = lnkRemove.CommandArgument.ToString.ToEntero
|
||||
' Dim Drs As DataRow() = DtDocumentos.Select(String.Format("No = {0}", i))
|
||||
' If Drs.Count > 0 Then
|
||||
|
||||
' Drs(0).Delete()
|
||||
' End If
|
||||
' DtDocumentos.AcceptChanges()
|
||||
' End If
|
||||
|
||||
' 'GvDocumentos.EditIndex = -1
|
||||
|
||||
' 'GvDocumentos.DataSource = DtDocumentos
|
||||
' 'GvDocumentos.DataBind()
|
||||
'End Sub
|
||||
|
||||
Private Function GuardaDocumentoBitacora(ObjEventoBitacora As ClsOIEventos, CveMovimiento As Integer) As Boolean
|
||||
Dim Retorno = True
|
||||
Dim Archivo As System.IO.FileInfo = Nothing
|
||||
|
||||
@@ -33,10 +33,18 @@
|
||||
</div>
|
||||
<div class="titlefiltros caption ">
|
||||
<ul class="list-inline" style="font-size: 12px;">
|
||||
<li>SubProyecto:</li>
|
||||
<%--SubProyecto--%>
|
||||
<li>
|
||||
<div >
|
||||
<asp:DropDownList runat="server" ID="DdlSubProyectos" CssClass="form-control input-sm select2me" DataValueField="CveSubProyecto" DataTextField="SubProyecto" Class="table-group-action-input form-control input-inline input-small input-sm">
|
||||
</asp:DropDownList>
|
||||
</div>
|
||||
</li>
|
||||
<li>Almacén:</li>
|
||||
<li>
|
||||
<div>
|
||||
<asp:DropDownList ID="DdlAlmacen" runat="server" DataTextField="Almacen" DataValueField="CveAlmacen" CssClass="form-control input-sm" Style="width: 150px !important;" ValidationGroup="GrpConsultar"></asp:DropDownList>
|
||||
<asp:DropDownList ID="DdlAlmacen" runat="server" DataTextField="Almacen" DataValueField="CveAlmacen" CssClass="form-control input-sm select2me" Style="width: 150px !important;" ValidationGroup="GrpConsultar"></asp:DropDownList>
|
||||
</div>
|
||||
</li>
|
||||
<li>FechaInicio:</li>
|
||||
@@ -93,7 +101,7 @@
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<asp:GridView ID="GvDatos" runat="server" data-sort="true" AutoGenerateColumns="False" EmptyDataText="No hay movimientos." ToolTip="Listado de Movimientos" CssClass="table table-striped table-advance table-hover Widthall" Style="text-align: center;" GridLines="None">
|
||||
<asp:GridView ID="GvDatos" runat="server" data-sort="true" AutoGenerateColumns="False" EmptyDataText="No hay movimientos." ToolTip="Listado de Movimientos" CssClass="table table-striped table-advance table-hover Widthall" GridLines="None">
|
||||
<Columns>
|
||||
<asp:HyperLinkField HeaderText="Folio Almacen" DataTextField="FolioAlmacen" DataNavigateUrlFields="CveMovimiento" DataNavigateUrlFormatString="/Inventarios/EntradasSalidas.aspx?CveMovimiento={0}" ItemStyle-Width="7.5%" ItemStyle-HorizontalAlign="Left"/>
|
||||
<asp:BoundField HeaderText="Almacen" DataField="Almacen" ItemStyle-Width="20%" />
|
||||
|
||||
@@ -70,10 +70,12 @@ Partial Class Inventarios_RepAlmacenCompras
|
||||
Private Sub CargaCombos()
|
||||
|
||||
'Llena Almacen
|
||||
DdlAlmacen.DataSource = GlobalDTAlmacenUsuarios(UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa)
|
||||
DdlAlmacen.DataSource = GlobalDTAlmacenUsuarios(UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, CveTipoAlmacen:=-1).FiltraParametros("CveTipoAlmacen IN ( 1, 22, 27)")
|
||||
DdlAlmacen.DataBind()
|
||||
DdlAlmacen.Items.Insert(0, New ListItem("Todos", "-1"))
|
||||
|
||||
CargarCentrosDeCosto(Nothing, DdlSubProyectos, Nothing, Nothing)
|
||||
|
||||
End Sub
|
||||
#End Region
|
||||
|
||||
@@ -90,7 +92,7 @@ Partial Class Inventarios_RepAlmacenCompras
|
||||
Dim FechaF As Date = If(TxtFechaFin.Text = "" Or TxtFechaFin.Text = "__/__/____", MaxFecha, TxtFechaFin.Text.ToDate)
|
||||
|
||||
|
||||
If ObjInventarios.RepAlmacenCompras(DdlAlmacen.SelectedValue.ToEntero, FechaI, FechaF, UsuarioActual.CveEmpresa) Then
|
||||
If ObjInventarios.RepAlmacenCompras(DdlAlmacen.SelectedValue.ToEntero, FechaI, FechaF, DdlSubProyectos.SelectedValue.ToEntero, UsuarioActual.CveEmpresa) Then
|
||||
DtDatos = ObjInventarios.DtResultados
|
||||
DtAlmacenCompra = ObjInventarios.DtResultados
|
||||
Else
|
||||
|
||||
@@ -56,7 +56,7 @@
|
||||
<div class="col-md-12">
|
||||
|
||||
<asp:GridView ID="GvDatos" runat="server" AutoGenerateColumns="false" EmptyDataText="No se encontraron solicitudes de cancelación"
|
||||
DataKeyNames="CveVenta,CveCliente,Folio,TipoDocto,Nombre,FolioFiscal,Total,SubTotal,RFCCliente"
|
||||
DataKeyNames="CveVenta,CveCliente,Folio,TipoDocto,Nombre,FolioFiscal,Total,SubTotal,RFCReceptor"
|
||||
CssClass="table table-striped table-advance table-hover Widthall ScrollAD mysmallbtn" data-sort="true" GridLines="None" Width="99%">
|
||||
<Columns>
|
||||
<asp:BoundField HeaderText="Cliente" DataField="Nombre" ItemStyle-Width="25%" />
|
||||
@@ -103,7 +103,7 @@
|
||||
<div class="col-md-12">
|
||||
|
||||
<asp:GridView ID="GvRefacturaciones" runat="server" AutoGenerateColumns="false" EmptyDataText="No se encontraron solicitudes de cancelación"
|
||||
DataKeyNames="CveVenta,CveCliente,Folio,TipoDocto,Nombre,FolioFiscal,Total,SubTotal,RFCCliente,FolioFiscalSustitucion,CveEstatusFactura"
|
||||
DataKeyNames="CveVenta,CveCliente,Folio,TipoDocto,Nombre,FolioFiscal,Total,SubTotal,FolioFiscalSustitucion,CveEstatusFactura,RFCReceptor"
|
||||
CssClass="table table-striped table-advance table-hover Widthall ScrollAD mysmallbtn" data-sort="true" GridLines="None" Width="99%" OnRowDataBound="GvDatos_RowDataBound">
|
||||
<Columns>
|
||||
<asp:BoundField HeaderText="Cliente" DataField="Nombre" ItemStyle-Width="25%" />
|
||||
|
||||
@@ -93,13 +93,13 @@ public partial class Ventas_RepCancelacionesPorRespuesta : ClsPaginas
|
||||
string Total = GvRow.DataKey("Total");
|
||||
string SubTotal = GvRow.DataKey("SubTotal");
|
||||
string Uuid = GvRow.DataKey("FolioFiscal");
|
||||
string RFCCliente = GvRow.DataKey("RFCCliente");
|
||||
string RFCReceptor = GvRow.DataKey("RFCReceptor");
|
||||
string Folio = GvRow.DataKey("Folio");
|
||||
string TipoDocto = GvRow.DataKey("TipoDocto");
|
||||
string Nombre = GvRow.DataKey("Nombre");
|
||||
if (CveVenta > 0 && Uuid != "")
|
||||
{
|
||||
var resp = VerificarVigenciaSAT(CveVenta, CveCliente, Folio, TipoDocto, Uuid, UsuarioActual.Empresa.RFC, RFCCliente, Total);
|
||||
var resp = VerificarVigenciaSAT(CveVenta, CveCliente, Folio, TipoDocto, Uuid, UsuarioActual.Empresa.RFC, RFCReceptor, Total);
|
||||
if (resp.EnviarAcuse)
|
||||
{
|
||||
Alert(resp.Mensaje, TipoMensaje.MsgConfirmacion, "BtnEnviarMailCancelacion();", TextoConfirmacion: "Enviar", TextoSegundoBoton: "Cancelar");
|
||||
@@ -124,7 +124,7 @@ public partial class Ventas_RepCancelacionesPorRespuesta : ClsPaginas
|
||||
string Total = GvRow.DataKey("Total");
|
||||
string SubTotal = GvRow.DataKey("SubTotal");
|
||||
string Uuid = GvRow.DataKey("FolioFiscal");
|
||||
string RFCCliente = GvRow.DataKey("RFCCliente");
|
||||
string RFCReceptor = GvRow.DataKey("RFCReceptor");
|
||||
string Folio = GvRow.DataKey("Folio");
|
||||
string TipoDocto = GvRow.DataKey("TipoDocto");
|
||||
string Nombre = GvRow.DataKey("Nombre");
|
||||
@@ -133,7 +133,7 @@ public partial class Ventas_RepCancelacionesPorRespuesta : ClsPaginas
|
||||
|
||||
if (CveVenta > 0 && Uuid != "")
|
||||
{
|
||||
var respuesta = VerificarVigenciaSAT(CveVenta, CveCliente, Folio, TipoDocto, Uuid, UsuarioActual.Empresa.RFC, RFCCliente, Total, EsRefacturacion: true, FolioSustitucion: FolioSustitucion, CveEstatusFactura: CveEstatusFactura);
|
||||
var respuesta = VerificarVigenciaSAT(CveVenta, CveCliente, Folio, TipoDocto, Uuid, UsuarioActual.Empresa.RFC, RFCReceptor, Total, EsRefacturacion: true, FolioSustitucion: FolioSustitucion, CveEstatusFactura: CveEstatusFactura);
|
||||
CargaDatos();
|
||||
if (respuesta.CveEstatus.Contiene(4, 5))
|
||||
{
|
||||
@@ -171,7 +171,7 @@ public partial class Ventas_RepCancelacionesPorRespuesta : ClsPaginas
|
||||
string Total = GvRow.DataKey("Total");
|
||||
string SubTotal = GvRow.DataKey("SubTotal");
|
||||
string Uuid = GvRow.DataKey("FolioFiscal");
|
||||
string RFCCliente = GvRow.DataKey("RFCCliente");
|
||||
string RFCReceptor = GvRow.DataKey("RFCReceptor");
|
||||
string Folio = GvRow.DataKey("Folio");
|
||||
string TipoDocto = GvRow.DataKey("TipoDocto");
|
||||
string Nombre = GvRow.DataKey("Nombre");
|
||||
@@ -219,10 +219,32 @@ public partial class Ventas_RepCancelacionesPorRespuesta : ClsPaginas
|
||||
sb.Append("Ocurrió un error al cambiar el estatus de la factura.");
|
||||
}
|
||||
ObjVentas.Dispose();
|
||||
|
||||
|
||||
if (respCancelacion.CveEstatus == 23)
|
||||
{
|
||||
var resp = Timbrado.VerificarVigenciaSAT(Uuid, UsuarioActual.Empresa.RFC, RFCReceptor, Total, true);
|
||||
if (resp != null)
|
||||
{
|
||||
sb.AppendFormat("<br/> Folio Fiscal: {0} <br/>", Uuid);
|
||||
sb.AppendFormat("Código Estado: {0} <br/>", resp.CodigoEstatus);
|
||||
sb.AppendFormat("Estado: {0} <br/>", resp.Estado);
|
||||
sb.AppendFormat("Es Cancelable: {0} <br/>", string.IsNullOrEmpty(resp.EsCancelable) ? "Desconocido" : resp.EsCancelable);
|
||||
sb.AppendFormat("Estatus de Cancelación: {0} <br/><br/>", string.IsNullOrEmpty(resp.EsCancelable) ? "Desconocido" : resp.EstatusCancelacion);
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
var resp = Timbrado.VerificarVigenciaSAT(Uuid, UsuarioActual.Empresa.RFC, RFCReceptor, Total, true);
|
||||
if (resp != null)
|
||||
{
|
||||
sb.AppendFormat("Folio Fiscal: {0} <br/>", Uuid);
|
||||
sb.AppendFormat("Código Estado: {0} <br/>", resp.CodigoEstatus);
|
||||
sb.AppendFormat("Estado: {0} <br/>", resp.Estado);
|
||||
sb.AppendFormat("Es Cancelable: {0} <br/>", string.IsNullOrEmpty(resp.EsCancelable) ? "Desconocido" : resp.EsCancelable);
|
||||
sb.AppendFormat("Estatus de Cancelación: {0} <br/><br/>", string.IsNullOrEmpty(resp.EsCancelable) ? "Desconocido" : resp.EstatusCancelacion);
|
||||
}
|
||||
|
||||
sb.Append(respCancelacion.Mensaje);
|
||||
}
|
||||
|
||||
@@ -346,7 +368,13 @@ public partial class Ventas_RepCancelacionesPorRespuesta : ClsPaginas
|
||||
}
|
||||
else if (respCancelacion.CveEstatus == 23)
|
||||
{
|
||||
sb.Append("La solicitud de cancelación no la aplicó el SAT, intente cancelar de nuevo.");
|
||||
sb.Append("La solicitud de cancelación no la aplicó el SAT, intente cancelar de nuevo.<br/>");
|
||||
|
||||
sb.AppendFormat("Folio Fiscal: {0} <br/>", uuid);
|
||||
sb.AppendFormat("Código Estado: {0} <br/>", resp.CodigoEstatus);
|
||||
sb.AppendFormat("Estado: {0} <br/>", resp.Estado);
|
||||
sb.AppendFormat("Es Cancelable: {0} <br/>", string.IsNullOrEmpty(resp.EsCancelable) ? "Desconocido" : resp.EsCancelable);
|
||||
sb.AppendFormat("Estatus de Cancelación: {0} <br/><br/>", string.IsNullOrEmpty(resp.EsCancelable) ? "Desconocido" : resp.EstatusCancelacion);
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -496,14 +524,14 @@ public partial class Ventas_RepCancelacionesPorRespuesta : ClsPaginas
|
||||
string Total = Row["Total"].ToString();
|
||||
string SubTotal = Row["SubTotal"].ToString();
|
||||
string Uuid = Row["FolioFiscal"].ToString();
|
||||
string RFCCliente = Row["RFCCliente"].ToString();
|
||||
string RFCReceptor = Row["RFCReceptor"].ToString();
|
||||
string Folio = Row["Folio"].ToString();
|
||||
string TipoDocto = Row["TipoDocto"].ToString();
|
||||
string Nombre = Row["Nombre"].ToString();
|
||||
int CveCliente = Row["CveCliente"].ToEntero();
|
||||
if (CveVenta > 0)
|
||||
{
|
||||
sb.AppendFormat("{0}<br/>", VerificarVigenciaSAT(CveVenta, CveCliente, Folio, TipoDocto, Uuid, UsuarioActual.Empresa.RFC, RFCCliente, SubTotal));
|
||||
sb.AppendFormat("{0}<br/>", VerificarVigenciaSAT(CveVenta, CveCliente, Folio, TipoDocto, Uuid, UsuarioActual.Empresa.RFC, RFCReceptor, SubTotal));
|
||||
}
|
||||
}
|
||||
Alert(sb.ToString());
|
||||
|
||||
@@ -190,6 +190,11 @@
|
||||
<ajax:ValidatorCalloutExtender ID="ValidatorCalloutExtender2" runat="server" HighlightCssClass="vco" TargetControlID="CVOFechaVencimiento" Width="350px"></ajax:ValidatorCalloutExtender>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-md-2" runat="server" id="divVerInv">
|
||||
<asp:CheckBox ID="chkInv" Checked="false" runat="server" Text="Ver Inventario"></asp:CheckBox>
|
||||
<%--<asp:DropDownList CssClass="table-group-action-input form-control input-inline input-small input-sm select2me" ID="DdlSubProyectos" DataTextField="SubProyecto" DataValueField="CveSubProyecto" runat="server"></asp:DropDownList>--%>
|
||||
</div>
|
||||
|
||||
<label class="col-md-1">Contrato: </label>
|
||||
<div class="col-md-2">
|
||||
|
||||
@@ -91,7 +91,7 @@ Partial Class RepRemisiones
|
||||
Dim Vendedores As String = IIf(DdlVendedor.GetSelectedValuesM = "", "-1", DdlVendedor.GetSelectedValuesM).ToString
|
||||
|
||||
Dim ObjVentas As New ClsVentas
|
||||
If ObjVentas.GetRepRemisionesSinFacturar(FechaI, FechaF, FechaV, Sucursales, CveCliente, CveContrato, Vendedores, UsuarioActual.CveEmpresa, CveUsuarioConsulta:=UsuarioActual.CveUsuario, ConsultaInventario:=UsuarioActual.TienePermisoProceso(201)) Then
|
||||
If ObjVentas.GetRepRemisionesSinFacturar(FechaI, FechaF, FechaV, Sucursales, CveCliente, CveContrato, Vendedores, UsuarioActual.CveEmpresa, CveUsuarioConsulta:=UsuarioActual.CveUsuario, ConsultaInventario:=chkInv.Checked) Then
|
||||
DtVentas = ObjVentas.DtResultados.Copy()
|
||||
GvDatos.DataSource = DtVentas
|
||||
End If
|
||||
@@ -100,7 +100,7 @@ Partial Class RepRemisiones
|
||||
GvDatos.Columns(7).Visible = DtVentas.SUMD("Descuento") > 0
|
||||
End If
|
||||
|
||||
GvDatos.Columns(10).Visible = UsuarioActual.TienePermisoProceso(201)
|
||||
GvDatos.Columns(10).Visible = chkInv.Checked 'solo se visualiza si está selccionada
|
||||
ObjVentas.Dispose()
|
||||
|
||||
GvDatos.DataBind()
|
||||
@@ -148,6 +148,11 @@ Partial Class RepRemisiones
|
||||
'DdlClientes.ddl.Items.Insert(0, New ListItem("Todos", "-1"))
|
||||
'End If
|
||||
|
||||
If UsuarioActual.TienePermisoProceso(201) Then
|
||||
divVerInv.Visible = True
|
||||
End If
|
||||
|
||||
|
||||
End Sub
|
||||
Private Sub CargaSucursales()
|
||||
|
||||
|
||||
@@ -130,11 +130,11 @@
|
||||
<ADS:Dropdownlost CssClassDdl="select2me" ID="DdlClientes" Width="100%" data-metodo="getcliente" runat="server" DataTextField="NombreComercial" DataValueField="CveCliente" CssStyle="width: 100%;" selectedindexchange="DdlClientes_SelectedIndexChanged"></ADS:Dropdownlost>
|
||||
</div>
|
||||
|
||||
<label class="col-md-1">Contrato: </label>
|
||||
<%-- <label class="col-md-1">Contrato: </label>
|
||||
<div class="col-md-2">
|
||||
<asp:DropDownList CssClass="table-group-action-input form-control input-inline input-small input-sm select2me" ID="DdlContrato" DataTextField="ContratoCompleto" DataValueField="CveContrato" runat="server">
|
||||
</asp:DropDownList>
|
||||
</div>
|
||||
</div>--%>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
@@ -187,6 +187,10 @@
|
||||
<ajax:ValidatorCalloutExtender ID="ValidatorCalloutExtender2" runat="server" HighlightCssClass="vco" TargetControlID="CVOFechaVencimiento" Width="350px"></ajax:ValidatorCalloutExtender>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-2" runat="server" id="divVerInv">
|
||||
<asp:CheckBox ID="chkInv" Checked="false" runat="server" Text="Ver Inventario"></asp:CheckBox>
|
||||
<%--<asp:DropDownList CssClass="table-group-action-input form-control input-inline input-small input-sm select2me" ID="DdlSubProyectos" DataTextField="SubProyecto" DataValueField="CveSubProyecto" runat="server"></asp:DropDownList>--%>
|
||||
</div>
|
||||
|
||||
<%-- <label class="col-md-1 ">Vendedor:</label>
|
||||
<div class="col-md-2">
|
||||
|
||||
@@ -114,7 +114,7 @@ Partial Class RepRemisionesDetalle
|
||||
If Request("CveCliente") IsNot Nothing AndAlso IsNumeric(Request("CveCliente")) AndAlso Request("CveCliente").ToEntero > 0 Then
|
||||
CveCliente = Request("CveCliente").ToEntero
|
||||
|
||||
Dim Cliente = GlobalDTCliente(UsuarioActual.CveEmpresa, -1).FiltroPrimeroValor("NombreComercial", $"CveCliente ={CveCliente}")
|
||||
Dim Cliente = GlobalDTCliente(UsuarioActual.CveEmpresa, CveCliente:=CveCliente).FiltroPrimeroValor("NombreComercial", "")
|
||||
If Cliente <> "" Then
|
||||
DdlClientes.SelectedValue = CveCliente.ToString
|
||||
DdlClientes.SelectedText = Cliente
|
||||
@@ -122,14 +122,14 @@ Partial Class RepRemisionesDetalle
|
||||
|
||||
Else
|
||||
CveCliente = -1
|
||||
End If
|
||||
|
||||
If Request("CveContrato") IsNot Nothing AndAlso IsNumeric(Request("CveContrato")) AndAlso Request("CveContrato").ToEntero > 0 Then
|
||||
CveContrato = Request("CveContrato").ToEntero
|
||||
DdlContrato.SelectedValueExist(CveContrato)
|
||||
Else
|
||||
CveContrato = -1
|
||||
End If
|
||||
End If
|
||||
|
||||
'If Request("CveContrato") IsNot Nothing AndAlso IsNumeric(Request("CveContrato")) AndAlso Request("CveContrato").ToEntero > 0 Then
|
||||
' CveContrato = Request("CveContrato").ToEntero
|
||||
' DdlContrato.SelectedValueExist(CveContrato)
|
||||
'Else
|
||||
CveContrato = -1
|
||||
'End If
|
||||
If Request("CveSubProyecto") IsNot Nothing Then
|
||||
CveSubProyecto = Request("CveSubProyecto").ToString
|
||||
DdlSubProyectos.SelectedValuesIfExistM(CveSubProyecto)
|
||||
@@ -155,10 +155,10 @@ Partial Class RepRemisionesDetalle
|
||||
FechaF = If(IsDate(txtFechaF.Text.Trim()), txtFechaF.Text.Trim(), "-1")
|
||||
FechaV = If(IsDate(TxtFechaVencimiento.Text.Trim()), TxtFechaVencimiento.Text.Trim(), "-1")
|
||||
CveCliente = If(DdlClientes.SelectedValue.ToEntero > 0, DdlClientes.SelectedValue.ToEntero, -1)
|
||||
CveContrato = If(DdlContrato.SelectedValue.ToEntero > 0, DdlContrato.SelectedValue.ToEntero, -1)
|
||||
'CveContrato = If(DdlContrato.SelectedValue.ToEntero > 0, DdlContrato.SelectedValue.ToEntero, -1)
|
||||
CveSubProyecto = IIf(DdlSubProyectos.GetSelectedValuesM = "", "-1", DdlSubProyectos.GetSelectedValuesM).ToString
|
||||
|
||||
If ObjVentas.GetRepRemisionesSinFacturarDetalle(FechaI, FechaF, FechaV, CveCliente, CveContrato, CveVenta, UsuarioActual.CveEmpresa, CveSubProyecto, CveUsuarioConsulta:=UsuarioActual.CveUsuario, ConsultaInventario:=UsuarioActual.TienePermisoProceso(201)) Then
|
||||
If ObjVentas.GetRepRemisionesSinFacturarDetalle(FechaI, FechaF, FechaV, CveCliente, CveContrato, CveVenta, UsuarioActual.CveEmpresa, CveSubProyecto, CveUsuarioConsulta:=UsuarioActual.CveUsuario, ConsultaInventario:=chkInv.Checked) Then
|
||||
If CveMoneda = 1 Or CveMoneda = 2 Then
|
||||
DtVentas = ObjVentas.DtResultados.FiltraParametros($"CveMoneda = {CveMoneda}")
|
||||
Else
|
||||
@@ -169,13 +169,13 @@ Partial Class RepRemisionesDetalle
|
||||
ObjVentas.Dispose()
|
||||
|
||||
GvDatos.DataBind()
|
||||
GvDatos.Columns(8).Visible = UsuarioActual.TienePermisoProceso(201)
|
||||
GvDatos.Columns(8).Visible = chkInv.Checked
|
||||
|
||||
UPDatos.Update()
|
||||
End Sub
|
||||
Public Sub CargaCombos()
|
||||
CargaCliente()
|
||||
CargaContrato()
|
||||
'CargaContrato()
|
||||
CargaSucursales()
|
||||
End Sub
|
||||
Private Sub CargaCliente()
|
||||
@@ -191,20 +191,20 @@ Partial Class RepRemisionesDetalle
|
||||
End If
|
||||
|
||||
End Sub
|
||||
Private Sub CargaContrato()
|
||||
Dim ObjContratos As New ClsContratos
|
||||
DdlContrato.Items.Clear()
|
||||
If ObjContratos.GetContratos(-1, UsuarioActual.CveEmpresa, DdlClientes.SelectedValue.ToEntero, -1, -1) Then
|
||||
If ObjContratos.DtResultados.Rows.Count > 0 Then
|
||||
DdlContrato.DataSource = ObjContratos.DtResultados
|
||||
DdlContrato.DataBind()
|
||||
End If
|
||||
'Private Sub CargaContrato()
|
||||
' Dim ObjContratos As New ClsContratos
|
||||
' DdlContrato.Items.Clear()
|
||||
' If ObjContratos.GetContratos(-1, UsuarioActual.CveEmpresa, DdlClientes.SelectedValue.ToEntero, -1, -1) Then
|
||||
' If ObjContratos.DtResultados.Rows.Count > 0 Then
|
||||
' DdlContrato.DataSource = ObjContratos.DtResultados
|
||||
' DdlContrato.DataBind()
|
||||
' End If
|
||||
|
||||
End If
|
||||
' End If
|
||||
|
||||
ObjContratos.Dispose()
|
||||
DdlContrato.Items.Insert(0, New ListItem("Todos", "-1"))
|
||||
End Sub
|
||||
' ObjContratos.Dispose()
|
||||
' DdlContrato.Items.Insert(0, New ListItem("Todos", "-1"))
|
||||
'End Sub
|
||||
Private Sub CargaSucursales()
|
||||
DdlSubProyectos.DataSource() = GlobalDTSubProyectosUsuarios(UsuarioActual.CveUsuario, -1, UsuarioActual.CveEmpresa, -1, 1)
|
||||
DdlSubProyectos.DataBind()
|
||||
@@ -233,7 +233,7 @@ Partial Class RepRemisionesDetalle
|
||||
|
||||
If DdlSubProyectos.GetSelectedText <> "" Then StrFiltro.AppendFormat(" <b>Sucursal</b>: {0}", DdlSubProyectos.GetSelectedText)
|
||||
If DdlClientes.SelectedValue.ToEntero > 0 Then StrFiltro.AppendFormat(" <b>Cliente</b>: {0}", DdlClientes.SelectedText)
|
||||
If DdlContrato.SelectedValue <> "-1" Then StrFiltro.AppendFormat(" <b>Contrato</b>: {0}", DdlContrato.SelectedItem.Text)
|
||||
'If DdlContrato.SelectedValue <> "-1" Then StrFiltro.AppendFormat(" <b>Contrato</b>: {0}", DdlContrato.SelectedItem.Text)
|
||||
|
||||
If txtFechaI.Text <> "" Then StrFiltro.AppendFormat(" <b>Fecha Inicio </b>: {0}", txtFechaI.Text.ToDate.ToShortDateString)
|
||||
If txtFechaF.Text <> "" Then StrFiltro.AppendFormat(" <b>Fecha Fin </b>: {0}", txtFechaF.Text.ToDate.ToShortDateString)
|
||||
|
||||
Reference in New Issue
Block a user