+
+
diff --git a/Sistemas/PopUpAddUsuario.aspx.vb b/Sistemas/PopUpAddUsuario.aspx.vb
index b48a4fd17..1ec6d9763 100644
--- a/Sistemas/PopUpAddUsuario.aspx.vb
+++ b/Sistemas/PopUpAddUsuario.aspx.vb
@@ -1,7 +1,7 @@
Imports Extensiones
Imports System.Data
Partial Class Sistemas_PopUpAddUsuario
- Inherits ClsPaginas
+ Inherits ClsPaginas
#Region "PROPIEDADES"
Public Property CveCliente As Integer
Get
@@ -51,7 +51,7 @@ Partial Class Sistemas_PopUpAddUsuario
Set(value As Integer)
ViewState("CvePlataforma") = value
End Set
- End Property
+ End Property
#End Region
Protected Sub Page_Load(sender As Object, e As EventArgs) Handles Me.Load
If Not Page.IsPostBack Then
@@ -164,8 +164,14 @@ Partial Class Sistemas_PopUpAddUsuario
If ObjUsuario.UpdateUsuario(LtlUsuario.Text, TxtNombre.Text, -1, TxtEmail.Text, -1, -1, True, True, -1, CveUsuario, -1, -1) Then
Alert("La contraseña se reestableció correctamente a la contraseña por default '-acceso-'.")
Dim Liga As String = $"{Context.Request.Url.OriginalString.Substring(0, Context.Request.Url.OriginalString.Length - Context.Request.Url.PathAndQuery.Length)}/LogIn.aspx"
- Dim LigaActivar As String = Liga & "?p=" & Encripta("CveU=" & CveUsuario & "&Clave=" & "-acceso-" & "&Opcion=Activar&Hora=" & DateTime.Now.Ticks& & "&CveE=" & UsuarioActual.CveEmpresa)
- EnviaCorreo(Liga, LigaActivar)
+ Dim LigaActivar As String = Liga & "?p=" & Encripta("CveU=" & CveUsuario & "&Clave=" & "-acceso-" & "&Opcion=Activar&Hora=" & DateTime.Now.Ticks& & "&CveE=" & UsuarioActual.CveEmpresa)
+
+ If UsuarioActual.Empresa.CvePlataforma = 3 Then
+ EnviaCorreoGPS(Liga, LigaActivar)
+ Else
+ EnviaCorreo(Liga, LigaActivar)
+ End If
+
End If
End If
ObjUsuario.Dispose()
@@ -251,8 +257,14 @@ Partial Class Sistemas_PopUpAddUsuario
'ENVIA CORREO
If CveUsuario > 0 Then
Dim Liga As String = $"{Context.Request.Url.OriginalString.Substring(0, Context.Request.Url.OriginalString.Length - Context.Request.Url.PathAndQuery.Length)}/LogIn.aspx"
- Dim LigaActivar As String = Liga & "?p=" & Encripta("CveU=" & CveUsuario & "&Clave=" & "-acceso-" & "&Opcion=Activar&Hora=" & DateTime.Now.Ticks& & "&CveE=" & UsuarioActual.CveEmpresa)
- Mensaje = EnviaCorreo(Liga, LigaActivar)
+ Dim LigaActivar As String = Liga & "?p=" & Encripta("CveU=" & CveUsuario & "&Clave=" & "-acceso-" & "&Opcion=Activar&Hora=" & DateTime.Now.Ticks& & "&CveE=" & UsuarioActual.CveEmpresa)
+
+ If UsuarioActual.Empresa.CvePlataforma = 3 Then
+ Mensaje = EnviaCorreoGPS(Liga, LigaActivar)
+ Else
+ Mensaje = EnviaCorreo(Liga, LigaActivar)
+ End If
+
Else
HuboError = True
End If
@@ -651,16 +663,139 @@ Partial Class Sistemas_PopUpAddUsuario
OnError("Ocurrió error al mandar MAIL", ex)
End Try
+ Return Retorno
+ End Function
+
+ Private Function EnviaCorreoGPS(Liga As String, LigaActivar As String) As String
+ Dim Retorno As String = ""
+ Try
+ 'Dim URL As String = "https://gps.signalsgps.com/" + LigaActivar
+
+ Dim Para = TxtEmail.Text.Trim
+ Dim Asunto = "ACCESO A SIGNALS GPS"
+
+ 'Dim SBBody As New StringBuilder
+ ''Linia de estilos
+ 'SBBody.Append("")
+ ''incio Cuerpo del correo
+ 'SBBody.Append("
")
+ 'SBBody.Append("
")
+ 'SBBody.Append("
")
+ 'SBBody.Append("ALTA DE CUENTA")
+ 'SBBody.Append("
")
+ 'SBBody.Append("
")
+ 'SBBody.AppendFormat("
Estimado {0}:", TxtNombre.Text.ToUpper)
+ 'SBBody.AppendFormat("El presente correo es para informarle que se le han asignado los siguientes datos para el acceso a la Plataforma de:
{0}", UsuarioActual.Empresa.Empresa)
+ 'SBBody.Append("
")
+ 'SBBody.Append("
Datos de usuario
")
+ 'SBBody.Append("
")
+ 'SBBody.Append("
")
+ 'SBBody.Append("
")
+ 'SBBody.Append("
Usuario
")
+ 'SBBody.AppendFormat("
{0}
", TxtEmail.Text)
+ 'SBBody.Append("
")
+ 'SBBody.Append("
")
+ 'SBBody.Append("
Accesé al sistema dando click a la liga y estableciendo su contraseña
")
+ 'SBBody.AppendFormat("
", LigaActivar)
+ 'SBBody.Append("
")
+ 'SBBody.Append("
")
+ 'SBBody.Append("
")
+ 'SBBody.Append("
")
+ 'SBBody.Append("Para Activar su cuenta debera cambiar su contraseña.
")
+ 'SBBody.Append("
")
+ 'SBBody.Append("Nota Favor de NO responder este correo. ")
+ 'SBBody.Append("
")
+ 'SBBody.AppendFormat("

