-- cambio en whatsap
corrección emisión
This commit is contained in:
@@ -105,7 +105,7 @@ Partial Class Ventas_PVCobranza
|
|||||||
If Not Page.IsPostBack Then
|
If Not Page.IsPostBack Then
|
||||||
|
|
||||||
|
|
||||||
Dim Arr As New ArrayList
|
'Dim Arr As New ArrayList
|
||||||
'Arr.Add("autorizada")
|
'Arr.Add("autorizada")
|
||||||
'If EnviarNotificacionWhatsApp("526621430964", "solicitud_autorizacion_anticipo_respuesta", Arr) Then
|
'If EnviarNotificacionWhatsApp("526621430964", "solicitud_autorizacion_anticipo_respuesta", Arr) Then
|
||||||
' Alert("bien")
|
' Alert("bien")
|
||||||
@@ -966,7 +966,7 @@ Partial Class Ventas_PVCobranza
|
|||||||
|
|
||||||
ObjFactura.CveVendedor = CveVendedor
|
ObjFactura.CveVendedor = CveVendedor
|
||||||
|
|
||||||
Retorno = ObjFactura.EmitirFactura(False, Transac:=ObjVentas.IniciaTransacSQL(), Modulo:="Cobranza/GuardarVenta", MostrarURL:=True)
|
Retorno = ObjFactura.EmitirFactura(True, Transac:=ObjVentas.IniciaTransacSQL(), Modulo:="Cobranza/GuardarVenta", MostrarURL:=True)
|
||||||
Retorno.Factura = ObjFactura
|
Retorno.Factura = ObjFactura
|
||||||
|
|
||||||
If Retorno IsNot Nothing AndAlso Retorno.CveVenta > 0 Then
|
If Retorno IsNot Nothing AndAlso Retorno.CveVenta > 0 Then
|
||||||
@@ -1876,11 +1876,12 @@ Partial Class Ventas_PVCobranza
|
|||||||
'falta sacar a los usuarios a notificar.
|
'falta sacar a los usuarios a notificar.
|
||||||
Dim gvr As GridViewRow = DirectCast(DirectCast(sender, LinkButton).BindingContainer, GridViewRow)
|
Dim gvr As GridViewRow = DirectCast(DirectCast(sender, LinkButton).BindingContainer, GridViewRow)
|
||||||
Dim Folio As String = gvr.DataKey("Folio")
|
Dim Folio As String = gvr.DataKey("Folio")
|
||||||
|
Dim Importe As Decimal = gvr.FCTextBox(String.Format("TxtAnticipo{0}", gvr.RowIndex)).Text.ToDecimal
|
||||||
Dim dtt As DataTable = Nothing
|
Dim dtt As DataTable = Nothing
|
||||||
|
|
||||||
Dim ObjProceso As New ClsSisProcesos
|
Dim ObjProceso As New ClsSisProcesos
|
||||||
If ObjProceso.GetUsuariosconProceso(379, UsuarioActual.CveEmpresa) Then 'proceso para autorizar
|
If ObjProceso.GetUsuariosconProceso(379, UsuarioActual.CveEmpresa) Then 'proceso para autorizar
|
||||||
dtt = ObjProceso.DtResultados.FiltraParametros("", DistinctColumns:={"CveUsuario", "Celular"})
|
dtt = ObjProceso.DtResultados.FiltraParametros("Celular <> ''", DistinctColumns:={"CveUsuario", "Celular"})
|
||||||
End If
|
End If
|
||||||
ObjProceso.Dispose()
|
ObjProceso.Dispose()
|
||||||
|
|
||||||
@@ -1893,20 +1894,27 @@ Partial Class Ventas_PVCobranza
|
|||||||
|
|
||||||
If dtt IsNot Nothing AndAlso dtt.Rows.Count > 0 Then
|
If dtt IsNot Nothing AndAlso dtt.Rows.Count > 0 Then
|
||||||
For Each dr As DataRow In dtt.Rows
|
For Each dr As DataRow In dtt.Rows
|
||||||
Dim NumeroTelefono = ""
|
Dim NumeroTelefono = "526621430964"
|
||||||
If EsProduccion Then
|
If EsProduccion Then
|
||||||
NumeroTelefono = String.Format("52{0}", dr("Celular").ToString())
|
NumeroTelefono = String.Format("52{0}", dr("Celular").ToString())
|
||||||
End If
|
End If
|
||||||
EnvioMsg = ModExtensiones.EnviarNotificacionWhatsApp2(NumeroTelefono, "", $"Solicitud de activación de anticipo.\\nFolio: {Folio}.\\nCliente: {NombreCliente}.")
|
Dim Arr As New ArrayList
|
||||||
|
Arr.Add(DdlSucursalCorte.SelectedItem.Text)
|
||||||
|
Arr.Add(NombreCliente)
|
||||||
|
Arr.Add(Folio)
|
||||||
|
Arr.Add($"$ {Importe}")
|
||||||
|
EnvioMsg = EnviarNotificacionWhatsAppPlantilla(NumeroTelefono, "solicitud_autorizacion_anticipo", Arr, $"https://grupodiaz.adssistemas.mx.com/Clientes/Clientes.aspx?CveCliente={CveCliente}")
|
||||||
|
'EnvioMsg = ModExtensiones.EnviarNotificacionWhatsApp2(NumeroTelefono, "", $"Solicitud de activación de anticipo.\\nFolio: {Folio}.\\nCliente: {NombreCliente}.")
|
||||||
ClsSisNotificaciones.EnviarAlerta("Solicitud de Anticipo", $"Solicitud de activación de anticipo Folio: {Folio} <br/><a href='/Ventas/Clientes.aspx?CveCliente={CveCliente}&op=ant'>Ir Activar</a>", dr("CveUsuario").ToString, Tipo:=TipoNotificacion.ToastInformacionB)
|
ClsSisNotificaciones.EnviarAlerta("Solicitud de Anticipo", $"Solicitud de activación de anticipo Folio: {Folio} <br/><a href='/Ventas/Clientes.aspx?CveCliente={CveCliente}&op=ant'>Ir Activar</a>", dr("CveUsuario").ToString, Tipo:=TipoNotificacion.ToastInformacionB)
|
||||||
Next
|
Next
|
||||||
|
If EnvioMsg Then
|
||||||
|
Alert("Se envió una solicitud de autorización", TipoMensaje.ToastInformacion)
|
||||||
|
'Else
|
||||||
|
' Alert("No se envió la solicitud de autorización", TipoMensaje.MsgAdvertencia)
|
||||||
|
End If
|
||||||
End If
|
End If
|
||||||
|
|
||||||
If EnvioMsg Then
|
|
||||||
Alert("Se envió una solicitud de autorización")
|
|
||||||
Else
|
|
||||||
Alert("No se envió la solicitud de autorización", TipoMensaje.MsgAdvertencia)
|
|
||||||
End If
|
|
||||||
UpAnticipos.Update()
|
UpAnticipos.Update()
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user