SMS Ventas Sucursales cliente + parte tarjeta SMS - 2024.01.04
This commit is contained in:
@@ -2560,6 +2560,7 @@ Partial Class Ventas
|
||||
If UsuarioActual.Empresa.Funcionalidad(578) = "1" Then
|
||||
CargaMedicos()
|
||||
CargaProcedimientos()
|
||||
|
||||
CargaDdlClientes()
|
||||
End If
|
||||
|
||||
@@ -7799,6 +7800,35 @@ Partial Class Ventas
|
||||
|
||||
End Sub
|
||||
|
||||
Private Sub CargaSucursalesModal(CveClienteSeleccionado As Integer)
|
||||
|
||||
DdlSucursalClienteModal.Items.Clear()
|
||||
DdlSucursalClienteModal.ClearSelection()
|
||||
DdlSucursalClienteModal.SelectedValue = Nothing
|
||||
|
||||
Dim ObjCliente As New ClsClientes
|
||||
If ObjCliente.GetSucursales(CveClienteSeleccionado) Then
|
||||
DdlSucursalClienteModal.DataSource = ObjCliente.DtResultados
|
||||
If ObjCliente.DtResultados.Rows.Count > 0 Then
|
||||
DvModalClientesucursal.Visible = True
|
||||
Else
|
||||
DvModalClientesucursal.Visible = False
|
||||
End If
|
||||
Else
|
||||
DvModalClientesucursal.Visible = False
|
||||
DdlSucursalClienteModal.DataSource = Nothing
|
||||
End If
|
||||
ObjCliente.Dispose()
|
||||
|
||||
DdlSucursalClienteModal.DataBind()
|
||||
DdlSucursalClienteModal.Items.Insert(0, New ListItem("Matriz", "-1"))
|
||||
|
||||
UpDvModalTipoVenta.FindDataSourceControl
|
||||
|
||||
End Sub
|
||||
|
||||
|
||||
|
||||
Private Sub CargaDdlClientes()
|
||||
If UsuarioActual.Empresa.Funcionalidad(105) = "1" Then
|
||||
DdlClientesWS.setEsWebService(True)
|
||||
@@ -10755,7 +10785,13 @@ Partial Class Ventas
|
||||
ObjFacturaDevolucion.Fech1 = TxtFech1.Text.Trim.ToDate
|
||||
ObjFacturaDevolucion.Fech2 = TxtFech2.Text.Trim.ToDate
|
||||
ObjFacturaDevolucion.Fech3 = TxtFech3.Text.Trim.ToDate
|
||||
ObjFacturaDevolucion.Alfa1 = TxtAlfa1.Text.Trim
|
||||
|
||||
If UsuarioActual.Empresa.Funcionalidad(578) = "1" AndAlso DvModalRequiereOSFecha.Visible Then
|
||||
ObjFacturaDevolucion.Alfa1 = TxtFechaOS.Text.Trim
|
||||
Else
|
||||
ObjFacturaDevolucion.Alfa1 = TxtAlfa1.Text.Trim
|
||||
End If
|
||||
|
||||
ObjFacturaDevolucion.Alfa2 = TxtAlfa2.Text.Trim
|
||||
ObjFacturaDevolucion.Alfa3 = TxtAlfa3.Text.Trim
|
||||
ObjFacturaDevolucion.Num1 = TxtNum1.Text.Trim.ToDouble
|
||||
@@ -11031,7 +11067,13 @@ Partial Class Ventas
|
||||
ObjFacturaBonificacion.Fech1 = TxtFech1.Text.Trim.ToDate
|
||||
ObjFacturaBonificacion.Fech2 = TxtFech2.Text.Trim.ToDate
|
||||
ObjFacturaBonificacion.Fech3 = TxtFech3.Text.Trim.ToDate
|
||||
ObjFacturaBonificacion.Alfa1 = TxtAlfa1.Text.Trim
|
||||
|
||||
If UsuarioActual.Empresa.Funcionalidad(578) = "1" AndAlso DvModalRequiereOSFecha.Visible Then
|
||||
ObjFacturaBonificacion.Alfa1 = TxtFechaOS.Text.Trim
|
||||
Else
|
||||
ObjFacturaBonificacion.Alfa1 = TxtAlfa1.Text.Trim
|
||||
End If
|
||||
|
||||
ObjFacturaBonificacion.Alfa2 = TxtAlfa2.Text.Trim
|
||||
ObjFacturaBonificacion.Alfa3 = TxtAlfa3.Text.Trim
|
||||
ObjFacturaBonificacion.Num1 = TxtNum1.Text.Trim.ToDouble
|
||||
@@ -11513,7 +11555,13 @@ Partial Class Ventas
|
||||
ObjFactura.Fech1 = TxtFech1.Text.Trim.ToDate
|
||||
ObjFactura.Fech2 = TxtFech2.Text.Trim.ToDate
|
||||
ObjFactura.Fech3 = TxtFech3.Text.Trim.ToDate
|
||||
ObjFactura.Alfa1 = TxtAlfa1.Text.Trim
|
||||
|
||||
If UsuarioActual.Empresa.Funcionalidad(578) = "1" AndAlso DvModalRequiereOSFecha.Visible Then
|
||||
ObjFactura.Alfa1 = TxtFechaOS.Text.Trim
|
||||
Else
|
||||
ObjFactura.Alfa1 = TxtAlfa1.Text.Trim
|
||||
End If
|
||||
|
||||
ObjFactura.Alfa2 = TxtAlfa2.Text.Trim
|
||||
ObjFactura.Alfa3 = TxtAlfa3.Text.Trim
|
||||
ObjFactura.Num1 = TxtNum1.Text.Trim.ToDouble
|
||||
@@ -12170,7 +12218,14 @@ Partial Class Ventas
|
||||
ObjFacturaDevolucion.Fech1 = TxtFech1.Text.Trim.ToDate
|
||||
ObjFacturaDevolucion.Fech2 = TxtFech2.Text.Trim.ToDate
|
||||
ObjFacturaDevolucion.Fech3 = TxtFech3.Text.Trim.ToDate
|
||||
ObjFacturaDevolucion.Alfa1 = TxtAlfa1.Text.Trim
|
||||
|
||||
|
||||
If UsuarioActual.Empresa.Funcionalidad(578) = "1" AndAlso DvModalRequiereOSFecha.Visible Then
|
||||
ObjFacturaDevolucion.Alfa1 = TxtFechaOS.Text.Trim
|
||||
Else
|
||||
ObjFacturaDevolucion.Alfa1 = TxtAlfa1.Text.Trim
|
||||
End If
|
||||
|
||||
ObjFacturaDevolucion.Alfa2 = TxtAlfa2.Text.Trim
|
||||
ObjFacturaDevolucion.Alfa3 = TxtAlfa3.Text.Trim
|
||||
ObjFacturaDevolucion.Num1 = TxtNum1.Text.Trim.ToDouble
|
||||
@@ -35975,14 +36030,24 @@ Partial Class Ventas
|
||||
DvModalTipoVentaPasoCliente.Visible = True
|
||||
DvModalTipoVentaPasoRequiereOS.Visible = True
|
||||
DvModalTipoVentaPasoMedicoProcedimiento.Visible = True
|
||||
TxtFechaModal.Text = NowADS.ToString("yyyy-MM-dd HH:mm:ss").Replace(" ", "T")
|
||||
|
||||
ChkRequiereTecnicoModal.Checked = True
|
||||
ChkRequiereTecnicoModal.Enabled = True
|
||||
DvModalRequiereOSFecha.Visible = True
|
||||
|
||||
If CveCliente > 0 Then
|
||||
CargaSucursalesModal(CveCliente)
|
||||
End If
|
||||
|
||||
TxtFechaModal.Text = NowADS.AddHours(1).ToString("yyyy-MM-dd HH").Replace(" ", "T") + ":00" ' ToString("yyyy-MM-dd HH:mm:ss").Replace(" ", "T")
|
||||
|
||||
LnkDvModalTipoVentaAceptar.Visible = True
|
||||
|
||||
|
||||
Select Case RBLTipoVenta.SelectedValue
|
||||
Case "1" ' Fuera de linea
|
||||
ChkRequiereTecnicoModal.Checked = True
|
||||
ChkRequiereTecnicoModal.Enabled = False
|
||||
ChkRequiereTecnicoModal.Enabled = True
|
||||
DvModalRequiereOSFecha.Visible = True
|
||||
Case "2" ' Pago Directo
|
||||
ChkRequiereTecnicoModal.Checked = True
|
||||
@@ -36012,6 +36077,9 @@ Partial Class Ventas
|
||||
|
||||
Protected Sub DdlClientesWS_selectedindexchange(sender As Object, e As EventArgs)
|
||||
CargaPSProcedimiento(DdlProcedimiento.SelectedValue.ToEntero, DdlClientesWS.SelectedValue.ToEntero, DdlSubProyectoDatos.SelectedValue.ToEntero)
|
||||
|
||||
CargaSucursalesModal(DdlClientesWS.SelectedValue.ToEntero)
|
||||
|
||||
End Sub
|
||||
|
||||
|
||||
@@ -36089,6 +36157,7 @@ Partial Class Ventas
|
||||
DdlMedico.SelectedValueExist(DdlMedicoModal.SelectedValue)
|
||||
DdlProcedimiento.SelectedValueExist(DdlProcedimientoModal.SelectedValue)
|
||||
|
||||
|
||||
'si es pago directo es factura
|
||||
If RBLTipoVenta.SelectedValue.Contiene("2") Then
|
||||
DdlTipoComprobante.SelectedValueExist("Ing")
|
||||
@@ -36106,8 +36175,12 @@ Partial Class Ventas
|
||||
DdlTipoComprobante.Enabled = False
|
||||
|
||||
CargaCliente(CveCliente)
|
||||
|
||||
DdlSucursalCliente.SelectedValueExist(DdlSucursalClienteModal.SelectedValue)
|
||||
|
||||
DdlTipoComprobante_SelectedIndexChanged(sender, Nothing)
|
||||
RegistraScript("$('#DvModalTipoVenta').modal('hide');")
|
||||
|
||||
|
||||
Dim CountPsAgregados As Integer = 0
|
||||
|
||||
For Each GvRow As GridViewRow In GvProductosProcedimiento.Rows
|
||||
@@ -36134,6 +36207,13 @@ Partial Class Ventas
|
||||
If CountPsAgregados > 0 Then
|
||||
CalculaTotalesVenta()
|
||||
End If
|
||||
|
||||
If UsuarioActual.CveVendedor > 0 Then
|
||||
DdlVendedor.SelectedValueExist(UsuarioActual.CveVendedor)
|
||||
UpParametros.Update()
|
||||
End If
|
||||
|
||||
RegistraScript("$('#DvModalTipoVenta').modal('hide');")
|
||||
UpCliente.Update()
|
||||
End Sub
|
||||
|
||||
|
||||
Reference in New Issue
Block a user