Empresas Zona Horaria
This commit is contained in:
@@ -298,8 +298,8 @@ Partial Class Bancos_PagoElectronicoGrupos
|
||||
CveCuenta = -1
|
||||
TipoMasiva = 1
|
||||
|
||||
txtFechaI.Text = Date.Now.ToShortDateString
|
||||
txtFechaF.Text = Date.Now.ToShortDateString
|
||||
txtFechaI.Text = NowADS().ToShortDateString
|
||||
txtFechaF.Text = NowADS().ToShortDateString
|
||||
|
||||
CargaCuentas()
|
||||
CargaProveedores()
|
||||
@@ -451,7 +451,7 @@ Partial Class Bancos_PagoElectronicoGrupos
|
||||
.Clear()
|
||||
.Buffer = True
|
||||
.ContentType = "textplain"
|
||||
.AddHeader("Content-Disposition", String.Format("attachment;filename={0}{1}.txt", NombreArchivo, Date.Now.ToString("ddMMyyyy")))
|
||||
.AddHeader("Content-Disposition", String.Format("attachment;filename={0}{1}.txt", NombreArchivo, NowADS().ToString("ddMMyyyy")))
|
||||
.Charset = "UTF-8"
|
||||
.ContentEncoding = Encoding.Default
|
||||
.Write(TextoCompleto)
|
||||
@@ -478,12 +478,12 @@ Partial Class Bancos_PagoElectronicoGrupos
|
||||
|
||||
DirectoryExistsCreate(String.Format("{0}Layout", UsuarioActual.Empresa.Ruta))
|
||||
|
||||
NombreArchivo = String.Format("{2}{1}{0}.txt", UsuarioActual.CveUsuario, Date.Now.ToString("yyyyMMdd-HH-mm-ss"), If(Tipo = 1, "LAYOUTPAGO", "LAYOUTALTA"))
|
||||
NombreArchivo = String.Format("{2}{1}{0}.txt", UsuarioActual.CveUsuario, NowADS().ToString("yyyyMMdd-HH-mm-ss"), If(Tipo = 1, "LAYOUTPAGO", "LAYOUTALTA"))
|
||||
|
||||
If Tipo = 1 Then
|
||||
NombreArchivo = String.Format("{2}{1}{0}.txt", UsuarioActual.CveUsuario, Date.Now.ToString("yyyyMMdd-HH-mm-ss"), "LAYOUTPAGO")
|
||||
NombreArchivo = String.Format("{2}{1}{0}.txt", UsuarioActual.CveUsuario, NowADS().ToString("yyyyMMdd-HH-mm-ss"), "LAYOUTPAGO")
|
||||
Else
|
||||
NombreArchivo = String.Format("{2}{1}{0}{3}.txt", UsuarioActual.CveUsuario, Date.Now.ToString("yyyyMMdd-HH-mm-ss"), "LAYOUTALTA", If(MismoBanco, "BANCOMER", "INTERBANCARIO"))
|
||||
NombreArchivo = String.Format("{2}{1}{0}{3}.txt", UsuarioActual.CveUsuario, NowADS().ToString("yyyyMMdd-HH-mm-ss"), "LAYOUTALTA", If(MismoBanco, "BANCOMER", "INTERBANCARIO"))
|
||||
End If
|
||||
|
||||
If NombreArchivoEnviado.Length > 0 Then
|
||||
@@ -600,7 +600,7 @@ Partial Class Bancos_PagoElectronicoGrupos
|
||||
e.Row.FCLabel("LblArchivo").Text = e.Row.DataKey("Archivo")
|
||||
|
||||
'Si la fecha de generacion del archivo es diferente de hoy activamos el boton REGENERAR
|
||||
'If e.Row.DBCampo("Fecha").ToDate.ToShortDateString <> Date.Now.ToShortDateString Then
|
||||
'If e.Row.DBCampo("Fecha").ToDate.ToShortDateString <> NowADS().ToShortDateString Then
|
||||
' e.Row.FCLinkButton("LBRegenerar").Visible = True
|
||||
'End If
|
||||
If DTEnviadas.MAX("FueConciliado", String.Format("CveLayoutEnvio = {0}", e.Row.DBCampo("CveLayoutEnvio"))).ToEntero > 0 Then
|
||||
@@ -1029,7 +1029,7 @@ Partial Class Bancos_PagoElectronicoGrupos
|
||||
|
||||
' 'Llenamos en blanco datos de otros bancos
|
||||
' 'Campos 8-17 del detalle --- 64 de otros bancos y 45 para FILLER --- Fecha de Alta
|
||||
' DetalleTexto &= String.Format("{0}{1}", Vacio.PadLeft(109), DateTime.Now().ToString("yyyy-MM-dd"))
|
||||
' DetalleTexto &= String.Format("{0}{1}", Vacio.PadLeft(109), NowADS().ToString("yyyy-MM-dd"))
|
||||
|
||||
|
||||
' 'Otros Bancos NACIONAL!!
|
||||
@@ -1043,7 +1043,7 @@ Partial Class Bancos_PagoElectronicoGrupos
|
||||
|
||||
' 'Llenamos datos de otros bancos
|
||||
' 'Campos 8- 17 del detalle --- 44 de otros bancos --- 20 de internacional --- 45 Filler -- Fecha de Alta
|
||||
' DetalleTexto &= String.Format("{0}40{1}{2}{3}{4}{5}", DTPendienteActual(0)("Abreviatura").ToString, DTPendienteActual(0)("CLABE").ToString.PadLeft(35, PadCeros), DTPendienteActual(0)("CLABE").ToString.Substring(0, 3).PadLeft(4, PadCeros), Vacio.PadRight(20), Vacio.PadRight(45), DateTime.Now().ToString("yyyy-MM-dd"))
|
||||
' DetalleTexto &= String.Format("{0}40{1}{2}{3}{4}{5}", DTPendienteActual(0)("Abreviatura").ToString, DTPendienteActual(0)("CLABE").ToString.PadLeft(35, PadCeros), DTPendienteActual(0)("CLABE").ToString.Substring(0, 3).PadLeft(4, PadCeros), Vacio.PadRight(20), Vacio.PadRight(45), NowADS().ToString("yyyy-MM-dd"))
|
||||
' End If
|
||||
|
||||
' 'Llenamos datos de Tipo de Persona - Fisica o Moral
|
||||
@@ -1157,14 +1157,14 @@ Partial Class Bancos_PagoElectronicoGrupos
|
||||
'''''' LLENADO HEADER
|
||||
Dim convenio As String = DTPendienteActual(0)("ConvenioPagoElectronico").ToString
|
||||
'Campos #1-4 del Header
|
||||
HeaderTexto = String.Format("H{0}{1}GRUPO01 ", convenio.PadLeft(9, PadCeros), DateTime.Now().ToString("yyyy-MM-dd"))
|
||||
HeaderTexto = String.Format("H{0}{1}GRUPO01 ", convenio.PadLeft(9, PadCeros), NowADS().ToString("yyyy-MM-dd"))
|
||||
'Campo #5 del Header
|
||||
|
||||
Dim IdentificadoUsuario As String = UsuarioActual.Usuario.Replace(" ", "").Replace(".", "").Replace("@", "").Replace("/", "").ToUpper.Trim
|
||||
IdentificadoUsuario = If(IdentificadoUsuario.Length > 12, IdentificadoUsuario.Substring(0, 12), IdentificadoUsuario)
|
||||
' Dim Identificado As String = String.Format("{0}{1}", UsuarioActual.Usuario, DateTime.Now().ToString("yyyyMMdd")))
|
||||
' Dim Identificado As String = String.Format("{0}{1}", UsuarioActual.Usuario, NowADS().ToString("yyyyMMdd")))
|
||||
|
||||
HeaderTexto &= String.Format("{0}{1}", IdentificadoUsuario, DateTime.Now().ToString("yyyyMMdd")).PadRight(20)
|
||||
HeaderTexto &= String.Format("{0}{1}", IdentificadoUsuario, NowADS().ToString("yyyyMMdd")).PadRight(20)
|
||||
'Campos #6-8 del Header
|
||||
HeaderTexto &= String.Format("00").PadRight(586)
|
||||
Dim HeaderLength = HeaderTexto.Length
|
||||
@@ -1422,7 +1422,7 @@ Partial Class Bancos_PagoElectronicoGrupos
|
||||
ObjBancos.IniciaTransacSQL()
|
||||
|
||||
|
||||
Dim CveLayoutEnvio = ObjBancos.AddLayoutEnvios(NombreArchivo, Date.Now, CveCuenta, PorGrupos:=True)
|
||||
Dim CveLayoutEnvio = ObjBancos.AddLayoutEnvios(NombreArchivo, NowADS(), CveCuenta, PorGrupos:=True)
|
||||
|
||||
If CveLayoutEnvio > 0 Then
|
||||
For Each dr As DataRow In DTPendientesTemp.Rows
|
||||
@@ -1558,7 +1558,7 @@ Partial Class Bancos_PagoElectronicoGrupos
|
||||
|
||||
' 'ACTUALIZA FECHADOCUMENTO DEL IE
|
||||
' 'If CveBLE > 0 Then
|
||||
' ' ObjBancos.UpdateBancos_IE(Date.Now, Date.Now, DTPendienteActual(0)("CveIE").ToString.ToEntero)
|
||||
' ' ObjBancos.UpdateBancos_IE(NowADS(), NowADS(), DTPendienteActual(0)("CveIE").ToString.ToEntero)
|
||||
' 'End If
|
||||
|
||||
' If TotalDetalles > 0 Then
|
||||
@@ -1574,14 +1574,14 @@ Partial Class Bancos_PagoElectronicoGrupos
|
||||
|
||||
' If CveBLE > 0 Then
|
||||
' 'ACTUALIZAMOS EL ENVIO SI ES REGENERACION
|
||||
' If Not ObjBancos.UpdateLayoutEnvios(CveBLE, Date.Now) Then
|
||||
' If Not ObjBancos.UpdateLayoutEnvios(CveBLE, NowADS()) Then
|
||||
' ErrorLayout = True
|
||||
' End If
|
||||
|
||||
' 'GUARDAMOS EL ENVIO SI NO ES REGENERACION
|
||||
' Else
|
||||
|
||||
' Dim CveLayoutEnvio = ObjBancos.AddLayoutEnvios(NombreArchivo, Date.Now, CveCuenta)
|
||||
' Dim CveLayoutEnvio = ObjBancos.AddLayoutEnvios(NombreArchivo, NowADS(), CveCuenta)
|
||||
|
||||
' If CveLayoutEnvio > 0 Then
|
||||
' For Each dr As DataRow In DTTemp.Rows
|
||||
@@ -1674,7 +1674,7 @@ Partial Class Bancos_PagoElectronicoGrupos
|
||||
'Correo = If(Correo.Length > 0, Correo.ToUpper.PadRight(50), Vacio.PadRight(50))
|
||||
|
||||
'Campos 24-50 del Detalle 0 1 2 3 4 5 6 7 8 9
|
||||
DetalleTexto &= String.Format("{0}{1}FA{2}{3}01{4}N{5}{6}{7}{7}{7}{6}N {7}700{8}{9}{7}", Divisa, Vacio.PadLeft(20), Importe.FormatoNumero.Replace(",", "").Replace(".", "").PadLeft(15, PadCeros), Vacio.PadRight(15, PadCeros), Correo, Vacio.PadRight(12, PadCeros), DateTime.Now.ToString("yyyy-MM-dd"), "0001-01-01", Observaciones.PadRight(700), Vacio.PadRight(52))
|
||||
DetalleTexto &= String.Format("{0}{1}FA{2}{3}01{4}N{5}{6}{7}{7}{7}{6}N {7}700{8}{9}{7}", Divisa, Vacio.PadLeft(20), Importe.FormatoNumero.Replace(",", "").Replace(".", "").PadLeft(15, PadCeros), Vacio.PadRight(15, PadCeros), Correo, Vacio.PadRight(12, PadCeros), NowADS().ToString("yyyy-MM-dd"), "0001-01-01", Observaciones.PadRight(700), Vacio.PadRight(52))
|
||||
TotalAcumulado += Importe.ToDouble
|
||||
|
||||
|
||||
@@ -1703,9 +1703,9 @@ Partial Class Bancos_PagoElectronicoGrupos
|
||||
|
||||
'''''' LLENADO HEADER
|
||||
'Campos #1-4 del Header
|
||||
HeaderTexto = String.Format("H{0}{1}01", convenio.PadLeft(9, PadCeros), DateTime.Now().ToString("yyyy-MM-dd"))
|
||||
HeaderTexto = String.Format("H{0}{1}01", convenio.PadLeft(9, PadCeros), NowADS().ToString("yyyy-MM-dd"))
|
||||
'Campo #5 del Header
|
||||
HeaderTexto &= String.Format("P{0}{1}", DateTime.Now().ToString("s").Replace("-", "").Replace(":", ""), Vacio.PadRight(14))
|
||||
HeaderTexto &= String.Format("P{0}{1}", NowADS().ToString("s").Replace("-", "").Replace(":", ""), Vacio.PadRight(14))
|
||||
'Campos #6-11 del Header
|
||||
HeaderTexto &= String.Format("00").PadRight(1314)
|
||||
|
||||
@@ -2332,7 +2332,7 @@ Partial Class Bancos_PagoElectronicoGrupos
|
||||
params.Add(New ReportParameter("Empresa", UsuarioActual.Empresa.Empresa))
|
||||
params.Add(New ReportParameter("Direccion", UsuarioActual.Empresa.Direccion))
|
||||
params.Add(New ReportParameter("RFC", UsuarioActual.Empresa.RFC))
|
||||
params.Add(New ReportParameter("FechaImpresion", DateTime.Now.ToString("dd/MM/yyyy")))
|
||||
params.Add(New ReportParameter("FechaImpresion", NowADS().ToString("dd/MM/yyyy")))
|
||||
|
||||
|
||||
ImprimirPDF("Empresas/Grales/Formatos/LayoutAltaProveedor.rdlc", DtAlta, params, "LayoutAltaProveedor", RDSName:="DsPagoElectronico")
|
||||
@@ -2360,7 +2360,7 @@ Partial Class Bancos_PagoElectronicoGrupos
|
||||
params.Add(New ReportParameter("Empresa", UsuarioActual.Empresa.Empresa))
|
||||
params.Add(New ReportParameter("Direccion", UsuarioActual.Empresa.Direccion))
|
||||
params.Add(New ReportParameter("RFC", UsuarioActual.Empresa.RFC))
|
||||
params.Add(New ReportParameter("FechaImpresion", DateTime.Now.ToString("dd/MM/yyyy")))
|
||||
params.Add(New ReportParameter("FechaImpresion", NowADS().ToString("dd/MM/yyyy")))
|
||||
ImprimirPDF("Empresas/Grales/Formatos/LayoutAltaProveedor.rdlc", DtAlta, params, "LayoutAltaProveedor", RDSName:="DsPagoElectronico")
|
||||
End If
|
||||
|
||||
@@ -2394,7 +2394,7 @@ Partial Class Bancos_PagoElectronicoGrupos
|
||||
params.Add(New ReportParameter("NombreEmpresa", UsuarioActual.Empresa.Empresa))
|
||||
params.Add(New ReportParameter("Direccion", UsuarioActual.Empresa.Direccion))
|
||||
params.Add(New ReportParameter("RFC", UsuarioActual.Empresa.RFC))
|
||||
params.Add(New ReportParameter("FechaImpresion", DateTime.Now.ToString("dd/MM/yyyy")))
|
||||
params.Add(New ReportParameter("FechaImpresion", NowADS().ToString("dd/MM/yyyy")))
|
||||
|
||||
params.Add(New ReportParameter("UsuarioImprimio", UsuarioActual.Nombre))
|
||||
params.Add(New ReportParameter("Titulo", "Reporte Pago Proveedor Layout Grupos"))
|
||||
@@ -2777,7 +2777,7 @@ Partial Class Bancos_PagoElectronicoGrupos
|
||||
ObjAC.IniciaTransacSQL()
|
||||
End If
|
||||
|
||||
Dim FechaCancelacion As Date = Now
|
||||
Dim FechaCancelacion As Date = NowADS()
|
||||
|
||||
Dim ErrorCancelar = False
|
||||
Dim MensajeError = ""
|
||||
@@ -2990,7 +2990,7 @@ Partial Class Bancos_PagoElectronicoGrupos
|
||||
params.Add(New ReportParameter("NombreEmpresa", UsuarioActual.Empresa.Empresa))
|
||||
params.Add(New ReportParameter("Direccion", UsuarioActual.Empresa.Direccion))
|
||||
params.Add(New ReportParameter("RFC", UsuarioActual.Empresa.RFC))
|
||||
params.Add(New ReportParameter("FechaImpresion", DateTime.Now.ToString("dd/MM/yyyy")))
|
||||
params.Add(New ReportParameter("FechaImpresion", NowADS().ToString("dd/MM/yyyy")))
|
||||
|
||||
params.Add(New ReportParameter("UsuarioImprimio", UsuarioActual.Nombre))
|
||||
params.Add(New ReportParameter("Titulo", "Reporte Pago Proveedor Layout"))
|
||||
|
||||
Reference in New Issue
Block a user