ADSistemas
", URL)
+ 'SBBody.Append("
")
+ 'SBBody.Append("
")
+
+ Dim SBBody As New StringBuilder()
+
+ SBBody.Append("
")
+ SBBody.Append("
")
+ SBBody.Append("
")
+ SBBody.Append(" ")
+ SBBody.Append(" ")
+ SBBody.Append(" | | ")
+ SBBody.Append(" ")
+ SBBody.Append(" DATOS DE ACCESO ")
+ SBBody.Append(" ")
+ SBBody.Append(" | ")
+ SBBody.Append("
")
+ SBBody.Append(" ")
+ SBBody.Append("
")
+ SBBody.Append("
")
+ SBBody.AppendFormat("
Estimado / a {0}:
", TxtNombre.Text)
+ SBBody.Append("
El presente correo es para informarle que se le han asignado los siguentes datos para el acceso a la plataforma SIGNALS GPS
")
+ SBBody.Append("
")
+ SBBody.Append(" ")
+ SBBody.Append(" ")
+ SBBody.Append(" | ")
+ SBBody.Append(" USUARIO ASIGNADO ")
+ SBBody.Append(" | ")
+ SBBody.Append("
")
+ SBBody.Append(" ")
+ SBBody.Append(" | ")
+ SBBody.Append(" Usuario: ")
+ SBBody.AppendFormat(" {0} ", TxtEmail.Text)
+ SBBody.Append(" | ")
+ SBBody.Append("
")
+ SBBody.Append(" ")
+ SBBody.Append(" | ")
+ SBBody.Append(" Contraseña: ")
+ SBBody.Append(" -acceso- ")
+ SBBody.Append(" | ")
+ SBBody.Append("
")
+ SBBody.Append(" ")
+ SBBody.Append(" | ")
+ SBBody.AppendFormat(" INGRESAR A SIGNALS GPS ", LigaActivar)
+ SBBody.Append(" | ")
+ SBBody.Append("
")
+ SBBody.Append("")
+ SBBody.Append("
")
+ SBBody.Append("
")
+ SBBody.Append("
Favor de NO responder este correo.
")
+ SBBody.Append("
")
+ SBBody.Append("
")
+ SBBody.Append("
")
+ 'Termino Cuerpo del correo
+
+ Dim Hilo As New System.Threading.Thread(Sub() MandaCorreo(Asunto, Para, SBBody.ToString))
+ Hilo.Start()
+
+ 'Dim JSBTN As String = ""
+ 'If UsuarioActual.CveCliente > 0 Then
+ ' JSBTN = $"document.location.href=""javascript: Ir2({CveCliente})"";"
+ 'ElseIf CveCliente > 0 Then
+ ' JSBTN = $"document.location.href=""javascript:Ir({CveCliente})"";"
+ 'End If
+ 'If UsuarioActual.Empresa.CvePlataforma = 3 Then
+ ' Alert("El correo se ha enviado correctamente a: " + TxtEmail.Text + ".", TipoMensaje.MsgInformacion, JSBTN)
+ 'End If
+
+ Retorno = $"El correo se ha enviado correctamente a:
{TxtEmail.Text}."
+
+ Catch ex As Exception
+ OnError("Ocurrió error al mandar MAIL", ex)
+ End Try
+
Return Retorno
End Function
Private Sub MandaCorreo(Asunto As String, Para As String, Body As String)
Dim a As String = String.Format("{0} -- {1} ---- -->", Asunto, Para)
a.GuardaLog()
Dim Mail As New ClsSisMail()
- Mail.SendMail(ClsPaginas.EmpresaNotificaciones, Para, Asunto, Body)
- End Sub
-#End Region
+ Dim EmpresaEnvio As Empresa = ClsPaginas.EmpresaNotificaciones
+
+ If UsuarioActual.Empresa.CvePlataforma = 3 Then
+ EmpresaEnvio = ClsPaginas.EmpresaNotificacionesGPS
+ End If
+
+ Mail.SendMail(EmpresaEnvio, Para, Asunto, Body)
+ End Sub
+#End Region
+
#Region "M O D U L O S"
Public Sub CargaModulosAcceso()
Dim ObjPermisos As New ClsSisUsuarios
@@ -808,11 +943,11 @@ Partial Class Sistemas_PopUpAddUsuario
End If
End If
- End Sub
-
-
+ End Sub
+
+
#End Region
-
+
#Region "V E H I C U L O S"
Private Sub CargaDispositivos()
GvDispositivos.DataSource = GlobalDTDispositivos(CveCliente).FiltraParametros("Estatus = 1 ")
@@ -826,10 +961,10 @@ Partial Class Sistemas_PopUpAddUsuario
End If
End If
End If
- End Sub
-
+ End Sub
+
#End Region
-
+
#Region "N O T I F I C A C I O N E S"
Private Sub CargarNotificaciones()
Dim ObjNotificaciones As New ClsSisNotificaciones
@@ -851,11 +986,11 @@ Partial Class Sistemas_PopUpAddUsuario
e.Row.FCCheckBox("chkApp").Checked = If(DtNotificacionesUsuarios.FiltroPrimeroValor("Alerta_App", $"CveNotificacion = {e.Row.DBCampo("CveNotificacion")}").ToString = "True", True, False)
End If
End If
- End Sub
-
-
+ End Sub
+
+
#End Region
-
+
Protected Sub BtnCambiarUsuario_Click(sender As Object, e As EventArgs)
CveUsuario = -1
diff --git a/Site.master b/Site.master
index 0996ebb05..6c399c64c 100644
--- a/Site.master
+++ b/Site.master
@@ -6,7 +6,7 @@
-
Sistema de Información Gerencial
+
Sistema de Información Gerencial
diff --git a/Site.master.vb b/Site.master.vb
index e35e3893b..899461f8d 100644
--- a/Site.master.vb
+++ b/Site.master.vb
@@ -76,6 +76,7 @@ Partial Class Site
If UsuarioActual.Empresa.CvePlataforma = 3 Then
lnkFavicon.Href = "/Imagenes/favicongps.ico"
+ tTitulo.Text = "SIGNALS GPS"
Else
lnkFavicon.Href = "/Imagenes/favicon.ico"
End If
diff --git a/Ventas/PV.aspx b/Ventas/PV.aspx
index fdfef6fe7..0ac8d7586 100644
--- a/Ventas/PV.aspx
+++ b/Ventas/PV.aspx
@@ -2953,7 +2953,7 @@