-- option strict on

This commit is contained in:
2023-08-23 00:04:25 -07:00
parent 3bc4f72658
commit e5c000432f
28 changed files with 192 additions and 279 deletions

View File

@@ -18,10 +18,10 @@ Partial Class AF_CatCargasCombustible
Dim ObjAF As New ClsAF()
Dim AnioMes = If(Request("AnioMes") IsNot Nothing, Request("AnioMes").ToString, "-1").ToString
Dim CveProveedor = If(Request("CveProveedor") IsNot Nothing AndAlso Request("CveProveedor").ToEntero() > 0, Request("CveProveedor").ToEntero(), -1).ToString
Dim CveSubProyecto = If(Request("CveSubProyecto") IsNot Nothing AndAlso Request("CveSubProyecto").ToEntero() > 0, Request("CveSubProyecto").ToEntero(), -1).ToString
Dim CveTipoAF = If(Request("CveTipoAF") IsNot Nothing AndAlso Request("CveTipoAF").ToEntero() > 0, Request("CveTipoAF").ToEntero(), -1).ToString
Dim CveAF = If(Request("CveAF") IsNot Nothing AndAlso Request("CveAF").ToEntero() > 0, Request("CveAF").ToEntero(), -1).ToString
Dim CveProveedor As Integer = If(Request("CveProveedor") IsNot Nothing AndAlso Request("CveProveedor").ToEntero() > 0, Request("CveProveedor").ToEntero(), -1).ToString.ToEntero
Dim CveSubProyecto As Integer = If(Request("CveSubProyecto") IsNot Nothing AndAlso Request("CveSubProyecto").ToEntero() > 0, Request("CveSubProyecto").ToEntero(), -1).ToString.ToEntero
Dim CveTipoAF As Integer = If(Request("CveTipoAF") IsNot Nothing AndAlso Request("CveTipoAF").ToEntero() > 0, Request("CveTipoAF").ToEntero(), -1).ToString.ToEntero
Dim CveAF As Integer = If(Request("CveAF") IsNot Nothing AndAlso Request("CveAF").ToEntero() > 0, Request("CveAF").ToEntero(), -1).ToString.ToEntero
Dim FechaI = If(Request("FechaI") IsNot Nothing, Request("FechaI").ToString, "-1").ToString
Dim FechaF = If(Request("FechaF") IsNot Nothing, Request("FechaF").ToString, "-1").ToString
@@ -39,7 +39,7 @@ Partial Class AF_CatCargasCombustible
If AnioMes <> "-1" Then
FechaI = String.Format("01/{0}/{1}", sMes, sAnio)
FechaF = FechaI.ToDate.LastDayOfMonth
FechaF = FechaI.ToDate.LastDayOfMonth.ToShortDateString
End If
If ObjAF.GetCargasCombustible(CveAF, CveProveedor, CveTipoAF, CveSubProyecto, FechaI, FechaF, UsuarioActual.CveEmpresa, CveCargaCombustible:=-1) Then
@@ -75,7 +75,7 @@ Partial Class AF_CatCargasCombustible
Dim ObjAF As New ClsAF()
DdlActivoFijo.Items.Clear()
If ObjAF.GetActivosFijos(-1, UsuarioActual.CveEmpresa, "-1", "-1", "-1", "-1", "-1", -1, -1, -1, -1, -1, "-1", -1) Then
If ObjAF.GetActivosFijos(-1, UsuarioActual.CveEmpresa, "-1", "-1", -1, -1, "-1", -1, -1, -1, -1, -1, "-1", -1) Then
DdlActivoFijo.Items.Insert(0, New ListItem("Seleccione", "-1"))
DdlActivoFijo.DataSource = ObjAF.DtResultados
DdlActivoFijo.DataBind()
@@ -110,7 +110,7 @@ Partial Class AF_CatCargasCombustible
FechaCarga = DateTime.Parse(String.Format("{0} {1}:{2} {3}", TxtFecha.Text, TimeSelector.Hour, TimeSelector.Minute, TimeSelector.AmPm))
If ObjAF.AddCargaCombustible(DdlCombustible.SelectedValue.ToEntero, DdlProveedor.SelectedValue.ToEntero, DdlActivoFijo.SelectedValue.ToEntero, TxtFolio.Text.Trim, FechaCarga, CkhTanque.Checked, TxtCantidad.Text.ToDouble, TxtCosto.Text.ToDouble,
If ObjAF.AddCargaCombustible(DdlCombustible.SelectedValue.ToEntero, DdlProveedor.SelectedValue.ToEntero, DdlActivoFijo.SelectedValue.ToEntero, TxtFolio.Text.Trim, FechaCarga, If(CkhTanque.Checked, 1, 0), TxtCantidad.Text.ToDouble, TxtCosto.Text.ToDouble,
TxtOdometro.Text.ToDouble, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa) Then
Alert("Se registró la carga correctamente.", TipoMensaje.MsgInformacion)
End If