-- limpieza de código de mandar idcta de contpaq
This commit is contained in:
@@ -314,46 +314,6 @@ Partial Class PV
|
||||
Return ViewState("Vendedor").ToString
|
||||
End Get
|
||||
End Property
|
||||
Private ReadOnly Property CtaContable As String
|
||||
Get
|
||||
Return ViewState("CtaContable").ToString
|
||||
End Get
|
||||
End Property
|
||||
Private ReadOnly Property IdCtaContClientes As Integer
|
||||
Get
|
||||
Return ViewState("IdCtaContClientes").ToString.ToEntero
|
||||
End Get
|
||||
End Property
|
||||
Private ReadOnly Property IdCtaContMonedaExtranjera As Integer
|
||||
Get
|
||||
Return ViewState("IdCtaContMonedaExtranjera").ToString.ToEntero
|
||||
End Get
|
||||
End Property
|
||||
Private ReadOnly Property IdCtaContComplementaria As Integer
|
||||
Get
|
||||
Return ViewState("IdCtaContComplementaria").ToString.ToEntero
|
||||
End Get
|
||||
End Property
|
||||
Private ReadOnly Property IdCtaContAnticipos As Integer
|
||||
Get
|
||||
Return ViewState("IdCtaContAnticipos").ToString.ToEntero
|
||||
End Get
|
||||
End Property
|
||||
Private ReadOnly Property IdCtaContRetIVA As Integer
|
||||
Get
|
||||
Return ViewState("IdCtaContRetIVA").ToString.ToEntero
|
||||
End Get
|
||||
End Property
|
||||
Private ReadOnly Property IdCtaContRetISR As Integer
|
||||
Get
|
||||
Return ViewState("IdCtaContRetISR").ToString.ToEntero
|
||||
End Get
|
||||
End Property
|
||||
Private ReadOnly Property IdCtaContDSV As Integer
|
||||
Get
|
||||
Return ViewState("IdCtaContDSV").ToString.ToEntero
|
||||
End Get
|
||||
End Property
|
||||
Private ReadOnly Property CodCliente As String
|
||||
Get
|
||||
Return ViewState("CodCliente").ToString
|
||||
@@ -1198,7 +1158,6 @@ Partial Class PV
|
||||
CargaClasificaciones()
|
||||
CargaPS(-1, DdlPS)
|
||||
CargaPS(-1, DdlPSAjuste, AplicaAlmacen:=False)
|
||||
CargaEmpresa()
|
||||
CreaDTVentas()
|
||||
CargaMetodosPago()
|
||||
CargaUsoCFDI()
|
||||
@@ -2569,20 +2528,6 @@ Partial Class PV
|
||||
CargaEstados(DdlSATPais.SelectedValue)
|
||||
End Sub
|
||||
|
||||
Private Sub CargaEmpresa()
|
||||
If UsuarioActual.Empresa.UsaContabilidad Then
|
||||
Dim ObjFisConfiguracion As New ClsFISConfiguracion
|
||||
If ObjFisConfiguracion.GetConfiguracion(UsuarioActual.CveEmpresa) Then
|
||||
ViewState("IdCtaContDSV") = ObjFisConfiguracion.ERDSV
|
||||
Else
|
||||
ViewState("IdCtaContDSV") = 0
|
||||
End If
|
||||
ObjFisConfiguracion.Dispose()
|
||||
Else
|
||||
ViewState("IdCtaContDSV") = 0
|
||||
End If
|
||||
End Sub
|
||||
|
||||
Private Sub CargaMonedas()
|
||||
DdlMoneda.DataSource = GlobalDTMonedas
|
||||
DdlMoneda.DataBind()
|
||||
@@ -2665,12 +2610,6 @@ Partial Class PV
|
||||
|
||||
ViewState("Vendedor") = ObjCliente.Vendedor
|
||||
ViewState("CtaContable") = ObjCliente.CuentaContable
|
||||
ViewState("IdCtaContClientes") = ObjCliente.IdCtaContClientes
|
||||
ViewState("IdCtaContMonedaExtranjera") = ObjCliente.IdCtaContMonedaExtranjera
|
||||
ViewState("IdCtaContComplementaria") = ObjCliente.IdCtaContComplementaria
|
||||
ViewState("IdCtaContAnticipos") = ObjCliente.IdCtaContAnticipos
|
||||
ViewState("IdCtaContRetIVA") = ObjCliente.IdCtaContRetIVA
|
||||
ViewState("IdCtaContRetISR") = ObjCliente.IdCtaContRetISR
|
||||
ViewState("CodCliente") = ObjCliente.Codigo
|
||||
ViewState("ClienteDesglosaIEPS") = ObjCliente.DesglosaIEPS
|
||||
ClienteCodigoRegimenFiscal = ObjCliente.DtResultados.Rows(0)("CodigoRegimenFiscal").ToString()
|
||||
@@ -4246,7 +4185,6 @@ Partial Class PV
|
||||
HdnIVAPS.Value = If(drPS("IVA").ToString = "-1", SubProyectoPorcentajeIVA.ToString(), drPS("IVA").ToString).ToString
|
||||
HdnIVARetAPS.Value = drPS("RetIVA").ToString
|
||||
HdnAsientoContable.Value = drPS("AsientoContableVentas").ToString
|
||||
HdnCtaContable.Value = drPS("IdCtaContVentas").ToString
|
||||
HdnAplicaParaConcepto.Value = drPS("AplicaParaConcepto").ToString
|
||||
HdnCodigo.Value = drPS("Codigo").ToString
|
||||
If DdlClasificacion.SelectedIndex = 0 Then
|
||||
@@ -4753,7 +4691,7 @@ Partial Class PV
|
||||
#Region "ADD PS"
|
||||
|
||||
Private Sub AddPS(Cantidad As Double, CveUM As Integer, UM As String, CveClasificacion As Integer, Clasificacion As String, CvePS As Integer, PS As String, Obs As String,
|
||||
PU As Double, IVA As Double, RetIVA As Double, Descuento As Double, AsientoContableVentas As Integer, IdCtaContable As Integer, AplicaParaConcepto As Boolean,
|
||||
PU As Double, IVA As Double, RetIVA As Double, Descuento As Double, AsientoContableVentas As Integer, AplicaParaConcepto As Boolean,
|
||||
Codigo As String, CveProyecto As Integer, Proyecto As String, CveSubProyecto As Integer, SubProyecto As String, Optional CveTipoPS As Integer = -1, Optional Serie As String = "",
|
||||
Optional CveContratoDetalle As Integer = -1, Optional TiempoEntrega As String = "", Optional CodigoPS As String = "")
|
||||
|
||||
@@ -4797,7 +4735,6 @@ Partial Class PV
|
||||
Row("TipoDescuento") = HdnTipoDescuento.Value
|
||||
Row("Total") = (Cantidad * PU)
|
||||
Row("AsientoContableVentas") = AsientoContableVentas
|
||||
Row("IdCtaContVentas") = IdCtaContable
|
||||
Row("AplicaParaConcepto") = AplicaParaConcepto
|
||||
Row("CveProyecto") = CveProyecto
|
||||
Row("Proyecto") = Proyecto
|
||||
@@ -5020,7 +4957,6 @@ Partial Class PV
|
||||
End If
|
||||
End If
|
||||
|
||||
|
||||
TotalCalculableImpuestos = (Cantidad * (PU)) - Descuento
|
||||
|
||||
If Modalidad = "A" Then
|
||||
@@ -5077,14 +5013,8 @@ Partial Class PV
|
||||
Row("TipoDescuento") = HdnTipoDescuento.Value
|
||||
Row("Total") = (Cantidad * PU)
|
||||
Row("TotalImporte") = (Cantidad * PU).RoundSQL(NumeroDecimales)
|
||||
'Row("AsientoContableVentas") = DrPS("AsientoContableVentas")
|
||||
' Row("IdCtaContVentas") = IdCtaContable
|
||||
' Row("AplicaParaConcepto") = AplicaParaConcepto
|
||||
|
||||
Row("SATClaveProdServ") = DrPS("SATClavePS")
|
||||
Row("SATClaveUM") = DrPS("SATClaveUnidadMedida")
|
||||
|
||||
|
||||
Row("EntregaDirecta") = EntregaDirecta
|
||||
'Contratos
|
||||
Row("CveContratoDetalle") = CveContratoDetalle
|
||||
@@ -5135,7 +5065,6 @@ Partial Class PV
|
||||
End If
|
||||
|
||||
Retorno = Row("Consec").ToString().ToEntero()
|
||||
|
||||
TmpDT.AcceptChanges()
|
||||
|
||||
Return Retorno
|
||||
@@ -6041,7 +5970,6 @@ Partial Class PV
|
||||
' HdnIVAPS.Value = If(DrProducto("IVA").ToString = "-1", ViewState("IVA"), DrProducto("IVA").ToString).ToString
|
||||
' HdnIVARetAPS.Value = DrProducto("RetIVA").ToString
|
||||
' HdnAsientoContable.Value = DrProducto("AsientoContableVentas").ToString
|
||||
' HdnCtaContable.Value = DrProducto("IdCtaContVentas").ToString
|
||||
' HdnAplicaParaConcepto.Value = DrProducto("AplicaParaConcepto").ToString
|
||||
' HdnCodigo.Value = DrProducto("Codigo").ToString
|
||||
|
||||
@@ -7932,14 +7860,6 @@ Partial Class PV
|
||||
Next
|
||||
StrCargos.Remove(StrCargos.Length - 1, 1)
|
||||
|
||||
'If TotalCantidad > TmpDT.FiltraParametros($"EsCargo = True AND CvePS IN ({StrCargos})").SUMD("Cantidad") Then
|
||||
' Dim drt As DataRow() = TmpDT.Select("CvePS = " & CvePS)
|
||||
' TmpDT.Rows.Remove(drt(0))
|
||||
|
||||
' Alert("No puede tener una cantidad mayor a la de los cargos", TipoMensaje.MsgAdvertencia)
|
||||
' Exit Sub
|
||||
'End If
|
||||
|
||||
Dim DtUsadosFiltro As DataTable = TmpDT.FiltraParametros($"ConsecPSPadre = {ConsecPSPadre} AND EsCargo = True AND EliminarDB = False AND CvePS IN ({StrCargos}) AND (Total - Descuento) > 0.0000")
|
||||
Dim DivisorUsado As Decimal = 1
|
||||
|
||||
@@ -7957,14 +7877,6 @@ Partial Class PV
|
||||
Dim TotalCalculableImpuestos As Decimal = (Dr("Cantidad").ToString.ToDecimal * (Dr("PU").ToString.ToDecimal)) - Descuento
|
||||
TotalCargos -= DescuentoCargo
|
||||
|
||||
'If PUActual <= 0 Then
|
||||
' Dim drt As DataRow() = TmpDT.Select("Consec = " & Dr("Consec").ToString)
|
||||
' TmpDT.Rows.Remove(drt(0))
|
||||
'Else
|
||||
|
||||
|
||||
'End If
|
||||
|
||||
Dim drt As DataRow() = TmpDT.Select("Consec = " & Dr("Consec").ToString)
|
||||
Dim drr As DataRow = drt(0)
|
||||
'drr("PU") = PUActual
|
||||
|
||||
Reference in New Issue
Block a user