This commit is contained in:
2024-07-17 09:30:07 -07:00
12 changed files with 2640 additions and 259 deletions

View File

@@ -9752,13 +9752,13 @@ Partial Class Ventas
Dim CveVendedor As Integer = DdlVendedor.SelectedValue.ToEntero()
Dim ObjVentas As New ClsVentas
If ObjVentas.GetAutorizacionLimite(UsuarioActual.CveEmpresa, CveCliente, CveVendedor, "Ing", CveEstatus:=1) Then
If ObjVentas.GetAutorizacionLimite(UsuarioActual.CveEmpresa, CveCliente, CveVendedor, If(DdlTipoComprobante.SelectedValue = "Egs", "Egs", "Ing"), CveEstatus:=1) Then
Dim RowAutorizacion As DataRow = Nothing
'SI TIENE DIAS VENCIDOS BUSCAR POR TIPO VENCIMIENTO
If TieneDiasVencidos Then
RowAutorizacion = ObjVentas.DtResultados.FiltroPrimero($"TipoAutorizacion IN(1,2) AND CveVenta IS NULL AND CveTipoDocumento='Ing'", Orderby:="Importe DESC")
RowAutorizacion = ObjVentas.DtResultados.FiltroPrimero($"TipoAutorizacion IN(1,2) AND CveVenta IS NULL AND CveTipoDocumento='{If(DdlTipoComprobante.SelectedValue = "Egs", "Egs", "Ing")}'", Orderby:="Importe DESC")
Else
RowAutorizacion = ObjVentas.DtResultados.FiltroPrimero($"TipoAutorizacion = 1 AND CveVenta IS NULL AND CveTipoDocumento='Ing'", Orderby:="Importe DESC")
RowAutorizacion = ObjVentas.DtResultados.FiltroPrimero($"TipoAutorizacion = 1 AND CveVenta IS NULL AND CveTipoDocumento='{If(DdlTipoComprobante.SelectedValue = "Egs", "Egs", "Ing")}'", Orderby:="Importe DESC")
End If
If RowAutorizacion IsNot Nothing Then
@@ -12239,7 +12239,7 @@ Partial Class Ventas
ObjFactura.Det_OrdenCompra = TxtDet_OrdenCompra.Text.Trim
ObjFactura.Det_FechaOrdenCompra = TxtDet_FechaOrdenCompra.Text.Trim
ObjFactura.Det_ContraRecibo = TxtDet_ContraRecibo.Text.Trim
ObjFactura.MonedaAbreviatura = ""
ObjFactura.MonedaAbreviatura = DdlMoneda.SelectedItem.Text
If UsuarioActual.Empresa.Funcionalidad(578) = "1" AndAlso DvModalRequiereOSFecha.Visible Then
ObjFactura.FechaEjecucion = TxtFechaOS.Text.Trim.ToDateTime