From 94a84f05a83a90119c6deba1f7bee55ca2181185 Mon Sep 17 00:00:00 2001 From: Antonio Gonzalez Date: Thu, 21 May 2020 14:54:48 -0700 Subject: [PATCH] reporte de sugerencias y mensaje agregado a clsContabilidad --- App_Code/ClsContabilidad.vb | 8 +++++++- Inventarios/EntregaAlmacen.aspx | 6 ++++++ Inventarios/EntregaAlmacen.aspx.vb | 19 +++++++++++++++++++ 3 files changed, 32 insertions(+), 1 deletion(-) diff --git a/App_Code/ClsContabilidad.vb b/App_Code/ClsContabilidad.vb index 7f1096c37..a56a6f108 100644 --- a/App_Code/ClsContabilidad.vb +++ b/App_Code/ClsContabilidad.vb @@ -1120,7 +1120,13 @@ Public Class ClsContabilidad If Empresa.TipoContabilizacion = 1 Then ' contabilidad en SIG - ContabilizaDesContabilizaPrePoliza(CvePrePoliza, True, Empresa.CveEmpresa) + + Retorno = ContabilizaDesContabilizaPrePoliza(CvePrePoliza, True, Empresa.CveEmpresa) + + If Retorno Then + Mensaje.Append(String.Format("{1}
", CvePrePoliza, _ContaFolio)) + End If + Else If CvePrePoliza <= 0 Then Return False diff --git a/Inventarios/EntregaAlmacen.aspx b/Inventarios/EntregaAlmacen.aspx index e38673a70..d81474caf 100644 --- a/Inventarios/EntregaAlmacen.aspx +++ b/Inventarios/EntregaAlmacen.aspx @@ -770,6 +770,9 @@ + + + diff --git a/Inventarios/EntregaAlmacen.aspx.vb b/Inventarios/EntregaAlmacen.aspx.vb index c092d7182..6a429e8f0 100644 --- a/Inventarios/EntregaAlmacen.aspx.vb +++ b/Inventarios/EntregaAlmacen.aspx.vb @@ -7,6 +7,8 @@ Imports System.Linq Imports CrystalDecisions.[Shared].Json Imports Extensiones +Imports Microsoft.Reporting.WebForms + Partial Class Inventarios_EntregaAlmacen Inherits ClsPaginas @@ -3064,6 +3066,23 @@ Partial Class Inventarios_EntregaAlmacen End If End Sub + Protected Sub BtnImprimirSugerencias_Click(sender As Object, e As EventArgs) + Dim LogoRutaFisica As String = String.Format("Empresas\{0}\Logo.png", UsuarioActual.CveEmpresa) + Dim logouri = String.Format("{0}://{1}:{2}/ashx/sigfiles.ashx?P={3}", Request.Url.Scheme, Request.Url.Host, Request.Url.Port, Encripta(LogoRutaFisica)) + Dim Imagen As New System.IO.FileInfo(String.Format("{0}Logo.png", UsuarioActual.Empresa.Ruta)) + + Dim params As New List(Of ReportParameter) + If Imagen.Exists Then + params.Add(New ReportParameter("LogoPath", logouri)) + Else + params.Add(New ReportParameter("LogoPath", "")) + End If + params.Add(New ReportParameter("NombreEmpresa", UsuarioActual.Empresa.Empresa)) + params.Add(New ReportParameter("UsuarioImprimio", UsuarioActual.Usuario)) + + ImprimirPDF("Empresas/Grales/Formatos/RepEntregaAlmacenSugerencia.rdlc", DtDatosSugerencias, params, "Equipo GPS") + End Sub + #End Region