From ce7938424e629d65def3f9e9219f6b814c5effdf Mon Sep 17 00:00:00 2001
From: Richard Morales
Date: Mon, 25 Feb 2013 19:00:59 -0500
Subject: [PATCH] IDEMPIERE-638 Check log level before calling logging method /
log.fine
---
.../org/compiere/model/CalloutAssignment.java | 2 +-
.../compiere/model/CalloutCashJournal.java | 2 +-
.../org/compiere/model/CalloutGLJournal.java | 2 +-
.../src/org/compiere/model/CalloutInOut.java | 20 +++---
.../org/compiere/model/CalloutInvoice.java | 42 ++++++------
.../compiere/model/CalloutInvoiceBatch.java | 14 ++--
.../src/org/compiere/model/CalloutOrder.java | 44 ++++++------
.../compiere/model/CalloutPaySelection.java | 4 +-
.../org/compiere/model/CalloutPayment.java | 10 +--
.../model/CalloutPaymentAllocate.java | 2 +-
.../org/compiere/model/CalloutProject.java | 3 +-
.../compiere/model/CalloutRequisition.java | 3 +-
.../compiere/model/CalloutTimeExpense.java | 4 +-
.../src/org/compiere/process/Aging.java | 4 +-
.../org/compiere/process/AllocationAuto.java | 22 +++---
.../org/compiere/process/AllocationReset.java | 4 +-
.../org/compiere/process/AssetDelivery.java | 4 +-
.../src/org/compiere/process/BOMValidate.java | 4 +-
.../process/BankStatementMatcher.java | 6 +-
.../process/BankStatementPayment.java | 4 +-
.../org/compiere/process/CommissionCalc.java | 4 +-
.../org/compiere/process/DistributionRun.java | 34 +++++-----
.../org/compiere/process/DunningPrint.java | 2 +-
.../compiere/process/DunningRunCreate.java | 6 +-
.../org/compiere/process/ExpenseSOrder.java | 2 +-
.../org/compiere/process/FactAcctReset.java | 2 +-
.../org/compiere/process/ImportAccount.java | 38 +++++------
.../org/compiere/process/ImportBPartner.java | 28 ++++----
.../compiere/process/ImportBankStatement.java | 2 +-
.../process/ImportConversionRate.java | 12 ++--
.../org/compiere/process/ImportGLJournal.java | 62 ++++++++---------
.../compiere/process/ImportInOutConfirm.java | 4 +-
.../org/compiere/process/ImportInventory.java | 18 ++---
.../org/compiere/process/ImportInvoice.java | 62 ++++++++---------
.../src/org/compiere/process/ImportOrder.java | 66 +++++++++---------
.../org/compiere/process/ImportPayment.java | 10 +--
.../org/compiere/process/ImportProduct.java | 18 ++---
.../compiere/process/ImportReportLine.java | 24 +++----
.../org/compiere/process/InOutGenerate.java | 22 +++---
.../process/InventoryCountCreate.java | 8 +--
.../org/compiere/process/InventoryValue.java | 23 ++++---
.../org/compiere/process/InvoiceGenerate.java | 10 +--
.../org/compiere/process/InvoicePrint.java | 4 +-
.../compiere/process/M_PriceList_Create.java | 36 +++++-----
.../compiere/process/M_Product_BOM_Check.java | 2 +-
.../org/compiere/process/OrderPOCreate.java | 2 +-
.../org/compiere/process/OrgOwnership.java | 14 ++--
.../org/compiere/process/RegisterSystem.java | 2 +-
.../org/compiere/process/ReplenishReport.java | 42 ++++++------
.../process/ReplenishReportProduction.java | 46 ++++++-------
.../compiere/process/ReplicationLocal.java | 12 ++--
.../compiere/process/ReplicationRemote.java | 6 +-
.../process/RequestEMailProcessor.java | 6 +-
.../org/compiere/process/RfQResponseRank.java | 20 +++---
.../org/compiere/process/SendMailText.java | 4 +-
.../compiere/process/TableCreateColumns.java | 2 +-
.../org/compiere/process/TransactionXRef.java | 2 +-
.../org/compiere/process/UserPassword.java | 2 +-
.../impexp/AbstractExcelExporter.java | 3 +-
.../adempiere/impexp/GridTabCSVImporter.java | 3 +-
.../util/AbstractDocumentSearch.java | 17 ++---
.../org/adempiere/util/LogAuthFailure.java | 5 +-
.../src/org/adempiere/util/ProcessUtil.java | 2 +-
.../src/org/compiere/acct/Doc.java | 14 ++--
.../src/org/compiere/acct/DocLine.java | 3 +-
.../org/compiere/acct/Doc_AllocationHdr.java | 14 ++--
.../org/compiere/acct/Doc_BankStatement.java | 5 +-
.../src/org/compiere/acct/Doc_Cash.java | 4 +-
.../src/org/compiere/acct/Doc_GLJournal.java | 4 +-
.../src/org/compiere/acct/Doc_InOut.java | 6 +-
.../src/org/compiere/acct/Doc_Inventory.java | 5 +-
.../src/org/compiere/acct/Doc_Invoice.java | 12 ++--
.../src/org/compiere/acct/Doc_MatchInv.java | 13 ++--
.../src/org/compiere/acct/Doc_MatchPO.java | 4 +-
.../src/org/compiere/acct/Doc_Movement.java | 5 +-
.../src/org/compiere/acct/Doc_Order.java | 8 +--
.../src/org/compiere/acct/Doc_Production.java | 4 +-
.../org/compiere/acct/Doc_ProjectIssue.java | 6 +-
.../src/org/compiere/acct/Fact.java | 20 +++---
.../src/org/compiere/acct/FactLine.java | 16 ++---
.../src/org/compiere/acct/Matcher.java | 4 +-
.../src/org/compiere/cm/WebProjectDeploy.java | 2 +-
.../src/org/compiere/db/CConnection.java | 2 +-
.../src/org/compiere/db/StatementProxy.java | 2 +-
.../src/org/compiere/dbPort/Convert.java | 2 +-
.../src/org/compiere/impexp/ImpFormat.java | 2 +-
.../org/compiere/model/AccessSqlParser.java | 4 +-
.../src/org/compiere/model/ArchiveDB.java | 8 +--
.../org/compiere/model/ArchiveFileSystem.java | 6 +-
.../compiere/model/AttachmentDBSystem.java | 8 +--
.../compiere/model/AttachmentFileSystem.java | 18 ++---
.../src/org/compiere/model/GridField.java | 28 ++++----
.../src/org/compiere/model/GridTab.java | 68 +++++++++----------
.../src/org/compiere/model/GridTable.java | 52 +++++++-------
.../src/org/compiere/model/Lookup.java | 6 +-
.../src/org/compiere/model/MAccount.java | 2 +-
.../compiere/model/MAcctSchemaElement.java | 2 +-
.../org/compiere/model/MAllocationHdr.java | 4 +-
.../org/compiere/model/MAllocationLine.java | 14 ++--
.../src/org/compiere/model/MArchive.java | 2 +-
.../src/org/compiere/model/MAsset.java | 6 +-
.../org/compiere/model/MAssetAddition.java | 10 +--
.../src/org/compiere/model/MAssetChange.java | 5 +-
.../src/org/compiere/model/MAssetClass.java | 12 ++--
.../org/compiere/model/MAssetDisposed.java | 2 +-
.../src/org/compiere/model/MAttachment.java | 6 +-
.../src/org/compiere/model/MAttribute.java | 2 +-
.../src/org/compiere/model/MBPartner.java | 2 +-
.../org/compiere/model/MBankStatement.java | 3 +-
.../src/org/compiere/model/MCStage.java | 4 +-
.../src/org/compiere/model/MCash.java | 3 +-
.../src/org/compiere/model/MClick.java | 4 +-
.../src/org/compiere/model/MColor.java | 2 +-
.../src/org/compiere/model/MColumn.java | 2 +-
.../org/compiere/model/MContactInterest.java | 4 +-
.../src/org/compiere/model/MContainer.java | 7 +-
.../src/org/compiere/model/MDepreciation.java | 17 ++---
.../model/MDepreciationConvention.java | 6 +-
.../compiere/model/MDepreciationEntry.java | 4 +-
.../compiere/model/MDepreciationMethod.java | 9 +--
.../compiere/model/MDepreciationWorkfile.java | 17 ++---
.../org/compiere/model/MDiscountSchema.java | 6 +-
.../src/org/compiere/model/MDistribution.java | 3 +-
.../model/MDistributionRunDetail.java | 2 +-
.../src/org/compiere/model/MDocType.java | 5 +-
.../org/compiere/model/MDocTypeCounter.java | 2 +-
.../src/org/compiere/model/MIFixedAsset.java | 10 +--
.../src/org/compiere/model/MInOut.java | 24 +++----
.../src/org/compiere/model/MInOutConfirm.java | 2 +-
.../src/org/compiere/model/MInventory.java | 10 +--
.../src/org/compiere/model/MInvoice.java | 24 +++----
.../src/org/compiere/model/MInvoiceBatch.java | 2 +-
.../src/org/compiere/model/MInvoiceLine.java | 10 +--
.../org/compiere/model/MInvoiceSchedule.java | 9 +--
.../src/org/compiere/model/MJournal.java | 2 +-
.../src/org/compiere/model/MLanguage.java | 6 +-
.../org/compiere/model/MLocatorLookup.java | 4 +-
.../src/org/compiere/model/MLookup.java | 20 +++---
.../src/org/compiere/model/MMeasure.java | 6 +-
.../src/org/compiere/model/MMedia.java | 4 +-
.../src/org/compiere/model/MMovement.java | 8 +--
.../src/org/compiere/model/MOrder.java | 28 ++++----
.../src/org/compiere/model/MOrderLine.java | 12 ++--
.../src/org/compiere/model/MOrderTax.java | 2 +-
.../src/org/compiere/model/MPInstance.java | 2 +-
.../src/org/compiere/model/MPOS.java | 4 +-
.../src/org/compiere/model/MPayment.java | 22 +++---
.../org/compiere/model/MPaymentLookup.java | 2 +-
.../src/org/compiere/model/MPaymentTerm.java | 12 ++--
.../src/org/compiere/model/MPeriod.java | 4 +-
.../src/org/compiere/model/MPriceList.java | 3 +-
.../src/org/compiere/model/MProcessPara.java | 2 +-
.../src/org/compiere/model/MProduct.java | 3 +-
.../org/compiere/model/MProductPricing.java | 12 ++--
.../src/org/compiere/model/MProject.java | 2 +-
.../src/org/compiere/model/MProjectPhase.java | 2 +-
.../src/org/compiere/model/MRMA.java | 8 +--
.../src/org/compiere/model/MRMALine.java | 9 ++-
.../src/org/compiere/model/MRMATax.java | 2 +-
.../src/org/compiere/model/MRegistration.java | 4 +-
.../org/compiere/model/MRequisitionLine.java | 2 +-
.../src/org/compiere/model/MRole.java | 50 +++++++-------
.../src/org/compiere/model/MSchedule.java | 2 +-
.../src/org/compiere/model/MSequence.java | 2 +-
.../src/org/compiere/model/MSetup.java | 2 +-
.../src/org/compiere/model/MSysConfig.java | 2 +-
.../src/org/compiere/model/MTax.java | 3 +-
.../src/org/compiere/model/MTemplate.java | 4 +-
.../src/org/compiere/model/MTimeExpense.java | 2 +-
.../src/org/compiere/model/MTree.java | 2 +-
.../src/org/compiere/model/M_Element.java | 11 +--
.../src/org/compiere/model/PO.java | 32 ++++-----
.../src/org/compiere/model/PO_LOB.java | 4 +-
.../org/compiere/model/PaymentProcessor.java | 4 +-
.../src/org/compiere/model/ScheduleUtil.java | 2 +-
.../src/org/compiere/model/Tax.java | 24 ++++---
.../org/compiere/model/TranslationTable.java | 9 +--
.../src/org/compiere/print/CPaper.java | 7 +-
.../src/org/compiere/print/MPrintFormat.java | 2 +-
.../org/compiere/print/MPrintFormatItem.java | 2 +-
.../src/org/compiere/print/MPrintPaper.java | 6 +-
.../org/compiere/print/MPrintTableFormat.java | 2 +-
.../org/compiere/print/PrintFormatUtil.java | 6 +-
.../src/org/compiere/print/PrintUtil.java | 6 +-
.../src/org/compiere/print/ReportEngine.java | 6 +-
.../compiere/print/layout/HTMLElement.java | 3 +-
.../compiere/print/layout/ImageElement.java | 10 +--
.../compiere/print/layout/LayoutEngine.java | 2 +-
.../compiere/print/layout/PrintElement.java | 2 +-
.../compiere/print/layout/StringElement.java | 2 +-
.../compiere/print/layout/TableElement.java | 22 +++---
.../org/compiere/process/AdempiereServer.java | 2 +-
.../compiere/process/FactReconciliation.java | 2 +-
.../compiere/process/ServerProcessCtl.java | 10 +--
.../src/org/compiere/process/SvrProcess.java | 4 +-
.../src/org/compiere/report/FinReport.java | 40 +++++------
.../src/org/compiere/report/FinStatement.java | 10 +--
.../org/compiere/report/MReportColumn.java | 2 +-
.../src/org/compiere/report/MReportTree.java | 4 +-
.../src/org/compiere/report/TrialBalance.java | 14 ++--
.../src/org/compiere/report/core/RModel.java | 2 +-
.../org/compiere/report/core/RModelData.java | 10 +--
.../src/org/compiere/util/CacheMgt.java | 11 +--
.../src/org/compiere/util/DB.java | 16 ++---
.../src/org/compiere/util/EMail.java | 10 +--
.../src/org/compiere/util/FileUpload.java | 8 +--
.../src/org/compiere/util/Login.java | 12 ++--
.../src/org/compiere/util/Task.java | 2 +-
.../src/org/compiere/util/Trace.java | 3 +-
.../src/org/compiere/util/WebInfo.java | 52 +++++++-------
.../src/org/compiere/util/WebLogin.java | 8 +--
.../src/org/compiere/util/WebSessionCtx.java | 4 +-
.../src/org/compiere/util/WebUser.java | 36 +++++-----
.../src/org/compiere/util/WebUtil.java | 12 ++--
.../org/compiere/wf/DocWorkflowManager.java | 4 +-
.../src/org/compiere/wf/MWFActivity.java | 42 ++++++------
.../src/org/compiere/wf/MWFNextCondition.java | 9 +--
.../src/org/compiere/wf/MWFNode.java | 5 +-
.../src/org/compiere/wf/MWFNodeNext.java | 7 +-
.../src/org/compiere/wf/MWFProcess.java | 4 +-
.../src/org/compiere/wf/MWorkflow.java | 6 +-
.../src/org/eevolution/model/MDDOrder.java | 8 +--
.../process/ImportInventoryMove.java | 2 +-
.../org/idempiere/fa/feature/UseLifeImpl.java | 29 ++++----
.../fa/process/ImportFixedAsset.java | 12 ++--
.../compiere/install/ConfigurationData.java | 8 +--
.../src/org/compiere/install/KeyStoreMgt.java | 10 +--
.../src/org/compiere/model/PP_Optimal.java | 6 +-
.../src/org/compiere/model/PP_PayFlowPro.java | 6 +-
.../org/compiere/model/PP_PayFlowPro4.java | 2 +-
.../compiere/server/ReplicationProcessor.java | 9 +--
.../process/rpl/exp/ExportHelper.java | 4 +-
.../compiere/server/AdempiereServerGroup.java | 10 +--
.../compiere/server/AdempiereServerMgr.java | 6 +-
.../org/compiere/server/AlertProcessor.java | 2 +-
.../org/compiere/server/EMailProcessor.java | 6 +-
.../server/org/compiere/server/Scheduler.java | 10 +--
.../src/org/compiere/apps/APanel.java | 4 +-
.../org/compiere/apps/ClientProcessCtrl.java | 3 +-
.../src/org/compiere/apps/ProcessCtl.java | 4 +-
.../org/compiere/apps/ProcessParameter.java | 2 +-
.../compiere/apps/ProcessParameterPanel.java | 4 +-
.../src/org/compiere/apps/Waiting.java | 2 +-
.../src/org/compiere/apps/form/VBOMDrop.java | 8 +--
.../compiere/apps/form/VResetPassword.java | 4 +-
.../src/org/compiere/apps/search/Find.java | 6 +-
.../src/org/compiere/apps/search/Info.java | 12 ++--
.../org/compiere/apps/search/InfoAsset.java | 5 +-
.../compiere/apps/search/InfoBPartner.java | 13 ++--
.../compiere/apps/search/InfoCashLine.java | 15 ++--
.../org/compiere/apps/search/InfoGeneral.java | 2 +-
.../org/compiere/apps/search/InfoInOut.java | 7 +-
.../org/compiere/apps/search/InfoInvoice.java | 11 +--
.../org/compiere/apps/search/InfoOrder.java | 8 +--
.../org/compiere/apps/search/InfoPayment.java | 11 +--
.../org/compiere/apps/search/InfoProduct.java | 18 ++---
.../compiere/apps/search/InvoiceHistory.java | 8 +--
.../apps/search/PAttributeInstance.java | 2 +-
.../compiere/apps/search/VSchedulePanel.java | 2 +-
.../src/org/compiere/apps/wf/WFActivity.java | 4 +-
.../src/org/compiere/apps/wf/WFPanel.java | 6 +-
.../org/compiere/grid/RecordAccessDialog.java | 10 +--
.../src/org/compiere/grid/VSortTab.java | 14 ++--
.../org/compiere/grid/VTableExcelAdapter.java | 2 +-
.../grid/ed/ComboSelectionManager.java | 4 +-
.../src/org/compiere/grid/ed/Editor.java | 2 +-
.../src/org/compiere/grid/ed/MDocDate.java | 2 +-
.../src/org/compiere/grid/ed/MDocNumber.java | 2 +-
.../src/org/compiere/grid/ed/MDocString.java | 2 +-
.../org/compiere/grid/ed/VAccountDialog.java | 8 +--
.../src/org/compiere/grid/ed/VBPartner.java | 6 +-
.../src/org/compiere/grid/ed/VCellEditor.java | 4 +-
.../src/org/compiere/grid/ed/VColor.java | 4 +-
.../src/org/compiere/grid/ed/VDate.java | 2 +-
.../src/org/compiere/grid/ed/VDocAction.java | 4 +-
.../src/org/compiere/grid/ed/VImage.java | 3 +-
.../org/compiere/grid/ed/VLocationDialog.java | 8 +--
.../org/compiere/grid/ed/VLocatorDialog.java | 4 +-
.../src/org/compiere/grid/ed/VLookup.java | 22 +++---
.../src/org/compiere/grid/ed/VPAttribute.java | 2 +-
.../compiere/grid/ed/VPAttributeDialog.java | 22 +++---
.../org/compiere/grid/ed/VPaymentEditor.java | 12 ++--
.../org/compiere/grid/ed/VRowIDEditor.java | 5 +-
.../org/compiere/grid/ed/ValuePreference.java | 4 +-
.../grid/tree/AdempiereTreeModel.java | 2 +-
.../org/compiere/grid/tree/VTreePanel.java | 4 +-
.../src/org/compiere/pos/PosKeyPanel.java | 5 +-
.../compiere/pos/PosKeyboardFocusManager.java | 5 +-
.../src/org/compiere/pos/PosOrderModel.java | 3 +-
.../src/org/compiere/pos/QueryBPartner.java | 5 +-
.../src/org/compiere/pos/QueryProduct.java | 5 +-
.../src/org/compiere/pos/SubCurrentLine.java | 4 +-
.../src/org/compiere/pos/SubOrder.java | 3 +-
.../org/compiere/report/core/ResultTable.java | 4 +-
.../src/org/compiere/swing/ColorBlind.java | 2 +-
.../org/adempiere/webui/ValuePreference.java | 4 +-
.../src/org/adempiere/webui/WZoomAcross.java | 2 +-
.../adempiere/webui/adwindow/ADSortTab.java | 14 ++--
.../webui/apps/ProcessParameterPanel.java | 4 +-
.../org/adempiere/webui/apps/WProcessCtl.java | 6 +-
.../adempiere/webui/apps/form/WBOMDrop.java | 8 +--
.../webui/apps/form/WResetPassword.java | 4 +-
.../org/adempiere/webui/apps/wf/WFPanel.java | 2 +-
.../adempiere/webui/apps/wf/WWFActivity.java | 4 +-
.../webui/component/ADTreeOnDropListener.java | 8 ++-
.../webui/dashboard/RequestWindow.java | 3 +-
.../adempiere/webui/editor/WImageEditor.java | 2 +-
.../webui/editor/WPAttributeEditor.java | 2 +-
.../org/adempiere/webui/grid/WBPartner.java | 6 +-
.../adempiere/webui/panel/InfoAssetPanel.java | 5 +-
.../webui/panel/InfoBPartnerPanel.java | 13 ++--
.../webui/panel/InfoCashLinePanel.java | 13 ++--
.../webui/panel/InfoGeneralPanel.java | 2 +-
.../adempiere/webui/panel/InfoInOutPanel.java | 7 +-
.../webui/panel/InfoInvoicePanel.java | 8 +--
.../adempiere/webui/panel/InfoOrderPanel.java | 6 +-
.../panel/InfoPAttributeInstancePanel.java | 2 +-
.../webui/panel/InfoPaymentPanel.java | 11 +--
.../webui/panel/InfoProductPanel.java | 20 +++---
.../adempiere/webui/panel/InvoiceHistory.java | 8 +--
.../adempiere/webui/process/InvoicePrint.java | 4 +-
.../adempiere/webui/window/FindWindow.java | 4 +-
.../webui/window/WAccountDialog.java | 8 +--
.../webui/window/WLocationDialog.java | 2 +-
.../webui/window/WLocatorDialog.java | 4 +-
.../webui/window/WPAttributeDialog.java | 24 +++----
.../webui/window/WPAttributeInstance.java | 2 +-
.../webui/window/WRecordAccessDialog.java | 10 +--
.../org/compiere/apps/AbstractProcessCtl.java | 12 ++--
.../org/compiere/apps/form/Allocation.java | 16 ++---
.../src/org/compiere/apps/form/Archive.java | 2 +-
.../org/compiere/apps/form/FactReconcile.java | 2 +-
.../src/org/compiere/apps/form/Match.java | 6 +-
.../src/org/compiere/apps/form/Merge.java | 4 +-
.../src/org/compiere/apps/form/PaySelect.java | 2 +-
.../apps/form/StatementCreateFromBatch.java | 12 ++--
.../org/compiere/apps/form/TrxMaterial.java | 10 +--
.../org/compiere/grid/CreateFromBatch.java | 9 +--
.../compiere/grid/CreateFromDepositBatch.java | 2 +-
.../org/compiere/grid/CreateFromInvoice.java | 6 +-
.../org/compiere/grid/CreateFromShipment.java | 2 +-
.../compiere/grid/CreateFromStatement.java | 2 +-
.../org/compiere/grid/PaymentFormCash.java | 8 +--
.../org/compiere/grid/PaymentFormCheck.java | 12 ++--
.../compiere/grid/PaymentFormCreditCard.java | 13 ++--
.../org/compiere/grid/PaymentFormDirect.java | 10 +--
.../compiere/install/TranslationHandler.java | 7 +-
.../src/org/compiere/wstore/AssetServlet.java | 6 +-
.../org/compiere/wstore/BasketServlet.java | 16 ++---
.../org/compiere/wstore/CheckOutLinkTag.java | 3 +-
.../src/org/compiere/wstore/Click.java | 5 +-
.../src/org/compiere/wstore/InfoLinkTag.java | 3 +-
.../src/org/compiere/wstore/InfoServlet.java | 2 +-
.../org/compiere/wstore/InvoiceServlet.java | 6 +-
.../src/org/compiere/wstore/LocationTag.java | 2 +-
.../src/org/compiere/wstore/LoginServlet.java | 3 +-
.../src/org/compiere/wstore/MessageTag.java | 3 +-
.../src/org/compiere/wstore/NoteServlet.java | 7 +-
.../src/org/compiere/wstore/OrderServlet.java | 5 +-
.../org/compiere/wstore/PaymentServlet.java | 3 +-
.../src/org/compiere/wstore/PriceList.java | 2 +-
.../src/org/compiere/wstore/PriceListTag.java | 5 +-
.../wstore/ProductCategoryListTag.java | 3 +-
.../compiere/wstore/RequestOrderRefTag.java | 2 +-
.../org/compiere/wstore/RequestServlet.java | 10 +--
.../org/compiere/wstore/RequestTypeTag.java | 2 +-
.../src/org/compiere/wstore/RfQServlet.java | 10 +--
.../src/org/compiere/wstore/WebOrder.java | 5 +-
.../org/compiere/wstore/WorkflowServlet.java | 9 +--
.../db/oracle/config/ConfigOracle.java | 2 +-
.../fitnesse/fixture/RunProcess.java | 7 +-
.../org/idempiere/adinterface/Process.java | 6 +-
372 files changed, 1655 insertions(+), 1587 deletions(-)
diff --git a/org.adempiere.base.callout/src/org/compiere/model/CalloutAssignment.java b/org.adempiere.base.callout/src/org/compiere/model/CalloutAssignment.java
index 943f3ee846..261275993e 100644
--- a/org.adempiere.base.callout/src/org/compiere/model/CalloutAssignment.java
+++ b/org.adempiere.base.callout/src/org/compiere/model/CalloutAssignment.java
@@ -89,7 +89,7 @@ public class CalloutAssignment extends CalloutEngine
rs = null; pstmt = null;
}
- log.fine("S_ResourceAssignment_ID=" + S_ResourceAssignment_ID + " - M_Product_ID=" + M_Product_ID);
+ if (log.isLoggable(Level.FINE)) log.fine("S_ResourceAssignment_ID=" + S_ResourceAssignment_ID + " - M_Product_ID=" + M_Product_ID);
if (M_Product_ID != 0)
{
mTab.setValue ("M_Product_ID", new Integer (M_Product_ID));
diff --git a/org.adempiere.base.callout/src/org/compiere/model/CalloutCashJournal.java b/org.adempiere.base.callout/src/org/compiere/model/CalloutCashJournal.java
index 309e754421..e7b9bf305e 100644
--- a/org.adempiere.base.callout/src/org/compiere/model/CalloutCashJournal.java
+++ b/org.adempiere.base.callout/src/org/compiere/model/CalloutCashJournal.java
@@ -140,7 +140,7 @@ public class CalloutCashJournal extends CalloutEngine
BigDecimal DiscountAmt = (BigDecimal)mTab.getValue("DiscountAmt");
BigDecimal WriteOffAmt = (BigDecimal)mTab.getValue("WriteOffAmt");
String colName = mField.getColumnName();
- log.fine(colName + " - Invoice=" + InvTotalAmt
+ if (log.isLoggable(Level.FINE)) log.fine(colName + " - Invoice=" + InvTotalAmt
+ " - Amount=" + PayAmt + ", Discount=" + DiscountAmt + ", WriteOff=" + WriteOffAmt);
// Amount - calculate write off
diff --git a/org.adempiere.base.callout/src/org/compiere/model/CalloutGLJournal.java b/org.adempiere.base.callout/src/org/compiere/model/CalloutGLJournal.java
index 39f277d93a..048d34e40a 100644
--- a/org.adempiere.base.callout/src/org/compiere/model/CalloutGLJournal.java
+++ b/org.adempiere.base.callout/src/org/compiere/model/CalloutGLJournal.java
@@ -177,7 +177,7 @@ public class CalloutGLJournal extends CalloutEngine
BigDecimal CurrencyRate = MConversionRate.getRate(C_Currency_ID, as.getC_Currency_ID(),
DateAcct, C_ConversionType_ID, AD_Client_ID, AD_Org_ID);
- log.fine("rate = " + CurrencyRate);
+ if (log.isLoggable(Level.FINE)) log.fine("rate = " + CurrencyRate);
if (CurrencyRate == null)
CurrencyRate = Env.ZERO;
mTab.setValue("CurrencyRate", CurrencyRate);
diff --git a/org.adempiere.base.callout/src/org/compiere/model/CalloutInOut.java b/org.adempiere.base.callout/src/org/compiere/model/CalloutInOut.java
index c2e534e419..e9a0ed8da2 100644
--- a/org.adempiere.base.callout/src/org/compiere/model/CalloutInOut.java
+++ b/org.adempiere.base.callout/src/org/compiere/model/CalloutInOut.java
@@ -530,10 +530,10 @@ public class CalloutInOut extends CalloutEngine
if (M_Warehouse_ID == loc.getM_Warehouse_ID())
mTab.setValue("M_Locator_ID", new Integer (product.getM_Locator_ID()));
else
- log.fine("No Locator for M_Product_ID=" + M_Product_ID + " and M_Warehouse_ID=" + M_Warehouse_ID);
+ if (log.isLoggable(Level.FINE)) log.fine("No Locator for M_Product_ID=" + M_Product_ID + " and M_Warehouse_ID=" + M_Warehouse_ID);
}
else
- log.fine("No Locator for M_Product_ID=" + M_Product_ID);
+ if (log.isLoggable(Level.FINE)) log.fine("No Locator for M_Product_ID=" + M_Product_ID);
return "";
} // product
@@ -571,7 +571,7 @@ public class CalloutInOut extends CalloutEngine
BigDecimal QtyEntered1 = QtyEntered.setScale(MUOM.getPrecision(ctx, C_UOM_To_ID), BigDecimal.ROUND_HALF_UP);
if (QtyEntered.compareTo(QtyEntered1) != 0)
{
- log.fine("Corrected QtyEntered Scale UOM=" + C_UOM_To_ID
+ if (log.isLoggable(Level.FINE)) log.fine("Corrected QtyEntered Scale UOM=" + C_UOM_To_ID
+ "; QtyEntered=" + QtyEntered + "->" + QtyEntered1);
QtyEntered = QtyEntered1;
mTab.setValue("QtyEntered", QtyEntered);
@@ -581,7 +581,7 @@ public class CalloutInOut extends CalloutEngine
if (MovementQty == null)
MovementQty = QtyEntered;
boolean conversion = QtyEntered.compareTo(MovementQty) != 0;
- log.fine("UOM=" + C_UOM_To_ID
+ if (log.isLoggable(Level.FINE)) log.fine("UOM=" + C_UOM_To_ID
+ ", QtyEntered=" + QtyEntered
+ " -> " + conversion
+ " MovementQty=" + MovementQty);
@@ -602,7 +602,7 @@ public class CalloutInOut extends CalloutEngine
BigDecimal QtyEntered1 = QtyEntered.setScale(MUOM.getPrecision(ctx, C_UOM_To_ID), BigDecimal.ROUND_HALF_UP);
if (QtyEntered.compareTo(QtyEntered1) != 0)
{
- log.fine("Corrected QtyEntered Scale UOM=" + C_UOM_To_ID
+ if (log.isLoggable(Level.FINE)) log.fine("Corrected QtyEntered Scale UOM=" + C_UOM_To_ID
+ "; QtyEntered=" + QtyEntered + "->" + QtyEntered1);
QtyEntered = QtyEntered1;
mTab.setValue("QtyEntered", QtyEntered);
@@ -612,7 +612,7 @@ public class CalloutInOut extends CalloutEngine
if (MovementQty == null)
MovementQty = QtyEntered;
boolean conversion = QtyEntered.compareTo(MovementQty) != 0;
- log.fine("UOM=" + C_UOM_To_ID
+ if (log.isLoggable(Level.FINE)) log.fine("UOM=" + C_UOM_To_ID
+ ", QtyEntered=" + QtyEntered
+ " -> " + conversion
+ " MovementQty=" + MovementQty);
@@ -628,7 +628,7 @@ public class CalloutInOut extends CalloutEngine
BigDecimal MovementQty1 = MovementQty.setScale(precision, BigDecimal.ROUND_HALF_UP);
if (MovementQty.compareTo(MovementQty1) != 0)
{
- log.fine("Corrected MovementQty "
+ if (log.isLoggable(Level.FINE)) log.fine("Corrected MovementQty "
+ MovementQty + "->" + MovementQty1);
MovementQty = MovementQty1;
mTab.setValue("MovementQty", MovementQty);
@@ -638,7 +638,7 @@ public class CalloutInOut extends CalloutEngine
if (QtyEntered == null)
QtyEntered = MovementQty;
boolean conversion = MovementQty.compareTo(QtyEntered) != 0;
- log.fine("UOM=" + C_UOM_To_ID
+ if (log.isLoggable(Level.FINE)) log.fine("UOM=" + C_UOM_To_ID
+ ", MovementQty=" + MovementQty
+ " -> " + conversion
+ " QtyEntered=" + QtyEntered);
@@ -669,7 +669,7 @@ public class CalloutInOut extends CalloutEngine
int M_Product_ID = Env.getContextAsInt(ctx, WindowNo, "M_Product_ID");
int M_Warehouse_ID = Env.getContextAsInt(ctx, WindowNo, "M_Warehouse_ID");
int M_Locator_ID = Env.getContextAsInt(ctx, WindowNo, "M_Locator_ID");
- log.fine("M_Product_ID=" + M_Product_ID
+ if (log.isLoggable(Level.FINE)) log.fine("M_Product_ID=" + M_Product_ID
+ ", M_ASI_ID=" + M_ASI_ID
+ " - M_Warehouse_ID=" + M_Warehouse_ID
+ ", M_Locator_ID=" + M_Locator_ID);
@@ -680,7 +680,7 @@ public class CalloutInOut extends CalloutEngine
int selectedM_Locator_ID = Env.getContextAsInt(Env.getCtx(), WindowNo, Env.TAB_INFO, "M_Locator_ID");
if (selectedM_Locator_ID != 0)
{
- log.fine("Selected M_Locator_ID=" + selectedM_Locator_ID);
+ if (log.isLoggable(Level.FINE)) log.fine("Selected M_Locator_ID=" + selectedM_Locator_ID);
mTab.setValue("M_Locator_ID", new Integer (selectedM_Locator_ID));
}
}
diff --git a/org.adempiere.base.callout/src/org/compiere/model/CalloutInvoice.java b/org.adempiere.base.callout/src/org/compiere/model/CalloutInvoice.java
index 2160da04ae..3ef217b696 100644
--- a/org.adempiere.base.callout/src/org/compiere/model/CalloutInvoice.java
+++ b/org.adempiere.base.callout/src/org/compiere/model/CalloutInvoice.java
@@ -439,7 +439,7 @@ public class CalloutInvoice extends CalloutEngine
C_Charge_ID = ((Integer)value).intValue();
else
C_Charge_ID = Env.getContextAsInt(ctx, WindowNo, "C_Charge_ID");
- log.fine("Product=" + M_Product_ID + ", C_Charge_ID=" + C_Charge_ID);
+ if (log.isLoggable(Level.FINE)) log.fine("Product=" + M_Product_ID + ", C_Charge_ID=" + C_Charge_ID);
if (M_Product_ID == 0 && C_Charge_ID == 0)
return amt (ctx, WindowNo, mTab, mField, value); //
@@ -447,21 +447,21 @@ public class CalloutInvoice extends CalloutEngine
int shipC_BPartner_Location_ID = Env.getContextAsInt(ctx, WindowNo, "C_BPartner_Location_ID");
if (shipC_BPartner_Location_ID == 0)
return amt (ctx, WindowNo, mTab, mField, value); //
- log.fine("Ship BP_Location=" + shipC_BPartner_Location_ID);
+ if (log.isLoggable(Level.FINE)) log.fine("Ship BP_Location=" + shipC_BPartner_Location_ID);
int billC_BPartner_Location_ID = shipC_BPartner_Location_ID;
- log.fine("Bill BP_Location=" + billC_BPartner_Location_ID);
+ if (log.isLoggable(Level.FINE)) log.fine("Bill BP_Location=" + billC_BPartner_Location_ID);
// Dates
Timestamp billDate = Env.getContextAsDate(ctx, WindowNo, "DateInvoiced");
- log.fine("Bill Date=" + billDate);
+ if (log.isLoggable(Level.FINE)) log.fine("Bill Date=" + billDate);
Timestamp shipDate = billDate;
- log.fine("Ship Date=" + shipDate);
+ if (log.isLoggable(Level.FINE)) log.fine("Ship Date=" + shipDate);
int AD_Org_ID = Env.getContextAsInt(ctx, WindowNo, "AD_Org_ID");
- log.fine("Org=" + AD_Org_ID);
+ if (log.isLoggable(Level.FINE)) log.fine("Org=" + AD_Org_ID);
int M_Warehouse_ID = Env.getContextAsInt(ctx, "#M_Warehouse_ID");
- log.fine("Warehouse=" + M_Warehouse_ID);
+ if (log.isLoggable(Level.FINE)) log.fine("Warehouse=" + M_Warehouse_ID);
//
int C_Tax_ID = Tax.get(ctx, M_Product_ID, C_Charge_ID, billDate, shipDate,
@@ -503,15 +503,17 @@ public class CalloutInvoice extends CalloutEngine
// get values
QtyEntered = (BigDecimal)mTab.getValue("QtyEntered");
QtyInvoiced = (BigDecimal)mTab.getValue("QtyInvoiced");
- log.fine("QtyEntered=" + QtyEntered + ", Invoiced=" + QtyInvoiced + ", UOM=" + C_UOM_To_ID);
+ if (log.isLoggable(Level.FINE)) log.fine("QtyEntered=" + QtyEntered + ", Invoiced=" + QtyInvoiced + ", UOM=" + C_UOM_To_ID);
//
PriceEntered = (BigDecimal)mTab.getValue("PriceEntered");
PriceActual = (BigDecimal)mTab.getValue("PriceActual");
// Discount = (BigDecimal)mTab.getValue("Discount");
PriceLimit = (BigDecimal)mTab.getValue("PriceLimit");
PriceList = (BigDecimal)mTab.getValue("PriceList");
- log.fine("PriceList=" + PriceList + ", Limit=" + PriceLimit + ", Precision=" + StdPrecision);
- log.fine("PriceEntered=" + PriceEntered + ", Actual=" + PriceActual);// + ", Discount=" + Discount);
+ if (log.isLoggable(Level.FINE)){
+ log.fine("PriceList=" + PriceList + ", Limit=" + PriceLimit + ", Precision=" + StdPrecision);
+ log.fine("PriceEntered=" + PriceEntered + ", Actual=" + PriceActual);// + ", Discount=" + Discount);
+ }
// No Product
if ( M_Product_ID == 0 )
@@ -555,7 +557,7 @@ public class CalloutInvoice extends CalloutEngine
if (PriceEntered == null)
PriceEntered = pp.getPriceStd();
//
- log.fine("amt - QtyChanged -> PriceActual=" + pp.getPriceStd()
+ if (log.isLoggable(Level.FINE)) log.fine("amt - QtyChanged -> PriceActual=" + pp.getPriceStd()
+ ", PriceEntered=" + PriceEntered + ", Discount=" + pp.getDiscount());
PriceActual = pp.getPriceStd();
mTab.setValue("PriceActual", pp.getPriceStd());
@@ -571,7 +573,7 @@ public class CalloutInvoice extends CalloutEngine
if (PriceEntered == null)
PriceEntered = PriceActual;
//
- log.fine("amt - PriceActual=" + PriceActual
+ if (log.isLoggable(Level.FINE)) log.fine("amt - PriceActual=" + PriceActual
+ " -> PriceEntered=" + PriceEntered);
mTab.setValue("PriceEntered", PriceEntered);
}
@@ -583,7 +585,7 @@ public class CalloutInvoice extends CalloutEngine
if (PriceActual == null)
PriceActual = PriceEntered;
//
- log.fine("amt - PriceEntered=" + PriceEntered
+ if (log.isLoggable(Level.FINE)) log.fine("amt - PriceEntered=" + PriceEntered
+ " -> PriceActual=" + PriceActual);
mTab.setValue("PriceActual", PriceActual);
}
@@ -629,7 +631,7 @@ public class CalloutInvoice extends CalloutEngine
C_UOM_To_ID, PriceLimit);
if (PriceEntered == null)
PriceEntered = PriceLimit;
- log.fine("amt =(under) PriceEntered=" + PriceEntered + ", Actual" + PriceLimit);
+ if (log.isLoggable(Level.FINE)) log.fine("amt =(under) PriceEntered=" + PriceEntered + ", Actual" + PriceLimit);
mTab.setValue ("PriceActual", PriceLimit);
mTab.setValue ("PriceEntered", PriceEntered);
mTab.fireDataStatusEEvent ("UnderLimitPrice", "", false);
@@ -735,7 +737,7 @@ public class CalloutInvoice extends CalloutEngine
BigDecimal QtyEntered1 = QtyEntered.setScale(MUOM.getPrecision(ctx, C_UOM_To_ID), BigDecimal.ROUND_HALF_UP);
if (QtyEntered.compareTo(QtyEntered1) != 0)
{
- log.fine("Corrected QtyEntered Scale UOM=" + C_UOM_To_ID
+ if (log.isLoggable(Level.FINE)) log.fine("Corrected QtyEntered Scale UOM=" + C_UOM_To_ID
+ "; QtyEntered=" + QtyEntered + "->" + QtyEntered1);
QtyEntered = QtyEntered1;
mTab.setValue("QtyEntered", QtyEntered);
@@ -750,7 +752,7 @@ public class CalloutInvoice extends CalloutEngine
C_UOM_To_ID, PriceActual);
if (PriceEntered == null)
PriceEntered = PriceActual;
- log.fine("qty - UOM=" + C_UOM_To_ID
+ if (log.isLoggable(Level.FINE)) log.fine("qty - UOM=" + C_UOM_To_ID
+ ", QtyEntered/PriceActual=" + QtyEntered + "/" + PriceActual
+ " -> " + conversion
+ " QtyInvoiced/PriceEntered=" + QtyInvoiced + "/" + PriceEntered);
@@ -766,7 +768,7 @@ public class CalloutInvoice extends CalloutEngine
BigDecimal QtyEntered1 = QtyEntered.setScale(MUOM.getPrecision(ctx, C_UOM_To_ID), BigDecimal.ROUND_HALF_UP);
if (QtyEntered.compareTo(QtyEntered1) != 0)
{
- log.fine("Corrected QtyEntered Scale UOM=" + C_UOM_To_ID
+ if (log.isLoggable(Level.FINE)) log.fine("Corrected QtyEntered Scale UOM=" + C_UOM_To_ID
+ "; QtyEntered=" + QtyEntered + "->" + QtyEntered1);
QtyEntered = QtyEntered1;
mTab.setValue("QtyEntered", QtyEntered);
@@ -776,7 +778,7 @@ public class CalloutInvoice extends CalloutEngine
if (QtyInvoiced == null)
QtyInvoiced = QtyEntered;
boolean conversion = QtyEntered.compareTo(QtyInvoiced) != 0;
- log.fine("qty - UOM=" + C_UOM_To_ID
+ if (log.isLoggable(Level.FINE)) log.fine("qty - UOM=" + C_UOM_To_ID
+ ", QtyEntered=" + QtyEntered
+ " -> " + conversion
+ " QtyInvoiced=" + QtyInvoiced);
@@ -792,7 +794,7 @@ public class CalloutInvoice extends CalloutEngine
BigDecimal QtyInvoiced1 = QtyInvoiced.setScale(precision, BigDecimal.ROUND_HALF_UP);
if (QtyInvoiced.compareTo(QtyInvoiced1) != 0)
{
- log.fine("Corrected QtyInvoiced Scale "
+ if (log.isLoggable(Level.FINE)) log.fine("Corrected QtyInvoiced Scale "
+ QtyInvoiced + "->" + QtyInvoiced1);
QtyInvoiced = QtyInvoiced1;
mTab.setValue("QtyInvoiced", QtyInvoiced);
@@ -802,7 +804,7 @@ public class CalloutInvoice extends CalloutEngine
if (QtyEntered == null)
QtyEntered = QtyInvoiced;
boolean conversion = QtyInvoiced.compareTo(QtyEntered) != 0;
- log.fine("qty - UOM=" + C_UOM_To_ID
+ if (log.isLoggable(Level.FINE)) log.fine("qty - UOM=" + C_UOM_To_ID
+ ", QtyInvoiced=" + QtyInvoiced
+ " -> " + conversion
+ " QtyEntered=" + QtyEntered);
diff --git a/org.adempiere.base.callout/src/org/compiere/model/CalloutInvoiceBatch.java b/org.adempiere.base.callout/src/org/compiere/model/CalloutInvoiceBatch.java
index 49f5f6dd06..12c51fc002 100644
--- a/org.adempiere.base.callout/src/org/compiere/model/CalloutInvoiceBatch.java
+++ b/org.adempiere.base.callout/src/org/compiere/model/CalloutInvoiceBatch.java
@@ -298,7 +298,7 @@ public class CalloutInvoiceBatch extends CalloutEngine
C_Charge_ID = ((Integer)value).intValue();
else
C_Charge_ID = Env.getContextAsInt(ctx, WindowNo, "C_Charge_ID");
- log.fine("C_Charge_ID=" + C_Charge_ID);
+ if (log.isLoggable(Level.FINE)) log.fine("C_Charge_ID=" + C_Charge_ID);
if (C_Charge_ID == 0)
return amt (ctx, WindowNo, mTab, mField, value); //
@@ -306,19 +306,19 @@ public class CalloutInvoiceBatch extends CalloutEngine
int C_BPartner_Location_ID = Env.getContextAsInt(ctx, WindowNo, "C_BPartner_Location_ID");
if (C_BPartner_Location_ID == 0)
return amt (ctx, WindowNo, mTab, mField, value); //
- log.fine("BP_Location=" + C_BPartner_Location_ID);
+ if (log.isLoggable(Level.FINE)) log.fine("BP_Location=" + C_BPartner_Location_ID);
// Dates
Timestamp billDate = Env.getContextAsDate(ctx, WindowNo, "DateInvoiced");
- log.fine("Bill Date=" + billDate);
+ if (log.isLoggable(Level.FINE)) log.fine("Bill Date=" + billDate);
Timestamp shipDate = billDate;
- log.fine("Ship Date=" + shipDate);
+ if (log.isLoggable(Level.FINE)) log.fine("Ship Date=" + shipDate);
int AD_Org_ID = Env.getContextAsInt(ctx, WindowNo, "AD_Org_ID");
- log.fine("Org=" + AD_Org_ID);
+ if (log.isLoggable(Level.FINE)) log.fine("Org=" + AD_Org_ID);
int M_Warehouse_ID = Env.getContextAsInt(ctx, "#M_Warehouse_ID");
- log.fine("Warehouse=" + M_Warehouse_ID);
+ if (log.isLoggable(Level.FINE)) log.fine("Warehouse=" + M_Warehouse_ID);
//
int C_Tax_ID = Tax.get(ctx, 0, C_Charge_ID, billDate, shipDate,
@@ -356,7 +356,7 @@ public class CalloutInvoiceBatch extends CalloutEngine
// get values
BigDecimal QtyEntered = (BigDecimal)mTab.getValue("QtyEntered");
BigDecimal PriceEntered = (BigDecimal)mTab.getValue("PriceEntered");
- log.fine("QtyEntered=" + QtyEntered + ", PriceEntered=" + PriceEntered);
+ if (log.isLoggable(Level.FINE)) log.fine("QtyEntered=" + QtyEntered + ", PriceEntered=" + PriceEntered);
if (QtyEntered == null)
QtyEntered = Env.ZERO;
if (PriceEntered == null)
diff --git a/org.adempiere.base.callout/src/org/compiere/model/CalloutOrder.java b/org.adempiere.base.callout/src/org/compiere/model/CalloutOrder.java
index 1498491f5d..1101a2595f 100644
--- a/org.adempiere.base.callout/src/org/compiere/model/CalloutOrder.java
+++ b/org.adempiere.base.callout/src/org/compiere/model/CalloutOrder.java
@@ -945,7 +945,7 @@ public class CalloutOrder extends CalloutEngine
C_Charge_ID = ((Integer)value).intValue();
else
C_Charge_ID = Env.getContextAsInt(ctx, WindowNo, "C_Charge_ID");
- log.fine("Product=" + M_Product_ID + ", C_Charge_ID=" + C_Charge_ID);
+ if (log.isLoggable(Level.FINE)) log.fine("Product=" + M_Product_ID + ", C_Charge_ID=" + C_Charge_ID);
if (M_Product_ID == 0 && C_Charge_ID == 0)
return amt(ctx, WindowNo, mTab, mField, value); //
@@ -957,25 +957,25 @@ public class CalloutOrder extends CalloutEngine
shipC_BPartner_Location_ID = Env.getContextAsInt(ctx, WindowNo, "C_BPartner_Location_ID");
if (shipC_BPartner_Location_ID == 0)
return amt(ctx, WindowNo, mTab, mField, value); //
- log.fine("Ship BP_Location=" + shipC_BPartner_Location_ID);
+ if (log.isLoggable(Level.FINE)) log.fine("Ship BP_Location=" + shipC_BPartner_Location_ID);
//
Timestamp billDate = Env.getContextAsDate(ctx, WindowNo, "DateOrdered");
- log.fine("Bill Date=" + billDate);
+ if (log.isLoggable(Level.FINE)) log.fine("Bill Date=" + billDate);
Timestamp shipDate = Env.getContextAsDate(ctx, WindowNo, "DatePromised");
- log.fine("Ship Date=" + shipDate);
+ if (log.isLoggable(Level.FINE)) log.fine("Ship Date=" + shipDate);
int AD_Org_ID = Env.getContextAsInt(ctx, WindowNo, "AD_Org_ID");
- log.fine("Org=" + AD_Org_ID);
+ if (log.isLoggable(Level.FINE)) log.fine("Org=" + AD_Org_ID);
int M_Warehouse_ID = Env.getContextAsInt(ctx, WindowNo, "M_Warehouse_ID");
- log.fine("Warehouse=" + M_Warehouse_ID);
+ if (log.isLoggable(Level.FINE)) log.fine("Warehouse=" + M_Warehouse_ID);
int billC_BPartner_Location_ID = Env.getContextAsInt(ctx, WindowNo, "Bill_Location_ID");
if (billC_BPartner_Location_ID == 0)
billC_BPartner_Location_ID = shipC_BPartner_Location_ID;
- log.fine("Bill BP_Location=" + billC_BPartner_Location_ID);
+ if (log.isLoggable(Level.FINE)) log.fine("Bill BP_Location=" + billC_BPartner_Location_ID);
//
int C_Tax_ID = Tax.get (ctx, M_Product_ID, C_Charge_ID, billDate, shipDate,
@@ -1020,15 +1020,17 @@ public class CalloutOrder extends CalloutEngine
// get values
QtyEntered = (BigDecimal)mTab.getValue("QtyEntered");
QtyOrdered = (BigDecimal)mTab.getValue("QtyOrdered");
- log.fine("QtyEntered=" + QtyEntered + ", Ordered=" + QtyOrdered + ", UOM=" + C_UOM_To_ID);
+ if (log.isLoggable(Level.FINE)) log.fine("QtyEntered=" + QtyEntered + ", Ordered=" + QtyOrdered + ", UOM=" + C_UOM_To_ID);
//
PriceEntered = (BigDecimal)mTab.getValue("PriceEntered");
PriceActual = (BigDecimal)mTab.getValue("PriceActual");
Discount = (BigDecimal)mTab.getValue("Discount");
PriceLimit = (BigDecimal)mTab.getValue("PriceLimit");
PriceList = (BigDecimal)mTab.getValue("PriceList");
- log.fine("PriceList=" + PriceList + ", Limit=" + PriceLimit + ", Precision=" + StdPrecision);
- log.fine("PriceEntered=" + PriceEntered + ", Actual=" + PriceActual + ", Discount=" + Discount);
+ if (log.isLoggable(Level.FINE)){
+ log.fine("PriceList=" + PriceList + ", Limit=" + PriceLimit + ", Precision=" + StdPrecision);
+ log.fine("PriceEntered=" + PriceEntered + ", Actual=" + PriceActual + ", Discount=" + Discount);
+ }
// No Product
if (M_Product_ID == 0)
@@ -1072,7 +1074,7 @@ public class CalloutOrder extends CalloutEngine
if (PriceEntered == null)
PriceEntered = pp.getPriceStd();
//
- log.fine("QtyChanged -> PriceActual=" + pp.getPriceStd()
+ if (log.isLoggable(Level.FINE)) log.fine("QtyChanged -> PriceActual=" + pp.getPriceStd()
+ ", PriceEntered=" + PriceEntered + ", Discount=" + pp.getDiscount());
PriceActual = pp.getPriceStd();
mTab.setValue("PriceActual", pp.getPriceStd());
@@ -1088,7 +1090,7 @@ public class CalloutOrder extends CalloutEngine
if (PriceEntered == null)
PriceEntered = PriceActual;
//
- log.fine("PriceActual=" + PriceActual
+ if (log.isLoggable(Level.FINE)) log.fine("PriceActual=" + PriceActual
+ " -> PriceEntered=" + PriceEntered);
mTab.setValue("PriceEntered", PriceEntered);
}
@@ -1100,7 +1102,7 @@ public class CalloutOrder extends CalloutEngine
if (PriceActual == null)
PriceActual = PriceEntered;
//
- log.fine("PriceEntered=" + PriceEntered
+ if (log.isLoggable(Level.FINE)) log.fine("PriceEntered=" + PriceEntered
+ " -> PriceActual=" + PriceActual);
mTab.setValue("PriceActual", PriceActual);
}
@@ -1130,7 +1132,7 @@ public class CalloutOrder extends CalloutEngine
Discount = Discount.setScale(2, BigDecimal.ROUND_HALF_UP);
mTab.setValue("Discount", Discount);
}
- log.fine("PriceEntered=" + PriceEntered + ", Actual=" + PriceActual + ", Discount=" + Discount);
+ if (log.isLoggable(Level.FINE)) log.fine("PriceEntered=" + PriceEntered + ", Actual=" + PriceActual + ", Discount=" + Discount);
// Check PriceLimit
String epl = Env.getContext(ctx, WindowNo, "EnforcePriceLimit");
@@ -1146,7 +1148,7 @@ public class CalloutOrder extends CalloutEngine
C_UOM_To_ID, PriceLimit);
if (PriceEntered == null)
PriceEntered = PriceLimit;
- log.fine("(under) PriceEntered=" + PriceEntered + ", Actual" + PriceLimit);
+ if (log.isLoggable(Level.FINE)) log.fine("(under) PriceEntered=" + PriceEntered + ", Actual" + PriceLimit);
mTab.setValue ("PriceActual", PriceLimit);
mTab.setValue ("PriceEntered", PriceEntered);
mTab.fireDataStatusEEvent ("UnderLimitPrice", "", false);
@@ -1205,7 +1207,7 @@ public class CalloutOrder extends CalloutEngine
BigDecimal QtyEntered1 = QtyEntered.setScale(MUOM.getPrecision(ctx, C_UOM_To_ID), BigDecimal.ROUND_HALF_UP);
if (QtyEntered.compareTo(QtyEntered1) != 0)
{
- log.fine("Corrected QtyEntered Scale UOM=" + C_UOM_To_ID
+ if (log.isLoggable(Level.FINE)) log.fine("Corrected QtyEntered Scale UOM=" + C_UOM_To_ID
+ "; QtyEntered=" + QtyEntered + "->" + QtyEntered1);
QtyEntered = QtyEntered1;
mTab.setValue("QtyEntered", QtyEntered);
@@ -1220,7 +1222,7 @@ public class CalloutOrder extends CalloutEngine
C_UOM_To_ID, PriceActual);
if (PriceEntered == null)
PriceEntered = PriceActual;
- log.fine("UOM=" + C_UOM_To_ID
+ if (log.isLoggable(Level.FINE)) log.fine("UOM=" + C_UOM_To_ID
+ ", QtyEntered/PriceActual=" + QtyEntered + "/" + PriceActual
+ " -> " + conversion
+ " QtyOrdered/PriceEntered=" + QtyOrdered + "/" + PriceEntered);
@@ -1236,7 +1238,7 @@ public class CalloutOrder extends CalloutEngine
BigDecimal QtyEntered1 = QtyEntered.setScale(MUOM.getPrecision(ctx, C_UOM_To_ID), BigDecimal.ROUND_HALF_UP);
if (QtyEntered.compareTo(QtyEntered1) != 0)
{
- log.fine("Corrected QtyEntered Scale UOM=" + C_UOM_To_ID
+ if (log.isLoggable(Level.FINE)) log.fine("Corrected QtyEntered Scale UOM=" + C_UOM_To_ID
+ "; QtyEntered=" + QtyEntered + "->" + QtyEntered1);
QtyEntered = QtyEntered1;
mTab.setValue("QtyEntered", QtyEntered);
@@ -1246,7 +1248,7 @@ public class CalloutOrder extends CalloutEngine
if (QtyOrdered == null)
QtyOrdered = QtyEntered;
boolean conversion = QtyEntered.compareTo(QtyOrdered) != 0;
- log.fine("UOM=" + C_UOM_To_ID
+ if (log.isLoggable(Level.FINE)) log.fine("UOM=" + C_UOM_To_ID
+ ", QtyEntered=" + QtyEntered
+ " -> " + conversion
+ " QtyOrdered=" + QtyOrdered);
@@ -1262,7 +1264,7 @@ public class CalloutOrder extends CalloutEngine
BigDecimal QtyOrdered1 = QtyOrdered.setScale(precision, BigDecimal.ROUND_HALF_UP);
if (QtyOrdered.compareTo(QtyOrdered1) != 0)
{
- log.fine("Corrected QtyOrdered Scale "
+ if (log.isLoggable(Level.FINE)) log.fine("Corrected QtyOrdered Scale "
+ QtyOrdered + "->" + QtyOrdered1);
QtyOrdered = QtyOrdered1;
mTab.setValue("QtyOrdered", QtyOrdered);
@@ -1272,7 +1274,7 @@ public class CalloutOrder extends CalloutEngine
if (QtyEntered == null)
QtyEntered = QtyOrdered;
boolean conversion = QtyOrdered.compareTo(QtyEntered) != 0;
- log.fine("UOM=" + C_UOM_To_ID
+ if (log.isLoggable(Level.FINE)) log.fine("UOM=" + C_UOM_To_ID
+ ", QtyOrdered=" + QtyOrdered
+ " -> " + conversion
+ " QtyEntered=" + QtyEntered);
diff --git a/org.adempiere.base.callout/src/org/compiere/model/CalloutPaySelection.java b/org.adempiere.base.callout/src/org/compiere/model/CalloutPaySelection.java
index 0c8ba4e251..69e413a719 100644
--- a/org.adempiere.base.callout/src/org/compiere/model/CalloutPaySelection.java
+++ b/org.adempiere.base.callout/src/org/compiere/model/CalloutPaySelection.java
@@ -67,7 +67,7 @@ public class CalloutPaySelection extends CalloutEngine
BigDecimal PayAmt = (BigDecimal)mTab.getValue("PayAmt");
BigDecimal DiscountAmt = (BigDecimal)mTab.getValue("DiscountAmt");
BigDecimal DifferenceAmt = OpenAmt.subtract(PayAmt).subtract(DiscountAmt);
- log.fine(" - OpenAmt=" + OpenAmt + " - PayAmt=" + PayAmt
+ if (log.isLoggable(Level.FINE)) log.fine(" - OpenAmt=" + OpenAmt + " - PayAmt=" + PayAmt
+ ", Discount=" + DiscountAmt + ", Difference=" + DifferenceAmt);
mTab.setValue("DifferenceAmt", DifferenceAmt);
@@ -133,7 +133,7 @@ public class CalloutPaySelection extends CalloutEngine
DB.close(rs, pstmt);
rs = null; pstmt = null;
}
- log.fine(" - OpenAmt=" + OpenAmt + " (Invoice=" + C_Invoice_ID + ",BankAcct=" + C_BankAccount_ID + ")");
+ if (log.isLoggable(Level.FINE)) log.fine(" - OpenAmt=" + OpenAmt + " (Invoice=" + C_Invoice_ID + ",BankAcct=" + C_BankAccount_ID + ")");
mTab.setValue("OpenAmt", OpenAmt);
mTab.setValue("PayAmt", OpenAmt.subtract(DiscountAmt));
mTab.setValue("DiscountAmt", DiscountAmt);
diff --git a/org.adempiere.base.callout/src/org/compiere/model/CalloutPayment.java b/org.adempiere.base.callout/src/org/compiere/model/CalloutPayment.java
index d731415b3c..312e495fec 100644
--- a/org.adempiere.base.callout/src/org/compiere/model/CalloutPayment.java
+++ b/org.adempiere.base.callout/src/org/compiere/model/CalloutPayment.java
@@ -242,7 +242,7 @@ public class CalloutPayment extends CalloutEngine
int C_Invoice_ID = Env.getContextAsInt (ctx, WindowNo, "C_Invoice_ID");
int C_Order_ID = Env.getContextAsInt (ctx, WindowNo, "C_Order_ID");
int C_DocType_ID = Env.getContextAsInt (ctx, WindowNo, "C_DocType_ID");
- log.fine ("Payment_DocType - C_Invoice_ID=" + C_Invoice_ID
+ if (log.isLoggable(Level.FINE)) log.fine ("Payment_DocType - C_Invoice_ID=" + C_Invoice_ID
+ ", C_DocType_ID=" + C_DocType_ID);
MDocType dt = null;
if (C_DocType_ID != 0)
@@ -359,14 +359,14 @@ public class CalloutPayment extends CalloutEngine
pstmt = null;
}
} // get Invoice Info
- log.fine ("Open=" + InvoiceOpenAmt + ", C_Invoice_ID=" + C_Invoice_ID
+ if (log.isLoggable(Level.FINE)) log.fine ("Open=" + InvoiceOpenAmt + ", C_Invoice_ID=" + C_Invoice_ID
+ ", C_Currency_ID=" + C_Currency_Invoice_ID);
// Get Info from Tab
BigDecimal PayAmt = (BigDecimal)mTab.getValue ("PayAmt");
BigDecimal DiscountAmt = (BigDecimal)mTab.getValue ("DiscountAmt");
BigDecimal WriteOffAmt = (BigDecimal)mTab.getValue ("WriteOffAmt");
BigDecimal OverUnderAmt = (BigDecimal)mTab.getValue ("OverUnderAmt");
- log.fine ("Pay=" + PayAmt + ", Discount=" + DiscountAmt + ", WriteOff="
+ if (log.isLoggable(Level.FINE)) log.fine ("Pay=" + PayAmt + ", Discount=" + DiscountAmt + ", WriteOff="
+ WriteOffAmt + ", OverUnderAmt=" + OverUnderAmt);
// Get Currency Info
int C_Currency_ID = ((Integer)mTab.getValue ("C_Currency_ID"))
@@ -385,7 +385,7 @@ public class CalloutPayment extends CalloutEngine
|| colName.equals ("C_Currency_ID")
|| colName.equals ("C_ConversionType_ID"))
{
- log.fine ("InvCurrency=" + C_Currency_Invoice_ID + ", PayCurrency="
+ if (log.isLoggable(Level.FINE)) log.fine ("InvCurrency=" + C_Currency_Invoice_ID + ", PayCurrency="
+ C_Currency_ID + ", Date=" + ConvDate + ", Type="
+ C_ConversionType_ID);
CurrencyRate = MConversionRate.getRate (C_Currency_Invoice_ID,
@@ -402,7 +402,7 @@ public class CalloutPayment extends CalloutEngine
//
InvoiceOpenAmt = InvoiceOpenAmt.multiply (CurrencyRate).setScale (
currency.getStdPrecision (), BigDecimal.ROUND_HALF_UP);
- log.fine ("Rate=" + CurrencyRate + ", InvoiceOpenAmt="
+ if (log.isLoggable(Level.FINE)) log.fine ("Rate=" + CurrencyRate + ", InvoiceOpenAmt="
+ InvoiceOpenAmt);
}
// Currency Changed - convert all
diff --git a/org.adempiere.base.callout/src/org/compiere/model/CalloutPaymentAllocate.java b/org.adempiere.base.callout/src/org/compiere/model/CalloutPaymentAllocate.java
index ef600b0ee9..9982b85f21 100644
--- a/org.adempiere.base.callout/src/org/compiere/model/CalloutPaymentAllocate.java
+++ b/org.adempiere.base.callout/src/org/compiere/model/CalloutPaymentAllocate.java
@@ -156,7 +156,7 @@ public class CalloutPaymentAllocate extends CalloutEngine
BigDecimal WriteOffAmt = (BigDecimal)mTab.getValue("WriteOffAmt");
BigDecimal OverUnderAmt = (BigDecimal)mTab.getValue("OverUnderAmt");
BigDecimal InvoiceAmt = (BigDecimal)mTab.getValue("InvoiceAmt");
- log.fine("Amt=" + Amount + ", Discount=" + DiscountAmt
+ if (log.isLoggable(Level.FINE)) log.fine("Amt=" + Amount + ", Discount=" + DiscountAmt
+ ", WriteOff=" + WriteOffAmt + ", OverUnder=" + OverUnderAmt
+ ", Invoice=" + InvoiceAmt);
diff --git a/org.adempiere.base.callout/src/org/compiere/model/CalloutProject.java b/org.adempiere.base.callout/src/org/compiere/model/CalloutProject.java
index 3e41385598..0f23ed39ed 100644
--- a/org.adempiere.base.callout/src/org/compiere/model/CalloutProject.java
+++ b/org.adempiere.base.callout/src/org/compiere/model/CalloutProject.java
@@ -18,6 +18,7 @@ package org.compiere.model;
import java.math.BigDecimal;
import java.util.Properties;
+import java.util.logging.Level;
import org.compiere.util.Env;
@@ -62,7 +63,7 @@ public class CalloutProject extends CalloutEngine
if (PlannedAmt.scale() > StdPrecision)
PlannedAmt = PlannedAmt.setScale(StdPrecision, BigDecimal.ROUND_HALF_UP);
//
- log.fine("PlannedQty=" + PlannedQty + " * PlannedPrice=" + PlannedPrice + " -> PlannedAmt=" + PlannedAmt + " (Precision=" + StdPrecision+ ")");
+ if (log.isLoggable(Level.FINE)) log.fine("PlannedQty=" + PlannedQty + " * PlannedPrice=" + PlannedPrice + " -> PlannedAmt=" + PlannedAmt + " (Precision=" + StdPrecision+ ")");
mTab.setValue("PlannedAmt", PlannedAmt);
return "";
} // planned
diff --git a/org.adempiere.base.callout/src/org/compiere/model/CalloutRequisition.java b/org.adempiere.base.callout/src/org/compiere/model/CalloutRequisition.java
index 7299f68b33..964eb888b7 100644
--- a/org.adempiere.base.callout/src/org/compiere/model/CalloutRequisition.java
+++ b/org.adempiere.base.callout/src/org/compiere/model/CalloutRequisition.java
@@ -19,6 +19,7 @@ package org.compiere.model;
import java.math.BigDecimal;
import java.sql.Timestamp;
import java.util.Properties;
+import java.util.logging.Level;
import org.adempiere.model.GridTabWrapper;
import org.compiere.util.Env;
@@ -82,7 +83,7 @@ public class CalloutRequisition extends CalloutEngine
int StdPrecision = Env.getContextAsInt(ctx, WindowNo, "StdPrecision");
BigDecimal Qty = line.getQty();
BigDecimal PriceActual = line.getPriceActual();
- log.fine("amt - Qty=" + Qty + ", Price=" + PriceActual + ", Precision=" + StdPrecision);
+ if (log.isLoggable(Level.FINE)) log.fine("amt - Qty=" + Qty + ", Price=" + PriceActual + ", Precision=" + StdPrecision);
// Multiply
BigDecimal LineNetAmt = Qty.multiply(PriceActual);
diff --git a/org.adempiere.base.callout/src/org/compiere/model/CalloutTimeExpense.java b/org.adempiere.base.callout/src/org/compiere/model/CalloutTimeExpense.java
index 1cba9a246f..b26c16a5a1 100644
--- a/org.adempiere.base.callout/src/org/compiere/model/CalloutTimeExpense.java
+++ b/org.adempiere.base.callout/src/org/compiere/model/CalloutTimeExpense.java
@@ -189,7 +189,7 @@ public class CalloutTimeExpense extends CalloutEngine
int C_Currency_To_ID = Env.getContextAsInt(ctx, "$C_Currency_ID");
Timestamp DateExpense = Env.getContextAsDate(ctx, WindowNo, "DateExpense");
//
- log.fine("Amt=" + ExpenseAmt + ", C_Currency_ID=" + C_Currency_From_ID);
+ if (log.isLoggable(Level.FINE)) log.fine("Amt=" + ExpenseAmt + ", C_Currency_ID=" + C_Currency_From_ID);
// Converted Amount = Unit price
BigDecimal ConvertedAmt = ExpenseAmt;
// convert if required
@@ -202,7 +202,7 @@ public class CalloutTimeExpense extends CalloutEngine
DateExpense, 0, AD_Client_ID, AD_Org_ID);
}
mTab.setValue("ConvertedAmt", ConvertedAmt);
- log.fine("= ConvertedAmt=" + ConvertedAmt);
+ if (log.isLoggable(Level.FINE)) log.fine("= ConvertedAmt=" + ConvertedAmt);
return "";
} // Expense_Amount
diff --git a/org.adempiere.base.process/src/org/compiere/process/Aging.java b/org.adempiere.base.process/src/org/compiere/process/Aging.java
index 0d75a29f9e..270fea7343 100644
--- a/org.adempiere.base.process/src/org/compiere/process/Aging.java
+++ b/org.adempiere.base.process/src/org/compiere/process/Aging.java
@@ -221,7 +221,7 @@ public class Aging extends SvrProcess
if (aging != null)
{
aging.saveEx();
- log.fine("#" + ++counter + " - " + aging);
+ if (log.isLoggable(Level.FINE)) log.fine("#" + ++counter + " - " + aging);
}
aging = new MAging (getCtx(), AD_PInstance_ID, p_StatementDate,
C_BPartner_ID, C_Currency_ID,
@@ -239,7 +239,7 @@ public class Aging extends SvrProcess
{
aging.saveEx();
counter++;
- log.fine("#" + counter + " - " + aging);
+ if (log.isLoggable(Level.FINE)) log.fine("#" + counter + " - " + aging);
}
}
catch (SQLException e)
diff --git a/org.adempiere.base.process/src/org/compiere/process/AllocationAuto.java b/org.adempiere.base.process/src/org/compiere/process/AllocationAuto.java
index b8cbe3d946..416c9c5e56 100644
--- a/org.adempiere.base.process/src/org/compiere/process/AllocationAuto.java
+++ b/org.adempiere.base.process/src/org/compiere/process/AllocationAuto.java
@@ -375,7 +375,7 @@ public class AllocationAuto extends SvrProcess
.add(payment.getOverUnderAmt());
if (!payment.isReceipt())
availableAmt = availableAmt.negate();
- log.fine("Available=" + availableAmt);
+ if (log.isLoggable(Level.FINE)) log.fine("Available=" + availableAmt);
//
if (payment.getC_Invoice_ID() != 0)
{
@@ -392,7 +392,7 @@ public class AllocationAuto extends SvrProcess
BigDecimal openAmt = invoice.getOpenAmt(true, null);
if (!invoice.isSOTrx())
openAmt = openAmt.negate();
- log.fine(invoice + ", Open=" + openAmt);
+ if (log.isLoggable(Level.FINE)) log.fine(invoice + ", Open=" + openAmt);
// With Discount, etc.
if (availableAmt.compareTo(openAmt) == 0)
{
@@ -432,7 +432,7 @@ public class AllocationAuto extends SvrProcess
.subtract(line.getDifferenceAmt()).subtract(overUnder);
if (!invoice.isSOTrx())
invoiceAmt = invoiceAmt.negate();
- log.fine(invoice + ", Invoice=" + invoiceAmt);
+ if (log.isLoggable(Level.FINE)) log.fine(invoice + ", Invoice=" + invoiceAmt);
totalInvoice = totalInvoice.add(invoiceAmt);
}
else // Multi-Currency
@@ -478,7 +478,7 @@ public class AllocationAuto extends SvrProcess
.add(payment.getOverUnderAmt());
if (!payment.isReceipt())
availableAmt = availableAmt.negate();
- log.fine("Available=" + availableAmt);
+ if (log.isLoggable(Level.FINE)) log.fine("Available=" + availableAmt);
for (int i = 0; i < m_invoices.length; i++)
{
MInvoice invoice = m_invoices[i];
@@ -491,7 +491,7 @@ public class AllocationAuto extends SvrProcess
if (!invoice.isSOTrx())
openAmt = openAmt.negate();
BigDecimal difference = availableAmt.subtract(openAmt).abs();
- log.fine(invoice + ", Open=" + openAmt + " - Difference=" + difference);
+ if (log.isLoggable(Level.FINE)) log.fine(invoice + ", Open=" + openAmt + " - Difference=" + difference);
if (difference.signum() == 0)
{
Timestamp dateAcct = payment.getDateAcct();
@@ -657,7 +657,7 @@ public class AllocationAuto extends SvrProcess
availableAmt = availableAmt.subtract(allocatedAmt);
if (!payment.isReceipt())
availableAmt = availableAmt.negate();
- log.fine("Available=" + availableAmt);
+ if (log.isLoggable(Level.FINE)) log.fine("Available=" + availableAmt);
if (dateAcct == null || payment.getDateAcct().after(dateAcct))
dateAcct = payment.getDateAcct();
totalPayments = totalPayments.add(availableAmt);
@@ -672,11 +672,11 @@ public class AllocationAuto extends SvrProcess
if (invoice.getC_Currency_ID() != C_Currency_ID)
continue;
BigDecimal openAmt = invoice.getOpenAmt(true, null);
- log.fine("" + invoice);
+ if (log.isLoggable(Level.FINE)) log.fine("" + invoice);
if (!invoice.isSOTrx())
openAmt = openAmt.negate();
// Foreign currency
- log.fine("Open=" + openAmt);
+ if (log.isLoggable(Level.FINE)) log.fine("Open=" + openAmt);
if (dateAcct == null || invoice.getDateAcct().after(dateAcct))
dateAcct = invoice.getDateAcct();
totalInvoices = totalInvoices.add(openAmt);
@@ -685,7 +685,7 @@ public class AllocationAuto extends SvrProcess
// must be either AP or AR balance
if (totalInvoices.signum() != totalPayments.signum())
{
- log.fine("Signum - Invoices=" + totalInvoices.signum()
+ if (log.isLoggable(Level.FINE)) log.fine("Signum - Invoices=" + totalInvoices.signum()
+ " <> Payments=" + totalPayments.signum());
return 0;
}
@@ -727,7 +727,7 @@ public class AllocationAuto extends SvrProcess
availableAmt = availableAmt.subtract(diff);
allocatedPayments = allocatedPayments.subtract(diff);
}
- log.fine("Payment Allocated=" + availableAmt);
+ if (log.isLoggable(Level.FINE)) log.fine("Payment Allocated=" + availableAmt);
if (!createAllocation(C_Currency_ID, "BP Oldest (" + difference.abs() + ")",
dateAcct, availableAmt, null, null, null,
payment.getC_BPartner_ID(), payment.getC_Payment_ID(), 0, payment.getAD_Org_ID()))
@@ -759,7 +759,7 @@ public class AllocationAuto extends SvrProcess
}
if (openAmt.signum() == 0)
break;
- log.fine("Invoice Allocated=" + openAmt);
+ if (log.isLoggable(Level.FINE)) log.fine("Invoice Allocated=" + openAmt);
if (!createAllocation(C_Currency_ID, "BP Oldest (" + difference.abs() + ")",
dateAcct, openAmt, null, null, null,
invoice.getC_BPartner_ID(), 0, invoice.getC_Invoice_ID(), invoice.getAD_Org_ID()))
diff --git a/org.adempiere.base.process/src/org/compiere/process/AllocationReset.java b/org.adempiere.base.process/src/org/compiere/process/AllocationReset.java
index acce4872ff..251ca03df1 100644
--- a/org.adempiere.base.process/src/org/compiere/process/AllocationReset.java
+++ b/org.adempiere.base.process/src/org/compiere/process/AllocationReset.java
@@ -59,7 +59,7 @@ public class AllocationReset extends SvrProcess
ProcessInfoParameter[] para = getParameter();
for (int i = 0; i < para.length; i++)
{
- log.fine("prepare - " + para[i]);
+ if (log.isLoggable(Level.FINE)) log.fine("prepare - " + para[i]);
String name = para[i].getParameterName();
if (para[i].getParameter() == null && para[i].getParameter_To() == null)
;
@@ -183,7 +183,7 @@ public class AllocationReset extends SvrProcess
boolean success = false;
if (hdr.delete(true, m_trx.getTrxName()))
{
- log.fine(hdr.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(hdr.toString());
success = true;
}
if (success)
diff --git a/org.adempiere.base.process/src/org/compiere/process/AssetDelivery.java b/org.adempiere.base.process/src/org/compiere/process/AssetDelivery.java
index 0aa97ce1d6..6eee91b0db 100644
--- a/org.adempiere.base.process/src/org/compiere/process/AssetDelivery.java
+++ b/org.adempiere.base.process/src/org/compiere/process/AssetDelivery.java
@@ -235,7 +235,7 @@ public class AssetDelivery extends SvrProcess
*/
private String deliverIt (int A_Asset_ID)
{
- log.fine("A_Asset_ID=" + A_Asset_ID);
+ if (log.isLoggable(Level.FINE)) log.fine("A_Asset_ID=" + A_Asset_ID);
long start = System.currentTimeMillis();
//
MAsset asset = new MAsset (getCtx(), A_Asset_ID, get_TrxName());
@@ -297,7 +297,7 @@ public class AssetDelivery extends SvrProcess
ad.saveEx();
asset.saveEx();
//
- log.fine((System.currentTimeMillis()-start) + " ms");
+ if (log.isLoggable(Level.FINE)) log.fine((System.currentTimeMillis()-start) + " ms");
// success
StringBuilder msgreturn = new StringBuilder().append(user.getEMail()).append(" - ").append(asset.getVersionNo());
return msgreturn.toString();
diff --git a/org.adempiere.base.process/src/org/compiere/process/BOMValidate.java b/org.adempiere.base.process/src/org/compiere/process/BOMValidate.java
index 366a9483a1..8a63a171cf 100644
--- a/org.adempiere.base.process/src/org/compiere/process/BOMValidate.java
+++ b/org.adempiere.base.process/src/org/compiere/process/BOMValidate.java
@@ -183,7 +183,7 @@ public class BOMValidate extends SvrProcess
return false;
}
m_products.add(product);
- log.fine(product.getName());
+ if (log.isLoggable(Level.FINE)) log.fine(product.getName());
//
MProductBOM[] productsBOMs = MProductBOM.getBOMLines(product);
for (int i = 0; i < productsBOMs.length; i++)
@@ -242,7 +242,7 @@ public class BOMValidate extends SvrProcess
return false;
}
m_products.add(product);
- log.fine(product.getName());
+ if (log.isLoggable(Level.FINE)) log.fine(product.getName());
//
MBOM bom = boms[0];
MBOMProduct[] BOMproducts = MBOMProduct.getOfBOM(bom);
diff --git a/org.adempiere.base.process/src/org/compiere/process/BankStatementMatcher.java b/org.adempiere.base.process/src/org/compiere/process/BankStatementMatcher.java
index 64c13d3888..5efe1baf32 100644
--- a/org.adempiere.base.process/src/org/compiere/process/BankStatementMatcher.java
+++ b/org.adempiere.base.process/src/org/compiere/process/BankStatementMatcher.java
@@ -88,7 +88,7 @@ public class BankStatementMatcher extends SvrProcess
if (m_matchers == null || ibs == null || ibs.getC_Payment_ID() != 0)
return "--";
- log.fine("" + ibs);
+ if (log.isLoggable(Level.FINE)) log.fine("" + ibs);
BankStatementMatchInfo info = null;
for (int i = 0; i < m_matchers.length; i++)
{
@@ -122,7 +122,7 @@ public class BankStatementMatcher extends SvrProcess
if (m_matchers == null || bsl == null || bsl.getC_Payment_ID() != 0)
return "--";
- log.fine("match - " + bsl);
+ if (log.isLoggable(Level.FINE)) log.fine("match - " + bsl);
BankStatementMatchInfo info = null;
for (int i = 0; i < m_matchers.length; i++)
{
@@ -154,7 +154,7 @@ public class BankStatementMatcher extends SvrProcess
{
if (m_matchers == null || bs == null)
return "--";
- log.fine("match - " + bs);
+ if (log.isLoggable(Level.FINE)) log.fine("match - " + bs);
int count = 0;
MBankStatementLine[] lines = bs.getLines(false);
for (int i = 0; i < lines.length; i++)
diff --git a/org.adempiere.base.process/src/org/compiere/process/BankStatementPayment.java b/org.adempiere.base.process/src/org/compiere/process/BankStatementPayment.java
index f51b0efd05..2309f053fa 100644
--- a/org.adempiere.base.process/src/org/compiere/process/BankStatementPayment.java
+++ b/org.adempiere.base.process/src/org/compiere/process/BankStatementPayment.java
@@ -83,7 +83,7 @@ public class BankStatementPayment extends SvrProcess
{
if (ibs == null || ibs.getC_Payment_ID() != 0)
return "--";
- log.fine(ibs.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(ibs.toString());
if (ibs.getC_Invoice_ID() == 0 && ibs.getC_BPartner_ID() == 0)
throw new AdempiereUserError ("@NotFound@ @C_Invoice_ID@ / @C_BPartner_ID@");
if (ibs.getC_BankAccount_ID() == 0)
@@ -117,7 +117,7 @@ public class BankStatementPayment extends SvrProcess
{
if (bsl == null || bsl.getC_Payment_ID() != 0)
return "--";
- log.fine(bsl.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(bsl.toString());
if (bsl.getC_Invoice_ID() == 0 && bsl.getC_BPartner_ID() == 0)
throw new AdempiereUserError ("@NotFound@ @C_Invoice_ID@ / @C_BPartner_ID@");
//
diff --git a/org.adempiere.base.process/src/org/compiere/process/CommissionCalc.java b/org.adempiere.base.process/src/org/compiere/process/CommissionCalc.java
index f9f1dd639e..6f5aca576c 100644
--- a/org.adempiere.base.process/src/org/compiere/process/CommissionCalc.java
+++ b/org.adempiere.base.process/src/org/compiere/process/CommissionCalc.java
@@ -241,7 +241,7 @@ public class CommissionCalc extends SvrProcess
if (!m_com.isListDetails())
sql.append(" GROUP BY h.C_Currency_ID");
//
- log.fine("Line=" + lines[i].getLine() + " - " + sql);
+ if (log.isLoggable(Level.FINE)) log.fine("Line=" + lines[i].getLine() + " - " + sql);
//
createDetail(sql.toString(), comAmt);
comAmt.calculateCommission();
@@ -319,7 +319,7 @@ public class CommissionCalc extends SvrProcess
cal.add(Calendar.DAY_OF_YEAR, -1);
m_EndDate = new Timestamp (cal.getTimeInMillis());
}
- log.fine("setStartEndDate = " + p_StartDate + " - " + m_EndDate);
+ if (log.isLoggable(Level.FINE)) log.fine("setStartEndDate = " + p_StartDate + " - " + m_EndDate);
/**
String sd = DB.TO_DATE(p_StartDate, true);
diff --git a/org.adempiere.base.process/src/org/compiere/process/DistributionRun.java b/org.adempiere.base.process/src/org/compiere/process/DistributionRun.java
index e64142fa69..491e1b91ba 100644
--- a/org.adempiere.base.process/src/org/compiere/process/DistributionRun.java
+++ b/org.adempiere.base.process/src/org/compiere/process/DistributionRun.java
@@ -237,7 +237,7 @@ public class DistributionRun extends SvrProcess
// Delete Old
sql = "DELETE FROM T_DistributionRunDetail WHERE M_DistributionRun_ID=?";
no = DB.executeUpdateEx(sql,new Object[]{p_M_DistributionRun_ID}, get_TrxName());
- log.fine("insertDetails - deleted #" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("insertDetails - deleted #" + no);
// Insert New
sql = "INSERT INTO T_DistributionRunDetail "
+ "(M_DistributionRun_ID, M_DistributionRunLine_ID, M_DistributionList_ID, M_DistributionListLine_ID,"
@@ -258,7 +258,7 @@ public class DistributionRun extends SvrProcess
+ "WHERE rl.M_DistributionRun_ID=?"
+ " AND l.RatioTotal<>0 AND rl.IsActive='Y' AND ll.IsActive='Y'";
no = DB.executeUpdateEx(sql,new Object[]{p_M_DistributionRun_ID}, get_TrxName());
- log.fine("inserted #" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("inserted #" + no);
return no;
} // insertDetails
@@ -291,7 +291,7 @@ public class DistributionRun extends SvrProcess
runLine.addActualAllocation(detail.getActualAllocation());
runLine.setMaxAllocation(detail.getActualAllocation(), false);
//
- log.fine("RunLine=" + runLine.getLine()
+ if (log.isLoggable(Level.FINE)) log.fine("RunLine=" + runLine.getLine()
+ ": BP_ID=" + detail.getC_BPartner_ID()
+ ", Min=" + detail.getMinQty()
+ ", Qty=" + detail.getQty()
@@ -305,7 +305,7 @@ public class DistributionRun extends SvrProcess
for (int j = 0; j < m_runLines.length; j++)
{
MDistributionRunLine runLine = m_runLines[j];
- log.fine("Run - " + runLine.getInfo());
+ if (log.isLoggable(Level.FINE)) log.fine("Run - " + runLine.getInfo());
}
} // addAllocations
@@ -360,7 +360,7 @@ public class DistributionRun extends SvrProcess
// Adjust when difference is -1->1 or last difference is the same
boolean adjustBiggest = difference.abs().compareTo(Env.ONE) <= 0
|| difference.abs().compareTo(runLine.getLastDifference().abs()) == 0;
- log.fine("Line=" + runLine.getLine()
+ if (log.isLoggable(Level.FINE)) log.fine("Line=" + runLine.getLine()
+ ", Diff=" + difference + ", Adjust=" + adjustBiggest);
// Adjust Biggest Amount
if (adjustBiggest)
@@ -370,7 +370,7 @@ public class DistributionRun extends SvrProcess
MDistributionRunDetail detail = m_details[i];
if (runLine.getM_DistributionRunLine_ID() == detail.getM_DistributionRunLine_ID())
{
- log.fine("Biggest - DetailAllocation=" + detail.getActualAllocation()
+ if (log.isLoggable(Level.FINE)) log.fine("Biggest - DetailAllocation=" + detail.getActualAllocation()
+ ", MaxAllocation=" + runLine.getMaxAllocation()
+ ", Qty Difference=" + difference);
if (detail.getActualAllocation().compareTo(runLine.getMaxAllocation()) == 0
@@ -414,7 +414,7 @@ public class DistributionRun extends SvrProcess
{
BigDecimal diffRatio = detail.getRatio().multiply(difference)
.divide(ratioTotal, BigDecimal.ROUND_HALF_UP); // precision from total
- log.fine("Detail=" + detail.toString()
+ if (log.isLoggable(Level.FINE)) log.fine("Detail=" + detail.toString()
+ ", Allocation=" + detail.getActualAllocation()
+ ", DiffRatio=" + diffRatio);
detail.adjustQty(diffRatio);
@@ -450,7 +450,7 @@ public class DistributionRun extends SvrProcess
+ " - " + m_docType);
log.info("Single=" + m_run.isCreateSingleOrder()
+ " - " + m_docType + ",SO=" + m_docType.isSOTrx());
- log.fine("Counter=" + counter
+ if (log.isLoggable(Level.FINE)) log.fine("Counter=" + counter
+ ",C_BPartner_ID=" + runC_BPartner_ID + "," + runBPartner);
//
MBPartner bp = null;
@@ -517,7 +517,7 @@ public class DistributionRun extends SvrProcess
// Counter Doc
if (counter && bp.getAD_OrgBP_ID_Int() > 0)
{
- log.fine("Counter - From_BPOrg=" + bp.getAD_OrgBP_ID_Int()
+ if (log.isLoggable(Level.FINE)) log.fine("Counter - From_BPOrg=" + bp.getAD_OrgBP_ID_Int()
+ "-" + bp + ", To_BP=" + runBPartner);
order.setAD_Org_ID(bp.getAD_OrgBP_ID_Int());
MOrgInfo oi = MOrgInfo.get(getCtx(), bp.getAD_OrgBP_ID_Int(), get_TrxName());
@@ -527,7 +527,7 @@ public class DistributionRun extends SvrProcess
}
else // normal
{
- log.fine("From_Org=" + runAD_Org_ID
+ if (log.isLoggable(Level.FINE)) log.fine("From_Org=" + runAD_Org_ID
+ ", To_BP=" + bp);
order.setAD_Org_ID(runAD_Org_ID);
order.setBPartner(bp);
@@ -601,7 +601,7 @@ public class DistributionRun extends SvrProcess
sql = new StringBuilder("DELETE FROM T_DistributionRunDetail WHERE M_DistributionRun_ID=")
.append(p_M_DistributionRun_ID);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("insertDetails - deleted #" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("insertDetails - deleted #" + no);
// Insert New
sql = new StringBuilder("INSERT INTO T_DistributionRunDetail ")
@@ -648,7 +648,7 @@ public class DistributionRun extends SvrProcess
record.setQty(drl.getTotalQty().multiply(factor));
record.saveEx();
}
- log.fine("inserted #" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("inserted #" + no);
return no;
} // insertDetails
@@ -713,7 +713,7 @@ public class DistributionRun extends SvrProcess
sql = new StringBuilder("DELETE FROM T_DistributionRunDetail WHERE M_DistributionRun_ID=")
.append(p_M_DistributionRun_ID);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("insertDetails - deleted #" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("insertDetails - deleted #" + no);
// Insert New
sql = new StringBuilder("INSERT INTO T_DistributionRunDetail ")
@@ -752,7 +752,7 @@ public class DistributionRun extends SvrProcess
record.setQty(factor.multiply(drl.getTotalQty()));
record.saveEx();
}
- log.fine("inserted #" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("inserted #" + no);
return no;
} // insertDetails
@@ -848,7 +848,7 @@ public class DistributionRun extends SvrProcess
+ " - " + m_docType);
log.info("Single=" + m_run.isCreateSingleOrder()
+ " - " + m_docType + ",SO=" + m_docType.isSOTrx());
- log.fine("Counter=" + counter
+ if (log.isLoggable(Level.FINE)) log.fine("Counter=" + counter
+ ",C_BPartner_ID=" + runC_BPartner_ID + "," + runBPartner);
//
MBPartner bp = null;
@@ -965,7 +965,7 @@ public class DistributionRun extends SvrProcess
// Counter Doc
if (counter && bp.getAD_OrgBP_ID_Int() > 0)
{
- log.fine("Counter - From_BPOrg=" + bp.getAD_OrgBP_ID_Int()
+ if (log.isLoggable(Level.FINE)) log.fine("Counter - From_BPOrg=" + bp.getAD_OrgBP_ID_Int()
+ "-" + bp + ", To_BP=" + runBPartner);
order.setAD_Org_ID(bp.getAD_OrgBP_ID_Int());
if (ws[0].getM_Warehouse_ID() > 0)
@@ -974,7 +974,7 @@ public class DistributionRun extends SvrProcess
}
else // normal
{
- log.fine("From_Org=" + runAD_Org_ID
+ if (log.isLoggable(Level.FINE)) log.fine("From_Org=" + runAD_Org_ID
+ ", To_BP=" + bp);
order.setAD_Org_ID(bp.getAD_OrgBP_ID_Int());
order.setBPartner(bp);
diff --git a/org.adempiere.base.process/src/org/compiere/process/DunningPrint.java b/org.adempiere.base.process/src/org/compiere/process/DunningPrint.java
index 2ce7c03734..c3dbf29e9a 100644
--- a/org.adempiere.base.process/src/org/compiere/process/DunningPrint.java
+++ b/org.adempiere.base.process/src/org/compiere/process/DunningPrint.java
@@ -199,7 +199,7 @@ public class DunningPrint extends SvrProcess
if (re != null) {
File attachment = re.getPDF(File.createTempFile("Dunning", ".pdf"));
StringBuilder msglog = new StringBuilder().append(to.toString()).append(" - ").append(attachment);
- log.fine(msglog.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(msglog.toString());
email.addAttachment(attachment);
}
//
diff --git a/org.adempiere.base.process/src/org/compiere/process/DunningRunCreate.java b/org.adempiere.base.process/src/org/compiere/process/DunningRunCreate.java
index da4c05ddfb..941f813f7f 100644
--- a/org.adempiere.base.process/src/org/compiere/process/DunningRunCreate.java
+++ b/org.adempiere.base.process/src/org/compiere/process/DunningRunCreate.java
@@ -234,12 +234,12 @@ public class DunningRunCreate extends SvrProcess
StringBuilder msglog = new StringBuilder()
.append("DaysAfterDue: ").append(DaysAfterDue.intValue()).append(" isShowAllDue: ").append(level.isShowAllDue());
- log.fine(msglog.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(msglog.toString());
msglog = new StringBuilder()
.append("C_Invoice_ID - DaysDue - GrandTotal: ").append(C_Invoice_ID).append(" - ").append(DaysDue).append(" - ").append(GrandTotal);
- log.fine(msglog.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(msglog.toString());
msglog = new StringBuilder("C_InvoicePaySchedule_ID: ").append(C_InvoicePaySchedule_ID);
- log.fine(msglog.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(msglog.toString());
//
// Check for Dispute
if (!p_IncludeInDispute && IsInDispute)
diff --git a/org.adempiere.base.process/src/org/compiere/process/ExpenseSOrder.java b/org.adempiere.base.process/src/org/compiere/process/ExpenseSOrder.java
index 70ef7e9c6e..024173c291 100644
--- a/org.adempiere.base.process/src/org/compiere/process/ExpenseSOrder.java
+++ b/org.adempiere.base.process/src/org/compiere/process/ExpenseSOrder.java
@@ -257,7 +257,7 @@ public class ExpenseSOrder extends SvrProcess
// Update TimeExpense Line
tel.setC_OrderLine_ID(ol.getC_OrderLine_ID());
if (tel.save())
- log.fine("Updated " + tel + " with C_OrderLine_ID");
+ if (log.isLoggable(Level.FINE)) log.fine("Updated " + tel + " with C_OrderLine_ID");
else
log.log(Level.SEVERE, "Not Updated " + tel + " with C_OrderLine_ID");
diff --git a/org.adempiere.base.process/src/org/compiere/process/FactAcctReset.java b/org.adempiere.base.process/src/org/compiere/process/FactAcctReset.java
index 24002b18f0..ebf991ac0a 100644
--- a/org.adempiere.base.process/src/org/compiere/process/FactAcctReset.java
+++ b/org.adempiere.base.process/src/org/compiere/process/FactAcctReset.java
@@ -158,7 +158,7 @@ public class FactAcctReset extends SvrProcess
int invalid = DB.executeUpdate(sql, get_TrxName());
//
if (unlocked + invalid != 0)
- log.fine(TableName + " - Unlocked=" + unlocked + " - Invalid=" + invalid);
+ if (log.isLoggable(Level.FINE)) log.fine(TableName + " - Unlocked=" + unlocked + " - Invalid=" + invalid);
m_countReset += unlocked + invalid;
} // reset
diff --git a/org.adempiere.base.process/src/org/compiere/process/ImportAccount.java b/org.adempiere.base.process/src/org/compiere/process/ImportAccount.java
index 19a7215010..73f6c8d2be 100644
--- a/org.adempiere.base.process/src/org/compiere/process/ImportAccount.java
+++ b/org.adempiere.base.process/src/org/compiere/process/ImportAccount.java
@@ -100,7 +100,7 @@ public class ImportAccount extends SvrProcess
sql = new StringBuilder ("DELETE I_ElementValue ")
.append("WHERE I_IsImported='Y'").append(clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Delete Old Impored =" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Delete Old Impored =" + no);
}
// Set Client, Org, IsActive, Created/Updated
@@ -118,7 +118,7 @@ public class ImportAccount extends SvrProcess
.append(" I_IsImported = 'N' ")
.append("WHERE I_IsImported<>'Y' OR I_IsImported IS NULL");
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Reset=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Reset=" + no);
// **** Prepare ****
@@ -130,7 +130,7 @@ public class ImportAccount extends SvrProcess
.append("WHERE ElementName IS NULL AND C_Element_ID IS NULL")
.append(" AND I_IsImported<>'Y'").append(clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set Element Default=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Element Default=" + no);
}
//
sql = new StringBuilder ("UPDATE I_ElementValue i ")
@@ -139,7 +139,7 @@ public class ImportAccount extends SvrProcess
.append("WHERE C_Element_ID IS NULL")
.append(" AND I_IsImported<>'Y'").append(clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set Element=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Element=" + no);
//
sql = new StringBuilder ("UPDATE I_ElementValue ")
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=Invalid Element, ' ")
@@ -165,7 +165,7 @@ public class ImportAccount extends SvrProcess
.append("WHERE Default_Account IS NOT NULL AND AD_Column_ID IS NULL")
.append(" AND I_IsImported<>'Y'").append(clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set Column=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Column=" + no);
//
sql = new StringBuilder ("UPDATE I_ElementValue ")
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=Invalid Column, ' ")
@@ -186,7 +186,7 @@ public class ImportAccount extends SvrProcess
.append(" AND I_IsImported<>'Y'").append(clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
StringBuilder msglog = new StringBuilder("Set ").append(yColumns[i]).append(" Default=").append(no);
- log.fine(msglog.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(msglog.toString());
}
// Summary
sql = new StringBuilder ("UPDATE I_ElementValue ")
@@ -194,7 +194,7 @@ public class ImportAccount extends SvrProcess
.append("WHERE IsSummary IS NULL OR IsSummary NOT IN ('Y','N')")
.append(" AND I_IsImported<>'Y'").append(clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set IsSummary Default=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set IsSummary Default=" + no);
// Doc Controlled
sql = new StringBuilder ("UPDATE I_ElementValue ")
@@ -202,7 +202,7 @@ public class ImportAccount extends SvrProcess
.append("WHERE IsDocControlled IS NULL OR IsDocControlled NOT IN ('Y','N')")
.append(" AND I_IsImported='N'").append(clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set IsDocumentControlled Default=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set IsDocumentControlled Default=" + no);
// Check Account Type A (E) L M O R
sql = new StringBuilder ("UPDATE I_ElementValue ")
@@ -210,7 +210,7 @@ public class ImportAccount extends SvrProcess
.append("WHERE AccountType IS NULL")
.append(" AND I_IsImported<>'Y'").append(clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set AccountType Default=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set AccountType Default=" + no);
//
sql = new StringBuilder ("UPDATE I_ElementValue ")
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=Invalid AccountType, ' ")
@@ -225,7 +225,7 @@ public class ImportAccount extends SvrProcess
.append("WHERE AccountSign IS NULL")
.append(" AND I_IsImported<>'Y'").append(clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set AccountSign Default=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set AccountSign Default=" + no);
//
sql = new StringBuilder ("UPDATE I_ElementValue ")
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=Invalid AccountSign, ' ")
@@ -251,7 +251,7 @@ public class ImportAccount extends SvrProcess
.append("WHERE C_ElementValue_ID IS NULL")
.append(" AND I_IsImported='N'").append(clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Found ElementValue=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Found ElementValue=" + no);
commitEx();
@@ -349,7 +349,7 @@ public class ImportAccount extends SvrProcess
.append("WHERE ParentElementValue_ID IS NULL")
.append(" AND I_IsImported='Y'").append(clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Found Parent ElementValue=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Found Parent ElementValue=" + no);
//
sql = new StringBuilder ("UPDATE I_ElementValue ")
.append("SET I_ErrorMsg=I_ErrorMsg||'Info=ParentNotFound, ' ")
@@ -421,7 +421,7 @@ public class ImportAccount extends SvrProcess
if (m_updateDefaultAccounts)
sql.append(" AND AD_Column_ID IS NULL");
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Reset Processing Flag=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Reset Processing Flag=" + no);
if (m_updateDefaultAccounts)
updateDefaults(clientCheck.toString());
@@ -437,7 +437,7 @@ public class ImportAccount extends SvrProcess
.append("WHERE I_IsImported='Y'")
.append(clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Processed=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Processed=" + no);
return "";
} // doIt
@@ -577,7 +577,7 @@ public class ImportAccount extends SvrProcess
private int updateDefaultAccount (String TableName, String ColumnName, int C_AcctSchema_ID, int C_ElementValue_ID)
{
StringBuilder msglog = new StringBuilder(TableName).append(".").append(ColumnName).append(" - ").append(C_ElementValue_ID);
- log.fine(msglog.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(msglog.toString());
int retValue = UPDATE_ERROR;
StringBuilder sql = new StringBuilder ("SELECT x.")
.append(ColumnName).append(",Account_ID FROM ")
@@ -620,7 +620,7 @@ public class ImportAccount extends SvrProcess
msglog = new StringBuilder("New #").append(no).append(" - ")
.append(TableName).append(".").append(ColumnName).append(" - ").append(C_ElementValue_ID)
.append(" -- ").append(C_ValidCombination_ID).append(" -> ").append(newC_ValidCombination_ID);
- log.fine(msglog.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(msglog.toString());
if (no == 1)
retValue = UPDATE_YES;
}
@@ -636,7 +636,7 @@ public class ImportAccount extends SvrProcess
int no = DB.executeUpdate(sql.toString(), get_TrxName());
msglog = new StringBuilder("Replace #").append(no).append(" - ")
.append("C_ValidCombination_ID=").append(C_ValidCombination_ID).append(", New Account_ID=").append(C_ElementValue_ID);
- log.fine(msglog.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(msglog.toString());
if (no == 1)
{
retValue = UPDATE_YES;
@@ -646,13 +646,13 @@ public class ImportAccount extends SvrProcess
no = DB.executeUpdate(sql.toString(), get_TrxName());
msglog = new StringBuilder("ImportAccount.updateDefaultAccount - Replace VC #").append(no).append(" - ")
.append("Account_ID=").append(Account_ID).append(", New Account_ID=").append(C_ElementValue_ID);
- log.fine(msglog.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(msglog.toString());
sql = new StringBuilder ("UPDATE Fact_Acct SET Account_ID=")
.append(C_ElementValue_ID).append(" WHERE Account_ID=").append(Account_ID);
no = DB.executeUpdate(sql.toString(), get_TrxName());
msglog = new StringBuilder("ImportAccount.updateDefaultAccount - Replace Fact #").append(no).append(" - ")
.append("Account_ID=").append(Account_ID).append(", New Account_ID=").append(C_ElementValue_ID);
- log.fine(msglog.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(msglog.toString());
}
} // replace combination
} // need to update
diff --git a/org.adempiere.base.process/src/org/compiere/process/ImportBPartner.java b/org.adempiere.base.process/src/org/compiere/process/ImportBPartner.java
index 3772fe8a39..792a1e0292 100644
--- a/org.adempiere.base.process/src/org/compiere/process/ImportBPartner.java
+++ b/org.adempiere.base.process/src/org/compiere/process/ImportBPartner.java
@@ -103,7 +103,7 @@ implements ImportProcess
sql = new StringBuilder ("DELETE I_BPartner ")
.append("WHERE I_IsImported='Y'").append(clientCheck);
no = DB.executeUpdateEx(sql.toString(), get_TrxName());
- log.fine("Delete Old Impored =" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Delete Old Impored =" + no);
}
// Set Client, Org, IsActive, Created/Updated
@@ -119,7 +119,7 @@ implements ImportProcess
.append(" I_IsImported = 'N' ")
.append("WHERE I_IsImported<>'Y' OR I_IsImported IS NULL");
no = DB.executeUpdateEx(sql.toString(), get_TrxName());
- log.fine("Reset=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Reset=" + no);
ModelValidationEngine.get().fireImportValidate(this, null, null, ImportValidator.TIMING_BEFORE_VALIDATE);
@@ -130,7 +130,7 @@ implements ImportProcess
sql.append("WHERE GroupValue IS NULL AND C_BP_Group_ID IS NULL")
.append(" AND I_IsImported<>'Y'").append(clientCheck);
no = DB.executeUpdateEx(sql.toString(), get_TrxName());
- log.fine("Set Group Default=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Group Default=" + no);
//
sql = new StringBuilder ("UPDATE I_BPartner i ")
.append("SET C_BP_Group_ID=(SELECT C_BP_Group_ID FROM C_BP_Group g")
@@ -138,7 +138,7 @@ implements ImportProcess
.append("WHERE C_BP_Group_ID IS NULL")
.append(" AND I_IsImported<>'Y'").append(clientCheck);
no = DB.executeUpdateEx(sql.toString(), get_TrxName());
- log.fine("Set Group=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Group=" + no);
//
sql = new StringBuilder ("UPDATE I_BPartner ")
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=Invalid Group, ' ")
@@ -164,7 +164,7 @@ implements ImportProcess
.append("WHERE C_Country_ID IS NULL")
.append(" AND I_IsImported<>'Y'").append(clientCheck);
no = DB.executeUpdateEx(sql.toString(), get_TrxName());
- log.fine("Set Country=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Country=" + no);
//
sql = new StringBuilder ("UPDATE I_BPartner ")
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=Invalid Country, ' ")
@@ -181,7 +181,7 @@ implements ImportProcess
sql.append("WHERE RegionName IS NULL AND C_Region_ID IS NULL")
.append(" AND I_IsImported<>'Y'").append(clientCheck);
no = DB.executeUpdateEx(sql.toString(), get_TrxName());
- log.fine("Set Region Default=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Region Default=" + no);
//
sql = new StringBuilder ("UPDATE I_BPartner i ")
.append("Set C_Region_ID=(SELECT C_Region_ID FROM C_Region r")
@@ -190,7 +190,7 @@ implements ImportProcess
.append("WHERE C_Region_ID IS NULL")
.append(" AND I_IsImported<>'Y'").append(clientCheck);
no = DB.executeUpdateEx(sql.toString(), get_TrxName());
- log.fine("Set Region=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Region=" + no);
//
sql = new StringBuilder ("UPDATE I_BPartner i ")
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=Invalid Region, ' ")
@@ -208,7 +208,7 @@ implements ImportProcess
.append("WHERE C_Greeting_ID IS NULL AND BPContactGreeting IS NOT NULL")
.append(" AND I_IsImported<>'Y'").append(clientCheck);
no = DB.executeUpdateEx(sql.toString(), get_TrxName());
- log.fine("Set Greeting=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Greeting=" + no);
//
sql = new StringBuilder ("UPDATE I_BPartner i ")
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=Invalid Greeting, ' ")
@@ -224,7 +224,7 @@ implements ImportProcess
.append("WHERE i.EMail=u.EMail AND u.AD_Client_ID=i.AD_Client_ID) ")
.append("WHERE i.EMail IS NOT NULL AND I_IsImported='N'").append(clientCheck);
no = DB.executeUpdateEx(sql.toString(), get_TrxName());
- log.fine("Found EMail User=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Found EMail User=" + no);
// Existing BPartner ? Match Value
sql = new StringBuilder ("UPDATE I_BPartner i ")
@@ -233,7 +233,7 @@ implements ImportProcess
.append("WHERE C_BPartner_ID IS NULL AND Value IS NOT NULL")
.append(" AND I_IsImported='N'").append(clientCheck);
no = DB.executeUpdateEx(sql.toString(), get_TrxName());
- log.fine("Found BPartner=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Found BPartner=" + no);
// Existing Contact ? Match Name
sql = new StringBuilder ("UPDATE I_BPartner i ")
@@ -242,7 +242,7 @@ implements ImportProcess
.append("WHERE C_BPartner_ID IS NOT NULL AND AD_User_ID IS NULL AND ContactName IS NOT NULL")
.append(" AND I_IsImported='N'").append(clientCheck);
no = DB.executeUpdateEx(sql.toString(), get_TrxName());
- log.fine("Found Contact=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Found Contact=" + no);
// Existing Location ? Exact Match
sql = new StringBuilder ("UPDATE I_BPartner i ")
@@ -259,7 +259,7 @@ implements ImportProcess
.append("WHERE C_BPartner_ID IS NOT NULL AND C_BPartner_Location_ID IS NULL")
.append(" AND I_IsImported='N'").append(clientCheck);
no = DB.executeUpdateEx(sql.toString(), get_TrxName());
- log.fine("Found Location=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Found Location=" + no);
// Interest Area
sql = new StringBuilder ("UPDATE I_BPartner i ")
@@ -268,7 +268,7 @@ implements ImportProcess
.append("WHERE R_InterestArea_ID IS NULL AND InterestAreaName IS NOT NULL")
.append(" AND I_IsImported='N'").append(clientCheck);
no = DB.executeUpdateEx(sql.toString(), get_TrxName());
- log.fine("Set Interest Area=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Interest Area=" + no);
// Value is mandatory error
sql = new StringBuilder ("UPDATE I_BPartner ")
@@ -318,7 +318,7 @@ implements ImportProcess
.append(", C_BPartner_ID=").append(impBP.getC_BPartner_ID())
.append(", C_BPartner_Location_ID=").append(impBP.getC_BPartner_Location_ID())
.append(", AD_User_ID=").append(impBP.getAD_User_ID());
- log.fine(msglog.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(msglog.toString());
if ( ! New_BPValue.equals(Old_BPValue)) {
diff --git a/org.adempiere.base.process/src/org/compiere/process/ImportBankStatement.java b/org.adempiere.base.process/src/org/compiere/process/ImportBankStatement.java
index 5448c8e440..f1cb138af7 100644
--- a/org.adempiere.base.process/src/org/compiere/process/ImportBankStatement.java
+++ b/org.adempiere.base.process/src/org/compiere/process/ImportBankStatement.java
@@ -96,7 +96,7 @@ public class ImportBankStatement extends SvrProcess
sql = new StringBuilder ("DELETE I_BankStatement ")
.append("WHERE I_IsImported='Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Delete Old Impored =" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Delete Old Impored =" + no);
}
// Set Client, Org, IsActive, Created/Updated
diff --git a/org.adempiere.base.process/src/org/compiere/process/ImportConversionRate.java b/org.adempiere.base.process/src/org/compiere/process/ImportConversionRate.java
index b2a067c77a..743d5145f2 100644
--- a/org.adempiere.base.process/src/org/compiere/process/ImportConversionRate.java
+++ b/org.adempiere.base.process/src/org/compiere/process/ImportConversionRate.java
@@ -102,7 +102,7 @@ public class ImportConversionRate extends SvrProcess
sql = new StringBuilder ("DELETE I_Conversion_Rate ")
.append("WHERE I_IsImported='Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Delete Old Impored =" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Delete Old Impored =" + no);
}
// Set Client, Org, Location, IsActive, Created/Updated
@@ -146,7 +146,7 @@ public class ImportConversionRate extends SvrProcess
.append(" AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
if (no > 0)
- log.fine("Set ConversionType =" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set ConversionType =" + no);
sql = new StringBuilder ("UPDATE I_Conversion_Rate i ")
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=Invalid ConversionType, ' ")
.append("WHERE (C_ConversionType_ID IS NULL")
@@ -166,7 +166,7 @@ public class ImportConversionRate extends SvrProcess
.append(" AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
if (no > 0)
- log.fine("Set Currency =" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Currency =" + no);
sql = new StringBuilder ("UPDATE I_Conversion_Rate i ")
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=Invalid Currency, ' ")
.append("WHERE (C_Currency_ID IS NULL")
@@ -186,7 +186,7 @@ public class ImportConversionRate extends SvrProcess
.append(" AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
if (no > 0)
- log.fine("Set Currency To =" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Currency To =" + no);
sql = new StringBuilder ("UPDATE I_Conversion_Rate i ")
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=Invalid Currency To, ' ")
.append("WHERE (C_Currency_ID_To IS NULL")
@@ -205,14 +205,14 @@ public class ImportConversionRate extends SvrProcess
.append(" AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
if (no > 0)
- log.fine("Set MultiplyRate =" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set MultiplyRate =" + no);
sql = new StringBuilder ("UPDATE I_Conversion_Rate i ")
.append("SET DivideRate = 1 / MultiplyRate ")
.append("WHERE (DivideRate IS NULL OR DivideRate = 0) AND MultiplyRate IS NOT NULL AND MultiplyRate<>0")
.append(" AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
if (no > 0)
- log.fine("Set DivideRate =" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set DivideRate =" + no);
sql = new StringBuilder ("UPDATE I_Conversion_Rate i ")
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=Invalid Rates, ' ")
.append("WHERE (MultiplyRate IS NULL OR MultiplyRate = 0 OR DivideRate IS NULL OR DivideRate = 0)")
diff --git a/org.adempiere.base.process/src/org/compiere/process/ImportGLJournal.java b/org.adempiere.base.process/src/org/compiere/process/ImportGLJournal.java
index 15ef431761..c568252a52 100644
--- a/org.adempiere.base.process/src/org/compiere/process/ImportGLJournal.java
+++ b/org.adempiere.base.process/src/org/compiere/process/ImportGLJournal.java
@@ -109,7 +109,7 @@ public class ImportGLJournal extends SvrProcess
sql = new StringBuilder ("DELETE I_GLJournal ")
.append("WHERE I_IsImported='Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Delete Old Impored =" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Delete Old Impored =" + no);
}
// Set IsActive, Created/Updated
@@ -131,7 +131,7 @@ public class ImportGLJournal extends SvrProcess
.append("WHERE (AD_Client_ID IS NULL OR AD_Client_ID=0) AND ClientValue IS NOT NULL")
.append(" AND I_IsImported<>'Y'");
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set Client from Value=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Client from Value=" + no);
// Set Default Client, Doc Org, AcctSchema, DatAcct
sql = new StringBuilder ("UPDATE I_GLJournal ")
@@ -144,7 +144,7 @@ public class ImportGLJournal extends SvrProcess
sql.append(" Updated = COALESCE (Updated, SysDate) ")
.append("WHERE I_IsImported<>'Y' OR I_IsImported IS NULL");
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Client/DocOrg/Default=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Client/DocOrg/Default=" + no);
// Error Doc Org
sql = new StringBuilder ("UPDATE I_GLJournal o ")
@@ -163,13 +163,13 @@ public class ImportGLJournal extends SvrProcess
.append("WHERE C_AcctSchema_ID IS NULL AND AcctSchemaName IS NOT NULL")
.append(" AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set AcctSchema from Name=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set AcctSchema from Name=" + no);
sql = new StringBuilder ("UPDATE I_GLJournal i ")
.append("SET C_AcctSchema_ID=(SELECT c.C_AcctSchema1_ID FROM AD_ClientInfo c WHERE c.AD_Client_ID=i.AD_Client_ID) ")
.append("WHERE C_AcctSchema_ID IS NULL AND AcctSchemaName IS NULL")
.append(" AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set AcctSchema from Client=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set AcctSchema from Client=" + no);
// Error AcctSchema
sql = new StringBuilder ("UPDATE I_GLJournal i ")
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=Invalid AcctSchema, '")
@@ -186,7 +186,7 @@ public class ImportGLJournal extends SvrProcess
.append("WHERE DateAcct IS NULL")
.append(" AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set DateAcct=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set DateAcct=" + no);
// Document Type
sql = new StringBuilder ("UPDATE I_GLJournal i ")
@@ -195,7 +195,7 @@ public class ImportGLJournal extends SvrProcess
.append("WHERE C_DocType_ID IS NULL AND DocTypeName IS NOT NULL")
.append(" AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set DocType=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set DocType=" + no);
sql = new StringBuilder ("UPDATE I_GLJournal i ")
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=Invalid DocType, '")
.append("WHERE (C_DocType_ID IS NULL OR C_DocType_ID=0")
@@ -212,7 +212,7 @@ public class ImportGLJournal extends SvrProcess
.append("WHERE GL_Category_ID IS NULL AND CategoryName IS NOT NULL")
.append(" AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set DocType=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set DocType=" + no);
sql = new StringBuilder ("UPDATE I_GLJournal i ")
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=Invalid Category, '")
.append("WHERE (GL_Category_ID IS NULL OR GL_Category_ID=0)")
@@ -228,14 +228,14 @@ public class ImportGLJournal extends SvrProcess
.append("WHERE C_Currency_ID IS NULL AND ISO_Code IS NOT NULL")
.append(" AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set Currency from ISO=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Currency from ISO=" + no);
sql = new StringBuilder ("UPDATE I_GLJournal i ")
.append("SET C_Currency_ID=(SELECT a.C_Currency_ID FROM C_AcctSchema a")
.append(" WHERE a.C_AcctSchema_ID=i.C_AcctSchema_ID AND a.AD_Client_ID=i.AD_Client_ID)")
.append("WHERE C_Currency_ID IS NULL AND ISO_Code IS NULL")
.append(" AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set Default Currency=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Default Currency=" + no);
sql = new StringBuilder ("UPDATE I_GLJournal i ")
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=Invalid Currency, '")
.append("WHERE (C_Currency_ID IS NULL OR C_Currency_ID=0)")
@@ -250,14 +250,14 @@ public class ImportGLJournal extends SvrProcess
.append("WHERE C_ConversionType_ID IS NULL AND ConversionTypeValue IS NULL")
.append(" AND I_IsImported='N'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set CurrencyType Value to Spot =" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set CurrencyType Value to Spot =" + no);
sql = new StringBuilder ("UPDATE I_GLJournal i ")
.append("SET C_ConversionType_ID=(SELECT c.C_ConversionType_ID FROM C_ConversionType c")
.append(" WHERE c.Value=i.ConversionTypeValue AND c.AD_Client_ID IN (0,i.AD_Client_ID)) ")
.append("WHERE C_ConversionType_ID IS NULL AND ConversionTypeValue IS NOT NULL")
.append(" AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set CurrencyType from Value=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set CurrencyType from Value=" + no);
sql = new StringBuilder ("UPDATE I_GLJournal i ")
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=Invalid CurrencyType, '")
.append("WHERE (C_ConversionType_ID IS NULL OR C_ConversionType_ID=0) AND ConversionTypeValue IS NOT NULL")
@@ -282,7 +282,7 @@ public class ImportGLJournal extends SvrProcess
.append(" WHERE a.C_AcctSchema_ID=i.C_AcctSchema_ID AND a.C_Currency_ID=i.C_Currency_ID)")
.append(" AND C_Currency_ID IS NOT NULL AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set Home CurrencyRate=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Home CurrencyRate=" + no);
// Set Currency Rate
sql = new StringBuilder ("UPDATE I_GLJournal i ")
.append("SET CurrencyRate=(SELECT MAX(r.MultiplyRate) FROM C_Conversion_Rate r, C_AcctSchema s")
@@ -295,7 +295,7 @@ public class ImportGLJournal extends SvrProcess
.append(") WHERE CurrencyRate IS NULL OR CurrencyRate=0 AND C_Currency_ID>0")
.append(" AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set Org Rate=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Org Rate=" + no);
sql = new StringBuilder ("UPDATE I_GLJournal i ")
.append("SET CurrencyRate=(SELECT MAX(r.MultiplyRate) FROM C_Conversion_Rate r, C_AcctSchema s")
.append(" WHERE s.C_AcctSchema_ID=i.C_AcctSchema_ID AND s.AD_Client_ID=i.AD_Client_ID")
@@ -307,7 +307,7 @@ public class ImportGLJournal extends SvrProcess
.append(") WHERE CurrencyRate IS NULL OR CurrencyRate=0 AND C_Currency_ID>0")
.append(" AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set Client Rate=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Client Rate=" + no);
sql = new StringBuilder ("UPDATE I_GLJournal i ")
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=No Rate, '")
.append("WHERE CurrencyRate IS NULL OR CurrencyRate=0")
@@ -327,7 +327,7 @@ public class ImportGLJournal extends SvrProcess
.append("WHERE C_Period_ID IS NULL")
.append(" AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set Period=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Period=" + no);
sql = new StringBuilder ("UPDATE I_GLJournal i ")
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=Invalid Period, '")
.append("WHERE C_Period_ID IS NULL OR C_Period_ID NOT IN")
@@ -355,7 +355,7 @@ public class ImportGLJournal extends SvrProcess
.append("SET PostingType='A' ")
.append("WHERE PostingType IS NULL AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set Actual PostingType=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Actual PostingType=" + no);
sql = new StringBuilder ("UPDATE I_GLJournal i ")
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=Invalid PostingType, ' ")
.append("WHERE PostingType IS NULL OR NOT EXISTS")
@@ -376,13 +376,13 @@ public class ImportGLJournal extends SvrProcess
.append("WHERE (AD_Org_ID IS NULL OR AD_Org_ID=0) AND OrgValue IS NOT NULL")
.append(" AND (C_ValidCombination_ID IS NULL OR C_ValidCombination_ID=0) AND I_IsImported<>'Y'");
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set Org from Value=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Org from Value=" + no);
sql = new StringBuilder ("UPDATE I_GLJournal i ")
.append("SET AD_Org_ID=AD_OrgDoc_ID ")
.append("WHERE (AD_Org_ID IS NULL OR AD_Org_ID=0) AND OrgValue IS NULL AND AD_OrgDoc_ID IS NOT NULL AND AD_OrgDoc_ID<>0")
.append(" AND (C_ValidCombination_ID IS NULL OR C_ValidCombination_ID=0) AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set Org from Doc Org=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Org from Doc Org=" + no);
// Error Org
sql = new StringBuilder ("UPDATE I_GLJournal o ")
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=Invalid Org, '")
@@ -403,7 +403,7 @@ public class ImportGLJournal extends SvrProcess
.append("WHERE Account_ID IS NULL AND AccountValue IS NOT NULL")
.append(" AND (C_ValidCombination_ID IS NULL OR C_ValidCombination_ID=0) AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set Account from Value=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Account from Value=" + no);
sql = new StringBuilder ("UPDATE I_GLJournal i ")
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=Invalid Account, '")
.append("WHERE (Account_ID IS NULL OR Account_ID=0)")
@@ -419,7 +419,7 @@ public class ImportGLJournal extends SvrProcess
.append("WHERE C_BPartner_ID IS NULL AND BPartnerValue IS NOT NULL")
.append(" AND (C_ValidCombination_ID IS NULL OR C_ValidCombination_ID=0) AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set BPartner from Value=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set BPartner from Value=" + no);
sql = new StringBuilder ("UPDATE I_GLJournal i ")
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=Invalid BPartner, '")
.append("WHERE C_BPartner_ID IS NULL AND BPartnerValue IS NOT NULL")
@@ -436,7 +436,7 @@ public class ImportGLJournal extends SvrProcess
.append("WHERE M_Product_ID IS NULL AND (ProductValue IS NOT NULL OR UPC IS NOT NULL OR SKU IS NOT NULL)")
.append(" AND (C_ValidCombination_ID IS NULL OR C_ValidCombination_ID=0) AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set Product from Value=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Product from Value=" + no);
sql = new StringBuilder ("UPDATE I_GLJournal i ")
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=Invalid Product, '")
.append("WHERE M_Product_ID IS NULL AND (ProductValue IS NOT NULL OR UPC IS NOT NULL OR SKU IS NOT NULL)")
@@ -452,7 +452,7 @@ public class ImportGLJournal extends SvrProcess
.append("WHERE C_Project_ID IS NULL AND ProjectValue IS NOT NULL")
.append(" AND (C_ValidCombination_ID IS NULL OR C_ValidCombination_ID=0) AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set Project from Value=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Project from Value=" + no);
sql = new StringBuilder ("UPDATE I_GLJournal i ")
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=Invalid Project, '")
.append("WHERE C_Project_ID IS NULL AND ProjectValue IS NOT NULL")
@@ -469,7 +469,7 @@ public class ImportGLJournal extends SvrProcess
.append("WHERE C_Campaign_ID IS NULL AND CampaignValue IS NOT NULL")
.append(" AND (C_ValidCombination_ID IS NULL OR C_ValidCombination_ID=0) AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set Campaign from Value=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Campaign from Value=" + no);
sql = new StringBuilder ("UPDATE I_GLJournal i ")
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=Invalid Campaign, '")
.append("WHERE C_Campaign_ID IS NULL AND CampaignValue IS NOT NULL")
@@ -485,7 +485,7 @@ public class ImportGLJournal extends SvrProcess
.append("WHERE C_Activity_ID IS NULL AND ActivityValue IS NOT NULL")
.append(" AND (C_ValidCombination_ID IS NULL OR C_ValidCombination_ID=0) AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set Activity from Value=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Activity from Value=" + no);
sql = new StringBuilder ("UPDATE I_GLJournal i ")
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=Invalid Activity, '")
.append("WHERE C_Activity_ID IS NULL AND ActivityValue IS NOT NULL")
@@ -501,7 +501,7 @@ public class ImportGLJournal extends SvrProcess
.append("WHERE C_SalesRegion_ID IS NULL AND SalesRegionValue IS NOT NULL")
.append(" AND (C_ValidCombination_ID IS NULL OR C_ValidCombination_ID=0) AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set SalesRegion from Value=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set SalesRegion from Value=" + no);
sql = new StringBuilder ("UPDATE I_GLJournal i ")
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=Invalid SalesRegion, '")
.append("WHERE C_SalesRegion_ID IS NULL AND SalesRegionValue IS NOT NULL")
@@ -518,7 +518,7 @@ public class ImportGLJournal extends SvrProcess
.append("WHERE AD_OrgTrx_ID IS NULL AND OrgTrxValue IS NOT NULL")
.append(" AND (C_ValidCombination_ID IS NULL OR C_ValidCombination_ID=0) AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set OrgTrx from Value=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set OrgTrx from Value=" + no);
sql = new StringBuilder ("UPDATE I_GLJournal i ")
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=Invalid OrgTrx, '")
.append("WHERE AD_OrgTrx_ID IS NULL AND OrgTrxValue IS NOT NULL")
@@ -534,13 +534,13 @@ public class ImportGLJournal extends SvrProcess
.append("WHERE AmtSourceDr IS NULL")
.append(" AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set 0 Source Dr=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set 0 Source Dr=" + no);
sql = new StringBuilder ("UPDATE I_GLJournal ")
.append("SET AmtSourceCr = 0 ")
.append("WHERE AmtSourceCr IS NULL")
.append(" AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set 0 Source Cr=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set 0 Source Cr=" + no);
sql = new StringBuilder ("UPDATE I_GLJournal i ")
.append("SET I_ErrorMsg=I_ErrorMsg||'WARN=Zero Source Balance, ' ")
.append("WHERE (AmtSourceDr-AmtSourceCr)=0")
@@ -555,13 +555,13 @@ public class ImportGLJournal extends SvrProcess
.append("WHERE AmtAcctDr IS NULL OR AmtAcctDr=0")
.append(" AND I_IsImported='N'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Calculate Acct Dr=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Calculate Acct Dr=" + no);
sql = new StringBuilder ("UPDATE I_GLJournal ")
.append("SET AmtAcctCr = ROUND(AmtSourceCr * CurrencyRate, 2) ")
.append("WHERE AmtAcctCr IS NULL OR AmtAcctCr=0")
.append(" AND I_IsImported='N'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Calculate Acct Cr=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Calculate Acct Cr=" + no);
sql = new StringBuilder ("UPDATE I_GLJournal i ")
.append("SET I_ErrorMsg=I_ErrorMsg||'WARN=Zero Acct Balance, ' ")
.append("WHERE (AmtSourceDr-AmtSourceCr)<>0 AND (AmtAcctDr-AmtAcctCr)=0")
diff --git a/org.adempiere.base.process/src/org/compiere/process/ImportInOutConfirm.java b/org.adempiere.base.process/src/org/compiere/process/ImportInOutConfirm.java
index dbce76bcf3..ea9850e01d 100644
--- a/org.adempiere.base.process/src/org/compiere/process/ImportInOutConfirm.java
+++ b/org.adempiere.base.process/src/org/compiere/process/ImportInOutConfirm.java
@@ -80,7 +80,7 @@ public class ImportInOutConfirm extends SvrProcess
sql = new StringBuilder ("DELETE I_InOutLineConfirm ")
.append("WHERE I_IsImported='Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Delete Old Impored =" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Delete Old Impored =" + no);
}
// Set IsActive, Created/Updated
@@ -102,7 +102,7 @@ public class ImportInOutConfirm extends SvrProcess
.append("WHERE (AD_Client_ID IS NULL OR AD_Client_ID=0)")
.append(" AND I_IsImported<>'Y'");
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set Client from Value=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Client from Value=" + no);
// Error Confirmation Line
sql = new StringBuilder ("UPDATE I_InOutLineConfirm i ")
diff --git a/org.adempiere.base.process/src/org/compiere/process/ImportInventory.java b/org.adempiere.base.process/src/org/compiere/process/ImportInventory.java
index 31ac613127..5c85243c54 100644
--- a/org.adempiere.base.process/src/org/compiere/process/ImportInventory.java
+++ b/org.adempiere.base.process/src/org/compiere/process/ImportInventory.java
@@ -149,7 +149,7 @@ public class ImportInventory extends SvrProcess
sql = new StringBuilder ("DELETE I_Inventory ")
.append("WHERE I_IsImported='Y'").append (clientCheck);
no = DB.executeUpdate (sql.toString (), get_TrxName());
- log.fine("Delete Old Imported=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Delete Old Imported=" + no);
}
// Set Client, Org, Location, IsActive, Created/Updated
@@ -186,7 +186,7 @@ public class ImportInventory extends SvrProcess
.append("WHERE C_DocType_ID IS NULL AND DocTypeName IS NOT NULL")
.append(" AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set DocType=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set DocType=" + no);
sql = new StringBuilder ("UPDATE I_Inventory i ")
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=Invalid DocType, ' ")
.append("WHERE C_DocType_ID IS NULL AND DocTypeName IS NOT NULL")
@@ -202,14 +202,14 @@ public class ImportInventory extends SvrProcess
.append("WHERE M_Locator_ID IS NULL AND LocatorValue IS NOT NULL")
.append(" AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate (sql.toString (), get_TrxName());
- log.fine("Set Locator from Value =" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Locator from Value =" + no);
sql = new StringBuilder ("UPDATE I_Inventory i ")
.append("SET M_Locator_ID=(SELECT MAX(M_Locator_ID) FROM M_Locator l")
.append(" WHERE i.X=l.X AND i.Y=l.Y AND i.Z=l.Z AND i.AD_Client_ID=l.AD_Client_ID) ")
.append("WHERE M_Locator_ID IS NULL AND X IS NOT NULL AND Y IS NOT NULL AND Z IS NOT NULL")
.append(" AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate (sql.toString (), get_TrxName());
- log.fine("Set Locator from X,Y,Z =" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Locator from X,Y,Z =" + no);
if (p_M_Locator_ID != 0)
{
sql = new StringBuilder ("UPDATE I_Inventory ")
@@ -217,7 +217,7 @@ public class ImportInventory extends SvrProcess
.append (" WHERE M_Locator_ID IS NULL")
.append(" AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate (sql.toString (), get_TrxName());
- log.fine("Set Locator from Parameter=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Locator from Parameter=" + no);
}
sql = new StringBuilder ("UPDATE I_Inventory ")
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=No Location, ' ")
@@ -233,7 +233,7 @@ public class ImportInventory extends SvrProcess
.append("WHERE M_Locator_ID IS NOT NULL")
.append(" AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate (sql.toString (), get_TrxName());
- log.fine("Set Warehouse from Locator =" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Warehouse from Locator =" + no);
sql = new StringBuilder ("UPDATE I_Inventory ")
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=No Warehouse, ' ")
.append("WHERE M_Warehouse_ID IS NULL")
@@ -258,14 +258,14 @@ public class ImportInventory extends SvrProcess
.append("WHERE M_Product_ID IS NULL AND Value IS NOT NULL")
.append(" AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate (sql.toString (), get_TrxName());
- log.fine("Set Product from Value=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Product from Value=" + no);
sql = new StringBuilder ("UPDATE I_Inventory i ")
.append("SET M_Product_ID=(SELECT MAX(M_Product_ID) FROM M_Product p")
.append(" WHERE i.UPC=p.UPC AND i.AD_Client_ID=p.AD_Client_ID) ")
.append("WHERE M_Product_ID IS NULL AND UPC IS NOT NULL")
.append(" AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate (sql.toString (), get_TrxName());
- log.fine("Set Product from UPC=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Product from UPC=" + no);
sql = new StringBuilder ("UPDATE I_Inventory ")
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=No Product, ' ")
.append("WHERE M_Product_ID IS NULL")
@@ -280,7 +280,7 @@ public class ImportInventory extends SvrProcess
.append(" WHERE o.ChargeName=p.Name AND o.AD_Client_ID=p.AD_Client_ID) ")
.append("WHERE C_Charge_ID IS NULL AND ChargeName IS NOT NULL AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set Charge=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Charge=" + no);
sql = new StringBuilder ("UPDATE I_Inventory ")
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=Invalid Charge, ' ")
.append("WHERE C_Charge_ID IS NULL AND (ChargeName IS NOT NULL)")
diff --git a/org.adempiere.base.process/src/org/compiere/process/ImportInvoice.java b/org.adempiere.base.process/src/org/compiere/process/ImportInvoice.java
index f9547e721a..5f38d284e9 100644
--- a/org.adempiere.base.process/src/org/compiere/process/ImportInvoice.java
+++ b/org.adempiere.base.process/src/org/compiere/process/ImportInvoice.java
@@ -98,7 +98,7 @@ public class ImportInvoice extends SvrProcess
sql = new StringBuilder ("DELETE I_Invoice ")
.append("WHERE I_IsImported='Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Delete Old Impored =" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Delete Old Impored =" + no);
}
// Set Client, Org, IsActive, Created/Updated
@@ -132,14 +132,14 @@ public class ImportInvoice extends SvrProcess
.append("WHERE C_DocType_ID IS NULL AND IsSOTrx='N' AND DocTypeName IS NOT NULL AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
if (no != 0)
- log.fine("Set PO DocType=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set PO DocType=" + no);
sql = new StringBuilder ("UPDATE I_Invoice o ")
.append("SET C_DocType_ID=(SELECT C_DocType_ID FROM C_DocType d WHERE d.Name=o.DocTypeName")
.append(" AND d.DocBaseType IN ('ARI','ARC') AND o.AD_Client_ID=d.AD_Client_ID) ")
.append("WHERE C_DocType_ID IS NULL AND IsSOTrx='Y' AND DocTypeName IS NOT NULL AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
if (no != 0)
- log.fine("Set SO DocType=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set SO DocType=" + no);
sql = new StringBuilder ("UPDATE I_Invoice o ")
.append("SET C_DocType_ID=(SELECT C_DocType_ID FROM C_DocType d WHERE d.Name=o.DocTypeName")
.append(" AND d.DocBaseType IN ('API','ARI','APC','ARC') AND o.AD_Client_ID=d.AD_Client_ID) ")
@@ -147,7 +147,7 @@ public class ImportInvoice extends SvrProcess
.append("WHERE C_DocType_ID IS NULL AND DocTypeName IS NOT NULL AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
if (no != 0)
- log.fine("Set DocType=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set DocType=" + no);
sql = new StringBuilder ("UPDATE I_Invoice ")
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=Invalid DocTypeName, ' ")
.append("WHERE C_DocType_ID IS NULL AND DocTypeName IS NOT NULL")
@@ -162,21 +162,21 @@ public class ImportInvoice extends SvrProcess
.append("WHERE C_DocType_ID IS NULL AND IsSOTrx='N' AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
if (no != 0)
- log.fine("Set PO Default DocType=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set PO Default DocType=" + no);
sql = new StringBuilder ("UPDATE I_Invoice o ")
.append("SET C_DocType_ID=(SELECT MAX(C_DocType_ID) FROM C_DocType d WHERE d.IsDefault='Y'")
.append(" AND d.DocBaseType='ARI' AND o.AD_Client_ID=d.AD_Client_ID) ")
.append("WHERE C_DocType_ID IS NULL AND IsSOTrx='Y' AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
if (no != 0)
- log.fine("Set SO Default DocType=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set SO Default DocType=" + no);
sql = new StringBuilder ("UPDATE I_Invoice o ")
.append("SET C_DocType_ID=(SELECT MAX(C_DocType_ID) FROM C_DocType d WHERE d.IsDefault='Y'")
.append(" AND d.DocBaseType IN('ARI','API') AND o.AD_Client_ID=d.AD_Client_ID) ")
.append("WHERE C_DocType_ID IS NULL AND IsSOTrx IS NULL AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
if (no != 0)
- log.fine("Set Default DocType=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Default DocType=" + no);
sql = new StringBuilder ("UPDATE I_Invoice ")
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=No DocType, ' ")
.append("WHERE C_DocType_ID IS NULL")
@@ -191,13 +191,13 @@ public class ImportInvoice extends SvrProcess
.append(" AND C_DocType_ID IS NOT NULL")
.append(" AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set IsSOTrx=Y=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set IsSOTrx=Y=" + no);
sql = new StringBuilder ("UPDATE I_Invoice o SET IsSOTrx='N' ")
.append("WHERE EXISTS (SELECT * FROM C_DocType d WHERE o.C_DocType_ID=d.C_DocType_ID AND d.DocBaseType='API' AND o.AD_Client_ID=d.AD_Client_ID)")
.append(" AND C_DocType_ID IS NOT NULL")
.append(" AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set IsSOTrx=N=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set IsSOTrx=N=" + no);
// Price List
sql = new StringBuilder ("UPDATE I_Invoice o ")
@@ -205,25 +205,25 @@ public class ImportInvoice extends SvrProcess
.append(" AND p.C_Currency_ID=o.C_Currency_ID AND p.IsSOPriceList=o.IsSOTrx AND o.AD_Client_ID=p.AD_Client_ID) ")
.append("WHERE M_PriceList_ID IS NULL AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set Default Currency PriceList=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Default Currency PriceList=" + no);
sql = new StringBuilder ("UPDATE I_Invoice o ")
.append("SET M_PriceList_ID=(SELECT MAX(M_PriceList_ID) FROM M_PriceList p WHERE p.IsDefault='Y'")
.append(" AND p.IsSOPriceList=o.IsSOTrx AND o.AD_Client_ID=p.AD_Client_ID) ")
.append("WHERE M_PriceList_ID IS NULL AND C_Currency_ID IS NULL AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set Default PriceList=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Default PriceList=" + no);
sql = new StringBuilder ("UPDATE I_Invoice o ")
.append("SET M_PriceList_ID=(SELECT MAX(M_PriceList_ID) FROM M_PriceList p ")
.append(" WHERE p.C_Currency_ID=o.C_Currency_ID AND p.IsSOPriceList=o.IsSOTrx AND o.AD_Client_ID=p.AD_Client_ID) ")
.append("WHERE M_PriceList_ID IS NULL AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set Currency PriceList=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Currency PriceList=" + no);
sql = new StringBuilder ("UPDATE I_Invoice o ")
.append("SET M_PriceList_ID=(SELECT MAX(M_PriceList_ID) FROM M_PriceList p ")
.append(" WHERE p.IsSOPriceList=o.IsSOTrx AND o.AD_Client_ID=p.AD_Client_ID) ")
.append("WHERE M_PriceList_ID IS NULL AND C_Currency_ID IS NULL AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set PriceList=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set PriceList=" + no);
//
sql = new StringBuilder ("UPDATE I_Invoice ")
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=No PriceList, ' ")
@@ -239,13 +239,13 @@ public class ImportInvoice extends SvrProcess
.append(" WHERE o.PaymentTermValue=p.Value AND o.AD_Client_ID=p.AD_Client_ID) ")
.append("WHERE C_PaymentTerm_ID IS NULL AND PaymentTermValue IS NOT NULL AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set PaymentTerm=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set PaymentTerm=" + no);
sql = new StringBuilder ("UPDATE I_Invoice o ")
.append("SET C_PaymentTerm_ID=(SELECT MAX(C_PaymentTerm_ID) FROM C_PaymentTerm p")
.append(" WHERE p.IsDefault='Y' AND o.AD_Client_ID=p.AD_Client_ID) ")
.append("WHERE C_PaymentTerm_ID IS NULL AND o.PaymentTermValue IS NULL AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set Default PaymentTerm=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Default PaymentTerm=" + no);
//
sql = new StringBuilder ("UPDATE I_Invoice ")
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=No PaymentTerm, ' ")
@@ -262,7 +262,7 @@ public class ImportInvoice extends SvrProcess
.append(" WHERE o.ProjectValue=p.Value AND o.AD_Client_ID=p.AD_Client_ID) ")
.append("WHERE C_Project_ID IS NULL AND ProjectValue IS NOT NULL AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set Project=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Project=" + no);
sql = new StringBuilder ("UPDATE I_Invoice ")
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=Invalid Project, ' ")
.append("WHERE C_Project_ID IS NULL AND (ProjectValue IS NOT NULL)")
@@ -276,7 +276,7 @@ public class ImportInvoice extends SvrProcess
.append(" WHERE o.ActivityValue=p.Value AND o.AD_Client_ID=p.AD_Client_ID) ")
.append("WHERE C_Activity_ID IS NULL AND ActivityValue IS NOT NULL AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set Activity=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Activity=" + no);
sql = new StringBuilder ("UPDATE I_Invoice ")
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=Invalid Activity, ' ")
.append("WHERE C_Activity_ID IS NULL AND (ActivityValue IS NOT NULL)")
@@ -291,7 +291,7 @@ public class ImportInvoice extends SvrProcess
.append(" WHERE o.ChargeName=p.Name AND o.AD_Client_ID=p.AD_Client_ID) ")
.append("WHERE C_Charge_ID IS NULL AND ChargeName IS NOT NULL AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set Charge=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Charge=" + no);
sql = new StringBuilder ("UPDATE I_Invoice ")
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=Invalid Charge, ' ")
.append("WHERE C_Charge_ID IS NULL AND (ChargeName IS NOT NULL)")
@@ -308,7 +308,7 @@ public class ImportInvoice extends SvrProcess
.append("WHERE C_BPartner_ID IS NULL AND EMail IS NOT NULL")
.append(" AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set BP from EMail=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set BP from EMail=" + no);
// BP from ContactName
sql = new StringBuilder ("UPDATE I_Invoice o ")
.append("SET (C_BPartner_ID,AD_User_ID)=(SELECT C_BPartner_ID,AD_User_ID FROM AD_User u")
@@ -317,7 +317,7 @@ public class ImportInvoice extends SvrProcess
.append(" AND EXISTS (SELECT Name FROM AD_User u WHERE o.ContactName=u.Name AND o.AD_Client_ID=u.AD_Client_ID AND u.C_BPartner_ID IS NOT NULL GROUP BY Name HAVING COUNT(*)=1)")
.append(" AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set BP from ContactName=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set BP from ContactName=" + no);
// BP from Value
sql = new StringBuilder ("UPDATE I_Invoice o ")
.append("SET C_BPartner_ID=(SELECT MAX(C_BPartner_ID) FROM C_BPartner bp")
@@ -325,7 +325,7 @@ public class ImportInvoice extends SvrProcess
.append("WHERE C_BPartner_ID IS NULL AND BPartnerValue IS NOT NULL")
.append(" AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set BP from Value=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set BP from Value=" + no);
// Default BP
sql = new StringBuilder ("UPDATE I_Invoice o ")
.append("SET C_BPartner_ID=(SELECT C_BPartnerCashTrx_ID FROM AD_ClientInfo c")
@@ -333,7 +333,7 @@ public class ImportInvoice extends SvrProcess
.append("WHERE C_BPartner_ID IS NULL AND BPartnerValue IS NULL AND Name IS NULL")
.append(" AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set Default BP=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Default BP=" + no);
// Existing Location ? Exact Match
sql = new StringBuilder ("UPDATE I_Invoice o ")
@@ -346,7 +346,7 @@ public class ImportInvoice extends SvrProcess
.append("WHERE C_BPartner_ID IS NOT NULL AND C_BPartner_Location_ID IS NULL")
.append(" AND I_IsImported='N'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Found Location=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Found Location=" + no);
// Set Location from BPartner
sql = new StringBuilder ("UPDATE I_Invoice o ")
.append("SET C_BPartner_Location_ID=(SELECT MAX(C_BPartner_Location_ID) FROM C_BPartner_Location l")
@@ -356,7 +356,7 @@ public class ImportInvoice extends SvrProcess
.append("WHERE C_BPartner_ID IS NOT NULL AND C_BPartner_Location_ID IS NULL")
.append(" AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set BP Location from BP=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set BP Location from BP=" + no);
//
sql = new StringBuilder ("UPDATE I_Invoice ")
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=No BP Location, ' ")
@@ -382,7 +382,7 @@ public class ImportInvoice extends SvrProcess
.append("WHERE C_BPartner_ID IS NULL AND C_Country_ID IS NULL AND CountryCode IS NOT NULL")
.append(" AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set Country=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Country=" + no);
//
sql = new StringBuilder ("UPDATE I_Invoice ")
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=Invalid Country, ' ")
@@ -400,7 +400,7 @@ public class ImportInvoice extends SvrProcess
.append("WHERE C_BPartner_ID IS NULL AND C_Region_ID IS NULL AND RegionName IS NULL")
.append(" AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set Region Default=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Region Default=" + no);
//
sql = new StringBuilder ("UPDATE I_Invoice o ")
.append("Set C_Region_ID=(SELECT C_Region_ID FROM C_Region r")
@@ -409,7 +409,7 @@ public class ImportInvoice extends SvrProcess
.append("WHERE C_BPartner_ID IS NULL AND C_Region_ID IS NULL AND RegionName IS NOT NULL")
.append(" AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set Region=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Region=" + no);
//
sql = new StringBuilder ("UPDATE I_Invoice o ")
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=Invalid Region, ' ")
@@ -428,21 +428,21 @@ public class ImportInvoice extends SvrProcess
.append("WHERE M_Product_ID IS NULL AND ProductValue IS NOT NULL")
.append(" AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set Product from Value=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Product from Value=" + no);
sql = new StringBuilder ("UPDATE I_Invoice o ")
.append("SET M_Product_ID=(SELECT MAX(M_Product_ID) FROM M_Product p")
.append(" WHERE o.UPC=p.UPC AND o.AD_Client_ID=p.AD_Client_ID) ")
.append("WHERE M_Product_ID IS NULL AND UPC IS NOT NULL")
.append(" AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set Product from UPC=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Product from UPC=" + no);
sql = new StringBuilder ("UPDATE I_Invoice o ")
.append("SET M_Product_ID=(SELECT MAX(M_Product_ID) FROM M_Product p")
.append(" WHERE o.SKU=p.SKU AND o.AD_Client_ID=p.AD_Client_ID) ")
.append("WHERE M_Product_ID IS NULL AND SKU IS NOT NULL")
.append(" AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set Product fom SKU=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Product fom SKU=" + no);
sql = new StringBuilder ("UPDATE I_Invoice ")
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=Invalid Product, ' ")
.append("WHERE M_Product_ID IS NULL AND (ProductValue IS NOT NULL OR UPC IS NOT NULL OR SKU IS NOT NULL)")
@@ -467,7 +467,7 @@ public class ImportInvoice extends SvrProcess
.append("WHERE C_Tax_ID IS NULL AND TaxIndicator IS NOT NULL")
.append(" AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set Tax=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Tax=" + no);
sql = new StringBuilder ("UPDATE I_Invoice ")
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=Invalid Tax, ' ")
.append("WHERE C_Tax_ID IS NULL AND TaxIndicator IS NOT NULL")
diff --git a/org.adempiere.base.process/src/org/compiere/process/ImportOrder.java b/org.adempiere.base.process/src/org/compiere/process/ImportOrder.java
index 25ae8d22bb..93de2663e6 100644
--- a/org.adempiere.base.process/src/org/compiere/process/ImportOrder.java
+++ b/org.adempiere.base.process/src/org/compiere/process/ImportOrder.java
@@ -100,7 +100,7 @@ public class ImportOrder extends SvrProcess
sql = new StringBuilder ("DELETE I_Order ")
.append("WHERE I_IsImported='Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Delete Old Impored =" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Delete Old Impored =" + no);
}
// Set Client, Org, IsActive, Created/Updated
@@ -133,20 +133,20 @@ public class ImportOrder extends SvrProcess
.append(" AND d.DocBaseType='POO' AND o.AD_Client_ID=d.AD_Client_ID) ")
.append("WHERE C_DocType_ID IS NULL AND IsSOTrx='N' AND DocTypeName IS NOT NULL AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set PO DocType=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set PO DocType=" + no);
sql = new StringBuilder ("UPDATE I_Order o ") // SO Document Type Name
.append("SET C_DocType_ID=(SELECT C_DocType_ID FROM C_DocType d WHERE d.Name=o.DocTypeName")
.append(" AND d.DocBaseType='SOO' AND o.AD_Client_ID=d.AD_Client_ID) ")
.append("WHERE C_DocType_ID IS NULL AND IsSOTrx='Y' AND DocTypeName IS NOT NULL AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set SO DocType=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set SO DocType=" + no);
sql = new StringBuilder ("UPDATE I_Order o ")
.append("SET C_DocType_ID=(SELECT C_DocType_ID FROM C_DocType d WHERE d.Name=o.DocTypeName")
.append(" AND d.DocBaseType IN ('SOO','POO') AND o.AD_Client_ID=d.AD_Client_ID) ")
//+ "WHERE C_DocType_ID IS NULL AND IsSOTrx IS NULL AND DocTypeName IS NOT NULL AND I_IsImported<>'Y'").append (clientCheck);
.append("WHERE C_DocType_ID IS NULL AND DocTypeName IS NOT NULL AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set DocType=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set DocType=" + no);
sql = new StringBuilder ("UPDATE I_Order ") // Error Invalid Doc Type Name
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=Invalid DocTypeName, ' ")
.append("WHERE C_DocType_ID IS NULL AND DocTypeName IS NOT NULL")
@@ -160,19 +160,19 @@ public class ImportOrder extends SvrProcess
.append(" AND d.DocBaseType='POO' AND o.AD_Client_ID=d.AD_Client_ID) ")
.append("WHERE C_DocType_ID IS NULL AND IsSOTrx='N' AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set PO Default DocType=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set PO Default DocType=" + no);
sql = new StringBuilder ("UPDATE I_Order o ") // Default SO
.append("SET C_DocType_ID=(SELECT MAX(C_DocType_ID) FROM C_DocType d WHERE d.IsDefault='Y'")
.append(" AND d.DocBaseType='SOO' AND o.AD_Client_ID=d.AD_Client_ID) ")
.append("WHERE C_DocType_ID IS NULL AND IsSOTrx='Y' AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set SO Default DocType=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set SO Default DocType=" + no);
sql = new StringBuilder ("UPDATE I_Order o ")
.append("SET C_DocType_ID=(SELECT MAX(C_DocType_ID) FROM C_DocType d WHERE d.IsDefault='Y'")
.append(" AND d.DocBaseType IN('SOO','POO') AND o.AD_Client_ID=d.AD_Client_ID) ")
.append("WHERE C_DocType_ID IS NULL AND IsSOTrx IS NULL AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set Default DocType=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Default DocType=" + no);
sql = new StringBuilder ("UPDATE I_Order ") // No DocType
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=No DocType, ' ")
.append("WHERE C_DocType_ID IS NULL")
@@ -187,13 +187,13 @@ public class ImportOrder extends SvrProcess
.append(" AND C_DocType_ID IS NOT NULL")
.append(" AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set IsSOTrx=Y=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set IsSOTrx=Y=" + no);
sql = new StringBuilder ("UPDATE I_Order o SET IsSOTrx='N' ")
.append("WHERE EXISTS (SELECT * FROM C_DocType d WHERE o.C_DocType_ID=d.C_DocType_ID AND d.DocBaseType='POO' AND o.AD_Client_ID=d.AD_Client_ID)")
.append(" AND C_DocType_ID IS NOT NULL")
.append(" AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set IsSOTrx=N=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set IsSOTrx=N=" + no);
// Price List
sql = new StringBuilder ("UPDATE I_Order o ")
@@ -201,25 +201,25 @@ public class ImportOrder extends SvrProcess
.append(" AND p.C_Currency_ID=o.C_Currency_ID AND p.IsSOPriceList=o.IsSOTrx AND o.AD_Client_ID=p.AD_Client_ID) ")
.append("WHERE M_PriceList_ID IS NULL AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set Default Currency PriceList=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Default Currency PriceList=" + no);
sql = new StringBuilder ("UPDATE I_Order o ")
.append("SET M_PriceList_ID=(SELECT MAX(M_PriceList_ID) FROM M_PriceList p WHERE p.IsDefault='Y'")
.append(" AND p.IsSOPriceList=o.IsSOTrx AND o.AD_Client_ID=p.AD_Client_ID) ")
.append("WHERE M_PriceList_ID IS NULL AND C_Currency_ID IS NULL AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set Default PriceList=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Default PriceList=" + no);
sql = new StringBuilder ("UPDATE I_Order o ")
.append("SET M_PriceList_ID=(SELECT MAX(M_PriceList_ID) FROM M_PriceList p ")
.append(" WHERE p.C_Currency_ID=o.C_Currency_ID AND p.IsSOPriceList=o.IsSOTrx AND o.AD_Client_ID=p.AD_Client_ID) ")
.append("WHERE M_PriceList_ID IS NULL AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set Currency PriceList=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Currency PriceList=" + no);
sql = new StringBuilder ("UPDATE I_Order o ")
.append("SET M_PriceList_ID=(SELECT MAX(M_PriceList_ID) FROM M_PriceList p ")
.append(" WHERE p.IsSOPriceList=o.IsSOTrx AND o.AD_Client_ID=p.AD_Client_ID) ")
.append("WHERE M_PriceList_ID IS NULL AND C_Currency_ID IS NULL AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set PriceList=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set PriceList=" + no);
//
sql = new StringBuilder ("UPDATE I_Order ")
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=No PriceList, ' ")
@@ -235,7 +235,7 @@ public class ImportOrder extends SvrProcess
.append(" WHERE o.C_OrderSourceValue=p.Value AND o.AD_Client_ID=p.AD_Client_ID) ")
.append("WHERE C_OrderSource_ID IS NULL AND C_OrderSourceValue IS NOT NULL AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set Order Source=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Order Source=" + no);
// Set proper error message
sql = new StringBuilder ("UPDATE I_Order ")
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=Not Found Order Source, ' ")
@@ -250,13 +250,13 @@ public class ImportOrder extends SvrProcess
.append(" WHERE o.PaymentTermValue=p.Value AND o.AD_Client_ID=p.AD_Client_ID) ")
.append("WHERE C_PaymentTerm_ID IS NULL AND PaymentTermValue IS NOT NULL AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set PaymentTerm=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set PaymentTerm=" + no);
sql = new StringBuilder ("UPDATE I_Order o ")
.append("SET C_PaymentTerm_ID=(SELECT MAX(C_PaymentTerm_ID) FROM C_PaymentTerm p")
.append(" WHERE p.IsDefault='Y' AND o.AD_Client_ID=p.AD_Client_ID) ")
.append("WHERE C_PaymentTerm_ID IS NULL AND o.PaymentTermValue IS NULL AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set Default PaymentTerm=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Default PaymentTerm=" + no);
//
sql = new StringBuilder ("UPDATE I_Order ")
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=No PaymentTerm, ' ")
@@ -273,7 +273,7 @@ public class ImportOrder extends SvrProcess
.append("WHERE M_Warehouse_ID IS NULL AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName()); // Warehouse for Org
if (no != 0)
- log.fine("Set Warehouse=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Warehouse=" + no);
sql = new StringBuilder ("UPDATE I_Order o ")
.append("SET M_Warehouse_ID=(SELECT M_Warehouse_ID FROM M_Warehouse w")
.append(" WHERE o.AD_Client_ID=w.AD_Client_ID) ")
@@ -282,7 +282,7 @@ public class ImportOrder extends SvrProcess
.append(" AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
if (no != 0)
- log.fine("Set Only Client Warehouse=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Only Client Warehouse=" + no);
//
sql = new StringBuilder ("UPDATE I_Order ")
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=No Warehouse, ' ")
@@ -299,7 +299,7 @@ public class ImportOrder extends SvrProcess
.append("WHERE C_BPartner_ID IS NULL AND EMail IS NOT NULL")
.append(" AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set BP from EMail=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set BP from EMail=" + no);
// BP from ContactName
sql = new StringBuilder ("UPDATE I_Order o ")
.append("SET (C_BPartner_ID,AD_User_ID)=(SELECT C_BPartner_ID,AD_User_ID FROM AD_User u")
@@ -308,7 +308,7 @@ public class ImportOrder extends SvrProcess
.append(" AND EXISTS (SELECT Name FROM AD_User u WHERE o.ContactName=u.Name AND o.AD_Client_ID=u.AD_Client_ID AND u.C_BPartner_ID IS NOT NULL GROUP BY Name HAVING COUNT(*)=1)")
.append(" AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set BP from ContactName=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set BP from ContactName=" + no);
// BP from Value
sql = new StringBuilder ("UPDATE I_Order o ")
.append("SET C_BPartner_ID=(SELECT MAX(C_BPartner_ID) FROM C_BPartner bp")
@@ -316,7 +316,7 @@ public class ImportOrder extends SvrProcess
.append("WHERE C_BPartner_ID IS NULL AND BPartnerValue IS NOT NULL")
.append(" AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set BP from Value=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set BP from Value=" + no);
// Default BP
sql = new StringBuilder ("UPDATE I_Order o ")
.append("SET C_BPartner_ID=(SELECT C_BPartnerCashTrx_ID FROM AD_ClientInfo c")
@@ -324,7 +324,7 @@ public class ImportOrder extends SvrProcess
.append("WHERE C_BPartner_ID IS NULL AND BPartnerValue IS NULL AND Name IS NULL")
.append(" AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set Default BP=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Default BP=" + no);
// Existing Location ? Exact Match
sql = new StringBuilder ("UPDATE I_Order o ")
@@ -337,7 +337,7 @@ public class ImportOrder extends SvrProcess
.append("WHERE C_BPartner_ID IS NOT NULL AND C_BPartner_Location_ID IS NULL")
.append(" AND I_IsImported='N'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Found Location=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Found Location=" + no);
// Set Bill Location from BPartner
sql = new StringBuilder ("UPDATE I_Order o ")
.append("SET BillTo_ID=(SELECT MAX(C_BPartner_Location_ID) FROM C_BPartner_Location l")
@@ -347,7 +347,7 @@ public class ImportOrder extends SvrProcess
.append("WHERE C_BPartner_ID IS NOT NULL AND BillTo_ID IS NULL")
.append(" AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set BP BillTo from BP=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set BP BillTo from BP=" + no);
// Set Location from BPartner
sql = new StringBuilder ("UPDATE I_Order o ")
.append("SET C_BPartner_Location_ID=(SELECT MAX(C_BPartner_Location_ID) FROM C_BPartner_Location l")
@@ -357,7 +357,7 @@ public class ImportOrder extends SvrProcess
.append("WHERE C_BPartner_ID IS NOT NULL AND C_BPartner_Location_ID IS NULL")
.append(" AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set BP Location from BP=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set BP Location from BP=" + no);
//
sql = new StringBuilder ("UPDATE I_Order ")
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=No BP Location, ' ")
@@ -383,7 +383,7 @@ public class ImportOrder extends SvrProcess
.append("WHERE C_BPartner_ID IS NULL AND C_Country_ID IS NULL AND CountryCode IS NOT NULL")
.append(" AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set Country=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Country=" + no);
//
sql = new StringBuilder ("UPDATE I_Order ")
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=Invalid Country, ' ")
@@ -401,7 +401,7 @@ public class ImportOrder extends SvrProcess
.append("WHERE C_BPartner_ID IS NULL AND C_Region_ID IS NULL AND RegionName IS NULL")
.append(" AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set Region Default=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Region Default=" + no);
//
sql = new StringBuilder ("UPDATE I_Order o ")
.append("Set C_Region_ID=(SELECT C_Region_ID FROM C_Region r")
@@ -410,7 +410,7 @@ public class ImportOrder extends SvrProcess
.append("WHERE C_BPartner_ID IS NULL AND C_Region_ID IS NULL AND RegionName IS NOT NULL")
.append(" AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set Region=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Region=" + no);
//
sql = new StringBuilder ("UPDATE I_Order o ")
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=Invalid Region, ' ")
@@ -429,21 +429,21 @@ public class ImportOrder extends SvrProcess
.append("WHERE M_Product_ID IS NULL AND ProductValue IS NOT NULL")
.append(" AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set Product from Value=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Product from Value=" + no);
sql = new StringBuilder ("UPDATE I_Order o ")
.append("SET M_Product_ID=(SELECT MAX(M_Product_ID) FROM M_Product p")
.append(" WHERE o.UPC=p.UPC AND o.AD_Client_ID=p.AD_Client_ID) ")
.append("WHERE M_Product_ID IS NULL AND UPC IS NOT NULL")
.append(" AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set Product from UPC=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Product from UPC=" + no);
sql = new StringBuilder ("UPDATE I_Order o ")
.append("SET M_Product_ID=(SELECT MAX(M_Product_ID) FROM M_Product p")
.append(" WHERE o.SKU=p.SKU AND o.AD_Client_ID=p.AD_Client_ID) ")
.append("WHERE M_Product_ID IS NULL AND SKU IS NOT NULL")
.append(" AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set Product fom SKU=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Product fom SKU=" + no);
sql = new StringBuilder ("UPDATE I_Order ")
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=Invalid Product, ' ")
.append("WHERE M_Product_ID IS NULL AND (ProductValue IS NOT NULL OR UPC IS NOT NULL OR SKU IS NOT NULL)")
@@ -458,7 +458,7 @@ public class ImportOrder extends SvrProcess
.append(" WHERE o.ChargeName=c.Name AND o.AD_Client_ID=c.AD_Client_ID) ")
.append("WHERE C_Charge_ID IS NULL AND ChargeName IS NOT NULL AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set Charge=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Charge=" + no);
sql = new StringBuilder ("UPDATE I_Order ")
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=Invalid Charge, ' ")
.append("WHERE C_Charge_ID IS NULL AND (ChargeName IS NOT NULL)")
@@ -483,7 +483,7 @@ public class ImportOrder extends SvrProcess
.append("WHERE C_Tax_ID IS NULL AND TaxIndicator IS NOT NULL")
.append(" AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set Tax=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Tax=" + no);
sql = new StringBuilder ("UPDATE I_Order ")
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=Invalid Tax, ' ")
.append("WHERE C_Tax_ID IS NULL AND TaxIndicator IS NOT NULL")
diff --git a/org.adempiere.base.process/src/org/compiere/process/ImportPayment.java b/org.adempiere.base.process/src/org/compiere/process/ImportPayment.java
index eccf0f60fd..632e476d4e 100644
--- a/org.adempiere.base.process/src/org/compiere/process/ImportPayment.java
+++ b/org.adempiere.base.process/src/org/compiere/process/ImportPayment.java
@@ -102,7 +102,7 @@ public class ImportPayment extends SvrProcess
sql = new StringBuilder ("DELETE I_Payment ")
.append("WHERE I_IsImported='Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Delete Old Impored =" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Delete Old Impored =" + no);
}
// Set Client, Org, IsActive, Created/Updated
@@ -272,7 +272,7 @@ public class ImportPayment extends SvrProcess
.append(" AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
if (no != 0)
- log.fine("Set Invoice from DocumentNo=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Invoice from DocumentNo=" + no);
// BPartner
sql = new StringBuilder ("UPDATE I_Payment i ")
@@ -282,7 +282,7 @@ public class ImportPayment extends SvrProcess
.append(" AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
if (no != 0)
- log.fine("Set BP from Value=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set BP from Value=" + no);
sql = new StringBuilder ("UPDATE I_Payment i ")
.append("SET C_BPartner_ID=(SELECT MAX(C_BPartner_ID) FROM C_Invoice ii")
@@ -291,7 +291,7 @@ public class ImportPayment extends SvrProcess
.append(" AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
if (no != 0)
- log.fine("Set BP from Invoice=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set BP from Invoice=" + no);
sql = new StringBuilder ("UPDATE I_Payment ")
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=No BPartner,' ")
@@ -388,7 +388,7 @@ public class ImportPayment extends SvrProcess
.append("WHERE C_DocType_ID IS NULL AND DocTypeName IS NOT NULL AND I_IsImported<>'Y'").append (clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
if (no != 0)
- log.fine("Set DocType=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set DocType=" + no);
sql = new StringBuilder ("UPDATE I_Payment ")
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=Invalid DocTypeName, ' ")
.append("WHERE C_DocType_ID IS NULL AND DocTypeName IS NOT NULL")
diff --git a/org.adempiere.base.process/src/org/compiere/process/ImportProduct.java b/org.adempiere.base.process/src/org/compiere/process/ImportProduct.java
index 3a059f09cd..536bb7fed3 100644
--- a/org.adempiere.base.process/src/org/compiere/process/ImportProduct.java
+++ b/org.adempiere.base.process/src/org/compiere/process/ImportProduct.java
@@ -188,7 +188,7 @@ public class ImportProduct extends SvrProcess implements ImportProcess
.append(" AND M_Product_ID IS NULL") // set category only if product not found
.append(" AND I_IsImported<>'Y'").append(clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set Category Default Value=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Category Default Value=" + no);
//
sql = new StringBuilder ("UPDATE I_Product i ")
.append("SET M_Product_Category_ID=(SELECT M_Product_Category_ID FROM M_Product_Category c")
@@ -210,7 +210,7 @@ public class ImportProduct extends SvrProcess implements ImportProcess
.append(" AND I_IsImported='N'").append(clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
if (no != 0)
- log.fine(strFieldsToCopy[i] + " - default from existing Product=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine(strFieldsToCopy[i] + " - default from existing Product=" + no);
}
String[] numFields = new String[] {"C_UOM_ID","M_Product_Category_ID",
"Volume","Weight","ShelfWidth","ShelfHeight","ShelfDepth","UnitsPerPallet"};
@@ -224,7 +224,7 @@ public class ImportProduct extends SvrProcess implements ImportProcess
.append(" AND I_IsImported='N'").append(clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
if (no != 0)
- log.fine(numFields[i] + " default from existing Product=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine(numFields[i] + " default from existing Product=" + no);
}
// Copy From Product_PO if Import does not have value
@@ -242,7 +242,7 @@ public class ImportProduct extends SvrProcess implements ImportProcess
.append(" AND I_IsImported='N'").append(clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
if (no != 0)
- log.fine(strFieldsPO[i] + " default from existing Product PO=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine(strFieldsPO[i] + " default from existing Product PO=" + no);
}
String[] numFieldsPO = new String[] {"C_UOM_ID","C_Currency_ID",
"PriceList","PricePO","RoyaltyAmt",
@@ -258,7 +258,7 @@ public class ImportProduct extends SvrProcess implements ImportProcess
.append(" AND I_IsImported='N'").append(clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
if (no != 0)
- log.fine(numFieldsPO[i] + " default from existing Product PO=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine(numFieldsPO[i] + " default from existing Product PO=" + no);
}
// Invalid Category
@@ -278,7 +278,7 @@ public class ImportProduct extends SvrProcess implements ImportProcess
.append("WHERE X12DE355 IS NULL AND C_UOM_ID IS NULL")
.append(" AND I_IsImported<>'Y'").append(clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set UOM Default=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set UOM Default=" + no);
//
sql = new StringBuilder ("UPDATE I_Product i ")
.append("SET C_UOM_ID = (SELECT C_UOM_ID FROM C_UOM u WHERE u.X12DE355=i.X12DE355 AND u.AD_Client_ID IN (0,i.AD_Client_ID)) ")
@@ -305,7 +305,7 @@ public class ImportProduct extends SvrProcess implements ImportProcess
.append("WHERE C_Currency_ID IS NULL AND ISO_Code IS NULL")
.append(" AND I_IsImported<>'Y'").append(clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set Currency Default=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Currency Default=" + no);
//
sql = new StringBuilder ("UPDATE I_Product i ")
.append("SET C_Currency_ID=(SELECT C_Currency_ID FROM C_Currency c")
@@ -405,7 +405,7 @@ public class ImportProduct extends SvrProcess implements ImportProcess
rs = null;
pstmt = null;
}
- log.fine("C_TaxCategory_ID=" + C_TaxCategory_ID);
+ if (log.isLoggable(Level.FINE)) log.fine("C_TaxCategory_ID=" + C_TaxCategory_ID);
ModelValidationEngine.get().fireImportValidate(this, null, null, ImportValidator.TIMING_AFTER_VALIDATE);
@@ -509,7 +509,7 @@ public class ImportProduct extends SvrProcess implements ImportProcess
int M_Product_ID = imp.getM_Product_ID();
int C_BPartner_ID = imp.getC_BPartner_ID();
boolean newProduct = M_Product_ID == 0;
- log.fine("I_Product_ID=" + I_Product_ID + ", M_Product_ID=" + M_Product_ID
+ if (log.isLoggable(Level.FINE)) log.fine("I_Product_ID=" + I_Product_ID + ", M_Product_ID=" + M_Product_ID
+ ", C_BPartner_ID=" + C_BPartner_ID);
// Product
diff --git a/org.adempiere.base.process/src/org/compiere/process/ImportReportLine.java b/org.adempiere.base.process/src/org/compiere/process/ImportReportLine.java
index 0bed108d9b..f5a5f2f823 100644
--- a/org.adempiere.base.process/src/org/compiere/process/ImportReportLine.java
+++ b/org.adempiere.base.process/src/org/compiere/process/ImportReportLine.java
@@ -88,7 +88,7 @@ public class ImportReportLine extends SvrProcess
sql = new StringBuilder ("DELETE I_ReportLine ")
.append("WHERE I_IsImported='Y'").append(clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Delete Old Impored =" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Delete Old Impored =" + no);
}
// Set Client, Org, IsActive, Created/Updated
@@ -104,7 +104,7 @@ public class ImportReportLine extends SvrProcess
.append(" I_IsImported = 'N' ")
.append("WHERE I_IsImported<>'Y' OR I_IsImported IS NULL");
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Reset=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Reset=" + no);
// ReportLineSetName (Default)
if (m_PA_ReportLineSet_ID != 0)
@@ -115,7 +115,7 @@ public class ImportReportLine extends SvrProcess
.append("WHERE ReportLineSetName IS NULL AND PA_ReportLineSet_ID IS NULL")
.append(" AND I_IsImported<>'Y'").append(clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set ReportLineSetName Default=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set ReportLineSetName Default=" + no);
}
// Set PA_ReportLineSet_ID
sql = new StringBuilder ("UPDATE I_ReportLine i ")
@@ -124,7 +124,7 @@ public class ImportReportLine extends SvrProcess
.append("WHERE PA_ReportLineSet_ID IS NULL")
.append(" AND I_IsImported<>'Y'").append(clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set PA_ReportLineSet_ID=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set PA_ReportLineSet_ID=" + no);
//
sql = new StringBuilder ("UPDATE I_ReportLine ")
.append("SET I_IsImported='E', I_ErrorMsg=I_ErrorMsg||'ERR=Invalid ReportLineSet, ' ")
@@ -148,7 +148,7 @@ public class ImportReportLine extends SvrProcess
.append("WHERE C_ElementValue_ID IS NULL AND ElementValue IS NOT NULL")
.append(" AND I_IsImported<>'Y'").append(clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set C_ElementValue_ID=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set C_ElementValue_ID=" + no);
// Validate C_ElementValue_ID
sql = new StringBuilder ("UPDATE I_ReportLine ")
@@ -164,7 +164,7 @@ public class ImportReportLine extends SvrProcess
.append("WHERE SeqNo IS NULL")
.append(" AND I_IsImported='N'").append(clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set SeqNo Default=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set SeqNo Default=" + no);
// Copy/Sync from first Row of Line
sql = new StringBuilder ("UPDATE I_ReportLine i ")
@@ -179,7 +179,7 @@ public class ImportReportLine extends SvrProcess
.append(" WHERE i.Name=iii.Name AND i.PA_ReportLineSet_ID=iii.PA_ReportLineSet_ID))")
.append(" AND I_IsImported='N'").append(clientCheck); // not if previous error
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Sync from first Row of Line=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Sync from first Row of Line=" + no);
// Validate IsSummary - (N) Y
sql = new StringBuilder ("UPDATE I_ReportLine ")
@@ -187,7 +187,7 @@ public class ImportReportLine extends SvrProcess
.append("WHERE IsSummary IS NULL OR IsSummary NOT IN ('Y','N')")
.append(" AND I_IsImported<>'Y'").append(clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set IsSummary Default=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set IsSummary Default=" + no);
// Validate IsPrinted - (Y) N
sql = new StringBuilder ("UPDATE I_ReportLine ")
@@ -195,7 +195,7 @@ public class ImportReportLine extends SvrProcess
.append("WHERE IsPrinted IS NULL OR IsPrinted NOT IN ('Y','N')")
.append(" AND I_IsImported<>'Y'").append(clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set IsPrinted Default=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set IsPrinted Default=" + no);
// Validate Line Type - (S) C
sql = new StringBuilder ("UPDATE I_ReportLine ")
@@ -203,7 +203,7 @@ public class ImportReportLine extends SvrProcess
.append("WHERE LineType IS NULL OR LineType NOT IN ('S','C')")
.append(" AND I_IsImported<>'Y'").append(clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set LineType Default=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set LineType Default=" + no);
// Validate Optional Calculation Type - A P R S
sql = new StringBuilder ("UPDATE I_ReportLine ")
@@ -252,7 +252,7 @@ public class ImportReportLine extends SvrProcess
.append("WHERE PA_ReportLine_ID IS NULL AND PA_ReportLineSet_ID IS NOT NULL")
.append(" AND I_IsImported='N'").append(clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set PA_ReportLine_ID=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set PA_ReportLine_ID=" + no);
commitEx();
@@ -334,7 +334,7 @@ public class ImportReportLine extends SvrProcess
.append("WHERE PA_ReportLine_ID IS NULL AND PA_ReportLineSet_ID IS NOT NULL")
.append(" AND I_IsImported='N'").append(clientCheck);
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Set PA_ReportLine_ID=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set PA_ReportLine_ID=" + no);
// **** Update ReportLine
sql = new StringBuilder ("UPDATE PA_ReportLine r ")
diff --git a/org.adempiere.base.process/src/org/compiere/process/InOutGenerate.java b/org.adempiere.base.process/src/org/compiere/process/InOutGenerate.java
index 6d9aefc6fc..16ccebf1c6 100644
--- a/org.adempiere.base.process/src/org/compiere/process/InOutGenerate.java
+++ b/org.adempiere.base.process/src/org/compiere/process/InOutGenerate.java
@@ -224,7 +224,7 @@ public class InOutGenerate extends SvrProcess
&& (m_shipment.getC_BPartner_Location_ID() != order.getC_BPartner_Location_ID()
|| m_shipment.getM_Shipper_ID() != order.getM_Shipper_ID() )))
completeShipment();
- log.fine("check: " + order + " - DeliveryRule=" + order.getDeliveryRule());
+ if (log.isLoggable(Level.FINE)) log.fine("check: " + order + " - DeliveryRule=" + order.getDeliveryRule());
//
Timestamp minGuaranteeDate = m_movementDate;
boolean completeOrder = MOrder.DELIVERYRULE_CompleteOrder.equals(order.getDeliveryRule());
@@ -251,7 +251,7 @@ public class InOutGenerate extends SvrProcess
MOrderLine line = lines[i];
if (line.getM_Warehouse_ID() != p_M_Warehouse_ID)
continue;
- log.fine("check: " + line);
+ if (log.isLoggable(Level.FINE)) log.fine("check: " + line);
BigDecimal onHand = Env.ZERO;
BigDecimal toDeliver = line.getQtyOrdered()
.subtract(line.getQtyDelivered());
@@ -284,7 +284,7 @@ public class InOutGenerate extends SvrProcess
}
// Adjust On Hand
onHand = onHand.subtract(unconfirmedShippedQty);
- log.fine(logInfo.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(logInfo.toString());
}
// Comments & lines w/o product & services
@@ -315,7 +315,7 @@ public class InOutGenerate extends SvrProcess
// Complete Order
if (completeOrder && !fullLine)
{
- log.fine("Failed CompleteOrder - OnHand=" + onHand
+ if (log.isLoggable(Level.FINE)) log.fine("Failed CompleteOrder - OnHand=" + onHand
+ " (Unconfirmed=" + unconfirmedShippedQty
+ "), ToDeliver=" + toDeliver + " - " + line);
completeOrder = false;
@@ -324,7 +324,7 @@ public class InOutGenerate extends SvrProcess
// Complete Line
else if (fullLine && MOrder.DELIVERYRULE_CompleteLine.equals(order.getDeliveryRule()))
{
- log.fine("CompleteLine - OnHand=" + onHand
+ if (log.isLoggable(Level.FINE)) log.fine("CompleteLine - OnHand=" + onHand
+ " (Unconfirmed=" + unconfirmedShippedQty
+ ", ToDeliver=" + toDeliver + " - " + line);
//
@@ -338,7 +338,7 @@ public class InOutGenerate extends SvrProcess
BigDecimal deliver = toDeliver;
if (deliver.compareTo(onHand) > 0)
deliver = onHand;
- log.fine("Available - OnHand=" + onHand
+ if (log.isLoggable(Level.FINE)) log.fine("Available - OnHand=" + onHand
+ " (Unconfirmed=" + unconfirmedShippedQty
+ "), ToDeliver=" + toDeliver
+ ", Delivering=" + deliver + " - " + line);
@@ -349,7 +349,7 @@ public class InOutGenerate extends SvrProcess
else if (MOrder.DELIVERYRULE_Force.equals(order.getDeliveryRule()))
{
BigDecimal deliver = toDeliver;
- log.fine("Force - OnHand=" + onHand
+ if (log.isLoggable(Level.FINE)) log.fine("Force - OnHand=" + onHand
+ " (Unconfirmed=" + unconfirmedShippedQty
+ "), ToDeliver=" + toDeliver
+ ", Delivering=" + deliver + " - " + line);
@@ -358,11 +358,11 @@ public class InOutGenerate extends SvrProcess
}
// Manual
else if (MOrder.DELIVERYRULE_Manual.equals(order.getDeliveryRule()))
- log.fine("Manual - OnHand=" + onHand
+ if (log.isLoggable(Level.FINE)) log.fine("Manual - OnHand=" + onHand
+ " (Unconfirmed=" + unconfirmedShippedQty
+ ") - " + line);
else
- log.fine("Failed: " + order.getDeliveryRule() + " - OnHand=" + onHand
+ if (log.isLoggable(Level.FINE)) log.fine("Failed: " + order.getDeliveryRule() + " - OnHand=" + onHand
+ " (Unconfirmed=" + unconfirmedShippedQty
+ "), ToDeliver=" + toDeliver + " - " + line);
} // for all order lines
@@ -450,7 +450,7 @@ public class InOutGenerate extends SvrProcess
line.setLine(m_line + orderLine.getLine());
if (!line.save())
throw new IllegalStateException("Could not create Shipment Line");
- log.fine(line.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(line.toString());
return;
}
@@ -506,7 +506,7 @@ public class InOutGenerate extends SvrProcess
line.setLine(m_line + orderLine.getLine());
if (!line.save())
throw new IllegalStateException("Could not create Shipment Line");
- log.fine("ToDeliver=" + qty + "/" + deliver + " - " + line);
+ if (log.isLoggable(Level.FINE)) log.fine("ToDeliver=" + qty + "/" + deliver + " - " + line);
toDeliver = toDeliver.subtract(deliver);
// Temp adjustment, actual update happen in MInOut.completeIt
storage.setQtyOnHand(storage.getQtyOnHand().subtract(deliver));
diff --git a/org.adempiere.base.process/src/org/compiere/process/InventoryCountCreate.java b/org.adempiere.base.process/src/org/compiere/process/InventoryCountCreate.java
index 9cf5ae112f..7a98322ec2 100644
--- a/org.adempiere.base.process/src/org/compiere/process/InventoryCountCreate.java
+++ b/org.adempiere.base.process/src/org/compiere/process/InventoryCountCreate.java
@@ -123,13 +123,13 @@ public class InventoryCountCreate extends SvrProcess
.append("(SELECT * FROM M_InventoryLine l WHERE l.M_InventoryLine_ID=ma.M_InventoryLine_ID")
.append(" AND Processed='N' AND M_Inventory_ID=").append(p_M_Inventory_ID).append(")");
int no1 = DB.executeUpdate(sql1.toString(), get_TrxName());
- log.fine("doIt - Deleted MA #" + no1);
+ if (log.isLoggable(Level.FINE)) log.fine("doIt - Deleted MA #" + no1);
//End of Added Line
StringBuilder sql = new StringBuilder("DELETE M_InventoryLine WHERE Processed='N' ")
.append("AND M_Inventory_ID=").append(p_M_Inventory_ID);
int no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("doIt - Deleted #" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("doIt - Deleted #" + no);
}
// Create Null Storage records
@@ -156,7 +156,7 @@ public class InventoryCountCreate extends SvrProcess
.append("WHERE sl.M_Warehouse_ID=l.M_Warehouse_ID")
.append(" AND s.M_Product_ID=p.M_Product_ID)");
int no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("'0' Inserted #" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("'0' Inserted #" + no);
}
StringBuilder sql = new StringBuilder("SELECT s.M_Product_ID, s.M_Locator_ID, s.M_AttributeSetInstance_ID,");
@@ -394,7 +394,7 @@ public class InventoryCountCreate extends SvrProcess
ret.append(",");
}
}
- log.fine(ret.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(ret.toString());
StringBuilder msgreturn = new StringBuilder(ret).append(productCategoryId);
return msgreturn.toString();
}
diff --git a/org.adempiere.base.process/src/org/compiere/process/InventoryValue.java b/org.adempiere.base.process/src/org/compiere/process/InventoryValue.java
index fddca19018..fc041f8661 100644
--- a/org.adempiere.base.process/src/org/compiere/process/InventoryValue.java
+++ b/org.adempiere.base.process/src/org/compiere/process/InventoryValue.java
@@ -17,6 +17,7 @@
package org.compiere.process;
import java.sql.Timestamp;
+import java.util.logging.Level;
import org.compiere.model.MAcctSchema;
import org.compiere.model.MClient;
@@ -112,7 +113,7 @@ public class InventoryValue extends SvrProcess
.append(" INNER JOIN M_CostElement ce ON (c.M_CostElement_ID=ce.M_CostElement_ID AND ce.CostingMethod='S' AND ce.CostElementType='M') ")
.append("WHERE w.M_Warehouse_ID=").append(p_M_Warehouse_ID);
int noInsertStd = DB.executeUpdateEx(sql.toString(), get_TrxName());
- log.fine("Inserted Std=" + noInsertStd);
+ if (log.isLoggable(Level.FINE)) log.fine("Inserted Std=" + noInsertStd);
if (noInsertStd == 0)
return "No Standard Costs found";
@@ -138,7 +139,7 @@ public class InventoryValue extends SvrProcess
.append(" AND iv.M_Product_ID=c.M_Product_ID")
.append(" AND iv.M_AttributeSetInstance_ID=c.M_AttributeSetInstance_ID)");
noInsertCost = DB.executeUpdateEx(sql.toString(), get_TrxName());
- log.fine("Inserted Cost=" + noInsertCost);
+ if (log.isLoggable(Level.FINE)) log.fine("Inserted Cost=" + noInsertCost);
// Update Std Cost Records
sql = new StringBuilder ("UPDATE T_InventoryValue iv ")
.append("SET (Cost, M_CostElement_ID)=")
@@ -156,7 +157,7 @@ public class InventoryValue extends SvrProcess
.append("WHERE ivv.AD_PInstance_ID=").append(getAD_PInstance_ID())
.append(" AND ivv.M_CostElement_ID IS NULL)");
int noUpdatedCost = DB.executeUpdateEx(sql.toString(), get_TrxName());
- log.fine("Updated Cost=" + noUpdatedCost);
+ if (log.isLoggable(Level.FINE)) log.fine("Updated Cost=" + noUpdatedCost);
}
if ((noInsertStd+noInsertCost) == 0)
return "No Costs found";
@@ -171,7 +172,7 @@ public class InventoryValue extends SvrProcess
.append("C_Currency_ID=").append(p_C_Currency_ID)
.append(" WHERE AD_PInstance_ID=").append(getAD_PInstance_ID());
no = DB.executeUpdateEx(sql.toString(), get_TrxName());
- log.fine("Constants=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Constants=" + no);
// Get current QtyOnHand with ASI
sql = new StringBuilder ("UPDATE T_InventoryValue iv SET QtyOnHand = ")
@@ -183,7 +184,7 @@ public class InventoryValue extends SvrProcess
.append("WHERE AD_PInstance_ID=").append(getAD_PInstance_ID())
.append(" AND iv.M_AttributeSetInstance_ID<>0");
no = DB.executeUpdateEx(sql.toString(), get_TrxName());
- log.fine("QtHand with ASI=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("QtHand with ASI=" + no);
// Get current QtyOnHand without ASI
sql = new StringBuilder ("UPDATE T_InventoryValue iv SET QtyOnHand = ")
.append("(SELECT SUM(QtyOnHand) FROM M_StorageOnHand s")
@@ -193,7 +194,7 @@ public class InventoryValue extends SvrProcess
.append("WHERE iv.AD_PInstance_ID=").append(getAD_PInstance_ID())
.append(" AND iv.M_AttributeSetInstance_ID=0");
no = DB.executeUpdateEx(sql.toString(), get_TrxName());
- log.fine("QtHand w/o ASI=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("QtHand w/o ASI=" + no);
// Adjust for Valuation Date
sql = new StringBuilder("UPDATE T_InventoryValue iv ")
@@ -208,7 +209,7 @@ public class InventoryValue extends SvrProcess
.append("WHERE iv.M_AttributeSetInstance_ID<>0" )
.append(" AND iv.AD_PInstance_ID=").append(getAD_PInstance_ID());
no = DB.executeUpdateEx(sql.toString(), get_TrxName());
- log.fine("Update with ASI=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Update with ASI=" + no);
//
sql = new StringBuilder("UPDATE T_InventoryValue iv ")
.append("SET QtyOnHand=")
@@ -222,13 +223,13 @@ public class InventoryValue extends SvrProcess
.append("AND iv.AD_PInstance_ID=").append(getAD_PInstance_ID());
no = DB.executeUpdateEx(sql.toString(), get_TrxName());
- log.fine("Update w/o ASI=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Update w/o ASI=" + no);
// Delete Records w/o OnHand Qty
sql = new StringBuilder("DELETE T_InventoryValue ")
.append("WHERE (QtyOnHand=0 OR QtyOnHand IS NULL) AND AD_PInstance_ID=").append(getAD_PInstance_ID());
int noQty = DB.executeUpdateEx (sql.toString(), get_TrxName());
- log.fine("NoQty Deleted=" + noQty);
+ if (log.isLoggable(Level.FINE)) log.fine("NoQty Deleted=" + noQty);
// Update Prices
sql = new StringBuilder("UPDATE T_InventoryValue iv ")
@@ -273,7 +274,7 @@ public class InventoryValue extends SvrProcess
.append("FROM C_AcctSchema acs WHERE acs.C_AcctSchema_ID=").append(as.getC_AcctSchema_ID()).append(") ")
.append("WHERE iv.AD_PInstance_ID=").append(getAD_PInstance_ID());
no = DB.executeUpdateEx (sql.toString(), get_TrxName());
- log.fine("Converted=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Converted=" + no);
}
// Update Values
@@ -287,7 +288,7 @@ public class InventoryValue extends SvrProcess
.append("WHERE AD_PInstance_ID=").append(getAD_PInstance_ID()
);
no = DB.executeUpdateEx(dbeux.toString(), get_TrxName());
- log.fine("Calculation=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Calculation=" + no);
//
return msg;
} // doIt
diff --git a/org.adempiere.base.process/src/org/compiere/process/InvoiceGenerate.java b/org.adempiere.base.process/src/org/compiere/process/InvoiceGenerate.java
index b92bff7e1c..5fae9440e1 100644
--- a/org.adempiere.base.process/src/org/compiere/process/InvoiceGenerate.java
+++ b/org.adempiere.base.process/src/org/compiere/process/InvoiceGenerate.java
@@ -269,7 +269,7 @@ public class InvoiceGenerate extends SvrProcess
// Complete Order
if (completeOrder && !fullyDelivered)
{
- log.fine("Failed CompleteOrder - " + oLine);
+ if (log.isLoggable(Level.FINE)) log.fine("Failed CompleteOrder - " + oLine);
addLog(0, null, null,"Failed CompleteOrder - " + oLine,oLine.get_Table_ID(),oLine.getC_OrderLine_ID()); // Elaine 2008/11/25
completeOrder = false;
break;
@@ -277,7 +277,7 @@ public class InvoiceGenerate extends SvrProcess
// Immediate
else if (MOrder.INVOICERULE_Immediate.equals(order.getInvoiceRule()))
{
- log.fine("Immediate - ToInvoice=" + toInvoice + " - " + oLine);
+ if (log.isLoggable(Level.FINE)) log.fine("Immediate - ToInvoice=" + toInvoice + " - " + oLine);
BigDecimal qtyEntered = toInvoice;
// Correct UOM for QtyEntered
if (oLine.getQtyEntered().compareTo(oLine.getQtyOrdered()) != 0)
@@ -288,7 +288,7 @@ public class InvoiceGenerate extends SvrProcess
}
else
{
- log.fine("Failed: " + order.getInvoiceRule()
+ if (log.isLoggable(Level.FINE)) log.fine("Failed: " + order.getInvoiceRule()
+ " - ToInvoice=" + toInvoice + " - " + oLine);
addLog(0, null, null,"Failed: " + order.getInvoiceRule()
+ " - ToInvoice=" + toInvoice + " - " + oLine,oLine.get_Table_ID(),oLine.getC_OrderLine_ID());
@@ -363,7 +363,7 @@ public class InvoiceGenerate extends SvrProcess
line.setLine(m_line + orderLine.getLine());
if (!line.save())
throw new IllegalStateException("Could not create Invoice Line (o)");
- log.fine(line.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(line.toString());
} // createLine
/**
@@ -436,7 +436,7 @@ public class InvoiceGenerate extends SvrProcess
if (!sLine.save())
throw new IllegalStateException("Could not update Shipment Line");
- log.fine(line.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(line.toString());
} // createLine
diff --git a/org.adempiere.base.process/src/org/compiere/process/InvoicePrint.java b/org.adempiere.base.process/src/org/compiere/process/InvoicePrint.java
index a65d3f4feb..95daeb5c29 100644
--- a/org.adempiere.base.process/src/org/compiere/process/InvoicePrint.java
+++ b/org.adempiere.base.process/src/org/compiere/process/InvoicePrint.java
@@ -210,7 +210,7 @@ public class InvoicePrint extends SvrProcess
}
}
sql.append(" ORDER BY i.C_Invoice_ID, pf.AD_Org_ID DESC"); // more than 1 PF record
- log.fine(sql.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(sql.toString());
MPrintFormat format = null;
int old_AD_PrintFormat_ID = -1;
@@ -313,7 +313,7 @@ public class InvoicePrint extends SvrProcess
if (!Ini.isClient())
invoice = new File(MInvoice.getPDFFileName(documentDir, C_Invoice_ID));
File attachment = re.getPDF(invoice);
- log.fine(to + " - " + attachment);
+ if (log.isLoggable(Level.FINE)) log.fine(to + " - " + attachment);
email.addAttachment(attachment);
//
String msg = email.send();
diff --git a/org.adempiere.base.process/src/org/compiere/process/M_PriceList_Create.java b/org.adempiere.base.process/src/org/compiere/process/M_PriceList_Create.java
index 324e9181e0..352bbb82da 100644
--- a/org.adempiere.base.process/src/org/compiere/process/M_PriceList_Create.java
+++ b/org.adempiere.base.process/src/org/compiere/process/M_PriceList_Create.java
@@ -108,7 +108,7 @@ public class M_PriceList_Create extends SvrProcess {
"Update The PriceList to zero of M_Product_PO WHERE PriceList IS NULL",
sqlupd.toString());
totu += cntu;
- log.fine("Updated " + cntu);
+ if (log.isLoggable(Level.FINE)) log.fine("Updated " + cntu);
sqlupd = new StringBuilder("UPDATE M_Product_PO SET PriceLastPO = 0 ");
sqlupd.append(" WHERE PriceLastPO IS NULL ");
@@ -119,7 +119,7 @@ public class M_PriceList_Create extends SvrProcess {
"Update The PriceListPO to zero of M_Product_PO WHERE PriceLastPO IS NULL",
sqlupd.toString());
totu += cntu;
- log.fine("Updated " + cntu);
+ if (log.isLoggable(Level.FINE)) log.fine("Updated " + cntu);
sqlupd = new StringBuilder("UPDATE M_Product_PO SET PricePO = PriceLastPO ");
sqlupd.append(" WHERE (PricePO IS NULL OR PricePO = 0) AND PriceLastPO <> 0 ");
@@ -130,7 +130,7 @@ public class M_PriceList_Create extends SvrProcess {
"Update The PricePO to PriceLastPO of M_Product_PO WHERE (PricePO IS NULL OR PricePO = 0) AND PriceLastPO <> 0 ",
sqlupd.toString());
totu += cntu;
- log.fine("Updated " + cntu);
+ if (log.isLoggable(Level.FINE)) log.fine("Updated " + cntu);
sqlupd = new StringBuilder("UPDATE M_Product_PO SET PricePO = 0 ");
sqlupd.append(" WHERE PricePO IS NULL ");
@@ -141,7 +141,7 @@ public class M_PriceList_Create extends SvrProcess {
"Update The PricePO to Zero of M_Product_PO WHERE PricePO IS NULL",
sqlupd.toString());
totu += cntu;
- log.fine("Updated " + cntu);
+ if (log.isLoggable(Level.FINE)) log.fine("Updated " + cntu);
//
// Set default current vendor
//
@@ -155,7 +155,7 @@ public class M_PriceList_Create extends SvrProcess {
if (cntu == -1)
raiseError("Update IsCurrentVendor to Y of M_Product_PO ", sqlupd.toString());
totu += cntu;
- log.fine("Updated " + cntu);
+ if (log.isLoggable(Level.FINE)) log.fine("Updated " + cntu);
// let the commit for SvrProcess
// DB.commit(true, get_TrxName());
@@ -206,7 +206,7 @@ public class M_PriceList_Create extends SvrProcess {
"Update IsCurrentVendor to N of M_Product_PO for a M_Product_ID and C_BPartner_ID ingresed",
sqlupd.toString());
totu += cntu;
- log.fine("Updated " + cntu);
+ if (log.isLoggable(Level.FINE)) log.fine("Updated " + cntu);
}
}
} catch (SQLException e) {
@@ -232,7 +232,7 @@ public class M_PriceList_Create extends SvrProcess {
raiseError(" DELETE M_ProductPrice ", sqldel.toString());
totd += cntd;
message = new StringBuilder("@Deleted@=").append(cntd).append(" - ");
- log.fine("Deleted " + cntd);
+ if (log.isLoggable(Level.FINE)) log.fine("Deleted " + cntd);
}
//
// Get PriceList Info
@@ -284,7 +284,7 @@ public class M_PriceList_Create extends SvrProcess {
if (cntd == -1)
raiseError(" DELETE T_Selection ", sqldel.toString());
totd += cntd;
- log.fine("Deleted " + cntd);
+ if (log.isLoggable(Level.FINE)) log.fine("Deleted " + cntd);
//
//Create Selection in temporary table
//
@@ -332,7 +332,7 @@ public class M_PriceList_Create extends SvrProcess {
if (cnti == -1)
raiseError(" INSERT INTO T_Selection ", sqlins.toString());
toti += cnti;
- log.fine("Inserted " + cnti);
+ if (log.isLoggable(Level.FINE)) log.fine("Inserted " + cnti);
} else {
//
@@ -382,7 +382,7 @@ public class M_PriceList_Create extends SvrProcess {
" INSERT INTO T_Selection from existing PriceList",
sqlins.toString());
toti += cnti;
- log.fine("Inserted " + cnti);
+ if (log.isLoggable(Level.FINE)) log.fine("Inserted " + cnti);
}
@@ -405,7 +405,7 @@ public class M_PriceList_Create extends SvrProcess {
raiseError(" DELETE M_ProductPrice ", sqldel.toString());
totd += cntd;
message.append(", @Deleted@=").append(cntd);
- log.fine("Deleted " + cntd);
+ if (log.isLoggable(Level.FINE)) log.fine("Deleted " + cntd);
}
//
@@ -499,7 +499,7 @@ public class M_PriceList_Create extends SvrProcess {
" INSERT INTO T_Selection from existing PriceList",
sqlins.toString());
toti += cnti;
- log.fine("Inserted " + cnti);
+ if (log.isLoggable(Level.FINE)) log.fine("Inserted " + cnti);
} else {
//
//Copy and Convert from other PriceList_Version
@@ -572,7 +572,7 @@ public class M_PriceList_Create extends SvrProcess {
" INSERT INTO T_Selection from existing PriceList",
sqlins.toString());
toti += cnti;
- log.fine("Inserted " + cnti);
+ if (log.isLoggable(Level.FINE)) log.fine("Inserted " + cnti);
}
message.append(", @Inserted@=").append(cnti);
@@ -612,7 +612,7 @@ public class M_PriceList_Create extends SvrProcess {
if (cntu == -1)
raiseError("Update M_ProductPrice ", sqlupd.toString());
totu += cntu;
- log.fine("Updated " + cntu);
+ if (log.isLoggable(Level.FINE)) log.fine("Updated " + cntu);
//
//Rounding (AD_Reference_ID=155)
@@ -665,7 +665,7 @@ public class M_PriceList_Create extends SvrProcess {
if (cntu == -1)
raiseError("Update M_ProductPrice ", sqlupd.toString());
totu += cntu;
- log.fine("Updated " + cntu);
+ if (log.isLoggable(Level.FINE)) log.fine("Updated " + cntu);
message.append(", @Updated@=").append(cntu);
//
@@ -691,7 +691,7 @@ public class M_PriceList_Create extends SvrProcess {
if (cntu == -1)
raiseError("Update M_ProductPrice ", sqlupd.toString());
totu += cntu;
- log.fine("Updated " + cntu);
+ if (log.isLoggable(Level.FINE)) log.fine("Updated " + cntu);
v_NextNo = v_NextNo + 1;
addLog(0, null, null, message.toString());
@@ -705,7 +705,7 @@ public class M_PriceList_Create extends SvrProcess {
if (cntd == -1)
raiseError(" DELETE T_Selection ", sqldel.toString());
totd += cntd;
- log.fine("Deleted " + cntd);
+ if (log.isLoggable(Level.FINE)) log.fine("Deleted " + cntd);
//
//commit;
@@ -797,7 +797,7 @@ public class M_PriceList_Create extends SvrProcess {
ret.append(",");
}
}
- log.fine(ret.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(ret.toString());
return ret.toString() + productCategoryId;
}
diff --git a/org.adempiere.base.process/src/org/compiere/process/M_Product_BOM_Check.java b/org.adempiere.base.process/src/org/compiere/process/M_Product_BOM_Check.java
index f1c0f0c5e6..657b621df7 100644
--- a/org.adempiere.base.process/src/org/compiere/process/M_Product_BOM_Check.java
+++ b/org.adempiere.base.process/src/org/compiere/process/M_Product_BOM_Check.java
@@ -130,7 +130,7 @@ public class M_Product_BOM_Check extends SvrProcess
rs = null;
pstmt = null;
}
- log.fine("Count T_Selection =" + countno);
+ if (log.isLoggable(Level.FINE)) log.fine("Count T_Selection =" + countno);
if (countno == 0)
break;
diff --git a/org.adempiere.base.process/src/org/compiere/process/OrderPOCreate.java b/org.adempiere.base.process/src/org/compiere/process/OrderPOCreate.java
index a889e2c647..53ac1734e4 100644
--- a/org.adempiere.base.process/src/org/compiere/process/OrderPOCreate.java
+++ b/org.adempiere.base.process/src/org/compiere/process/OrderPOCreate.java
@@ -162,7 +162,7 @@ public class OrderPOCreate extends SvrProcess
rs = null; pstmt = null;
}
if (counter == 0)
- log.fine(sql.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(sql.toString());
StringBuilder msgreturn = new StringBuilder("@Created@ ").append(counter);
return msgreturn.toString();
} // doIt
diff --git a/org.adempiere.base.process/src/org/compiere/process/OrgOwnership.java b/org.adempiere.base.process/src/org/compiere/process/OrgOwnership.java
index 6213572be1..6f97c475d7 100644
--- a/org.adempiere.base.process/src/org/compiere/process/OrgOwnership.java
+++ b/org.adempiere.base.process/src/org/compiere/process/OrgOwnership.java
@@ -180,7 +180,7 @@ public class OrgOwnership extends SvrProcess
else
set.append(" WHERE M_Product_ID=").append(p_M_Product_ID);
set.append(" AND AD_Client_ID=").append(getAD_Client_ID()).append(" AND AD_Org_ID<>").append(p_AD_Org_ID);
- log.fine("productOwnership - " + set);
+ if (log.isLoggable(Level.FINE)) log.fine("productOwnership - " + set);
// Product
StringBuilder sql = new StringBuilder("UPDATE M_Product x ").append(set);
@@ -225,7 +225,7 @@ public class OrgOwnership extends SvrProcess
else
set.append(" WHERE C_BPartner_ID=").append(p_C_BPartner_ID);
set.append(" AND AD_Client_ID=").append(getAD_Client_ID()).append(" AND AD_Org_ID<>").append(p_AD_Org_ID);
- log.fine("bPartnerOwnership - " + set.toString());
+ if (log.isLoggable(Level.FINE)) log.fine("bPartnerOwnership - " + set.toString());
// BPartner
StringBuilder sql = new StringBuilder("UPDATE C_BPartner x ").append(set);
@@ -274,31 +274,31 @@ public class OrgOwnership extends SvrProcess
StringBuilder sql = new StringBuilder("UPDATE R_ContactInterest ").append(set);
int no = DB.executeUpdate(sql.toString(), get_TrxName());
if (no != 0)
- log.fine("generalOwnership - R_ContactInterest=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("generalOwnership - R_ContactInterest=" + no);
// AD_User_Roles
sql = new StringBuilder("UPDATE AD_User_Roles ").append(set);
no = DB.executeUpdate(sql.toString(), get_TrxName());
if (no != 0)
- log.fine("generalOwnership - AD_User_Roles=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("generalOwnership - AD_User_Roles=" + no);
// C_BPartner_Product
sql = new StringBuilder("UPDATE C_BPartner_Product ").append(set);
no = DB.executeUpdate(sql.toString(), get_TrxName());
if (no != 0)
- log.fine("generalOwnership - C_BPartner_Product=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("generalOwnership - C_BPartner_Product=" + no);
// Withholding
sql = new StringBuilder("UPDATE C_BP_Withholding x ").append(set);
no = DB.executeUpdate(sql.toString(), get_TrxName());
if (no != 0)
- log.fine("generalOwnership - C_BP_Withholding=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("generalOwnership - C_BP_Withholding=" + no);
// Replenish
sql = new StringBuilder("UPDATE M_Replenish ").append(set);
no = DB.executeUpdate(sql.toString(), get_TrxName());
if (no != 0)
- log.fine("generalOwnership - M_Replenish=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("generalOwnership - M_Replenish=" + no);
} // generalOwnership
diff --git a/org.adempiere.base.process/src/org/compiere/process/RegisterSystem.java b/org.adempiere.base.process/src/org/compiere/process/RegisterSystem.java
index cdbc94f307..b783036e42 100644
--- a/org.adempiere.base.process/src/org/compiere/process/RegisterSystem.java
+++ b/org.adempiere.base.process/src/org/compiere/process/RegisterSystem.java
@@ -127,7 +127,7 @@ public class RegisterSystem extends SvrProcess
.append("&NumInvoice=").append(URLEncoder.encode(String.valueOf(
DB.getSQLValue(null, "SELECT Count(*) FROM C_Invoice")), enc));
}
- log.fine(urlString.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(urlString.toString());
// Send it
URL url = new URL (urlString.toString());
diff --git a/org.adempiere.base.process/src/org/compiere/process/ReplenishReport.java b/org.adempiere.base.process/src/org/compiere/process/ReplenishReport.java
index 6a784a1598..0f603f623c 100644
--- a/org.adempiere.base.process/src/org/compiere/process/ReplenishReport.java
+++ b/org.adempiere.base.process/src/org/compiere/process/ReplenishReport.java
@@ -144,7 +144,7 @@ public class ReplenishReport extends SvrProcess
.append("WHERE Level_Max < Level_Min");
int no = DB.executeUpdate(sql.toString(), get_TrxName());
if (no != 0)
- log.fine("Corrected Max_Level=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Corrected Max_Level=" + no);
// Minimum Order should be 1
sql = new StringBuilder("UPDATE M_Product_PO")
@@ -152,7 +152,7 @@ public class ReplenishReport extends SvrProcess
.append("WHERE Order_Min IS NULL OR Order_Min < 1");
no = DB.executeUpdate(sql.toString(), get_TrxName());
if (no != 0)
- log.fine("Corrected Order Min=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Corrected Order Min=" + no);
// Pack should be 1
sql = new StringBuilder("UPDATE M_Product_PO")
@@ -160,7 +160,7 @@ public class ReplenishReport extends SvrProcess
.append("WHERE Order_Pack IS NULL OR Order_Pack < 1");
no = DB.executeUpdate(sql.toString(), get_TrxName());
if (no != 0)
- log.fine("Corrected Order Pack=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Corrected Order Pack=" + no);
// Set Current Vendor where only one vendor
@@ -173,7 +173,7 @@ public class ReplenishReport extends SvrProcess
.append("HAVING COUNT(*) = 1)");
no = DB.executeUpdate(sql.toString(), get_TrxName());
if (no != 0)
- log.fine("Corrected CurrentVendor(Y)=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Corrected CurrentVendor(Y)=" + no);
// More then one current vendor
sql = new StringBuilder("UPDATE M_Product_PO p")
@@ -185,13 +185,13 @@ public class ReplenishReport extends SvrProcess
.append("HAVING COUNT(*) > 1)");
no = DB.executeUpdate(sql.toString(), get_TrxName());
if (no != 0)
- log.fine("Corrected CurrentVendor(N)=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Corrected CurrentVendor(N)=" + no);
// Just to be sure
sql = new StringBuilder("DELETE T_Replenish WHERE AD_PInstance_ID=").append(getAD_PInstance_ID());
no = DB.executeUpdate(sql.toString(), get_TrxName());
if (no != 0)
- log.fine("Delete Existing Temp=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Delete Existing Temp=" + no);
} // prepareTable
/**
@@ -223,7 +223,7 @@ public class ReplenishReport extends SvrProcess
sql.append(" AND po.C_BPartner_ID=").append(p_C_BPartner_ID);
int no = DB.executeUpdate(sql.toString(), get_TrxName());
if (log.isLoggable(Level.FINEST)) log.finest(sql.toString());
- log.fine("Insert (1) #" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Insert (1) #" + no);
if (p_C_BPartner_ID == 0)
{
@@ -246,7 +246,7 @@ public class ReplenishReport extends SvrProcess
sql.append("WHERE r.M_Product_ID=t.M_Product_ID");
sql.append(" AND AD_PInstance_ID=").append(getAD_PInstance_ID()).append(")");
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Insert (BP) #" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Insert (BP) #" + no);
}
sql = new StringBuilder("UPDATE T_Replenish t SET ");
sql.append("QtyOnHand = (SELECT COALESCE(SUM(QtyOnHand),0) FROM M_StorageOnHand s, M_Locator l WHERE t.M_Product_ID=s.M_Product_ID");
@@ -260,7 +260,7 @@ public class ReplenishReport extends SvrProcess
sql.append(" WHERE AD_PInstance_ID=").append(getAD_PInstance_ID());
no = DB.executeUpdate(sql.toString(), get_TrxName());
if (no != 0)
- log.fine("Update #" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Update #" + no);
// Delete inactive products and replenishments
sql = new StringBuilder("DELETE T_Replenish r ");
@@ -272,7 +272,7 @@ public class ReplenishReport extends SvrProcess
sql.append(" AND AD_PInstance_ID=").append(getAD_PInstance_ID());
no = DB.executeUpdate(sql.toString(), get_TrxName());
if (no != 0)
- log.fine("Delete Inactive=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Delete Inactive=" + no);
// Ensure Data consistency
sql = new StringBuilder("UPDATE T_Replenish SET QtyOnHand = 0 WHERE QtyOnHand IS NULL");
@@ -292,7 +292,7 @@ public class ReplenishReport extends SvrProcess
sql.append(" AND AD_PInstance_ID=").append(getAD_PInstance_ID());
no = DB.executeUpdate(sql.toString(), get_TrxName());
if (no != 0)
- log.fine("Update Type-1=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Update Type-1=" + no);
//
// X_M_Replenish.REPLENISHTYPE_MaintainMaximumLevel
sql = new StringBuilder("UPDATE T_Replenish");
@@ -301,7 +301,7 @@ public class ReplenishReport extends SvrProcess
sql.append(" AND AD_PInstance_ID=").append(getAD_PInstance_ID());
no = DB.executeUpdate(sql.toString(), get_TrxName());
if (no != 0)
- log.fine("Update Type-2=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Update Type-2=" + no);
// Minimum Order Quantity
@@ -312,7 +312,7 @@ public class ReplenishReport extends SvrProcess
sql.append(" AND AD_PInstance_ID=").append(getAD_PInstance_ID());
no = DB.executeUpdate(sql.toString(), get_TrxName());
if (no != 0)
- log.fine("Set MinOrderQty=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set MinOrderQty=" + no);
// Even dividable by Pack
sql = new StringBuilder("UPDATE T_Replenish");
@@ -322,7 +322,7 @@ public class ReplenishReport extends SvrProcess
sql.append(" AND AD_PInstance_ID=").append(getAD_PInstance_ID());
no = DB.executeUpdate(sql.toString(), get_TrxName());
if (no != 0)
- log.fine("Set OrderPackQty=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set OrderPackQty=" + no);
// Source from other warehouse
if (wh.getM_WarehouseSource_ID() != 0)
@@ -332,7 +332,7 @@ public class ReplenishReport extends SvrProcess
sql.append(" WHERE AD_PInstance_ID=").append(getAD_PInstance_ID());
no = DB.executeUpdate(sql.toString(), get_TrxName());
if (no != 0)
- log.fine("Set Source Warehouse=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Source Warehouse=" + no);
}
// Check Source Warehouse
sql = new StringBuilder("UPDATE T_Replenish");
@@ -341,7 +341,7 @@ public class ReplenishReport extends SvrProcess
sql.append(" AND AD_PInstance_ID=").append(getAD_PInstance_ID());
no = DB.executeUpdate(sql.toString(), get_TrxName());
if (no != 0)
- log.fine("Set same Source Warehouse=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set same Source Warehouse=" + no);
// Custom Replenishment
String className = wh.getReplenishmentClass();
@@ -388,7 +388,7 @@ public class ReplenishReport extends SvrProcess
sql.append(" AND AD_PInstance_ID=").append(getAD_PInstance_ID());
no = DB.executeUpdate(sql.toString(), get_TrxName());
if (no != 0)
- log.fine("Delete No QtyToOrder=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Delete No QtyToOrder=" + no);
} // fillTable
/**
@@ -424,7 +424,7 @@ public class ReplenishReport extends SvrProcess
order.setM_Warehouse_ID(wh.getM_Warehouse_ID());
if (!order.save())
return;
- log.fine(order.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(order.toString());
noOrders++;
info.append(" - ");
info.append(order.getDocumentNo());
@@ -468,7 +468,7 @@ public class ReplenishReport extends SvrProcess
requisition.setM_Warehouse_ID(wh.getM_Warehouse_ID());
if (!requisition.save())
return;
- log.fine(requisition.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(requisition.toString());
noReqs++;
info.append(" - ");
info.append(requisition.getDocumentNo());
@@ -525,7 +525,7 @@ public class ReplenishReport extends SvrProcess
move.setAD_Org_ID(whSource.getAD_Org_ID());
if (!move.save())
return;
- log.fine(move.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(move.toString());
noMoves++;
info.append(" - ").append(move.getDocumentNo());
}
@@ -648,7 +648,7 @@ public class ReplenishReport extends SvrProcess
if (!order.save())
return;
- log.fine(order.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(order.toString());
noMoves++;
info.append(" - ").append(order.getDocumentNo());
}
diff --git a/org.adempiere.base.process/src/org/compiere/process/ReplenishReportProduction.java b/org.adempiere.base.process/src/org/compiere/process/ReplenishReportProduction.java
index 3271c8a6b5..97efed83a4 100644
--- a/org.adempiere.base.process/src/org/compiere/process/ReplenishReportProduction.java
+++ b/org.adempiere.base.process/src/org/compiere/process/ReplenishReportProduction.java
@@ -155,7 +155,7 @@ public class ReplenishReportProduction extends SvrProcess
.append("WHERE Level_Max < Level_Min");
int no = DB.executeUpdate(sql.toString(), get_TrxName());
if (no != 0)
- log.fine("Corrected Max_Level=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Corrected Max_Level=" + no);
// Minimum Order should be 1
sql = new StringBuilder("UPDATE M_Product_PO")
@@ -163,7 +163,7 @@ public class ReplenishReportProduction extends SvrProcess
.append("WHERE Order_Min IS NULL OR Order_Min < 1");
no = DB.executeUpdate(sql.toString(), get_TrxName());
if (no != 0)
- log.fine("Corrected Order Min=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Corrected Order Min=" + no);
// Pack should be 1
sql = new StringBuilder("UPDATE M_Product_PO")
@@ -171,7 +171,7 @@ public class ReplenishReportProduction extends SvrProcess
.append("WHERE Order_Pack IS NULL OR Order_Pack < 1");
no = DB.executeUpdate(sql.toString(), get_TrxName());
if (no != 0)
- log.fine("Corrected Order Pack=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Corrected Order Pack=" + no);
// Set Current Vendor where only one vendor
sql = new StringBuilder("UPDATE M_Product_PO p")
@@ -183,7 +183,7 @@ public class ReplenishReportProduction extends SvrProcess
.append("HAVING COUNT(*) = 1)");
no = DB.executeUpdate(sql.toString(), get_TrxName());
if (no != 0)
- log.fine("Corrected CurrentVendor(Y)=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Corrected CurrentVendor(Y)=" + no);
// More then one current vendor
sql = new StringBuilder("UPDATE M_Product_PO p")
@@ -195,13 +195,13 @@ public class ReplenishReportProduction extends SvrProcess
.append("HAVING COUNT(*) > 1)");
no = DB.executeUpdate(sql.toString(), get_TrxName());
if (no != 0)
- log.fine("Corrected CurrentVendor(N)=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Corrected CurrentVendor(N)=" + no);
// Just to be sure
sql = new StringBuilder("DELETE T_Replenish WHERE AD_PInstance_ID=").append(getAD_PInstance_ID());
no = DB.executeUpdate(sql.toString(), get_TrxName());
if (no != 0)
- log.fine("Delete Existing Temp=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Delete Existing Temp=" + no);
} // prepareTable
/**
@@ -237,7 +237,7 @@ public class ReplenishReportProduction extends SvrProcess
sql.append(" AND p.IsKanban = '").append(isKanban).append("' ");
int no = DB.executeUpdate(sql.toString(), get_TrxName());
if (log.isLoggable(Level.FINEST)) log.finest(sql.toString());
- log.fine("Insert (1) #" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Insert (1) #" + no);
if (p_C_BPartner_ID == 0)
{
@@ -265,7 +265,7 @@ public class ReplenishReportProduction extends SvrProcess
if ( isKanban != null )
sql.append(" AND p.IsKanban = '").append(isKanban).append("' ");
no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Insert (BP) #" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Insert (BP) #" + no);
}
sql = new StringBuilder("UPDATE T_Replenish t SET ");
@@ -280,7 +280,7 @@ public class ReplenishReportProduction extends SvrProcess
sql.append(" WHERE AD_PInstance_ID=").append(getAD_PInstance_ID());
no = DB.executeUpdate(sql.toString(), get_TrxName());
if (no != 0)
- log.fine("Update #" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Update #" + no);
// add production lines
sql = new StringBuilder("UPDATE T_Replenish t SET ");
@@ -293,7 +293,7 @@ public class ReplenishReportProduction extends SvrProcess
sql.append(" WHERE AD_PInstance_ID=").append(getAD_PInstance_ID());
no = DB.executeUpdate(sql.toString(), get_TrxName());
if (no != 0)
- log.fine("Update #" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Update #" + no);
// Delete inactive products and replenishments
@@ -306,7 +306,7 @@ public class ReplenishReportProduction extends SvrProcess
sql.append(" AND AD_PInstance_ID=").append(getAD_PInstance_ID());
no = DB.executeUpdate(sql.toString(), get_TrxName());
if (no != 0)
- log.fine("Delete Inactive=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Delete Inactive=" + no);
// Ensure Data consistency
sql = new StringBuilder("UPDATE T_Replenish SET QtyOnHand = 0 WHERE QtyOnHand IS NULL");
@@ -326,7 +326,7 @@ public class ReplenishReportProduction extends SvrProcess
sql.append(" AND AD_PInstance_ID=").append(getAD_PInstance_ID());
no = DB.executeUpdate(sql.toString(), get_TrxName());
if (no != 0)
- log.fine("Update Type-1=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Update Type-1=" + no);
//
// X_M_Replenish.REPLENISHTYPE_MaintainMaximumLevel
sql = new StringBuilder("UPDATE T_Replenish");
@@ -335,7 +335,7 @@ public class ReplenishReportProduction extends SvrProcess
sql.append(" AND AD_PInstance_ID=").append(getAD_PInstance_ID());
no = DB.executeUpdate(sql.toString(), get_TrxName());
if (no != 0)
- log.fine("Update Type-2=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Update Type-2=" + no);
// Minimum Order Quantity
@@ -346,7 +346,7 @@ public class ReplenishReportProduction extends SvrProcess
sql.append(" AND AD_PInstance_ID=").append(getAD_PInstance_ID());
no = DB.executeUpdate(sql.toString(), get_TrxName());
if (no != 0)
- log.fine("Set MinOrderQty=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set MinOrderQty=" + no);
// Even dividable by Pack
sql = new StringBuilder("UPDATE T_Replenish");
@@ -356,7 +356,7 @@ public class ReplenishReportProduction extends SvrProcess
sql.append(" AND AD_PInstance_ID=").append(getAD_PInstance_ID());
no = DB.executeUpdate(sql.toString(), get_TrxName());
if (no != 0)
- log.fine("Set OrderPackQty=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set OrderPackQty=" + no);
// Source from other warehouse
if (wh.getM_WarehouseSource_ID() != 0)
@@ -366,7 +366,7 @@ public class ReplenishReportProduction extends SvrProcess
sql.append(" WHERE AD_PInstance_ID=").append(getAD_PInstance_ID());
no = DB.executeUpdate(sql.toString(), get_TrxName());
if (no != 0)
- log.fine("Set Source Warehouse=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set Source Warehouse=" + no);
}
// Check Source Warehouse
sql = new StringBuilder("UPDATE T_Replenish");
@@ -375,7 +375,7 @@ public class ReplenishReportProduction extends SvrProcess
sql.append(" AND AD_PInstance_ID=").append(getAD_PInstance_ID());
no = DB.executeUpdate(sql.toString(), get_TrxName());
if (no != 0)
- log.fine("Set same Source Warehouse=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Set same Source Warehouse=" + no);
// Custom Replenishment
String className = wh.getReplenishmentClass();
@@ -422,7 +422,7 @@ public class ReplenishReportProduction extends SvrProcess
sql.append(" AND AD_PInstance_ID=").append(getAD_PInstance_ID());
no = DB.executeUpdate(sql.toString(), get_TrxName());
if (no != 0)
- log.fine("Delete No QtyToOrder=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Delete No QtyToOrder=" + no);
} // fillTable
@@ -459,7 +459,7 @@ public class ReplenishReportProduction extends SvrProcess
order.setM_Warehouse_ID(wh.getM_Warehouse_ID());
if (!order.save())
return;
- log.fine(order.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(order.toString());
noOrders++;
info.append(" - ");
info.append(order.getDocumentNo());
@@ -503,7 +503,7 @@ public class ReplenishReportProduction extends SvrProcess
requisition.setM_Warehouse_ID(wh.getM_Warehouse_ID());
if (!requisition.save())
return;
- log.fine(requisition.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(requisition.toString());
noReqs++;
info.append(" - ");
info.append(requisition.getDocumentNo());
@@ -561,7 +561,7 @@ public class ReplenishReportProduction extends SvrProcess
move.setAD_Org_ID(whSource.getAD_Org_ID());
if (!move.save())
return;
- log.fine(move.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(move.toString());
noMoves++;
info.append(" - ").append(move.getDocumentNo());
}
@@ -684,7 +684,7 @@ public class ReplenishReportProduction extends SvrProcess
if (!order.save())
return;
- log.fine(order.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(order.toString());
noMoves++;
info.append(" - ").append(order.getDocumentNo());
}
@@ -814,7 +814,7 @@ public class ReplenishReportProduction extends SvrProcess
production.setIsCreated("Y");
production.saveEx(get_TrxName());
- log.fine(production.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(production.toString());
noProds++;
info.append(" - ");
info.append(production.getDocumentNo());
diff --git a/org.adempiere.base.process/src/org/compiere/process/ReplicationLocal.java b/org.adempiere.base.process/src/org/compiere/process/ReplicationLocal.java
index 35d0966489..df267a09a1 100644
--- a/org.adempiere.base.process/src/org/compiere/process/ReplicationLocal.java
+++ b/org.adempiere.base.process/src/org/compiere/process/ReplicationLocal.java
@@ -280,7 +280,7 @@ public class ReplicationLocal extends SvrProcess
data.CentralData = getRowSet(data.Sql, null);
if (data.CentralData == null)
{
- log.fine("mergeDataTable - CentralData is Null - " + TableName);
+ if (log.isLoggable(Level.FINE)) log.fine("mergeDataTable - CentralData is Null - " + TableName);
m_replicated = false;
return false;
}
@@ -312,7 +312,7 @@ public class ReplicationLocal extends SvrProcess
{data.TableName, data.KeyColumns, sourceRS, targetRS, m_test, Boolean.TRUE});
boolean replicated = isReplicated(result);
if (replicated)
- log.fine("mergeDataTable -> " + TableName + " - " + result);
+ if (log.isLoggable(Level.FINE)) log.fine("mergeDataTable -> " + TableName + " - " + result);
else
{
m_replicated = false;
@@ -458,7 +458,7 @@ public class ReplicationLocal extends SvrProcess
data.CentralData = getRowSet(data.Sql, null);
if (data.CentralData == null)
{
- log.fine("sendUpdatesTable - Null - " + TableName);
+ if (log.isLoggable(Level.FINE)) log.fine("sendUpdatesTable - Null - " + TableName);
m_replicated = false;
return false;
}
@@ -471,17 +471,17 @@ public class ReplicationLocal extends SvrProcess
}
catch (SQLException ex)
{
- log.fine("RowCheck " + ex);
+ if (log.isLoggable(Level.FINE)) log.fine("RowCheck " + ex);
m_replicated = false;
return false;
}
if (rows == 0)
{
- log.fine("No Rows - " + TableName);
+ if (log.isLoggable(Level.FINE)) log.fine("No Rows - " + TableName);
return true;
}
else
- log.fine(TableName + " #" + rows);
+ if (log.isLoggable(Level.FINE)) log.fine(TableName + " #" + rows);
// Process Info
ProcessInfo pi = new ProcessInfo("SendUpdates", 0);
diff --git a/org.adempiere.base.process/src/org/compiere/process/ReplicationRemote.java b/org.adempiere.base.process/src/org/compiere/process/ReplicationRemote.java
index cd790a7aa0..7b63065728 100644
--- a/org.adempiere.base.process/src/org/compiere/process/ReplicationRemote.java
+++ b/org.adempiere.base.process/src/org/compiere/process/ReplicationRemote.java
@@ -111,7 +111,7 @@ public class ReplicationRemote extends SvrProcess
//int AD_Table_ID = rs.getInt(1);
String ReplicationType = rs.getString(2);
String TableName = rs.getString(3);
- log.fine("setupRemote - " + TableName + " - " + ReplicationType);
+ if (log.isLoggable(Level.FINE)) log.fine("setupRemote - " + TableName + " - " + ReplicationType);
if (!data.Test.booleanValue())
setupRemoteAD_Table(TableName, ReplicationType);
}
@@ -237,7 +237,7 @@ public class ReplicationRemote extends SvrProcess
RowSet targetRS = ReplicationLocal.getRowSet(data.Sql, null);
Object result = doIt (ReplicationLocal.START, "sync", new Object[] // Merge
{data.TableName, data.KeyColumns, sourceRS, targetRS, data.Test, Boolean.TRUE});
- log.fine("receiveUpdateFromCentral - " + data.TableName + " - " + result);
+ if (log.isLoggable(Level.FINE)) log.fine("receiveUpdateFromCentral - " + data.TableName + " - " + result);
pi.setSerializableObject(null);
boolean replicated = ReplicationLocal.isReplicated(result);
if (!replicated)
@@ -280,7 +280,7 @@ public class ReplicationRemote extends SvrProcess
RowSet targetRS = ReplicationLocal.getRowSet(data.Sql, null);
Object result = doIt (ReplicationLocal.START, "sync", new Object[] // Sync
{data.TableName, data.KeyColumns, sourceRS, targetRS, data.Test, Boolean.FALSE});
- log.fine("receiveUpdateFromCentral - " + data.TableName + " - " + result);
+ if (log.isLoggable(Level.FINE)) log.fine("receiveUpdateFromCentral - " + data.TableName + " - " + result);
pi.setSerializableObject(null);
boolean replicated = ReplicationLocal.isReplicated(result);
if (!replicated)
diff --git a/org.adempiere.base.process/src/org/compiere/process/RequestEMailProcessor.java b/org.adempiere.base.process/src/org/compiere/process/RequestEMailProcessor.java
index f791882fcc..79f162f59f 100644
--- a/org.adempiere.base.process/src/org/compiere/process/RequestEMailProcessor.java
+++ b/org.adempiere.base.process/src/org/compiere/process/RequestEMailProcessor.java
@@ -186,7 +186,7 @@ public class RequestEMailProcessor extends SvrProcess
//
m_session = Session.getDefaultInstance(props, auth);
m_session.setDebug(CLogMgt.isLevelFinest());
- log.fine("getSession - " + m_session);
+ if (log.isLoggable(Level.FINE)) log.fine("getSession - " + m_session);
return m_session;
} // getSession
@@ -208,7 +208,7 @@ public class RequestEMailProcessor extends SvrProcess
// Connect
m_store.connect();
//
- log.fine("getStore - " + m_store);
+ if (log.isLoggable(Level.FINE)) log.fine("getStore - " + m_store);
return m_store;
} // getStore
@@ -229,7 +229,7 @@ public class RequestEMailProcessor extends SvrProcess
if (!inbox.exists())
throw new IllegalStateException("No Inbox");
inbox.open(Folder.READ_WRITE);
- log.fine("processInBox - " + inbox.getName()
+ if (log.isLoggable(Level.FINE)) log.fine("processInBox - " + inbox.getName()
+ "; Messages Total=" + inbox.getMessageCount()
+ "; New=" + inbox.getNewMessageCount());
diff --git a/org.adempiere.base.process/src/org/compiere/process/RfQResponseRank.java b/org.adempiere.base.process/src/org/compiere/process/RfQResponseRank.java
index 05fbc904e3..79bcc001e3 100644
--- a/org.adempiere.base.process/src/org/compiere/process/RfQResponseRank.java
+++ b/org.adempiere.base.process/src/org/compiere/process/RfQResponseRank.java
@@ -82,7 +82,7 @@ public class RfQResponseRank extends SvrProcess
// Get Completed, Active Responses
MRfQResponse[] responses = rfq.getResponses (true, true);
- log.fine("doIt - #Responses=" + responses.length);
+ if (log.isLoggable(Level.FINE)) log.fine("doIt - #Responses=" + responses.length);
if (responses.length == 0)
throw new IllegalArgumentException("No completed RfQ Responses found");
if (responses.length == 1)
@@ -120,7 +120,7 @@ public class RfQResponseRank extends SvrProcess
MRfQLine rfqLine = rfqLines[i];
if (!rfqLine.isActive())
continue;
- log.fine("rankLines - " + rfqLine);
+ if (log.isLoggable(Level.FINE)) log.fine("rankLines - " + rfqLine);
MRfQLineQty[] rfqQtys = rfqLine.getQtys();
for (int j = 0; j < rfqQtys.length; j++)
{
@@ -128,7 +128,7 @@ public class RfQResponseRank extends SvrProcess
MRfQLineQty rfqQty = rfqQtys[j];
if (!rfqQty.isActive() || !rfqQty.isRfQQty())
continue;
- log.fine("rankLines Qty - " + rfqQty);
+ if (log.isLoggable(Level.FINE)) log.fine("rankLines Qty - " + rfqQty);
MRfQResponseLineQty[] respQtys = rfqQty.getResponseQtys(false);
for (int kk = 0; kk < respQtys.length; kk++)
{
@@ -138,14 +138,14 @@ public class RfQResponseRank extends SvrProcess
{
respQty.setRanking(999);
respQty.saveEx();
- log.fine(" - ignored: " + respQty);
+ if (log.isLoggable(Level.FINE)) log.fine(" - ignored: " + respQty);
}
} // for all respones line qtys
// Rank RfQ Line Qtys
respQtys = rfqQty.getResponseQtys(false);
if (respQtys.length == 0)
- log.fine(" - No Qtys with valid Amounts");
+ if (log.isLoggable(Level.FINE)) log.fine(" - No Qtys with valid Amounts");
else
{
Arrays.sort(respQtys, respQtys[0]);
@@ -164,7 +164,7 @@ public class RfQResponseRank extends SvrProcess
{
qty.setRanking(999);
qty.saveEx();
- log.fine(" - Rank 999: " + qty);
+ if (log.isLoggable(Level.FINE)) log.fine(" - Rank 999: " + qty);
continue;
}
@@ -174,7 +174,7 @@ public class RfQResponseRank extends SvrProcess
lastAmt = qty.getNetAmt();
}
qty.setRanking(lastRank);
- log.fine(" - Rank " + lastRank + ": " + qty);
+ if (log.isLoggable(Level.FINE)) log.fine(" - Rank " + lastRank + ": " + qty);
qty.saveEx();
//
if (rank == 0) // Update RfQ
@@ -224,7 +224,7 @@ public class RfQResponseRank extends SvrProcess
}
response.setRanking(ranking);
response.saveEx();
- log.fine("- Response Ranking " + ranking + ": " + response);
+ if (log.isLoggable(Level.FINE)) log.fine("- Response Ranking " + ranking + ": " + response);
if (!rfq.isQuoteSelectedLines()) // no total selected winner if not all lines
{
if (winner == null && ranking > 0)
@@ -239,7 +239,7 @@ public class RfQResponseRank extends SvrProcess
{
winner.setIsSelectedWinner(true);
winner.saveEx();
- log.fine("- Response Winner: " + winner);
+ if (log.isLoggable(Level.FINE)) log.fine("- Response Winner: " + winner);
}
} // rankLines
@@ -272,7 +272,7 @@ public class RfQResponseRank extends SvrProcess
response.setIsSelectedWinner(false);
}
response.saveEx();
- log.fine("rankResponse - " + response);
+ if (log.isLoggable(Level.FINE)) log.fine("rankResponse - " + response);
}
} // rankResponses
diff --git a/org.adempiere.base.process/src/org/compiere/process/SendMailText.java b/org.adempiere.base.process/src/org/compiere/process/SendMailText.java
index e108d88759..03eb16f3ff 100644
--- a/org.adempiere.base.process/src/org/compiere/process/SendMailText.java
+++ b/org.adempiere.base.process/src/org/compiere/process/SendMailText.java
@@ -116,7 +116,7 @@ public class SendMailText extends SvrProcess
if (m_from.getAD_User_ID() == 0)
throw new Exception ("No found @AD_User_ID@=" + m_AD_User_ID);
}
- log.fine("From " + m_from);
+ if (log.isLoggable(Level.FINE)) log.fine("From " + m_from);
long start = System.currentTimeMillis();
if (m_R_InterestArea_ID > 0)
@@ -284,7 +284,7 @@ public class SendMailText extends SvrProcess
new MUserMail(m_MailText, AD_User_ID, email).saveEx();
//
if (OK)
- log.fine(to.getEMail());
+ if (log.isLoggable(Level.FINE)) log.fine(to.getEMail());
else
log.warning("FAILURE - " + to.getEMail());
StringBuilder msglog = new StringBuilder((OK ? "@OK@" : "@ERROR@")).append(" - ").append(to.getEMail());
diff --git a/org.adempiere.base.process/src/org/compiere/process/TableCreateColumns.java b/org.adempiere.base.process/src/org/compiere/process/TableCreateColumns.java
index 7a22cd2705..3423884e16 100644
--- a/org.adempiere.base.process/src/org/compiere/process/TableCreateColumns.java
+++ b/org.adempiere.base.process/src/org/compiere/process/TableCreateColumns.java
@@ -167,7 +167,7 @@ public class TableCreateColumns extends SvrProcess
|| tn.indexOf("EXPLAIN") != -1 // explain plan
)
{
- log.fine("Ignored: " + tableName + " - " + tableType);
+ if (log.isLoggable(Level.FINE)) log.fine("Ignored: " + tableName + " - " + tableType);
continue;
}
//
diff --git a/org.adempiere.base.process/src/org/compiere/process/TransactionXRef.java b/org.adempiere.base.process/src/org/compiere/process/TransactionXRef.java
index 83afc16e94..d334afa0e8 100644
--- a/org.adempiere.base.process/src/org/compiere/process/TransactionXRef.java
+++ b/org.adempiere.base.process/src/org/compiere/process/TransactionXRef.java
@@ -134,7 +134,7 @@ public class TransactionXRef extends SvrProcess
.append(") ORDER BY M_Transaction_ID");
//
int no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine(sql.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(sql.toString());
if (log.isLoggable(Level.CONFIG)) log.config("#" + no);
// Multi-Level
diff --git a/org.adempiere.base.process/src/org/compiere/process/UserPassword.java b/org.adempiere.base.process/src/org/compiere/process/UserPassword.java
index 47fd389231..31164246ab 100644
--- a/org.adempiere.base.process/src/org/compiere/process/UserPassword.java
+++ b/org.adempiere.base.process/src/org/compiere/process/UserPassword.java
@@ -82,7 +82,7 @@ public class UserPassword extends SvrProcess
MUser user = MUser.get(getCtx(), p_AD_User_ID);
user.load(get_TrxName());
MUser operator = MUser.get(getCtx(), getAD_User_ID());
- log.fine("User=" + user + ", Operator=" + operator);
+ if (log.isLoggable(Level.FINE)) log.fine("User=" + user + ", Operator=" + operator);
boolean hash_password = MSysConfig.getBooleanValue(MSysConfig.USER_PASSWORD_HASH, false);
diff --git a/org.adempiere.base/src/org/adempiere/impexp/AbstractExcelExporter.java b/org.adempiere.base/src/org/adempiere/impexp/AbstractExcelExporter.java
index 68bdf41b5a..643ad19430 100644
--- a/org.adempiere.base/src/org/adempiere/impexp/AbstractExcelExporter.java
+++ b/org.adempiere.base/src/org/adempiere/impexp/AbstractExcelExporter.java
@@ -35,7 +35,6 @@ import org.apache.poi.hssf.usermodel.HSSFRow;
import org.apache.poi.hssf.usermodel.HSSFSheet;
import org.apache.poi.hssf.usermodel.HSSFWorkbook;
import org.compiere.Adempiere;
-import org.compiere.util.CLogMgt;
import org.compiere.util.CLogger;
import org.compiere.util.DisplayType;
import org.compiere.util.Env;
@@ -457,7 +456,7 @@ public abstract class AbstractExcelExporter
//
// Workbook Info
- if (CLogMgt.isLevelFine()) {
+ if (log.isLoggable(Level.FINE)) {
log.fine("Sheets #"+m_sheetCount);
log.fine("Styles used #"+m_styles.size());
}
diff --git a/org.adempiere.base/src/org/adempiere/impexp/GridTabCSVImporter.java b/org.adempiere.base/src/org/adempiere/impexp/GridTabCSVImporter.java
index 331b2f8373..60f5594749 100644
--- a/org.adempiere.base/src/org/adempiere/impexp/GridTabCSVImporter.java
+++ b/org.adempiere.base/src/org/adempiere/impexp/GridTabCSVImporter.java
@@ -28,6 +28,7 @@ import java.util.Calendar;
import java.util.List;
import java.util.Map;
import java.util.Map.Entry;
+import java.util.logging.Level;
import java.util.UUID;
import org.adempiere.base.IGridTabImporter;
@@ -195,7 +196,7 @@ public class GridTabCSVImporter implements IGridTabImporter
StringBuilder lineError = new StringBuilder();
String headName = set.getKey();
Object value = set.getValue();
- log.fine("Setting " + headName + " to " + value);
+ if (log.isLoggable(Level.FINE)) log.fine("Setting " + headName + " to " + value);
String columnName = headName;
diff --git a/org.adempiere.base/src/org/adempiere/util/AbstractDocumentSearch.java b/org.adempiere.base/src/org/adempiere/util/AbstractDocumentSearch.java
index aa1436a58f..62e70632c5 100644
--- a/org.adempiere.base/src/org/adempiere/util/AbstractDocumentSearch.java
+++ b/org.adempiere.base/src/org/adempiere/util/AbstractDocumentSearch.java
@@ -36,6 +36,7 @@ import java.util.ArrayList;
import java.util.List;
import java.util.Properties;
import java.util.Vector;
+import java.util.logging.Level;
import org.compiere.model.MColumn;
import org.compiere.model.MQuery;
@@ -67,7 +68,7 @@ public abstract class AbstractDocumentSearch {
StringBuilder msglog = new StringBuilder();
msglog.append("Search started with String: ").append(searchString);
- log.fine(msglog.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(msglog.toString());
// Check if / how many transaction-codes are used
if (! Util.isEmpty(searchString)) {
@@ -104,12 +105,12 @@ public abstract class AbstractDocumentSearch {
msglog = new StringBuilder("Search with Transaction: '");
msglog.append(codeList.get(i)).append("' for: '")
.append(search.toString()).append("'");
- log.fine(msglog.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(msglog.toString());
getID(codeList.get(i), search.toString());
}
} else {
msglog = new StringBuilder("Search without Transaction: ").append(search.toString());
- log.fine(msglog.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(msglog.toString());
getID(null, search.toString());
}
} else {
@@ -195,7 +196,7 @@ public abstract class AbstractDocumentSearch {
}
if (pstmtSO != null) {
msglog = new StringBuilder("SQL Sales: ").append(sqlSO.toString());
- log.fine(msglog.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(msglog.toString());
rsSO = pstmtSO.executeQuery();
Vector idSO = new Vector();
while (rsSO.next()) {
@@ -204,7 +205,7 @@ public abstract class AbstractDocumentSearch {
if (role.getWindowAccess(msd.getAD_Window_ID()) != null) {
msglog = new StringBuilder("Open Window: ").append(msd.getAD_Window_ID()).append(" / Table: ")
.append(table.getTableName()).append(" / Number of Results: ").append(idSO.size());
- log.fine(msglog.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(msglog.toString());
if (idSO.size() == 0 && (searchString == null || searchString.trim().length() == 0)) {
// No search string - open the window with new record
@@ -218,7 +219,7 @@ public abstract class AbstractDocumentSearch {
}
if (pstmtPO != null) {
msglog = new StringBuilder("SQL Purchase: ").append(sqlPO);
- log.fine(msglog.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(msglog.toString());
rsPO = pstmtPO.executeQuery();
Vector idPO = new Vector();
while (rsPO.next()) {
@@ -227,7 +228,7 @@ public abstract class AbstractDocumentSearch {
if (role.getWindowAccess(msd.getPO_Window_ID()) != null) {
msglog = new StringBuilder("Open Window: ").append(msd.getPO_Window_ID()).append(" / Table: ")
.append(table.getTableName()).append(" / Number of Results: ").append(idPO.size());
- log.fine(msglog.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(msglog.toString());
openWindow(idPO, table.getTableName(), msd.getPO_Window_ID());
} else {
log.warning("Role is not allowed to view this window");
@@ -287,7 +288,7 @@ public abstract class AbstractDocumentSearch {
final MQuery query = new MQuery(tableName);
if (whereString != null) {
- log.fine(whereString.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(whereString.toString());
query.addRestriction(whereString.toString());
}
final boolean ok = openWindow(windowId, query);
diff --git a/org.adempiere.base/src/org/adempiere/util/LogAuthFailure.java b/org.adempiere.base/src/org/adempiere/util/LogAuthFailure.java
index 0509fd0924..9623de84db 100644
--- a/org.adempiere.base/src/org/adempiere/util/LogAuthFailure.java
+++ b/org.adempiere.base/src/org/adempiere/util/LogAuthFailure.java
@@ -24,6 +24,7 @@ import java.io.OutputStreamWriter;
import java.io.Writer;
import java.sql.Timestamp;
import java.text.SimpleDateFormat;
+import java.util.logging.Level;
import org.compiere.util.CLogger;
import org.compiere.util.DisplayType;
@@ -47,7 +48,7 @@ public class LogAuthFailure {
file = new FileOutputStream(fileName, true);
writer = new BufferedWriter(new OutputStreamWriter(file, "UTF8"));
} catch (IOException e) {
- log.fine(e.getMessage());
+ if (log.isLoggable(Level.FINE)) log.fine(e.getMessage());
e.printStackTrace();
}
}
@@ -70,7 +71,7 @@ public class LogAuthFailure {
writer.append("\n");
writer.flush();
} catch (Exception e) {
- log.fine(e.getMessage());
+ if (log.isLoggable(Level.FINE)) log.fine(e.getMessage());
}
}
diff --git a/org.adempiere.base/src/org/adempiere/util/ProcessUtil.java b/org.adempiere.base/src/org/adempiere/util/ProcessUtil.java
index fabec25df4..f3cec3714f 100644
--- a/org.adempiere.base/src/org/adempiere/util/ProcessUtil.java
+++ b/org.adempiere.base/src/org/adempiere/util/ProcessUtil.java
@@ -308,7 +308,7 @@ public final class ProcessUtil {
public static MWFProcess startWorkFlow(Properties ctx, ProcessInfo pi, int AD_Workflow_ID) {
MWorkflow wf = MWorkflow.get (ctx, AD_Workflow_ID);
MWFProcess wfProcess = wf.start(pi, pi.getTransactionName());
- log.fine(pi.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(pi.toString());
return wfProcess;
}
diff --git a/org.adempiere.base/src/org/compiere/acct/Doc.java b/org.adempiere.base/src/org/compiere/acct/Doc.java
index 0b4e9fd6f3..ebf2d88c90 100644
--- a/org.adempiere.base/src/org/compiere/acct/Doc.java
+++ b/org.adempiere.base/src/org/compiere/acct/Doc.java
@@ -916,7 +916,7 @@ public abstract class Doc
//
boolean retValue = getBalance().signum() == 0;
if (retValue)
- log.fine("Yes " + toString());
+ if (log.isLoggable(Level.FINE)) log.fine("Yes " + toString());
else
log.warning("NO - " + toString());
return retValue;
@@ -932,7 +932,7 @@ public abstract class Doc
// No Currency in document
if (getC_Currency_ID() == NO_CURRENCY)
{
- log.fine("(none) - " + toString());
+ if (log.isLoggable(Level.FINE)) log.fine("(none) - " + toString());
return true;
}
// Journal from a different acct schema
@@ -954,7 +954,7 @@ public abstract class Doc
// just one and the same
if (set.size() == 1 && acctSchema.getC_Currency_ID() == getC_Currency_ID())
{
- log.fine("(same) Cur=" + getC_Currency_ID() + " - " + toString());
+ if (log.isLoggable(Level.FINE)) log.fine("(same) Cur=" + getC_Currency_ID() + " - " + toString());
return true;
}
@@ -975,11 +975,11 @@ public abstract class Doc
+ " - " + toString());
}
else
- log.fine("From C_Currency_ID=" + C_Currency_ID);
+ if (log.isLoggable(Level.FINE)) log.fine("From C_Currency_ID=" + C_Currency_ID);
}
}
- log.fine("Convertible=" + convertible + ", AcctSchema C_Currency_ID=" + acctSchema.getC_Currency_ID() + " - " + toString());
+ if (log.isLoggable(Level.FINE)) log.fine("Convertible=" + convertible + ", AcctSchema C_Currency_ID=" + acctSchema.getC_Currency_ID() + " - " + toString());
return convertible;
} // isConvertible
@@ -1009,7 +1009,7 @@ public abstract class Doc
else
m_C_Period_ID = -1;
//
- log.fine( // + AD_Client_ID + " - "
+ if (log.isLoggable(Level.FINE)) log.fine( // + AD_Client_ID + " - "
getDateAcct() + " - " + getDocumentType() + " => " + m_C_Period_ID);
} // setC_Period_ID
@@ -1033,7 +1033,7 @@ public abstract class Doc
setPeriod();
boolean open = m_C_Period_ID > 0;
if (open)
- log.fine("Yes - " + toString());
+ if (log.isLoggable(Level.FINE)) log.fine("Yes - " + toString());
else
log.warning("NO - " + toString());
return open;
diff --git a/org.adempiere.base/src/org/compiere/acct/DocLine.java b/org.adempiere.base/src/org/compiere/acct/DocLine.java
index a28f11b81b..ac1cce333b 100644
--- a/org.adempiere.base/src/org/compiere/acct/DocLine.java
+++ b/org.adempiere.base/src/org/compiere/acct/DocLine.java
@@ -18,6 +18,7 @@ package org.compiere.acct;
import java.math.BigDecimal;
import java.sql.Timestamp;
+import java.util.logging.Level;
import org.compiere.model.MAccount;
import org.compiere.model.MAcctSchema;
@@ -978,7 +979,7 @@ public class DocLine
String sql = "SELECT COALESCE(C_SalesRegion_ID,0) FROM C_BPartner_Location WHERE C_BPartner_Location_ID=?";
m_C_SalesRegion_ID = DB.getSQLValue (null,
sql, getC_BPartner_Location_ID());
- log.fine("C_SalesRegion_ID=" + m_C_SalesRegion_ID + " (from BPL)" );
+ if (log.isLoggable(Level.FINE)) log.fine("C_SalesRegion_ID=" + m_C_SalesRegion_ID + " (from BPL)" );
if (m_C_SalesRegion_ID == 0)
m_C_SalesRegion_ID = -2; // don't try again
}
diff --git a/org.adempiere.base/src/org/compiere/acct/Doc_AllocationHdr.java b/org.adempiere.base/src/org/compiere/acct/Doc_AllocationHdr.java
index 73473c796d..77e474fb19 100644
--- a/org.adempiere.base/src/org/compiere/acct/Doc_AllocationHdr.java
+++ b/org.adempiere.base/src/org/compiere/acct/Doc_AllocationHdr.java
@@ -109,7 +109,7 @@ public class Doc_AllocationHdr extends Doc
docLine.setC_ConversionType_ID(C_ConversionType_ID);
}
//
- log.fine(docLine.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(docLine.toString());
list.add (docLine);
}
@@ -749,7 +749,7 @@ public class Doc_AllocationHdr extends Doc
//
StringBuilder description = new StringBuilder("Invoice=(").append(invoice.getC_Currency_ID()).append(")").append(invoiceSource).append("/").append(invoiceAccounted)
.append(" - Allocation=(").append(getC_Currency_ID()).append(")").append(allocationSource).append("/").append(allocationAccounted);
- log.fine(description.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(description.toString());
// Allocation not Invoice Currency
if (getC_Currency_ID() != invoice.getC_Currency_ID())
{
@@ -761,7 +761,7 @@ public class Doc_AllocationHdr extends Doc
return "Gain/Loss - No Conversion from Allocation->Invoice";
StringBuilder d2 = new StringBuilder("Allocation=(").append(getC_Currency_ID()).append(")").append(allocationSource)
.append("->(").append(invoice.getC_Currency_ID()).append(")").append(allocationSourceNew);
- log.fine(d2.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(d2.toString());
description.append(" - ").append(d2);
allocationSource = allocationSourceNew;
}
@@ -772,7 +772,7 @@ public class Doc_AllocationHdr extends Doc
{
acctDifference = invoiceAccounted.subtract(allocationAccounted); // gain is negative
StringBuilder d2 = new StringBuilder("(full) = ").append(acctDifference);
- log.fine(d2.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(d2.toString());
description.append(" - ").append(d2);
}
else // partial or MC
@@ -791,7 +791,7 @@ public class Doc_AllocationHdr extends Doc
if (acctDifference.scale() > precision)
acctDifference = acctDifference.setScale(precision, BigDecimal.ROUND_HALF_UP);
StringBuilder d2 = new StringBuilder("(partial) = ").append(acctDifference).append(" - Multiplier=").append(multiplier);
- log.fine(d2.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(d2.toString());
description.append(" - ").append(d2);
}
@@ -1092,7 +1092,7 @@ class Doc_AllocationTax
*/
private BigDecimal calcAmount (BigDecimal tax, BigDecimal total, BigDecimal amt, int precision)
{
- log.fine("Amt=" + amt + " - Total=" + total + ", Tax=" + tax);
+ if (log.isLoggable(Level.FINE)) log.fine("Amt=" + amt + " - Total=" + total + ", Tax=" + tax);
if (tax.signum() == 0
|| total.signum() == 0
|| amt.signum() == 0)
@@ -1102,7 +1102,7 @@ class Doc_AllocationTax
BigDecimal retValue = multiplier.multiply(amt);
if (retValue.scale() > precision)
retValue = retValue.setScale(precision, BigDecimal.ROUND_HALF_UP);
- log.fine(retValue + " (Mult=" + multiplier + "(Prec=" + precision + ")");
+ if (log.isLoggable(Level.FINE)) log.fine(retValue + " (Mult=" + multiplier + "(Prec=" + precision + ")");
return retValue;
} // calcAmount
diff --git a/org.adempiere.base/src/org/compiere/acct/Doc_BankStatement.java b/org.adempiere.base/src/org/compiere/acct/Doc_BankStatement.java
index 706ce4b728..ef8f147a95 100644
--- a/org.adempiere.base/src/org/compiere/acct/Doc_BankStatement.java
+++ b/org.adempiere.base/src/org/compiere/acct/Doc_BankStatement.java
@@ -19,6 +19,7 @@ package org.compiere.acct;
import java.math.BigDecimal;
import java.sql.ResultSet;
import java.util.ArrayList;
+import java.util.logging.Level;
import org.compiere.model.MAccount;
import org.compiere.model.MAcctSchema;
@@ -79,7 +80,7 @@ public class Doc_BankStatement extends Doc
// Contained Objects
p_lines = loadLines(bs);
- log.fine("Lines=" + p_lines.length);
+ if (log.isLoggable(Level.FINE)) log.fine("Lines=" + p_lines.length);
return null;
} // loadDocumentDetails
@@ -132,7 +133,7 @@ public class Doc_BankStatement extends Doc
}
sb.append("]");
//
- log.fine(toString() + " Balance=" + retValue + sb.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(toString() + " Balance=" + retValue + sb.toString());
return retValue;
} // getBalance
diff --git a/org.adempiere.base/src/org/compiere/acct/Doc_Cash.java b/org.adempiere.base/src/org/compiere/acct/Doc_Cash.java
index 4c6e36f6cd..c90bf0d937 100644
--- a/org.adempiere.base/src/org/compiere/acct/Doc_Cash.java
+++ b/org.adempiere.base/src/org/compiere/acct/Doc_Cash.java
@@ -68,7 +68,7 @@ public class Doc_Cash extends Doc
// Contained Objects
p_lines = loadLines(cash, cb);
- log.fine("Lines=" + p_lines.length);
+ if (log.isLoggable(Level.FINE)) log.fine("Lines=" + p_lines.length);
return null;
} // loadDocumentDetails
@@ -117,7 +117,7 @@ public class Doc_Cash extends Doc
}
sb.append("]");
//
- log.fine(toString() + " Balance=" + retValue + sb.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(toString() + " Balance=" + retValue + sb.toString());
// return retValue;
return Env.ZERO; // Lines are balanced
} // getBalance
diff --git a/org.adempiere.base/src/org/compiere/acct/Doc_GLJournal.java b/org.adempiere.base/src/org/compiere/acct/Doc_GLJournal.java
index 1c6318eba3..902d4cfd16 100644
--- a/org.adempiere.base/src/org/compiere/acct/Doc_GLJournal.java
+++ b/org.adempiere.base/src/org/compiere/acct/Doc_GLJournal.java
@@ -65,7 +65,7 @@ public class Doc_GLJournal extends Doc
// Contained Objects
p_lines = loadLines(journal);
- log.fine("Lines=" + p_lines.length);
+ if (log.isLoggable(Level.FINE)) log.fine("Lines=" + p_lines.length);
return null;
} // loadDocumentDetails
@@ -117,7 +117,7 @@ public class Doc_GLJournal extends Doc
}
sb.append("]");
//
- log.fine(toString() + " Balance=" + retValue + sb.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(toString() + " Balance=" + retValue + sb.toString());
return retValue;
} // getBalance
diff --git a/org.adempiere.base/src/org/compiere/acct/Doc_InOut.java b/org.adempiere.base/src/org/compiere/acct/Doc_InOut.java
index 53b2c8d381..f74460caf1 100644
--- a/org.adempiere.base/src/org/compiere/acct/Doc_InOut.java
+++ b/org.adempiere.base/src/org/compiere/acct/Doc_InOut.java
@@ -76,7 +76,7 @@ public class Doc_InOut extends Doc
m_DocStatus = inout.getDocStatus();
// Contained Objects
p_lines = loadLines(inout);
- log.fine("Lines=" + p_lines.length);
+ if (log.isLoggable(Level.FINE)) log.fine("Lines=" + p_lines.length);
return null;
} // loadDocumentDetails
@@ -110,7 +110,7 @@ public class Doc_InOut extends Doc
int PP_Cost_Collector_ID = DB.getSQLValueEx(getTrxName(), sql, new Object[]{line.getC_OrderLine_ID()});
docLine.setPP_Cost_Collector_ID(PP_Cost_Collector_ID);
//
- log.fine(docLine.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(docLine.toString());
list.add (docLine);
}
@@ -410,7 +410,7 @@ public class Doc_InOut extends Doc
{
int stdPrecision = MCurrency.getStdPrecision(getCtx(), C_Currency_ID);
BigDecimal costTax = tax.calculateTax(costs, true, stdPrecision);
- log.fine("Costs=" + costs + " - Tax=" + costTax);
+ if (log.isLoggable(Level.FINE)) log.fine("Costs=" + costs + " - Tax=" + costTax);
costs = costs.subtract(costTax);
}
} // correct included Tax
diff --git a/org.adempiere.base/src/org/compiere/acct/Doc_Inventory.java b/org.adempiere.base/src/org/compiere/acct/Doc_Inventory.java
index 88417492d6..1f67aabd87 100644
--- a/org.adempiere.base/src/org/compiere/acct/Doc_Inventory.java
+++ b/org.adempiere.base/src/org/compiere/acct/Doc_Inventory.java
@@ -19,6 +19,7 @@ package org.compiere.acct;
import java.math.BigDecimal;
import java.sql.ResultSet;
import java.util.ArrayList;
+import java.util.logging.Level;
import org.compiere.model.MAccount;
import org.compiere.model.MAcctSchema;
@@ -72,7 +73,7 @@ public class Doc_Inventory extends Doc
m_DocStatus = inventory.getDocStatus();
// Contained Objects
p_lines = loadLines(inventory);
- log.fine("Lines=" + p_lines.length);
+ if (log.isLoggable(Level.FINE)) log.fine("Lines=" + p_lines.length);
return null;
} // loadDocumentDetails
@@ -105,7 +106,7 @@ public class Doc_Inventory extends Doc
}
docLine.setQty (Qty, false); // -5 => -5
docLine.setReversalLine_ID(line.getReversalLine_ID());
- log.fine(docLine.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(docLine.toString());
list.add (docLine);
}
diff --git a/org.adempiere.base/src/org/compiere/acct/Doc_Invoice.java b/org.adempiere.base/src/org/compiere/acct/Doc_Invoice.java
index f5e6084051..8021c57e02 100644
--- a/org.adempiere.base/src/org/compiere/acct/Doc_Invoice.java
+++ b/org.adempiere.base/src/org/compiere/acct/Doc_Invoice.java
@@ -88,7 +88,7 @@ public class Doc_Invoice extends Doc
// Contained Objects
m_taxes = loadTaxes();
p_lines = loadLines(invoice);
- log.fine("Lines=" + p_lines.length + ", Taxes=" + m_taxes.length);
+ if (log.isLoggable(Level.FINE)) log.fine("Lines=" + p_lines.length + ", Taxes=" + m_taxes.length);
return null;
} // loadDocumentDetails
@@ -121,7 +121,7 @@ public class Doc_Invoice extends Doc
//
DocTax taxLine = new DocTax(C_Tax_ID, name, rate,
taxBaseAmt, amount, salesTax);
- log.fine(taxLine.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(taxLine.toString());
list.add(taxLine);
}
}
@@ -173,7 +173,7 @@ public class Doc_Invoice extends Doc
if (!tax.isZeroTax())
{
BigDecimal LineNetAmtTax = tax.calculateTax(LineNetAmt, true, getStdPrecision());
- log.fine("LineNetAmt=" + LineNetAmt + " - Tax=" + LineNetAmtTax);
+ if (log.isLoggable(Level.FINE)) log.fine("LineNetAmt=" + LineNetAmt + " - Tax=" + LineNetAmtTax);
LineNetAmt = LineNetAmt.subtract(LineNetAmtTax);
for (int t = 0; t < m_taxes.length; t++)
{
@@ -194,7 +194,7 @@ public class Doc_Invoice extends Doc
else
m_allLinesItem = false;
//
- log.fine(docLine.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(docLine.toString());
list.add(docLine);
}
@@ -266,7 +266,7 @@ public class Doc_Invoice extends Doc
}
sb.append("]");
//
- log.fine(toString() + " Balance=" + retValue + sb.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(toString() + " Balance=" + retValue + sb.toString());
return retValue;
} // getBalance
@@ -914,7 +914,7 @@ public class Doc_Invoice extends Doc
.append(" AND po.M_Product_ID=il.M_Product_ID AND po.C_BPartner_ID=i.C_BPartner_ID")
.append(" AND i.C_Invoice_ID=").append(get_ID()).append(")");
int no = DB.executeUpdate(sql.toString(), getTrxName());
- log.fine("Updated=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Updated=" + no);
} // updateProductPO
} // Doc_Invoice
diff --git a/org.adempiere.base/src/org/compiere/acct/Doc_MatchInv.java b/org.adempiere.base/src/org/compiere/acct/Doc_MatchInv.java
index 7c96be0ff6..cff6ff0c50 100644
--- a/org.adempiere.base/src/org/compiere/acct/Doc_MatchInv.java
+++ b/org.adempiere.base/src/org/compiere/acct/Doc_MatchInv.java
@@ -19,6 +19,7 @@ package org.compiere.acct;
import java.math.BigDecimal;
import java.sql.ResultSet;
import java.util.ArrayList;
+import java.util.logging.Level;
import org.compiere.model.MAccount;
import org.compiere.model.MAcctSchema;
@@ -131,7 +132,7 @@ public class Doc_MatchInv extends Doc
|| getQty().signum() == 0
|| m_receiptLine.getMovementQty().signum() == 0) // Qty = 0
{
- log.fine("No Product/Qty - M_Product_ID=" + getM_Product_ID()
+ if (log.isLoggable(Level.FINE)) log.fine("No Product/Qty - M_Product_ID=" + getM_Product_ID()
+ ",Qty=" + getQty() + ",InOutQty=" + m_receiptLine.getMovementQty());
return facts;
}
@@ -178,7 +179,7 @@ public class Doc_MatchInv extends Doc
p_Error = "Mat.Receipt not posted yet";
return null;
}
- log.fine("CR - Amt(" + temp + "->" + dr.getAcctBalance()
+ if (log.isLoggable(Level.FINE)) log.fine("CR - Amt(" + temp + "->" + dr.getAcctBalance()
+ ") - " + dr.toString());
// InventoryClearing CR
@@ -201,7 +202,7 @@ public class Doc_MatchInv extends Doc
as.getC_Currency_ID(), null, LineNetAmt); // updated below
if (cr == null)
{
- log.fine("Line Net Amt=0 - M_Product_ID=" + getM_Product_ID()
+ if (log.isLoggable(Level.FINE)) log.fine("Line Net Amt=0 - M_Product_ID=" + getM_Product_ID()
+ ",Qty=" + getQty() + ",InOutQty=" + m_receiptLine.getMovementQty());
// Invoice Price Variance
@@ -222,7 +223,7 @@ public class Doc_MatchInv extends Doc
pv.setUser1_ID(m_invoiceLine.getUser1_ID());
pv.setUser2_ID(m_invoiceLine.getUser2_ID());
}
- log.fine("IPV=" + ipv + "; Balance=" + fact.getSourceBalance());
+ if (log.isLoggable(Level.FINE)) log.fine("IPV=" + ipv + "; Balance=" + fact.getSourceBalance());
facts.add(fact);
return facts;
}
@@ -235,7 +236,7 @@ public class Doc_MatchInv extends Doc
p_Error = "Invoice not posted yet";
return null;
}
- log.fine("DR - Amt(" + temp + "->" + cr.getAcctBalance()
+ if (log.isLoggable(Level.FINE)) log.fine("DR - Amt(" + temp + "->" + cr.getAcctBalance()
+ ") - " + cr.toString());
}
else // Cash Acct
@@ -303,7 +304,7 @@ public class Doc_MatchInv extends Doc
pv.setUser1_ID(m_invoiceLine.getUser1_ID());
pv.setUser2_ID(m_invoiceLine.getUser2_ID());
}
- log.fine("IPV=" + ipv + "; Balance=" + fact.getSourceBalance());
+ if (log.isLoggable(Level.FINE)) log.fine("IPV=" + ipv + "; Balance=" + fact.getSourceBalance());
String error = createMatchInvCostDetail(as);
if (error != null && error.trim().length() > 0)
diff --git a/org.adempiere.base/src/org/compiere/acct/Doc_MatchPO.java b/org.adempiere.base/src/org/compiere/acct/Doc_MatchPO.java
index 33d644db91..ed3d8b8355 100644
--- a/org.adempiere.base/src/org/compiere/acct/Doc_MatchPO.java
+++ b/org.adempiere.base/src/org/compiere/acct/Doc_MatchPO.java
@@ -129,7 +129,7 @@ public class Doc_MatchPO extends Doc
|| getQty().signum() == 0
|| m_M_InOutLine_ID == 0) // No posting if not matched to Shipment
{
- log.fine("No Product/Qty - M_Product_ID=" + getM_Product_ID()
+ if (log.isLoggable(Level.FINE)) log.fine("No Product/Qty - M_Product_ID=" + getM_Product_ID()
+ ",Qty=" + getQty());
return facts;
}
@@ -311,7 +311,7 @@ public class Doc_MatchPO extends Doc
{
int stdPrecision = MCurrency.getStdPrecision(getCtx(), m_oLine.getC_Currency_ID());
BigDecimal costTax = tax.calculateTax(poCost, true, stdPrecision);
- log.fine("Costs=" + poCost + " - Tax=" + costTax);
+ if (log.isLoggable(Level.FINE)) log.fine("Costs=" + poCost + " - Tax=" + costTax);
poCost = poCost.subtract(costTax);
}
} // correct included Tax
diff --git a/org.adempiere.base/src/org/compiere/acct/Doc_Movement.java b/org.adempiere.base/src/org/compiere/acct/Doc_Movement.java
index 3ee984284e..039ebf82a9 100644
--- a/org.adempiere.base/src/org/compiere/acct/Doc_Movement.java
+++ b/org.adempiere.base/src/org/compiere/acct/Doc_Movement.java
@@ -19,6 +19,7 @@ package org.compiere.acct;
import java.math.BigDecimal;
import java.sql.ResultSet;
import java.util.ArrayList;
+import java.util.logging.Level;
import org.compiere.model.MAcctSchema;
import org.compiere.model.MCostDetail;
@@ -69,7 +70,7 @@ public class Doc_Movement extends Doc
m_DocStatus = move.getDocStatus();
// Contained Objects
p_lines = loadLines(move);
- log.fine("Lines=" + p_lines.length);
+ if (log.isLoggable(Level.FINE)) log.fine("Lines=" + p_lines.length);
return null;
} // loadDocumentDetails
@@ -88,7 +89,7 @@ public class Doc_Movement extends Doc
DocLine docLine = new DocLine (line, this);
docLine.setQty(line.getMovementQty(), false);
docLine.setReversalLine_ID(line.getReversalLine_ID());
- log.fine(docLine.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(docLine.toString());
list.add (docLine);
}
diff --git a/org.adempiere.base/src/org/compiere/acct/Doc_Order.java b/org.adempiere.base/src/org/compiere/acct/Doc_Order.java
index 0fa93b74ce..63ad382edb 100644
--- a/org.adempiere.base/src/org/compiere/acct/Doc_Order.java
+++ b/org.adempiere.base/src/org/compiere/acct/Doc_Order.java
@@ -121,7 +121,7 @@ public class Doc_Order extends Doc
if (!tax.isZeroTax())
{
BigDecimal LineNetAmtTax = tax.calculateTax(LineNetAmt, true, getStdPrecision());
- log.fine("LineNetAmt=" + LineNetAmt + " - Tax=" + LineNetAmtTax);
+ if (log.isLoggable(Level.FINE)) log.fine("LineNetAmt=" + LineNetAmt + " - Tax=" + LineNetAmtTax);
LineNetAmt = LineNetAmt.subtract(LineNetAmtTax);
for (int t = 0; t < m_taxes.length; t++)
{
@@ -311,11 +311,11 @@ public class Doc_Order extends Doc
if (retValue.signum() != 0 // Sum of Cost(vs. Price) in lines may not add up
&& getDocumentType().equals(DOCTYPE_POrder)) // PO
{
- log.fine(toString() + " Balance=" + retValue + sb.toString() + " (ignored)");
+ if (log.isLoggable(Level.FINE)) log.fine(toString() + " Balance=" + retValue + sb.toString() + " (ignored)");
retValue = Env.ZERO;
}
else
- log.fine(toString() + " Balance=" + retValue + sb.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(toString() + " Balance=" + retValue + sb.toString());
return retValue;
} // getBalance
@@ -486,7 +486,7 @@ public class Doc_Order extends Doc
.append(" AND po.M_Product_ID=ol.M_Product_ID AND po.C_BPartner_ID=o.C_BPartner_ID")
.append(" AND o.C_Order_ID=").append(get_ID()).append(")");
int no = DB.executeUpdate(sql.toString(), getTrxName());
- log.fine("Updated=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Updated=" + no);
} // updateProductPO
diff --git a/org.adempiere.base/src/org/compiere/acct/Doc_Production.java b/org.adempiere.base/src/org/compiere/acct/Doc_Production.java
index 8931f8ef0a..febaad86f8 100644
--- a/org.adempiere.base/src/org/compiere/acct/Doc_Production.java
+++ b/org.adempiere.base/src/org/compiere/acct/Doc_Production.java
@@ -66,7 +66,7 @@ public class Doc_Production extends Doc
setDateAcct(prod.getMovementDate());
// Contained Objects
p_lines = loadLines(prod);
- log.fine("Lines=" + p_lines.length);
+ if (log.isLoggable(Level.FINE)) log.fine("Lines=" + p_lines.length);
return null;
} // loadDocumentDetails
@@ -103,7 +103,7 @@ public class Doc_Production extends Doc
// Identify finished BOM Product
docLine.setProductionBOM(line.getM_Product_ID() == prod.getM_Product_ID());
//
- log.fine(docLine.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(docLine.toString());
list.add (docLine);
}
}
diff --git a/org.adempiere.base/src/org/compiere/acct/Doc_ProjectIssue.java b/org.adempiere.base/src/org/compiere/acct/Doc_ProjectIssue.java
index 11ce108a20..31752cda01 100644
--- a/org.adempiere.base/src/org/compiere/acct/Doc_ProjectIssue.java
+++ b/org.adempiere.base/src/org/compiere/acct/Doc_ProjectIssue.java
@@ -75,7 +75,7 @@ public class Doc_ProjectIssue extends Doc
// Pseudo Line Check
if (m_line.getM_Product_ID() == 0)
log.warning(m_line.toString() + " - No Product");
- log.fine(m_line.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(m_line.toString());
return null;
} // loadDocumentDetails
@@ -189,7 +189,7 @@ public class Doc_ProjectIssue extends Doc
if (rs.next())
{
retValue = rs.getBigDecimal(1);
- log.fine("POCost = " + retValue);
+ if (log.isLoggable(Level.FINE)) log.fine("POCost = " + retValue);
}
else
log.warning("Not found for M_InOutLine_ID=" + m_issue.getM_InOutLine_ID());
@@ -232,7 +232,7 @@ public class Doc_ProjectIssue extends Doc
retValue = rs.getBigDecimal(1);
qty = rs.getBigDecimal(2);
retValue = retValue.multiply(qty);
- log.fine("ExpLineCost = " + retValue);
+ if (log.isLoggable(Level.FINE)) log.fine("ExpLineCost = " + retValue);
}
else
log.warning("Not found for S_TimeExpenseLine_ID=" + m_issue.getS_TimeExpenseLine_ID());
diff --git a/org.adempiere.base/src/org/compiere/acct/Fact.java b/org.adempiere.base/src/org/compiere/acct/Fact.java
index 14d5d196b1..2f943e56f7 100644
--- a/org.adempiere.base/src/org/compiere/acct/Fact.java
+++ b/org.adempiere.base/src/org/compiere/acct/Fact.java
@@ -137,11 +137,11 @@ public final class Fact
{
if (docLine == null || docLine.getQty() == null || docLine.getQty().signum() == 0)
{
- log.fine("Both amounts & qty = 0/Null - " + docLine
+ if (log.isLoggable(Level.FINE)) log.fine("Both amounts & qty = 0/Null - " + docLine
+ " - " + toString());
return null;
}
- log.fine("Both amounts = 0/Null, Qty=" + docLine.getQty() + " - " + docLine
+ if (log.isLoggable(Level.FINE)) log.fine("Both amounts = 0/Null, Qty=" + docLine.getQty() + " - " + docLine
+ " - " + toString());
}
// Convert
@@ -151,7 +151,7 @@ public final class Fact
&& (docLine.getAmtAcctDr() != null || docLine.getAmtAcctCr() != null))
line.setAmtAcct(docLine.getAmtAcctDr(), docLine.getAmtAcctCr());
//
- log.fine(line.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(line.toString());
add(line);
return line;
} // createLine
@@ -310,7 +310,7 @@ public final class Fact
// Convert
line.convert();
//
- log.fine(line.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(line.toString());
m_lines.add(line);
return line;
} // balancingSource
@@ -412,7 +412,7 @@ public final class Fact
if (m_lines.size() == 0)
return;
- log.fine ("(" + elementType + ") - " + toString());
+ if (log.isLoggable(Level.FINE)) log.fine ("(" + elementType + ") - " + toString());
// Org
if (elementType.equals(MAcctSchemaElement.ELEMENTTYPE_Organization))
@@ -481,7 +481,7 @@ public final class Fact
line.setAD_Org_ID(key.intValue());
//
m_lines.add(line);
- log.fine("(" + elementType + ") - " + line);
+ if (log.isLoggable(Level.FINE)) log.fine("(" + elementType + ") - " + line);
}
}
map.clear();
@@ -536,7 +536,7 @@ public final class Fact
public FactLine balanceAccounting()
{
BigDecimal diff = getAcctBalance(); // DR-CR
- log.fine("Balance=" + diff
+ if (log.isLoggable(Level.FINE)) log.fine("Balance=" + diff
+ ", CurrBal=" + m_acctSchema.isCurrencyBalancing()
+ " - " + toString());
FactLine line = null;
@@ -598,7 +598,7 @@ public final class Fact
drAmt = difference.negate();
}
line.setAmtAcct(drAmt, crAmt);
- log.fine(line.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(line.toString());
m_lines.add(line);
}
else // Adjust biggest (Balance Sheet) line amount
@@ -611,9 +611,9 @@ public final class Fact
log.severe ("No Line found");
else
{
- log.fine("Adjusting Amt=" + diff + "; Line=" + line);
+ if (log.isLoggable(Level.FINE)) log.fine("Adjusting Amt=" + diff + "; Line=" + line);
line.currencyCorrect(diff);
- log.fine(line.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(line.toString());
}
} // correct biggest amount
diff --git a/org.adempiere.base/src/org/compiere/acct/FactLine.java b/org.adempiere.base/src/org/compiere/acct/FactLine.java
index 6b53664fd0..f7a50dcba8 100644
--- a/org.adempiere.base/src/org/compiere/acct/FactLine.java
+++ b/org.adempiere.base/src/org/compiere/acct/FactLine.java
@@ -653,7 +653,7 @@ public final class FactLine extends X_Fact_Acct
boolean negative = deltaAmount.compareTo(Env.ZERO) < 0;
boolean adjustDr = getAmtAcctDr().abs().compareTo(getAmtAcctCr().abs()) > 0;
- log.fine(deltaAmount.toString()
+ if (log.isLoggable(Level.FINE)) log.fine(deltaAmount.toString()
+ "; Old-AcctDr=" + getAmtAcctDr() + ",AcctCr=" + getAmtAcctCr()
+ "; Negative=" + negative + "; AdjustDr=" + adjustDr);
@@ -668,7 +668,7 @@ public final class FactLine extends X_Fact_Acct
else
setAmtAcctCr (getAmtAcctCr().add(deltaAmount));
- log.fine("New-AcctDr=" + getAmtAcctDr() + ",AcctCr=" + getAmtAcctCr());
+ if (log.isLoggable(Level.FINE)) log.fine("New-AcctDr=" + getAmtAcctDr() + ",AcctCr=" + getAmtAcctCr());
} // currencyCorrect
/**
@@ -859,7 +859,7 @@ public final class FactLine extends X_Fact_Acct
if (super.getC_SalesRegion_ID() != 0) // save in VO
{
m_doc.setBP_C_SalesRegion_ID(super.getC_SalesRegion_ID());
- log.fine("C_SalesRegion_ID=" + super.getC_SalesRegion_ID() + " (from BPL)" );
+ if (log.isLoggable(Level.FINE)) log.fine("C_SalesRegion_ID=" + super.getC_SalesRegion_ID() + " (from BPL)" );
}
else // From Sales Rep of Document -> Sales Region
{
@@ -869,7 +869,7 @@ public final class FactLine extends X_Fact_Acct
if (super.getC_SalesRegion_ID() != 0) // save in VO
{
m_doc.setBP_C_SalesRegion_ID(super.getC_SalesRegion_ID());
- log.fine("C_SalesRegion_ID=" + super.getC_SalesRegion_ID() + " (from SR)" );
+ if (log.isLoggable(Level.FINE)) log.fine("C_SalesRegion_ID=" + super.getC_SalesRegion_ID() + " (from SR)" );
}
else
m_doc.setBP_C_SalesRegion_ID(-2); // don't try again
@@ -896,7 +896,7 @@ public final class FactLine extends X_Fact_Acct
{
if (newRecord)
{
- log.fine(toString());
+ if (log.isLoggable(Level.FINE)) log.fine(toString());
//
getAD_Org_ID();
getC_SalesRegion_ID();
@@ -985,7 +985,7 @@ public final class FactLine extends X_Fact_Acct
int C_Campaign_ID, int C_Activity_ID,
int User1_ID, int User2_ID, int UserElement1_ID, int UserElement2_ID)
{
- log.fine("From Accout_ID=" + Account_ID);
+ if (log.isLoggable(Level.FINE)) log.fine("From Accout_ID=" + Account_ID);
// get VC for P_Revenue (from Product)
MAccount revenue = MAccount.get(getCtx(),
AD_Client_ID, AD_Org_ID, getC_AcctSchema_ID(), Account_ID, C_SubAcct_ID,
@@ -1050,7 +1050,7 @@ public final class FactLine extends X_Fact_Acct
log.severe ("Plan NOT created");
return Account_ID;
}
- log.fine("From Acctount_ID=" + Account_ID + " to " + new_Account_ID
+ if (log.isLoggable(Level.FINE)) log.fine("From Acctount_ID=" + Account_ID + " to " + new_Account_ID
+ " - Plan from UnearnedRevenue_Acct=" + UnearnedRevenue_Acct + " to Revenue_Acct=" + P_Revenue_Acct);
return new_Account_ID;
} // createRevenueRecognition
@@ -1114,7 +1114,7 @@ public final class FactLine extends X_Fact_Acct
// end Bayu Sistematika
//
success = true;
- log.fine(new StringBuilder("(Table=").append(AD_Table_ID)
+ if (log.isLoggable(Level.FINE)) log.fine(new StringBuilder("(Table=").append(AD_Table_ID)
.append(",Record_ID=").append(Record_ID)
.append(",Line=").append(Record_ID)
.append(", Account=").append(m_acct)
diff --git a/org.adempiere.base/src/org/compiere/acct/Matcher.java b/org.adempiere.base/src/org/compiere/acct/Matcher.java
index dd1245e57d..f507f6a51a 100644
--- a/org.adempiere.base/src/org/compiere/acct/Matcher.java
+++ b/org.adempiere.base/src/org/compiere/acct/Matcher.java
@@ -132,7 +132,7 @@ public class Matcher
DB.close(rs, pstmt);
rs = null; pstmt = null;
}
- log.fine("Matcher.match - Client_ID=" + m_AD_Client_ID
+ if (log.isLoggable(Level.FINE)) log.fine("Matcher.match - Client_ID=" + m_AD_Client_ID
+ ", Records created=" + counter);
return counter;
} // match
@@ -152,7 +152,7 @@ public class Matcher
int M_InOutLine_ID, int C_InvoiceLine_ID,
int M_Product_ID, Timestamp DateTrx, BigDecimal Qty)
{
- log.fine("InvLine=" + C_InvoiceLine_ID + ",Rec=" + M_InOutLine_ID + ", Qty=" + Qty + ", " + DateTrx);
+ if (log.isLoggable(Level.FINE)) log.fine("InvLine=" + C_InvoiceLine_ID + ",Rec=" + M_InOutLine_ID + ", Qty=" + Qty + ", " + DateTrx);
// MMatchInv inv = new MMatchInv ();
int M_MatchInv_ID = DB.getNextID (AD_Client_ID, "M_MatchInv", m_trxName);
diff --git a/org.adempiere.base/src/org/compiere/cm/WebProjectDeploy.java b/org.adempiere.base/src/org/compiere/cm/WebProjectDeploy.java
index 10facdb1bc..b7aee9aa88 100644
--- a/org.adempiere.base/src/org/compiere/cm/WebProjectDeploy.java
+++ b/org.adempiere.base/src/org/compiere/cm/WebProjectDeploy.java
@@ -110,7 +110,7 @@ public class WebProjectDeploy extends SvrProcess
{
String name = container.getName();
if (container.delete(true))
- log.fine("Deleted: " + name);
+ if (log.isLoggable(Level.FINE)) log.fine("Deleted: " + name);
else // e.g. was referenced
{
log.warning("Failed Delete: " + name);
diff --git a/org.adempiere.base/src/org/compiere/db/CConnection.java b/org.adempiere.base/src/org/compiere/db/CConnection.java
index 197df7f7cd..fe7ea9ade7 100644
--- a/org.adempiere.base/src/org/compiere/db/CConnection.java
+++ b/org.adempiere.base/src/org/compiere/db/CConnection.java
@@ -98,7 +98,7 @@ public class CConnection implements Serializable, Cloneable
s_cc = new CConnection (null);
s_cc.setAttributes (attributes);
}
- log.fine(s_cc.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(s_cc.toString());
}
return s_cc;
diff --git a/org.adempiere.base/src/org/compiere/db/StatementProxy.java b/org.adempiere.base/src/org/compiere/db/StatementProxy.java
index 1a1cc5a7cc..f3cc7af0e9 100644
--- a/org.adempiere.base/src/org/compiere/db/StatementProxy.java
+++ b/org.adempiere.base/src/org/compiere/db/StatementProxy.java
@@ -115,7 +115,7 @@ public class StatementProxy implements InvocationHandler {
}
if (logOperation != null) {
logSql = logSql.substring(0, logSql.indexOf(' '));
- log.fine((DisplayType.getDateFormat(DisplayType.DateTime)).format(new Date(System.currentTimeMillis()))+","+logOperation+","+logSql+","+(p_vo.getTrxName() != null ? p_vo.getTrxName() : "")+" (begin)");
+ if (log.isLoggable(Level.FINE)) log.fine((DisplayType.getDateFormat(DisplayType.DateTime)).format(new Date(System.currentTimeMillis()))+","+logOperation+","+logSql+","+(p_vo.getTrxName() != null ? p_vo.getTrxName() : "")+" (begin)");
}
}
}
diff --git a/org.adempiere.base/src/org/compiere/dbPort/Convert.java b/org.adempiere.base/src/org/compiere/dbPort/Convert.java
index 91f9d23d6b..11069502c2 100644
--- a/org.adempiere.base/src/org/compiere/dbPort/Convert.java
+++ b/org.adempiere.base/src/org/compiere/dbPort/Convert.java
@@ -148,7 +148,7 @@ public abstract class Convert
}
}
if (m_verbose)
- log.fine("- ok " + no);
+ if (log.isLoggable(Level.FINE)) log.fine("- ok " + no);
}
catch (SQLException ex)
{
diff --git a/org.adempiere.base/src/org/compiere/impexp/ImpFormat.java b/org.adempiere.base/src/org/compiere/impexp/ImpFormat.java
index b9dc578241..6ab5159777 100644
--- a/org.adempiere.base/src/org/compiere/impexp/ImpFormat.java
+++ b/org.adempiere.base/src/org/compiere/impexp/ImpFormat.java
@@ -414,7 +414,7 @@ public final class ImpFormat
list.add(entry.toString());
//
if (trace)
- log.fine(info + "=>" + entry.toString() + " (Length=" + info.length() + ")");
+ if (log.isLoggable(Level.FINE)) log.fine(info + "=>" + entry.toString() + " (Length=" + info.length() + ")");
} // for all columns
String[] retValue = new String[list.size()];
diff --git a/org.adempiere.base/src/org/compiere/model/AccessSqlParser.java b/org.adempiere.base/src/org/compiere/model/AccessSqlParser.java
index 9b11a5b45b..f1c8cbb8e0 100644
--- a/org.adempiere.base/src/org/compiere/model/AccessSqlParser.java
+++ b/org.adempiere.base/src/org/compiere/model/AccessSqlParser.java
@@ -20,7 +20,6 @@ import java.util.ArrayList;
import java.util.StringTokenizer;
import java.util.logging.Level;
-import org.compiere.util.CLogMgt;
import org.compiere.util.CLogger;
/**
@@ -117,8 +116,7 @@ public class AccessSqlParser
m_tableInfo.add(info);
}
//
- if (CLogMgt.isLevelFinest())
- log.fine(toString());
+ if (log.isLoggable(Level.FINE)) log.fine(toString());
return m_tableInfo.size() > 0;
} // parse
diff --git a/org.adempiere.base/src/org/compiere/model/ArchiveDB.java b/org.adempiere.base/src/org/compiere/model/ArchiveDB.java
index 56b45b3234..a55ceae167 100644
--- a/org.adempiere.base/src/org/compiere/model/ArchiveDB.java
+++ b/org.adempiere.base/src/org/compiere/model/ArchiveDB.java
@@ -41,7 +41,7 @@ public class ArchiveDB implements IArchiveStore {
if (deflatedData == null)
return null;
//
- log.fine("ZipSize=" + deflatedData.length);
+ if (log.isLoggable(Level.FINE)) log.fine("ZipSize=" + deflatedData.length);
if (deflatedData.length == 0)
return null;
@@ -61,7 +61,7 @@ public class ArchiveDB implements IArchiveStore {
}
//
inflatedData = out.toByteArray();
- log.fine("Size=" + inflatedData.length + " - zip=" + entry.getCompressedSize()
+ if (log.isLoggable(Level.FINE)) log.fine("Size=" + inflatedData.length + " - zip=" + entry.getCompressedSize()
+ "(" + entry.getSize() + ") "
+ (entry.getCompressedSize() * 100 / entry.getSize()) + "%");
}
@@ -93,13 +93,13 @@ public class ArchiveDB implements IArchiveStore {
zip.putNextEntry(entry);
zip.write(inflatedData, 0, inflatedData.length);
zip.closeEntry();
- log.fine(entry.getCompressedSize() + " (" + entry.getSize() + ") "
+ if (log.isLoggable(Level.FINE)) log.fine(entry.getCompressedSize() + " (" + entry.getSize() + ") "
+ (entry.getCompressedSize() * 100 / entry.getSize()) + "%");
//
// zip.finish();
zip.close();
deflatedData = out.toByteArray();
- log.fine("Length=" + inflatedData.length);
+ if (log.isLoggable(Level.FINE)) log.fine("Length=" + inflatedData.length);
} catch (Exception e) {
log.log(Level.SEVERE, "saveLOBData", e);
deflatedData = null;
diff --git a/org.adempiere.base/src/org/compiere/model/ArchiveFileSystem.java b/org.adempiere.base/src/org/compiere/model/ArchiveFileSystem.java
index 172a1353dc..07dd848e90 100644
--- a/org.adempiere.base/src/org/compiere/model/ArchiveFileSystem.java
+++ b/org.adempiere.base/src/org/compiere/model/ArchiveFileSystem.java
@@ -85,7 +85,7 @@ public class ArchiveFileSystem implements IArchiveStore {
return null;
}
String filePath = fileNode.getNodeValue();
- log.fine("filePath: " + filePath);
+ if (log.isLoggable(Level.FINE)) log.fine("filePath: " + filePath);
if(filePath!=null){
filePath = filePath.replaceFirst(ARCHIVE_FOLDER_PLACEHOLDER, archivePathRoot.replaceAll("\\\\","\\\\\\\\"));
//just to be shure...
@@ -96,7 +96,7 @@ public class ArchiveFileSystem implements IArchiveStore {
filePath = filePath.replaceAll("/", replaceSeparator);
filePath = filePath.replaceAll("\\\\", replaceSeparator);
}
- log.fine("filePath: " + filePath);
+ if (log.isLoggable(Level.FINE)) log.fine("filePath: " + filePath);
final File file = new File(filePath);
if (file.exists()) {
// read files into byte[]
@@ -196,7 +196,7 @@ public class ArchiveFileSystem implements IArchiveStore {
final Transformer xformer = TransformerFactory.newInstance().newTransformer();
xformer.transform(source, result);
final byte[] xmlData = bos.toByteArray();
- log.fine(bos.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(bos.toString());
//store xml in db
archive.setByteData(xmlData);
diff --git a/org.adempiere.base/src/org/compiere/model/AttachmentDBSystem.java b/org.adempiere.base/src/org/compiere/model/AttachmentDBSystem.java
index 31426df03c..d0abc43b73 100644
--- a/org.adempiere.base/src/org/compiere/model/AttachmentDBSystem.java
+++ b/org.adempiere.base/src/org/compiere/model/AttachmentDBSystem.java
@@ -41,7 +41,7 @@ public class AttachmentDBSystem implements IAttachmentStore
byte[] data = attach.getBinaryData();
if (data == null)
return true;
- log.fine("ZipSize=" + data.length);
+ if (log.isLoggable(Level.FINE)) log.fine("ZipSize=" + data.length);
if (data.length == 0)
return true;
@@ -70,7 +70,7 @@ public class AttachmentDBSystem implements IAttachmentStore
}
//
byte[] dataEntry = out.toByteArray();
- log.fine(name
+ if (log.isLoggable(Level.FINE)) log.fine(name
+ " - size=" + dataEntry.length + " - zip="
+ entry.getCompressedSize() + "(" + entry.getSize() + ") "
+ (entry.getCompressedSize()*100/entry.getSize())+ "%");
@@ -113,14 +113,14 @@ public class AttachmentDBSystem implements IAttachmentStore
byte[] data = item.getData();
zip.write (data, 0, data.length);
zip.closeEntry();
- log.fine(entry.getName() + " - "
+ if (log.isLoggable(Level.FINE)) log.fine(entry.getName() + " - "
+ entry.getCompressedSize() + " (" + entry.getSize() + ") "
+ (entry.getCompressedSize()*100/entry.getSize())+ "%");
}
// zip.finish();
zip.close();
byte[] zipData = out.toByteArray();
- log.fine("Length=" + zipData.length);
+ if (log.isLoggable(Level.FINE)) log.fine("Length=" + zipData.length);
attach.setBinaryData(zipData);
attach.setTitle(MAttachment.ZIP);
return true;
diff --git a/org.adempiere.base/src/org/compiere/model/AttachmentFileSystem.java b/org.adempiere.base/src/org/compiere/model/AttachmentFileSystem.java
index d64800747c..0b06fae312 100644
--- a/org.adempiere.base/src/org/compiere/model/AttachmentFileSystem.java
+++ b/org.adempiere.base/src/org/compiere/model/AttachmentFileSystem.java
@@ -67,13 +67,13 @@ public class AttachmentFileSystem implements IAttachmentStore {
document.setXmlStandalone(true);
// create xml entries
for (int i = 0; i < attach.m_items.size(); i++) {
- log.fine(attach.m_items.get(i).toString());
+ if (log.isLoggable(Level.FINE)) log.fine(attach.m_items.get(i).toString());
File entryFile = attach.m_items.get(i).getFile();
final String path = entryFile.getAbsolutePath();
// if local file - copy to central attachment folder
- log.fine(path + " - " + attachmentPathRoot);
+ if (log.isLoggable(Level.FINE)) log.fine(path + " - " + attachmentPathRoot);
if (!path.startsWith(attachmentPathRoot)) {
- log.fine("move file: " + path);
+ if (log.isLoggable(Level.FINE)) log.fine("move file: " + path);
FileChannel in = null;
FileChannel out = null;
try {
@@ -130,7 +130,7 @@ public class AttachmentFileSystem implements IAttachmentStore {
final Transformer xformer = TransformerFactory.newInstance().newTransformer();
xformer.transform(source, result);
final byte[] xmlData = bos.toByteArray();
- log.fine(bos.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(bos.toString());
attach.setBinaryData(xmlData);
attach.setTitle(MAttachment.XML);
return true;
@@ -155,7 +155,7 @@ public class AttachmentFileSystem implements IAttachmentStore {
byte[] data = attach.getBinaryData();
if (data == null)
return true;
- log.fine("TextFileSize=" + data.length);
+ if (log.isLoggable(Level.FINE)) log.fine("TextFileSize=" + data.length);
if (data.length == 0)
return true;
@@ -175,9 +175,9 @@ public class AttachmentFileSystem implements IAttachmentStore {
attach.m_items = null;
return false;
}
- log.fine("name: " + nameNode.getNodeValue());
+ if (log.isLoggable(Level.FINE)) log.fine("name: " + nameNode.getNodeValue());
String filePath = fileNode.getNodeValue();
- log.fine("filePath: " + filePath);
+ if (log.isLoggable(Level.FINE)) log.fine("filePath: " + filePath);
if(filePath!=null){
filePath = filePath.replaceFirst(attach.ATTACHMENT_FOLDER_PLACEHOLDER, attachmentPathRoot.replaceAll("\\\\","\\\\\\\\"));
//just to be shure...
@@ -188,7 +188,7 @@ public class AttachmentFileSystem implements IAttachmentStore {
filePath = filePath.replaceAll("/", replaceSeparator);
filePath = filePath.replaceAll("\\\\", replaceSeparator);
}
- log.fine("filePath: " + filePath);
+ if (log.isLoggable(Level.FINE)) log.fine("filePath: " + filePath);
final File file = new File(filePath);
if (file.exists()) {
// read files into byte[]
@@ -273,7 +273,7 @@ public class AttachmentFileSystem implements IAttachmentStore {
//remove files
final MAttachmentEntry entry = attach.m_items.get(index);
final File file = entry.getFile();
- log.fine("delete: " + file.getAbsolutePath());
+ if (log.isLoggable(Level.FINE)) log.fine("delete: " + file.getAbsolutePath());
if (file != null && file.exists()) {
if (!file.delete()) {
log.warning("unable to delete " + file.getAbsolutePath());
diff --git a/org.adempiere.base/src/org/compiere/model/GridField.java b/org.adempiere.base/src/org/compiere/model/GridField.java
index e7146982fe..21dbb5c54f 100644
--- a/org.adempiere.base/src/org/compiere/model/GridField.java
+++ b/org.adempiere.base/src/org/compiere/model/GridField.java
@@ -274,7 +274,7 @@ public class GridField
if (m_lookup == null || m_lookup.getValidation().length() == 0)
return true;
//
- log.fine("(" + m_vo.ColumnName + ")");
+ if (log.isLoggable(Level.FINE)) log.fine("(" + m_vo.ColumnName + ")");
m_lookup.refresh();
return m_lookup.isValidated();
} // refreshLookup
@@ -539,13 +539,13 @@ public class GridField
&& (m_vo.DefaultValue == null || m_vo.DefaultValue.length() == 0))
{
String parent = Env.getContext(m_vo.ctx, m_vo.WindowNo, m_vo.ColumnName);
- log.fine("[Parent] " + m_vo.ColumnName + "=" + parent);
+ if (log.isLoggable(Level.FINE)) log.fine("[Parent] " + m_vo.ColumnName + "=" + parent);
return createDefault(parent);
}
// Always Active
if (m_vo.ColumnName.equals("IsActive"))
{
- log.fine("[IsActive] " + m_vo.ColumnName + "=Y");
+ if (log.isLoggable(Level.FINE)) log.fine("[IsActive] " + m_vo.ColumnName + "=Y");
return "Y";
}
@@ -553,14 +553,14 @@ public class GridField
if (X_AD_Table.ACCESSLEVEL_SystemOnly.equals(Env.getContext(m_vo.ctx, m_vo.WindowNo, m_vo.TabNo, GridTab.CTX_AccessLevel))
&& (m_vo.ColumnName.equals("AD_Client_ID") || m_vo.ColumnName.equals("AD_Org_ID")))
{
- log.fine("[SystemAccess] " + m_vo.ColumnName + "=0");
+ if (log.isLoggable(Level.FINE)) log.fine("[SystemAccess] " + m_vo.ColumnName + "=0");
return new Integer(0);
}
// Set Org to System, if Client access
else if (X_AD_Table.ACCESSLEVEL_SystemPlusClient.equals(Env.getContext(m_vo.ctx, m_vo.WindowNo, m_vo.TabNo, GridTab.CTX_AccessLevel))
&& m_vo.ColumnName.equals("AD_Org_ID"))
{
- log.fine("[ClientAccess] " + m_vo.ColumnName + "=0");
+ if (log.isLoggable(Level.FINE)) log.fine("[ClientAccess] " + m_vo.ColumnName + "=0");
return new Integer(0);
}
@@ -605,7 +605,7 @@ public class GridField
}
if (defStr != null && defStr.length() > 0)
{
- log.fine("[SQL] " + m_vo.ColumnName + "=" + defStr);
+ if (log.isLoggable(Level.FINE)) log.fine("[SQL] " + m_vo.ColumnName + "=" + defStr);
return createDefault(defStr);
}
} // SQL Statement
@@ -630,7 +630,7 @@ public class GridField
if (!defStr.equals(""))
{
- log.fine("[DefaultValue] " + m_vo.ColumnName + "=" + defStr);
+ if (log.isLoggable(Level.FINE)) log.fine("[DefaultValue] " + m_vo.ColumnName + "=" + defStr);
return createDefault(defStr);
}
} // while more Tokens
@@ -642,7 +642,7 @@ public class GridField
defStr = Env.getPreference (m_vo.ctx, m_vo.AD_Window_ID, m_vo.ColumnName, false);
if (!defStr.equals(""))
{
- log.fine("[UserPreference] " + m_vo.ColumnName + "=" + defStr);
+ if (log.isLoggable(Level.FINE)) log.fine("[UserPreference] " + m_vo.ColumnName + "=" + defStr);
return createDefault(defStr);
}
@@ -652,7 +652,7 @@ public class GridField
defStr = Env.getPreference (m_vo.ctx, m_vo.AD_Window_ID, m_vo.ColumnName, true);
if (!defStr.equals(""))
{
- log.fine("[SystemPreference] " + m_vo.ColumnName + "=" + defStr);
+ if (log.isLoggable(Level.FINE)) log.fine("[SystemPreference] " + m_vo.ColumnName + "=" + defStr);
return createDefault(defStr);
}
@@ -663,13 +663,13 @@ public class GridField
// Button to N
if (m_vo.displayType == DisplayType.Button && !m_vo.ColumnName.endsWith("_ID"))
{
- log.fine("[Button=N] " + m_vo.ColumnName);
+ if (log.isLoggable(Level.FINE)) log.fine("[Button=N] " + m_vo.ColumnName);
return "N";
}
// CheckBoxes default to No
if (m_vo.displayType == DisplayType.YesNo)
{
- log.fine("[YesNo=N] " + m_vo.ColumnName);
+ if (log.isLoggable(Level.FINE)) log.fine("[YesNo=N] " + m_vo.ColumnName);
return "N";
}
// lookups with one value
@@ -680,20 +680,20 @@ public class GridField
// IDs remain null
if (m_vo.ColumnName.endsWith("_ID"))
{
- log.fine("[ID=null] " + m_vo.ColumnName);
+ if (log.isLoggable(Level.FINE)) log.fine("[ID=null] " + m_vo.ColumnName);
return null;
}
// actual Numbers default to zero
if (DisplayType.isNumeric(m_vo.displayType))
{
- log.fine("[Number=0] " + m_vo.ColumnName);
+ if (log.isLoggable(Level.FINE)) log.fine("[Number=0] " + m_vo.ColumnName);
return createDefault("0");
}
/**
* No resolution
*/
- log.fine("[NONE] " + m_vo.ColumnName);
+ if (log.isLoggable(Level.FINE)) log.fine("[NONE] " + m_vo.ColumnName);
return null;
} // getDefault
diff --git a/org.adempiere.base/src/org/compiere/model/GridTab.java b/org.adempiere.base/src/org/compiere/model/GridTab.java
index 6c2bbd5c27..04a049ca6a 100644
--- a/org.adempiere.base/src/org/compiere/model/GridTab.java
+++ b/org.adempiere.base/src/org/compiere/model/GridTab.java
@@ -272,7 +272,7 @@ public class GridTab implements DataStatusListener, Evaluatee, Serializable
*/
public boolean initTab (boolean async)
{
- log.fine("#" + m_vo.TabNo + " - Async=" + async + " - Where=" + m_vo.WhereClause);
+ if (log.isLoggable(Level.FINE)) log.fine("#" + m_vo.TabNo + " - Async=" + async + " - Where=" + m_vo.WhereClause);
if (isLoadComplete()) return true;
if (m_loaderFuture != null && m_loaderFuture.isDone())
@@ -318,7 +318,7 @@ public class GridTab implements DataStatusListener, Evaluatee, Serializable
*/
protected void dispose()
{
- log.fine("#" + m_vo.TabNo);
+ if (log.isLoggable(Level.FINE)) log.fine("#" + m_vo.TabNo);
m_OrderBys = null;
//
m_parents.clear();
@@ -352,7 +352,7 @@ public class GridTab implements DataStatusListener, Evaluatee, Serializable
*/
private boolean loadFields()
{
- log.fine("#" + m_vo.TabNo);
+ if (log.isLoggable(Level.FINE)) log.fine("#" + m_vo.TabNo);
if (m_vo.getFields() == null)
return false;
@@ -616,7 +616,7 @@ public class GridTab implements DataStatusListener, Evaluatee, Serializable
Env.clearTabContext(m_vo.ctx, m_vo.WindowNo, m_vo.TabNo);
- log.fine("#" + m_vo.TabNo
+ if (log.isLoggable(Level.FINE)) log.fine("#" + m_vo.TabNo
+ " - Only Current Rows=" + onlyCurrentRows
+ ", Days=" + onlyCurrentDays + ", Detail=" + isDetail());
// is it same query?
@@ -730,7 +730,7 @@ public class GridTab implements DataStatusListener, Evaluatee, Serializable
/**
* Query
*/
- log.fine("#" + m_vo.TabNo + " - " + where);
+ if (log.isLoggable(Level.FINE)) log.fine("#" + m_vo.TabNo + " - " + where);
if (m_mTable.isOpen())
{
if (refresh)
@@ -761,20 +761,20 @@ public class GridTab implements DataStatusListener, Evaluatee, Serializable
// Check: only one restriction
if (query.getRestrictionCount() != 1)
{
- log.fine("Ignored(More than 1 Restriction): " + query);
+ if (log.isLoggable(Level.FINE)) log.fine("Ignored(More than 1 Restriction): " + query);
return query.getWhereClause();
}
String colName = query.getColumnName(0);
if (colName == null)
{
- log.fine("Ignored(No Column): " + query);
+ if (log.isLoggable(Level.FINE)) log.fine("Ignored(No Column): " + query);
return query.getWhereClause();
}
// a '(' in the name = function - don't try to resolve
if (colName.indexOf('(') != -1)
{
- log.fine("Ignored(Function): " + colName);
+ if (log.isLoggable(Level.FINE)) log.fine("Ignored(Function): " + colName);
return query.getWhereClause();
}
// OK - Query is valid
@@ -782,7 +782,7 @@ public class GridTab implements DataStatusListener, Evaluatee, Serializable
// Simple Query.
if (getField(colName) != null)
{
- log.fine("Field Found: " + colName);
+ if (log.isLoggable(Level.FINE)) log.fine("Field Found: " + colName);
return query.getWhereClause();
}
@@ -821,7 +821,7 @@ public class GridTab implements DataStatusListener, Evaluatee, Serializable
query.setColumnName(0, refColName);
if (getField(refColName) != null)
{
- log.fine("Column " + colName + " replaced with " + refColName);
+ if (log.isLoggable(Level.FINE)) log.fine("Column " + colName + " replaced with " + refColName);
return query.getWhereClause();
}
colName = refColName;
@@ -885,7 +885,7 @@ public class GridTab implements DataStatusListener, Evaluatee, Serializable
.append(tableName).append(" xx WHERE ")
.append(query.getWhereClause(true))
.append(")");
- log.fine(result.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(result.toString());
return result.toString();
} // validateQuery
@@ -913,7 +913,7 @@ public class GridTab implements DataStatusListener, Evaluatee, Serializable
*/
public void dataRefreshAll (boolean fireEvent, boolean retainedCurrentRow)
{
- log.fine("#" + m_vo.TabNo);
+ if (log.isLoggable(Level.FINE)) log.fine("#" + m_vo.TabNo);
/** @todo does not work with alpha key */
int keyNo = m_mTable.getKeyID(m_currentRow);
m_mTable.dataRefreshAll(fireEvent, retainedCurrentRow ? m_currentRow : -1);
@@ -971,7 +971,7 @@ public class GridTab implements DataStatusListener, Evaluatee, Serializable
*/
public void dataRefresh (int row, boolean fireEvent)
{
- log.fine("#" + m_vo.TabNo + " - row=" + row);
+ if (log.isLoggable(Level.FINE)) log.fine("#" + m_vo.TabNo + " - row=" + row);
m_mTable.dataRefresh(row, fireEvent);
setCurrentRow(row, fireEvent);
if (fireEvent)
@@ -986,7 +986,7 @@ public class GridTab implements DataStatusListener, Evaluatee, Serializable
*/
public boolean dataSave(boolean manualCmd)
{
- log.fine("#" + m_vo.TabNo + " - row=" + m_currentRow);
+ if (log.isLoggable(Level.FINE)) log.fine("#" + m_vo.TabNo + " - row=" + m_currentRow);
try
{
if (hasChangedCurrentTabAndParents())
@@ -1104,7 +1104,7 @@ public class GridTab implements DataStatusListener, Evaluatee, Serializable
*/
public void dataIgnore()
{
- log.fine("#" + m_vo.TabNo);
+ if (log.isLoggable(Level.FINE)) log.fine("#" + m_vo.TabNo);
if (m_mTable.isInserting())
{
m_currentRow--;
@@ -1113,7 +1113,7 @@ public class GridTab implements DataStatusListener, Evaluatee, Serializable
setCurrentRow(m_currentRow, false); // re-load data
fireStateChangeEvent(new StateChangeEvent(this, StateChangeEvent.DATA_IGNORE));
- log.fine("#" + m_vo.TabNo + "- fini");
+ if (log.isLoggable(Level.FINE)) log.fine("#" + m_vo.TabNo + "- fini");
} // dataIgnore
@@ -1125,7 +1125,7 @@ public class GridTab implements DataStatusListener, Evaluatee, Serializable
*/
public boolean dataNew (boolean copy)
{
- log.fine("#" + m_vo.TabNo);
+ if (log.isLoggable(Level.FINE)) log.fine("#" + m_vo.TabNo);
if (!isInsertRecord())
{
log.warning ("Inset Not allowed in TabNo=" + m_vo.TabNo);
@@ -1182,7 +1182,7 @@ public class GridTab implements DataStatusListener, Evaluatee, Serializable
*/
public boolean dataDelete()
{
- log.fine("#" + m_vo.TabNo + " - row=" + m_currentRow);
+ if (log.isLoggable(Level.FINE)) log.fine("#" + m_vo.TabNo + " - row=" + m_currentRow);
boolean retValue = m_mTable.dataDelete(m_currentRow);
setCurrentRow(m_currentRow, true);
fireStateChangeEvent(new StateChangeEvent(this, StateChangeEvent.DATA_DELETE));
@@ -1319,7 +1319,7 @@ public class GridTab implements DataStatusListener, Evaluatee, Serializable
rs = null;
pstmt = null;
}
- log.fine("AD_Column_ID=" + m_vo.AD_Column_ID + " - " + m_linkColumnName);
+ if (log.isLoggable(Level.FINE)) log.fine("AD_Column_ID=" + m_vo.AD_Column_ID + " - " + m_linkColumnName);
}
}
Env.setContext(m_vo.ctx, m_vo.WindowNo, m_vo.TabNo, CTX_LinkColumnName, m_linkColumnName);
@@ -1418,7 +1418,7 @@ public class GridTab implements DataStatusListener, Evaluatee, Serializable
*/
/*private int getTreeID()
{
- log.fine(m_vo.TableName);
+ if (log.isLoggable(Level.FINE)) log.fine(m_vo.TableName);
String SQL = "SELECT * FROM AD_ClientInfo WHERE AD_Client="
+ Env.getContext(m_vo.ctx, m_vo.WindowNo, "AD_Client_ID")
+ " ORDER BY AD_Org DESC";
@@ -1747,7 +1747,7 @@ public class GridTab implements DataStatusListener, Evaluatee, Serializable
if (m_vo.TableName.startsWith("C_InvoiceBatch"))
{
int Record_ID = Env.getContextAsInt(m_vo.ctx, m_vo.WindowNo, "C_InvoiceBatch_ID");
- log.fine(m_vo.TableName + " - " + Record_ID);
+ if (log.isLoggable(Level.FINE)) log.fine(m_vo.TableName + " - " + Record_ID);
MessageFormat mf = null;
try
{
@@ -1836,7 +1836,7 @@ public class GridTab implements DataStatusListener, Evaluatee, Serializable
}
sql.append("GROUP BY o.C_Currency_ID, c.ISO_Code, o.TotalLines, o.GrandTotal, o.DateAcct, o.AD_Client_ID, o.AD_Org_ID");
- log.fine(m_vo.TableName + " - " + Record_ID);
+ if (log.isLoggable(Level.FINE)) log.fine(m_vo.TableName + " - " + Record_ID);
MessageFormat mf = null;
try
{
@@ -1907,7 +1907,7 @@ public class GridTab implements DataStatusListener, Evaluatee, Serializable
else if (m_vo.TableName.startsWith("S_TimeExpense") && m_vo.TabNo == 0)
{
int Record_ID = Env.getContextAsInt(m_vo.ctx, m_vo.WindowNo, "S_TimeExpense_ID");
- log.fine(m_vo.TableName + " - " + Record_ID);
+ if (log.isLoggable(Level.FINE)) log.fine(m_vo.TableName + " - " + Record_ID);
MessageFormat mf = null;
try
{
@@ -2108,7 +2108,7 @@ public class GridTab implements DataStatusListener, Evaluatee, Serializable
public void loadLocks()
{
int AD_User_ID = Env.getContextAsInt(Env.getCtx(), "#AD_User_ID");
- log.fine("#" + m_vo.TabNo + " - AD_User_ID=" + AD_User_ID);
+ if (log.isLoggable(Level.FINE)) log.fine("#" + m_vo.TabNo + " - AD_User_ID=" + AD_User_ID);
if (!canHaveAttachment())
return;
@@ -2144,7 +2144,7 @@ public class GridTab implements DataStatusListener, Evaluatee, Serializable
rs = null;
pstmt = null;
}
- log.fine("#" + m_Lock.size());
+ if (log.isLoggable(Level.FINE)) log.fine("#" + m_Lock.size());
} // loadLooks
/**
@@ -2173,7 +2173,7 @@ public class GridTab implements DataStatusListener, Evaluatee, Serializable
public void lock (Properties ctx, int Record_ID, boolean lock)
{
int AD_User_ID = Env.getContextAsInt(ctx, "#AD_User_ID");
- log.fine("Lock=" + lock + ", AD_User_ID=" + AD_User_ID
+ if (log.isLoggable(Level.FINE)) log.fine("Lock=" + lock + ", AD_User_ID=" + AD_User_ID
+ ", AD_Table_ID=" + m_vo.AD_Table_ID + ", Record_ID=" + Record_ID);
MPrivateAccess access = MPrivateAccess.get (ctx, AD_User_ID, m_vo.AD_Table_ID, Record_ID);
if (access == null)
@@ -2194,7 +2194,7 @@ public class GridTab implements DataStatusListener, Evaluatee, Serializable
*/
public void dataStatusChanged (DataStatusEvent e)
{
- log.fine("#" + m_vo.TabNo + " - " + e.toString());
+ if (log.isLoggable(Level.FINE)) log.fine("#" + m_vo.TabNo + " - " + e.toString());
int oldCurrentRow = e.getCurrentRow();
m_DataStatusEvent = e; // save it
// when sorted set current row to 0
@@ -2233,7 +2233,7 @@ public class GridTab implements DataStatusListener, Evaluatee, Serializable
DataStatusListener[] listeners = m_listenerList.getListeners(DataStatusListener.class);
if (listeners.length == 0)
return;
- log.fine(e.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(e.toString());
// WHO Info
if (e.getCurrentRow() >= 0)
{
@@ -2410,7 +2410,7 @@ public class GridTab implements DataStatusListener, Evaluatee, Serializable
if (newRow >= rows)
{
newRow = rows-1;
- log.fine("Set to max Row: " + newRow);
+ if (log.isLoggable(Level.FINE)) log.fine("Set to max Row: " + newRow);
}
else if (newRow < 0)
{
@@ -2433,7 +2433,7 @@ public class GridTab implements DataStatusListener, Evaluatee, Serializable
{
int oldCurrentRow = m_currentRow;
m_currentRow = verifyRow (newCurrentRow);
- log.fine("Row=" + m_currentRow + " - fire=" + fireEvents);
+ if (log.isLoggable(Level.FINE)) log.fine("Row=" + m_currentRow + " - fire=" + fireEvents);
// Update Field Values
int size = m_mTable.getColumnCount();
@@ -2592,7 +2592,7 @@ public class GridTab implements DataStatusListener, Evaluatee, Serializable
if (field == null)
return "NoField";
- log.fine(field.getColumnName() + "=" + value + " - Row=" + m_currentRow);
+ if (log.isLoggable(Level.FINE)) log.fine(field.getColumnName() + "=" + value + " - Row=" + m_currentRow);
if (DisplayType.isID(field.getDisplayType()) && value instanceof Integer && ((Integer)value).intValue() < 0)
value = null;
@@ -2662,7 +2662,7 @@ public class GridTab implements DataStatusListener, Evaluatee, Serializable
// if the lookup is dynamic (i.e. contains this columnName as variable)
if (mLookup.getValidation().indexOf("@"+columnName+"@") != -1)
{
- log.fine(columnName + " changed - "
+ if (log.isLoggable(Level.FINE)) log.fine(columnName + " changed - "
+ dependentField.getColumnName() + " set to null");
// invalidate current selection
setValue(dependentField, null);
@@ -2754,7 +2754,7 @@ public class GridTab implements DataStatusListener, Evaluatee, Serializable
if (callout.length() == 0)
return "";
- log.fine(field.getColumnName() + "=" + value
+ if (log.isLoggable(Level.FINE)) log.fine(field.getColumnName() + "=" + value
+ " (" + callout + ") - old=" + oldValue);
StringTokenizer st = new StringTokenizer(callout, ";,", false);
@@ -3023,7 +3023,7 @@ public class GridTab implements DataStatusListener, Evaluatee, Serializable
* @param ascending sorting modus
*/
public void switchRows(int from, int to, int sortColumn, boolean ascending) {
- log.fine(from + " - " + to + " - " + sortColumn + " - " + ascending);
+ if (log.isLoggable(Level.FINE)) log.fine(from + " - " + to + " - " + sortColumn + " - " + ascending);
// nothing to do
if (from == to) {
log.finest("nothing to do - from == to");
diff --git a/org.adempiere.base/src/org/compiere/model/GridTable.java b/org.adempiere.base/src/org/compiere/model/GridTable.java
index 28bbdfd135..d897277ef9 100644
--- a/org.adempiere.base/src/org/compiere/model/GridTable.java
+++ b/org.adempiere.base/src/org/compiere/model/GridTable.java
@@ -48,7 +48,6 @@ import javax.swing.table.AbstractTableModel;
import org.adempiere.exceptions.DBException;
import org.adempiere.util.ServerContext;
import org.compiere.Adempiere;
-import org.compiere.util.CLogMgt;
import org.compiere.util.CLogger;
import org.compiere.util.DB;
import org.compiere.util.DisplayType;
@@ -420,7 +419,7 @@ public class GridTable extends AbstractTableModel
*/
public void addField (GridField field)
{
- log.fine("(" + m_tableName + ") - " + field.getColumnName());
+ if (log.isLoggable(Level.FINE)) log.fine("(" + m_tableName + ") - " + field.getColumnName());
if (m_open)
{
log.log(Level.SEVERE, "Table already open - ignored: " + field.getColumnName());
@@ -428,7 +427,7 @@ public class GridTable extends AbstractTableModel
}
if (!MRole.getDefault(m_ctx, false).isColumnAccess (m_AD_Table_ID, field.getAD_Column_ID(), true))
{
- log.fine("No Column Access " + field.getColumnName());
+ if (log.isLoggable(Level.FINE)) log.fine("No Column Access " + field.getColumnName());
return;
}
// Set Index for Key column
@@ -726,7 +725,7 @@ public class GridTable extends AbstractTableModel
{
if (!m_open)
return;
- log.fine("final=" + finalCall);
+ if (log.isLoggable(Level.FINE)) log.fine("final=" + finalCall);
// remove listeners
if (finalCall)
@@ -1029,7 +1028,7 @@ public class GridTable extends AbstractTableModel
//wait for 30 seconds
while (row >= m_sort.size() && m_loaderFuture != null && !m_loaderFuture.isDone() && loops < 60)
{
- log.fine("Waiting for loader row=" + row + ", size=" + m_sort.size());
+ if (log.isLoggable(Level.FINE)) log.fine("Waiting for loader row=" + row + ", size=" + m_sort.size());
try
{
m_loaderFuture.get(500, TimeUnit.MILLISECONDS);
@@ -1224,7 +1223,7 @@ public class GridTable extends AbstractTableModel
return;
}
- log.fine("r=" + row + " c=" + col + " = " + value + " (" + oldValue + ")");
+ if (log.isLoggable(Level.FINE)) log.fine("r=" + row + " c=" + col + " = " + value + " (" + oldValue + ")");
// Save old value
m_oldValue = new Object[3];
@@ -1365,7 +1364,7 @@ public class GridTable extends AbstractTableModel
*/
public boolean dataSave (int newRow, boolean manualCmd)
{
- log.fine("Row=" + newRow +
+ if (log.isLoggable(Level.FINE)) log.fine("Row=" + newRow +
", Changed=" + m_rowChanged + "/" + m_changed); // m_rowChanged set in setValueAt
// nothing done
if (!m_changed && m_rowChanged == -1)
@@ -1569,7 +1568,7 @@ public class GridTable extends AbstractTableModel
}
else
{
- log.fine("Prepare updating ... manual=" + manualUpdate);
+ if (log.isLoggable(Level.FINE)) log.fine("Prepare updating ... manual=" + manualUpdate);
// get current Data in DB
rowDataDB = readData (rs);
}
@@ -1658,7 +1657,7 @@ public class GridTable extends AbstractTableModel
if (m_inserting)
insertDoc = DB.getDocumentNo (m_ctx, m_WindowNo,
m_tableName, true, null); // only doc type - no trx
- log.fine("DocumentNo entered=" + docNo + ", DocTypeInsert=" + insertDoc + ", newDocNo=" + newDocNo);
+ if (log.isLoggable(Level.FINE)) log.fine("DocumentNo entered=" + docNo + ", DocTypeInsert=" + insertDoc + ", newDocNo=" + newDocNo);
// can we use entered DocNo?
if (insertDoc == null || insertDoc.length () == 0)
{
@@ -1792,8 +1791,7 @@ public class GridTable extends AbstractTableModel
|| (m_rowData[col] == null && rowDataDB[col] == null)
|| (m_rowData[col] != null && m_rowData[col].equals (rowDataDB[col])))
{
- if (CLogMgt.isLevelFinest())
- log.fine(columnName + "=" + rowData[col]
+ if (log.isLoggable(Level.FINE)) log.fine(columnName + "=" + rowData[col]
+ " " + (rowData[col]==null ? "" : rowData[col].getClass().getName()));
//
boolean encrypted = field.isEncryptedColumn();
@@ -1975,7 +1973,7 @@ public class GridTable extends AbstractTableModel
}
else
{
- log.fine("Updating ... " + whereClause);
+ if (log.isLoggable(Level.FINE)) log.fine("Updating ... " + whereClause);
if (manualUpdate)
{
String sql = createUpdateSql(false, whereClause);
@@ -1995,7 +1993,7 @@ public class GridTable extends AbstractTableModel
lobSave(whereClause);
// Need to re-read row to get ROWID, Key, DocumentNo, Trigger, virtual columns
- log.fine("Reading ... " + whereClause);
+ if (log.isLoggable(Level.FINE)) log.fine("Reading ... " + whereClause);
StringBuffer refreshSQL = new StringBuffer(m_SQL_Select)
.append(" WHERE ").append(whereClause);
pstmt = DB.prepareStatement(refreshSQL.toString(), null);
@@ -2064,7 +2062,7 @@ public class GridTable extends AbstractTableModel
*/
private char dataSavePO (int Record_ID) throws Exception
{
- log.fine("ID=" + Record_ID);
+ if (log.isLoggable(Level.FINE)) log.fine("ID=" + Record_ID);
//
Object[] rowData = getDataAtRow(m_rowChanged);
//
@@ -2177,7 +2175,7 @@ public class GridTable extends AbstractTableModel
// Refresh - update buffer
String whereClause = po.get_WhereClause(true);
- log.fine("Reading ... " + whereClause);
+ if (log.isLoggable(Level.FINE)) log.fine("Reading ... " + whereClause);
StringBuffer refreshSQL = new StringBuffer(m_SQL_Select)
.append(" WHERE ").append(whereClause);
PreparedStatement pstmt = null;
@@ -2354,7 +2352,7 @@ public class GridTable extends AbstractTableModel
}
sb.append(" WHERE ").append(whereClause);
}
- log.fine(sb.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(sb.toString());
// reset
createUpdateSqlReset();
return sb.toString();
@@ -2427,7 +2425,7 @@ public class GridTable extends AbstractTableModel
*/
private void lobAdd (PO_LOB lob)
{
- log.fine("LOB=" + lob);
+ if (log.isLoggable(Level.FINE)) log.fine("LOB=" + lob);
if (m_lobInfo == null)
m_lobInfo = new ArrayList();
m_lobInfo.add(lob);
@@ -2536,10 +2534,10 @@ public class GridTable extends AbstractTableModel
m_rowChanged = -1; // only changed in setValueAt
// inform
- log.fine("Current=" + currentRow + ", New=" + m_newRow);
+ if (log.isLoggable(Level.FINE)) log.fine("Current=" + currentRow + ", New=" + m_newRow);
fireTableRowsInserted(m_newRow, m_newRow);
fireDataStatusIEvent(copyCurrent ? "UpdateCopied" : "Inserted", "");
- log.fine("Current=" + currentRow + ", New=" + m_newRow + " - complete");
+ if (log.isLoggable(Level.FINE)) log.fine("Current=" + currentRow + ", New=" + m_newRow + " - complete");
return true;
} // dataNew
@@ -2684,7 +2682,7 @@ public class GridTable extends AbstractTableModel
m_rowChanged = -1;
fireTableRowsDeleted(row, row);
fireDataStatusIEvent("Deleted", "");
- log.fine("Row=" + row + " complete");
+ if (log.isLoggable(Level.FINE)) log.fine("Row=" + row + " complete");
return true;
} // dataDelete
@@ -3028,7 +3026,7 @@ public class GridTable extends AbstractTableModel
*/
public void setReadOnly (boolean value)
{
- log.fine("ReadOnly=" + value);
+ if (log.isLoggable(Level.FINE)) log.fine("ReadOnly=" + value);
m_readOnly = value;
} // setReadOnly
@@ -3078,7 +3076,7 @@ public class GridTable extends AbstractTableModel
*/
public void setDeleteable (boolean value)
{
- log.fine("Deleteable=" + value);
+ if (log.isLoggable(Level.FINE)) log.fine("Deleteable=" + value);
m_deleteable = value;
} // setDeleteable
@@ -3410,7 +3408,7 @@ public class GridTable extends AbstractTableModel
}
if (log.isLoggable(Level.FINE))
- log.fine(info.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(info.toString());
return rows;
} // open
@@ -3478,7 +3476,7 @@ public class GridTable extends AbstractTableModel
{
if (Thread.interrupted())
{
- log.fine("Interrupted");
+ if (log.isLoggable(Level.FINE)) log.fine("Interrupted");
close();
return;
}
@@ -3510,7 +3508,7 @@ public class GridTable extends AbstractTableModel
}
catch (InterruptedException ie)
{
- log.fine("Interrupted while sleeping");
+ if (log.isLoggable(Level.FINE)) log.fine("Interrupted while sleeping");
close();
return;
}
@@ -3549,7 +3547,7 @@ public class GridTable extends AbstractTableModel
{
Object para = m_parameterSELECT.get(i);
if (para != null)
- log.fine("Select " + i + "=" + para);
+ if (log.isLoggable(Level.FINE)) log.fine("Select " + i + "=" + para);
//
if (para == null)
;
@@ -3568,7 +3566,7 @@ public class GridTable extends AbstractTableModel
{
Object para = m_parameterWHERE.get(i);
if (para != null)
- log.fine("Where " + i + "=" + para);
+ if (log.isLoggable(Level.FINE)) log.fine("Where " + i + "=" + para);
//
if (para == null)
;
diff --git a/org.adempiere.base/src/org/compiere/model/Lookup.java b/org.adempiere.base/src/org/compiere/model/Lookup.java
index 7e198350a7..6db890bd69 100644
--- a/org.adempiere.base/src/org/compiere/model/Lookup.java
+++ b/org.adempiere.base/src/org/compiere/model/Lookup.java
@@ -116,7 +116,7 @@ public abstract class Lookup extends AbstractListModel
else
{
m_selectedObject = null;
- log.fine(getColumnName() + ": setSelectedItem - Set to NULL");
+ if (log.isLoggable(Level.FINE)) log.fine(getColumnName() + ": setSelectedItem - Set to NULL");
}
// if (m_worker == null || !m_worker.isAlive())
fireContentsChanged(this, -1, -1);
@@ -304,10 +304,10 @@ public abstract class Lookup extends AbstractListModel
m_loaded = true;
fireContentsChanged(this, 0, p_data.size());
if (p_data.size() == 0)
- log.fine(getColumnName() + ": #0 - ms="
+ if (log.isLoggable(Level.FINE)) log.fine(getColumnName() + ": #0 - ms="
+ String.valueOf(System.currentTimeMillis()-startTime));
else
- log.fine(getColumnName() + ": #" + p_data.size() + " - ms="
+ if (log.isLoggable(Level.FINE)) log.fine(getColumnName() + ": #" + p_data.size() + " - ms="
+ String.valueOf(System.currentTimeMillis()-startTime));
diff --git a/org.adempiere.base/src/org/compiere/model/MAccount.java b/org.adempiere.base/src/org/compiere/model/MAccount.java
index 15d1e5208f..19e2155368 100644
--- a/org.adempiere.base/src/org/compiere/model/MAccount.java
+++ b/org.adempiere.base/src/org/compiere/model/MAccount.java
@@ -765,7 +765,7 @@ public class MAccount extends X_C_ValidCombination
super.setDescription(descr.toString());
if (fullyQualified != isFullyQualified())
setIsFullyQualified(fullyQualified);
- log.fine("Combination=" + getCombination()
+ if (log.isLoggable(Level.FINE)) log.fine("Combination=" + getCombination()
+ " - " + getDescription()
+ " - FullyQualified=" + fullyQualified);
} // setValueDescription
diff --git a/org.adempiere.base/src/org/compiere/model/MAcctSchemaElement.java b/org.adempiere.base/src/org/compiere/model/MAcctSchemaElement.java
index 17c596889b..2462891928 100644
--- a/org.adempiere.base/src/org/compiere/model/MAcctSchemaElement.java
+++ b/org.adempiere.base/src/org/compiere/model/MAcctSchemaElement.java
@@ -512,7 +512,7 @@ public final class MAcctSchemaElement extends X_C_AcctSchema_Element
.append(" WHERE ").append(element).append(" IS NULL AND C_AcctSchema_ID=").append(getC_AcctSchema_ID());
int noF = DB.executeUpdate(sql.toString(), get_TrxName());
//
- log.fine("ValidCombination=" + noC + ", Fact=" + noF);
+ if (log.isLoggable(Level.FINE)) log.fine("ValidCombination=" + noC + ", Fact=" + noF);
} // updateData
@Override
diff --git a/org.adempiere.base/src/org/compiere/model/MAllocationHdr.java b/org.adempiere.base/src/org/compiere/model/MAllocationHdr.java
index d8655f2f58..4899e91f1f 100644
--- a/org.adempiere.base/src/org/compiere/model/MAllocationHdr.java
+++ b/org.adempiere.base/src/org/compiere/model/MAllocationHdr.java
@@ -284,7 +284,7 @@ public final class MAllocationHdr extends X_C_AllocationHdr implements DocAction
.append("' WHERE C_AllocationHdr_ID=").append(getC_AllocationHdr_ID());
int no = DB.executeUpdate(sql.toString(), get_TrxName());
m_lines = null;
- log.fine(processed + " - #" + no);
+ if (log.isLoggable(Level.FINE)) log.fine(processed + " - #" + no);
} // setProcessed
@@ -849,7 +849,7 @@ public final class MAllocationHdr extends X_C_AllocationHdr implements DocAction
bp.setTotalOpenBalance(); // recalculates from scratch
// bp.setSOCreditStatus(); // called automatically
if (bp.save())
- log.fine(bp.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(bp.toString());
else
log.log(Level.SEVERE, "BP not updated - " + bp);
}
diff --git a/org.adempiere.base/src/org/compiere/model/MAllocationLine.java b/org.adempiere.base/src/org/compiere/model/MAllocationLine.java
index c4fcf5948a..f21bb52e72 100644
--- a/org.adempiere.base/src/org/compiere/model/MAllocationLine.java
+++ b/org.adempiere.base/src/org/compiere/model/MAllocationLine.java
@@ -248,7 +248,7 @@ public class MAllocationLine extends X_C_AllocationLine
*/
protected int processIt (boolean reverse)
{
- log.fine("Reverse=" + reverse + " - " + toString());
+ if (log.isLoggable(Level.FINE)) log.fine("Reverse=" + reverse + " - " + toString());
int C_Invoice_ID = getC_Invoice_ID();
MInvoice invoice = getInvoice();
if (invoice != null
@@ -286,13 +286,13 @@ public class MAllocationLine extends X_C_AllocationLine
if (reverse)
{
invoice.setC_Payment_ID(0);
- log.fine("C_Payment_ID=" + C_Payment_ID
+ if (log.isLoggable(Level.FINE)) log.fine("C_Payment_ID=" + C_Payment_ID
+ " Unlinked from C_Invoice_ID=" + C_Invoice_ID);
}
else if (invoice.isPaid())
{
invoice.setC_Payment_ID(C_Payment_ID);
- log.fine("C_Payment_ID=" + C_Payment_ID
+ if (log.isLoggable(Level.FINE)) log.fine("C_Payment_ID=" + C_Payment_ID
+ " Linked to C_Invoice_ID=" + C_Invoice_ID);
}
@@ -303,7 +303,7 @@ public class MAllocationLine extends X_C_AllocationLine
+ "WHERE o.C_Order_ID = (SELECT i.C_Order_ID FROM C_Invoice i "
+ "WHERE i.C_Invoice_ID=" + C_Invoice_ID + ")";
if (DB.executeUpdate(update, get_TrxName()) > 0)
- log.fine("C_Payment_ID=" + C_Payment_ID
+ if (log.isLoggable(Level.FINE)) log.fine("C_Payment_ID=" + C_Payment_ID
+ (reverse ? " UnLinked from" : " Linked to")
+ " order of C_Invoice_ID=" + C_Invoice_ID);
}
@@ -315,13 +315,13 @@ public class MAllocationLine extends X_C_AllocationLine
if (reverse)
{
invoice.setC_CashLine_ID(0);
- log.fine("C_CashLine_ID=" + C_CashLine_ID
+ if (log.isLoggable(Level.FINE)) log.fine("C_CashLine_ID=" + C_CashLine_ID
+ " Unlinked from C_Invoice_ID=" + C_Invoice_ID);
}
else
{
invoice.setC_CashLine_ID(C_CashLine_ID);
- log.fine("C_CashLine_ID=" + C_CashLine_ID
+ if (log.isLoggable(Level.FINE)) log.fine("C_CashLine_ID=" + C_CashLine_ID
+ " Linked to C_Invoice_ID=" + C_Invoice_ID);
}
@@ -332,7 +332,7 @@ public class MAllocationLine extends X_C_AllocationLine
+ "WHERE o.C_Order_ID = (SELECT i.C_Order_ID FROM C_Invoice i "
+ "WHERE i.C_Invoice_ID=" + C_Invoice_ID + ")";
if (DB.executeUpdate(update, get_TrxName()) > 0)
- log.fine("C_CashLine_ID=" + C_CashLine_ID
+ if (log.isLoggable(Level.FINE)) log.fine("C_CashLine_ID=" + C_CashLine_ID
+ (reverse ? " UnLinked from" : " Linked to")
+ " order of C_Invoice_ID=" + C_Invoice_ID);
}
diff --git a/org.adempiere.base/src/org/compiere/model/MArchive.java b/org.adempiere.base/src/org/compiere/model/MArchive.java
index bb847d6d8b..3d9207517c 100644
--- a/org.adempiere.base/src/org/compiere/model/MArchive.java
+++ b/org.adempiere.base/src/org/compiere/model/MArchive.java
@@ -265,7 +265,7 @@ public class MArchive extends X_AD_Archive {
if (data == null || data.length == 0)
return false;
//
- log.fine(toString());
+ if (log.isLoggable(Level.FINE)) log.fine(toString());
return true;
} // beforeSave
diff --git a/org.adempiere.base/src/org/compiere/model/MAsset.java b/org.adempiere.base/src/org/compiere/model/MAsset.java
index d27a600d8d..26551f3c4a 100644
--- a/org.adempiere.base/src/org/compiere/model/MAsset.java
+++ b/org.adempiere.base/src/org/compiere/model/MAsset.java
@@ -120,7 +120,7 @@ public class MAsset extends X_A_Asset
}
MBPartner bp = new MBPartner(getCtx(), invoiceLine.getC_Invoice().getC_BPartner_ID(), null);
name += bp.getName()+"-"+invoiceLine.getC_Invoice().getDocumentNo();
- log.fine("name=" + name);
+ if (log.isLoggable(Level.FINE)) log.fine("name=" + name);
setValue(name);
setName(name);
setDescription(invoiceLine.getDescription());
@@ -379,7 +379,7 @@ public class MAsset extends X_A_Asset
int A_Asset_ID = getA_Asset_ID();
setA_Parent_Asset_ID(A_Asset_ID);
DB.executeUpdateEx("UPDATE A_Asset SET A_Parent_Asset_ID=A_Asset_ID WHERE A_Asset_ID=" + A_Asset_ID, get_TrxName());
- log.fine("A_Parent_Asset_ID=" + getA_Parent_Asset_ID());
+ if (log.isLoggable(Level.FINE)) log.fine("A_Parent_Asset_ID=" + getA_Parent_Asset_ID());
}
//
@@ -390,7 +390,7 @@ public class MAsset extends X_A_Asset
invNo = "" + get_ID();
setInventoryNo(invNo);
DB.executeUpdateEx("UPDATE A_Asset SET InventoryNo=" + DB.TO_STRING(invNo) + " WHERE A_Asset_ID=" + getA_Asset_ID(), get_TrxName());
- log.fine("InventoryNo=" + getInventoryNo());
+ if (log.isLoggable(Level.FINE)) log.fine("InventoryNo=" + getInventoryNo());
}
diff --git a/org.adempiere.base/src/org/compiere/model/MAssetAddition.java b/org.adempiere.base/src/org/compiere/model/MAssetAddition.java
index 06ecbcba7a..6b9adb82c0 100644
--- a/org.adempiere.base/src/org/compiere/model/MAssetAddition.java
+++ b/org.adempiere.base/src/org/compiere/model/MAssetAddition.java
@@ -268,7 +268,7 @@ public class MAssetAddition extends X_A_Asset_Addition
if (dateAcct != null)
{
dateAcct = UseLifeImpl.getDateAcct(dateAcct, 1);
- log.fine("DateAcct=" + dateAcct);
+ if (log.isLoggable(Level.FINE)) log.fine("DateAcct=" + dateAcct);
setDateAcct(dateAcct);
}
setC_Project(project);
@@ -319,7 +319,7 @@ public class MAssetAddition extends X_A_Asset_Addition
if (dateAcct != null)
{
//dateAcct = UseLifeImpl.getDateAcct(dateAcct, 1); //commented by @win -- i don't see why i should add 1 month
- log.fine("DateAcct=" + dateAcct);
+ if (log.isLoggable(Level.FINE)) log.fine("DateAcct=" + dateAcct);
setDateAcct(dateAcct);
}
setI_FixedAsset(ifa);
@@ -478,7 +478,7 @@ public class MAssetAddition extends X_A_Asset_Addition
{
String str = Env.getContext(getCtx(), "#IsCanApproveOwnDoc");
boolean isApproved = "Y".equals(str); //ARHIPAC.toBoolean(str, false);
- log.fine("#IsCanApproveOwnDoc=" + str + "=" + isApproved);
+ if (log.isLoggable(Level.FINE)) log.fine("#IsCanApproveOwnDoc=" + str + "=" + isApproved);
setIsApproved(isApproved);
}
}
@@ -650,7 +650,7 @@ public class MAssetAddition extends X_A_Asset_Addition
//loading asset
MAsset asset = getA_Asset(!m_justPrepared); // requery if not just prepared
- log.fine("asset=" + asset);
+ if (log.isLoggable(Level.FINE)) log.fine("asset=" + asset);
//
// Get/Create Asset Workfile:
@@ -660,7 +660,7 @@ public class MAssetAddition extends X_A_Asset_Addition
{
assetwk = new MDepreciationWorkfile(asset, getPostingType(), null);
}
- log.fine("workfile: " + assetwk);
+ if (log.isLoggable(Level.FINE)) log.fine("workfile: " + assetwk);
//
// Can not upgrade a previous period
/*
diff --git a/org.adempiere.base/src/org/compiere/model/MAssetChange.java b/org.adempiere.base/src/org/compiere/model/MAssetChange.java
index 3270c53b71..cf5fd482a6 100644
--- a/org.adempiere.base/src/org/compiere/model/MAssetChange.java
+++ b/org.adempiere.base/src/org/compiere/model/MAssetChange.java
@@ -19,7 +19,6 @@ import java.util.logging.Level;
import org.compiere.model.MRefList;
import org.compiere.model.PO;
-import org.compiere.util.CLogMgt;
import org.compiere.util.CLogger;
/**
@@ -123,7 +122,7 @@ public class MAssetChange extends X_A_Asset_Change
}
public void addChanges(PO po) {
- if(CLogMgt.isLevelFine()) log.fine("Entering: po=" + po);
+ if (log.isLoggable(Level.FINE)) log.fine("Entering: po=" + po);
if (po == null) {
return;
}
@@ -145,7 +144,7 @@ public class MAssetChange extends X_A_Asset_Change
}
*/
//
- if(CLogMgt.isLevelFine()) log.fine("Leaving: po=" + po);
+ if (log.isLoggable(Level.FINE)) log.fine("Leaving: po=" + po);
}
/** ARHIPAC: TEO: END ------------------------------------------------------------------ */
} // MAssetChange
\ No newline at end of file
diff --git a/org.adempiere.base/src/org/compiere/model/MAssetClass.java b/org.adempiere.base/src/org/compiere/model/MAssetClass.java
index f8ddc39768..e9653cfa42 100644
--- a/org.adempiere.base/src/org/compiere/model/MAssetClass.java
+++ b/org.adempiere.base/src/org/compiere/model/MAssetClass.java
@@ -4,10 +4,10 @@ import java.sql.ResultSet;
import java.sql.Timestamp;
import java.util.Calendar;
import java.util.Properties;
+import java.util.logging.Level;
import org.compiere.model.Query;
import org.compiere.util.CCache;
-import org.compiere.util.CLogMgt;
import org.compiere.util.Env;
import org.compiere.util.TimeUtil;
import org.idempiere.fa.feature.UseLifeImpl;
@@ -151,9 +151,7 @@ public class MAssetClass extends X_A_Asset_Class
A_Life_Period_Max = getA_Life_Period_2004();
}
// logging:
- if (CLogMgt.isLevelFine()) {
- log.fine("serviceDate=" + serviceDate + ", A_Life_Period_Min=" + A_Life_Period_Min + ", A_Life_Period_Max=" + A_Life_Period_Max + ", A_Life_Period=" + A_Life_Period);
- }
+ if (log.isLoggable(Level.FINE)) log.fine("serviceDate=" + serviceDate + ", A_Life_Period_Min=" + A_Life_Period_Min + ", A_Life_Period_Max=" + A_Life_Period_Max + ", A_Life_Period=" + A_Life_Period);
if (A_Life_Period < A_Life_Period_Min || A_Life_Period > A_Life_Period_Max) {
@@ -161,7 +159,7 @@ public class MAssetClass extends X_A_Asset_Class
if (saveError) {
log.saveError("Error", errmsg);
}
- if(CLogMgt.isLevelFine()) {
+ if (log.isLoggable(Level.FINE)) {
log.fine("Leaving: " + errmsg);
Thread.dumpStack();
}
@@ -175,7 +173,7 @@ public class MAssetClass extends X_A_Asset_Class
/** Validate UseLifeImpl model
*/
public boolean validate(UseLifeImpl asset) {
- if(CLogMgt.isLevelFine()) log.fine("Entering: UseLifeImpl=" + asset);
+ if (log.isLoggable(Level.FINE)) log.fine("Entering: UseLifeImpl=" + asset);
if (!asset.isFiscal()) {
log.fine("Leaving: fiscal=false [RETURN TRUE]");
@@ -190,7 +188,7 @@ public class MAssetClass extends X_A_Asset_Class
String errmsg = validate(true, A_Life_Period, serviceDate);
boolean ok = (errmsg == null || errmsg.length() == 0);
- log.fine("Leaving: ok=" + ok);
+ if (log.isLoggable(Level.FINE)) log.fine("Leaving: ok=" + ok);
return ok;
}
diff --git a/org.adempiere.base/src/org/compiere/model/MAssetDisposed.java b/org.adempiere.base/src/org/compiere/model/MAssetDisposed.java
index 06d83d8479..850f5fa3d2 100644
--- a/org.adempiere.base/src/org/compiere/model/MAssetDisposed.java
+++ b/org.adempiere.base/src/org/compiere/model/MAssetDisposed.java
@@ -192,7 +192,7 @@ implements DocAction
//loading asset
MAsset asset = getAsset();
- log.fine("asset=" + asset);
+ if (log.isLoggable(Level.FINE)) log.fine("asset=" + asset);
// Activation
if(!isDisposal())
diff --git a/org.adempiere.base/src/org/compiere/model/MAttachment.java b/org.adempiere.base/src/org/compiere/model/MAttachment.java
index ed6a6a0895..50fca012ab 100644
--- a/org.adempiere.base/src/org/compiere/model/MAttachment.java
+++ b/org.adempiere.base/src/org/compiere/model/MAttachment.java
@@ -215,7 +215,7 @@ public class MAttachment extends X_AD_Attachment
+ ", Exists=" + file.exists() + ", Directory=" + file.isDirectory());
return false;
}
- log.fine("addEntry - " + file);
+ if (log.isLoggable(Level.FINE)) log.fine("addEntry - " + file);
//
String name = file.getName();
byte[] data = null;
@@ -291,7 +291,7 @@ public class MAttachment extends X_AD_Attachment
if (!replaced) {
retValue = m_items.add(item);
}
- log.fine(item.toStringX());
+ if (log.isLoggable(Level.FINE)) log.fine(item.toStringX());
setBinaryData(new byte[0]); // ATTENTION! HEAVY HACK HERE... Else it will not save :(
return retValue || replaced;
} // addEntry
@@ -565,7 +565,7 @@ public class MAttachment extends X_AD_Attachment
+ ", Exists=" + file.exists() + ", Directory=" + file.isDirectory());
return false;
}
- log.fine("updateEntry - " + file);
+ if (log.isLoggable(Level.FINE)) log.fine("updateEntry - " + file);
//
byte[] data = null;
try
diff --git a/org.adempiere.base/src/org/compiere/model/MAttribute.java b/org.adempiere.base/src/org/compiere/model/MAttribute.java
index edcbc2df6c..ad8212af46 100644
--- a/org.adempiere.base/src/org/compiere/model/MAttribute.java
+++ b/org.adempiere.base/src/org/compiere/model/MAttribute.java
@@ -251,7 +251,7 @@ public class MAttribute extends X_M_Attribute
.append("WHERE mas.M_AttributeSet_ID=mau.M_AttributeSet_ID")
.append(" AND mau.M_Attribute_ID=").append(getM_Attribute_ID()).append(")");
int no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("AttributeSet Instance set #" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("AttributeSet Instance set #" + no);
}
return success;
} // afterSave
diff --git a/org.adempiere.base/src/org/compiere/model/MBPartner.java b/org.adempiere.base/src/org/compiere/model/MBPartner.java
index ae322565e6..5b6978b844 100644
--- a/org.adempiere.base/src/org/compiere/model/MBPartner.java
+++ b/org.adempiere.base/src/org/compiere/model/MBPartner.java
@@ -244,7 +244,7 @@ public class MBPartner extends X_C_BPartner
setShareOfCustomer(0);
setSalesVolume(0);
}
- log.fine(toString());
+ if (log.isLoggable(Level.FINE)) log.fine(toString());
} // MBPartner
/**
diff --git a/org.adempiere.base/src/org/compiere/model/MBankStatement.java b/org.adempiere.base/src/org/compiere/model/MBankStatement.java
index d5a41708dc..24a41a7c31 100644
--- a/org.adempiere.base/src/org/compiere/model/MBankStatement.java
+++ b/org.adempiere.base/src/org/compiere/model/MBankStatement.java
@@ -22,6 +22,7 @@ import java.sql.ResultSet;
import java.sql.Timestamp;
import java.util.List;
import java.util.Properties;
+import java.util.logging.Level;
import org.compiere.process.DocAction;
import org.compiere.process.DocumentEngine;
@@ -170,7 +171,7 @@ public class MBankStatement extends X_C_BankStatement implements DocAction
.append("' WHERE C_BankStatement_ID=").append(getC_BankStatement_ID());
int noLine = DB.executeUpdate(sql.toString(), get_TrxName());
m_lines = null;
- log.fine("setProcessed - " + processed + " - Lines=" + noLine);
+ if (log.isLoggable(Level.FINE)) log.fine("setProcessed - " + processed + " - Lines=" + noLine);
} // setProcessed
/**
diff --git a/org.adempiere.base/src/org/compiere/model/MCStage.java b/org.adempiere.base/src/org/compiere/model/MCStage.java
index b512702684..6e77389e36 100644
--- a/org.adempiere.base/src/org/compiere/model/MCStage.java
+++ b/org.adempiere.base/src/org/compiere/model/MCStage.java
@@ -211,7 +211,7 @@ public class MCStage extends X_CM_CStage
.append(", 0, 999)");
int no = DB.executeUpdate(sb.toString(), get_TrxName());
if (no > 0)
- log.fine("#" + no + " - TreeType=CMS");
+ if (log.isLoggable(Level.FINE)) log.fine("#" + no + " - TreeType=CMS");
else
log.warning("#" + no + " - TreeType=CMS");
return no > 0;
@@ -236,7 +236,7 @@ public class MCStage extends X_CM_CStage
.append(" AND AD_Tree_ID=").append(getAD_Tree_ID());
int no = DB.executeUpdate(sb.toString(), get_TrxName());
if (no > 0)
- log.fine("#" + no + " - TreeType=CMS");
+ if (log.isLoggable(Level.FINE)) log.fine("#" + no + " - TreeType=CMS");
else
log.warning("#" + no + " - TreeType=CMS");
return no > 0;
diff --git a/org.adempiere.base/src/org/compiere/model/MCash.java b/org.adempiere.base/src/org/compiere/model/MCash.java
index 4e4adf1f81..d8fadf6608 100644
--- a/org.adempiere.base/src/org/compiere/model/MCash.java
+++ b/org.adempiere.base/src/org/compiere/model/MCash.java
@@ -22,6 +22,7 @@ import java.sql.ResultSet;
import java.sql.Timestamp;
import java.util.List;
import java.util.Properties;
+import java.util.logging.Level;
import org.compiere.process.DocAction;
import org.compiere.process.DocumentEngine;
@@ -771,7 +772,7 @@ public class MCash extends X_C_Cash implements DocAction
.append("' WHERE C_Cash_ID=").append(getC_Cash_ID());
int noLine = DB.executeUpdate (sql.toString(), get_TrxName());
m_lines = null;
- log.fine(processed + " - Lines=" + noLine);
+ if (log.isLoggable(Level.FINE)) log.fine(processed + " - Lines=" + noLine);
} // setProcessed
/**
diff --git a/org.adempiere.base/src/org/compiere/model/MClick.java b/org.adempiere.base/src/org/compiere/model/MClick.java
index 9af7f449ab..f31f43326d 100644
--- a/org.adempiere.base/src/org/compiere/model/MClick.java
+++ b/org.adempiere.base/src/org/compiere/model/MClick.java
@@ -153,7 +153,7 @@ public class MClick extends X_W_Click
// remove everything after /
if (slash != -1)
url = url.substring(0, slash);
- log.fine(exactURL + " -> " + url);
+ if (log.isLoggable(Level.FINE)) log.fine(exactURL + " -> " + url);
int W_ClickCount_ID = search (url, exactURL);
// try minumum
if (W_ClickCount_ID == 0)
@@ -166,7 +166,7 @@ public class MClick extends X_W_Click
lastDot = url.lastIndexOf('.');
firstDot = url.indexOf('.');
}
- log.fine(exactURL + " -> " + url);
+ if (log.isLoggable(Level.FINE)) log.fine(exactURL + " -> " + url);
W_ClickCount_ID = search (url, exactURL);
}
// Not found
diff --git a/org.adempiere.base/src/org/compiere/model/MColor.java b/org.adempiere.base/src/org/compiere/model/MColor.java
index 46cba1004c..ae63a0900b 100644
--- a/org.adempiere.base/src/org/compiere/model/MColor.java
+++ b/org.adempiere.base/src/org/compiere/model/MColor.java
@@ -87,7 +87,7 @@ public class MColor extends X_AD_Color
{
String colName = p_info.getColumnName(index);
String colValue = value == null ? "null" : value.getClass().toString();
- log.fine(colName + "=" + colValue);
+ if (log.isLoggable(Level.FINE)) log.fine(colName + "=" + colValue);
if (value == null)
return "NULL";
return value.toString();
diff --git a/org.adempiere.base/src/org/compiere/model/MColumn.java b/org.adempiere.base/src/org/compiere/model/MColumn.java
index 1ffbbcb11d..1b52b0e44f 100644
--- a/org.adempiere.base/src/org/compiere/model/MColumn.java
+++ b/org.adempiere.base/src/org/compiere/model/MColumn.java
@@ -319,7 +319,7 @@ public class MColumn extends X_AD_Column
.append(" WHERE AD_Column_ID=").append(get_ID())
.append(" AND IsCentrallyMaintained='Y'");
int no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("afterSave - Fields updated #" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("afterSave - Fields updated #" + no);
}
}
return success;
diff --git a/org.adempiere.base/src/org/compiere/model/MContactInterest.java b/org.adempiere.base/src/org/compiere/model/MContactInterest.java
index 7de2cc8cff..dcc02997f7 100644
--- a/org.adempiere.base/src/org/compiere/model/MContactInterest.java
+++ b/org.adempiere.base/src/org/compiere/model/MContactInterest.java
@@ -124,7 +124,7 @@ public class MContactInterest extends X_R_ContactInterest
{
if (OptOutDate == null)
OptOutDate = new Timestamp(System.currentTimeMillis());
- log.fine("" + OptOutDate);
+ if (log.isLoggable(Level.FINE)) log.fine("" + OptOutDate);
super.setOptOutDate(OptOutDate);
setIsActive(false);
} // setOptOutDate
@@ -156,7 +156,7 @@ public class MContactInterest extends X_R_ContactInterest
{
if (SubscribeDate == null)
SubscribeDate = new Timestamp(System.currentTimeMillis());
- log.fine("" + SubscribeDate);
+ if (log.isLoggable(Level.FINE)) log.fine("" + SubscribeDate);
super.setSubscribeDate(SubscribeDate);
super.setOptOutDate(null);
setIsActive(true);
diff --git a/org.adempiere.base/src/org/compiere/model/MContainer.java b/org.adempiere.base/src/org/compiere/model/MContainer.java
index 1cd050165e..33db8d86e8 100644
--- a/org.adempiere.base/src/org/compiere/model/MContainer.java
+++ b/org.adempiere.base/src/org/compiere/model/MContainer.java
@@ -19,6 +19,7 @@ package org.compiere.model;
import java.sql.ResultSet;
import java.util.List;
import java.util.Properties;
+import java.util.logging.Level;
import org.compiere.util.CLogger;
import org.compiere.util.DB;
@@ -444,7 +445,7 @@ public class MContainer extends X_CM_Container
", 0, 999)");
int no = DB.executeUpdate (sb.toString (), get_TrxName ());
if (no > 0)
- log.fine ("#" + no + " - TreeType=CMC");
+ if (log.isLoggable(Level.FINE)) log.fine ("#" + no + " - TreeType=CMC");
else
log.warning ("#" + no + " - TreeType=CMC");
return no > 0;
@@ -488,7 +489,7 @@ public class MContainer extends X_CM_Container
" AND AD_Tree_ID=").append (getAD_Tree_ID ());
int no = DB.executeUpdate (sb.toString (), get_TrxName ());
if (no > 0)
- log.fine ("#" + no + " - TreeType=CMC");
+ if (log.isLoggable(Level.FINE)) log.fine ("#" + no + " - TreeType=CMC");
else
log.warning ("#" + no + " - TreeType=CMC");
return no > 0;
@@ -511,7 +512,7 @@ public class MContainer extends X_CM_Container
int no = DB.executeUpdate (sb.toString (), get_TrxName ());
// If 0 than there is nothing to delete which is okay.
if (no > 0)
- log.fine ("#" + no + " - TreeType=CMC");
+ if (log.isLoggable(Level.FINE)) log.fine ("#" + no + " - TreeType=CMC");
else
log.warning ("#" + no + " - TreeType=CMC");
return true;
diff --git a/org.adempiere.base/src/org/compiere/model/MDepreciation.java b/org.adempiere.base/src/org/compiere/model/MDepreciation.java
index 783c78d4fe..5e99ed0200 100644
--- a/org.adempiere.base/src/org/compiere/model/MDepreciation.java
+++ b/org.adempiere.base/src/org/compiere/model/MDepreciation.java
@@ -153,7 +153,7 @@ public class MDepreciation extends X_A_Depreciation
if(CLogMgt.isLevelFinest())
{
- log.fine("Entering: DepreciationType=" + depreciationType
+ if (log.isLoggable(Level.FINE)) log.fine("Entering: DepreciationType=" + depreciationType
+ ", assetwk=" + assetwk+ ", assetacct=" + assetAcct
+ ", A_Current_Period=" + A_Current_Period //+ " (offset=" + offset + ")"
+ ", Accum_Dep=" + Accum_Dep
@@ -195,7 +195,7 @@ public class MDepreciation extends X_A_Depreciation
}
retValue = retValue.setScale(getPrecision(), RoundingMode.HALF_UP);
//
- if(CLogMgt.isLevelFinest()) log.fine("Leaving: retValue=" + retValue);
+ if (log.isLoggable(Level.FINE)) log.fine("Leaving: retValue=" + retValue);
return retValue;
} // invoke
@@ -296,9 +296,7 @@ public class MDepreciation extends X_A_Depreciation
BigDecimal remainingPeriods = new BigDecimal(wk.getRemainingPeriods(A_Current_Period));
assetExp = remainingAmt.divide(remainingPeriods, getPrecision(), RoundingMode.HALF_UP);
// logging
- if (CLogMgt.isLevelFinest()) {
- log.fine("remainingAmt=" + remainingAmt + ", remainingPeriods=" + remainingPeriods+ " => assetExp=" + assetExp);
- }
+ if (log.isLoggable(Level.FINE)) log.fine("remainingAmt=" + remainingAmt + ", remainingPeriods=" + remainingPeriods+ " => assetExp=" + assetExp);
}
return assetExp;
@@ -345,7 +343,7 @@ public class MDepreciation extends X_A_Depreciation
//~ BigDecimal DUR = BD_100.multiply(
// logging
- if (CLogMgt.isLevelFinest()) {
+ if (log.isLoggable(Level.FINE)) {
log.fine("assetAmt=" + assetAmt + ", A_Life_Period=" + A_Life_Period);
log.fine("A_Current_Year=" + A_Current_Year + ", A_Life_Year=" + A_Life_Year);
//log.fine("coef_K=" + coef_K + ", coef_sl=" + coef_sl + ", coef_ad1=" + coef_ad1); //commented out by @win
@@ -397,7 +395,7 @@ public class MDepreciation extends X_A_Depreciation
BigDecimal assetExp = getPeriodExp(A_Current_Period, amtPerYear);
/** Depreciation refund */
- if (CLogMgt.isLevelFinest()) log.fine("assetExp=" + assetExp);
+ if (log.isLoggable(Level.FINE)) log.fine("assetExp=" + assetExp);
return assetExp;
}
@@ -455,10 +453,7 @@ public class MDepreciation extends X_A_Depreciation
assetExp = assetExp.add(adj).setScale(getPrecision(), RoundingMode.HALF_UP);
}
- if (CLogMgt.isLevelFinest())
- {
- log.fine("amtPerYear=" + amtPerYear + ", amtPerMonth=" + amtPerMonth + ", adj=" + adj + " => assetExp=" + assetExp);
- }
+ if (log.isLoggable(Level.FINE)) log.fine("amtPerYear=" + amtPerYear + ", amtPerMonth=" + amtPerMonth + ", adj=" + adj + " => assetExp=" + assetExp);
return assetExp;
}
diff --git a/org.adempiere.base/src/org/compiere/model/MDepreciationConvention.java b/org.adempiere.base/src/org/compiere/model/MDepreciationConvention.java
index f7b72894f8..10aa841d72 100644
--- a/org.adempiere.base/src/org/compiere/model/MDepreciationConvention.java
+++ b/org.adempiere.base/src/org/compiere/model/MDepreciationConvention.java
@@ -6,7 +6,6 @@ import java.util.Properties;
import java.util.logging.Level;
import org.compiere.util.CCache;
-import org.compiere.util.CLogMgt;
import org.compiere.util.DB;
/** Convention for the first year of depreciation (ex. FMCON, FYCON ...)
@@ -74,8 +73,7 @@ public class MDepreciationConvention extends X_A_Depreciation_Convention
String conventionType = getConventionType();
BigDecimal retValue = null;
- if(CLogMgt.isLevelFine())
- log.fine("Entering: ConventionType=" + conventionType
+ if (log.isLoggable(Level.FINE)) log.fine("Entering: ConventionType=" + conventionType
+ "A_Asset_ID=" + A_Asset_ID + ", PostingType=" + PostingType + ", A_Asset_Acct_ID=" + A_Asset_Acct_ID
+ ", Flag=" + Flag + ", Period=" + Period
);
@@ -109,7 +107,7 @@ public class MDepreciationConvention extends X_A_Depreciation_Convention
retValue = BigDecimal.ZERO;
}
//
- if(CLogMgt.isLevelFine()) log.fine("Leaving: retValue=" + retValue);
+ if (log.isLoggable(Level.FINE)) log.fine("Leaving: retValue=" + retValue);
return retValue;
}
diff --git a/org.adempiere.base/src/org/compiere/model/MDepreciationEntry.java b/org.adempiere.base/src/org/compiere/model/MDepreciationEntry.java
index 3ac40faa28..72d8d0ae23 100644
--- a/org.adempiere.base/src/org/compiere/model/MDepreciationEntry.java
+++ b/org.adempiere.base/src/org/compiere/model/MDepreciationEntry.java
@@ -113,7 +113,7 @@ implements DocAction
id = get_IDOld();
}
int no = DB.executeUpdateEx(sql, new Object[]{id}, get_TrxName());
- log.fine("Updated #" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Updated #" + no);
}
private void selectLines()
@@ -130,7 +130,7 @@ implements DocAction
;
Timestamp dateAcct = TimeUtil.trunc(getDateAcct(), TimeUtil.TRUNC_MONTH);
int no = DB.executeUpdateEx(sql, new Object[]{get_ID(), dateAcct, getAD_Client_ID(), getAD_Org_ID()}, get_TrxName());
- log.fine("Updated #" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Updated #" + no);
}
/**
diff --git a/org.adempiere.base/src/org/compiere/model/MDepreciationMethod.java b/org.adempiere.base/src/org/compiere/model/MDepreciationMethod.java
index 7b570c5f5e..cf5317d683 100644
--- a/org.adempiere.base/src/org/compiere/model/MDepreciationMethod.java
+++ b/org.adempiere.base/src/org/compiere/model/MDepreciationMethod.java
@@ -5,6 +5,7 @@ import java.sql.CallableStatement;
import java.sql.ResultSet;
import java.sql.SQLException;
import java.util.Properties;
+import java.util.logging.Level;
import org.adempiere.exceptions.DBException;
import org.compiere.model.Query;
@@ -145,7 +146,7 @@ public class MDepreciationMethod extends X_A_Depreciation_Method
String depreciationType = getDepreciationType();
BigDecimal retValue = null;
- if(CLogMgt.isLevelFine())
+ if (log.isLoggable(Level.FINE))
log.fine("Entering: DepreciationMethodType=" + depreciationType
+ ", A_Asset_ID=" + A_Asset_ID + ", A_Asset_Adjustment=" + A_Asset_Adjustment
+ ", A_PeriodNo=" + A_PeriodNo + ", PostingType=" + PostingType + ", A_Asset_Acct_ID=" + A_Asset_Acct_ID
@@ -195,7 +196,7 @@ public class MDepreciationMethod extends X_A_Depreciation_Method
retValue = BigDecimal.ZERO;
}
//
- if(CLogMgt.isLevelFine()) log.fine("Leaving: retValue=" + retValue);
+ if(CLogMgt.isLevelFine()) if (log.isLoggable(Level.FINE)) log.fine("Leaving: retValue=" + retValue);
return retValue;
}
@@ -218,7 +219,7 @@ public class MDepreciationMethod extends X_A_Depreciation_Method
}
BigDecimal periodAdjustment = A_Asset_Adjustment.divide(remainingPeriods, getPrecision(), RoundingMode.HALF_UP);
- if(CLogMgt.isLevelFine()) {
+ if (log.isLoggable(Level.FINE)) {
log.fine("A_Asset_Adjustment=" + A_Asset_Adjustment + ", remainingPeriods=" + remainingPeriods + " => periodAdjustment=" + periodAdjustment);
}
return periodAdjustment;
@@ -241,7 +242,7 @@ public class MDepreciationMethod extends X_A_Depreciation_Method
BigDecimal periodAdjustment = A_Asset_Adjustment.divide(remainingPeriods, getPrecision(), RoundingMode.HALF_UP);
- if(CLogMgt.isLevelFine()) {
+ if (log.isLoggable(Level.FINE)) {
log.fine("A_Asset_Adjustment=" + A_Asset_Adjustment + ", remainingPeriods=" + remainingPeriods + " => periodAdjustment=" + periodAdjustment);
}
return periodAdjustment;
diff --git a/org.adempiere.base/src/org/compiere/model/MDepreciationWorkfile.java b/org.adempiere.base/src/org/compiere/model/MDepreciationWorkfile.java
index 8983b96107..519562c7a9 100644
--- a/org.adempiere.base/src/org/compiere/model/MDepreciationWorkfile.java
+++ b/org.adempiere.base/src/org/compiere/model/MDepreciationWorkfile.java
@@ -5,6 +5,7 @@ import java.sql.ResultSet;
import java.sql.Timestamp;
import java.util.Collection;
import java.util.Properties;
+import java.util.logging.Level;
import org.apache.commons.collections.keyvalue.MultiKey;
import org.compiere.util.CCache;
@@ -351,7 +352,7 @@ public class MDepreciationWorkfile extends X_A_Depreciation_Workfile
Timestamp lastActionDate = getLastActionDate();
boolean isDepr = !date.after(lastActionDate); // date <= lastActionDate
- log.fine("LastActionDate=" + lastActionDate + ", GivenDate=" + date + " => isDepreciated=" + isDepr);
+ if (log.isLoggable(Level.FINE)) log.fine("LastActionDate=" + lastActionDate + ", GivenDate=" + date + " => isDepreciated=" + isDepr);
return isDepr;
}
@@ -425,7 +426,7 @@ public class MDepreciationWorkfile extends X_A_Depreciation_Workfile
setA_Asset_Cost(newCost);
setA_QTY_Current(newQty);
- if(CLogMgt.isLevelFine()) log.fine("adjustCost(" + deltaAmt + ", " + deltaQty + ", reset=" + reset + ") => amt=" + getA_Asset_Cost() + ", qty=" + getA_QTY_Current());
+ if (log.isLoggable(Level.FINE)) log.fine("adjustCost(" + deltaAmt + ", " + deltaQty + ", reset=" + reset + ") => amt=" + getA_Asset_Cost() + ", qty=" + getA_QTY_Current());
}
/**
@@ -455,12 +456,12 @@ public class MDepreciationWorkfile extends X_A_Depreciation_Workfile
*/
public void adjustUseLife(int deltaUseLifeYears, int deltaUseLifeYears_F, boolean reset)
{
- if(CLogMgt.isLevelFine()) log.fine("Entering: deltaUseLifeYears=" + deltaUseLifeYears + ", deltaUseLifeYears_F=" + deltaUseLifeYears_F);
+ if (log.isLoggable(Level.FINE)) log.fine("Entering: deltaUseLifeYears=" + deltaUseLifeYears + ", deltaUseLifeYears_F=" + deltaUseLifeYears_F);
//
UseLifeImpl.get(this, false).adjustUseLifeYears(deltaUseLifeYears, reset);
UseLifeImpl.get(this, true).adjustUseLifeYears(deltaUseLifeYears_F, reset);
//
- if(CLogMgt.isLevelFine()) log.fine("Leaving");
+ if (log.isLoggable(Level.FINE)) log.fine("Leaving");
}
/** */
@@ -549,7 +550,7 @@ public class MDepreciationWorkfile extends X_A_Depreciation_Workfile
setA_Current_Period(new_period);
setDateAcct(new_date);
//
- if(CLogMgt.isLevelFine()) log.fine("(A_Current_Period, DateAcct)=(" + old_period + ", " + old_date + ")->(" + new_period + ", " + new_date + ")");
+ if (log.isLoggable(Level.FINE)) log.fine("(A_Current_Period, DateAcct)=(" + old_period + ", " + old_date + ")->(" + new_period + ", " + new_date + ")");
}
/**
@@ -669,7 +670,7 @@ public class MDepreciationWorkfile extends X_A_Depreciation_Workfile
exp_C, exp_F,
accumDep_C, accumDep_F,
help, get_TrxName());
- if(CLogMgt.isLevelFine())
+ if (log.isLoggable(Level.FINE))
{
String info = "" + cnt + ": period=" + currentPeriod + "/" + lifePeriods_C + "|" + lifePeriods_F
+ ", exp=" + exp_C + "|" + exp_F + ", accumDep=" + accumDep_C + "|" + accumDep_F
@@ -678,7 +679,7 @@ public class MDepreciationWorkfile extends X_A_Depreciation_Workfile
sb.append(info + Env.NL);
}
} // for
- log.fine(sb.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(sb.toString());
m_buildDepreciation = false;
} // buildDepreciation
@@ -703,7 +704,7 @@ public class MDepreciationWorkfile extends X_A_Depreciation_Workfile
;
Object[] params = new Object[]{false, A_Current_Period, getA_Asset_ID(), getPostingType()};
int no = DB.executeUpdateEx(sql, params, trxName);
- log.fine("sql=" + sql + "\nDeleted #" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("sql=" + sql + "\nDeleted #" + no);
} // truncDepreciation
/**
diff --git a/org.adempiere.base/src/org/compiere/model/MDiscountSchema.java b/org.adempiere.base/src/org/compiere/model/MDiscountSchema.java
index c5d8b2b7a6..fa793e1ca7 100644
--- a/org.adempiere.base/src/org/compiere/model/MDiscountSchema.java
+++ b/org.adempiere.base/src/org/compiere/model/MDiscountSchema.java
@@ -191,7 +191,7 @@ public class MDiscountSchema extends X_M_DiscountSchema
int M_Product_ID, int M_Product_Category_ID,
BigDecimal BPartnerFlatDiscount)
{
- log.fine("Price=" + Price + ",Qty=" + Qty);
+ if (log.isLoggable(Level.FINE)) log.fine("Price=" + Price + ",Qty=" + Qty);
if (Price == null || Env.ZERO.compareTo(Price) == 0)
return Price;
//
@@ -205,7 +205,7 @@ public class MDiscountSchema extends X_M_DiscountSchema
BigDecimal multiplier = (onehundred).subtract(discount);
multiplier = multiplier.divide(onehundred, 6, BigDecimal.ROUND_HALF_UP);
BigDecimal newPrice = Price.multiply(multiplier);
- log.fine("=>" + newPrice);
+ if (log.isLoggable(Level.FINE)) log.fine("=>" + newPrice);
return newPrice;
} // calculatePrice
@@ -278,7 +278,7 @@ public class MDiscountSchema extends X_M_DiscountSchema
discount = BPartnerFlatDiscount;
else
discount = br.getBreakDiscount();
- log.fine("Discount=>" + discount);
+ if (log.isLoggable(Level.FINE)) log.fine("Discount=>" + discount);
return discount;
} // for all breaks
diff --git a/org.adempiere.base/src/org/compiere/model/MDistribution.java b/org.adempiere.base/src/org/compiere/model/MDistribution.java
index b1e536c4ce..5ceb4eb07b 100644
--- a/org.adempiere.base/src/org/compiere/model/MDistribution.java
+++ b/org.adempiere.base/src/org/compiere/model/MDistribution.java
@@ -21,6 +21,7 @@ import java.sql.ResultSet;
import java.util.ArrayList;
import java.util.List;
import java.util.Properties;
+import java.util.logging.Level;
import org.compiere.util.CCache;
import org.compiere.util.CLogMgt;
@@ -382,7 +383,7 @@ public class MDistribution extends X_GL_Distribution
for (int i = 0; i < m_lines.length; i++)
{
if (m_lines[i].isActive())
- log.fine("distribute = Amt=" + m_lines[i].getAmt() + " - " + m_lines[i].getAccount());
+ if (log.isLoggable(Level.FINE)) log.fine("distribute = Amt=" + m_lines[i].getAmt() + " - " + m_lines[i].getAccount());
}
}
} // distribute
diff --git a/org.adempiere.base/src/org/compiere/model/MDistributionRunDetail.java b/org.adempiere.base/src/org/compiere/model/MDistributionRunDetail.java
index a4590e2b9f..c4c54a2292 100644
--- a/org.adempiere.base/src/org/compiere/model/MDistributionRunDetail.java
+++ b/org.adempiere.base/src/org/compiere/model/MDistributionRunDetail.java
@@ -173,7 +173,7 @@ public class MDistributionRunDetail extends X_T_DistributionRunDetail
}
else
setQty(qty.add(diff));
- log.fine("Qty=" + qty + ", Min=" + getMinQty()
+ if (log.isLoggable(Level.FINE)) log.fine("Qty=" + qty + ", Min=" + getMinQty()
+ ", Max=" + max + ", Diff=" + diff + ", newQty=" + getQty()
+ ", Remaining=" + remaining);
return remaining;
diff --git a/org.adempiere.base/src/org/compiere/model/MDocType.java b/org.adempiere.base/src/org/compiere/model/MDocType.java
index ff2185b82d..c48daad779 100644
--- a/org.adempiere.base/src/org/compiere/model/MDocType.java
+++ b/org.adempiere.base/src/org/compiere/model/MDocType.java
@@ -19,6 +19,7 @@ package org.compiere.model;
import java.sql.ResultSet;
import java.util.List;
import java.util.Properties;
+import java.util.logging.Level;
import org.compiere.util.CCache;
import org.compiere.util.DB;
@@ -283,7 +284,7 @@ public class MDocType extends X_C_DocType
.append(")");
int docact = DB.executeUpdate(sqlDocAction.toString(), get_TrxName());
- log.fine("AD_Document_Action_Access=" + docact);
+ if (log.isLoggable(Level.FINE)) log.fine("AD_Document_Action_Access=" + docact);
}
return success;
} // afterSave
@@ -298,7 +299,7 @@ public class MDocType extends X_C_DocType
// delete access records
StringBuilder msgdb = new StringBuilder("DELETE FROM AD_Document_Action_Access WHERE C_DocType_ID=").append(get_ID());
int docactDel = DB.executeUpdate(msgdb.toString(), get_TrxName());
- log.fine("Delete AD_Document_Action_Access=" + docactDel + " for C_DocType_ID: " + get_ID());
+ if (log.isLoggable(Level.FINE)) log.fine("Delete AD_Document_Action_Access=" + docactDel + " for C_DocType_ID: " + get_ID());
return docactDel >= 0;
} // beforeDelete
diff --git a/org.adempiere.base/src/org/compiere/model/MDocTypeCounter.java b/org.adempiere.base/src/org/compiere/model/MDocTypeCounter.java
index d56805ccfb..07e560db8c 100644
--- a/org.adempiere.base/src/org/compiere/model/MDocTypeCounter.java
+++ b/org.adempiere.base/src/org/compiere/model/MDocTypeCounter.java
@@ -308,7 +308,7 @@ public class MDocTypeCounter extends X_C_DocTypeCounter
//
String dtBT = dt.getDocBaseType();
String c_dtBT = c_dt.getDocBaseType();
- log.fine(dtBT + " -> " + c_dtBT);
+ if (log.isLoggable(Level.FINE)) log.fine(dtBT + " -> " + c_dtBT);
// SO / PO
if ((MDocType.DOCBASETYPE_SalesOrder.equals(dtBT) && MDocType.DOCBASETYPE_PurchaseOrder.equals(c_dtBT))
diff --git a/org.adempiere.base/src/org/compiere/model/MIFixedAsset.java b/org.adempiere.base/src/org/compiere/model/MIFixedAsset.java
index ab15920766..bf83b5578f 100644
--- a/org.adempiere.base/src/org/compiere/model/MIFixedAsset.java
+++ b/org.adempiere.base/src/org/compiere/model/MIFixedAsset.java
@@ -5,12 +5,12 @@ import java.math.RoundingMode;
import java.sql.ResultSet;
import java.sql.Timestamp;
import java.util.Properties;
+import java.util.logging.Level;
import org.adempiere.exceptions.FillMandatoryException;
import org.compiere.model.MClient;
import org.compiere.model.MProduct;
import org.compiere.model.MUOM;
-import org.compiere.util.CLogMgt;
import org.compiere.util.DB;
import org.compiere.util.DisplayType;
import org.compiere.util.Env;
@@ -74,7 +74,7 @@ public class MIFixedAsset extends X_I_FixedAsset
whereClause.append(" AND AD_Client_ID=").append(getAD_Client_ID());
String sql = "SELECT M_Product_ID FROM M_Product WHERE " + whereClause.toString();
M_Product_ID = DB.getSQLValueEx(trxName, sql);
- log.fine("M_Product_ID=" + M_Product_ID + " -- sql=" + sql);
+ if (log.isLoggable(Level.FINE)) log.fine("M_Product_ID=" + M_Product_ID + " -- sql=" + sql);
}
MProduct prod = null;
@@ -123,7 +123,7 @@ public class MIFixedAsset extends X_I_FixedAsset
int precision = getStdPrecision();
BigDecimal newAmt = amt.setScale(getStdPrecision(), RoundingMode.HALF_UP);
set_Value(idx, newAmt);
- if(CLogMgt.isLevelFine()) log.fine(getInventoryNo() + ": " + get_ColumnName(idx) + "=" + amt + "->" + newAmt + " (precision=" + precision + ")");
+ if (log.isLoggable(Level.FINE)) log.fine(getInventoryNo() + ": " + get_ColumnName(idx) + "=" + amt + "->" + newAmt + " (precision=" + precision + ")");
//~ } catch (Exception e) {}
}
@@ -135,7 +135,7 @@ public class MIFixedAsset extends X_I_FixedAsset
if (name == null)
return;
String newName = name.trim().replaceAll("[ ]+", " ");
- if(CLogMgt.isLevelFine()) log.fine(getInventoryNo() + ": " + get_ColumnName(idx) + "=[" + name + "]->[" + newName + "]");
+ if (log.isLoggable(Level.FINE)) log.fine(getInventoryNo() + ": " + get_ColumnName(idx) + "=[" + name + "]->[" + newName + "]");
set_Value(idx, newName);
//~ } catch (Exception e) {}
}
@@ -177,7 +177,7 @@ public class MIFixedAsset extends X_I_FixedAsset
// Create/Set Product
MProduct product = getCreateProduct();
- log.fine("product=" + product);
+ if (log.isLoggable(Level.FINE)) log.fine("product=" + product);
if (getM_Product_ID() <= 0) {
throw new FillMandatoryException(COLUMNNAME_M_Product_ID);
}
diff --git a/org.adempiere.base/src/org/compiere/model/MInOut.java b/org.adempiere.base/src/org/compiere/model/MInOut.java
index 6f176f00ef..1ae6d88a4e 100644
--- a/org.adempiere.base/src/org/compiere/model/MInOut.java
+++ b/org.adempiere.base/src/org/compiere/model/MInOut.java
@@ -810,7 +810,7 @@ public class MInOut extends X_M_InOut implements DocAction
.append("' WHERE M_InOut_ID=").append(getM_InOut_ID());
int noLine = DB.executeUpdate(sql.toString(), get_TrxName());
m_lines = null;
- log.fine(processed + " - Lines=" + noLine);
+ if (log.isLoggable(Level.FINE)) log.fine(processed + " - Lines=" + noLine);
} // setProcessed
/**
@@ -841,7 +841,7 @@ public class MInOut extends X_M_InOut implements DocAction
+ getAD_Client_ID() + " - " + DocBaseType);
else
{
- log.fine("DocBaseType=" + DocBaseType + " - C_DocType_ID=" + C_DocType_ID);
+ if (log.isLoggable(Level.FINE)) log.fine("DocBaseType=" + DocBaseType + " - C_DocType_ID=" + C_DocType_ID);
setC_DocType_ID (C_DocType_ID);
boolean isSOTrx = MDocType.DOCBASETYPE_MaterialDelivery.equals(DocBaseType);
setIsSOTrx (isSOTrx);
@@ -921,7 +921,7 @@ public class MInOut extends X_M_InOut implements DocAction
{
if (!confirm.isProcessed()) // wait intil done
{
- log.fine("Unprocessed: " + confirm);
+ if (log.isLoggable(Level.FINE)) log.fine("Unprocessed: " + confirm);
return;
}
havePick = true;
@@ -1055,7 +1055,7 @@ public class MInOut extends X_M_InOut implements DocAction
.append(" FROM M_InOut o WHERE ol.M_InOut_ID=o.M_InOut_ID) ")
.append("WHERE M_InOut_ID=").append(getC_Order_ID());
int no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Lines -> #" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Lines -> #" + no);
}
return true;
} // afterSave
@@ -1291,7 +1291,7 @@ public class MInOut extends X_M_InOut implements DocAction
if (sLine.getC_OrderLine_ID() != 0)
{
oLine = new MOrderLine (getCtx(), sLine.getC_OrderLine_ID(), get_TrxName());
- log.fine("OrderLine - Reserved=" + oLine.getQtyReserved()
+ if (log.isLoggable(Level.FINE)) log.fine("OrderLine - Reserved=" + oLine.getQtyReserved()
+ ", Delivered=" + oLine.getQtyDelivered());
if (isSOTrx())
QtySO = sLine.getMovementQty();
@@ -1527,7 +1527,7 @@ public class MInOut extends X_M_InOut implements DocAction
return DocAction.STATUS_Invalid;
}
else
- log.fine("OrderLine -> Reserved=" + oLine.getQtyReserved()
+ if (log.isLoggable(Level.FINE)) log.fine("OrderLine -> Reserved=" + oLine.getQtyReserved()
+ ", Delivered=" + oLine.getQtyReserved());
}
// Update RMA Line Qty Delivered
@@ -1779,7 +1779,7 @@ public class MInOut extends X_M_InOut implements DocAction
}
}
- log.fine(dropShipment.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(dropShipment.toString());
dropShipment.setDocAction(DocAction.ACTION_Complete);
// added AdempiereException by Zuhri
@@ -1889,7 +1889,7 @@ public class MInOut extends X_M_InOut implements DocAction
storage.getQtyOnHand());
ma.saveEx();
qtyToDeliver = qtyToDeliver.subtract(storage.getQtyOnHand());
- log.fine( ma + ", QtyToDeliver=" + qtyToDeliver);
+ if (log.isLoggable(Level.FINE)) log.fine( ma + ", QtyToDeliver=" + qtyToDeliver);
}
if (qtyToDeliver.signum() == 0)
@@ -1903,7 +1903,7 @@ public class MInOut extends X_M_InOut implements DocAction
int M_AttributeSetInstance_ID = asi.getM_AttributeSetInstance_ID();
MInOutLineMA ma = new MInOutLineMA (line, M_AttributeSetInstance_ID, qtyToDeliver);
ma.saveEx();
- log.fine("##: " + ma);
+ if (log.isLoggable(Level.FINE)) log.fine("##: " + ma);
}
} // outgoing Trx
} // attributeSetInstance
@@ -1945,7 +1945,7 @@ public class MInOut extends X_M_InOut implements DocAction
MDocTypeCounter counterDT = MDocTypeCounter.getCounterDocType(getCtx(), getC_DocType_ID());
if (counterDT != null)
{
- log.fine(counterDT.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(counterDT.toString());
if (!counterDT.isCreateCounter() || !counterDT.isValid())
return null;
C_DocTypeTarget_ID = counterDT.getCounter_C_DocType_ID();
@@ -1953,7 +1953,7 @@ public class MInOut extends X_M_InOut implements DocAction
else // indirect
{
C_DocTypeTarget_ID = MDocTypeCounter.getCounterDocType_ID(getCtx(), getC_DocType_ID());
- log.fine("Indirect C_DocTypeTarget_ID=" + C_DocTypeTarget_ID);
+ if (log.isLoggable(Level.FINE)) log.fine("Indirect C_DocTypeTarget_ID=" + C_DocTypeTarget_ID);
if (C_DocTypeTarget_ID <= 0)
return null;
}
@@ -1996,7 +1996,7 @@ public class MInOut extends X_M_InOut implements DocAction
counterLine.saveEx(get_TrxName());
}
- log.fine(counter.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(counter.toString());
// Document Action
if (counterDT != null)
diff --git a/org.adempiere.base/src/org/compiere/model/MInOutConfirm.java b/org.adempiere.base/src/org/compiere/model/MInOutConfirm.java
index 1f261da4b0..d0716299f9 100644
--- a/org.adempiere.base/src/org/compiere/model/MInOutConfirm.java
+++ b/org.adempiere.base/src/org/compiere/model/MInOutConfirm.java
@@ -488,7 +488,7 @@ public class MInOutConfirm extends X_M_InOutConfirm implements DocAction
continue;
//
MInOutLine oldLine = confirmLine.getLine();
- log.fine("Qty=" + differenceQty + ", Old=" + oldLine);
+ if (log.isLoggable(Level.FINE)) log.fine("Qty=" + differenceQty + ", Old=" + oldLine);
//
// Create Header
if (split == null)
diff --git a/org.adempiere.base/src/org/compiere/model/MInventory.java b/org.adempiere.base/src/org/compiere/model/MInventory.java
index 49cab66966..f4453238ac 100644
--- a/org.adempiere.base/src/org/compiere/model/MInventory.java
+++ b/org.adempiere.base/src/org/compiere/model/MInventory.java
@@ -276,7 +276,7 @@ public class MInventory extends X_M_Inventory implements DocAction
final String sql = "UPDATE M_InventoryLine SET Processed=? WHERE M_Inventory_ID=?";
int noLine = DB.executeUpdateEx(sql, new Object[]{processed, getM_Inventory_ID()}, get_TrxName());
m_lines = null;
- log.fine("Processed=" + processed + " - Lines=" + noLine);
+ if (log.isLoggable(Level.FINE)) log.fine("Processed=" + processed + " - Lines=" + noLine);
} // setProcessed
@@ -438,7 +438,7 @@ public class MInventory extends X_M_Inventory implements DocAction
MInventoryLineMA ma = mas[j];
BigDecimal QtyMA = ma.getMovementQty();
BigDecimal QtyNew = QtyMA.add(qtyDiff);
- log.fine("Diff=" + qtyDiff
+ if (log.isLoggable(Level.FINE)) log.fine("Diff=" + qtyDiff
+ " - Instance OnHand=" + QtyMA + "->" + QtyNew);
if (!MStorageOnHand.add(getCtx(), getM_Warehouse_ID(),
@@ -622,7 +622,7 @@ public class MInventory extends X_M_Inventory implements DocAction
qtyToDeliver);
ma.saveEx();
qtyToDeliver = Env.ZERO;
- log.fine( ma + ", QtyToDeliver=" + qtyToDeliver);
+ if (log.isLoggable(Level.FINE)) log.fine( ma + ", QtyToDeliver=" + qtyToDeliver);
}
else
{
@@ -631,7 +631,7 @@ public class MInventory extends X_M_Inventory implements DocAction
storage.getQtyOnHand());
ma.saveEx();
qtyToDeliver = qtyToDeliver.subtract(storage.getQtyOnHand());
- log.fine( ma + ", QtyToDeliver=" + qtyToDeliver);
+ if (log.isLoggable(Level.FINE)) log.fine( ma + ", QtyToDeliver=" + qtyToDeliver);
}
if (qtyToDeliver.signum() == 0)
break;
@@ -646,7 +646,7 @@ public class MInventory extends X_M_Inventory implements DocAction
MInventoryLineMA ma = new MInventoryLineMA (line, M_AttributeSetInstance_ID , qtyToDeliver);
ma.saveEx();
- log.fine("##: " + ma);
+ if (log.isLoggable(Level.FINE)) log.fine("##: " + ma);
}
} // outgoing Trx
diff --git a/org.adempiere.base/src/org/compiere/model/MInvoice.java b/org.adempiere.base/src/org/compiere/model/MInvoice.java
index a5e09fea0a..4080e7e606 100644
--- a/org.adempiere.base/src/org/compiere/model/MInvoice.java
+++ b/org.adempiere.base/src/org/compiere/model/MInvoice.java
@@ -863,7 +863,7 @@ public class MInvoice extends X_C_Invoice implements DocAction
int noTax = DB.executeUpdate(msgdb.toString(), get_TrxName());
m_lines = null;
m_taxes = null;
- log.fine(processed + " - Lines=" + noLine + ", Tax=" + noTax);
+ if (log.isLoggable(Level.FINE)) log.fine(processed + " - Lines=" + noLine + ", Tax=" + noTax);
} // setProcessed
/**
@@ -874,7 +874,7 @@ public class MInvoice extends X_C_Invoice implements DocAction
{
MInvoicePaySchedule[] schedule = MInvoicePaySchedule.getInvoicePaySchedule
(getCtx(), getC_Invoice_ID(), 0, get_TrxName());
- log.fine("#" + schedule.length);
+ if (log.isLoggable(Level.FINE)) log.fine("#" + schedule.length);
if (schedule.length == 0)
{
setIsPayScheduleValid(false);
@@ -1066,7 +1066,7 @@ public class MInvoice extends X_C_Invoice implements DocAction
.append(" FROM C_Invoice o WHERE ol.C_Invoice_ID=o.C_Invoice_ID) ")
.append("WHERE C_Invoice_ID=").append(getC_Invoice_ID());
int no = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine("Lines -> #" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Lines -> #" + no);
}
return true;
} // afterSave
@@ -1148,7 +1148,7 @@ public class MInvoice extends X_C_Invoice implements DocAction
change = test != isPaid();
if (change)
setIsPaid(test);
- log.fine("Paid=" + test
+ if (log.isLoggable(Level.FINE)) log.fine("Paid=" + test
+ " (" + alloc + "=" + total + ")");
}
@@ -1493,7 +1493,7 @@ public class MInvoice extends X_C_Invoice implements DocAction
{
MInvoiceLine line = lines[i];
MProduct product = MProduct.get (getCtx(), line.getM_Product_ID());
- log.fine(product.getName());
+ if (log.isLoggable(Level.FINE)) log.fine(product.getName());
// New Lines
int lineNo = line.getLine ();
@@ -1646,7 +1646,7 @@ public class MInvoice extends X_C_Invoice implements DocAction
if (getC_PaymentTerm_ID() == 0)
return false;
MPaymentTerm pt = new MPaymentTerm(getCtx(), getC_PaymentTerm_ID(), null);
- log.fine(pt.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(pt.toString());
int numSchema = pt.getSchedule(false).length;
@@ -1893,7 +1893,7 @@ public class MInvoice extends X_C_Invoice implements DocAction
else
newCreditAmt = newCreditAmt.add(invAmt);
//
- log.fine("GrandTotal=" + getGrandTotal(true) + "(" + invAmt
+ if (log.isLoggable(Level.FINE)) log.fine("GrandTotal=" + getGrandTotal(true) + "(" + invAmt
+ ") BP Life=" + bp.getActualLifeTimeValue() + "->" + newLifeAmt
+ ", Credit=" + bp.getSO_CreditUsed() + "->" + newCreditAmt
+ ", Balance=" + bp.getTotalOpenBalance(false) + " -> " + newBalance);
@@ -1903,7 +1903,7 @@ public class MInvoice extends X_C_Invoice implements DocAction
else
{
newBalance = newBalance.subtract(invAmt);
- log.fine("GrandTotal=" + getGrandTotal(true) + "(" + invAmt
+ if (log.isLoggable(Level.FINE)) log.fine("GrandTotal=" + getGrandTotal(true) + "(" + invAmt
+ ") Balance=" + bp.getTotalOpenBalance(false) + " -> " + newBalance);
}
bp.setTotalOpenBalance(newBalance);
@@ -1948,7 +1948,7 @@ public class MInvoice extends X_C_Invoice implements DocAction
newAmt = amt;
else
newAmt = newAmt.add(amt);
- log.fine("GrandTotal=" + getGrandTotal(true) + "(" + amt
+ if (log.isLoggable(Level.FINE)) log.fine("GrandTotal=" + getGrandTotal(true) + "(" + amt
+ ") Project " + project.getName()
+ " - Invoiced=" + project.getInvoicedAmt() + "->" + newAmt);
project.setInvoicedAmt(newAmt);
@@ -2106,7 +2106,7 @@ public class MInvoice extends X_C_Invoice implements DocAction
MDocTypeCounter counterDT = MDocTypeCounter.getCounterDocType(getCtx(), getC_DocType_ID());
if (counterDT != null)
{
- log.fine(counterDT.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(counterDT.toString());
if (!counterDT.isCreateCounter() || !counterDT.isValid())
return null;
C_DocTypeTarget_ID = counterDT.getCounter_C_DocType_ID();
@@ -2114,7 +2114,7 @@ public class MInvoice extends X_C_Invoice implements DocAction
else // indirect
{
C_DocTypeTarget_ID = MDocTypeCounter.getCounterDocType_ID(getCtx(), getC_DocType_ID());
- log.fine("Indirect C_DocTypeTarget_ID=" + C_DocTypeTarget_ID);
+ if (log.isLoggable(Level.FINE)) log.fine("Indirect C_DocTypeTarget_ID=" + C_DocTypeTarget_ID);
if (C_DocTypeTarget_ID <= 0)
return null;
}
@@ -2144,7 +2144,7 @@ public class MInvoice extends X_C_Invoice implements DocAction
counterLine.saveEx(get_TrxName());
}
- log.fine(counter.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(counter.toString());
// Document Action
if (counterDT != null)
diff --git a/org.adempiere.base/src/org/compiere/model/MInvoiceBatch.java b/org.adempiere.base/src/org/compiere/model/MInvoiceBatch.java
index ed4d445d73..81bd5017b7 100644
--- a/org.adempiere.base/src/org/compiere/model/MInvoiceBatch.java
+++ b/org.adempiere.base/src/org/compiere/model/MInvoiceBatch.java
@@ -135,7 +135,7 @@ public class MInvoiceBatch extends X_C_InvoiceBatch
.append("' WHERE C_InvoiceBatch_ID=").append(getC_InvoiceBatch_ID());
int noLine = DB.executeUpdate("UPDATE C_InvoiceBatchLine " + set, get_TrxName());
m_lines = null;
- log.fine(processed + " - Lines=" + noLine);
+ if (log.isLoggable(Level.FINE)) log.fine(processed + " - Lines=" + noLine);
} // setProcessed
} // MInvoiceBatch
diff --git a/org.adempiere.base/src/org/compiere/model/MInvoiceLine.java b/org.adempiere.base/src/org/compiere/model/MInvoiceLine.java
index cd217292a8..33171970f1 100644
--- a/org.adempiere.base/src/org/compiere/model/MInvoiceLine.java
+++ b/org.adempiere.base/src/org/compiere/model/MInvoiceLine.java
@@ -352,7 +352,7 @@ public class MInvoiceLine extends X_C_InvoiceLine
if (getM_Product_ID() == 0 || isDescription())
return;
//
- log.fine("M_PriceList_ID=" + M_PriceList_ID);
+ if (log.isLoggable(Level.FINE)) log.fine("M_PriceList_ID=" + M_PriceList_ID);
m_productPricing = new MProductPricing (getM_Product_ID(),
C_BPartner_ID, getQtyInvoiced(), m_IsSOTrx);
m_productPricing.setM_PriceList_ID(M_PriceList_ID);
@@ -482,15 +482,15 @@ public class MInvoiceLine extends X_C_InvoiceLine
if (stdTax != null)
{
- log.fine("stdTax rate is " + stdTax.getRate());
- log.fine("invoiceTax rate is " + invoiceTax.getRate());
+ if (log.isLoggable(Level.FINE)) log.fine("stdTax rate is " + stdTax.getRate());
+ if (log.isLoggable(Level.FINE)) log.fine("invoiceTax rate is " + invoiceTax.getRate());
taxThisAmt = taxThisAmt.add(invoiceTax.calculateTax(bd, isTaxIncluded(), getPrecision()));
taxStdAmt = taxStdAmt.add(stdTax.calculateTax(bd, isTaxIncluded(), getPrecision()));
bd = bd.subtract(taxStdAmt).add(taxThisAmt);
- log.fine("Price List includes Tax and Tax Changed on Invoice Line: New Tax Amt: "
+ if (log.isLoggable(Level.FINE)) log.fine("Price List includes Tax and Tax Changed on Invoice Line: New Tax Amt: "
+ taxThisAmt + " Standard Tax Amt: " + taxStdAmt + " Line Net Amt: " + bd);
}
}
@@ -816,7 +816,7 @@ public class MInvoiceLine extends X_C_InvoiceLine
*/
protected boolean beforeSave (boolean newRecord)
{
- log.fine("New=" + newRecord);
+ if (log.isLoggable(Level.FINE)) log.fine("New=" + newRecord);
if (newRecord && getParent().isComplete()) {
log.saveError("ParentComplete", Msg.translate(getCtx(), "C_InvoiceLine"));
return false;
diff --git a/org.adempiere.base/src/org/compiere/model/MInvoiceSchedule.java b/org.adempiere.base/src/org/compiere/model/MInvoiceSchedule.java
index 3f7705500a..9b8f251252 100644
--- a/org.adempiere.base/src/org/compiere/model/MInvoiceSchedule.java
+++ b/org.adempiere.base/src/org/compiere/model/MInvoiceSchedule.java
@@ -21,6 +21,7 @@ import java.sql.ResultSet;
import java.sql.Timestamp;
import java.util.Calendar;
import java.util.Properties;
+import java.util.logging.Level;
import org.compiere.util.CCache;
import org.compiere.util.TimeUtil;
@@ -113,7 +114,7 @@ public class MInvoiceSchedule extends X_C_InvoiceSchedule
if (cutoff.after(today))
cutoff.add(Calendar.DAY_OF_YEAR, -7);
Timestamp cutoffDate = new Timestamp (cutoff.getTimeInMillis());
- log.fine("canInvoice - Date=" + xDate + " > Cutoff=" + cutoffDate
+ if (log.isLoggable(Level.FINE)) log.fine("canInvoice - Date=" + xDate + " > Cutoff=" + cutoffDate
+ " - " + xDate.after(cutoffDate));
if (xDate.after(cutoffDate))
return false;
@@ -123,7 +124,7 @@ public class MInvoiceSchedule extends X_C_InvoiceSchedule
if (invoice.after(today))
invoice.add(Calendar.DAY_OF_YEAR, -7);
Timestamp invoiceDate = new Timestamp (invoice.getTimeInMillis());
- log.fine("canInvoice - Date=" + xDate + " > Invoice=" + invoiceDate
+ if (log.isLoggable(Level.FINE)) log.fine("canInvoice - Date=" + xDate + " > Invoice=" + invoiceDate
+ " - " + xDate.after(invoiceDate));
if (xDate.after(invoiceDate))
return false;
@@ -141,7 +142,7 @@ public class MInvoiceSchedule extends X_C_InvoiceSchedule
if (cutoff.after(today))
cutoff.add(Calendar.MONTH, -1);
Timestamp cutoffDate = new Timestamp (cutoff.getTimeInMillis());
- log.fine("canInvoice - Date=" + xDate + " > Cutoff=" + cutoffDate
+ if (log.isLoggable(Level.FINE)) log.fine("canInvoice - Date=" + xDate + " > Cutoff=" + cutoffDate
+ " - " + xDate.after(cutoffDate));
if (xDate.after(cutoffDate))
return false;
@@ -151,7 +152,7 @@ public class MInvoiceSchedule extends X_C_InvoiceSchedule
if (invoice.after(today))
invoice.add(Calendar.MONTH, -1);
Timestamp invoiceDate = new Timestamp (invoice.getTimeInMillis());
- log.fine("canInvoice - Date=" + xDate + " > Invoice=" + invoiceDate
+ if (log.isLoggable(Level.FINE)) log.fine("canInvoice - Date=" + xDate + " > Invoice=" + invoiceDate
+ " - " + xDate.after(invoiceDate));
if (xDate.after(invoiceDate))
return false;
diff --git a/org.adempiere.base/src/org/compiere/model/MJournal.java b/org.adempiere.base/src/org/compiere/model/MJournal.java
index d716cdfbd6..5724d07ff1 100644
--- a/org.adempiere.base/src/org/compiere/model/MJournal.java
+++ b/org.adempiere.base/src/org/compiere/model/MJournal.java
@@ -285,7 +285,7 @@ public class MJournal extends X_GL_Journal implements DocAction
.append((processed ? "Y" : "N"))
.append("' WHERE GL_Journal_ID=").append(getGL_Journal_ID());
int noLine = DB.executeUpdate(sql.toString(), get_TrxName());
- log.fine(processed + " - Lines=" + noLine);
+ if (log.isLoggable(Level.FINE)) log.fine(processed + " - Lines=" + noLine);
} // setProcessed
diff --git a/org.adempiere.base/src/org/compiere/model/MLanguage.java b/org.adempiere.base/src/org/compiere/model/MLanguage.java
index b72c8203fb..8572d7f313 100644
--- a/org.adempiere.base/src/org/compiere/model/MLanguage.java
+++ b/org.adempiere.base/src/org/compiere/model/MLanguage.java
@@ -319,7 +319,7 @@ public class MLanguage extends X_AD_Language
protected boolean afterSave (boolean newRecord, boolean success)
{
int no = TranslationTable.getActiveLanguages(true);
- log.fine("Active Languages=" + no);
+ if (log.isLoggable(Level.FINE)) log.fine("Active Languages=" + no);
return true;
} // afterSave
@@ -368,7 +368,7 @@ public class MLanguage extends X_AD_Language
{
StringBuilder sql = new StringBuilder("DELETE FROM ").append(tableName).append(" WHERE AD_Language=?");
int no = DB.executeUpdateEx(sql.toString(), new Object[]{getAD_Language()}, get_TrxName());
- log.fine(tableName + " #" + no);
+ if (log.isLoggable(Level.FINE)) log.fine(tableName + " #" + no);
return no;
} // deleteTable
@@ -442,7 +442,7 @@ public class MLanguage extends X_AD_Language
UUIDGenerator.updateUUID(column, get_TrxName());
//
StringBuilder msglog = new StringBuilder().append(tableName).append(" #").append(no);
- log.fine(msglog.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(msglog.toString());
return no;
} // addTable
diff --git a/org.adempiere.base/src/org/compiere/model/MLocatorLookup.java b/org.adempiere.base/src/org/compiere/model/MLocatorLookup.java
index 9bddcbeac2..be63e95c10 100644
--- a/org.adempiere.base/src/org/compiere/model/MLocatorLookup.java
+++ b/org.adempiere.base/src/org/compiere/model/MLocatorLookup.java
@@ -82,7 +82,7 @@ public final class MLocatorLookup extends Lookup implements Serializable
*/
public void dispose()
{
- log.fine("C_Locator_ID=" + C_Locator_ID);
+ if (log.isLoggable(Level.FINE)) log.fine("C_Locator_ID=" + C_Locator_ID);
if (m_loader != null)
{
while (m_loader.isAlive())
@@ -379,7 +379,7 @@ public final class MLocatorLookup extends Lookup implements Serializable
DB.close(rs, pstmt);
rs = null; pstmt = null;
}
- log.fine("Complete #" + m_lookup.size());
+ if (log.isLoggable(Level.FINE)) log.fine("Complete #" + m_lookup.size());
if (m_lookup.size() == 0)
log.finer(finalSql);
} // run
diff --git a/org.adempiere.base/src/org/compiere/model/MLookup.java b/org.adempiere.base/src/org/compiere/model/MLookup.java
index fa6f79f895..eecec83f60 100644
--- a/org.adempiere.base/src/org/compiere/model/MLookup.java
+++ b/org.adempiere.base/src/org/compiere/model/MLookup.java
@@ -67,7 +67,7 @@ public final class MLookup extends Lookup implements Serializable
{
super(info.DisplayType, info.WindowNo);
m_info = info;
- log.fine(m_info.KeyColumn);
+ if (log.isLoggable(Level.FINE)) log.fine(m_info.KeyColumn);
// load into local lookup, if already cached
if (Ini.isClient())
@@ -135,7 +135,7 @@ public final class MLookup extends Lookup implements Serializable
public void dispose()
{
if (m_info != null)
- log.fine(m_info.KeyColumn + ": dispose");
+ if (log.isLoggable(Level.FINE)) log.fine(m_info.KeyColumn + ": dispose");
if (m_loaderFuture != null && !m_loaderFuture.isDone())
m_loaderFuture.cancel(true);
m_loader = null;
@@ -365,7 +365,7 @@ public final class MLookup extends Lookup implements Serializable
{
if (m_loaderFuture != null && !m_loaderFuture.isDone())
{
- log.fine((m_info.KeyColumn==null ? "ID="+m_info.Column_ID : m_info.KeyColumn)
+ if (log.isLoggable(Level.FINE)) log.fine((m_info.KeyColumn==null ? "ID="+m_info.Column_ID : m_info.KeyColumn)
+ ": waiting for Loader");
loadComplete();
}
@@ -385,7 +385,7 @@ public final class MLookup extends Lookup implements Serializable
if (!validated && onlyValidated)
{
loadData (loadParent);
- log.fine(m_info.KeyColumn + ": Validated - #" + m_lookup.size());
+ if (log.isLoggable(Level.FINE)) log.fine(m_info.KeyColumn + ": Validated - #" + m_lookup.size());
}
return new ArrayList
");
- log.fine( "#" + map.size() + " - " + keyColor);
+ if (log.isLoggable(Level.FINE)) log.fine( "#" + map.size() + " - " + keyColor);
CButton button = new CButton(buttonHTML.toString());
button.setBackground(keyColor);
button.setFont(keyFont);
diff --git a/org.adempiere.ui.swing/src/org/compiere/pos/PosKeyboardFocusManager.java b/org.adempiere.ui.swing/src/org/compiere/pos/PosKeyboardFocusManager.java
index 1f0a31b6f9..4b47a65d5c 100644
--- a/org.adempiere.ui.swing/src/org/compiere/pos/PosKeyboardFocusManager.java
+++ b/org.adempiere.ui.swing/src/org/compiere/pos/PosKeyboardFocusManager.java
@@ -19,6 +19,7 @@ import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
import java.awt.event.KeyEvent;
import java.util.LinkedList;
+import java.util.logging.Level;
import org.compiere.util.CLogger;
@@ -74,7 +75,7 @@ public class PosKeyboardFocusManager extends DefaultKeyboardFocusManager
public void start() {
// Unqueue time - 200 ms
int delay = 200;
- log.fine("PosKeyboardFocusManager.start - " + delay);
+ if (log.isLoggable(Level.FINE)) log.fine("PosKeyboardFocusManager.start - " + delay);
if (m_timer == null)
m_timer = new javax.swing.Timer(delay, this);
if (!m_timer.isRunning())
@@ -85,7 +86,7 @@ public class PosKeyboardFocusManager extends DefaultKeyboardFocusManager
* Stop Timer
*/
public void stop() {
- log.fine("PosKeyboardFocusManager.stop - " + m_timer);
+ if (log.isLoggable(Level.FINE)) log.fine("PosKeyboardFocusManager.stop - " + m_timer);
if (m_timer != null)
m_timer.stop();
diff --git a/org.adempiere.ui.swing/src/org/compiere/pos/PosOrderModel.java b/org.adempiere.ui.swing/src/org/compiere/pos/PosOrderModel.java
index 6b23add169..f9bbc941fd 100644
--- a/org.adempiere.ui.swing/src/org/compiere/pos/PosOrderModel.java
+++ b/org.adempiere.ui.swing/src/org/compiere/pos/PosOrderModel.java
@@ -16,6 +16,7 @@ package org.compiere.pos;
import java.math.BigDecimal;
import java.util.HashMap;
import java.util.Properties;
+import java.util.logging.Level;
import org.compiere.model.MBPartner;
import org.compiere.model.MBankAccountProcessor;
@@ -419,7 +420,7 @@ public class PosOrderModel extends MOrder {
//
ValueNamePair[] retValue = new ValueNamePair[map.size ()];
map.values ().toArray (retValue);
- log.fine("getCreditCards - #" + retValue.length + " - Processors=" + m_mBankAccountProcessors.length);
+ if (log.isLoggable(Level.FINE)) log.fine("getCreditCards - #" + retValue.length + " - Processors=" + m_mBankAccountProcessors.length);
return retValue;
}
catch (Exception ex)
diff --git a/org.adempiere.ui.swing/src/org/compiere/pos/QueryBPartner.java b/org.adempiere.ui.swing/src/org/compiere/pos/QueryBPartner.java
index 31e4b38da0..605d89f4bf 100644
--- a/org.adempiere.ui.swing/src/org/compiere/pos/QueryBPartner.java
+++ b/org.adempiere.ui.swing/src/org/compiere/pos/QueryBPartner.java
@@ -17,6 +17,7 @@ package org.compiere.pos;
import java.awt.Dimension;
import java.awt.event.ActionEvent;
import java.awt.event.KeyEvent;
+import java.util.logging.Level;
import javax.swing.KeyStroke;
import javax.swing.border.TitledBorder;
@@ -260,7 +261,7 @@ public class QueryBPartner extends PosQuery
}
}
f_ok.setEnabled(enabled);
- log.fine("C_BPartner_ID=" + m_C_BPartner_ID);
+ if (log.isLoggable(Level.FINE)) log.fine("C_BPartner_ID=" + m_C_BPartner_ID);
} // enableButtons
/**
@@ -269,7 +270,7 @@ public class QueryBPartner extends PosQuery
*/
protected void close()
{
- log.fine("C_BPartner_ID=" + m_C_BPartner_ID);
+ if (log.isLoggable(Level.FINE)) log.fine("C_BPartner_ID=" + m_C_BPartner_ID);
if (m_C_BPartner_ID > 0)
{
diff --git a/org.adempiere.ui.swing/src/org/compiere/pos/QueryProduct.java b/org.adempiere.ui.swing/src/org/compiere/pos/QueryProduct.java
index 50aaf2deb2..673b8f7ab3 100644
--- a/org.adempiere.ui.swing/src/org/compiere/pos/QueryProduct.java
+++ b/org.adempiere.ui.swing/src/org/compiere/pos/QueryProduct.java
@@ -18,6 +18,7 @@ import java.awt.Dimension;
import java.awt.event.ActionEvent;
import java.awt.event.KeyEvent;
import java.math.BigDecimal;
+import java.util.logging.Level;
import javax.swing.KeyStroke;
import javax.swing.border.TitledBorder;
@@ -275,7 +276,7 @@ public class QueryProduct extends PosQuery
}
}
f_ok.setEnabled(enabled);
- log.fine("M_Product_ID=" + m_M_Product_ID + " - " + m_ProductName + " - " + m_Price);
+ if (log.isLoggable(Level.FINE)) log.fine("M_Product_ID=" + m_M_Product_ID + " - " + m_ProductName + " - " + m_Price);
} // enableButtons
@@ -286,7 +287,7 @@ public class QueryProduct extends PosQuery
*/
protected void close()
{
- log.fine("M_Product_ID=" + m_M_Product_ID);
+ if (log.isLoggable(Level.FINE)) log.fine("M_Product_ID=" + m_M_Product_ID);
if (m_M_Product_ID > 0)
{
diff --git a/org.adempiere.ui.swing/src/org/compiere/pos/SubCurrentLine.java b/org.adempiere.ui.swing/src/org/compiere/pos/SubCurrentLine.java
index a9df8564ab..77e2333e7c 100644
--- a/org.adempiere.ui.swing/src/org/compiere/pos/SubCurrentLine.java
+++ b/org.adempiere.ui.swing/src/org/compiere/pos/SubCurrentLine.java
@@ -633,7 +633,7 @@ public class SubCurrentLine extends PosSubPanel implements ActionListener, Focus
*/
public void setM_Product_ID (int M_Product_ID)
{
- log.fine( "PosSubProduct.setM_Product_ID=" + M_Product_ID);
+ if (log.isLoggable(Level.FINE)) log.fine( "PosSubProduct.setM_Product_ID=" + M_Product_ID);
if (M_Product_ID <= 0)
m_product = null;
else
@@ -706,7 +706,7 @@ public class SubCurrentLine extends PosSubPanel implements ActionListener, Focus
if ( lineId <= 0 )
return;
- log.fine("SubCurrentLine - loading line " + lineId);
+ if (log.isLoggable(Level.FINE)) log.fine("SubCurrentLine - loading line " + lineId);
MOrderLine ol = new MOrderLine(p_ctx, lineId, null);
if ( ol != null )
{
diff --git a/org.adempiere.ui.swing/src/org/compiere/pos/SubOrder.java b/org.adempiere.ui.swing/src/org/compiere/pos/SubOrder.java
index 093e423a92..175001b3f2 100644
--- a/org.adempiere.ui.swing/src/org/compiere/pos/SubOrder.java
+++ b/org.adempiere.ui.swing/src/org/compiere/pos/SubOrder.java
@@ -25,6 +25,7 @@ import java.awt.event.KeyEvent;
import java.io.FileOutputStream;
import java.io.IOException;
import java.util.Vector;
+import java.util.logging.Level;
import javax.swing.DefaultComboBoxModel;
import javax.swing.JFormattedTextField;
@@ -408,7 +409,7 @@ public class SubOrder extends PosSubPanel
*/
public void setC_BPartner_ID (int C_BPartner_ID)
{
- log.fine( "PosSubCustomer.setC_BPartner_ID=" + C_BPartner_ID);
+ if (log.isLoggable(Level.FINE)) log.fine( "PosSubCustomer.setC_BPartner_ID=" + C_BPartner_ID);
if (C_BPartner_ID == 0)
m_bpartner = null;
else
diff --git a/org.adempiere.ui.swing/src/org/compiere/report/core/ResultTable.java b/org.adempiere.ui.swing/src/org/compiere/report/core/ResultTable.java
index fd93b8c255..88948d77a2 100644
--- a/org.adempiere.ui.swing/src/org/compiere/report/core/ResultTable.java
+++ b/org.adempiere.ui.swing/src/org/compiere/report/core/ResultTable.java
@@ -142,7 +142,7 @@ public class ResultTable extends JTable implements MouseListener
public void tableChanged(TableModelEvent e)
{
super.tableChanged(e);
- log.fine("Type=" + e.getType());
+ if (log.isLoggable(Level.FINE)) log.fine("Type=" + e.getType());
} // tableChanged
/*************************************************************************/
@@ -154,7 +154,7 @@ public class ResultTable extends JTable implements MouseListener
public void mouseClicked(MouseEvent e)
{
int col = getColumnModel().getColumnIndexAtX(e.getX());
- log.fine("Column " + col + " = " + getColumnModel().getColumn(col).getHeaderValue()
+ if (log.isLoggable(Level.FINE)) log.fine("Column " + col + " = " + getColumnModel().getColumn(col).getHeaderValue()
+ ", Table r=" + this.getSelectedRow() + " c=" + this.getSelectedColumn());
// clicked Cell
diff --git a/org.adempiere.ui.swing/src/org/compiere/swing/ColorBlind.java b/org.adempiere.ui.swing/src/org/compiere/swing/ColorBlind.java
index 0eb244ae2a..10a46e4260 100644
--- a/org.adempiere.ui.swing/src/org/compiere/swing/ColorBlind.java
+++ b/org.adempiere.ui.swing/src/org/compiere/swing/ColorBlind.java
@@ -281,7 +281,7 @@ public class ColorBlind
// System.out.println("Red: " + red * 255.0 + " Green: " + green * 255.0 + " Blue: " + blue * 255.0);
Color retValue = new Color((float)red, (float)green, (float)blue);
- log.fine("Color " + color.getRed() + "-" + color.getGreen() + "-" + color.getBlue()
+ if (log.isLoggable(Level.FINE)) log.fine("Color " + color.getRed() + "-" + color.getGreen() + "-" + color.getBlue()
+ " -> " + retValue.getRed() + "-" + retValue.getGreen() + "-" + retValue.getBlue() + " <- " + COLORBLIND_TYPE[colorType]);
return retValue;
diff --git a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/ValuePreference.java b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/ValuePreference.java
index 4d9268df66..60b9c53734 100644
--- a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/ValuePreference.java
+++ b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/ValuePreference.java
@@ -484,7 +484,7 @@ public class ValuePreference extends Window implements EventListener
sql.append(" AND AD_Window_ID IS NULL");
sql.append(" AND Attribute='").append(m_Attribute).append("'");
//
- log.fine( sql.toString());
+ if (log.isLoggable(Level.FINE)) log.fine( sql.toString());
int no = DB.executeUpdate(sql.toString(), null);
if (no > 0)
Env.setContext(m_ctx, getContextKey(), (String)null);
@@ -548,7 +548,7 @@ public class ValuePreference extends Window implements EventListener
//
sql.append(DB.TO_STRING(m_Attribute)).append(",").append(DB.TO_STRING(m_Value)).append(")");
//
- log.fine( sql.toString());
+ if (log.isLoggable(Level.FINE)) log.fine( sql.toString());
no = DB.executeUpdate(sql.toString(), null);
if (no == 1)
{
diff --git a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/WZoomAcross.java b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/WZoomAcross.java
index a813f5159a..bcbb236cab 100644
--- a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/WZoomAcross.java
+++ b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/WZoomAcross.java
@@ -105,7 +105,7 @@ public class WZoomAcross
windowID)) {
if (zoomInfo.query.getRecordCount() == 0) {
- log.fine("No target records for destination "
+ if (log.isLoggable(Level.FINE)) log.fine("No target records for destination "
+ zoomInfo.destinationDisplay);
continue;
}
diff --git a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/adwindow/ADSortTab.java b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/adwindow/ADSortTab.java
index 9e7c6f8e48..455f4dcdd9 100644
--- a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/adwindow/ADSortTab.java
+++ b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/adwindow/ADSortTab.java
@@ -192,32 +192,32 @@ public class ADSortTab extends Panel implements IADTabpanel
// Sort Column
if (AD_ColumnSortOrder_ID == rs.getInt(2))
{
- log.fine("Sort=" + rs.getString(1) + "." + rs.getString(3));
+ if (log.isLoggable(Level.FINE)) log.fine("Sort=" + rs.getString(1) + "." + rs.getString(3));
m_ColumnSortName = rs.getString(3);
yesLabel.setValue(rs.getString(4));
}
// Optional YesNo
else if (AD_ColumnSortYesNo_ID == rs.getInt(2))
{
- log.fine("YesNo=" + rs.getString(1) + "." + rs.getString(3));
+ if (log.isLoggable(Level.FINE)) log.fine("YesNo=" + rs.getString(1) + "." + rs.getString(3));
m_ColumnYesNoName = rs.getString(3);
}
// Parent2
else if (rs.getString(5).equals("Y"))
{
- log.fine("Parent=" + rs.getString(1) + "." + rs.getString(3));
+ if (log.isLoggable(Level.FINE)) log.fine("Parent=" + rs.getString(1) + "." + rs.getString(3));
m_ParentColumnName = rs.getString(3);
}
// KeyColumn
else if (rs.getString(6).equals("Y"))
{
- log.fine("Key=" + rs.getString(1) + "." + rs.getString(3));
+ if (log.isLoggable(Level.FINE)) log.fine("Key=" + rs.getString(1) + "." + rs.getString(3));
m_KeyColumnName = rs.getString(3);
}
// Identifier
else if (rs.getString(7).equals("Y"))
{
- log.fine("Identifier=" + rs.getString(1) + "." + rs.getString(3));
+ if (log.isLoggable(Level.FINE)) log.fine("Identifier=" + rs.getString(1) + "." + rs.getString(3));
boolean isTranslated = trl && "Y".equals(rs.getString(8));
if (identifierSql.length() > 0)
identifierSql.append(",");
@@ -228,7 +228,7 @@ public class ADSortTab extends Panel implements IADTabpanel
m_IdentifierTranslated = true;
}
else
- log.fine("??NotUsed??=" + rs.getString(1) + "." + rs.getString(3));
+ if (log.isLoggable(Level.FINE)) log.fine("??NotUsed??=" + rs.getString(1) + "." + rs.getString(3));
}
}
catch (SQLException e)
@@ -403,7 +403,7 @@ public class ADSortTab extends Panel implements IADTabpanel
if(m_ParentColumnName != null)
{
ID = Env.getContextAsInt(Env.getCtx(), m_WindowNo, m_ParentColumnName);
- log.fine(sql.toString() + " - ID=" + ID);
+ if (log.isLoggable(Level.FINE)) log.fine(sql.toString() + " - ID=" + ID);
}
else
{
diff --git a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/apps/ProcessParameterPanel.java b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/apps/ProcessParameterPanel.java
index 0e0f17f69c..8b2725422b 100644
--- a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/apps/ProcessParameterPanel.java
+++ b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/apps/ProcessParameterPanel.java
@@ -481,7 +481,7 @@ public class ProcessParameterPanel extends Panel implements
para.setInfo_To(editor2.getDisplay());
//
para.saveEx();
- log.fine(para.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(para.toString());
} // for every parameter
return true;
@@ -576,7 +576,7 @@ public class ProcessParameterPanel extends Panel implements
// if the lookup is dynamic (i.e. contains this columnName as variable)
if (mLookup.getValidation().indexOf("@"+columnName+"@") != -1)
{
- log.fine(columnName + " changed - "
+ if (log.isLoggable(Level.FINE)) log.fine(columnName + " changed - "
+ field.getColumnName() + " set to null");
// invalidate current selection
field.setValue(null, true);
diff --git a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/apps/WProcessCtl.java b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/apps/WProcessCtl.java
index 7c174ae8c7..ca9994d3b9 100644
--- a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/apps/WProcessCtl.java
+++ b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/apps/WProcessCtl.java
@@ -16,6 +16,8 @@
*****************************************************************************/
package org.adempiere.webui.apps;
+import java.util.logging.Level;
+
import org.adempiere.util.IProcessUI;
import org.adempiere.webui.component.Window;
import org.compiere.apps.AbstractProcessCtl;
@@ -54,7 +56,7 @@ public class WProcessCtl extends AbstractProcessCtl {
*/
public static void process (int WindowNo, ProcessInfo pi, Trx trx)
{
- log.fine("WindowNo=" + WindowNo + " - " + pi);
+ if (log.isLoggable(Level.FINE)) log.fine("WindowNo=" + WindowNo + " - " + pi);
MPInstance instance = null;
try
@@ -112,7 +114,7 @@ public class WProcessCtl extends AbstractProcessCtl {
*/
public static void process(IProcessUI aProcessUI, int WindowNo, IProcessParameter parameter, ProcessInfo pi, Trx trx)
{
- log.fine("WindowNo=" + WindowNo + " - " + pi);
+ if (log.isLoggable(Level.FINE)) log.fine("WindowNo=" + WindowNo + " - " + pi);
MPInstance instance = null;
try
diff --git a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/apps/form/WBOMDrop.java b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/apps/form/WBOMDrop.java
index 38d5780c31..01ba67c4d1 100644
--- a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/apps/form/WBOMDrop.java
+++ b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/apps/form/WBOMDrop.java
@@ -422,7 +422,7 @@ public class WBOMDrop extends ADForm implements EventListener
grpSelectProd.appendChild(new Separator());
}
- log.fine("#" + bomLines.length);
+ if (log.isLoggable(Level.FINE)) log.fine("#" + bomLines.length);
} // addBOMLines
/**
@@ -434,7 +434,7 @@ public class WBOMDrop extends ADForm implements EventListener
private void addBOMLine (MProductBOM line, BigDecimal qty)
{
- log.fine(line.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(line.toString());
String bomType = line.getBOMType();
if (bomType == null)
@@ -465,7 +465,7 @@ public class WBOMDrop extends ADForm implements EventListener
private void addDisplay (int parentM_Product_ID,
int M_Product_ID, String bomType, String name, BigDecimal lineQty)
{
- log.fine("M_Product_ID=" + M_Product_ID + ",Type=" + bomType + ",Name=" + name + ",Qty=" + lineQty);
+ if (log.isLoggable(Level.FINE)) log.fine("M_Product_ID=" + M_Product_ID + ",Type=" + bomType + ",Name=" + name + ",Qty=" + lineQty);
boolean selected = true;
@@ -507,7 +507,7 @@ public class WBOMDrop extends ADForm implements EventListener
if (group == null)
{
- log.fine("ButtonGroup=" + groupName);
+ if (log.isLoggable(Level.FINE)) log.fine("ButtonGroup=" + groupName);
group = new Radiogroup();
m_buttonGroups.put(groupName, group);
group.appendChild(b);
diff --git a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/apps/form/WResetPassword.java b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/apps/form/WResetPassword.java
index 7274f49851..1da5d18c93 100644
--- a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/apps/form/WResetPassword.java
+++ b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/apps/form/WResetPassword.java
@@ -266,13 +266,13 @@ public class WResetPassword implements IFormController, EventListener, Va
String p_NewEMailUserPW = txtNewEMailUserPW.getValue();
MUser user = MUser.get(Env.getCtx(), p_AD_User_ID);
- log.fine("User=" + user);
+ if (log.isLoggable(Level.FINE)) log.fine("User=" + user);
// Do we need a password ?
if (Util.isEmpty(p_OldPassword)) // Password required
{
MUser operator = MUser.get(Env.getCtx(), Env.getAD_User_ID(Env.getCtx()));
- log.fine("Operator=" + operator);
+ if (log.isLoggable(Level.FINE)) log.fine("Operator=" + operator);
if (p_AD_User_ID == 0 // change of System
|| p_AD_User_ID == 100 // change of SuperUser
diff --git a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/apps/wf/WFPanel.java b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/apps/wf/WFPanel.java
index 8327461fc6..0c0072553f 100644
--- a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/apps/wf/WFPanel.java
+++ b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/apps/wf/WFPanel.java
@@ -150,7 +150,7 @@ public class WFPanel extends Borderlayout implements EventListener
*/
public void load (int AD_Workflow_ID)
{
- log.fine("AD_Workflow_ID=" + AD_Workflow_ID);
+ if (log.isLoggable(Level.FINE)) log.fine("AD_Workflow_ID=" + AD_Workflow_ID);
if (AD_Workflow_ID == 0)
return;
// Get Workflow
diff --git a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/apps/wf/WWFActivity.java b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/apps/wf/WWFActivity.java
index 40f94d37cd..af390625e1 100644
--- a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/apps/wf/WWFActivity.java
+++ b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/apps/wf/WWFActivity.java
@@ -397,7 +397,7 @@ public class WWFActivity extends ADForm implements EventListener
m_activities = new MWFActivity[list.size ()];
list.toArray (m_activities);
//
- log.fine("#" + m_activities.length
+ if (log.isLoggable(Level.FINE)) log.fine("#" + m_activities.length
+ "(" + (System.currentTimeMillis()-start) + "ms)");
m_index = 0;
@@ -488,7 +488,7 @@ public class WWFActivity extends ADForm implements EventListener
*/
public void display (int index)
{
- log.fine("Index=" + index);
+ if (log.isLoggable(Level.FINE)) log.fine("Index=" + index);
//
m_activity = resetDisplay(index);
// Nothing to show
diff --git a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/component/ADTreeOnDropListener.java b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/component/ADTreeOnDropListener.java
index 60f9e2bd81..c2bdcfb0aa 100644
--- a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/component/ADTreeOnDropListener.java
+++ b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/component/ADTreeOnDropListener.java
@@ -12,6 +12,8 @@
*****************************************************************************/
package org.adempiere.webui.component;
+import java.util.logging.Level;
+
import org.adempiere.webui.util.TreeUtils;
import org.adempiere.webui.window.FDialog;
import org.compiere.model.MTree;
@@ -65,7 +67,7 @@ public class ADTreeOnDropListener implements EventListener {
public void onEvent(Event event) throws Exception {
if (event instanceof DropEvent) {
DropEvent de = (DropEvent) event;
- log.fine("Source=" + de.getDragged() + " Target=" + de.getTarget());
+ if (log.isLoggable(Level.FINE)) log.fine("Source=" + de.getDragged() + " Target=" + de.getTarget());
if (de.getDragged() != de.getTarget()) {
Treeitem src = (Treeitem) ((Treerow) de.getDragged()).getParent();
Treeitem target = (Treeitem) ((Treerow) de.getTarget()).getParent();
@@ -172,7 +174,7 @@ public class ADTreeOnDropListener implements EventListener {
.append(", Updated=SysDate")
.append(" WHERE AD_Tree_ID=").append(mTree.getAD_Tree_ID())
.append(" AND Node_ID=").append(md.getNode_ID());
- log.fine(sql.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(sql.toString());
no = DB.executeUpdate(sql.toString(),trx.getTrxName());
}
if (oldParent != newParent)
@@ -189,7 +191,7 @@ public class ADTreeOnDropListener implements EventListener {
.append(", Updated=SysDate")
.append(" WHERE AD_Tree_ID=").append(mTree.getAD_Tree_ID())
.append(" AND Node_ID=").append(md.getNode_ID());
- log.fine(sql.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(sql.toString());
no = DB.executeUpdate(sql.toString(),trx.getTrxName());
}
}
diff --git a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/dashboard/RequestWindow.java b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/dashboard/RequestWindow.java
index 982e2b7d34..2f5f15b098 100644
--- a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/dashboard/RequestWindow.java
+++ b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/dashboard/RequestWindow.java
@@ -14,6 +14,7 @@
package org.adempiere.webui.dashboard;
import java.sql.Timestamp;
+import java.util.logging.Level;
import org.adempiere.webui.component.Borderlayout;
import org.adempiere.webui.component.Column;
@@ -290,7 +291,7 @@ public class RequestWindow extends Window implements EventListener {
if (request.save())
{
- log.fine("R_Request_ID=" + request.getR_Request_ID());
+ if (log.isLoggable(Level.FINE)) log.fine("R_Request_ID=" + request.getR_Request_ID());
Events.postEvent("onRefresh", parent, null);
// Events.echoEvent("onRefresh", parent, null);
}
diff --git a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/editor/WImageEditor.java b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/editor/WImageEditor.java
index 7692eb6507..bad8670ea9 100644
--- a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/editor/WImageEditor.java
+++ b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/editor/WImageEditor.java
@@ -132,7 +132,7 @@ public class WImageEditor extends WEditor
if (m_mImage == null || newValue != m_mImage.get_ID())
m_mImage = MImage.get (Env.getCtx(), newValue);
//
- log.fine(m_mImage.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(m_mImage.toString());
AImage img = null;
byte[] data = m_mImage.getData();
if (data != null && data.length > 0) {
diff --git a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/editor/WPAttributeEditor.java b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/editor/WPAttributeEditor.java
index e16beedfec..b7db382cec 100644
--- a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/editor/WPAttributeEditor.java
+++ b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/editor/WPAttributeEditor.java
@@ -103,7 +103,7 @@ public class WPAttributeEditor extends WEditor implements ContextMenuListener
if (value.equals(m_value))
return;
// new value
- log.fine("Value=" + value);
+ if (log.isLoggable(Level.FINE)) log.fine("Value=" + value);
m_value = value;
getComponent().setText(m_mPAttribute.getDisplay(value)); // loads value
}
diff --git a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/grid/WBPartner.java b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/grid/WBPartner.java
index bc97f88443..e1ea5d4799 100644
--- a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/grid/WBPartner.java
+++ b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/grid/WBPartner.java
@@ -437,7 +437,7 @@ public class WBPartner extends Window implements EventListener, ValueChan
m_partner.setC_Greeting_ID(0);
if (m_partner.save())
- log.fine("C_BPartner_ID=" + m_partner.getC_BPartner_ID());
+ if (log.isLoggable(Level.FINE)) log.fine("C_BPartner_ID=" + m_partner.getC_BPartner_ID());
else {
FDialog.error(m_WindowNo, this, "BPartnerNotSaved");
m_partner = null;
@@ -456,7 +456,7 @@ public class WBPartner extends Window implements EventListener, ValueChan
m_pLocation.setFax(fFax.getText());
if (m_pLocation.save())
- log.fine("C_BPartner_Location_ID=" + m_pLocation.getC_BPartner_Location_ID());
+ if (log.isLoggable(Level.FINE)) log.fine("C_BPartner_Location_ID=" + m_pLocation.getC_BPartner_Location_ID());
else
FDialog.error(m_WindowNo, this, "BPartnerNotSaved", Msg.translate(Env.getCtx(), "C_BPartner_Location_ID"));
@@ -490,7 +490,7 @@ public class WBPartner extends Window implements EventListener, ValueChan
m_user.setFax(fFax.getText());
if (m_user.save())
- log.fine("AD_User_ID=" + m_user.getAD_User_ID());
+ if (log.isLoggable(Level.FINE)) log.fine("AD_User_ID=" + m_user.getAD_User_ID());
else
FDialog.error(m_WindowNo, this, "BPartnerNotSaved", Msg.translate(Env.getCtx(), "AD_User_ID"));
}
diff --git a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/panel/InfoAssetPanel.java b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/panel/InfoAssetPanel.java
index 0da3a174b9..d074d41cb1 100644
--- a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/panel/InfoAssetPanel.java
+++ b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/panel/InfoAssetPanel.java
@@ -20,6 +20,7 @@ package org.adempiere.webui.panel;
import java.sql.PreparedStatement;
import java.sql.SQLException;
import java.sql.Timestamp;
+import java.util.logging.Level;
import org.adempiere.webui.apps.AEnv;
import org.adempiere.webui.component.Grid;
@@ -324,7 +325,7 @@ public class InfoAssetPanel extends InfoPanel implements ValueChangeListener, Ev
value += "%";
pstmt.setString(index++, value);
- log.fine("Value: " + value);
+ if (log.isLoggable(Level.FINE)) log.fine("Value: " + value);
}
// => Name
@@ -337,7 +338,7 @@ public class InfoAssetPanel extends InfoPanel implements ValueChangeListener, Ev
name += "%";
pstmt.setString(index++, name);
- log.fine("Name: " + name);
+ if (log.isLoggable(Level.FINE)) log.fine("Name: " + name);
}
} // setParameters
diff --git a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/panel/InfoBPartnerPanel.java b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/panel/InfoBPartnerPanel.java
index 14d068ddab..a02e9ef782 100644
--- a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/panel/InfoBPartnerPanel.java
+++ b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/panel/InfoBPartnerPanel.java
@@ -21,6 +21,7 @@ import java.math.BigDecimal;
import java.sql.PreparedStatement;
import java.sql.SQLException;
import java.util.ArrayList;
+import java.util.logging.Level;
import org.adempiere.webui.AdempiereWebUI;
import org.adempiere.webui.apps.AEnv;
@@ -354,7 +355,7 @@ public class InfoBPartnerPanel extends InfoPanel implements EventListener
if (!value.endsWith("%"))
value += "%";
pstmt.setString(index++, value);
- log.fine("Value: " + value);
+ if (log.isLoggable(Level.FINE)) log.fine("Value: " + value);
}
// => Name
String name = fieldName.getText().toUpperCase();
@@ -363,7 +364,7 @@ public class InfoBPartnerPanel extends InfoPanel implements EventListener
if (!name.endsWith("%"))
name += "%";
pstmt.setString(index++, name);
- log.fine("Name: " + name);
+ if (log.isLoggable(Level.FINE)) log.fine("Name: " + name);
}
// => Contact
String contact = fieldContact.getText().toUpperCase();
@@ -372,7 +373,7 @@ public class InfoBPartnerPanel extends InfoPanel implements EventListener
if (!contact.endsWith("%"))
contact += "%";
pstmt.setString(index++, contact);
- log.fine("Contact: " + contact);
+ if (log.isLoggable(Level.FINE)) log.fine("Contact: " + contact);
}
// => EMail
String email = fieldEMail.getText().toUpperCase();
@@ -381,7 +382,7 @@ public class InfoBPartnerPanel extends InfoPanel implements EventListener
if (!email.endsWith("%"))
email += "%";
pstmt.setString(index++, email);
- log.fine("EMail: " + email);
+ if (log.isLoggable(Level.FINE)) log.fine("EMail: " + email);
}
// => Phone
String phone = fieldPhone.getText().toUpperCase();
@@ -390,7 +391,7 @@ public class InfoBPartnerPanel extends InfoPanel implements EventListener
if (!phone.endsWith("%"))
phone += "%";
pstmt.setString(index++, phone);
- log.fine("Phone: " + phone);
+ if (log.isLoggable(Level.FINE)) log.fine("Phone: " + phone);
}
// => Postal
String postal = fieldPostal.getText().toUpperCase();
@@ -399,7 +400,7 @@ public class InfoBPartnerPanel extends InfoPanel implements EventListener
if (!postal.endsWith("%"))
postal += "%";
pstmt.setString(index++, postal);
- log.fine("Postal: " + postal);
+ if (log.isLoggable(Level.FINE)) log.fine("Postal: " + postal);
}
} // setParameters
diff --git a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/panel/InfoCashLinePanel.java b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/panel/InfoCashLinePanel.java
index 5672530611..143029c265 100644
--- a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/panel/InfoCashLinePanel.java
+++ b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/panel/InfoCashLinePanel.java
@@ -22,6 +22,7 @@ import java.sql.PreparedStatement;
import java.sql.SQLException;
import java.sql.Timestamp;
import java.util.Date;
+import java.util.logging.Level;
import org.adempiere.webui.component.Checkbox;
import org.adempiere.webui.component.Datebox;
@@ -366,7 +367,7 @@ public class InfoCashLinePanel extends InfoPanel implements ValueChangeListener,
}
}
- log.fine(sql.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(sql.toString());
return sql.toString();
} // getSQLWhere
@@ -392,14 +393,14 @@ public class InfoCashLinePanel extends InfoPanel implements ValueChangeListener,
{
Integer cb = (Integer)fCashBook_ID.getValue();
pstmt.setInt(index++, cb.intValue());
- log.fine("CashBook=" + cb);
+ if (log.isLoggable(Level.FINE)) log.fine("CashBook=" + cb);
}
if (fInvoice_ID.getValue() != null)
{
Integer i = (Integer)fInvoice_ID.getValue();
pstmt.setInt(index++, i.intValue());
- log.fine("Invoice=" + i);
+ if (log.isLoggable(Level.FINE)) log.fine("Invoice=" + i);
}
if (fDateFrom.getValue() != null || fDateTo.getValue() != null)
@@ -414,7 +415,7 @@ public class InfoCashLinePanel extends InfoPanel implements ValueChangeListener,
if (t != null)
to = new Timestamp(t.getTime());
- log.fine("Date From=" + from + ", To=" + to);
+ if (log.isLoggable(Level.FINE)) log.fine("Date From=" + from + ", To=" + to);
if (from == null && to != null)
pstmt.setTimestamp(index++, to);
@@ -440,7 +441,7 @@ public class InfoCashLinePanel extends InfoPanel implements ValueChangeListener,
to = to.abs();
}
- log.fine("Amt From=" + from + ", To=" + to + ", Absolute=" + cbAbsolute.isChecked());
+ if (log.isLoggable(Level.FINE)) log.fine("Amt From=" + from + ", To=" + to + ", Absolute=" + cbAbsolute.isChecked());
if (from == null && to != null)
pstmt.setBigDecimal(index++, to);
@@ -472,7 +473,7 @@ public class InfoCashLinePanel extends InfoPanel implements ValueChangeListener,
if (!s.endsWith("%"))
s += "%";
- log.fine( "String=" + s);
+ if (log.isLoggable(Level.FINE)) log.fine( "String=" + s);
return s;
} // getSQLText
diff --git a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/panel/InfoGeneralPanel.java b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/panel/InfoGeneralPanel.java
index af4962ced9..119ec82857 100644
--- a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/panel/InfoGeneralPanel.java
+++ b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/panel/InfoGeneralPanel.java
@@ -463,7 +463,7 @@ public class InfoGeneralPanel extends InfoPanel implements EventListener
String s = f.getText().toUpperCase();
if (!s.endsWith("%"))
s += "%";
- log.fine( "String=" + s);
+ if (log.isLoggable(Level.FINE)) log.fine( "String=" + s);
return s;
} // getSQLText
diff --git a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/panel/InfoInOutPanel.java b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/panel/InfoInOutPanel.java
index 58c41470e6..2fbebc845e 100644
--- a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/panel/InfoInOutPanel.java
+++ b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/panel/InfoInOutPanel.java
@@ -21,6 +21,7 @@ import java.sql.PreparedStatement;
import java.sql.SQLException;
import java.sql.Timestamp;
import java.util.Date;
+import java.util.logging.Level;
import org.adempiere.webui.AdempiereWebUI;
import org.adempiere.webui.apps.AEnv;
@@ -357,7 +358,7 @@ public class InfoInOutPanel extends InfoPanel implements ValueChangeListener, Ev
{
Integer bp = (Integer)fBPartner_ID.getValue();
pstmt.setInt(index++, bp.intValue());
- log.fine("BPartner=" + bp);
+ if (log.isLoggable(Level.FINE)) log.fine("BPartner=" + bp);
}
if (fDateFrom.getValue() != null || fDateTo.getValue() != null)
@@ -372,7 +373,7 @@ public class InfoInOutPanel extends InfoPanel implements ValueChangeListener, Ev
if (t != null)
to = new Timestamp(t.getTime());
- log.fine("Date From=" + from + ", To=" + to);
+ if (log.isLoggable(Level.FINE)) log.fine("Date From=" + from + ", To=" + to);
if (from == null && to != null)
pstmt.setTimestamp(index++, to);
@@ -400,7 +401,7 @@ public class InfoInOutPanel extends InfoPanel implements ValueChangeListener, Ev
if (!s.endsWith("%"))
s += "%";
- log.fine( "String=" + s);
+ if (log.isLoggable(Level.FINE)) log.fine( "String=" + s);
return s;
} // getSQLText
diff --git a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/panel/InfoInvoicePanel.java b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/panel/InfoInvoicePanel.java
index a44287cb93..c0a3c79ee2 100644
--- a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/panel/InfoInvoicePanel.java
+++ b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/panel/InfoInvoicePanel.java
@@ -417,14 +417,14 @@ public class InfoInvoicePanel extends InfoPanel implements ValueChangeListener
{
Integer bp = (Integer)editorBPartner.getValue();
pstmt.setInt(index++, bp.intValue());
- log.fine("BPartner=" + bp);
+ if (log.isLoggable(Level.FINE)) log.fine("BPartner=" + bp);
}
//
if (editorOrder.getValue() != null)
{
Integer order = (Integer)editorOrder.getValue();
pstmt.setInt(index++, order.intValue());
- log.fine("Order=" + order);
+ if (log.isLoggable(Level.FINE)) log.fine("Order=" + order);
}
Date fromD = null;
Date toD = null;
@@ -455,7 +455,7 @@ public class InfoInvoicePanel extends InfoPanel implements ValueChangeListener
}
- log.fine("Date From=" + from + ", To=" + to);
+ if (log.isLoggable(Level.FINE)) log.fine("Date From=" + from + ", To=" + to);
if (from == null && to != null)
{
pstmt.setTimestamp(index++, to);
@@ -530,7 +530,7 @@ public class InfoInvoicePanel extends InfoPanel implements ValueChangeListener
String s = f.getText().toUpperCase();
if (!s.endsWith("%"))
s += "%";
- log.fine("String=" + s);
+ if (log.isLoggable(Level.FINE)) log.fine("String=" + s);
return s;
} // getSQLText
diff --git a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/panel/InfoOrderPanel.java b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/panel/InfoOrderPanel.java
index 6863d30564..b3c00f12e2 100644
--- a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/panel/InfoOrderPanel.java
+++ b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/panel/InfoOrderPanel.java
@@ -393,7 +393,7 @@ public class InfoOrderPanel extends InfoPanel implements ValueChangeListener
{
Integer bp = (Integer)editorBPartner.getValue();
pstmt.setInt(index++, bp.intValue());
- log.fine("BPartner=" + bp);
+ if (log.isLoggable(Level.FINE)) log.fine("BPartner=" + bp);
}
//
@@ -426,7 +426,7 @@ public class InfoOrderPanel extends InfoPanel implements ValueChangeListener
}
- log.fine("Date From=" + from + ", To=" + to);
+ if (log.isLoggable(Level.FINE)) log.fine("Date From=" + from + ", To=" + to);
if (from == null && to != null)
{
pstmt.setTimestamp(index++, to);
@@ -501,7 +501,7 @@ public class InfoOrderPanel extends InfoPanel implements ValueChangeListener
String s = f.getText().toUpperCase();
if (!s.endsWith("%"))
s += "%";
- log.fine("String=" + s);
+ if (log.isLoggable(Level.FINE)) log.fine("String=" + s);
return s;
} // getSQLText
diff --git a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/panel/InfoPAttributeInstancePanel.java b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/panel/InfoPAttributeInstancePanel.java
index a636f78a37..ad4ae3f798 100644
--- a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/panel/InfoPAttributeInstancePanel.java
+++ b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/panel/InfoPAttributeInstancePanel.java
@@ -339,7 +339,7 @@ public class InfoPAttributeInstancePanel extends Window implements EventListener
}
}
confirmPanel.getOKButton().setEnabled(enabled);
- log.fine("M_AttributeSetInstance_ID=" + m_M_AttributeSetInstance_ID
+ if (log.isLoggable(Level.FINE)) log.fine("M_AttributeSetInstance_ID=" + m_M_AttributeSetInstance_ID
+ " - " + m_M_AttributeSetInstanceName
+ "; M_Locator_ID=" + m_M_Locator_ID);
} // enableButtons
diff --git a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/panel/InfoPaymentPanel.java b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/panel/InfoPaymentPanel.java
index aea35694dd..028ab63fa6 100644
--- a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/panel/InfoPaymentPanel.java
+++ b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/panel/InfoPaymentPanel.java
@@ -22,6 +22,7 @@ import java.sql.PreparedStatement;
import java.sql.SQLException;
import java.sql.Timestamp;
import java.util.Date;
+import java.util.logging.Level;
import org.adempiere.webui.apps.AEnv;
import org.adempiere.webui.component.Checkbox;
@@ -360,7 +361,7 @@ public class InfoPaymentPanel extends InfoPanel implements ValueChangeListener,
sql.append(" AND p.IsReceipt=?");
- log.fine(sql.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(sql.toString());
return sql.toString();
} // getSQLWhere
@@ -383,7 +384,7 @@ public class InfoPaymentPanel extends InfoPanel implements ValueChangeListener,
{
Integer bp = (Integer)fBPartner_ID.getValue();
pstmt.setInt(index++, bp.intValue());
- log.fine("BPartner=" + bp);
+ if (log.isLoggable(Level.FINE)) log.fine("BPartner=" + bp);
}
if (fDateFrom.getValue() != null || fDateTo.getValue() != null)
@@ -398,7 +399,7 @@ public class InfoPaymentPanel extends InfoPanel implements ValueChangeListener,
if (t != null)
to = new Timestamp(t.getTime());
- log.fine("Date From=" + from + ", To=" + to);
+ if (log.isLoggable(Level.FINE)) log.fine("Date From=" + from + ", To=" + to);
if (from == null && to != null)
pstmt.setTimestamp(index++, to);
@@ -433,7 +434,7 @@ public class InfoPaymentPanel extends InfoPanel implements ValueChangeListener,
}
}
- log.fine("Amt From=" + from + ", To=" + to);
+ if (log.isLoggable(Level.FINE)) log.fine("Amt From=" + from + ", To=" + to);
if (from == null && to != null)
pstmt.setBigDecimal(index++, to);
@@ -462,7 +463,7 @@ public class InfoPaymentPanel extends InfoPanel implements ValueChangeListener,
if (!s.endsWith("%"))
s += "%";
- log.fine( "String=" + s);
+ if (log.isLoggable(Level.FINE)) log.fine( "String=" + s);
return s;
} // getSQLText
diff --git a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/panel/InfoProductPanel.java b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/panel/InfoProductPanel.java
index e0c28cd45d..59939ff9f8 100644
--- a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/panel/InfoProductPanel.java
+++ b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/panel/InfoProductPanel.java
@@ -644,7 +644,7 @@ public class InfoProductPanel extends InfoPanel implements EventListener
rs = null; pstmt = null;
}
- log.fine("#" + m_count + " - " + (System.currentTimeMillis()-start) + "ms");
+ if (log.isLoggable(Level.FINE)) log.fine("#" + m_count + " - " + (System.currentTimeMillis()-start) + "ms");
return true;
}
@@ -1050,7 +1050,7 @@ public class InfoProductPanel extends InfoPanel implements EventListener
pstmt.setInt(index++, M_Warehouse_ID);
}
}
- log.fine("M_Warehouse_ID=" + M_Warehouse_ID + " (" + (index-1) + "*)");
+ if (log.isLoggable(Level.FINE)) log.fine("M_Warehouse_ID=" + M_Warehouse_ID + " (" + (index-1) + "*)");
// => PriceList
int M_PriceList_Version_ID = 0;
@@ -1060,20 +1060,20 @@ public class InfoProductPanel extends InfoPanel implements EventListener
if (M_PriceList_Version_ID != 0)
{
pstmt.setInt(index++, M_PriceList_Version_ID);
- log.fine("M_PriceList_Version_ID=" + M_PriceList_Version_ID);
+ if (log.isLoggable(Level.FINE)) log.fine("M_PriceList_Version_ID=" + M_PriceList_Version_ID);
}
// Elaine 2008/11/29
// => Product Category
int M_Product_Category_ID = getM_Product_Category_ID();
if (M_Product_Category_ID > 0) {
pstmt.setInt(index++, M_Product_Category_ID);
- log.fine("M_Product_Category_ID=" + M_Product_Category_ID);
+ if (log.isLoggable(Level.FINE)) log.fine("M_Product_Category_ID=" + M_Product_Category_ID);
}
//
int M_AttributeSet_ID = getM_AttributeSet_ID();
if (M_AttributeSet_ID > 0) {
pstmt.setInt(index++, M_AttributeSet_ID);
- log.fine("M_AttributeSet_ID=" + M_AttributeSet_ID);
+ if (log.isLoggable(Level.FINE)) log.fine("M_AttributeSet_ID=" + M_AttributeSet_ID);
}
// Rest of Parameter in Query for Attribute Search
if (m_pAttributeWhere != null)
@@ -1086,7 +1086,7 @@ public class InfoProductPanel extends InfoPanel implements EventListener
if (!value.endsWith("%"))
value += "%";
pstmt.setString(index++, value);
- log.fine("Value: " + value);
+ if (log.isLoggable(Level.FINE)) log.fine("Value: " + value);
}
// => Name
@@ -1096,7 +1096,7 @@ public class InfoProductPanel extends InfoPanel implements EventListener
if (!name.endsWith("%"))
name += "%";
pstmt.setString(index++, name);
- log.fine("Name: " + name);
+ if (log.isLoggable(Level.FINE)) log.fine("Name: " + name);
}
// => UPC
@@ -1106,7 +1106,7 @@ public class InfoProductPanel extends InfoPanel implements EventListener
if (!upc.endsWith("%"))
upc += "%";
pstmt.setString(index++, upc);
- log.fine("UPC: " + upc);
+ if (log.isLoggable(Level.FINE)) log.fine("UPC: " + upc);
}
// => SKU
@@ -1116,7 +1116,7 @@ public class InfoProductPanel extends InfoPanel implements EventListener
if (!sku.endsWith("%"))
sku += "%";
pstmt.setString(index++, sku);
- log.fine("SKU: " + sku);
+ if (log.isLoggable(Level.FINE)) log.fine("SKU: " + sku);
}
// => Vendor
@@ -1126,7 +1126,7 @@ public class InfoProductPanel extends InfoPanel implements EventListener
if (!vendor.endsWith("%"))
vendor += "%";
pstmt.setString(index++, vendor);
- log.fine("Vendor: " + vendor);
+ if (log.isLoggable(Level.FINE)) log.fine("Vendor: " + vendor);
}
} // setParameters
diff --git a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/panel/InvoiceHistory.java b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/panel/InvoiceHistory.java
index 14e2357cbc..dd011a7ec8 100644
--- a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/panel/InvoiceHistory.java
+++ b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/panel/InvoiceHistory.java
@@ -295,7 +295,7 @@ public class InvoiceHistory extends Window implements EventListener
*/
private Vector> fillTable (String sql, int parameter)
{
- log.fine(sql + "; Parameter=" + parameter);
+ if (log.isLoggable(Level.FINE)) log.fine(sql + "; Parameter=" + parameter);
Vector> data = new Vector>();
PreparedStatement pstmt = null;
ResultSet rs = null;
@@ -340,7 +340,7 @@ public class InvoiceHistory extends Window implements EventListener
DB.close(rs, pstmt);
rs = null; pstmt = null;
}
- log.fine("#" + data.size());
+ if (log.isLoggable(Level.FINE)) log.fine("#" + data.size());
return data;
} // fillTable
@@ -350,7 +350,7 @@ public class InvoiceHistory extends Window implements EventListener
*/
private void fillLabel (String sql, int parameter)
{
- log.fine(sql + "; Parameter=" + parameter);
+ if (log.isLoggable(Level.FINE)) log.fine(sql + "; Parameter=" + parameter);
String retValue = DB.getSQLValueString(null, sql, parameter);
if (retValue != null)
label.setText(retValue);
@@ -555,7 +555,7 @@ public class InvoiceHistory extends Window implements EventListener
DB.close(rs, pstmt);
rs = null; pstmt = null;
}
- log.fine("#" + data.size());
+ if (log.isLoggable(Level.FINE)) log.fine("#" + data.size());
// Table
m_modelUnconfirmed = new ListModelTable(data);
diff --git a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/process/InvoicePrint.java b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/process/InvoicePrint.java
index f3a7716069..24d0189ec3 100644
--- a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/process/InvoicePrint.java
+++ b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/process/InvoicePrint.java
@@ -204,7 +204,7 @@ public class InvoicePrint extends SvrProcess
}
}
sql.append(" ORDER BY i.C_Invoice_ID, pf.AD_Org_ID DESC"); // more than 1 PF record
- log.fine(sql.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(sql.toString());
MPrintFormat format = null;
int old_AD_PrintFormat_ID = -1;
@@ -308,7 +308,7 @@ public class InvoicePrint extends SvrProcess
if (!Ini.isClient())
invoice = new File(MInvoice.getPDFFileName(documentDir, C_Invoice_ID));
File attachment = re.getPDF(invoice);
- log.fine(to + " - " + attachment);
+ if (log.isLoggable(Level.FINE)) log.fine(to + " - " + attachment);
email.addAttachment(attachment);
//
String msg = email.send();
diff --git a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/window/FindWindow.java b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/window/FindWindow.java
index f45e56f0df..824ce6de6e 100644
--- a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/window/FindWindow.java
+++ b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/window/FindWindow.java
@@ -1690,7 +1690,7 @@ public class FindWindow extends Window implements EventListener, ValueCha
{
String ColumnName = wed.getColumnName();
StringBuilder msglog = new StringBuilder(ColumnName).append("=").append(value);
- log.fine(msglog.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(msglog.toString());
// globalqss - Carlos Ruiz - 20060711
// fix a bug with virtualColumn + isSelectionColumn not yielding results
@@ -1969,7 +1969,7 @@ public class FindWindow extends Window implements EventListener, ValueCha
ret.append(getSubCategoriesString(node.getNodeId(), categories, loopIndicatorId)).append(",");
}
}
- log.fine(ret.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(ret.toString());
StringBuilder msgreturn = new StringBuilder(ret.toString()).append(productCategoryId);
return msgreturn.toString();
diff --git a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/window/WAccountDialog.java b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/window/WAccountDialog.java
index 2acc32d361..b07af78c32 100644
--- a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/window/WAccountDialog.java
+++ b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/window/WAccountDialog.java
@@ -473,7 +473,7 @@ public final class WAccountDialog extends Window
*/
private void addLine (GridField field, WEditor editor, boolean mandatory)
{
- log.fine("Field=" + field);
+ if (log.isLoggable(Level.FINE)) log.fine("Field=" + field);
Label label = editor.getLabel();
editor.setReadWrite(true);
editor.setMandatory(mandatory);
@@ -508,7 +508,7 @@ public final class WAccountDialog extends Window
*/
private void loadInfo (int C_ValidCombination_ID, int C_AcctSchema_ID)
{
- log.fine("C_ValidCombination_ID=" + C_ValidCombination_ID);
+ if (log.isLoggable(Level.FINE)) log.fine("C_ValidCombination_ID=" + C_ValidCombination_ID);
String sql = "SELECT * FROM C_ValidCombination WHERE C_ValidCombination_ID=? AND C_AcctSchema_ID=?";
PreparedStatement pstmt = null;
ResultSet rs = null;
@@ -912,7 +912,7 @@ public final class WAccountDialog extends Window
* Check if already exists
*/
sql.append("AD_Client_ID=? AND C_AcctSchema_ID=?");
- log.fine("Check = " + sql.toString());
+ if (log.isLoggable(Level.FINE)) log.fine("Check = " + sql.toString());
int IDvalue = 0;
String Alias = null;
PreparedStatement pstmt = null;
@@ -940,7 +940,7 @@ public final class WAccountDialog extends Window
rs = null;
pstmt = null;
}
- log.fine("ID=" + IDvalue + ", Alias=" + Alias);
+ if (log.isLoggable(Level.FINE)) log.fine("ID=" + IDvalue + ", Alias=" + Alias);
if (Alias == null)
Alias = "";
diff --git a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/window/WLocationDialog.java b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/window/WLocationDialog.java
index a518c3a8a2..697a2f1124 100644
--- a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/window/WLocationDialog.java
+++ b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/window/WLocationDialog.java
@@ -336,7 +336,7 @@ public class WLocationDialog extends Window implements EventListener
mainPanel.getRows().getChildren().clear();
MCountry country = m_location.getCountry();
- log.fine(country.getName() + ", Region=" + country.isHasRegion() + " " + country.getCaptureSequence()
+ if (log.isLoggable(Level.FINE)) log.fine(country.getName() + ", Region=" + country.isHasRegion() + " " + country.getCaptureSequence()
+ ", C_Location_ID=" + m_location.getC_Location_ID());
// new Country
if (m_location.getC_Country_ID() != s_oldCountry_ID)
diff --git a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/window/WLocatorDialog.java b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/window/WLocatorDialog.java
index 42c17c8409..818fccb8b6 100644
--- a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/window/WLocatorDialog.java
+++ b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/window/WLocatorDialog.java
@@ -327,13 +327,13 @@ public class WLocatorDialog extends Window implements EventListener
pstmt = null;
}
- log.fine("Warehouses=" + lstWarehouse.getItemCount());
+ if (log.isLoggable(Level.FINE)) log.fine("Warehouses=" + lstWarehouse.getItemCount());
// Load existing Locators
m_mLocator.fillComboBox(m_mandatory, true, true, false, false); // IDEMPIERE 90
- log.fine(m_mLocator.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(m_mLocator.toString());
for (int i = 0; i < m_mLocator.getSize(); i++)
{
diff --git a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/window/WPAttributeDialog.java b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/window/WPAttributeDialog.java
index 5f060b2a66..ec8ef5840e 100644
--- a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/window/WPAttributeDialog.java
+++ b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/window/WPAttributeDialog.java
@@ -298,7 +298,7 @@ public class WPAttributeDialog extends Window implements EventListener
row.appendChild(bNewRecord);
row.appendChild(new Space());
MAttribute[] attributes = as.getMAttributes (false);
- log.fine ("Product Attributes=" + attributes.length);
+ if (log.isLoggable(Level.FINE)) log.fine ("Product Attributes=" + attributes.length);
for (int i = 0; i < attributes.length; i++)
addAttributeLine (rows, attributes[i], true, false);
if (m_M_AttributeSetInstance_ID > 0)
@@ -333,7 +333,7 @@ public class WPAttributeDialog extends Window implements EventListener
// All Attributes
MAttribute[] attributes = as.getMAttributes (true);
- log.fine ("Instance Attributes=" + attributes.length);
+ if (log.isLoggable(Level.FINE)) log.fine ("Instance Attributes=" + attributes.length);
for (int i = 0; i < attributes.length; i++)
addAttributeLine (rows, attributes[i], false, false);
}
@@ -498,7 +498,7 @@ public class WPAttributeDialog extends Window implements EventListener
*/
private void addAttributeLine (Rows rows, MAttribute attribute, boolean product, boolean readOnly)
{
- log.fine(attribute + ", Product=" + product + ", R/O=" + readOnly);
+ if (log.isLoggable(Level.FINE)) log.fine(attribute + ", Product=" + product + ", R/O=" + readOnly);
m_row++;
Label label = new Label (attribute.getName());
@@ -600,12 +600,12 @@ public class WPAttributeDialog extends Window implements EventListener
}
}
if (found)
- log.fine("Attribute=" + attribute.getName() + " #" + values.length + " - found: " + instance);
+ if (log.isLoggable(Level.FINE)) log.fine("Attribute=" + attribute.getName() + " #" + values.length + " - found: " + instance);
else
log.warning("Attribute=" + attribute.getName() + " #" + values.length + " - NOT found: " + instance);
} // setComboBox
else
- log.fine("Attribute=" + attribute.getName() + " #" + values.length + " no instance");
+ if (log.isLoggable(Level.FINE)) log.fine("Attribute=" + attribute.getName() + " #" + values.length + " no instance");
}
/**
@@ -717,7 +717,7 @@ public class WPAttributeDialog extends Window implements EventListener
// Get Attribute Set
MAttributeSet as = m_masi.getMAttributeSet();
MAttribute[] attributes = as.getMAttributes (false);
- log.fine ("Product Attributes=" + attributes.length);
+ if (log.isLoggable(Level.FINE)) log.fine ("Product Attributes=" + attributes.length);
for (int i = 0; i < attributes.length; i++)
updateAttributeEditor(attributes[i], i);
@@ -914,7 +914,7 @@ public class WPAttributeDialog extends Window implements EventListener
String mandatory = "";
if (!m_productWindow && as.isLot())
{
- log.fine("Lot=" + fieldLotString.getText ());
+ if (log.isLoggable(Level.FINE)) log.fine("Lot=" + fieldLotString.getText ());
String text = fieldLotString.getText();
m_masi.setLot (text);
if (as.isLotMandatory() && (text == null || text.length() == 0))
@@ -923,7 +923,7 @@ public class WPAttributeDialog extends Window implements EventListener
} // Lot
if (!m_productWindow && as.isSerNo())
{
- log.fine("SerNo=" + fieldSerNo.getText());
+ if (log.isLoggable(Level.FINE)) log.fine("SerNo=" + fieldSerNo.getText());
String text = fieldSerNo.getText();
m_masi.setSerNo(text);
if (as.isSerNoMandatory() && (text == null || text.length() == 0))
@@ -932,7 +932,7 @@ public class WPAttributeDialog extends Window implements EventListener
} // SerNo
if (!m_productWindow && as.isGuaranteeDate())
{
- log.fine("GuaranteeDate=" + fieldGuaranteeDate.getValue());
+ if (log.isLoggable(Level.FINE)) log.fine("GuaranteeDate=" + fieldGuaranteeDate.getValue());
Date gDate = fieldGuaranteeDate.getValue();
Timestamp ts = gDate != null ? new Timestamp(gDate.getTime()) : null;
m_masi.setGuaranteeDate(ts);
@@ -959,7 +959,7 @@ public class WPAttributeDialog extends Window implements EventListener
Listbox editor = (Listbox)m_editors.get(i);
ListItem item = editor.getSelectedItem();
MAttributeValue value = item != null ? (MAttributeValue)item.getValue() : null;
- log.fine(attributes[i].getName() + "=" + value);
+ if (log.isLoggable(Level.FINE)) log.fine(attributes[i].getName() + "=" + value);
if (attributes[i].isMandatory() && value == null)
mandatory += " - " + attributes[i].getName();
attributes[i].setMAttributeInstance(m_M_AttributeSetInstance_ID, value);
@@ -968,7 +968,7 @@ public class WPAttributeDialog extends Window implements EventListener
{
NumberBox editor = (NumberBox)m_editors.get(i);
BigDecimal value = editor.getValue();
- log.fine(attributes[i].getName() + "=" + value);
+ if (log.isLoggable(Level.FINE)) log.fine(attributes[i].getName() + "=" + value);
if (attributes[i].isMandatory() && value == null)
mandatory += " - " + attributes[i].getName();
//setMAttributeInstance doesn't work without decimal point
@@ -980,7 +980,7 @@ public class WPAttributeDialog extends Window implements EventListener
{
Textbox editor = (Textbox)m_editors.get(i);
String value = editor.getText();
- log.fine(attributes[i].getName() + "=" + value);
+ if (log.isLoggable(Level.FINE)) log.fine(attributes[i].getName() + "=" + value);
if (attributes[i].isMandatory() && (value == null || value.length() == 0))
mandatory += " - " + attributes[i].getName();
attributes[i].setMAttributeInstance(m_M_AttributeSetInstance_ID, value);
diff --git a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/window/WPAttributeInstance.java b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/window/WPAttributeInstance.java
index 7113762ec9..df86416717 100644
--- a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/window/WPAttributeInstance.java
+++ b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/window/WPAttributeInstance.java
@@ -333,7 +333,7 @@ public class WPAttributeInstance extends Window implements EventListener
}
}
confirmPanel.getButton("Ok").setEnabled(enabled);
- log.fine("M_AttributeSetInstance_ID=" + m_M_AttributeSetInstance_ID
+ if (log.isLoggable(Level.FINE)) log.fine("M_AttributeSetInstance_ID=" + m_M_AttributeSetInstance_ID
+ " - " + m_M_AttributeSetInstanceName
+ "; M_Locator_ID=" + m_M_Locator_ID);
} // enableButtons
diff --git a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/window/WRecordAccessDialog.java b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/window/WRecordAccessDialog.java
index 256b6e681a..39882bdd9b 100644
--- a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/window/WRecordAccessDialog.java
+++ b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/window/WRecordAccessDialog.java
@@ -140,7 +140,7 @@ public class WRecordAccessDialog extends Window implements EventListener
pstmt = null;
}
- log.fine("#" + m_recordAccesss.size());
+ if (log.isLoggable(Level.FINE)) log.fine("#" + m_recordAccesss.size());
setLine(0, false);
} // dynInit
@@ -221,7 +221,7 @@ public class WRecordAccessDialog extends Window implements EventListener
*/
private void setLine (int rowDelta, boolean newRecord)
{
- log.fine("delta=" + rowDelta + ", new=" + newRecord
+ if (log.isLoggable(Level.FINE)) log.fine("delta=" + rowDelta + ", new=" + newRecord
+ " - currentRow=" + m_currentRow + ", size=" + m_recordAccesss.size());
int maxIndex = 0;
// nothing defined
@@ -301,7 +301,7 @@ public class WRecordAccessDialog extends Window implements EventListener
{
roleField.setSelectedItem(selection);
m_currentData = ra;
- log.fine("" + ra);
+ if (log.isLoggable(Level.FINE)) log.fine("" + ra);
}
else
m_currentData = null;
@@ -360,7 +360,7 @@ public class WRecordAccessDialog extends Window implements EventListener
m_currentData.setIsDependentEntities(isDependentEntities);
boolean success = m_currentData.save();
//
- log.fine("Success=" + success);
+ if (log.isLoggable(Level.FINE)) log.fine("Success=" + success);
return success;
} // cmd_save
@@ -378,7 +378,7 @@ public class WRecordAccessDialog extends Window implements EventListener
success = m_currentData.delete(true);
m_currentData = null;
m_recordAccesss.remove(m_currentRow);
- log.fine("Success=" + success);
+ if (log.isLoggable(Level.FINE)) log.fine("Success=" + success);
}
return success;
} // cmd_delete
diff --git a/org.adempiere.ui/src/org/compiere/apps/AbstractProcessCtl.java b/org.adempiere.ui/src/org/compiere/apps/AbstractProcessCtl.java
index 8e48de83fc..def4c8350f 100644
--- a/org.adempiere.ui/src/org/compiere/apps/AbstractProcessCtl.java
+++ b/org.adempiere.ui/src/org/compiere/apps/AbstractProcessCtl.java
@@ -106,7 +106,7 @@ public abstract class AbstractProcessCtl implements Runnable
*/
public void run ()
{
- log.fine("AD_PInstance_ID=" + m_pi.getAD_PInstance_ID()
+ if (log.isLoggable(Level.FINE)) log.fine("AD_PInstance_ID=" + m_pi.getAD_PInstance_ID()
+ ", Record_ID=" + m_pi.getRecord_ID());
// Lock
@@ -294,7 +294,7 @@ public abstract class AbstractProcessCtl implements Runnable
ProcessInfoUtil.setSummaryFromDB(m_pi);
unlock();
} // *** Process submission ***
- // log.fine(Log.l3_Util, "ProcessCtl.run - done");
+ // if (log.isLoggable(Level.FINE)) log.fine(Log.l3_Util, "ProcessCtl.run - done");
} // run
protected abstract void updateProgressWindowTimerEstimate(int estSeconds);
@@ -345,7 +345,7 @@ public abstract class AbstractProcessCtl implements Runnable
*/
private boolean startWorkflow (int AD_Workflow_ID)
{
- log.fine(AD_Workflow_ID + " - " + m_pi);
+ if (log.isLoggable(Level.FINE)) log.fine(AD_Workflow_ID + " - " + m_pi);
boolean started = false;
if (m_IsServerProcess)
{
@@ -387,7 +387,7 @@ public abstract class AbstractProcessCtl implements Runnable
*/
private boolean startProcess ()
{
- log.fine(m_pi.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(m_pi.toString());
boolean started = false;
//hengsin, bug [ 1633995 ]
@@ -460,7 +460,7 @@ public abstract class AbstractProcessCtl implements Runnable
private boolean startDBProcess (String ProcedureName)
{
// execute on this thread/connection
- log.fine(ProcedureName + "(" + m_pi.getAD_PInstance_ID() + ")");
+ if (log.isLoggable(Level.FINE)) log.fine(ProcedureName + "(" + m_pi.getAD_PInstance_ID() + ")");
boolean started = false;
if (m_IsServerProcess)
{
@@ -513,7 +513,7 @@ public abstract class AbstractProcessCtl implements Runnable
{
return ProcessUtil.startDatabaseProcedure(m_pi, ProcedureName, m_trx);
}
- // log.fine(Log.l4_Data, "ProcessCtl.startProcess - done");
+ // if (log.isLoggable(Level.FINE)) log.fine(Log.l4_Data, "ProcessCtl.startProcess - done");
return true;
} // startDBProcess
diff --git a/org.adempiere.ui/src/org/compiere/apps/form/Allocation.java b/org.adempiere.ui/src/org/compiere/apps/form/Allocation.java
index b07c39bc2c..bab5f2f7c0 100644
--- a/org.adempiere.ui/src/org/compiere/apps/form/Allocation.java
+++ b/org.adempiere.ui/src/org/compiere/apps/form/Allocation.java
@@ -137,7 +137,7 @@ public class Allocation
// role security
sql = new StringBuilder( MRole.getDefault(Env.getCtx(), false).addAccessSQL( sql.toString(), "p", MRole.SQL_FULLYQUALIFIED, MRole.SQL_RO ) );
- log.fine("PaySQL=" + sql.toString());
+ if (log.isLoggable(Level.FINE)) log.fine("PaySQL=" + sql.toString());
PreparedStatement pstmt = null;
ResultSet rs = null;
try
@@ -265,7 +265,7 @@ public class Allocation
if (m_AD_Org_ID != 0 )
sql.append(" AND i.AD_Org_ID=" + m_AD_Org_ID);
sql.append(" ORDER BY i.DateInvoiced, i.DocumentNo");
- log.fine("InvSQL=" + sql.toString());
+ if (log.isLoggable(Level.FINE)) log.fine("InvSQL=" + sql.toString());
// role security
sql = new StringBuilder( MRole.getDefault(Env.getCtx(), false).addAccessSQL( sql.toString(), "i", MRole.SQL_FULLYQUALIFIED, MRole.SQL_RO ) );
@@ -561,7 +561,7 @@ public class Allocation
BigDecimal bd = (BigDecimal)payment.getValueAt(i, i_payment);
totalPay = totalPay.add(bd); // Applied Pay
m_noPayments++;
- log.fine("Payment_" + i + " = " + bd + " - Total=" + totalPay);
+ if (log.isLoggable(Level.FINE)) log.fine("Payment_" + i + " = " + bd + " - Total=" + totalPay);
}
}
return String.valueOf(m_noPayments) + " - "
@@ -585,7 +585,7 @@ public class Allocation
BigDecimal bd = (BigDecimal)invoice.getValueAt(i, i_applied);
totalInv = totalInv.add(bd); // Applied Inv
m_noInvoices++;
- log.fine("Invoice_" + i + " = " + bd + " - Total=" + totalPay);
+ if (log.isLoggable(Level.FINE)) log.fine("Invoice_" + i + " = " + bd + " - Total=" + totalPay);
}
}
return String.valueOf(m_noInvoices) + " - "
@@ -638,7 +638,7 @@ public class Allocation
//
paymentAppliedAmt = paymentAppliedAmt.add(PaymentAmt);
//
- log.fine("C_Payment_ID=" + C_Payment_ID
+ if (log.isLoggable(Level.FINE)) log.fine("C_Payment_ID=" + C_Payment_ID
+ " - PaymentAmt=" + PaymentAmt); // + " * " + Multiplier + " = " + PaymentAmtAbs);
}
}
@@ -698,7 +698,7 @@ public class Allocation
// subtract amount from Payment/Invoice
AppliedAmt = AppliedAmt.subtract(amount);
PaymentAmt = PaymentAmt.subtract(amount);
- log.fine("Allocation Amount=" + amount + " - Remaining Applied=" + AppliedAmt + ", Payment=" + PaymentAmt);
+ if (log.isLoggable(Level.FINE)) log.fine("Allocation Amount=" + amount + " - Remaining Applied=" + AppliedAmt + ", Payment=" + PaymentAmt);
amountList.set(j, PaymentAmt); // update
} // for all applied amounts
} // loop through payments for invoice
@@ -714,7 +714,7 @@ public class Allocation
aLine.setDocInfo(C_BPartner_ID, C_Order_ID, C_Invoice_ID);
aLine.setPaymentInfo(C_Payment_ID, C_CashLine_ID);
aLine.saveEx();
- log.fine("Allocation Amount=" + AppliedAmt);
+ if (log.isLoggable(Level.FINE)) log.fine("Allocation Amount=" + AppliedAmt);
unmatchedApplied = unmatchedApplied.add(AppliedAmt);
}
} // invoice selected
@@ -726,7 +726,7 @@ public class Allocation
if ( payAmt.signum() == 0 )
continue;
int C_Payment_ID = ((Integer)paymentList.get(i)).intValue();
- log.fine("Payment=" + C_Payment_ID
+ if (log.isLoggable(Level.FINE)) log.fine("Payment=" + C_Payment_ID
+ ", Amount=" + payAmt);
// Allocation Line
diff --git a/org.adempiere.ui/src/org/compiere/apps/form/Archive.java b/org.adempiere.ui/src/org/compiere/apps/form/Archive.java
index 8823d98027..3545663392 100644
--- a/org.adempiere.ui/src/org/compiere/apps/form/Archive.java
+++ b/org.adempiere.ui/src/org/compiere/apps/form/Archive.java
@@ -193,7 +193,7 @@ public class Archive {
if (createdTo != null)
sql.append(" AND Created<").append(DB.TO_DATE(TimeUtil.addDays(createdTo,1), true));
- log.fine(sql.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(sql.toString());
//metas: Bugfix zu included_Role
// Process Access
diff --git a/org.adempiere.ui/src/org/compiere/apps/form/FactReconcile.java b/org.adempiere.ui/src/org/compiere/apps/form/FactReconcile.java
index eab1c471bb..4eb1bbf4ce 100644
--- a/org.adempiere.ui/src/org/compiere/apps/form/FactReconcile.java
+++ b/org.adempiere.ui/src/org/compiere/apps/form/FactReconcile.java
@@ -120,7 +120,7 @@ public class FactReconcile {
sql.append(" ORDER BY 1,5,3,6");
- log.fine("SQL=" + sql.toString());
+ if (log.isLoggable(Level.FINE)) log.fine("SQL=" + sql.toString());
PreparedStatement pstmt = null;
ResultSet rs = null;
diff --git a/org.adempiere.ui/src/org/compiere/apps/form/Match.java b/org.adempiere.ui/src/org/compiere/apps/form/Match.java
index 64f9e2e046..4ff7de16e3 100644
--- a/org.adempiere.ui/src/org/compiere/apps/form/Match.java
+++ b/org.adempiere.ui/src/org/compiere/apps/form/Match.java
@@ -83,7 +83,7 @@ public class Match
*/
protected Vector cmd_matchFrom(String selection)
{
- // log.fine( "VMatch.cmd_matchFrom");
+ // if (log.isLoggable(Level.FINE)) log.fine( "VMatch.cmd_matchFrom");
//String selection = (String)matchFrom.getSelectedItem();
Vector vector = new Vector(2);
if (selection.equals(m_matchOptions[MATCH_INVOICE]))
@@ -240,7 +240,7 @@ public class Match
KeyNamePair BPartner = (KeyNamePair)xMatchedTable.getValueAt(row, I_BPartner);
//KeyNamePair Org = (KeyNamePair)xMatchedTable.getValueAt(row, I_Org); //JAVIER
KeyNamePair Product = (KeyNamePair)xMatchedTable.getValueAt(row, I_Product);
- log.fine("BPartner=" + BPartner + " - Product=" + Product);
+ if (log.isLoggable(Level.FINE)) log.fine("BPartner=" + BPartner + " - Product=" + Product);
//
if (sameBPartner)
m_sql.append(" AND hdr.C_BPartner_ID=").append(BPartner.getKey());
@@ -405,7 +405,7 @@ public class Match
{
if (qty.compareTo(Env.ZERO) == 0)
return true;
- log.fine("IsInvoice=" + invoice
+ if (log.isLoggable(Level.FINE)) log.fine("IsInvoice=" + invoice
+ ", M_InOutLine_ID=" + M_InOutLine_ID + ", Line_ID=" + Line_ID
+ ", Qty=" + qty);
//
diff --git a/org.adempiere.ui/src/org/compiere/apps/form/Merge.java b/org.adempiere.ui/src/org/compiere/apps/form/Merge.java
index d888a0ec00..61deafde41 100644
--- a/org.adempiere.ui/src/org/compiere/apps/form/Merge.java
+++ b/org.adempiere.ui/src/org/compiere/apps/form/Merge.java
@@ -191,7 +191,7 @@ public class Merge
*/
public int mergeTable (String TableName, String ColumnName, int from_ID, int to_ID)
{
- log.fine(TableName + "." + ColumnName + " - From=" + from_ID + ",To=" + to_ID);
+ if (log.isLoggable(Level.FINE)) log.fine(TableName + "." + ColumnName + " - From=" + from_ID + ",To=" + to_ID);
String sql = "UPDATE " + TableName
+ " SET " + ColumnName + "=" + to_ID
+ " WHERE " + ColumnName + "=" + from_ID;
@@ -228,7 +228,7 @@ public class Merge
m_trx.rollback();
}
- log.fine(count
+ if (log.isLoggable(Level.FINE)) log.fine(count
+ (delete ? " -Delete- " : " -Update- ") + TableName);
diff --git a/org.adempiere.ui/src/org/compiere/apps/form/PaySelect.java b/org.adempiere.ui/src/org/compiere/apps/form/PaySelect.java
index 50f5805887..b9327f53a6 100644
--- a/org.adempiere.ui/src/org/compiere/apps/form/PaySelect.java
+++ b/org.adempiere.ui/src/org/compiere/apps/form/PaySelect.java
@@ -454,7 +454,7 @@ public class PaySelect
{
return Msg.translate(Env.getCtx(), "C_PaySelectionLine_ID");
}
- log.fine("C_Invoice_ID=" + C_Invoice_ID + ", PayAmt=" + PayAmt);
+ if (log.isLoggable(Level.FINE)) log.fine("C_Invoice_ID=" + C_Invoice_ID + ", PayAmt=" + PayAmt);
}
} // for all rows in table
diff --git a/org.adempiere.ui/src/org/compiere/apps/form/StatementCreateFromBatch.java b/org.adempiere.ui/src/org/compiere/apps/form/StatementCreateFromBatch.java
index 615d3381d5..958367f875 100644
--- a/org.adempiere.ui/src/org/compiere/apps/form/StatementCreateFromBatch.java
+++ b/org.adempiere.ui/src/org/compiere/apps/form/StatementCreateFromBatch.java
@@ -98,7 +98,7 @@ public abstract class StatementCreateFromBatch extends CreateFromForm
sql.append(" AND TRUNC(p.DateTrx) BETWEEN ? AND ?");
}
- log.fine(sql.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(sql.toString());
return sql.toString();
}
@@ -135,7 +135,7 @@ public abstract class StatementCreateFromBatch extends CreateFromForm
{
BigDecimal from = (BigDecimal) AmtFrom;
BigDecimal to = (BigDecimal) AmtTo;
- log.fine("Amt From=" + from + ", To=" + to);
+ if (log.isLoggable(Level.FINE)) log.fine("Amt From=" + from + ", To=" + to);
if(from == null && to != null)
pstmt.setBigDecimal(index++, to);
else if(from != null && to == null)
@@ -151,7 +151,7 @@ public abstract class StatementCreateFromBatch extends CreateFromForm
{
Timestamp from = (Timestamp) DateFrom;
Timestamp to = (Timestamp) DateTo;
- log.fine("Date From=" + from + ", To=" + to);
+ if (log.isLoggable(Level.FINE)) log.fine("Date From=" + from + ", To=" + to);
if(from == null && to != null)
pstmt.setTimestamp(index++, to);
else if(from != null && to == null)
@@ -169,7 +169,7 @@ public abstract class StatementCreateFromBatch extends CreateFromForm
String s = text.toUpperCase();
if(!s.endsWith("%"))
s += "%";
- log.fine( "String=" + s);
+ if (log.isLoggable(Level.FINE)) log.fine( "String=" + s);
return s;
}
@@ -282,7 +282,7 @@ public abstract class StatementCreateFromBatch extends CreateFromForm
pp = (KeyNamePair) miniTable.getValueAt(i, 5); // 5- C_BankAccount_ID
int C_BankAccount_ID = pp.getKey();
- log.fine("Deposit Batch Date=" + trxDate + ", Batch=" + X_DepositBatch_ID
+ if (log.isLoggable(Level.FINE)) log.fine("Deposit Batch Date=" + trxDate + ", Batch=" + X_DepositBatch_ID
+" , Bank Account" + C_BankAccount_ID);
PreparedStatement pstmt = null;
@@ -300,7 +300,7 @@ public abstract class StatementCreateFromBatch extends CreateFromForm
int C_Currency_ID = rs.getInt(4);
BigDecimal TrxAmt = rs.getBigDecimal(6); // PayAmt
- log.fine("Line Date=" + trxDate + ", Payment=" + C_Payment_ID + ", Currency=" + C_Currency_ID + ", Amt=" + TrxAmt);
+ if (log.isLoggable(Level.FINE)) log.fine("Line Date=" + trxDate + ", Payment=" + C_Payment_ID + ", Currency=" + C_Currency_ID + ", Amt=" + TrxAmt);
//
MBankStatementLine bsl = new MBankStatementLine (bs);
bsl.setStatementLineDate(trxDate);
diff --git a/org.adempiere.ui/src/org/compiere/apps/form/TrxMaterial.java b/org.adempiere.ui/src/org/compiere/apps/form/TrxMaterial.java
index 1d07c8dc94..111e8a95cf 100644
--- a/org.adempiere.ui/src/org/compiere/apps/form/TrxMaterial.java
+++ b/org.adempiere.ui/src/org/compiere/apps/form/TrxMaterial.java
@@ -125,7 +125,7 @@ public class TrxMaterial {
int lineID = Env.getContextAsInt(Env.getCtx(), m_WindowNo, "M_InOutLine_ID");
if (lineID != 0)
{
- log.fine("M_InOutLine_ID=" + lineID);
+ if (log.isLoggable(Level.FINE)) log.fine("M_InOutLine_ID=" + lineID);
if (Env.getContext(Env.getCtx(), m_WindowNo, "MovementType").startsWith("C"))
AD_Window_ID = WINDOW_SHIPMENT_CUSTOMER; // Customer
else
@@ -138,7 +138,7 @@ public class TrxMaterial {
lineID = Env.getContextAsInt(Env.getCtx(), m_WindowNo, "M_InventoryLine_ID");
if (lineID != 0)
{
- log.fine("M_InventoryLine_ID=" + lineID);
+ if (log.isLoggable(Level.FINE)) log.fine("M_InventoryLine_ID=" + lineID);
AD_Window_ID = WINDOW_PHYSICALINVENTORY;
ColumnName = "M_Inventory_ID";
SQL = "SELECT M_Inventory_ID FROM M_InventoryLine WHERE M_InventoryLine_ID=?";
@@ -148,7 +148,7 @@ public class TrxMaterial {
lineID = Env.getContextAsInt(Env.getCtx(), m_WindowNo, "M_MovementLine_ID");
if (lineID != 0)
{
- log.fine("M_MovementLine_ID=" + lineID);
+ if (log.isLoggable(Level.FINE)) log.fine("M_MovementLine_ID=" + lineID);
AD_Window_ID = WINDOW_INVENTORYMOVE;
ColumnName = "M_Movement_ID";
SQL = "SELECT M_Movement_ID FROM M_MovementLine WHERE M_MovementLine_ID=?";
@@ -158,13 +158,13 @@ public class TrxMaterial {
lineID = Env.getContextAsInt(Env.getCtx(), m_WindowNo, "M_ProductionLine_ID");
if (lineID != 0)
{
- log.fine("M_ProductionLine_ID=" + lineID);
+ if (log.isLoggable(Level.FINE)) log.fine("M_ProductionLine_ID=" + lineID);
AD_Window_ID = WINDOW_PRODUCTION;
ColumnName = "M_Production_ID";
SQL = "SELECT M_Production_ID FROM M_ProductionLine WHERE M_ProductionLine_ID=?";
}
else
- log.fine("Not found WindowNo=" + m_WindowNo);
+ if (log.isLoggable(Level.FINE)) log.fine("Not found WindowNo=" + m_WindowNo);
}
}
}
diff --git a/org.adempiere.ui/src/org/compiere/grid/CreateFromBatch.java b/org.adempiere.ui/src/org/compiere/grid/CreateFromBatch.java
index 544dbd2d04..eddc7cf373 100644
--- a/org.adempiere.ui/src/org/compiere/grid/CreateFromBatch.java
+++ b/org.adempiere.ui/src/org/compiere/grid/CreateFromBatch.java
@@ -19,6 +19,7 @@ import java.sql.SQLException;
import java.sql.Timestamp;
import java.text.DecimalFormat;
import java.util.Vector;
+import java.util.logging.Level;
import org.compiere.apps.IStatusBar;
import org.compiere.minigrid.IMiniTable;
@@ -84,7 +85,7 @@ public abstract class CreateFromBatch extends CreateFrom
sql.append(" AND TRUNC(p.DateTrx) BETWEEN ? AND ?");
}
- log.fine(sql.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(sql.toString());
return sql.toString();
}
@@ -121,7 +122,7 @@ public abstract class CreateFromBatch extends CreateFrom
{
BigDecimal from = (BigDecimal) AmtFrom;
BigDecimal to = (BigDecimal) AmtTo;
- log.fine("Amt From=" + from + ", To=" + to);
+ if (log.isLoggable(Level.FINE)) log.fine("Amt From=" + from + ", To=" + to);
if(from == null && to != null)
pstmt.setBigDecimal(index++, to);
else if(from != null && to == null)
@@ -137,7 +138,7 @@ public abstract class CreateFromBatch extends CreateFrom
{
Timestamp from = (Timestamp) DateFrom;
Timestamp to = (Timestamp) DateTo;
- log.fine("Date From=" + from + ", To=" + to);
+ if (log.isLoggable(Level.FINE)) log.fine("Date From=" + from + ", To=" + to);
if(from == null && to != null)
pstmt.setTimestamp(index++, to);
else if(from != null && to == null)
@@ -155,7 +156,7 @@ public abstract class CreateFromBatch extends CreateFrom
String s = text.toUpperCase();
if(!s.endsWith("%"))
s += "%";
- log.fine( "String=" + s);
+ if (log.isLoggable(Level.FINE)) log.fine( "String=" + s);
return s;
}
diff --git a/org.adempiere.ui/src/org/compiere/grid/CreateFromDepositBatch.java b/org.adempiere.ui/src/org/compiere/grid/CreateFromDepositBatch.java
index f94b4bde06..74e25bb0f2 100644
--- a/org.adempiere.ui/src/org/compiere/grid/CreateFromDepositBatch.java
+++ b/org.adempiere.ui/src/org/compiere/grid/CreateFromDepositBatch.java
@@ -140,7 +140,7 @@ public abstract class CreateFromDepositBatch extends CreateFromBatch
BigDecimal TrxAmt = (BigDecimal) miniTable.getValueAt(i, 4); // 4-PayAmt
// BigDecimal StmtAmt = (BigDecimal) miniTable.getValueAt(i, 5);// 5-Conv Amt
//
- log.fine("Line Date=" + trxDate + ", Payment=" + C_Payment_ID + ", Currency=" + C_Currency_ID + ", Amt=" + TrxAmt);
+ if (log.isLoggable(Level.FINE)) log.fine("Line Date=" + trxDate + ", Payment=" + C_Payment_ID + ", Currency=" + C_Currency_ID + ", Amt=" + TrxAmt);
//
MDepositBatchLine dbl = new MDepositBatchLine(db);
// dbl.setStatementLineDate(trxDate);
diff --git a/org.adempiere.ui/src/org/compiere/grid/CreateFromInvoice.java b/org.adempiere.ui/src/org/compiere/grid/CreateFromInvoice.java
index d6b88488eb..a24fec9819 100644
--- a/org.adempiere.ui/src/org/compiere/grid/CreateFromInvoice.java
+++ b/org.adempiere.ui/src/org/compiere/grid/CreateFromInvoice.java
@@ -428,7 +428,7 @@ public abstract class CreateFromInvoice extends CreateFrom
}
QtyEntered = QtyEntered.setScale(precision, BigDecimal.ROUND_HALF_DOWN);
//
- log.fine("Line QtyEntered=" + QtyEntered
+ if (log.isLoggable(Level.FINE)) log.fine("Line QtyEntered=" + QtyEntered
+ ", Product_ID=" + M_Product_ID
+ ", OrderLine_ID=" + C_OrderLine_ID + ", InOutLine_ID=" + M_InOutLine_ID);
@@ -468,7 +468,7 @@ public abstract class CreateFromInvoice extends CreateFrom
String whereClause = "EXISTS (SELECT 1 FROM M_InOut io WHERE io.M_InOut_ID=M_InOutLine.M_InOut_ID AND io.DocStatus IN ('CO','CL'))";
MInOutLine[] lines = MInOutLine.getOfOrderLine(Env.getCtx(),
C_OrderLine_ID, whereClause, trxName);
- log.fine ("Receipt Lines with OrderLine = #" + lines.length);
+ if (log.isLoggable(Level.FINE)) log.fine ("Receipt Lines with OrderLine = #" + lines.length);
if (lines.length > 0)
{
for (int j = 0; j < lines.length; j++)
@@ -492,7 +492,7 @@ public abstract class CreateFromInvoice extends CreateFrom
{
String whereClause = "EXISTS (SELECT 1 FROM M_InOut io WHERE io.M_InOut_ID=M_InOutLine.M_InOut_ID AND io.DocStatus IN ('CO','CL'))";
MInOutLine[] lines = MInOutLine.getOfRMALine(Env.getCtx(), M_RMALine_ID, whereClause, null);
- log.fine ("Receipt Lines with RMALine = #" + lines.length);
+ if (log.isLoggable(Level.FINE)) log.fine ("Receipt Lines with RMALine = #" + lines.length);
if (lines.length > 0)
{
for (int j = 0; j < lines.length; j++)
diff --git a/org.adempiere.ui/src/org/compiere/grid/CreateFromShipment.java b/org.adempiere.ui/src/org/compiere/grid/CreateFromShipment.java
index ecc4ecf4ae..966c4b1734 100644
--- a/org.adempiere.ui/src/org/compiere/grid/CreateFromShipment.java
+++ b/org.adempiere.ui/src/org/compiere/grid/CreateFromShipment.java
@@ -594,7 +594,7 @@ public abstract class CreateFromShipment extends CreateFrom
}
QtyEntered = QtyEntered.setScale(precision, BigDecimal.ROUND_HALF_DOWN);
//
- log.fine("Line QtyEntered=" + QtyEntered
+ if (log.isLoggable(Level.FINE)) log.fine("Line QtyEntered=" + QtyEntered
+ ", Product=" + M_Product_ID
+ ", OrderLine=" + C_OrderLine_ID + ", InvoiceLine=" + C_InvoiceLine_ID);
diff --git a/org.adempiere.ui/src/org/compiere/grid/CreateFromStatement.java b/org.adempiere.ui/src/org/compiere/grid/CreateFromStatement.java
index a21fcec4aa..3d9aba336c 100644
--- a/org.adempiere.ui/src/org/compiere/grid/CreateFromStatement.java
+++ b/org.adempiere.ui/src/org/compiere/grid/CreateFromStatement.java
@@ -134,7 +134,7 @@ public abstract class CreateFromStatement extends CreateFromBatch
int C_Currency_ID = pp.getKey();
BigDecimal TrxAmt = (BigDecimal) miniTable.getValueAt(i, 5); // 5- Conv Amt
- log.fine("Line Date=" + trxDate
+ if (log.isLoggable(Level.FINE)) log.fine("Line Date=" + trxDate
+ ", Payment=" + C_Payment_ID + ", Currency=" + C_Currency_ID + ", Amt=" + TrxAmt);
//
MBankStatementLine bsl = new MBankStatementLine (bs);
diff --git a/org.adempiere.ui/src/org/compiere/grid/PaymentFormCash.java b/org.adempiere.ui/src/org/compiere/grid/PaymentFormCash.java
index d86fc19b35..579ea67100 100644
--- a/org.adempiere.ui/src/org/compiere/grid/PaymentFormCash.java
+++ b/org.adempiere.ui/src/org/compiere/grid/PaymentFormCash.java
@@ -226,9 +226,9 @@ public abstract class PaymentFormCash extends PaymentForm {
*/
if (!PAYMENTRULE.equals(m_PaymentRule))
{
- log.fine("Changed PaymentRule: " + m_PaymentRule + " -> " + PAYMENTRULE);
+ if (log.isLoggable(Level.FINE)) log.fine("Changed PaymentRule: " + m_PaymentRule + " -> " + PAYMENTRULE);
// We had a CashBook Entry
- log.fine("Old Cash - " + m_cashLine);
+ if (log.isLoggable(Level.FINE)) log.fine("Old Cash - " + m_cashLine);
if (m_cashLine != null)
{
MCashLine cl = m_cashLine.createReversal();
@@ -365,7 +365,7 @@ public abstract class PaymentFormCash extends PaymentForm {
*/
if (m_Cash_As_Payment)
{
- log.fine("Payment - " + PAYMENTRULE);
+ if (log.isLoggable(Level.FINE)) log.fine("Payment - " + PAYMENTRULE);
// Set Amount
m_mPayment.setAmount(m_C_Currency_ID, payAmount);
// Get changes to cash amount
@@ -396,7 +396,7 @@ public abstract class PaymentFormCash extends PaymentForm {
}
}
else
- log.fine("NotDraft " + m_mPayment);
+ if (log.isLoggable(Level.FINE)) log.fine("NotDraft " + m_mPayment);
}
/**********************
diff --git a/org.adempiere.ui/src/org/compiere/grid/PaymentFormCheck.java b/org.adempiere.ui/src/org/compiere/grid/PaymentFormCheck.java
index 594f9c87ec..16055d66c2 100644
--- a/org.adempiere.ui/src/org/compiere/grid/PaymentFormCheck.java
+++ b/org.adempiere.ui/src/org/compiere/grid/PaymentFormCheck.java
@@ -149,11 +149,11 @@ public abstract class PaymentFormCheck extends PaymentForm {
*/
if (!PAYMENTRULE.equals(m_PaymentRule))
{
- log.fine("Changed PaymentRule: " + m_PaymentRule + " -> " + PAYMENTRULE);
+ if (log.isLoggable(Level.FINE)) log.fine("Changed PaymentRule: " + m_PaymentRule + " -> " + PAYMENTRULE);
// We had a change in Payment type (e.g. Check to CC)
if (payTypes.indexOf(m_PaymentRule) != -1 && payTypes.indexOf(PAYMENTRULE) != -1 && m_mPaymentOriginal != null)
{
- log.fine("Old Payment(1) - " + m_mPaymentOriginal);
+ if (log.isLoggable(Level.FINE)) log.fine("Old Payment(1) - " + m_mPaymentOriginal);
m_mPaymentOriginal.setDocAction(DocAction.ACTION_Reverse_Correct);
boolean ok = m_mPaymentOriginal.processIt(DocAction.ACTION_Reverse_Correct);
m_mPaymentOriginal.saveEx();
@@ -169,7 +169,7 @@ public abstract class PaymentFormCheck extends PaymentForm {
// We had a Payment and something else (e.g. Check to Cash)
else if (payTypes.indexOf(m_PaymentRule) != -1 && payTypes.indexOf(PAYMENTRULE) == -1)
{
- log.fine("Old Payment(2) - " + m_mPaymentOriginal);
+ if (log.isLoggable(Level.FINE)) log.fine("Old Payment(2) - " + m_mPaymentOriginal);
if (m_mPaymentOriginal != null)
{
m_mPaymentOriginal.setDocAction(DocAction.ACTION_Reverse_Correct);
@@ -177,7 +177,7 @@ public abstract class PaymentFormCheck extends PaymentForm {
m_mPaymentOriginal.saveEx();
if (ok) // Cancel Payment
{
- log.fine("PaymentCancelled " + m_mPayment.getDocumentNo ());
+ if (log.isLoggable(Level.FINE)) log.fine("PaymentCancelled " + m_mPayment.getDocumentNo ());
getGridTab().getTableModel().dataSave(true);
m_mPayment.resetNew();
m_mPayment.setAmount(m_C_Currency_ID, m_Amount);
@@ -220,7 +220,7 @@ public abstract class PaymentFormCheck extends PaymentForm {
/***********************
* Payments
*/
- log.fine("Payment - " + PAYMENTRULE);
+ if (log.isLoggable(Level.FINE)) log.fine("Payment - " + PAYMENTRULE);
// Set Amount
m_mPayment.setAmount(m_C_Currency_ID, payAmount);
m_mPayment.setBankCheck(newC_BankAccount_ID, m_isSOTrx, routing,
@@ -251,7 +251,7 @@ public abstract class PaymentFormCheck extends PaymentForm {
}
}
else
- log.fine("NotDraft " + m_mPayment);
+ if (log.isLoggable(Level.FINE)) log.fine("NotDraft " + m_mPayment);
/**********************
* Save Values to mTab
diff --git a/org.adempiere.ui/src/org/compiere/grid/PaymentFormCreditCard.java b/org.adempiere.ui/src/org/compiere/grid/PaymentFormCreditCard.java
index e313d2415e..0d5c194095 100644
--- a/org.adempiere.ui/src/org/compiere/grid/PaymentFormCreditCard.java
+++ b/org.adempiere.ui/src/org/compiere/grid/PaymentFormCreditCard.java
@@ -14,6 +14,7 @@
package org.compiere.grid;
import java.math.BigDecimal;
+import java.util.logging.Level;
import org.adempiere.exceptions.AdempiereException;
import org.adempiere.util.PaymentUtil;
@@ -232,11 +233,11 @@ public abstract class PaymentFormCreditCard extends PaymentForm {
*/
if (!PAYMENTRULE.equals(m_PaymentRule))
{
- log.fine("Changed PaymentRule: " + m_PaymentRule + " -> " + PAYMENTRULE);
+ if (log.isLoggable(Level.FINE)) log.fine("Changed PaymentRule: " + m_PaymentRule + " -> " + PAYMENTRULE);
// We had a change in Payment type (e.g. Check to CC)
if (payTypes.indexOf(m_PaymentRule) != -1 && payTypes.indexOf(PAYMENTRULE) != -1 && m_mPaymentOriginal != null)
{
- log.fine("Old Payment(1) - " + m_mPaymentOriginal);
+ if (log.isLoggable(Level.FINE)) log.fine("Old Payment(1) - " + m_mPaymentOriginal);
m_mPaymentOriginal.setDocAction(DocAction.ACTION_Reverse_Correct);
boolean ok = m_mPaymentOriginal.processIt(DocAction.ACTION_Reverse_Correct);
m_mPaymentOriginal.saveEx();
@@ -252,7 +253,7 @@ public abstract class PaymentFormCreditCard extends PaymentForm {
// We had a Payment and something else (e.g. Check to Cash)
else if (payTypes.indexOf(m_PaymentRule) != -1 && payTypes.indexOf(PAYMENTRULE) == -1)
{
- log.fine("Old Payment(2) - " + m_mPaymentOriginal);
+ if (log.isLoggable(Level.FINE)) log.fine("Old Payment(2) - " + m_mPaymentOriginal);
if (m_mPaymentOriginal != null)
{
m_mPaymentOriginal.setDocAction(DocAction.ACTION_Reverse_Correct);
@@ -260,7 +261,7 @@ public abstract class PaymentFormCreditCard extends PaymentForm {
m_mPaymentOriginal.saveEx();
if (ok) // Cancel Payment
{
- log.fine("PaymentCancelled " + m_mPayment.getDocumentNo ());
+ if (log.isLoggable(Level.FINE)) log.fine("PaymentCancelled " + m_mPayment.getDocumentNo ());
getGridTab().getTableModel().dataSave(true);
m_mPayment.resetNew();
m_mPayment.setAmount(m_C_Currency_ID, m_Amount);
@@ -303,7 +304,7 @@ public abstract class PaymentFormCreditCard extends PaymentForm {
/***********************
* Payments
*/
- log.fine("Payment - " + PAYMENTRULE);
+ if (log.isLoggable(Level.FINE)) log.fine("Payment - " + PAYMENTRULE);
// Set Amount
m_mPayment.setAmount(m_C_Currency_ID, payAmount);
m_mPayment.setCreditCard(MPayment.TRXTYPE_Sales, newCCType, newCCNumber, "", newCCExp);
@@ -370,7 +371,7 @@ public abstract class PaymentFormCreditCard extends PaymentForm {
}
else
{
- log.fine("NotDraft " + m_mPayment);
+ if (log.isLoggable(Level.FINE)) log.fine("NotDraft " + m_mPayment);
m_mPayment.setCreditCardNumber(PaymentUtil.encrpytCreditCard(m_mPayment.getCreditCardNumber()));
m_mPayment.setCreditCardVV(PaymentUtil.encrpytCvv(m_mPayment.getCreditCardVV()));
m_mPayment.saveEx();
diff --git a/org.adempiere.ui/src/org/compiere/grid/PaymentFormDirect.java b/org.adempiere.ui/src/org/compiere/grid/PaymentFormDirect.java
index 7f4a418549..581ee96fb8 100644
--- a/org.adempiere.ui/src/org/compiere/grid/PaymentFormDirect.java
+++ b/org.adempiere.ui/src/org/compiere/grid/PaymentFormDirect.java
@@ -139,11 +139,11 @@ public abstract class PaymentFormDirect extends PaymentForm {
*/
if (!PAYMENTRULE.equals(m_PaymentRule))
{
- log.fine("Changed PaymentRule: " + m_PaymentRule + " -> " + PAYMENTRULE);
+ if (log.isLoggable(Level.FINE)) log.fine("Changed PaymentRule: " + m_PaymentRule + " -> " + PAYMENTRULE);
// We had a change in Payment type (e.g. Check to CC)
if (payTypes.indexOf(m_PaymentRule) != -1 && payTypes.indexOf(PAYMENTRULE) != -1 && m_mPaymentOriginal != null)
{
- log.fine("Old Payment(1) - " + m_mPaymentOriginal);
+ if (log.isLoggable(Level.FINE)) log.fine("Old Payment(1) - " + m_mPaymentOriginal);
m_mPaymentOriginal.setDocAction(DocAction.ACTION_Reverse_Correct);
boolean ok = m_mPaymentOriginal.processIt(DocAction.ACTION_Reverse_Correct);
m_mPaymentOriginal.saveEx();
@@ -159,7 +159,7 @@ public abstract class PaymentFormDirect extends PaymentForm {
// We had a Payment and something else (e.g. Check to Cash)
else if (payTypes.indexOf(m_PaymentRule) != -1 && payTypes.indexOf(PAYMENTRULE) == -1)
{
- log.fine("Old Payment(2) - " + m_mPaymentOriginal);
+ if (log.isLoggable(Level.FINE)) log.fine("Old Payment(2) - " + m_mPaymentOriginal);
if (m_mPaymentOriginal != null)
{
m_mPaymentOriginal.setDocAction(DocAction.ACTION_Reverse_Correct);
@@ -167,7 +167,7 @@ public abstract class PaymentFormDirect extends PaymentForm {
m_mPaymentOriginal.saveEx();
if (ok) // Cancel Payment
{
- log.fine("PaymentCancelled " + m_mPayment.getDocumentNo ());
+ if (log.isLoggable(Level.FINE)) log.fine("PaymentCancelled " + m_mPayment.getDocumentNo ());
getGridTab().getTableModel().dataSave(true);
m_mPayment.resetNew();
m_mPayment.setAmount(m_C_Currency_ID, m_Amount);
@@ -239,7 +239,7 @@ public abstract class PaymentFormDirect extends PaymentForm {
}
}
else
- log.fine("NotDraft " + m_mPayment);
+ if (log.isLoggable(Level.FINE)) log.fine("NotDraft " + m_mPayment);
/**********************
* Save Values to mTab
diff --git a/org.adempiere.ui/src/org/compiere/install/TranslationHandler.java b/org.adempiere.ui/src/org/compiere/install/TranslationHandler.java
index 257d49c86a..22870f688c 100644
--- a/org.adempiere.ui/src/org/compiere/install/TranslationHandler.java
+++ b/org.adempiere.ui/src/org/compiere/install/TranslationHandler.java
@@ -17,8 +17,8 @@
package org.compiere.install;
import java.sql.Timestamp;
+import java.util.logging.Level;
-import org.compiere.util.CLogMgt;
import org.compiere.util.CLogger;
import org.compiere.util.DB;
import org.compiere.util.Language;
@@ -92,7 +92,7 @@ public class TranslationHandler extends DefaultHandler
if (!m_isBaseLanguage)
m_updateSQL += "_Trl";
m_updateSQL += " SET ";
- log.fine("AD_Language=" + m_AD_Language + ", Base=" + m_isBaseLanguage + ", TableName=" + m_TableName);
+ if (log.isLoggable(Level.FINE)) log.fine("AD_Language=" + m_AD_Language + ", Base=" + m_isBaseLanguage + ", TableName=" + m_TableName);
}
else if (qName.equals(Translation.XML_ROW_TAG))
{
@@ -167,8 +167,7 @@ public class TranslationHandler extends DefaultHandler
int no = DB.executeUpdate(m_sql.toString(), null);
if (no == 1)
{
- if (CLogMgt.isLevelFinest())
- log.fine(m_sql.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(m_sql.toString());
m_updateCount++;
}
else if (no == 0)
diff --git a/org.adempiere.webstore.servlet/src/org/compiere/wstore/AssetServlet.java b/org.adempiere.webstore.servlet/src/org/compiere/wstore/AssetServlet.java
index 240c9d6cf6..f2f504c8b5 100644
--- a/org.adempiere.webstore.servlet/src/org/compiere/wstore/AssetServlet.java
+++ b/org.adempiere.webstore.servlet/src/org/compiere/wstore/AssetServlet.java
@@ -176,7 +176,7 @@ public class AssetServlet extends HttpServlet
MAsset asset = new MAsset(ctx, A_Asset_ID, null);
if (asset.getA_Asset_ID() != A_Asset_ID)
{
- log.fine("Asset not found - ID=" + A_Asset_ID);
+ if (log.isLoggable(Level.FINE)) log.fine("Asset not found - ID=" + A_Asset_ID);
return "Asset not found";
}
// Get WebUser & Compare with invoice
@@ -215,7 +215,7 @@ public class AssetServlet extends HttpServlet
}
}
}
- log.fine(dl_name + " - " + dl_url);
+ if (log.isLoggable(Level.FINE)) log.fine(dl_name + " - " + dl_url);
if (dl_name == null || dl_url == null || in == null)
return "@NotFound@ @A_Asset_ID@: " + pd;
@@ -257,7 +257,7 @@ public class AssetServlet extends HttpServlet
int bufferSize = 2048; // 2k Buffer
response.setBufferSize(bufferSize);
//
- log.fine(in + ", available=" + in.available());
+ if (log.isLoggable(Level.FINE)) log.fine(in + ", available=" + in.available());
long time = System.currentTimeMillis();
// Zip Output Stream
diff --git a/org.adempiere.webstore.servlet/src/org/compiere/wstore/BasketServlet.java b/org.adempiere.webstore.servlet/src/org/compiere/wstore/BasketServlet.java
index 592708117c..b6ea42d624 100644
--- a/org.adempiere.webstore.servlet/src/org/compiere/wstore/BasketServlet.java
+++ b/org.adempiere.webstore.servlet/src/org/compiere/wstore/BasketServlet.java
@@ -120,7 +120,7 @@ public class BasketServlet extends HttpServlet
if (SalesRep_ID != 0)
{
wb.setSalesRep_ID(SalesRep_ID);
- log.fine("SalesRep_ID=" + SalesRep_ID);
+ if (log.isLoggable(Level.FINE)) log.fine("SalesRep_ID=" + SalesRep_ID);
}
// Get Price List
@@ -130,7 +130,7 @@ public class BasketServlet extends HttpServlet
log.fine("No Price List in session");
pl = (PriceList)request.getAttribute(PriceList.NAME);
}
- log.fine("PL=" + pl);
+ if (log.isLoggable(Level.FINE)) log.fine("PL=" + pl);
// Do we delete? Delete_x
deleteLine (request, wb);
@@ -179,14 +179,14 @@ public class BasketServlet extends HttpServlet
try
{
M_Product_ID = Integer.parseInt (parameter.substring (4));
- log.fine("Found Parameter=" + parameter + " -> " + M_Product_ID);
+ if (log.isLoggable(Level.FINE)) log.fine("Found Parameter=" + parameter + " -> " + M_Product_ID);
if (!WebUtil.exists(sQuantity))
sQuantity = WebUtil.getParameter (request, "Qty_" + M_Product_ID);
if (!WebUtil.exists(sPrice))
sPrice = WebUtil.getParameter (request, "Price_" + M_Product_ID);
if (!WebUtil.exists(Name))
Name = WebUtil.getParameter (request, "Name_" + M_Product_ID);
- log.fine("Found Parameters " + Name + ",Qty=" + sQuantity + ",Price=" + sPrice);
+ if (log.isLoggable(Level.FINE)) log.fine("Found Parameters " + Name + ",Qty=" + sQuantity + ",Price=" + sPrice);
}
catch (Exception ex)
{
@@ -222,7 +222,7 @@ public class BasketServlet extends HttpServlet
{
Price = plp.getPrice ();
Name = plp.getName ();
- log.fine("Found in PL = " + Name + " - " + Price);
+ if (log.isLoggable(Level.FINE)) log.fine("Found in PL = " + Name + " - " + Price);
}
}
/** if not found inPL and exists as parameter
@@ -248,7 +248,7 @@ public class BasketServlet extends HttpServlet
{
Price = plp.getPrice ();
Name = plp.getName ();
- log.fine("Found in complete PL = " + Name + " - " + Price);
+ if (log.isLoggable(Level.FINE)) log.fine("Found in complete PL = " + Name + " - " + Price);
}
}
@@ -256,7 +256,7 @@ public class BasketServlet extends HttpServlet
if (Price != null)
{
WebBasketLine wbl = wb.add (M_Product_ID, Name, Qty, Price);
- log.fine(wbl.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(wbl.toString());
}
else // Price not found
log.warning ("Product Price not found - M_Product_ID=" + M_Product_ID
@@ -291,7 +291,7 @@ public class BasketServlet extends HttpServlet
try
{
int line = Integer.parseInt (parameter.substring (7));
- log.fine("Delete parameter=" + parameter + " -> " + line);
+ if (log.isLoggable(Level.FINE)) log.fine("Delete parameter=" + parameter + " -> " + line);
wb.delete(line);
}
catch (NumberFormatException ex)
diff --git a/org.adempiere.webstore.servlet/src/org/compiere/wstore/CheckOutLinkTag.java b/org.adempiere.webstore.servlet/src/org/compiere/wstore/CheckOutLinkTag.java
index 3ca13c3c39..cd76898286 100644
--- a/org.adempiere.webstore.servlet/src/org/compiere/wstore/CheckOutLinkTag.java
+++ b/org.adempiere.webstore.servlet/src/org/compiere/wstore/CheckOutLinkTag.java
@@ -16,6 +16,7 @@
*****************************************************************************/
package org.compiere.wstore;
import java.util.ArrayList;
+import java.util.logging.Level;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpSession;
@@ -74,7 +75,7 @@ public class CheckOutLinkTag extends TagSupport
// log.fine("WebBasket=" + wb);
if (wb != null && wb.getLineCount() > 0)
{
- log.fine("WebBasket exists");
+ if (log.isLoggable(Level.FINE)) log.fine("WebBasket exists");
//
JspWriter out = pageContext.getOut();
HtmlCode html = new HtmlCode();
diff --git a/org.adempiere.webstore.servlet/src/org/compiere/wstore/Click.java b/org.adempiere.webstore.servlet/src/org/compiere/wstore/Click.java
index c4c54918ad..61ca7e48db 100644
--- a/org.adempiere.webstore.servlet/src/org/compiere/wstore/Click.java
+++ b/org.adempiere.webstore.servlet/src/org/compiere/wstore/Click.java
@@ -19,6 +19,7 @@ package org.compiere.wstore;
import java.io.IOException;
import java.util.Enumeration;
import java.util.Properties;
+import java.util.logging.Level;
import javax.servlet.ServletConfig;
import javax.servlet.ServletException;
@@ -113,12 +114,12 @@ public class Click extends HttpServlet
if (!response.isCommitted ())
response.sendRedirect(url);
response.flushBuffer();
- log.fine("redirect - " + url);
+ if (log.isLoggable(Level.FINE)) log.fine("redirect - " + url);
// Save Click
saveClick(request, url);
//
- log.fine(url + " - " + (System.currentTimeMillis()-time) + "ms");
+ if (log.isLoggable(Level.FINE)) log.fine(url + " - " + (System.currentTimeMillis()-time) + "ms");
} // doGet
/**
diff --git a/org.adempiere.webstore.servlet/src/org/compiere/wstore/InfoLinkTag.java b/org.adempiere.webstore.servlet/src/org/compiere/wstore/InfoLinkTag.java
index b533f89ff6..97117402d4 100644
--- a/org.adempiere.webstore.servlet/src/org/compiere/wstore/InfoLinkTag.java
+++ b/org.adempiere.webstore.servlet/src/org/compiere/wstore/InfoLinkTag.java
@@ -17,6 +17,7 @@
package org.compiere.wstore;
import java.util.Properties;
+import java.util.logging.Level;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpSession;
@@ -105,7 +106,7 @@ public class InfoLinkTag extends TagSupport
}
else
{
- if (CLogMgt.isLevelFiner())
+ if (log.isLoggable(Level.FINE))
log.fine("No WebUser");
if (session.getAttribute(WebInfo.NAME) == null)
session.setAttribute (WebInfo.NAME, WebInfo.getGeneral());
diff --git a/org.adempiere.webstore.servlet/src/org/compiere/wstore/InfoServlet.java b/org.adempiere.webstore.servlet/src/org/compiere/wstore/InfoServlet.java
index 9338a9cb7f..21d15cd401 100644
--- a/org.adempiere.webstore.servlet/src/org/compiere/wstore/InfoServlet.java
+++ b/org.adempiere.webstore.servlet/src/org/compiere/wstore/InfoServlet.java
@@ -149,7 +149,7 @@ public class InfoServlet extends HttpServlet
// contact = -1
int AD_User_ID = WebUtil.getParameterAsInt(request, "contact");
//
- log.fine("Subscribe=" + subscribe
+ if (log.isLoggable(Level.FINE)) log.fine("Subscribe=" + subscribe
+ ",R_InterestArea_ID=" + R_InterestArea_ID
+ ",AD_User_ID=" + AD_User_ID);
if (R_InterestArea_ID == 0 || AD_User_ID == 0)
diff --git a/org.adempiere.webstore.servlet/src/org/compiere/wstore/InvoiceServlet.java b/org.adempiere.webstore.servlet/src/org/compiere/wstore/InvoiceServlet.java
index 7750d25d71..c945417593 100644
--- a/org.adempiere.webstore.servlet/src/org/compiere/wstore/InvoiceServlet.java
+++ b/org.adempiere.webstore.servlet/src/org/compiere/wstore/InvoiceServlet.java
@@ -170,7 +170,7 @@ public class InvoiceServlet extends HttpServlet
MInvoice invoice = new MInvoice (ctx, C_Invoice_ID, null);
if (invoice.getC_Invoice_ID() != C_Invoice_ID)
{
- log.fine("Invoice not found - ID=" + C_Invoice_ID);
+ if (log.isLoggable(Level.FINE)) log.fine("Invoice not found - ID=" + C_Invoice_ID);
return "Invoice not found";
}
// Get WebUser & Compare with invoice
@@ -230,7 +230,7 @@ public class InvoiceServlet extends HttpServlet
response.setBufferSize(bufferSize);
response.setContentLength(fileLength);
//
- log.fine(file.getAbsolutePath() + ", length=" + fileLength);
+ if (log.isLoggable(Level.FINE)) log.fine(file.getAbsolutePath() + ", length=" + fileLength);
long time = System.currentTimeMillis(); // timer start
//
FileInputStream in = new FileInputStream (file);
@@ -253,7 +253,7 @@ public class InvoiceServlet extends HttpServlet
in.close();
time = System.currentTimeMillis() - time;
double speed = (totalSize/1024) / ((double)time/1000);
- log.fine("Length="
+ if (log.isLoggable(Level.FINE)) log.fine("Length="
+ totalSize + " - "
+ time + " ms - "
+ speed + " kB/sec");
diff --git a/org.adempiere.webstore.servlet/src/org/compiere/wstore/LocationTag.java b/org.adempiere.webstore.servlet/src/org/compiere/wstore/LocationTag.java
index d991cf4285..9e2aa0d7ed 100644
--- a/org.adempiere.webstore.servlet/src/org/compiere/wstore/LocationTag.java
+++ b/org.adempiere.webstore.servlet/src/org/compiere/wstore/LocationTag.java
@@ -260,7 +260,7 @@ public class LocationTag extends TagSupport
- log.fine("C_Country_ID=" + C_Country_ID + ", C_Region_ID=" + C_Region_ID
+ if (log.isLoggable(Level.FINE)) log.fine("C_Country_ID=" + C_Country_ID + ", C_Region_ID=" + C_Region_ID
+ ", RegionName=" + regionName + ", City=" + city + ", Postal=" + postal);
JspWriter out = pageContext.getOut();
diff --git a/org.adempiere.webstore.servlet/src/org/compiere/wstore/LoginServlet.java b/org.adempiere.webstore.servlet/src/org/compiere/wstore/LoginServlet.java
index 2f4b4f107c..3bc9650a69 100644
--- a/org.adempiere.webstore.servlet/src/org/compiere/wstore/LoginServlet.java
+++ b/org.adempiere.webstore.servlet/src/org/compiere/wstore/LoginServlet.java
@@ -18,6 +18,7 @@ package org.compiere.wstore;
import java.io.IOException;
import java.util.Properties;
+import java.util.logging.Level;
import javax.servlet.RequestDispatcher;
import javax.servlet.ServletConfig;
@@ -184,7 +185,7 @@ public class LoginServlet extends HttpServlet
url += "?SalesRep_ID=" + salesRep;
//
//String mode = WebUtil.getParameter (request, "Mode");
- log.fine("- targeting url=" + url); // + " - mode=" + mode);
+ if (log.isLoggable(Level.FINE)) log.fine("- targeting url=" + url); // + " - mode=" + mode);
// Web User
WebUser wu = WebUser.get(request);
diff --git a/org.adempiere.webstore.servlet/src/org/compiere/wstore/MessageTag.java b/org.adempiere.webstore.servlet/src/org/compiere/wstore/MessageTag.java
index 4fe88c6fda..45041caf4c 100644
--- a/org.adempiere.webstore.servlet/src/org/compiere/wstore/MessageTag.java
+++ b/org.adempiere.webstore.servlet/src/org/compiere/wstore/MessageTag.java
@@ -17,6 +17,7 @@
package org.compiere.wstore;
import java.util.Properties;
+import java.util.logging.Level;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.jsp.JspException;
@@ -65,7 +66,7 @@ public class MessageTag extends TagSupport
{
Properties ctx = JSPEnv.getCtx((HttpServletRequest)pageContext.getRequest());
String msg = Msg.translate(ctx, m_txt);
- log.fine(m_txt + "->" + msg);
+ if (log.isLoggable(Level.FINE)) log.fine(m_txt + "->" + msg);
//
try
{
diff --git a/org.adempiere.webstore.servlet/src/org/compiere/wstore/NoteServlet.java b/org.adempiere.webstore.servlet/src/org/compiere/wstore/NoteServlet.java
index fa28bd64a5..597af8f094 100644
--- a/org.adempiere.webstore.servlet/src/org/compiere/wstore/NoteServlet.java
+++ b/org.adempiere.webstore.servlet/src/org/compiere/wstore/NoteServlet.java
@@ -18,6 +18,7 @@ package org.compiere.wstore;
import java.io.IOException;
import java.util.Properties;
+import java.util.logging.Level;
import javax.servlet.RequestDispatcher;
import javax.servlet.ServletConfig;
@@ -156,14 +157,14 @@ public class NoteServlet extends HttpServlet
MNote doc = new MNote (ctx, AD_Note_ID, null);
if (doc.getAD_Note_ID() != AD_Note_ID)
{
- log.fine("Note not found - ID=" + AD_Note_ID);
+ if (log.isLoggable(Level.FINE)) log.fine("Note not found - ID=" + AD_Note_ID);
return "Notice not found";
}
MAttachment attachment = doc.getAttachment(false);
if (attachment == null)
{
- log.fine("No Attachment for AD_Note_ID=" + AD_Note_ID);
+ if (log.isLoggable(Level.FINE)) log.fine("No Attachment for AD_Note_ID=" + AD_Note_ID);
return "Notice Attachment not found";
}
@@ -221,7 +222,7 @@ public class NoteServlet extends HttpServlet
{
note.setProcessed(true);
note.saveEx();
- log.fine("doPost - " + note);
+ if (log.isLoggable(Level.FINE)) log.fine("doPost - " + note);
}
}
diff --git a/org.adempiere.webstore.servlet/src/org/compiere/wstore/OrderServlet.java b/org.adempiere.webstore.servlet/src/org/compiere/wstore/OrderServlet.java
index bd34cf92ab..47e69809e3 100644
--- a/org.adempiere.webstore.servlet/src/org/compiere/wstore/OrderServlet.java
+++ b/org.adempiere.webstore.servlet/src/org/compiere/wstore/OrderServlet.java
@@ -18,6 +18,7 @@ package org.compiere.wstore;
import java.io.IOException;
import java.util.Properties;
+import java.util.logging.Level;
import javax.servlet.RequestDispatcher;
import javax.servlet.ServletConfig;
@@ -257,7 +258,7 @@ public class OrderServlet extends HttpServlet
if (C_Order_ID == 0)
return null;
- log.fine("C_Order_ID=" + C_Order_ID);
+ if (log.isLoggable(Level.FINE)) log.fine("C_Order_ID=" + C_Order_ID);
return new MOrder (ctx, C_Order_ID, null);
} // getOrder
@@ -285,7 +286,7 @@ public class OrderServlet extends HttpServlet
}
// We have a Order No & DocAction
- log.fine("DocAction=" + DocAction);
+ if (log.isLoggable(Level.FINE)) log.fine("DocAction=" + DocAction);
if (!MOrder.DOCACTION_Void.equals(DocAction))
{
// Do not complete Prepayment
diff --git a/org.adempiere.webstore.servlet/src/org/compiere/wstore/PaymentServlet.java b/org.adempiere.webstore.servlet/src/org/compiere/wstore/PaymentServlet.java
index 137e5b6c0b..1e851dcdad 100644
--- a/org.adempiere.webstore.servlet/src/org/compiere/wstore/PaymentServlet.java
+++ b/org.adempiere.webstore.servlet/src/org/compiere/wstore/PaymentServlet.java
@@ -19,6 +19,7 @@ package org.compiere.wstore;
import java.io.IOException;
import java.math.BigDecimal;
import java.util.Properties;
+import java.util.logging.Level;
import javax.servlet.RequestDispatcher;
import javax.servlet.ServletConfig;
@@ -286,7 +287,7 @@ public class PaymentServlet extends HttpServlet
}
else
{
- log.fine(payment.getErrorMessage());
+ if (log.isLoggable(Level.FINE)) log.fine(payment.getErrorMessage());
String errMsg = payment.getErrorMessage();
payment.save ();
payment.setErrorMessage(errMsg);
diff --git a/org.adempiere.webstore.servlet/src/org/compiere/wstore/PriceList.java b/org.adempiere.webstore.servlet/src/org/compiere/wstore/PriceList.java
index 44aff45f98..f89baf8c7a 100644
--- a/org.adempiere.webstore.servlet/src/org/compiere/wstore/PriceList.java
+++ b/org.adempiere.webstore.servlet/src/org/compiere/wstore/PriceList.java
@@ -328,7 +328,7 @@ public class PriceList
DB.close(rs, pstmt);
rs = null; pstmt = null;
}
- log.fine("load #" + m_prices.size() + ", Search=" + m_searchInfo);
+ if (log.isLoggable(Level.FINE)) log.fine("load #" + m_prices.size() + ", Search=" + m_searchInfo);
} // load
diff --git a/org.adempiere.webstore.servlet/src/org/compiere/wstore/PriceListTag.java b/org.adempiere.webstore.servlet/src/org/compiere/wstore/PriceListTag.java
index ec5773e62e..c9fa5ab0b2 100644
--- a/org.adempiere.webstore.servlet/src/org/compiere/wstore/PriceListTag.java
+++ b/org.adempiere.webstore.servlet/src/org/compiere/wstore/PriceListTag.java
@@ -17,6 +17,7 @@
package org.compiere.wstore;
import java.util.Properties;
+import java.util.logging.Level;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpSession;
@@ -92,7 +93,7 @@ public class PriceListTag extends TagSupport
int PriceList_ID = wu.getM_PriceList_ID();
if (PriceList_ID != 0)
{
- log.fine("- using BP PriceList_ID=" + PriceList_ID);
+ if (log.isLoggable(Level.FINE)) log.fine("- using BP PriceList_ID=" + PriceList_ID);
M_PriceList_ID = PriceList_ID;
}
}
@@ -111,7 +112,7 @@ public class PriceListTag extends TagSupport
// Set Price List
HttpSession session = pageContext.getSession();
session.setAttribute (PriceList.NAME, m_priceList);
- log.fine("PL=" + m_priceList);
+ if (log.isLoggable(Level.FINE)) log.fine("PL=" + m_priceList);
// Set Locale from Price List
String AD_Language = m_priceList.getAD_Language();
diff --git a/org.adempiere.webstore.servlet/src/org/compiere/wstore/ProductCategoryListTag.java b/org.adempiere.webstore.servlet/src/org/compiere/wstore/ProductCategoryListTag.java
index f30fcb5075..7f38e83579 100644
--- a/org.adempiere.webstore.servlet/src/org/compiere/wstore/ProductCategoryListTag.java
+++ b/org.adempiere.webstore.servlet/src/org/compiere/wstore/ProductCategoryListTag.java
@@ -17,6 +17,7 @@
package org.compiere.wstore;
import java.util.Properties;
+import java.util.logging.Level;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.jsp.JspException;
@@ -69,7 +70,7 @@ public class ProductCategoryListTag extends TagSupport
select sel = new select (name, options);
sel.setID("ID_" + name);
- log.fine("AD_Client_ID=" + AD_Client_ID + ", #=" + options.length);
+ if (log.isLoggable(Level.FINE)) log.fine("AD_Client_ID=" + AD_Client_ID + ", #=" + options.length);
// Assemble
HtmlCode html = new HtmlCode();
diff --git a/org.adempiere.webstore.servlet/src/org/compiere/wstore/RequestOrderRefTag.java b/org.adempiere.webstore.servlet/src/org/compiere/wstore/RequestOrderRefTag.java
index fa04736242..3828a6c6a5 100644
--- a/org.adempiere.webstore.servlet/src/org/compiere/wstore/RequestOrderRefTag.java
+++ b/org.adempiere.webstore.servlet/src/org/compiere/wstore/RequestOrderRefTag.java
@@ -152,7 +152,7 @@ public class RequestOrderRefTag extends TagSupport
// Return to Array and return
option options[] = new option [list.size()];
list.toArray(options);
- log.fine("#" + options.length);
+ if (log.isLoggable(Level.FINE)) log.fine("#" + options.length);
return options;
} // getOptions
diff --git a/org.adempiere.webstore.servlet/src/org/compiere/wstore/RequestServlet.java b/org.adempiere.webstore.servlet/src/org/compiere/wstore/RequestServlet.java
index be2e10b166..ffb3424c4a 100644
--- a/org.adempiere.webstore.servlet/src/org/compiere/wstore/RequestServlet.java
+++ b/org.adempiere.webstore.servlet/src/org/compiere/wstore/RequestServlet.java
@@ -175,14 +175,14 @@ public class RequestServlet extends HttpServlet
MRequest doc = new MRequest (ctx, R_Request_ID, null);
if (doc.getR_Request_ID() != R_Request_ID)
{
- log.fine("Request not found - R_Request_ID=" + R_Request_ID);
+ if (log.isLoggable(Level.FINE)) log.fine("Request not found - R_Request_ID=" + R_Request_ID);
return "Request not found";
}
MAttachment attachment = doc.getAttachment(false);
if (attachment == null)
{
- log.fine("No Attachment for R_Request_ID=" + R_Request_ID);
+ if (log.isLoggable(Level.FINE)) log.fine("No Attachment for R_Request_ID=" + R_Request_ID);
return "Request Attachment not found";
}
@@ -246,7 +246,7 @@ public class RequestServlet extends HttpServlet
String source = WebUtil.getParameter (request, P_SOURCE);
String info = WebUtil.getParameter (request, P_INFO);
String forwardTo = WebUtil.getParameter (request, P_FORWARDTO);
- log.fine("Referer=" + requestRef + ", Source=" + source + ", ForwardTo=" + forwardTo);
+ if (log.isLoggable(Level.FINE)) log.fine("Referer=" + requestRef + ", Source=" + source + ", ForwardTo=" + forwardTo);
if (requestURL == null)
requestURL = "";
if (requestURL.equals(requestRef)) // if URL and Referrer are the same, get source
@@ -409,7 +409,7 @@ public class RequestServlet extends HttpServlet
return;
}
String fileName = upload.getFileName();
- log.fine("R_Request_ID=" + R_Request_ID + " - " + fileName);
+ if (log.isLoggable(Level.FINE)) log.fine("R_Request_ID=" + R_Request_ID + " - " + fileName);
// Add Attachment
MAttachment attachment = req.createAttachment();
@@ -423,7 +423,7 @@ public class RequestServlet extends HttpServlet
}
else
WebUtil.createForwardPage(response, "File Upload Error - Please try again", "requests.jsp", 10);
- log.fine(attachment.toString());
+ if (log.isLoggable(Level.FINE)) log.fine(attachment.toString());
} // uploadFile
diff --git a/org.adempiere.webstore.servlet/src/org/compiere/wstore/RequestTypeTag.java b/org.adempiere.webstore.servlet/src/org/compiere/wstore/RequestTypeTag.java
index 18946d096a..36783b475e 100644
--- a/org.adempiere.webstore.servlet/src/org/compiere/wstore/RequestTypeTag.java
+++ b/org.adempiere.webstore.servlet/src/org/compiere/wstore/RequestTypeTag.java
@@ -120,7 +120,7 @@ public class RequestTypeTag extends TagSupport
// Return to Array and return
option options[] = new option [list.size()];
list.toArray(options);
- log.fine("#" + options.length);
+ if (log.isLoggable(Level.FINE)) log.fine("#" + options.length);
return options;
} // getOptions
diff --git a/org.adempiere.webstore.servlet/src/org/compiere/wstore/RfQServlet.java b/org.adempiere.webstore.servlet/src/org/compiere/wstore/RfQServlet.java
index 87a0de7861..f798d141b7 100644
--- a/org.adempiere.webstore.servlet/src/org/compiere/wstore/RfQServlet.java
+++ b/org.adempiere.webstore.servlet/src/org/compiere/wstore/RfQServlet.java
@@ -153,7 +153,7 @@ public class RfQServlet extends HttpServlet
MRfQ doc = new MRfQ (ctx, C_RfQ_ID, null);
if (doc.getC_RfQ_ID() != C_RfQ_ID)
{
- log.fine("streamAttachment - RfQ not found - ID=" + C_RfQ_ID);
+ if (log.isLoggable(Level.FINE)) log.fine("streamAttachment - RfQ not found - ID=" + C_RfQ_ID);
return "RfQ not found";
}
@@ -173,7 +173,7 @@ public class RfQServlet extends HttpServlet
response.setBufferSize(bufferSize);
response.setContentLength(fileLength);
//
- log.fine("streamAttachment - length=" + fileLength);
+ if (log.isLoggable(Level.FINE)) log.fine("streamAttachment - length=" + fileLength);
long time = System.currentTimeMillis(); // timer start
//
ServletOutputStream out = response.getOutputStream ();
@@ -183,7 +183,7 @@ public class RfQServlet extends HttpServlet
//
time = System.currentTimeMillis() - time;
double speed = (fileLength/(double)1024) / (time/(double)1000);
- log.fine("streamInvoice - length="
+ if (log.isLoggable(Level.FINE)) log.fine("streamInvoice - length="
+ fileLength + " - "
+ time + " ms - "
+ speed + " kB/sec");
@@ -257,7 +257,7 @@ public class RfQServlet extends HttpServlet
*/
private String updateResponse (HttpServletRequest request, MRfQResponse rfqResponse)
{
- log.fine("updateResponse - " + rfqResponse);
+ if (log.isLoggable(Level.FINE)) log.fine("updateResponse - " + rfqResponse);
String saveError = "RfQ NOT updated";
String msg = "RfQ updated";
// RfQ Response
@@ -311,7 +311,7 @@ public class RfQServlet extends HttpServlet
return saveError;
}
}
- log.fine("complete - " + rfqResponse);
+ if (log.isLoggable(Level.FINE)) log.fine("complete - " + rfqResponse);
return msg;
} // updateResponse
diff --git a/org.adempiere.webstore.servlet/src/org/compiere/wstore/WebOrder.java b/org.adempiere.webstore.servlet/src/org/compiere/wstore/WebOrder.java
index ad4346a2b4..d7b53df857 100644
--- a/org.adempiere.webstore.servlet/src/org/compiere/wstore/WebOrder.java
+++ b/org.adempiere.webstore.servlet/src/org/compiere/wstore/WebOrder.java
@@ -19,6 +19,7 @@ package org.compiere.wstore;
import java.math.BigDecimal;
import java.util.ArrayList;
import java.util.Properties;
+import java.util.logging.Level;
import org.compiere.model.MCurrency;
import org.compiere.model.MInvoice;
@@ -77,7 +78,7 @@ public class WebOrder
private boolean createOrder (WebUser wu, WebBasket wb)
{
m_order = new MOrder (m_ctx, 0, null);
- log.fine("AD_Client_ID=" + m_order.getAD_Client_ID()
+ if (log.isLoggable(Level.FINE)) log.fine("AD_Client_ID=" + m_order.getAD_Client_ID()
+ ",AD_Org_ID=" + m_order.getAD_Org_ID() + " - " + m_order);
//
m_order.setC_DocTypeTarget_ID(MOrder.DocSubTypeSO_Prepay);
@@ -98,7 +99,7 @@ public class WebOrder
m_order.setSendEMail(true);
m_order.setDocAction(MOrder.DOCACTION_Prepare);
m_order.saveEx();
- log.fine("ID=" + m_order.getC_Order_ID()
+ if (log.isLoggable(Level.FINE)) log.fine("ID=" + m_order.getC_Order_ID()
+ ", DocNo=" + m_order.getDocumentNo());
ArrayList lines = wb.getLines();
diff --git a/org.adempiere.webstore.servlet/src/org/compiere/wstore/WorkflowServlet.java b/org.adempiere.webstore.servlet/src/org/compiere/wstore/WorkflowServlet.java
index 12142ccc91..dae0d9811e 100644
--- a/org.adempiere.webstore.servlet/src/org/compiere/wstore/WorkflowServlet.java
+++ b/org.adempiere.webstore.servlet/src/org/compiere/wstore/WorkflowServlet.java
@@ -18,6 +18,7 @@ package org.compiere.wstore;
import java.io.IOException;
import java.util.Properties;
+import java.util.logging.Level;
import javax.servlet.RequestDispatcher;
import javax.servlet.ServletConfig;
@@ -157,14 +158,14 @@ public class WorkflowServlet extends HttpServlet
MWFActivity doc = new MWFActivity (ctx, AD_WF_Activity_ID, null);
if (doc.get_ID() != AD_WF_Activity_ID)
{
- log.fine("streamAttachment - Activity not found - ID=" + AD_WF_Activity_ID);
+ if (log.isLoggable(Level.FINE)) log.fine("streamAttachment - Activity not found - ID=" + AD_WF_Activity_ID);
return "Activity not found";
}
MAttachment attachment = doc.getAttachment(false);
if (attachment == null)
{
- log.fine("streamAttachment - No Attachment for AD_WF_Activity_ID=" + AD_WF_Activity_ID);
+ if (log.isLoggable(Level.FINE)) log.fine("streamAttachment - No Attachment for AD_WF_Activity_ID=" + AD_WF_Activity_ID);
return "Notice Attachment not found";
}
@@ -222,10 +223,10 @@ public class WorkflowServlet extends HttpServlet
boolean isApproved = WebUtil.getParameterAsBoolean (request, "IsApproved");
boolean isRejected = WebUtil.getParameterAsBoolean (request, "IsApproved");
String textMsg = WebUtil.getParameter (request, "textMsg");
- log.fine("doPost - TextMsg=" + textMsg);
+ if (log.isLoggable(Level.FINE)) log.fine("doPost - TextMsg=" + textMsg);
//
MWFActivity act = new MWFActivity (ctx, AD_WF_Activity_ID, null);
- log.fine("doPost - " + act);
+ if (log.isLoggable(Level.FINE)) log.fine("doPost - " + act);
if (AD_WF_Activity_ID == 0 || act == null || act.getAD_WF_Activity_ID() != AD_WF_Activity_ID)
session.setAttribute(WebSessionCtx.HDR_MESSAGE, "Activity not found");
diff --git a/org.compiere.db.oracle.provider/src/org/adempiere/db/oracle/config/ConfigOracle.java b/org.compiere.db.oracle.provider/src/org/adempiere/db/oracle/config/ConfigOracle.java
index b05efd612b..b26ec4aba4 100644
--- a/org.compiere.db.oracle.provider/src/org/adempiere/db/oracle/config/ConfigOracle.java
+++ b/org.compiere.db.oracle.provider/src/org/adempiere/db/oracle/config/ConfigOracle.java
@@ -463,7 +463,7 @@ public class ConfigOracle implements IDatabaseConfig
*/
private boolean testJDBC (String url, String uid, String pwd)
{
- log.fine("Url=" + url + ", UID=" + uid);
+ if (log.isLoggable(Level.FINE)) log.fine("Url=" + url + ", UID=" + uid);
try
{
DriverManager.registerDriver(Database.getDatabase(Database.DB_ORACLE).getDriver());
diff --git a/org.idempiere.fitnesse.fixture/src/org/idempiere/fitnesse/fixture/RunProcess.java b/org.idempiere.fitnesse.fixture/src/org/idempiere/fitnesse/fixture/RunProcess.java
index 90b582f69a..359174500a 100644
--- a/org.idempiere.fitnesse.fixture/src/org/idempiere/fitnesse/fixture/RunProcess.java
+++ b/org.idempiere.fitnesse.fixture/src/org/idempiere/fitnesse/fixture/RunProcess.java
@@ -31,6 +31,7 @@ import java.sql.Timestamp;
import java.text.SimpleDateFormat;
import java.util.HashMap;
import java.util.Properties;
+import java.util.logging.Level;
import org.compiere.model.Lookup;
import org.compiere.model.MPInstance;
@@ -275,7 +276,7 @@ public class RunProcess extends TableFixture {
if (ob!=null)
valueString2 = ob.toString();
}
- log.fine("fillParameter - " + key + " = " + valueString);
+ if (log.isLoggable(Level.FINE)) log.fine("fillParameter - " + key + " = " + valueString);
Object value = valueString;
if (valueString != null && valueString.length() == 0)
value = null;
@@ -305,7 +306,7 @@ public class RunProcess extends TableFixture {
else
bd = new BigDecimal (value.toString());
iPara.setP_Number(bd);
- log.fine("fillParameter - " + key
+ if (log.isLoggable(Level.FINE)) log.fine("fillParameter - " + key
+ " = " + valueString + " (=" + bd + "=)");
if (pPara.isRange())
@@ -347,7 +348,7 @@ public class RunProcess extends TableFixture {
}
- log.fine("fillParameter - " + key
+ if (log.isLoggable(Level.FINE)) log.fine("fillParameter - " + key
+ " = " + valueString + " (=" + ts + "=)");
}
else if (DisplayType.YesNo == pPara.getAD_Reference_ID())
diff --git a/org.idempiere.webservices/WEB-INF/src/org/idempiere/adinterface/Process.java b/org.idempiere.webservices/WEB-INF/src/org/idempiere/adinterface/Process.java
index c968c92573..c421708295 100644
--- a/org.idempiere.webservices/WEB-INF/src/org/idempiere/adinterface/Process.java
+++ b/org.idempiere.webservices/WEB-INF/src/org/idempiere/adinterface/Process.java
@@ -428,7 +428,7 @@ public class Process {
if (ob!=null)
valueString2 = ob.toString();
}
- log.fine("fillParameter - " + key + " = " + valueString);
+ if (log.isLoggable(Level.FINE)) log.fine("fillParameter - " + key + " = " + valueString);
Object value = valueString;
if (valueString != null && valueString.length() == 0)
value = null;
@@ -458,7 +458,7 @@ public class Process {
else
bd = new BigDecimal (value.toString());
iPara.setP_Number(bd);
- log.fine("fillParameter - " + key
+ if (log.isLoggable(Level.FINE)) log.fine("fillParameter - " + key
+ " = " + valueString + " (=" + bd + "=)");
if (pPara.isRange())
@@ -498,7 +498,7 @@ public class Process {
}
- log.fine("fillParameter - " + key
+ if (log.isLoggable(Level.FINE)) log.fine("fillParameter - " + key
+ " = " + valueString + " (=" + ts + "=)");
}
else if (DisplayType.YesNo == pPara.getAD_Reference_ID())