From e207419f71f8281302eeb505bd685904beda4648 Mon Sep 17 00:00:00 2001 From: roberto Date: Mon, 26 May 2014 17:23:07 +0000 Subject: [PATCH] =?UTF-8?q?Se=20arregla=20consumo=20de=20recursos=20por=20?= =?UTF-8?q?parte=20del=20log=20(el=20componente=20jvlog=203.32=20no=20est?= =?UTF-8?q?=C3=A1=20bien=20deberia=20actualizarse=20al=203.36),=20tambien?= =?UTF-8?q?=20se=20arreglan=20informes=20de=20contratos=20a=20peticion=20d?= =?UTF-8?q?e=20angelica?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit git-svn-id: https://192.168.0.254/svn/Proyectos.AbetoDesign_FactuGES/trunk@99 93f398dd-4eb6-7a46-baf6-13f46f578da2 --- Database/scripts/factuges.sql | 121 ++++++++++++----------- Source/Base/uDMBase.pas | 4 + Source/Informes/1/InfContratoCliente.fr3 | 4 +- Source/Informes/2/InfContratoCliente.fr3 | 4 +- Source/Informes/3/InfContratoCliente.fr3 | 4 +- Source/Informes/4/InfContratoCliente.fr3 | 4 +- Source/Servidor/uDataModuleServer.pas | 4 + 7 files changed, 79 insertions(+), 66 deletions(-) diff --git a/Database/scripts/factuges.sql b/Database/scripts/factuges.sql index ef8fe6e..d696226 100644 --- a/Database/scripts/factuges.sql +++ b/Database/scripts/factuges.sql @@ -5455,34 +5455,35 @@ begin begin if (visible <> 0) then begin - /*Escribimos capitulo anterior*/ - if ((Importe_total > 0) - and ((ultimo_tipo_detalle = 'Descuento') or (ultimo_tipo_detalle = 'Subtotal'))) then - begin - Importe_aux = Importe_total; - id = id_aux; - posicion = posicion_aux; - tipo_detalle = tipo_detalle_aux; - tipo_articulo = tipo_articulo_aux; - concepto = concepto_aux; - importe_total = total_acumulado; - importe_descuento = importe_descuento_aux; - descuento = descuento_aux; - visible = 1; - valorado = 1; - suspend; - total_acumulado = 0.0; - importe_descuento_aux = 0.0; - descuento_aux = 0.0; - /*Inicializamos*/ - ID_AUX = -1; - posicion_aux = -1; - concepto_aux = 'General'; - tipo_detalle_aux = 'Titulo'; - tipo_articulo_aux = 'NA'; - importe_total = Importe_aux; - end + /*Escribimos capitulo anterior*/ + if ((Importe_total > 0) + and ((ultimo_tipo_detalle = 'Descuento') or (ultimo_tipo_detalle = 'Subtotal'))) then + begin + Importe_aux = Importe_total; + id = id_aux; + posicion = posicion_aux; + tipo_detalle = tipo_detalle_aux; + tipo_articulo = tipo_articulo_aux; + concepto = concepto_aux; + importe_total = total_acumulado; + importe_descuento = importe_descuento_aux; + descuento = descuento_aux; + visible = 1; + valorado = 1; + suspend; + total_acumulado = 0.0; + importe_descuento_aux = 0.0; + descuento_aux = 0.0; + /*Inicializamos*/ + ID_AUX = -1; + posicion_aux = -1; + concepto_aux = 'General'; + tipo_detalle_aux = 'Titulo'; + tipo_articulo_aux = 'NA'; + importe_total = Importe_aux; + end end + if (valorado <> 0) then total_acumulado = total_acumulado + importe_total; ultimo_tipo_detalle = tipo_detalle; @@ -5554,6 +5555,7 @@ begin end end end + else if (TIPO = 'Contrato') then begin for select id, id_contrato, posicion, tipo_detalle, tipo_articulo, F_RTFTOTEXT(concepto) as concepto, @@ -5568,39 +5570,42 @@ begin contador = contador + 1; /*CONCEPTO*/ - if ((visible <> 0) and (tipo_detalle = 'Concepto')) then + if (tipo_detalle = 'Concepto') then begin - /*Escribimos capitulo anterior*/ - if ((Importe_total > 0) - and ((ultimo_tipo_detalle = 'Descuento') or (ultimo_tipo_detalle = 'Subtotal'))) then - begin - Importe_aux = Importe_total; - id = id_aux; - posicion = posicion_aux; - tipo_detalle = tipo_detalle_aux; - tipo_articulo = tipo_articulo_aux; - concepto = concepto_aux; - importe_total = total_acumulado; - importe_descuento = importe_descuento_aux; - descuento = descuento_aux; - visible = 1; - valorado = 1; - suspend; - total_acumulado = 0.0; - importe_descuento_aux = 0.0; - descuento_aux = 0.0; - /*Inicializamos*/ - ID_AUX = -1; - posicion_aux = -1; - concepto_aux = 'General'; - tipo_detalle_aux = 'Titulo'; - tipo_articulo_aux = 'NA'; - importe_total = Importe_aux; - end + if (visible <> 0) then + begin + /*Escribimos capitulo anterior*/ + if ((Importe_total > 0) + and ((ultimo_tipo_detalle = 'Descuento') or (ultimo_tipo_detalle = 'Subtotal'))) then + begin + Importe_aux = Importe_total; + id = id_aux; + posicion = posicion_aux; + tipo_detalle = tipo_detalle_aux; + tipo_articulo = tipo_articulo_aux; + concepto = concepto_aux; + importe_total = total_acumulado; + importe_descuento = importe_descuento_aux; + descuento = descuento_aux; + visible = 1; + valorado = 1; + suspend; + total_acumulado = 0.0; + importe_descuento_aux = 0.0; + descuento_aux = 0.0; + /*Inicializamos*/ + ID_AUX = -1; + posicion_aux = -1; + concepto_aux = 'General'; + tipo_detalle_aux = 'Titulo'; + tipo_articulo_aux = 'NA'; + importe_total = Importe_aux; + end + end - if (valorado <> 0) then - total_acumulado = total_acumulado + importe_total; - ultimo_tipo_detalle = tipo_detalle; + if (valorado <> 0) then + total_acumulado = total_acumulado + importe_total; + ultimo_tipo_detalle = tipo_detalle; end /*TITULO*/ diff --git a/Source/Base/uDMBase.pas b/Source/Base/uDMBase.pas index d7761f7..dc11f74 100644 --- a/Source/Base/uDMBase.pas +++ b/Source/Base/uDMBase.pas @@ -71,11 +71,13 @@ begin if SysUtils.ForceDirectories(ALogFileName) then begin +{SE COMENTA PORQUE TUESTA LA PARTE CLIENTE SI SE DESEA ARREGLAR ACTUALIZAR LAS JV de tecsitel JvLogFile.Active := False; JvLogFile.FileName := ALogFileName + 'ClientLog.txt'; JvLogFile.AutoSave := True; JvLogFile.Active := True; JvLogFile.Clear; +} end else raise Exception.Create('Error al crear directorio para Log: ' + IntToStr(GetLastError)); @@ -137,12 +139,14 @@ end; procedure TdmBase.EscribirLog(const AMensaje: String); begin +{ FEscribirLog.Acquire; try JvLogFile.Add(AMensaje); finally FEscribirLog.Release; end; +} end; end. diff --git a/Source/Informes/1/InfContratoCliente.fr3 b/Source/Informes/1/InfContratoCliente.fr3 index ae7c0f0..86d57a1 100644 --- a/Source/Informes/1/InfContratoCliente.fr3 +++ b/Source/Informes/1/InfContratoCliente.fr3 @@ -1,5 +1,5 @@ - + @@ -57,7 +57,7 @@ - + diff --git a/Source/Informes/2/InfContratoCliente.fr3 b/Source/Informes/2/InfContratoCliente.fr3 index c3552c4..403aca2 100644 --- a/Source/Informes/2/InfContratoCliente.fr3 +++ b/Source/Informes/2/InfContratoCliente.fr3 @@ -1,5 +1,5 @@ - + @@ -58,7 +58,7 @@ - + diff --git a/Source/Informes/3/InfContratoCliente.fr3 b/Source/Informes/3/InfContratoCliente.fr3 index c3552c4..f35e079 100644 --- a/Source/Informes/3/InfContratoCliente.fr3 +++ b/Source/Informes/3/InfContratoCliente.fr3 @@ -1,5 +1,5 @@ - + @@ -58,7 +58,7 @@ - + diff --git a/Source/Informes/4/InfContratoCliente.fr3 b/Source/Informes/4/InfContratoCliente.fr3 index 86e2d6d..3e6b71d 100644 --- a/Source/Informes/4/InfContratoCliente.fr3 +++ b/Source/Informes/4/InfContratoCliente.fr3 @@ -1,5 +1,5 @@ - + @@ -55,7 +55,7 @@ - + diff --git a/Source/Servidor/uDataModuleServer.pas b/Source/Servidor/uDataModuleServer.pas index df1c363..4d2952f 100644 --- a/Source/Servidor/uDataModuleServer.pas +++ b/Source/Servidor/uDataModuleServer.pas @@ -174,11 +174,13 @@ procedure TdmServer.IniciarLog; begin FEscribirLog := TCriticalSection.Create; +{SE COMENTA PORQUE TUESTA LA PARTE SERVIDORA SI SE DESEA ARREGLAR ACTUALIZAR LAS JV de tecsitel JvLogFile1.Active := False; JvLogFile1.FileName := ExtractFilePath(Application.ExeName) + 'ServerLog.txt'; JvLogFile1.AutoSave := True; JvLogFile1.Active := True; JvLogFile1.Clear; +} end; procedure TdmServer.DataModuleCreate(Sender: TObject); @@ -278,12 +280,14 @@ end; procedure TdmServer.EscribirLog(const AMensaje: String); begin +{ FEscribirLog.Acquire; try JvLogFile1.Add(AMensaje); finally FEscribirLog.Release; end; +} end; procedure TdmServer.RefrescarConexion;