details:   https://code.openbravo.com/erp/devel/pi/rev/bf8836816014
changeset: 31041:bf8836816014
user:      Atul Gaware <atul.gaware <at> openbravo.com>
date:      Fri Dec 23 22:18:43 2016 +0530
summary:   Fixes Issue 34785:Report's general ledger should be defaulted to
organization's general ledger, when organization is filled by default

In Default method, organization is blank, in this case get the organization
information from current user session and get the Default Ledger for
selected organization.

diffstat:

 src/org/openbravo/erpCommon/ad_reports/ReportGeneralLedger.java        |  2 +-
 src/org/openbravo/erpCommon/ad_reports/ReportGeneralLedgerJournal.java |  3 ++-
 src/org/openbravo/erpCommon/ad_reports/ReportTrialBalance.java         |  2 +-
 3 files changed, 4 insertions(+), 3 deletions(-)

diffs (37 lines):

diff -r 220abb789afd -r bf8836816014 
src/org/openbravo/erpCommon/ad_reports/ReportGeneralLedger.java
--- a/src/org/openbravo/erpCommon/ad_reports/ReportGeneralLedger.java   Fri Dec 
23 19:43:21 2016 +0000
+++ b/src/org/openbravo/erpCommon/ad_reports/ReportGeneralLedger.java   Fri Dec 
23 22:18:43 2016 +0530
@@ -60,7 +60,7 @@
     VariablesSecureApp vars = new VariablesSecureApp(request);
 
     if (vars.commandIn("DEFAULT")) {
-      String strOrg = vars.getGlobalVariable("inpOrg", 
"ReportGeneralLedger|Org", "0");
+      String strOrg = vars.getGlobalVariable("inpOrg", 
"ReportGeneralLedger|Org", vars.getOrg());
       String strcAcctSchemaId = OBLedgerUtils.getOrgLedger(strOrg);
       String strDateFrom = vars
           .getGlobalVariable("inpDateFrom", "ReportGeneralLedger|DateFrom", 
"");
diff -r 220abb789afd -r bf8836816014 
src/org/openbravo/erpCommon/ad_reports/ReportGeneralLedgerJournal.java
--- a/src/org/openbravo/erpCommon/ad_reports/ReportGeneralLedgerJournal.java    
Fri Dec 23 19:43:21 2016 +0000
+++ b/src/org/openbravo/erpCommon/ad_reports/ReportGeneralLedgerJournal.java    
Fri Dec 23 22:18:43 2016 +0530
@@ -90,7 +90,8 @@
       log4j.debug("Command: " + vars.getStringParameter("Command"));
 
     if (vars.commandIn("DEFAULT")) {
-      String strOrg = vars.getGlobalVariable("inpOrg", 
"ReportGeneralLedgerJournal|Org", "0");
+      String strOrg = vars.getGlobalVariable("inpOrg", 
"ReportGeneralLedgerJournal|Org",
+          vars.getOrg());
       String strcAcctSchemaId = OBLedgerUtils.getOrgLedger(strOrg);
       String strDateFrom = vars.getGlobalVariable("inpDateFrom",
           "ReportGeneralLedgerJournal|DateFrom", "");
diff -r 220abb789afd -r bf8836816014 
src/org/openbravo/erpCommon/ad_reports/ReportTrialBalance.java
--- a/src/org/openbravo/erpCommon/ad_reports/ReportTrialBalance.java    Fri Dec 
23 19:43:21 2016 +0000
+++ b/src/org/openbravo/erpCommon/ad_reports/ReportTrialBalance.java    Fri Dec 
23 22:18:43 2016 +0530
@@ -64,7 +64,7 @@
     VariablesSecureApp vars = new VariablesSecureApp(request);
 
     if (vars.commandIn("DEFAULT")) {
-      String strOrg = vars.getGlobalVariable("inpOrg", 
"ReportTrialBalance|Org", "");
+      String strOrg = vars.getGlobalVariable("inpOrg", 
"ReportTrialBalance|Org", vars.getOrg());
       String strcAcctSchemaId = OBLedgerUtils.getOrgLedger(strOrg);
       String strDateFrom = vars.getGlobalVariable("inpDateFrom", 
"ReportTrialBalance|DateFrom", "");
       String strDateTo = vars.getGlobalVariable("inpDateTo", 
"ReportTrialBalance|DateTo", "");

------------------------------------------------------------------------------
Developer Access Program for Intel Xeon Phi Processors
Access to Intel Xeon Phi processor-based developer platforms.
With one year of Intel Parallel Studio XE.
Training and support from Colfax.
Order your platform today.http://sdm.link/intel
_______________________________________________
Openbravo-commits mailing list
Openbravo-commits@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/openbravo-commits

Reply via email to