Proveedores abonar, Pop IE Compras no enviar correo cuando cuando el tipode transaccion sea Layout o layout por grupos, correciones pago electronico por grupos
This commit is contained in:
@@ -718,13 +718,15 @@ Partial Class Bancos_PagoElectronicoGrupos
|
||||
|
||||
If SBErrores.ToString.Length > 0 Then
|
||||
Mensaje.Append("<a class='Texto' data-toggle='collapse' data-target='#ErroresCuentas'>Errores Cuentas</a><br>")
|
||||
Mensaje.Append("<div id='ErroresCuentas' Class='collapse'")
|
||||
Mensaje.Append("<div id='ErroresCuentas' Class='collapse'>")
|
||||
Mensaje.Append(SBErrores.ToString)
|
||||
Mensaje.Append("</div>")
|
||||
End If
|
||||
|
||||
If NombreArchivoBancomer.Length > 0 Or NombreArchivoInterbancario.Length > 0 Then
|
||||
Alert(Mensaje.ToString, TipoMensaje.MsgInformacion)
|
||||
Else
|
||||
Alert(Mensaje.ToString, TipoMensaje.MsgAdvertencia)
|
||||
End If
|
||||
|
||||
|
||||
@@ -1100,8 +1102,9 @@ Partial Class Bancos_PagoElectronicoGrupos
|
||||
End If
|
||||
|
||||
|
||||
Else
|
||||
|
||||
|
||||
Alert(MENSAJEError.ToString, TipoMensaje.MsgAdvertencia)
|
||||
|
||||
End If
|
||||
|
||||
@@ -2417,7 +2420,7 @@ Partial Class Bancos_PagoElectronicoGrupos
|
||||
TipoMasiva = 2
|
||||
GvProveedores.Columns(0).HeaderText = "Funcionario"
|
||||
CargaFyE()
|
||||
BtnGenerarProveedores.Text = "Generar Layout Alta Funcionarios"
|
||||
BtnGenerarProveedores.Text = "Generar LayoutBtnGenerarPago Alta Funcionarios"
|
||||
End If
|
||||
End Sub
|
||||
Protected Sub BtnGenerarProveedores_Click(sender As Object, e As EventArgs)
|
||||
|
||||
@@ -978,7 +978,10 @@ Partial Class Bancos_PopIECompras
|
||||
|
||||
Case 2
|
||||
LblPagueseA.Text = "Beneficiario"
|
||||
End Select
|
||||
End Select
|
||||
|
||||
|
||||
|
||||
CargaCuentas()
|
||||
CargaCuentasDepositos()
|
||||
UpDatos.Update()
|
||||
@@ -3335,51 +3338,57 @@ Partial Class Bancos_PopIECompras
|
||||
Alert(Str.ToString, TipoMensaje.MsgInformacion, "self.parent.tb_remove();self.parent.location.reload();")
|
||||
End Sub
|
||||
|
||||
Private Sub MandaCorreo(NombreArchivo As String, Correo As String, Optional ConAlerta As Boolean = True)
|
||||
Try
|
||||
Dim Msg As String = ""
|
||||
If NombreArchivo <> "-1" Then '
|
||||
|
||||
Dim ObjMail As New ClsSisMail()
|
||||
Dim RutaXML As String = String.Format("{0}\XML\Pag\{1}.xml", UsuarioActual.Empresa.Ruta, NombreArchivo)
|
||||
Dim RutaPDF As String = String.Format("{0}\PDF\Pag\{1}.pdf", UsuarioActual.Empresa.Ruta, NombreArchivo)
|
||||
|
||||
Dim Cuerpo As String = "Se hace entrega del comprobante de pago"
|
||||
Dim Asunto As String = "Entrega de comprobante de pago"
|
||||
|
||||
If IO.File.Exists(RutaPDF) AndAlso IO.File.Exists(RutaXML) Then
|
||||
|
||||
Dim LSRutasMail As New List(Of ClsSisMail.ArchivoMail)
|
||||
|
||||
LSRutasMail.Add(New ClsSisMail.ArchivoMail With {.Ruta = RutaPDF})
|
||||
LSRutasMail.Add(New ClsSisMail.ArchivoMail With {.Ruta = RutaXML})
|
||||
|
||||
If ObjMail.SendMail(UsuarioActual.Empresa, Correo, Asunto, Cuerpo, "", LSRutasMail) Then
|
||||
|
||||
If ConAlerta Then
|
||||
RegistraScript("$('#ModalDivMail').modal('hide');")
|
||||
Alert("El correo se envió correctamente", TipoMensaje.MsgInformacion)
|
||||
End If
|
||||
|
||||
Else
|
||||
Msg = "No se pudo enviar el correo electrónico."
|
||||
End If
|
||||
|
||||
Else
|
||||
Msg = "No se pudo adjuntar el correo electrónico."
|
||||
End If
|
||||
|
||||
End If
|
||||
|
||||
If ConAlerta AndAlso Msg <> "" Then
|
||||
Alert(Msg, TipoMensaje.MsgError)
|
||||
End If
|
||||
Private Sub MandaCorreo(NombreArchivo As String, Correo As String, Optional ConAlerta As Boolean = True)
|
||||
|
||||
If Not DdlTipoTransaccion.SelectedValue.ToEntero.Contiene(9, 17) Then
|
||||
Try
|
||||
|
||||
Dim Msg As String = ""
|
||||
If NombreArchivo <> "-1" Then '
|
||||
|
||||
Dim ObjMail As New ClsSisMail()
|
||||
Dim RutaXML As String = String.Format("{0}\XML\Pag\{1}.xml", UsuarioActual.Empresa.Ruta, NombreArchivo)
|
||||
Dim RutaPDF As String = String.Format("{0}\PDF\Pag\{1}.pdf", UsuarioActual.Empresa.Ruta, NombreArchivo)
|
||||
|
||||
Dim Cuerpo As String = "Se hace entrega del comprobante de pago"
|
||||
Dim Asunto As String = "Entrega de comprobante de pago"
|
||||
|
||||
If IO.File.Exists(RutaPDF) AndAlso IO.File.Exists(RutaXML) Then
|
||||
|
||||
Dim LSRutasMail As New List(Of ClsSisMail.ArchivoMail)
|
||||
|
||||
LSRutasMail.Add(New ClsSisMail.ArchivoMail With {.Ruta = RutaPDF})
|
||||
LSRutasMail.Add(New ClsSisMail.ArchivoMail With {.Ruta = RutaXML})
|
||||
|
||||
If ObjMail.SendMail(UsuarioActual.Empresa, Correo, Asunto, Cuerpo, "", LSRutasMail) Then
|
||||
|
||||
If ConAlerta Then
|
||||
RegistraScript("$('#ModalDivMail').modal('hide');")
|
||||
Alert("El correo se envió correctamente", TipoMensaje.MsgInformacion)
|
||||
End If
|
||||
|
||||
Else
|
||||
Msg = "No se pudo enviar el correo electrónico."
|
||||
End If
|
||||
|
||||
Else
|
||||
Msg = "No se pudo adjuntar el correo electrónico."
|
||||
End If
|
||||
|
||||
End If
|
||||
|
||||
If ConAlerta AndAlso Msg <> "" Then
|
||||
Alert(Msg, TipoMensaje.MsgError)
|
||||
End If
|
||||
|
||||
|
||||
Catch ex As Exception
|
||||
OnError("Ocurrió error al mandar MAIL", ex)
|
||||
|
||||
End Try
|
||||
End If
|
||||
|
||||
|
||||
Catch ex As Exception
|
||||
OnError("Ocurrió error al mandar MAIL", ex)
|
||||
|
||||
End Try
|
||||
End Sub
|
||||
#End Region
|
||||
|
||||
|
||||
@@ -2377,10 +2377,23 @@ Partial Class Bancos_ProveedoresAbonar
|
||||
'cuando es cheque
|
||||
If DdlTipoTransaccion.SelectedValue = "1" Then
|
||||
ChkAbonoCuenta.Visible = True
|
||||
|
||||
|
||||
Else
|
||||
ChkAbonoCuenta.Visible = False
|
||||
End If
|
||||
|
||||
If DdlTipoTransaccion.SelectedValue.ToEntero.Contiene(9, 17) Then
|
||||
ChkEnviarCorreo.Enabled = False
|
||||
ChkEnviarCorreo.Checked = False
|
||||
Else
|
||||
ChkEnviarCorreo.Enabled = True
|
||||
ChkEnviarCorreo.Checked = True
|
||||
End If
|
||||
|
||||
|
||||
|
||||
|
||||
CargaCuentas(DdlTipoTransaccion.SelectedValue.ToEntero)
|
||||
RecargaCuentasDepositos()
|
||||
|
||||
|
||||
Reference in New Issue
Block a user