TareasProgramadas Envio de estado cuenta, compras cvetipoOperacion, , reembolsos filtror rwo acumulado, ajkustes carta porte, OC carga desde excel filtro rows vacios, personal cuentas deposito
This commit is contained in:
@@ -108,7 +108,9 @@ Public Class TareasProgramadas : Implements IHttpHandler, IReadOnlySessionState
|
||||
context.Response.Write(retorno)
|
||||
Case "EstadosCuenta"
|
||||
'CargaEstadosCuenta(context, 119, 227774)
|
||||
CargaEstadosCuenta(context, 119, -1, FechaEnvio, FechaActual)
|
||||
'CargaEstadosCuenta(context, 119, -1, FechaEnvio, FechaActual)
|
||||
Dim tCveEmpresa As Integer = context.Request("CveEmpresa").ToString.ToEntero
|
||||
CargaEstadosCuenta(context, tCveEmpresa, -1, FechaEnvio, FechaActual)
|
||||
|
||||
Case "ScoreCard"
|
||||
CargaScoreCard(context, 140, FechaEnvio)
|
||||
@@ -354,6 +356,9 @@ Public Class TareasProgramadas : Implements IHttpHandler, IReadOnlySessionState
|
||||
|
||||
#Region "E S T A D O S D E C U E N T A"
|
||||
Private Sub CargaEstadosCuenta(ByVal context As HttpContext, pCveEmpresa As Integer, pCveCliente As Integer, FechaEnvio As DateTime, FechaActual As DateTime)
|
||||
|
||||
Dim Usuario As Usuario = ValidaUsuarioSistema(100, pCveEmpresa)
|
||||
|
||||
Dim Retorno As New JArray()
|
||||
Dim DtEmpresas As DataTable = Nothing
|
||||
Using ObjEmpresas As New ClsSisEmpresas()
|
||||
@@ -364,7 +369,7 @@ Public Class TareasProgramadas : Implements IHttpHandler, IReadOnlySessionState
|
||||
|
||||
If DtEmpresas IsNot Nothing Then
|
||||
For Each Row As DataRow In DtEmpresas.Rows
|
||||
Dim Usuario As Usuario = ValidaUsuarioSistema(100, Row("CveEmpresa").ToString().ToEntero())
|
||||
'Dim Usuario As Usuario = ValidaUsuarioSistema(100, Row("CveEmpresa").ToString().ToEntero())
|
||||
Dim obj As JObject = EjecutarEnvioEstadoCuenta(Usuario, FechaEnvio, FechaActual, pCveCliente:=pCveCliente)
|
||||
|
||||
Retorno.Add(obj)
|
||||
@@ -499,7 +504,9 @@ Public Class TareasProgramadas : Implements IHttpHandler, IReadOnlySessionState
|
||||
|
||||
Dim Envio As Boolean = False
|
||||
If Not String.IsNullOrEmpty(Correo) Then
|
||||
'Correo = "oscar.irigoyen@adssistemas.mx"
|
||||
Envio = EnviarEstadoCuenta(UsuarioActual, Correo, Cliente)
|
||||
GuardaLog($"Log envio Estados Cuenta correo {If(Envio, "Enviado", "Error")} CveCliente {CveCliente} ")
|
||||
End If
|
||||
|
||||
If Envio Then
|
||||
@@ -522,6 +529,7 @@ Public Class TareasProgramadas : Implements IHttpHandler, IReadOnlySessionState
|
||||
New JProperty("Cliente", Cliente.Nombre)
|
||||
))
|
||||
End If
|
||||
|
||||
End If
|
||||
Next
|
||||
End If
|
||||
@@ -857,7 +865,10 @@ Public Class TareasProgramadas : Implements IHttpHandler, IReadOnlySessionState
|
||||
If sw.Elapsed.TotalSeconds > 10 Then
|
||||
GuardaLog($"Reporte:{RutaReporte} | Tiempo Renderizado Milisegundos: {sw.ElapsedMilliseconds},Total Segundos: {sw.Elapsed.TotalSeconds} ")
|
||||
End If
|
||||
If MR IsNot Nothing Then MR.Dispose()
|
||||
If MR IsNot Nothing Then
|
||||
'MR.Close()
|
||||
MR.Dispose()
|
||||
End If
|
||||
Return Bytes
|
||||
End Function
|
||||
|
||||
|
||||
Reference in New Issue
Block a user