-- mejora carga de clientes
This commit is contained in:
@@ -736,8 +736,8 @@ Partial Class ContabilidadC_RegPrePolizaS
|
||||
Private Sub CargaClientes()
|
||||
DdlClientes.setEsWebService(True)
|
||||
DdlClientes.Attributes.Add("data-metodo", "getcliente")
|
||||
DdlClientes.DataSource = GlobalDTCliente(UsuarioActual.CveEmpresa)
|
||||
DdlClientes.DataBind()
|
||||
'DdlClientes.DataSource = GlobalDTCliente(UsuarioActual.CveEmpresa)
|
||||
'DdlClientes.DataBind()
|
||||
' DdlClientes.Items.Insert(0, New ListItem(" - ", "-1"))
|
||||
End Sub
|
||||
|
||||
@@ -1359,16 +1359,17 @@ Partial Class ContabilidadC_RegPrePolizaS
|
||||
|
||||
If CveCliente > 0 Then
|
||||
DvModalconceptoCliente.Visible = True
|
||||
DdlClientesE.SelectedValue = CveCliente
|
||||
DdlClientesE.SelectedText = GlobalDTCliente(UsuarioActual.CveEmpresa, CveCliente:=CveCliente).FiltroPrimeroValor("NombreComercial", "")
|
||||
DdlClientesE_SelectedIndexChanged(DdlClientesE, e)
|
||||
|
||||
DdlClientesE.SelectedText = GlobalDTCliente(UsuarioActual.CveEmpresa, CveCliente:=CveCliente).FiltroPrimeroValor("NombreComercial", "")
|
||||
DdlClientesE.ddl.Items.Insert(0, New ListItem(GlobalDTCliente(UsuarioActual.CveEmpresa, CveCliente:=CveCliente).FiltroPrimeroValor("NombreComercial", ""), CveCliente))
|
||||
DdlClientesE.SelectedValue = CveCliente
|
||||
|
||||
CargaVentasE(CveCliente)
|
||||
End If
|
||||
If CveVenta > 0 Then
|
||||
DdlVentasE.SelectedValueExist(CveVenta)
|
||||
End If
|
||||
|
||||
|
||||
If CveClasificacion > 0 Then
|
||||
DdlClasificacionesE.SelectedValue = CveClasificacion
|
||||
End If
|
||||
@@ -1621,11 +1622,20 @@ Partial Class ContabilidadC_RegPrePolizaS
|
||||
DdlClientesE.setEsWebService(True)
|
||||
|
||||
DdlClientesE.Attributes.Add("data-metodo", "getcliente")
|
||||
'DdlClientesE.DataSource = GlobalDTCliente(UsuarioActual.CveEmpresa)
|
||||
'DdlClientesE.DataBind()
|
||||
' DdlClientes.Items.Insert(0, New ListItem(" - ", "-1"))
|
||||
|
||||
End Sub
|
||||
Private Sub CargaVentasE(CveCliente As Integer, Optional CveMoneda As Integer = -1)
|
||||
Private Sub CargaVentasE(CveCliente As Integer)
|
||||
If CveCliente <= 0 Then Exit Sub
|
||||
|
||||
If DrConceptoContable IsNot Nothing Then
|
||||
Dim AplicaME = Boolean.Parse(DrConceptoContable("EsMonedaExtranjera").ToString)
|
||||
Dim AplicaVenta = Boolean.Parse(DrConceptoContable("AplicaVenta").ToString)
|
||||
If AplicaME Then
|
||||
CveMoneda = 2
|
||||
End If
|
||||
If Not AplicaVenta Then Exit Sub
|
||||
End If
|
||||
|
||||
DvModalconceptoVenta.Visible = True
|
||||
DdlVentasE.DataSource = Nothing
|
||||
DdlVentasE.ClearSelection()
|
||||
@@ -1661,16 +1671,9 @@ Partial Class ContabilidadC_RegPrePolizaS
|
||||
CargaComprasE(DdlProveedoresE.SelectedValue.ToEntero)
|
||||
End Sub
|
||||
Private Sub DdlClientesE_SelectedIndexChanged(sender As Object, e As EventArgs) Handles DdlClientesE.selectedindexchange
|
||||
Dim tCveMoneda As Integer = 1
|
||||
|
||||
If DrConceptoContable IsNot Nothing Then
|
||||
Dim AplicaME = Boolean.Parse(DrConceptoContable("EsMonedaExtranjera").ToString)
|
||||
If AplicaME Then
|
||||
tCveMoneda = 2
|
||||
End If
|
||||
End If
|
||||
If DdlClientesE.SelectedValue.ToEntero > 0 Then CargaVentasE(DdlClientesE.SelectedValue.ToEntero)
|
||||
|
||||
CargaVentasE(DdlClientesE.SelectedValue.ToEntero, tCveMoneda)
|
||||
End Sub
|
||||
|
||||
Private Function CargaValidacionesConcepto() As Boolean
|
||||
@@ -1853,7 +1856,7 @@ Partial Class ContabilidadC_RegPrePolizaS
|
||||
TxtTotalAbonos.Text = DtMovimientos.SUMD("Abono").ToString.FormatoNumero
|
||||
UpTotalCargo.Update()
|
||||
UpTotalAbono.Update()
|
||||
DdlClientesE.SelectedValue = "-1"
|
||||
DdlClientesE.ddl.Items.Clear()
|
||||
DdlClientesE.SelectedText = ""
|
||||
|
||||
End If
|
||||
|
||||
Reference in New Issue
Block a user