mejoras
This commit is contained in:
@@ -186,11 +186,11 @@ Partial Class Bancos_PopIECompras
|
||||
ViewState("TipoTransaccion") = value
|
||||
End Set
|
||||
End Property
|
||||
Private Property SaldoVenta As Double
|
||||
Private Property SaldoVenta As Decimal
|
||||
Get
|
||||
Return ViewState("SaldoVenta").ToString.ToDouble
|
||||
Return ViewState("SaldoVenta").ToString.ToDecimal
|
||||
End Get
|
||||
Set(value As Double)
|
||||
Set(value As Decimal)
|
||||
ViewState("SaldoVenta") = value
|
||||
End Set
|
||||
End Property
|
||||
@@ -277,7 +277,7 @@ Partial Class Bancos_PopIECompras
|
||||
<Serializable>
|
||||
Public Class Anticipos
|
||||
Public Property CveIE As Integer
|
||||
Public Property Importe As Double
|
||||
Public Property Importe As Decimal
|
||||
Public Property CvePersonal As Integer
|
||||
End Class
|
||||
<Serializable>
|
||||
@@ -677,10 +677,10 @@ Partial Class Bancos_PopIECompras
|
||||
RVImporte.Enabled = True
|
||||
|
||||
RVImporte.Enabled = True
|
||||
RVImporte.MaximumValue = dr("Saldo").ToString.ToDouble.ToString.FormatoNumero
|
||||
TxtImporte.Text = dr("Saldo").ToString.ToDouble.FormatoNumero
|
||||
RVImporte.MaximumValue = dr("Saldo").ToString.ToDecimal.ToString.FormatoNumero
|
||||
TxtImporte.Text = dr("Saldo").ToString.ToDecimal.FormatoNumero
|
||||
|
||||
SaldoVenta = dr("Saldo").ToString.ToDouble
|
||||
SaldoVenta = dr("Saldo").ToString.ToDecimal
|
||||
EsImportacion = CBool(dr("EsImportacion"))
|
||||
End If
|
||||
End If
|
||||
@@ -915,10 +915,10 @@ Partial Class Bancos_PopIECompras
|
||||
dr = DtAcreedores.FiltroPrimero(String.Format("CveProveedor = {0}", DdlAcreedor.SelectedValue))
|
||||
|
||||
If dr IsNot Nothing Then
|
||||
Dim tSaldo As Double = dr("Saldo").ToString.ToDouble
|
||||
Dim tSaldo As Decimal = dr("Saldo").ToString.ToDecimal
|
||||
|
||||
'si el saldo es mayor de la compra poner el valor de la compra sino el valor del saldo
|
||||
TxtImporte.Text = If(tSaldo > TxtTotal.Text.ToDouble, TxtTotal.Text, tSaldo.ToString).FormatoNumero
|
||||
TxtImporte.Text = If(tSaldo > TxtTotal.Text.ToDecimal, TxtTotal.Text, tSaldo.ToString).FormatoNumero
|
||||
|
||||
|
||||
Dim ObjMov As New ClsMovimientos
|
||||
@@ -1086,7 +1086,7 @@ Partial Class Bancos_PopIECompras
|
||||
End If
|
||||
Next
|
||||
'actualizo el monto maximo a pagar en el movimiento bancario
|
||||
Dim tSaldo As Double = DdlFuncionarioEmpleado.SelectedItem.Text.Split(CChar("-"))(1).ToDouble
|
||||
Dim tSaldo As Decimal = DdlFuncionarioEmpleado.SelectedItem.Text.Split(CChar("-"))(1).ToDecimal
|
||||
If tSaldo < MovimientoPagar.Saldo Then
|
||||
TxtImporte.Text = tSaldo.FormatoNumero()
|
||||
End If
|
||||
@@ -1149,7 +1149,7 @@ Partial Class Bancos_PopIECompras
|
||||
GvDeudores.Columns(6).Visible = False
|
||||
|
||||
RVImporte.Enabled = True
|
||||
RVImporte.MaximumValue = LtlSaldo.Text.ToDouble.ToString
|
||||
RVImporte.MaximumValue = LtlSaldo.Text.ToDecimal.ToString
|
||||
|
||||
CVImporteDolares.Enabled = False
|
||||
CVImportePesos.Enabled = False
|
||||
@@ -1160,7 +1160,7 @@ Partial Class Bancos_PopIECompras
|
||||
End Sub
|
||||
|
||||
Protected Sub CVImporteDolares_ServerValidate(source As Object, args As ServerValidateEventArgs)
|
||||
If args.Value.ToString.Substring(0, args.Value.Length - 3).ToDouble <= LtlSaldo.Text.Substring(0, LtlSaldo.Text.Length - 3).ToDouble Then
|
||||
If args.Value.ToString.Substring(0, args.Value.Length - 3).ToDecimal <= LtlSaldo.Text.Substring(0, LtlSaldo.Text.Length - 3).ToDecimal Then
|
||||
args.IsValid = True
|
||||
Else
|
||||
args.IsValid = False
|
||||
@@ -1208,7 +1208,7 @@ Partial Class Bancos_PopIECompras
|
||||
GvDeudores.Columns(6).Visible = False
|
||||
|
||||
RVImporte.Enabled = True
|
||||
RVImporte.MaximumValue = LtlSaldo.Text.ToDouble.ToString
|
||||
RVImporte.MaximumValue = LtlSaldo.Text.ToDecimal.ToString
|
||||
|
||||
CVImporteDolares.Enabled = False
|
||||
CVImportePesos.Enabled = False
|
||||
@@ -1219,7 +1219,7 @@ Partial Class Bancos_PopIECompras
|
||||
End Sub
|
||||
|
||||
Protected Sub CVImportePesos_ServerValidate(source As Object, args As ServerValidateEventArgs)
|
||||
If args.Value.ToString.Substring(0, args.Value.Length - 3).ToDouble <= LtlSaldo.Text.Substring(0, LtlSaldo.Text.Length - 3).ToDouble Then
|
||||
If args.Value.ToString.Substring(0, args.Value.Length - 3).ToDecimal <= LtlSaldo.Text.Substring(0, LtlSaldo.Text.Length - 3).ToDecimal Then
|
||||
args.IsValid = True
|
||||
Else
|
||||
args.IsValid = False
|
||||
@@ -1251,10 +1251,10 @@ Partial Class Bancos_PopIECompras
|
||||
#Region "GV ROW DATA BOUND"
|
||||
Private Sub GvIngresos_RowDataBound(sender As Object, e As GridViewRowEventArgs) Handles GvIngresos.RowDataBound
|
||||
If e.Row.RowType = DataControlRowType.DataRow Then
|
||||
Dim total As Double
|
||||
Dim saldo As Double
|
||||
Dim total As Decimal
|
||||
Dim saldo As Decimal
|
||||
|
||||
saldo = e.Row.DataKey("Saldo").ToDouble
|
||||
saldo = e.Row.DataKey("Saldo").ToDecimal
|
||||
total = SaldoVenta
|
||||
|
||||
e.Row.FCCheckBox("Chk").Attributes.Add("onclick", String.Format("ClickDeudorChk(this, ""{0}"", ""{1}"", ""{2}"")", e.Row.FCTextBox("TxtSaldoDeudor").ClientID, total, saldo))
|
||||
@@ -1268,10 +1268,10 @@ Partial Class Bancos_PopIECompras
|
||||
|
||||
Private Sub GvDeudores_RowDataBound(sender As Object, e As GridViewRowEventArgs) Handles GvDeudores.RowDataBound
|
||||
If e.Row.RowType = DataControlRowType.DataRow Then
|
||||
Dim total As Double
|
||||
Dim saldo As Double
|
||||
Dim total As Decimal
|
||||
Dim saldo As Decimal
|
||||
|
||||
saldo = e.Row.DataKey("Saldo").ToDouble
|
||||
saldo = e.Row.DataKey("Saldo").ToDecimal
|
||||
total = SaldoVenta
|
||||
|
||||
e.Row.FCCheckBox("Chk").Attributes.Add("onclick", String.Format("ClickDeudorChk(this, ""{0}"", ""{1}"", ""{2}"")", e.Row.FCTextBox("TxtSaldoDeudor").ClientID, total, saldo))
|
||||
@@ -1284,10 +1284,10 @@ Partial Class Bancos_PopIECompras
|
||||
|
||||
Private Sub GvAcreedores_RowDataBound(sender As Object, e As GridViewRowEventArgs) Handles GvAcreedores.RowDataBound
|
||||
If e.Row.RowType = DataControlRowType.DataRow Then
|
||||
Dim total As Double
|
||||
Dim saldo As Double
|
||||
Dim total As Decimal
|
||||
Dim saldo As Decimal
|
||||
|
||||
saldo = e.Row.DataKey("Saldo").ToDouble
|
||||
saldo = e.Row.DataKey("Saldo").ToDecimal
|
||||
total = SaldoVenta
|
||||
|
||||
e.Row.FCCheckBox("Chk").Attributes.Add("onclick", String.Format("ClickDeudorChk(this, ""{0}"", ""{1}"", ""{2}"")", e.Row.FCTextBox("TxtSaldoDeudor").ClientID, total, saldo))
|
||||
@@ -1300,10 +1300,10 @@ Partial Class Bancos_PopIECompras
|
||||
|
||||
Private Sub GvVentas_RowDataBound(sender As Object, e As GridViewRowEventArgs) Handles GvVentas.RowDataBound
|
||||
If e.Row.RowType = DataControlRowType.DataRow Then
|
||||
Dim total As Double
|
||||
Dim saldo As Double
|
||||
Dim total As Decimal
|
||||
Dim saldo As Decimal
|
||||
|
||||
saldo = e.Row.DataKey("Saldo").ToDouble
|
||||
saldo = e.Row.DataKey("Saldo").ToDecimal
|
||||
total = SaldoVenta
|
||||
|
||||
e.Row.FCCheckBox("Chk").Attributes.Add("onclick", String.Format("ClickDeudorChk(this, ""{0}"", ""{1}"", ""{2}"")", e.Row.FCTextBox("TxtSaldoDeudor").ClientID, total, saldo))
|
||||
@@ -1506,7 +1506,7 @@ Partial Class Bancos_PopIECompras
|
||||
CveIE = -1
|
||||
End Select
|
||||
|
||||
If DdlOtrosPagos.SelectedValue = "2" AndAlso TxtComision.Text.ToDouble > 0 Then
|
||||
If DdlOtrosPagos.SelectedValue = "2" AndAlso TxtComision.Text.ToDecimal > 0 Then
|
||||
'Agrego el movimiento a Comisiones
|
||||
If Not ObjMov.AddPrePolizasDetalle(CvePrePoliza, False, TxtComision.Text.ToDecimal, TxtObservaciones.Text, 78, TxtObservaciones.Text, Fecha, 0, -1, CveIE, CveCompra, -1, -1, If(ViewState("CveCliente") IsNot Nothing, ViewState("CveCliente").ToString.ToEntero, -1)) Then
|
||||
MsgError = "Detalle"
|
||||
@@ -2430,7 +2430,7 @@ Partial Class Bancos_PopIECompras
|
||||
ImporteMovimientoNoDeducible = (MovimientoPagar.IVANoDeducible)
|
||||
ImporteMXNoDeducible = ImporteMovimientoNoDeducible * If(FuncionalidadFluctuacionImpuestos, tipoCambioPago, tipoCambioCompra)
|
||||
End If
|
||||
ImporteMovimientoNoDeducible = Math.Round(ImporteMovimientoNoDeducible, 2)
|
||||
ImporteMovimientoNoDeducible = ImporteMovimientoNoDeducible.RoundSQL
|
||||
ImporteMXNoDeducible = ImporteMX.RoundSQL
|
||||
TimpocambioGeneral = If(FuncionalidadFluctuacionImpuestos, tipoCambioPago, tipoCambioCompra)
|
||||
|
||||
@@ -2454,8 +2454,8 @@ Partial Class Bancos_PopIECompras
|
||||
ImporteMovimientoNoDeducible = (MovimientoPagar.IVANoDeducible * PorcentajePago)
|
||||
ImporteMXNoDeducible = ImporteMovimientoNoDeducible * If(FuncionalidadFluctuacionImpuestos, tipoCambioPago, tipoCambioCompra)
|
||||
End If
|
||||
ImporteMovimientoNoDeducible = Math.Round(ImporteMovimientoNoDeducible, 2)
|
||||
ImporteMXNoDeducible = Math.Round(ImporteMXNoDeducible, 2)
|
||||
ImporteMovimientoNoDeducible = ImporteMovimientoNoDeducible.RoundSQL
|
||||
ImporteMXNoDeducible = ImporteMXNoDeducible.RoundSQL
|
||||
TimpocambioGeneral = If(FuncionalidadFluctuacionImpuestos, tipoCambioPago, tipoCambioCompra)
|
||||
|
||||
If tipoCambioPago > 1 Then ConceptoMovimiento += $" TC:{tipoCambioPago} ${ImporteMovimientoNoDeducible.FormatoNumero(2)}"
|
||||
@@ -2656,7 +2656,7 @@ Partial Class Bancos_PopIECompras
|
||||
ImporteMovimientoNoDeducible = (MovimientoPagar.IVANoDeducible)
|
||||
ImporteMXNoDeducible = ImporteMovimientoNoDeducible * If(FuncionalidadFluctuacionImpuestos, tipoCambioPago, tipoCambioCompra)
|
||||
End If
|
||||
ImporteMovimientoNoDeducible = Math.Round(ImporteMovimientoNoDeducible, 2)
|
||||
ImporteMovimientoNoDeducible = ImporteMovimientoNoDeducible.RoundSQL
|
||||
ImporteMXNoDeducible = ImporteMX.RoundSQL
|
||||
TimpocambioGeneral = If(FuncionalidadFluctuacionImpuestos, tipoCambioPago, tipoCambioCompra)
|
||||
|
||||
@@ -2680,8 +2680,8 @@ Partial Class Bancos_PopIECompras
|
||||
ImporteMovimientoNoDeducible = (MovimientoPagar.IVANoDeducible * PorcentajePago)
|
||||
ImporteMXNoDeducible = ImporteMovimientoNoDeducible * If(FuncionalidadFluctuacionImpuestos, tipoCambioPago, tipoCambioCompra)
|
||||
End If
|
||||
ImporteMovimientoNoDeducible = Math.Round(ImporteMovimientoNoDeducible, 2)
|
||||
ImporteMXNoDeducible = Math.Round(ImporteMXNoDeducible, 2)
|
||||
ImporteMovimientoNoDeducible = ImporteMovimientoNoDeducible.RoundSQL
|
||||
ImporteMXNoDeducible = ImporteMXNoDeducible.RoundSQL
|
||||
TimpocambioGeneral = If(FuncionalidadFluctuacionImpuestos, tipoCambioPago, tipoCambioCompra)
|
||||
|
||||
If tipoCambioPago > 1 Then ConceptoMovimiento += $" TC:{tipoCambioPago} ${ImporteMovimientoNoDeducible.FormatoNumero(2)}"
|
||||
@@ -3067,7 +3067,7 @@ Partial Class Bancos_PopIECompras
|
||||
IdCtaContable = IdCtaContComplementariaCliente
|
||||
If ImporteMovimiento <> 0 AndAlso (IdCtaContable > 0 Or UsuarioActual.CveEmpresa = 119) Then
|
||||
ImporteMX = ImporteMovimiento
|
||||
If Not ObjMov.AddPrePolizasDetalle(CvePrePoliza, TipoMovimiento, 0, TxtObservaciones.Text, 207, ConceptoMovimiento, Fecha, IdCtaContable, -1, CveIE, rw.DataKey("CveVenta").ToString.ToEntero, CveCompra, CveCliente:=rw.DataKey("CveCliente").ToString.ToEntero, ImporteMX:=Math.Round(ImporteMovimiento * tipoCambioPago - ImporteMovimiento, 2, MidpointRounding.AwayFromZero), ImporteME:=ImporteMovimiento, TipoCambio:=tipoCambioPago) Then
|
||||
If Not ObjMov.AddPrePolizasDetalle(CvePrePoliza, TipoMovimiento, 0, TxtObservaciones.Text, 207, ConceptoMovimiento, Fecha, IdCtaContable, -1, CveIE, rw.DataKey("CveVenta").ToString.ToEntero, CveCompra, CveCliente:=rw.DataKey("CveCliente").ToString.ToEntero, ImporteMX:=(ImporteMovimiento * tipoCambioPago - ImporteMovimiento).RoundSQL, ImporteME:=ImporteMovimiento, TipoCambio:=tipoCambioPago) Then
|
||||
MsgError = "No se pudo insertar la póliza"
|
||||
End If
|
||||
End If
|
||||
|
||||
Reference in New Issue
Block a user