From d97c97aae222f7a8089c8f211f7e2a592c52f34d Mon Sep 17 00:00:00 2001 From: Jonathan Alexis Perez Morales Date: Thu, 26 Dec 2024 18:57:26 -0700 Subject: [PATCH] --Ocultar ImgAnticipos -- Atencion A siempre en mayusculas --- Ventas/Ventas.aspx.vb | 31 +++++++++++++++++++++++++++---- 1 file changed, 27 insertions(+), 4 deletions(-) diff --git a/Ventas/Ventas.aspx.vb b/Ventas/Ventas.aspx.vb index 5b1a8e42a..2d74eb9bf 100644 --- a/Ventas/Ventas.aspx.vb +++ b/Ventas/Ventas.aspx.vb @@ -5469,7 +5469,11 @@ Partial Class Ventas HplPagado.Text = "CANCELADO" End If If ViewState("CveCotizacion") IsNot Nothing AndAlso ViewState("CveCotizacion").ToString().ToEntero() > 0 AndAlso DdlTipoComprobante.SelectedValue = "Ing" Then - ImgAntiPend.Visible = True + If UsuarioActual.CveEmpresa = 189 Then + ImgAntiPend.Visible = False + Else + ImgAntiPend.Visible = True + End If Else ImgAntiPend.Visible = False End If @@ -5578,7 +5582,11 @@ Partial Class Ventas If DbRowVenta("Saldo").ToString().ToDouble < 0.01 Then If ViewState("CveCotizacion") IsNot Nothing AndAlso ViewState("CveCotizacion").ToString().ToEntero() > 0 AndAlso DdlTipoComprobante.SelectedValue = "Ing" Then - ImgAntiPend.Visible = True + If UsuarioActual.CveEmpresa = 189 Then + ImgAntiPend.Visible = False + Else + ImgAntiPend.Visible = True + End If Else ImgAntiPend.Visible = False End If @@ -17301,6 +17309,10 @@ Partial Class Ventas If UsuarioActual.Empresa.Funcionalidad(382) = "1" AndAlso DtMovtos IsNot Nothing AndAlso DtMovtos.Rows.Count = 0 Then ImgAntiPend.Visible = False End If + + If UsuarioActual.CveEmpresa = 189 Then + ImgAntiPend.Visible = False + End If Else GVAnticipos.DataSource = Nothing End If @@ -18963,6 +18975,9 @@ Partial Class Ventas ImgAntiPend.Visible = True End If + If UsuarioActual.CveEmpresa = 189 Then + ImgAntiPend.Visible = False + End If If ImgAntiPend.Visible Then If Me.TmpDTAnticiposNCIxCCliente IsNot Nothing Then @@ -19008,6 +19023,10 @@ Partial Class Ventas ImgAntiPend.Visible = True End If + If UsuarioActual.CveEmpresa = 189 Then + ImgAntiPend.Visible = False + End If + If ImgAntiPend.Visible Then If Me.TmpDTAnticiposNCIxCCliente IsNot Nothing Then Dim DtMovtos As DataTable = Me.TmpDTAnticiposNCIxCCliente.FiltraParametros($"Saldo > 0 And SaldoSubtotal > 0 {If(CveVenta < 0, $"AND Tipo IN('NC','RNC','IxC','Ant') ", "")}") @@ -23985,7 +24004,7 @@ Partial Class Ventas If Not ObjVentas.UpdateVentas(TxtSubTotal.Text.ToDecimal, LblDescuentos.Text.ToDecimal, TxtIVA.Text.ToDecimal, TxtIEPS.Text.ToDecimal, TxtTotal.Text.ToDecimal, Moneda, TipoCambio, TxtFecha.Text.Trim.ToDate, TxtObsFact.Text.Trim, UsuarioActual.CveEmpresa, CveVenta, Vigencia:=TxtFechaVencimientoCotizacion.Text.Trim.ToDate, CondicionesPago:=If(RBLPago.SelectedValue = "2", 0, 1), - PedidoContrato:=TxtPedidoContrato.Text, AtencionA:=TxtAtencionA.Text.Trim, CveMetodoPago33:=DdlMetodoPago33.SelectedValue.ToEntero(), + PedidoContrato:=TxtPedidoContrato.Text, AtencionA:=TxtAtencionA.Text.Trim.ToUpper(), CveMetodoPago33:=DdlMetodoPago33.SelectedValue.ToEntero(), CveFormaPago33:=DdlFormaPago33.SelectedValue.ToEntero(), TipoDocto:=DdlTipoComprobante.SelectedValue, CveCliente:=CveCliente, CveClienteSucursal:=CveClienteSucursal, OrdenCompra:=TxtOrdenCompra.Text, RetIVA:=TxtRetIVA.Text.ToDecimal, RetISR:=TxtRetISR.Text.ToDecimal, Kilometraje:=TxtKilometraje.Text.ToDecimal, CveUsoCFDi:=DdlUsoCFDI.SelectedValue.ToEntero(), CveVendedor:=DdlVendedor.SelectedValue.ToEntero(), ServicioDomicilio:=TrServicioDomicilio.Visible, CveMedico:=DdlMedico.SelectedValue.ToEntero, CveProcedimiento:=DdlProcedimiento.SelectedValue.ToEntero, @@ -32729,6 +32748,10 @@ Partial Class Ventas GVAnticipos.DataSource = DtMovtos GVAnticipos.DataBind() If DtMovtos.Rows.Count > 0 Then ImgAntiPend.Visible = True + + If UsuarioActual.CveEmpresa = 189 Then + ImgAntiPend.Visible = False + End If Else Dim DtMovtos As DataTable = Me.TmpDTAnticiposNCIxCCliente.FiltraParametros($"Saldo > 0 AND SaldoSubtotal > 0 {If(CveVenta < 0, $"AND Tipo = 'Ant' ", "")} {If(DdlTipoComprobante.SelectedValue = "Ant", "AND Tipo = 'NC'", "")}") divAmortizacionTipoRelacion.Visible = True @@ -33022,7 +33045,7 @@ Partial Class Ventas Moneda, TipoCambio, TxtFecha.Text.Trim.ToDate, TxtObsFact.Text.Trim, UsuarioActual.CveEmpresa, CveVenta, Vigencia:=TxtFechaVencimientoCotizacion.Text.Trim.ToDate, CondicionesPago:=If(RBLPago.SelectedValue = "2", 0, 1), - PedidoContrato:=TxtPedidoContrato.Text, AtencionA:=TxtAtencionA.Text.Trim, CveMetodoPago33:=DdlMetodoPago33.SelectedValue.ToEntero(), CveFormaPago33:=DdlFormaPago33.SelectedValue.ToEntero(), + PedidoContrato:=TxtPedidoContrato.Text, AtencionA:=TxtAtencionA.Text.Trim.ToUpper(), CveMetodoPago33:=DdlMetodoPago33.SelectedValue.ToEntero(), CveFormaPago33:=DdlFormaPago33.SelectedValue.ToEntero(), CveCliente:=CveCliente, CveClienteSucursal:=CveClienteSucursal, OrdenCompra:=TxtOrdenCompra.Text, RetIVA:=TxtRetIVA.Text.ToDecimal, RetISR:=TxtRetISR.Text.ToDecimal, TipoDocto:=DdlTipoComprobante.SelectedValue, Kilometraje:=TxtKilometraje.Text.ToDecimal, CveUsoCFDi:=DdlUsoCFDI.SelectedValue.ToEntero(), CveVendedor:=DdlVendedor.SelectedValue.ToEntero()) Then MensajeError = "Ocurrió un error al actualizar la información de la cotización"