Empresas Zona Horaria
This commit is contained in:
@@ -402,7 +402,7 @@ Partial Class AF_AF
|
||||
|
||||
'Configuración de Modalidad Insert
|
||||
ImgAddObs.Visible = False
|
||||
LblFechaCaptura.Text = Now.ToShortDateString()
|
||||
LblFechaCaptura.Text = NowADS().ToShortDateString()
|
||||
LblUsuarioCapturo.Text = UsuarioActual.Usuario
|
||||
|
||||
BtnEliminar.Visible = False
|
||||
@@ -484,17 +484,17 @@ Partial Class AF_AF
|
||||
GVOrdenesdeServicio.DataBind()
|
||||
End Sub
|
||||
Private Sub CargaFechaGPS()
|
||||
TxtFechaIH.Text = $"01/{DateTime.Now.ToString("MM")}/{DateTime.Now.Year} 00:00"
|
||||
TxtFechaFH.Text = $"{DateTime.Now.ToString("dd/MM/yyyy")} 23:59"
|
||||
TxtFechaIH.Text = $"01/{NowADS().ToString("MM")}/{NowADS().Year} 00:00"
|
||||
TxtFechaFH.Text = $"{NowADS().ToString("dd/MM/yyyy")} 23:59"
|
||||
|
||||
TxtFechaIC.Text = $"01/{DateTime.Now.ToString("MM")}/{DateTime.Now.Year} 00:00"
|
||||
TxtFechaFC.Text = $"{DateTime.Now.ToString("dd/MM/yyyy")} 23:59"
|
||||
TxtFechaIC.Text = $"01/{NowADS().ToString("MM")}/{NowADS().Year} 00:00"
|
||||
TxtFechaFC.Text = $"{NowADS().ToString("dd/MM/yyyy")} 23:59"
|
||||
|
||||
TxtFechaID.Text = $"01/{DateTime.Now.ToString("MM")}/{DateTime.Now.Year} 00:00"
|
||||
TxtFechaFD.Text = $"{DateTime.Now.ToString("dd/MM/yyyy")} 23:59"
|
||||
TxtFechaID.Text = $"01/{NowADS().ToString("MM")}/{NowADS().Year} 00:00"
|
||||
TxtFechaFD.Text = $"{NowADS().ToString("dd/MM/yyyy")} 23:59"
|
||||
|
||||
TxtFechaIG.Text = $"01/{DateTime.Now.ToString("MM")}/{DateTime.Now.Year} 00:00"
|
||||
TxtFechaFG.Text = $"{DateTime.Now.ToString("dd/MM/yyyy")} 23:59"
|
||||
TxtFechaIG.Text = $"01/{NowADS().ToString("MM")}/{NowADS().Year} 00:00"
|
||||
TxtFechaFG.Text = $"{NowADS().ToString("dd/MM/yyyy")} 23:59"
|
||||
End Sub
|
||||
|
||||
Private Sub InicializaValores()
|
||||
@@ -2380,7 +2380,7 @@ Partial Class AF_AF
|
||||
Dim NewName As String
|
||||
For Each FileItem As Archivo In FilesGral
|
||||
Dim Retorno As Boolean = False
|
||||
NewName = DateTime.Now.Ticks.ToString
|
||||
NewName = NowADS().Ticks.ToString
|
||||
Dim ObjActivosFijos As New ClsAF
|
||||
Try
|
||||
FileMove = FileItem.filename
|
||||
@@ -2477,7 +2477,7 @@ Partial Class AF_AF
|
||||
If AFInvCvePS > 0 AndAlso AFInvCveAlmacen > 0 Then
|
||||
Dim CveUMInv = GlobalDTPS(CveEmpresaActual, CvePS:=AFInvCvePS).FiltroPrimeroValor("CveUM").ToEntero
|
||||
If CveUMInv > 0 Then
|
||||
CveMovimientoSalidaInv = ObjInventarios.AddMovimiento(AFInvCveAlmacen, 3, 1, Now, -1, UsuarioActual.CveUsuario, CveEmpresaActual, -1, -1, -1, -1, Observaciones:=$"Salida de inventario para Activo Fijo | {TxtCodigo.Text.Trim}", Modulo:="AF1")
|
||||
CveMovimientoSalidaInv = ObjInventarios.AddMovimiento(AFInvCveAlmacen, 3, 1, NowADS(), -1, UsuarioActual.CveUsuario, CveEmpresaActual, -1, -1, -1, -1, Observaciones:=$"Salida de inventario para Activo Fijo | {TxtCodigo.Text.Trim}", Modulo:="AF1")
|
||||
If Not ObjInventarios.AddMovimientoDetalle(CveMovimientoSalidaInv, 1, CveUMInv, AFInvCvePS, 0, -1, Serie:=AFInvSerie, CveSeccionAlmacen:=AFInvCveSeccionAlmacen) Then
|
||||
ErrorGuardar = True
|
||||
End If
|
||||
@@ -2578,7 +2578,7 @@ Partial Class AF_AF
|
||||
'PREPOLIZA DE IMPORTACION DESDE ALMACEN
|
||||
If AFInvCvePS > 0 AndAlso AFInvCveAlmacen > 0 Then
|
||||
If Not ErrorGuardar Then
|
||||
Dim CvePrePoliza As Integer = ObjContabilidad.AddPrePolizas("AF/ImportadoInv", 4, TxtValorCompra.Text.ToDouble, TxtValorCompra.Text.ToDouble, 1, Now, $"AF importado de Almacén {TxtCodigo.Text.Trim}", UsuarioActual.CveUsuario, CveEmpresaActual)
|
||||
Dim CvePrePoliza As Integer = ObjContabilidad.AddPrePolizas("AF/ImportadoInv", 4, TxtValorCompra.Text.ToDouble, TxtValorCompra.Text.ToDouble, 1, NowADS(), $"AF importado de Almacén {TxtCodigo.Text.Trim}", UsuarioActual.CveUsuario, CveEmpresaActual)
|
||||
If ObjContabilidad.AddPrePolizasDetalle(CvePrePoliza, False, TxtValorCompra.Text.ToDecimal, TxtValorCompra.Text.ToDecimal, 49, $"{TxtCodigo.Text.Trim} - {TxtDescripcion.Text.Trim}", $"{TxtCodigo.Text.Trim} - {TxtDescripcion.Text.Trim}", CveActivoFijo:=CveActivoFijo) Then
|
||||
If Not ErrorGuardar Then
|
||||
If Not ObjContabilidad.AddPrePolizasDetalle(CvePrePoliza, True, TxtValorCompra.Text.ToDecimal, TxtValorCompra.Text.ToDecimal, 68, TxtCodigo.Text.Trim, TxtCodigo.Text.Trim, CveMovimientoAlmacen:=CveMovimientoSalidaInv) Then
|
||||
@@ -3534,12 +3534,12 @@ Partial Class AF_AF
|
||||
|
||||
|
||||
Dim ObjInventario As New ClsInventarios
|
||||
Dim Existencia = ObjInventario.GetExistenciasPS(DdlAFInvPS.SelectedValue.ToEntero, -1, UsuarioActual.CveEmpresa, DdlAFInvAlmacen.SelectedValue.ToEntero, CveSeccionAlmacen:=CveSeccionAlmacen, FechaMovto:=Now.ToDateTime.ToString("yyyy/MM/dd HH:mm"), Serie:=AFInvSerie)
|
||||
Dim Existencia = ObjInventario.GetExistenciasPS(DdlAFInvPS.SelectedValue.ToEntero, -1, UsuarioActual.CveEmpresa, DdlAFInvAlmacen.SelectedValue.ToEntero, CveSeccionAlmacen:=CveSeccionAlmacen, FechaMovto:=NowADS().ToDateTime.ToString("yyyy/MM/dd HH:mm"), Serie:=AFInvSerie)
|
||||
Dim Costo As Decimal = 0
|
||||
If Inv_CveMetodoInventario = 5 Then
|
||||
Costo = ObjInventario.GetCostoPSSerie(DdlAFInvPS.SelectedValue.ToEntero, AFInvSerie, DdlAFInvAlmacen.SelectedValue.ToEntero, CveEmpresaActual)
|
||||
Else
|
||||
Costo = ObjInventario.GetCostoPS(DdlAFInvPS.SelectedValue.ToEntero, 1, DdlAFInvAlmacen.SelectedValue.ToEntero, AFInvSerie, Now)
|
||||
Costo = ObjInventario.GetCostoPS(DdlAFInvPS.SelectedValue.ToEntero, 1, DdlAFInvAlmacen.SelectedValue.ToEntero, AFInvSerie, NowADS())
|
||||
End If
|
||||
|
||||
ObjInventario.Dispose()
|
||||
@@ -3557,7 +3557,7 @@ Partial Class AF_AF
|
||||
|
||||
TxtDescripcion.Text = DdlAFInvPS.SelectedText
|
||||
TxtValorCompra.Text = Costo.FormatoNumero
|
||||
TxtFechaCompra.Text = Now.ToShortDateString
|
||||
TxtFechaCompra.Text = NowADS().ToShortDateString
|
||||
TxtFechaBaja.Text = ""
|
||||
TxtNoSerie.Text = TxtAFInvSerie.Text.Trim
|
||||
|
||||
|
||||
@@ -65,7 +65,7 @@ Partial Class AF_CatAF
|
||||
Grupo = If(Request("GPO") IsNot Nothing AndAlso Request("GPO").ToEntero() > 0, Request("GPO").ToEntero(), -1).ToString.ToEntero
|
||||
CveAgrupador = If(Request("CveAgrupador") IsNot Nothing AndAlso Request("CveAgrupador").ToEntero() > 0, Request("CveAgrupador").ToEntero(), -1).ToEntero
|
||||
|
||||
If ObjAF.GetActivosFijos(-1, UsuarioActual.CveEmpresa, "-1", "-1", IfNull(CveTipoActivoFijo, "-1").ToString.ToEntero, IfNull(CveSubTipoActivoFijo, "-1").ToString.ToEntero, "-1", IfNull(Request("Anio"), Now.Year).ToString.ToEntero,
|
||||
If ObjAF.GetActivosFijos(-1, UsuarioActual.CveEmpresa, "-1", "-1", IfNull(CveTipoActivoFijo, "-1").ToString.ToEntero, IfNull(CveSubTipoActivoFijo, "-1").ToString.ToEntero, "-1", IfNull(Request("Anio"), NowADS().Year).ToString.ToEntero,
|
||||
IfNull(CvePersonalResponsable, "-1").ToString.ToEntero, DdlProyecto.SelectedValue.ToEntero, IfNull(CveSubProyecto, "-1").ToString.ToEntero, IfNull(CveEstadoActivoFijo, "-1").ToString.ToEntero, "", -1) Then
|
||||
If ObjAF.DtResultados.Rows.Count > 0 Then
|
||||
DtActivosFijos = ObjAF.DtResultados
|
||||
@@ -462,7 +462,7 @@ Partial Class AF_CatAF
|
||||
Dim Ruta As String = ""
|
||||
params.Add(New ReportParameter("NombreEmpresa", UsuarioActual.Empresa.Empresa))
|
||||
params.Add(New ReportParameter("UsuarioImprimio", UsuarioActual.Nombre))
|
||||
params.Add(New ReportParameter("FechaImpresion", Now.ToDateTime.ToShortDateString))
|
||||
params.Add(New ReportParameter("FechaImpresion", NowADS().ToDateTime.ToShortDateString))
|
||||
|
||||
params.Add(New ReportParameter("LogoPath", If(Imagen.Exists, $"file://{Imagen.FullName}", "")))
|
||||
|
||||
|
||||
@@ -50,7 +50,7 @@ Partial Class AF_OrdenTrabajoAsignacion
|
||||
CargaCombos()
|
||||
CargaDatos()
|
||||
|
||||
Dim FechaActual As Date = Now
|
||||
Dim FechaActual As Date = NowADS()
|
||||
|
||||
|
||||
'TxtFechaF.Text = $"{FechaActual.Day.ToString("00")}/{FechaActual.Month.ToString("00")}/{FechaActual.Year}"
|
||||
|
||||
@@ -67,7 +67,7 @@ Partial Class AF_RegistroRevision
|
||||
'CargaDatos()
|
||||
|
||||
|
||||
TxtFecha.Text = $"{Now.Day.ToString("00")}/{Now.Month.ToString("00")}/{Now.Year}"
|
||||
TxtFecha.Text = $"{NowADS().Day.ToString("00")}/{NowADS().Month.ToString("00")}/{NowADS().Year}"
|
||||
|
||||
End If
|
||||
End Sub
|
||||
@@ -253,7 +253,7 @@ Partial Class AF_RegistroRevision
|
||||
If Not ErrorProceso Then
|
||||
|
||||
ObjAF.Commit()
|
||||
ExportToExcelG(GvDatos, $"RegistroRevision{Now.ToString("yyyyMMddmmss")}", UsuarioActual, "ReporteRevision", 100, 100, filtros:=$"Filtros {LblSubProyecto.Text}: {DdlSubProyecto.SelectedItem.Text} Fecha: {TxtFecha.Text}")
|
||||
ExportToExcelG(GvDatos, $"RegistroRevision{NowADS().ToString("yyyyMMddmmss")}", UsuarioActual, "ReporteRevision", 100, 100, filtros:=$"Filtros {LblSubProyecto.Text}: {DdlSubProyecto.SelectedItem.Text} Fecha: {TxtFecha.Text}")
|
||||
RegistraScript("$('#ModalDescargaReporte').modal({ backdrop: 'static', keyboard: false });")
|
||||
GvDatos.DataSource = Nothing
|
||||
GvDatos.DataBind()
|
||||
@@ -390,7 +390,7 @@ Partial Class AF_RegistroRevision
|
||||
worksheet.Rows(IndexEndTable + 1).Cells(0).Value = Usuario.Nombre
|
||||
|
||||
worksheet.Rows(IndexEndTable).Cells(2).Value = "Fecha Impresión"
|
||||
worksheet.Rows(IndexEndTable + 1).Cells(2).Value = DateTime.Now.ToString("dd/MM/yyyy")
|
||||
worksheet.Rows(IndexEndTable + 1).Cells(2).Value = NowADS().ToString("dd/MM/yyyy")
|
||||
|
||||
Dim Imagen As New System.IO.FileInfo(String.Format("{0}/Logo.png", Usuario.Empresa.Ruta))
|
||||
|
||||
@@ -420,7 +420,7 @@ Partial Class AF_RegistroRevision
|
||||
|
||||
|
||||
Response.ContentType = "application/force-download"
|
||||
Response.AppendHeader("Content-Disposition", $"attachment;filename=RegistroRevision{Now.ToString("yyyyMMddmmss")}.xlsx")
|
||||
Response.AppendHeader("Content-Disposition", $"attachment;filename=RegistroRevision{NowADS().ToString("yyyyMMddmmss")}.xlsx")
|
||||
Response.BinaryWrite(ReporteBytes)
|
||||
Response.End()
|
||||
|
||||
|
||||
@@ -330,7 +330,7 @@ Partial Class AF_RepAF
|
||||
|
||||
params.Add(New ReportParameter("NombreEmpresa", UsuarioActual.Empresa.Empresa))
|
||||
params.Add(New ReportParameter("UsuarioImprimio", UsuarioActual.Nombre))
|
||||
params.Add(New ReportParameter("FechaImpresion", Now.ToDateTime.ToShortDateString))
|
||||
params.Add(New ReportParameter("FechaImpresion", NowADS().ToDateTime.ToShortDateString))
|
||||
|
||||
params.Add(New ReportParameter("LogoPath", If(Imagen.Exists, $"file://{Imagen.FullName}", "")))
|
||||
ImprimirPDF(String.Format("{0}Formatos\RepAF.rdlc", UsuarioActual.Empresa.Ruta), DtActivosFijos, params, "ReporteActivosFijos", Formato:=Formato)
|
||||
|
||||
@@ -13,7 +13,7 @@ Partial Class AF_RepDepreciacion
|
||||
#End Region
|
||||
Protected Sub Page_Load(sender As Object, e As System.EventArgs) Handles Me.Load
|
||||
If Not Page.IsPostBack Then
|
||||
txtFechaI.Text = DateTime.Now.AddMonths(1).AddDays(-1).ToString("dd/MM/yyyy")
|
||||
txtFechaI.Text = NowADS().AddMonths(1).AddDays(-1).ToString("dd/MM/yyyy")
|
||||
End If
|
||||
End Sub
|
||||
|
||||
|
||||
@@ -50,7 +50,7 @@ Partial Class AF_RepOrdenTrabajo
|
||||
CargaCombos()
|
||||
CargaDatos()
|
||||
|
||||
Dim FechaActual As Date = Now
|
||||
Dim FechaActual As Date = NowADS()
|
||||
|
||||
|
||||
'TxtFechaF.Text = $"{FechaActual.Day.ToString("00")}/{FechaActual.Month.ToString("00")}/{FechaActual.Year}"
|
||||
|
||||
@@ -50,7 +50,7 @@ Partial Class AF_RepRevision
|
||||
CargaCombos()
|
||||
CargaDatos()
|
||||
|
||||
Dim FechaActual As Date = Now
|
||||
Dim FechaActual As Date = NowADS()
|
||||
|
||||
|
||||
TxtFechaF.Text = $"{FechaActual.Day.ToString("00")}/{FechaActual.Month.ToString("00")}/{FechaActual.Year}"
|
||||
|
||||
@@ -69,7 +69,7 @@ Partial Class AF_ResguardoAF
|
||||
CveResguardoPadre = -1
|
||||
CargaDTResguardos()
|
||||
'RESGUARDO
|
||||
TxtFecha.Text = Now.ToShortDateString
|
||||
TxtFecha.Text = NowADS().ToShortDateString
|
||||
CargaAFResguardos()
|
||||
DdlSubProyecto.DataSource = GlobalDTSubProyectosUsuarios(UsuarioActual.CveUsuario, -1, UsuarioActual.CveEmpresa)
|
||||
DdlSubProyecto.DataBind()
|
||||
@@ -85,7 +85,7 @@ Partial Class AF_ResguardoAF
|
||||
|
||||
'TRASPASO
|
||||
|
||||
TxtFechaT.Text = Now.ToShortDateString
|
||||
TxtFechaT.Text = NowADS().ToShortDateString
|
||||
CargaAFResguardosTraslado()
|
||||
DdlSubProyectoT.DataSource = GlobalDTSubProyectos(-1, CveEmpresa:=UsuarioActual.CveEmpresa)
|
||||
DdlSubProyectoT.DataBind()
|
||||
@@ -110,7 +110,7 @@ Partial Class AF_ResguardoAF
|
||||
DdlSubProyectoRTA.DataSource = GlobalDTSubProyectosUsuarios(UsuarioActual.CveUsuario, -1, UsuarioActual.CveEmpresa)
|
||||
DdlSubProyectoRTA.DataBind()
|
||||
DdlSubProyectoRTA.Items.Insert(0, New ListItem("Seleccione", "-1"))
|
||||
TxtFechaR.Text = Now.ToShortDateString
|
||||
TxtFechaR.Text = NowADS().ToShortDateString
|
||||
|
||||
|
||||
'LIBERACION
|
||||
@@ -123,7 +123,7 @@ Partial Class AF_ResguardoAF
|
||||
DdlSubProyectoL.DataBind()
|
||||
DdlSubProyectoL.Items.Insert(0, New ListItem("Seleccione", "-1"))
|
||||
|
||||
TxtFechaRecepcion.Text = Now.ToShortDateString
|
||||
TxtFechaRecepcion.Text = NowADS().ToShortDateString
|
||||
|
||||
|
||||
DdlPersonalR.DataSource = GlobalDTRHPersonal(UsuarioActual.CveEmpresa).FiltraParametros("", "NombreCompleto")
|
||||
@@ -253,7 +253,7 @@ Partial Class AF_ResguardoAF
|
||||
TxtObservacionesR.Text = ""
|
||||
TxtObservacionesRecepcion.Text = ""
|
||||
TxtObservacionesT.Text = ""
|
||||
TxtFecha.Text = Now.ToShortDateString
|
||||
TxtFecha.Text = NowADS().ToShortDateString
|
||||
End Sub
|
||||
#End Region
|
||||
|
||||
@@ -331,7 +331,7 @@ Partial Class AF_ResguardoAF
|
||||
DdlSubProyectoT.SelectedValue = "-1"
|
||||
DdlResponsableT.SelectedValue = "-1"
|
||||
TxtObservacionesT.Text = ""
|
||||
TxtFechaT.Text = Now.ToShortDateString
|
||||
TxtFechaT.Text = NowADS().ToShortDateString
|
||||
UPTraslado.Update()
|
||||
End Sub
|
||||
#End Region
|
||||
@@ -419,7 +419,7 @@ Partial Class AF_ResguardoAF
|
||||
Private Sub LimpiaRT()
|
||||
GvAFTR.DataBind()
|
||||
TxtObservacionesR.Text = ""
|
||||
TxtFechaR.Text = Now.ToShortDateString
|
||||
TxtFechaR.Text = NowADS().ToShortDateString
|
||||
DdlPersonalRT.SelectedValue = "-1"
|
||||
TxtFolioT.Text = ""
|
||||
DdlSubProyectoRT.SelectedValue = "-1"
|
||||
@@ -507,7 +507,7 @@ Partial Class AF_ResguardoAF
|
||||
Private Sub LimpiaRecepcion()
|
||||
GvRecepcion.DataBind()
|
||||
TxtObservacionesRecepcion.Text = ""
|
||||
TxtFechaRecepcion.Text = Now.ToShortDateString
|
||||
TxtFechaRecepcion.Text = NowADS().ToShortDateString
|
||||
DdlPersonalR.SelectedValue = "-1"
|
||||
DdlSubProyectoRL.SelectedValue = "-1"
|
||||
TxtFolioRL.Text = ""
|
||||
|
||||
@@ -449,7 +449,7 @@ Partial Class AF_TipoOrdenTrabajo
|
||||
' worksheet.Rows(IndexEndTable + 1).Cells(0).Value = Usuario.Nombre
|
||||
|
||||
' worksheet.Rows(IndexEndTable).Cells(2).Value = "Fecha Impresión"
|
||||
' worksheet.Rows(IndexEndTable + 1).Cells(2).Value = DateTime.Now.ToString("dd/MM/yyyy")
|
||||
' worksheet.Rows(IndexEndTable + 1).Cells(2).Value = NowADS().ToString("dd/MM/yyyy")
|
||||
|
||||
' Dim Imagen As New System.IO.FileInfo(String.Format("{0}/Logo.png", Usuario.Empresa.Ruta))
|
||||
|
||||
@@ -479,7 +479,7 @@ Partial Class AF_TipoOrdenTrabajo
|
||||
|
||||
|
||||
' Response.ContentType = "application/force-download"
|
||||
' Response.AppendHeader("Content-Disposition", $"attachment;filename=RegistroRevision{Now.ToString("yyyyMMddmmss")}.xlsx")
|
||||
' Response.AppendHeader("Content-Disposition", $"attachment;filename=RegistroRevision{NowADS().ToString("yyyyMMddmmss")}.xlsx")
|
||||
' Response.BinaryWrite(ReporteBytes)
|
||||
' Response.End()
|
||||
|
||||
|
||||
@@ -22,7 +22,7 @@ Partial Class AF_ValesCombustible
|
||||
CargarCombos()
|
||||
CargaFolios()
|
||||
|
||||
TxtFechaVale.Text = DateTime.Now.ToShortDateString
|
||||
TxtFechaVale.Text = NowADS().ToShortDateString
|
||||
BtnActualizar.Visible = False
|
||||
'BtnAplicar.Visible = False
|
||||
|
||||
|
||||
Reference in New Issue
Block a user