EMD - solicitar anticipo de OC, error, y permite duplicar la solicitud
This commit is contained in:
@@ -5464,28 +5464,46 @@ Partial Class OC_OC
|
||||
End If
|
||||
|
||||
End Sub
|
||||
|
||||
Private Sub EnviaCorreoSolicitudAnticipo(CveEvento As Integer, Optional ImporteAnticipo As Decimal = 0)
|
||||
Dim Param As New List(Of String)
|
||||
|
||||
Dim DtPara As DataTable = GlobalDTUsuarios(DdlSAUsuario.SelectedValue.ToString.ToEntero, CveEmpresaActual)
|
||||
|
||||
If DdlMetodoPago.SelectedValue.ToEntero = 0 Then
|
||||
|
||||
DtPara = GlobalDTUsuarios(DdlSAUsuarioContado.SelectedValue.ToString.ToEntero, CveEmpresaActual)
|
||||
|
||||
If DtPara Is Nothing Then
|
||||
DtPara = GlobalDTUsuarios(DdlSAUsuario.SelectedValue.ToString.ToEntero, CveEmpresaActual)
|
||||
End If
|
||||
|
||||
End If
|
||||
|
||||
Param.Add(DtPara.Rows(0)("Correo").ToString()) 'Para
|
||||
Param.Add("Solicitud de anticipo de Orden de Compra") 'Asunto
|
||||
Try
|
||||
If DtPara IsNot Nothing AndAlso DtPara.Rows.Count > 0 Then
|
||||
|
||||
Param.Add(DtPara.Rows(0)("Correo").ToString()) 'Para
|
||||
Param.Add("Solicitud de anticipo de Orden de Compra") 'Asunto
|
||||
|
||||
|
||||
If ImporteAnticipo = 0 Then
|
||||
ImporteAnticipo = TxtSAImporte.Text.ToDecimal
|
||||
End If
|
||||
If ImporteAnticipo = 0 Then
|
||||
ImporteAnticipo = TxtSAImporte.Text.ToDecimal
|
||||
End If
|
||||
|
||||
|
||||
Param.Add(GeneraCorreoAnticipo(lblFolio.Text, DtPara.Rows(0)("Nombre").ToString(), String.Format("http://sig.adssistemas.mx/OI/EventoDetalle.aspx?CveTipoEvento=1&CveEvento={0}", CveEvento), ImporteAnticipo.ToString, DdlProveedores.SelectedText))
|
||||
Param.Add(String.Format("{0}PDF\OC-{1}.pdf", UsuarioActual.Empresa.Ruta, CveOrdenCompra))
|
||||
Dim Hilo As New Threading.Thread(AddressOf MandaCorreoAnticipo)
|
||||
Hilo.Start(Param)
|
||||
Param.Add(GeneraCorreoAnticipo(lblFolio.Text, DtPara.Rows(0)("Nombre").ToString(), String.Format("http://sig.adssistemas.mx/OI/EventoDetalle.aspx?CveTipoEvento=1&CveEvento={0}", CveEvento), ImporteAnticipo.ToString, DdlProveedores.SelectedText))
|
||||
Param.Add(String.Format("{0}PDF\OC-{1}.pdf", UsuarioActual.Empresa.Ruta, CveOrdenCompra))
|
||||
Dim Hilo As New Threading.Thread(AddressOf MandaCorreoAnticipo)
|
||||
Hilo.Start(Param)
|
||||
|
||||
End If
|
||||
Catch ex As Exception
|
||||
|
||||
End Try
|
||||
|
||||
End Sub
|
||||
|
||||
Private Sub EnviaCorreoSolicitudAnticipoCancelado()
|
||||
'If Not CveIEAnticipo > 0 Then 'SI NO SE HA REALIZADO EL ANTICIPO NOTIFICA QUE SE HA CANCELADO
|
||||
Dim ObjOC As New ClsOC
|
||||
|
||||
Reference in New Issue
Block a user