From 7111dc47dbbdbe57e2979adb9505de8f4170ec30 Mon Sep 17 00:00:00 2001 From: Rakcsle Supertramp Date: Thu, 28 May 2020 19:59:08 -0700 Subject: [PATCH] No enviar notificaion pago layout y layout grupos --- Bancos/IE.aspx.vb | 30 ++++++++++++++++++---------- Bancos/PagoElectronicoGrupos.aspx.vb | 18 ++++++++++------- Bancos/ProveedoresAbonar.aspx.vb | 28 +++++++++++++++----------- 3 files changed, 46 insertions(+), 30 deletions(-) diff --git a/Bancos/IE.aspx.vb b/Bancos/IE.aspx.vb index b27cfb067..85126f221 100644 --- a/Bancos/IE.aspx.vb +++ b/Bancos/IE.aspx.vb @@ -3350,17 +3350,25 @@ Partial Class Bancos_IE End Sub #Region " NOTIFICACION PAGO " - Private Sub NotificacionPago(CveIE As Integer, CorreoNotificarA As String) - Dim Param As New List(Of String) - - Param.Add(CorreoNotificarA) 'Para - Param.Add("Notificaciones de pago") 'Asunto - Param.Add(GeneraCorreo2(CveIE)) 'Body - Param.Add(CveIE.ToString) 'CveIE - Param.Add(If(ComprobanteIE <> "", String.Format("{0}IE\{1}", UsuarioActual.Empresa.Ruta, ComprobanteIE), "")) 'Archivo Adjunto - - Dim Hilo As New Threading.Thread(AddressOf MandaCorreo) - Hilo.Start(Param) + Private Sub NotificacionPago(CveIE As Integer, CorreoNotificarA As String) + + If Not DdlTipoTransaccion.SelectedValue.ToEntero.Contiene(9, 17) Then + + Dim Param As New List(Of String) + + Param.Add(CorreoNotificarA) 'Para + Param.Add("Notificaciones de pago") 'Asunto + Param.Add(GeneraCorreo2(CveIE)) 'Body + Param.Add(CveIE.ToString) 'CveIE + Param.Add(If(ComprobanteIE <> "", String.Format("{0}IE\{1}", UsuarioActual.Empresa.Ruta, ComprobanteIE), "")) 'Archivo Adjunto + + Dim Hilo As New Threading.Thread(AddressOf MandaCorreo) + Hilo.Start(Param) + + End If + + + End Sub Private Sub MandaCorreo(data As Object) Dim Parametros As List(Of String) = DirectCast(data, List(Of String)) diff --git a/Bancos/PagoElectronicoGrupos.aspx.vb b/Bancos/PagoElectronicoGrupos.aspx.vb index acf4a927d..b7dca6fdc 100644 --- a/Bancos/PagoElectronicoGrupos.aspx.vb +++ b/Bancos/PagoElectronicoGrupos.aspx.vb @@ -966,6 +966,16 @@ Partial Class Bancos_PagoElectronicoGrupos RegistrosPago.Append("PSC") End If + + If drow("CLABEDestino").ToString.Trim.Length.Contiene(10, 18) Then + RegistrosPago.Append(drow("CLABEDestino").ToString.PadLeft(18, CeroRelleno)) + Else + ErrorLayout = True + MENSAJEError.AppendLine("ERROR EN CLABE cuenta destino") + Exit For + End If + + If drow("CLABEOrigen").ToString.Trim.Length.Contiene(10, 18) Then RegistrosPago.Append(drow("CLABEOrigen").ToString.PadLeft(18, CeroRelleno)) @@ -976,13 +986,7 @@ Partial Class Bancos_PagoElectronicoGrupos Exit For End If - If drow("CLABEDestino").ToString.Trim.Length.Contiene(10, 18) Then - RegistrosPago.Append(drow("CLABEDestino").ToString.PadLeft(18, CeroRelleno)) - Else - ErrorLayout = True - MENSAJEError.AppendLine("ERROR EN CLABE cuenta destino") - Exit For - End If + RegistrosPago.Append(drow("Abreviatura").ToString) RegistrosPago.Append(drow("Abonado").ToString.ToDecimal.ToString("0000000000000.00")) diff --git a/Bancos/ProveedoresAbonar.aspx.vb b/Bancos/ProveedoresAbonar.aspx.vb index 4fa513d66..1cc586d2c 100644 --- a/Bancos/ProveedoresAbonar.aspx.vb +++ b/Bancos/ProveedoresAbonar.aspx.vb @@ -2680,22 +2680,26 @@ Partial Class Bancos_ProveedoresAbonar #Region " NOTIFICACION PAGO " Private Sub NotificacionPago(CveIE As Integer, CorreoNotificarA As String) - 'Dim Param As New List(Of String) - 'Param.Add(CorreoNotificarA) 'Para - 'Param.Add("Notificaciones de pago") 'Asunto - 'Param.Add(GeneraCorreo(CveIE)) 'Body - 'Param.Add(CveIE.ToString) 'CveIE - Dim Body As String = GeneraCorreo(CveIE) - Dim Comprobante = If(ComprobanteIE <> "", String.Format("{0}IE\{1}", UsuarioActual.Empresa.Ruta, ComprobanteIE), "") 'Archivo Adjunto + If Not DdlTipoTransaccion.SelectedValue.ToEntero.Contiene(9, 17) Then + 'Dim Param As New List(Of String) - Dim File As Byte() = Nothing - If UsuarioActual.Empresa.Funcionalidad(545).ToEntero > 0 Then - File = NewGeneraBytesCxP(CveProveedor, UsuarioActual.Nombre) + 'Param.Add(CorreoNotificarA) 'Para + 'Param.Add("Notificaciones de pago") 'Asunto + 'Param.Add(GeneraCorreo(CveIE)) 'Body + 'Param.Add(CveIE.ToString) 'CveIE + Dim Body As String = GeneraCorreo(CveIE) + Dim Comprobante = If(ComprobanteIE <> "", String.Format("{0}IE\{1}", UsuarioActual.Empresa.Ruta, ComprobanteIE), "") 'Archivo Adjunto + + Dim File As Byte() = Nothing + If UsuarioActual.Empresa.Funcionalidad(545).ToEntero > 0 Then + File = NewGeneraBytesCxP(CveProveedor, UsuarioActual.Nombre) + End If + + Dim Hilo As New Threading.Thread(Sub() MandaCorreo(CorreoNotificarA, "Notificaciones de pago", Body, CveIE, Comprobante, File)) + Hilo.Start() End If - Dim Hilo As New Threading.Thread(Sub() MandaCorreo(CorreoNotificarA, "Notificaciones de pago", Body, CveIE, Comprobante, File)) - Hilo.Start() End Sub Private Sub MandaCorreo(Para As String, Asunto As String, Body As String, CveIE As Integer, Comprobante As String, File As Byte())