Merge branch 'master' of http://192.168.10.111:8383/SIG
This commit is contained in:
@@ -9207,6 +9207,7 @@ Public Class ClsPaginas
|
||||
'PaginaDict.Add("/Sistemas/CatEmpresas.aspx".ToUpper(), 2)
|
||||
PaginaDict.Add("/Sistemas/CatEmpresas.aspx".ToUpper(), 24)
|
||||
PaginaDict.Add("/Sistemas/Empresa.aspx".ToUpper(), 2)
|
||||
PaginaDict.Add("/Sistemas/Empresa2.aspx".ToUpper(), -1)
|
||||
PaginaDict.Add("/Sistemas/CatUsuarios.aspx".ToUpper(), 20)
|
||||
PaginaDict.Add("/Sistemas/Usuarios.aspx".ToUpper(), 20)
|
||||
PaginaDict.Add("/Sistemas/UsuarioDetalle.aspx".ToUpper(), 20)
|
||||
|
||||
@@ -443,6 +443,10 @@ Public Class ClsSisEmpresas
|
||||
_Empresa.GrupoEmpresa = Data.Rows(0)("GrupoEmpresa").ToString.ToEntero
|
||||
_Empresa.PlantillaMailVenta = Data.Rows(0)("PlantillaMailVenta").ToString
|
||||
_Empresa.AsuntoPlantillaMailVenta = Data.Rows(0)("AsuntoPlantillaMailVenta").ToString
|
||||
|
||||
_Empresa.PlantillaMailVentaCotizacion = Data.Rows(0)("PlantillaMailVentaCotizacion").ToString
|
||||
_Empresa.AsuntoPlantillaMailVentaCotizacion = Data.Rows(0)("AsuntoPlantillaMailVentaCotizacion").ToString
|
||||
|
||||
_Empresa.CvePlataforma = Data.Rows(0)("CvePlataforma").ToString.ToEntero
|
||||
_Empresa.CveDistribuidor = Data.Rows(0)("CveDistribuidor").ToString.ToEntero
|
||||
_Empresa.DiasPermitidos = Data.Rows(0)("DiasPermitidos").ToString.ToEntero
|
||||
|
||||
@@ -33,7 +33,7 @@ Public Class ClsSisMail
|
||||
Return Resultado
|
||||
End Function
|
||||
|
||||
Public Function SendMail(ObjEmpresa As Empresa, Para As String, Asunto As String, Body As String, Optional CCP As String = "", Optional Archivos As List(Of ArchivoMail) = Nothing, Optional Displayname As String = "") As Boolean
|
||||
Public Function SendMail(ObjEmpresa As Empresa, Para As String, Asunto As String, Body As String, Optional CCP As String = "", Optional Archivos As List(Of ArchivoMail) = Nothing, Optional Displayname As String = "", Optional CCO As String = "") As Boolean
|
||||
Dim ObjMail As New Mail
|
||||
ObjMail.ObjEmpresa = ObjEmpresa
|
||||
ObjMail.De = If(Displayname.Trim = String.Empty, "", Displayname)
|
||||
@@ -41,6 +41,7 @@ Public Class ClsSisMail
|
||||
ObjMail.CCP = CCP
|
||||
ObjMail.Asunto = Asunto
|
||||
ObjMail.Body = Body
|
||||
ObjMail.CCO = CCO
|
||||
|
||||
If Archivos IsNot Nothing AndAlso Archivos.Count > 0 Then ' si tiene adjuntos, me crea el objeto
|
||||
ObjMail.Archivos = New List(Of ArchivoMail)
|
||||
@@ -85,6 +86,7 @@ Public Class ClsSisMail
|
||||
Dim Mensaje As String = String.Empty
|
||||
Dim ArrayPara() As String = ObjMail.Para.Replace(",", ";").Split(";"c)
|
||||
Dim ArrayCCP() As String = ObjMail.CCP.Replace(",", ";").Split(";"c)
|
||||
Dim ArrayBCC() As String = ObjMail.CCO.Replace(",", ";").Split(";"c)
|
||||
|
||||
'"sgd.facturacion@adsistemas.mx"
|
||||
If ObjMail.De = String.Empty Then
|
||||
@@ -103,6 +105,12 @@ Public Class ClsSisMail
|
||||
For Each CorreoCCPPara As String In ArrayCCP.Distinct
|
||||
If IsMail(CorreoCCPPara.Trim) Then Correo.To.Add(CorreoCCPPara.Trim)
|
||||
Next
|
||||
End If
|
||||
|
||||
If ArrayBCC IsNot Nothing AndAlso ArrayBCC.Length > 0 Then
|
||||
For Each CorreoCCOPara As String In ArrayBCC.Distinct
|
||||
If IsMail(CorreoCCOPara.Trim) Then Correo.Bcc.Add(CorreoCCOPara.Trim)
|
||||
Next
|
||||
End If
|
||||
|
||||
Correo.Subject = ObjMail.Asunto
|
||||
@@ -120,7 +128,6 @@ Public Class ClsSisMail
|
||||
Correo.Body = Mensaje & ObjMail.Body
|
||||
Correo.IsBodyHtml = True
|
||||
Correo.Priority = Net.Mail.MailPriority.Normal
|
||||
|
||||
If ObjMail.Archivos IsNot Nothing Then
|
||||
For Each Item As ArchivoMail In ObjMail.Archivos
|
||||
If Item.ArchivoBinario IsNot Nothing Then
|
||||
@@ -190,6 +197,7 @@ Public Class ClsSisMail
|
||||
Public Property Para As String
|
||||
Public Property Asunto As String
|
||||
Public Property CCP As String
|
||||
Public Property CCO As String
|
||||
Public Property Body As String
|
||||
Public Property Archivos As List(Of ArchivoMail)
|
||||
End Class
|
||||
|
||||
@@ -5850,7 +5850,7 @@ Public Class ClsVentas
|
||||
.Add("@CamionRemolque2", SqlDbType.VarChar).Value = CamionRemolque2
|
||||
.Add("@Distancia", SqlDbType.Decimal).Value = Distancia
|
||||
.Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa
|
||||
.Add("@ErrorMSG", SqlDbType.VarChar, 300).Direction = ParameterDirection.Output
|
||||
.Add("@ErrorMSG", SqlDbType.VarChar, 5000).Direction = ParameterDirection.Output
|
||||
End With
|
||||
|
||||
Try
|
||||
|
||||
@@ -140,8 +140,9 @@ Public Class Empresa
|
||||
Public Property CveEncuestaCRM As Integer
|
||||
|
||||
Public Property FielPassword As String
|
||||
Public Property FielPFX As String
|
||||
|
||||
Public Property FielPFX As String
|
||||
Public Property AsuntoPlantillaMailVentaCotizacion As String
|
||||
Public Property PlantillaMailVentaCotizacion As String
|
||||
Dim Funcionalidades As HybridDictionary
|
||||
'HybridDictionary, no se puede serializar, por eso no es propiedad, y se utilizar el setfuncionalidad, para asignarle valor
|
||||
Public Sub SetFuncionalidades(HD As HybridDictionary)
|
||||
|
||||
106
Ashx/E141.ashx
106
Ashx/E141.ashx
@@ -130,7 +130,7 @@ Public Class E141 : Implements IHttpHandler
|
||||
End If
|
||||
|
||||
Catch ex As Exception
|
||||
GuardaLogAD("Ocurrió un error al descargar el pdf. " + ex.ToString() + ".parametros: " + Params, "LogE141")
|
||||
GuardaLogAD("Ocurrió un error al descargar el pdf. " + ex.ToString() + ".parametros: " + Params, "LogE141Descargas")
|
||||
End Try
|
||||
|
||||
Else
|
||||
@@ -250,6 +250,16 @@ Public Class E141 : Implements IHttpHandler
|
||||
Else
|
||||
retorno = "False"
|
||||
End If
|
||||
Case "EnviarCorreoAltasSemanal"
|
||||
GuardaLogAD("CA-Inicia envio de correo semanal", "LogE141")
|
||||
respuesta = EnviarCorreoActualizarProductos()
|
||||
GuardaLogAD("CA-Finaliza envio de correo semanal", "LogE141")
|
||||
If respuesta Then
|
||||
retorno = "True"
|
||||
Else
|
||||
retorno = "False"
|
||||
End If
|
||||
|
||||
End Select
|
||||
|
||||
End If
|
||||
@@ -268,6 +278,27 @@ Public Class E141 : Implements IHttpHandler
|
||||
End Try
|
||||
End Sub
|
||||
|
||||
Private Sub EnviarCorreoNotificacion(TareaNotificar As String, Cuerpo As String)
|
||||
Dim ResultadoMail As Integer = 0
|
||||
Dim CorreoDestino As String = "atencion@fidelityapps.mx"
|
||||
Dim MailCC As String = "citas@econollantas.com;sixrogs@hotmail.com;ffelix@econollantas.com"
|
||||
Dim MailCCO As String = "jonathan.perez@adssistemas.mx;rene.molina@adsistemas.mx"
|
||||
|
||||
If Not EsProduccion Then
|
||||
CorreoDestino = "jonathan.perez@adssistemas.mx"
|
||||
MailCC = "rene.molina@adsistemas.mx"
|
||||
MailCCO = "japmx95@gmail.com"
|
||||
End If
|
||||
|
||||
Dim ObjMail As New ClsSisMail
|
||||
If ObjMail.SendMail(ClsPaginas.EmpresaNotificaciones, CorreoDestino, TareaNotificar, Cuerpo, CCP:=MailCC, CCO:=MailCCO) Then
|
||||
GuardaLogAD($"EC-Envio de correo exitoso. Tarea: {TareaNotificar}", "LogE141")
|
||||
Else
|
||||
GuardaLogAD($"EC-No se pudo enviar el correo. Tarea: {TareaNotificar}", "LogE141")
|
||||
End If
|
||||
|
||||
End Sub
|
||||
|
||||
Private Function ValidarSolicitud(ByVal context As HttpContext) As AuthMessage
|
||||
Dim unauthorized As Boolean = True
|
||||
Dim respuesta As New AuthMessage
|
||||
@@ -1729,6 +1760,38 @@ Public Class E141 : Implements IHttpHandler
|
||||
'End Function
|
||||
#Region "C R E A C I Ó N / A C T U A L I Z A C I Ó N - P R O D U C T O S"
|
||||
|
||||
Private Function EnviarCorreoActualizarProductos() As Boolean
|
||||
Dim Retorno As Boolean = True
|
||||
|
||||
Dim CountPeticiones As Integer = 0, CountPeticionesExitosas As Integer = 0
|
||||
|
||||
Dim DtPS As DataTable = Nothing
|
||||
Using ObjPS As New ClsProductosServicios
|
||||
'OBTENER LOS PRODUCTOS NUEVOS EN LA ULTIMA SEMANA
|
||||
If ObjPS.GetProductosModificados(CveEmpresa, 44, HorasDiferencia:=(24 * 7)) Then
|
||||
DtPS = ObjPS.DtResultados
|
||||
End If
|
||||
End Using
|
||||
|
||||
If DtPS IsNot Nothing Then
|
||||
Dim sb As New StringBuilder
|
||||
For Each Row As DataRow In DtPS.Rows
|
||||
sb.AppendFormat("- {0}. <br/>", Row("CodigoPS"))
|
||||
Next
|
||||
Dim msg As String = ""
|
||||
|
||||
If sb.Length > 0 Then
|
||||
msg = $"Se enviaron los siguientes productos: <br/> {sb.ToString()} <br/> Fecha y hora: {Now.ToString("dd/MM/yyyy hh:mm:ss tt")}"
|
||||
Else
|
||||
msg = $"No se enviaron productos esta semana <br/> Fecha y hora: {Now.ToString("dd/MM/yyyy hh:mm:ss tt")}"
|
||||
End If
|
||||
|
||||
EnviarCorreoNotificacion("SIG - Productos enviados en la semana", msg)
|
||||
End If
|
||||
|
||||
Return Retorno
|
||||
End Function
|
||||
|
||||
Private Function CrearActualizarProductos(Todos As Boolean) As Boolean
|
||||
Dim Retorno As Boolean = False
|
||||
Dim CountPeticiones As Integer = 0, CountPeticionesExitosas As Integer = 0
|
||||
@@ -1738,6 +1801,8 @@ Public Class E141 : Implements IHttpHandler
|
||||
'OBTERNER PRECIOS DE PUBLICO GENERAL
|
||||
If ObjPS.GetProductosModificados(CveEmpresa, 44, If(Todos, -1, 26)) Then
|
||||
DtPS = ObjPS.DtResultados.Copy()
|
||||
Else
|
||||
GuardaLogAD($"NP-Ocurrió un error al obtener los productos", "LogE141")
|
||||
End If
|
||||
End Using
|
||||
|
||||
@@ -1759,10 +1824,10 @@ Public Class E141 : Implements IHttpHandler
|
||||
CountPeticionesExitosas += 1
|
||||
GuardaLogAD("NP-Creacion/actualizacion de productos exitosa", "LogE141")
|
||||
Else
|
||||
GuardaLogAD($"NP-No se pudo realizar la Creacion/actualizacion de productos ${respuesta.ToString()}", "LogE141")
|
||||
GuardaLogAD($"NP-No se pudo realizar la Creacion/actualizacion de productos ${respuesta.ToString()}", "LogE141")
|
||||
End If
|
||||
Else
|
||||
GuardaLogAD($"NP-No se pudo realizar la Creacion/actualizacion de productos ${resp}", "LogE141")
|
||||
GuardaLogAD($"NP-No se pudo realizar la Creacion/actualizacion de productos ${resp}", "LogE141")
|
||||
End If
|
||||
|
||||
Else
|
||||
@@ -1799,16 +1864,18 @@ Public Class E141 : Implements IHttpHandler
|
||||
CountPeticionesExitosas += 1
|
||||
GuardaLogAD("NP-Creacion/actualizacion de productos exitosa", "LogE141")
|
||||
Else
|
||||
GuardaLogAD($"NP-No se pudo realizar la Creacion/actualizacion de productos ${respuesta.ToString()}", "LogE141")
|
||||
GuardaLogAD($"NP-No se pudo realizar la Creacion/actualizacion de productos ${respuesta.ToString()}", "LogE141")
|
||||
End If
|
||||
Else
|
||||
GuardaLogAD($"NP-No se pudo realizar la Creacion/actualizacion de productos ${resp}", "LogE141")
|
||||
GuardaLogAD($"NP-No se pudo realizar la Creacion/actualizacion de productos ${resp}", "LogE141")
|
||||
End If
|
||||
|
||||
Threading.Thread.Sleep(1000)
|
||||
End While
|
||||
End If
|
||||
|
||||
If DtPS.Rows.Count > 0 Then
|
||||
EnviarCorreoNotificacion("SIG - Actualización de productos", $"Se ejecuto la tarea de actualización de productos. <br/> Fecha y hora: {Now.ToString("dd/MM/yyyy hh:mm:ss tt")}")
|
||||
End If
|
||||
End If
|
||||
|
||||
If CountPeticionesExitosas = CountPeticiones Then
|
||||
@@ -1826,7 +1893,7 @@ Public Class E141 : Implements IHttpHandler
|
||||
Dim DtPS As DataTable = Nothing
|
||||
Using ObjPS As New ClsProductosServicios
|
||||
'OBTERNER PRECIOS DE PUBLICO GENERAL
|
||||
If ObjPS.GetProductosModificados(CveEmpresa, 44, If(Todos, -1, 1)) Then
|
||||
If ObjPS.GetProductosModificados(CveEmpresa, 44, If(Todos, -1, 26)) Then
|
||||
DtPS = ObjPS.DtResultados.Copy()
|
||||
End If
|
||||
End Using
|
||||
@@ -1890,6 +1957,12 @@ Public Class E141 : Implements IHttpHandler
|
||||
|
||||
Private Function ActualizarPrecios(Todos As Boolean) As Boolean
|
||||
Dim Retorno As Boolean = False
|
||||
'ENVIAR PRECIOS SOLO DE 8am a 7pm
|
||||
If Now.Hour < 7 OrElse Now.Hour > 21 Then
|
||||
Retorno = True
|
||||
Return Retorno
|
||||
End If
|
||||
|
||||
Dim CountPeticiones As Integer = 0, CountPeticionesExitosas As Integer = 0
|
||||
|
||||
Dim DtPS As DataTable = Nothing
|
||||
@@ -1897,6 +1970,8 @@ Public Class E141 : Implements IHttpHandler
|
||||
'OBTERNER PRECIOS DE PUBLICO GENERAL
|
||||
If ObjPS.GetPreciosModificados(CveEmpresa, 44, If(Todos, -1, 1)) Then
|
||||
DtPS = ObjPS.DtResultados.Copy()
|
||||
Else
|
||||
GuardaLogAD($"AP-Ocurrió un error al obtener los precios", "LogE141")
|
||||
End If
|
||||
End Using
|
||||
|
||||
@@ -1965,8 +2040,13 @@ Public Class E141 : Implements IHttpHandler
|
||||
End While
|
||||
End If
|
||||
|
||||
If DtPS.Rows.Count > 0 Then
|
||||
EnviarCorreoNotificacion("SIG - Actualización de precios", $"Se ejecuto la tarea de actualización de precios. <br/> Fecha y hora: {Now.ToString("dd/MM/yyyy hh:mm:ss tt")}")
|
||||
End If
|
||||
|
||||
End If
|
||||
|
||||
|
||||
Return Retorno
|
||||
End Function
|
||||
|
||||
@@ -2017,11 +2097,19 @@ Public Class E141 : Implements IHttpHandler
|
||||
Dim Retorno As Boolean = False
|
||||
Dim CountPeticiones As Integer = 0, CountPeticionesExitosas As Integer = 0
|
||||
|
||||
'ENVIAR SOLO DE 8am a 8pm
|
||||
If Now.Hour < 7 OrElse Now.Hour > 21 Then
|
||||
Retorno = True
|
||||
Return Retorno
|
||||
End If
|
||||
|
||||
Dim DtPS As DataTable = Nothing
|
||||
Using ObjPS As New ClsProductosServicios
|
||||
'OBTERNER PRECIOS DE PUBLICO GENERAL
|
||||
If ObjPS.GetExistenciasEmpresa("-1", CveEmpresa) Then
|
||||
DtPS = ObjPS.DtResultados.Copy()
|
||||
Else
|
||||
GuardaLogAD($"AE-Ocurrió un error al obtener las existencias", "LogE141")
|
||||
End If
|
||||
End Using
|
||||
|
||||
@@ -2087,6 +2175,10 @@ Public Class E141 : Implements IHttpHandler
|
||||
Threading.Thread.Sleep(1000)
|
||||
End While
|
||||
End If
|
||||
|
||||
If DtPS.Rows.Count > 0 Then
|
||||
EnviarCorreoNotificacion("SIG - Actualización de existencias", $"Se ejecuto la tarea de actualización de existencias. <br/> Fecha y hora: {Now.ToString("dd/MM/yyyy hh:mm:ss tt")}")
|
||||
End If
|
||||
End If
|
||||
|
||||
If CountPeticionesExitosas = CountPeticiones Then
|
||||
|
||||
@@ -413,11 +413,13 @@ Partial Class Compras_ReembolsosComprobaciones
|
||||
|
||||
Dim FechaFactura As Date = gvRowVal.DataKey("FechaCompra").ToDate
|
||||
Dim FechaDocumento As Date
|
||||
If DDlCheques.SelectedValue.ToEntero = -1 Then
|
||||
|
||||
If DDlCheques.SelectedValue.ToEntero = -1 And Not ChkReembolsarSinBancos.Checked Then
|
||||
FechaDocumento = TxtFechaDocumento.Text.ToDate
|
||||
Else
|
||||
FechaDocumento = TxtFechaPrePoliza.Text.ToDate
|
||||
End If
|
||||
|
||||
Dim AnioFactura As Integer = FechaFactura.Year
|
||||
Dim MesFactura As Integer = FechaFactura.Month
|
||||
Dim AnioDocumento As Integer = FechaDocumento.Year
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Report xmlns="http://schemas.microsoft.com/sqlserver/reporting/2010/01/reportdefinition" xmlns:rd="http://schemas.microsoft.com/SQLServer/reporting/reportdesigner">
|
||||
<Report xmlns:rd="http://schemas.microsoft.com/SQLServer/reporting/reportdesigner" xmlns:cl="http://schemas.microsoft.com/sqlserver/reporting/2010/01/componentdefinition" xmlns="http://schemas.microsoft.com/sqlserver/reporting/2010/01/reportdefinition">
|
||||
<AutoRefresh>0</AutoRefresh>
|
||||
<DataSources>
|
||||
<DataSource Name="DataSet">
|
||||
@@ -65,6 +65,10 @@
|
||||
<DataField>Valor</DataField>
|
||||
<rd:TypeName>System.Decimal</rd:TypeName>
|
||||
</Field>
|
||||
<Field Name="Disponible">
|
||||
<DataField>Disponible</DataField>
|
||||
<rd:TypeName>System.Decimal</rd:TypeName>
|
||||
</Field>
|
||||
</Fields>
|
||||
<rd:DataSetInfo>
|
||||
<rd:DataSetName>DataSet</rd:DataSetName>
|
||||
@@ -811,7 +815,6 @@
|
||||
<PaddingBottom>2pt</PaddingBottom>
|
||||
</Style>
|
||||
</Textbox>
|
||||
<rd:Selected>true</rd:Selected>
|
||||
</CellContents>
|
||||
</TablixCell>
|
||||
<TablixCell>
|
||||
@@ -823,7 +826,7 @@
|
||||
<Paragraph>
|
||||
<TextRuns>
|
||||
<TextRun>
|
||||
<Value>=Fields!Cantidad.Value</Value>
|
||||
<Value>=Fields!Disponible .Value</Value>
|
||||
<Style>
|
||||
<FontSize>7pt</FontSize>
|
||||
<FontWeight>=IIf(Fields!PS.Value = "", "Bold", "Default")</FontWeight>
|
||||
@@ -1612,7 +1615,6 @@
|
||||
<Prompt>ReportParameter1</Prompt>
|
||||
</ReportParameter>
|
||||
</ReportParameters>
|
||||
|
||||
<rd:ReportUnitType>Cm</rd:ReportUnitType>
|
||||
<rd:ReportID>40c94aad-a12a-44fb-ab0d-ea36a9656792</rd:ReportID>
|
||||
</Report>
|
||||
@@ -4825,10 +4825,13 @@
|
||||
<i></i>
|
||||
</div>
|
||||
<div class="form-group form-md-line-input input-iconright">
|
||||
<asp:TextBox CssClass="form-control" ID="TxtNumeroCuenta" runat="server"></asp:TextBox>
|
||||
<asp:TextBox CssClass="form-control" ID="TxtNumeroCuenta" runat="server" CausesValidation="true"></asp:TextBox>
|
||||
<asp:Label runat="server" AssociatedControlID="TxtNumeroCuenta" Text="Cuenta:"></asp:Label>
|
||||
<asp:RequiredFieldValidator ID="RFVNumeroCuenta" runat="server" InitialValue="-1" ControlToValidate="TxtNumeroCuenta" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Cuenta''</b> es necesario, por favor ingréselo." ValidationGroup="GrpAgregarBanco"></asp:RequiredFieldValidator>
|
||||
<asp:RequiredFieldValidator ID="RFVNumeroCuenta" runat="server" ControlToValidate="TxtNumeroCuenta" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Cuenta''</b> es necesario, por favor ingréselo." ValidationGroup="GrpAgregarBanco"></asp:RequiredFieldValidator>
|
||||
<asp:RegularExpressionValidator ID="RGVNumeroCuenta" ValidationExpression="^(?:\d{10}|\d{11}|\d{15}|\d{16}|\d{18})$" runat="server" ControlToValidate="TxtNumeroCuenta" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Cuenta''</b> debe de tener una logitud de 10,11,15,16,18 caracteres." ValidationGroup="GrpAgregarBanco"></asp:RegularExpressionValidator>
|
||||
|
||||
<ajax:ValidatorCalloutExtender ID="VcoNumeroCuenta" runat="server" HighlightCssClass="vco" TargetControlID="RFVNumeroCuenta" Width="300px"></ajax:ValidatorCalloutExtender>
|
||||
<ajax:ValidatorCalloutExtender ID="VcoRGVNumeroCuenta" runat="server" HighlightCssClass="vco" TargetControlID="RGVNumeroCuenta" Width="300px"></ajax:ValidatorCalloutExtender>
|
||||
<i></i>
|
||||
</div>
|
||||
<div class="form-group form-md-line-input input-iconright">
|
||||
|
||||
1049
Sistemas/Empresa2.aspx
Normal file
1049
Sistemas/Empresa2.aspx
Normal file
File diff suppressed because it is too large
Load Diff
2048
Sistemas/Empresa2.aspx.vb
Normal file
2048
Sistemas/Empresa2.aspx.vb
Normal file
File diff suppressed because it is too large
Load Diff
@@ -109,21 +109,30 @@ Partial Class Ventas_FacturacionAcarreos
|
||||
Try
|
||||
Dim DtPS As DataTable = GlobalDTPSSimplificado(UsuarioActual.CveEmpresa)
|
||||
For Each row As DataRow In dt.Rows
|
||||
Dim msg As String = ObjVentas.AddFacturacionAcarreos(row("Sucursal").ToString(), row("RFC").ToString(), row("Cantidad").ToString().ToDecimal(), row("ProductoGeneral").ToString(),
|
||||
row("Origen").ToString(), row("Destino").ToString(), row("FechaSalida").ToString().ToDateTime(), row("FechaLlegada").ToString().ToDateTime(),
|
||||
row("Unidad").ToString(), row("Chofer").ToString(), row("Configuración").ToString(), row("Remolque1").ToString(), row("Remolque2").ToString(),
|
||||
row("Distancia").ToString().ToDecimal(), UsuarioActual.CveEmpresa)
|
||||
Dim FechaSalida As DateTime = MinFecha
|
||||
Dim FechaLlegada As DateTime = MinFecha
|
||||
|
||||
If row("FechaSalida").ToString().ToDateTime() > FechaSalida Then
|
||||
FechaSalida = row("FechaSalida").ToString().ToDateTime()
|
||||
End If
|
||||
If row("FechaLlegada").ToString().ToDateTime() > FechaLlegada Then
|
||||
FechaLlegada = row("FechaLlegada").ToString().ToDateTime()
|
||||
End If
|
||||
|
||||
Dim msg As String = ObjVentas.AddFacturacionAcarreos(row("Sucursal").ToString(), row("RFC").ToString(), row("Cantidad").ToString().ToDecimal(), row("ProductoGeneral").ToString(), row("Origen").ToString(),
|
||||
row("Destino").ToString(), FechaSalida, FechaLlegada, row("Unidad").ToString(), row("Chofer").ToString(), row("Configuración").ToString(),
|
||||
row("Remolque1").ToString(), row("Remolque2").ToString(), row("Distancia").ToString().ToDecimal(), UsuarioActual.CveEmpresa)
|
||||
If msg = "Correcto" Then
|
||||
RowsCargados += 1
|
||||
Else
|
||||
TieneError = True
|
||||
MsgFacturacionAcarreos.AppendFormat("{0}", msg)
|
||||
MsgFacturacionAcarreos.AppendFormat("Ocurrió un error al procesar la fila: {0}<br/>{1}", row("NoExcel"), msg)
|
||||
RowsNoCargados += 1
|
||||
Exit For
|
||||
End If
|
||||
Next
|
||||
Catch ex As Exception
|
||||
OnError("Ocurrió un error al cargar los precios.", ex)
|
||||
OnError("Ocurrió un error al cargar los datos.", ex)
|
||||
Finally
|
||||
Dim MensajeFinal As New StringBuilder()
|
||||
If RowsNoCargados = 0 AndAlso RowsCargados > 0 Then
|
||||
@@ -179,15 +188,21 @@ Partial Class Ventas_FacturacionAcarreos
|
||||
End If
|
||||
Next
|
||||
|
||||
dataTable.Columns.Add("NoExcel", GetType(String))
|
||||
|
||||
While curRow < worksheet.Rows.Count
|
||||
columns = New String(cols - 1) {}
|
||||
columns = New String(cols) {}
|
||||
|
||||
For curCol = 0 To cols - 1
|
||||
|
||||
If worksheet.Rows(curRow).Cells(curCol).Value Is Nothing Then
|
||||
columns(curCol) = ""
|
||||
Else
|
||||
columns(curCol) = worksheet.Rows(curRow).Cells(curCol).Value.ToString()
|
||||
For curCol = 0 To cols
|
||||
|
||||
If curCol = cols Then
|
||||
columns(curCol) = worksheet.Rows(curRow).Name
|
||||
Else
|
||||
If worksheet.Rows(curRow).Cells(curCol).Value Is Nothing Then
|
||||
columns(curCol) = ""
|
||||
Else
|
||||
columns(curCol) = worksheet.Rows(curRow).Cells(curCol).Value.ToString()
|
||||
End If
|
||||
End If
|
||||
Next
|
||||
|
||||
|
||||
@@ -625,72 +625,74 @@
|
||||
<table class="table table-striped nobordertop table-advance table-hover">
|
||||
<tbody>
|
||||
<tr>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkTipoDocto" runat="server" Text="*Tipo Documento" Checked="true" /></td>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkSucursal" runat="server" Text="*Sucursal" Checked="true" /></td>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkSucursalCobranza" runat="server" Text="Sucursal Cobranza" /></td>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkTipoDocto" runat="server" Text=" *Tipo Documento" Checked="true" /></td>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkSucursal" runat="server" Text=" *Sucursal" Checked="true" /></td>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkSucursalCobranza" runat="server" Text=" Sucursal Cobranza" /></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkFolio" runat="server" Text="*Folio" Checked="true" /></td>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkEstatusFactura" runat="server" Text="*Estatus de Factura" Checked="true" /></td>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkSucursalEjecucion" runat="server" Text="Sucursal Ejecución" /></td>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkFolio" runat="server" Text=" *Folio" Checked="true" /></td>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkEstatusFactura" runat="server" Text=" *Estatus de Factura" Checked="true" /></td>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkSucursalEjecucion" runat="server" Text=" Sucursal Ejecución" /></td>
|
||||
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkFecha" runat="server" Text="*Fecha" Checked="true" /></td>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkVendedor" runat="server" Text="Vendedor" /></td>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkMotivoCancelacion" runat="server" Text="Motivo Cancelacion" /></td>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkFecha" runat="server" Text=" *Fecha" Checked="true" /></td>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkVendedor" runat="server" Text=" Vendedor" /></td>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkMotivoCancelacion" runat="server" Text=" Motivo Cancelacion" /></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkSubTotal" runat="server" Text="*SubTotal" Checked="true" /></td>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkCodigo" runat="server" Text="Código Cliente" /></td>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkUsuario" runat="server" Text="Usuario" /></td>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkSubTotal" runat="server" Text=" *SubTotal" Checked="true" /></td>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkCodigo" runat="server" Text=" Código Cliente" /></td>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkUsuario" runat="server" Text=" Usuario" /></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkDescuento" runat="server" Text="*Descuento" /></td>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkCliente" runat="server" Text="*Cliente" Checked="true" /></td>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkEstatusFacturacion" runat="server" Text="Estatus Facturación" /></td>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkDescuento" runat="server" Text=" *Descuento" /></td>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkCliente" runat="server" Text=" *Cliente" Checked="true" /></td>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkEstatusFacturacion" runat="server" Text=" Estatus Facturación" /></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkIVA" runat="server" Text="*IVA" Checked="true" /></td>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkMailCliente" runat="server" Text="Mail Cliente" /></td>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkFolioFacturacion" runat="server" Text="Factura Cotización" /></td>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkIVA" runat="server" Text=" *IVA" Checked="true" /></td>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkMailCliente" runat="server" Text=" Mail Cliente" /></td>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkFolioFacturacion" runat="server" Text=" Factura Cotización" /></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkIEPS" runat="server" Text="*IEPS" /></td>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkCuentaContable" runat="server" Text="Cuenta Contable" /></td>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkObservaciones" runat="server" Text="Observaciones" /></td>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkRetIVA" runat="server" Text=" Ret. IVA" /></td>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkCuentaContable" runat="server" Text=" Cuenta Contable" /></td>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkObservaciones" runat="server" Text=" Observaciones" /></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkRetIVA" runat="server" Text="Ret. IVA" /></td>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkSucursalCliente" runat="server" Text="Sucursal Cliente" /></td>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkOrdenCompra" runat="server" Text="OrdenCompra" /></td>
|
||||
<tr>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkRetISR" runat="server" Text=" Ret. ISR" /></td>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkSucursalCliente" runat="server" Text=" Sucursal Cliente" /></td>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkOrdenCompra" runat="server" Text=" OrdenCompra" /></td>
|
||||
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkRetISR" runat="server" Text="Ret. ISR" /></td>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkSaldo" runat="server" Text="Saldo" Checked="false" /></td>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkPedidoContrato" runat="server" Text="Pedido Contrato" /></td>
|
||||
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkTotalImpuestos" runat="server" Text=" Impuestos Locales" /></td>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkSaldo" runat="server" Text=" Saldo" Checked="false" /></td>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkPedidoContrato" runat="server" Text=" Pedido Contrato" /></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkTotalImpuestos" runat="server" Text="Impuestos Locales" /></td>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkFolioFiscal" runat="server" Text="Folio Fiscal (UUID)" /></td>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChlMotivoDescuento" runat="server" Text="Motivo Descuento" /></td>
|
||||
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkTotal" runat="server" Text=" *Total" Checked="true" /></td>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkFolioFiscal" runat="server" Text=" Folio Fiscal (UUID)" /></td>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChlMotivoDescuento" runat="server" Text=" Motivo Descuento" /></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkTotal" runat="server" Text="*Total" Checked="true" /></td>
|
||||
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkMoneda" runat="server" Text=" *Moneda" Checked="true" /></td>
|
||||
<td style="text-align: left;"></td>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkAmortizacion" runat="server" Text="Amortización" /></td>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkAmortizacion" runat="server" Text=" Amortización" /></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkMoneda" runat="server" Text="*Moneda" Checked="true" /></td>
|
||||
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkIEPS" runat="server" Text=" *IEPS" /></td>
|
||||
<td style="text-align: left;"></td>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkSeTimbro" runat="server" Text="Se Timbró" /></td>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkSeTimbro" runat="server" Text=" Se Timbró" /></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="text-align: left;"></td>
|
||||
<td style="text-align: left;"></td>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkSeEnvioMail" runat="server" Text="Se envió Mail" /></td>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkSeEnvioMail" runat="server" Text=" Se envió Mail" />&nbst</td>
|
||||
</tr>
|
||||
|
||||
</tbody>
|
||||
|
||||
@@ -423,66 +423,69 @@
|
||||
<tbody>
|
||||
<tr>
|
||||
<td style="text-align: left;">
|
||||
<asp:CheckBox ID="ChkCantidad" runat="server" Text="*Cantidad" /></td>
|
||||
<asp:CheckBox ID="ChkCantidad" runat="server" Text=" *Cantidad" /></td>
|
||||
<td style="text-align: left;">
|
||||
<asp:CheckBox ID="ChkMaxSub" runat="server" Text="SubTotal Máximo" />
|
||||
<asp:CheckBox ID="ChkMaxSub" runat="server" Text=" SubTotal Máximo" />
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="text-align: left;">
|
||||
<asp:CheckBox ID="ChkSubtotal" runat="server" Text="Sub total" /></td>
|
||||
<asp:CheckBox ID="ChkSubtotal" runat="server" Text=" Sub total" /></td>
|
||||
</td>
|
||||
<td style="text-align: left;">
|
||||
<asp:CheckBox ID="ChkAVGSub" runat="server" Text="SubTotal Promedio" />
|
||||
<asp:CheckBox ID="ChkAVGSub" runat="server" Text=" SubTotal Promedio" />
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="text-align: left;">
|
||||
<asp:CheckBox ID="ChkDescuentos" runat="server" Text="*Descuentos" /></td>
|
||||
<asp:CheckBox ID="ChkDescuentos" runat="server" Text=" *Descuentos" /></td>
|
||||
</td>
|
||||
<td style="text-align: left;">
|
||||
<asp:CheckBox ID="ChkMinSub" runat="server" Text="SubTotal Mínimo" />
|
||||
<asp:CheckBox ID="ChkMinSub" runat="server" Text=" SubTotal Mínimo" />
|
||||
</td>
|
||||
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="text-align: left;">
|
||||
<asp:CheckBox ID="ChkSubTotal2" runat="server" Text="*Subtotal 2" />
|
||||
<asp:CheckBox ID="ChkSubTotal2" runat="server" Text=" *Subtotal 2" />
|
||||
</td>
|
||||
<td style="text-align: left;">
|
||||
<asp:CheckBox ID="ChkMaxTot" runat="server" Text="Total Máximo" />
|
||||
<asp:CheckBox ID="ChkMaxTot" runat="server" Text=" Total Máximo" />
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="text-align: left;">
|
||||
<asp:CheckBox ID="ChkIVA" runat="server" Text="*IVA" />
|
||||
<asp:CheckBox ID="ChkIVA" runat="server" Text=" *IVA" />
|
||||
</td>
|
||||
<td style="text-align: left;">
|
||||
<asp:CheckBox ID="ChkAvgTot" runat="server" Text="Total Promedio" />
|
||||
<asp:CheckBox ID="ChkAvgTot" runat="server" Text=" Total Promedio" />
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="text-align: left;">
|
||||
<asp:CheckBox ID="ChkIEPS" runat="server" Text="*IEPS" />
|
||||
<asp:CheckBox ID="ChkRetIVA" runat="server" Text=" Ret. IVA" />
|
||||
|
||||
</td>
|
||||
<td style="text-align: left;">
|
||||
<asp:CheckBox ID="ChkMinTot" runat="server" Text="Total Mínimo" />
|
||||
<asp:CheckBox ID="ChkMinTot" runat="server" Text=" Total Mínimo" />
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td style="text-align: left;">
|
||||
<asp:CheckBox ID="ChkRetIVA" runat="server" Text="Ret. IVA" />
|
||||
|
||||
<asp:CheckBox ID="ChkRetISR" runat="server" Text=" Ret. ISR" />
|
||||
</td>
|
||||
<td style="text-align: left;">
|
||||
<asp:CheckBox ID="CheckRefacturado" runat="server" Text="Refacturado" />
|
||||
<asp:CheckBox ID="CheckRefacturado" runat="server" Text=" Refacturado" />
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
|
||||
<tr>
|
||||
<td style="text-align: left;">
|
||||
<asp:CheckBox ID="ChkRetISR" runat="server" Text="Ret. ISR" />
|
||||
|
||||
<asp:CheckBox ID="ChkImpLoc" runat="server" Text=" Impuestos Locales" />
|
||||
</td>
|
||||
<td style="text-align: left;">
|
||||
|
||||
@@ -491,7 +494,8 @@
|
||||
|
||||
<tr>
|
||||
<td style="text-align: left;">
|
||||
<asp:CheckBox ID="ChkImpLoc" runat="server" Text="Impuestos Locales" />
|
||||
|
||||
<asp:CheckBox ID="ChkTotal" runat="server" Text=" *Total" />
|
||||
</td>
|
||||
<td style="text-align: left;">
|
||||
|
||||
@@ -500,7 +504,9 @@
|
||||
|
||||
<tr>
|
||||
<td style="text-align: left;">
|
||||
<asp:CheckBox ID="ChkTotal" runat="server" Text="*Total" />
|
||||
|
||||
|
||||
<asp:CheckBox ID="ChkIEPS" runat="server" Text=" *IEPS" />
|
||||
</td>
|
||||
<td style="text-align: left;">
|
||||
|
||||
|
||||
Reference in New Issue
Block a user