Hi Hans,
this commit has broken the accounting report (trial balance etc...); see for example: https://demo-trunk-ofbiz.apache.org/accounting/control/IncomeStatement?organizationPartyId=Company Could you please look into it? Thank you Jacopo On Fri, Feb 5, 2016 at 2:45 AM, <[hidden email]> wrote: > Author: hansbak > Date: Fri Feb 5 01:45:50 2016 > New Revision: 1728584 > > URL: http://svn.apache.org/viewvc?rev=1728584&view=rev > Log: > be able to set accounting company in the header, so other companent can > change it too. https://issues.apache.org/jira/browse/OFBIZ-6802 > > Modified: > > ofbiz/trunk/applications/accounting/script/org/ofbiz/accounting/admin/AcctgAdminServices.xml > ofbiz/trunk/applications/accounting/servicedef/secas.xml > ofbiz/trunk/applications/accounting/servicedef/services_admin.xml > > ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/chartofaccounts/TaxAuthorityGlAccounts.groovy > > ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/reports/BalanceSheet.groovy > > ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/reports/CashFlowStatement.groovy > > ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/reports/GlAccountTrialBalance.groovy > > ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/reports/IncomeStatement.groovy > > ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/reports/TransactionTotals.groovy > > ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/controller.xml > > ofbiz/trunk/applications/accounting/webapp/accounting/reports/GlAccountTrialBalanceReport.ftl > ofbiz/trunk/applications/accounting/widget/CommonScreens.xml > ofbiz/trunk/applications/accounting/widget/GlScreens.xml > ofbiz/trunk/applications/accounting/widget/GlSetupForms.xml > ofbiz/trunk/applications/accounting/widget/GlSetupScreens.xml > > ofbiz/trunk/applications/accounting/widget/ReportFinancialSummaryForms.xml > > ofbiz/trunk/applications/accounting/widget/ReportFinancialSummaryScreens.xml > > ofbiz/trunk/applications/commonext/webapp/ofbizsetup/organization/changeOrgPartyId.groovy > ofbiz/trunk/applications/commonext/widget/CommonScreens.xml > > ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/order/CompanyHeader.groovy > ofbiz/trunk/framework/common/config/CommonUiLabels.xml > ofbiz/trunk/framework/common/webcommon/WEB-INF/common-controller.xml > ofbiz/trunk/framework/common/webcommon/includes/listVisualThemes.ftl > ofbiz/trunk/framework/common/widget/CommonScreens.xml > ofbiz/trunk/framework/common/widget/LookupScreens.xml > ofbiz/trunk/themes/bizznesstime/includes/header.ftl > ofbiz/trunk/themes/bizznesstime/webapp/bizznesstime/js/application.js > ofbiz/trunk/themes/bluelight/includes/header.ftl > ofbiz/trunk/themes/droppingcrumbs/includes/header.ftl > ofbiz/trunk/themes/tomahawk/includes/appbarClose.ftl > > Modified: > ofbiz/trunk/applications/accounting/script/org/ofbiz/accounting/admin/AcctgAdminServices.xml > URL: > http://svn.apache.org/viewvc/ofbiz/trunk/applications/accounting/script/org/ofbiz/accounting/admin/AcctgAdminServices.xml?rev=1728584&r1=1728583&r2=1728584&view=diff > > ============================================================================== > --- > ofbiz/trunk/applications/accounting/script/org/ofbiz/accounting/admin/AcctgAdminServices.xml > (original) > +++ > ofbiz/trunk/applications/accounting/script/org/ofbiz/accounting/admin/AcctgAdminServices.xml > Fri Feb 5 01:45:50 2016 > @@ -101,6 +101,20 @@ under the License. > </if-not-empty> > </simple-method> > > + <simple-method method-name="setAcctgCompany" short-description="Set > Accounting Company when select or create an accounting company"> > + <!-- set user preference --> > + <entity-one entity-name="PartyAcctgPreference" > value-field="partyAcctgPreference"> > + <field-map field-name="partyId" > from-field="parameters.organizationPartyId"/> > + </entity-one> > + <if-not-empty field="partyAcctgPreference"> > + <set field="setUserPref.userPrefGroupTypeId" > value="GLOBAL_PREFERENCES"/> > + <set field="setUserPref.userPrefTypeId" > value="ORGANIZATION_PARTY"/> > + <set field="setUserPref.userPrefValue" > from-field="parameters.organizationPartyId"/> > + <call-service service-name="setUserPreference" > in-map-name="setUserPref"/> > + </if-not-empty> > + <field-to-result field="parameters.organizationPartyId" > result-name="organizationPartyId"/> > + </simple-method> > + > <!-- update currency conversion rates in the UomConversionDated > entity --> > <simple-method method-name="updateFXConversion" > short-description="Update Foreign Exchange conversion rate"> > <!-- set the FX rate changes as of now --> > > Modified: ofbiz/trunk/applications/accounting/servicedef/secas.xml > URL: > http://svn.apache.org/viewvc/ofbiz/trunk/applications/accounting/servicedef/secas.xml?rev=1728584&r1=1728583&r2=1728584&view=diff > > ============================================================================== > --- ofbiz/trunk/applications/accounting/servicedef/secas.xml (original) > +++ ofbiz/trunk/applications/accounting/servicedef/secas.xml Fri Feb 5 > 01:45:50 2016 > @@ -158,4 +158,10 @@ under the License. > <condition field-name="productTypeId" operator="equals" > value="ASSET_USAGE"/> > <action service="createFixedAssetAndLinkToProduct" mode="sync"/> > </eca> > + > + <!-- automatically set company to user when create an accounting > company --> > + <eca service="createPartyAcctgPreference" event="return"> > + <set field-name="organizationPartyId" env-name="partyId"/> > + <action service="setAcctgCompany" mode="sync"/> > + </eca> > </service-eca> > > Modified: ofbiz/trunk/applications/accounting/servicedef/services_admin.xml > URL: > http://svn.apache.org/viewvc/ofbiz/trunk/applications/accounting/servicedef/services_admin.xml?rev=1728584&r1=1728583&r2=1728584&view=diff > > ============================================================================== > --- ofbiz/trunk/applications/accounting/servicedef/services_admin.xml > (original) > +++ ofbiz/trunk/applications/accounting/servicedef/services_admin.xml Fri > Feb 5 01:45:50 2016 > @@ -65,6 +65,12 @@ under the License. > <attribute type="String" mode="IN" name="organizationPartyId" > optional="false"/> > <attribute name="partyAccountingPreference" > type="org.ofbiz.entity.GenericValue" mode="OUT" optional="true"/> > </service> > + <service name="setAcctgCompany" engine="simple" > + > location="component://accounting/script/org/ofbiz/accounting/admin/AcctgAdminServices.xml" > invoke="setAcctgCompany" auth="true"> > + <description>Set Accounting Company when select</description> > + <permission-service service-name="acctgPrefPermissionCheck" > main-action="CREATE"/> > + <attribute type="String" mode="INOUT" name="organizationPartyId" > optional="true"/> > + </service> > > <service name="updateFXConversion" engine="simple" > > location="component://accounting/script/org/ofbiz/accounting/admin/AcctgAdminServices.xml" > invoke="updateFXConversion"> > > Modified: > ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/chartofaccounts/TaxAuthorityGlAccounts.groovy > URL: > http://svn.apache.org/viewvc/ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/chartofaccounts/TaxAuthorityGlAccounts.groovy?rev=1728584&r1=1728583&r2=1728584&view=diff > > ============================================================================== > --- > ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/chartofaccounts/TaxAuthorityGlAccounts.groovy > (original) > +++ > ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/chartofaccounts/TaxAuthorityGlAccounts.groovy > Fri Feb 5 01:45:50 2016 > @@ -22,5 +22,5 @@ import org.ofbiz.base.util.UtilMisc; > taxAuthorities = from('TaxAuthority').orderBy("taxAuthGeoId", > "taxAuthPartyId").queryList(); > > context.taxAuthorityHavingNoGlAccountList = taxAuthorities.findAll { > taxAuthority -> > - !taxAuthority.getRelated('TaxAuthorityGlAccount', > [organizationPartyId : organizationPartyId], null, false) > + !taxAuthority.getRelated('TaxAuthorityGlAccount', > [organizationPartyId : > parameters.get('ApplicationDecorator|organizationPartyId')], null, false) > } > > Modified: > ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/reports/BalanceSheet.groovy > URL: > http://svn.apache.org/viewvc/ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/reports/BalanceSheet.groovy?rev=1728584&r1=1728583&r2=1728584&view=diff > > ============================================================================== > --- > ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/reports/BalanceSheet.groovy > (original) > +++ > ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/reports/BalanceSheet.groovy > Fri Feb 5 01:45:50 2016 > @@ -39,8 +39,8 @@ if (!glFiscalTypeId) { > } > > // Setup the divisions for which the report is executed > -List partyIds = > PartyWorker.getAssociatedPartyIdsByRelationshipType(delegator, > organizationPartyId, 'GROUP_ROLLUP'); > -partyIds.add(organizationPartyId); > +List partyIds = > PartyWorker.getAssociatedPartyIdsByRelationshipType(delegator, > parameters.get('ApplicationDecorator|organizationPartyId'), 'GROUP_ROLLUP'); > +partyIds.add(parameters.get('ApplicationDecorator|organizationPartyId')); > > // Get the group of account classes that will be used to position > accounts in the proper section of the financial statement > GenericValue assetGlAccountClass = > from("GlAccountClass").where("glAccountClassId", > "ASSET").cache(true).queryOne(); > @@ -63,7 +63,7 @@ GenericValue accumAmortizationGlAccountC > List accumAmortizationAccountClassIds = > UtilAccounting.getDescendantGlAccountClassIds(accumAmortizationGlAccountClass); > > // Find the last closed time period to get the fromDate for the > transactions in the current period and the ending balances of the last > closed period > -Map lastClosedTimePeriodResult = runService('findLastClosedDate', > ["organizationPartyId": organizationPartyId, "findDate": new > Date(thruDate.getTime()),"userLogin": userLogin]); > +Map lastClosedTimePeriodResult = runService('findLastClosedDate', > ["organizationPartyId": > parameters.get('ApplicationDecorator|organizationPartyId'), "findDate": new > Date(thruDate.getTime()),"userLogin": userLogin]); > Timestamp fromDate = (Timestamp)lastClosedTimePeriodResult.lastClosedDate; > if (!fromDate) { > return; > @@ -407,9 +407,9 @@ transactionTotals.each { transactionTota > transactionTotalsMap.put(transactionTotal.glAccountId, accountMap); > } > // Add the "retained earnings" account > -Map netIncomeResult = runService('prepareIncomeStatement', > ["organizationPartyId": organizationPartyId, "glFiscalTypeId": > glFiscalTypeId, "fromDate": fromDate, "thruDate": thruDate, "userLogin": > userLogin]); > +Map netIncomeResult = runService('prepareIncomeStatement', > ["organizationPartyId": > parameters.get('ApplicationDecorator|organizationPartyId'), > "glFiscalTypeId": glFiscalTypeId, "fromDate": fromDate, "thruDate": > thruDate, "userLogin": userLogin]); > BigDecimal netIncome = (BigDecimal)netIncomeResult.totalNetIncome; > -GenericValue retainedEarningsAccount = > from("GlAccountTypeDefault").where("glAccountTypeId", "RETAINED_EARNINGS", > "organizationPartyId", organizationPartyId).cache(true).queryOne(); > +GenericValue retainedEarningsAccount = > from("GlAccountTypeDefault").where("glAccountTypeId", "RETAINED_EARNINGS", > "organizationPartyId", > parameters.get('ApplicationDecorator|organizationPartyId')).cache(true).queryOne(); > if (retainedEarningsAccount) { > GenericValue retainedEarningsGlAccount = > retainedEarningsAccount.getRelatedOne("GlAccount", false); > transactionTotalsMap.put(retainedEarningsGlAccount.glAccountId, > UtilMisc.toMap("glAccountId", > retainedEarningsGlAccount.glAccountId,"accountName", > retainedEarningsGlAccount.accountName, "accountCode", > retainedEarningsGlAccount.accountCode, "balance", netIncome)); > > Modified: > ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/reports/CashFlowStatement.groovy > URL: > http://svn.apache.org/viewvc/ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/reports/CashFlowStatement.groovy?rev=1728584&r1=1728583&r2=1728584&view=diff > > ============================================================================== > --- > ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/reports/CashFlowStatement.groovy > (original) > +++ > ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/reports/CashFlowStatement.groovy > Fri Feb 5 01:45:50 2016 > @@ -43,8 +43,8 @@ uiLabelMap = UtilProperties.getResourceB > parametersFromDate = fromDate; > > // Setup the divisions for which the report is executed > -List partyIds = > PartyWorker.getAssociatedPartyIdsByRelationshipType(delegator, > organizationPartyId, 'GROUP_ROLLUP'); > -partyIds.add(organizationPartyId); > +List partyIds = > PartyWorker.getAssociatedPartyIdsByRelationshipType(delegator, > parameters.get('ApplicationDecorator|organizationPartyId'), 'GROUP_ROLLUP'); > +partyIds.add(parameters.get('ApplicationDecorator|organizationPartyId')); > > // Get the group of account classes that will be used to position > accounts in the proper section of the Cash Flow statement > GenericValue glAccountClass = > from("GlAccountClass").where("glAccountClassId", > "CASH_EQUIVALENT").cache(true).queryOne(); > @@ -53,7 +53,7 @@ List glAccountClassIds = UtilAccounting. > List cashFlowBalanceTotalList = []; > > // Find the last closed time period to get the fromDate for the > transactions in the current period and the ending balances of the last > closed period > -Map lastClosedTimePeriodResult = runService('findLastClosedDate', > ["organizationPartyId":organizationPartyId, "findDate":new > Date(parametersFromDate.getTime()),"userLogin":userLogin]); > +Map lastClosedTimePeriodResult = runService('findLastClosedDate', > ["organizationPartyId":parameters.get('ApplicationDecorator|organizationPartyId'), > "findDate":new Date(parametersFromDate.getTime()),"userLogin":userLogin]); > Timestamp periodClosingFromDate = > (Timestamp)lastClosedTimePeriodResult.lastClosedDate; > if (!periodClosingFromDate) { > return; > > Modified: > ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/reports/GlAccountTrialBalance.groovy > URL: > http://svn.apache.org/viewvc/ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/reports/GlAccountTrialBalance.groovy?rev=1728584&r1=1728583&r2=1728584&view=diff > > ============================================================================== > --- > ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/reports/GlAccountTrialBalance.groovy > (original) > +++ > ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/reports/GlAccountTrialBalance.groovy > Fri Feb 5 01:45:50 2016 > @@ -23,17 +23,17 @@ import org.ofbiz.base.util.UtilNumber; > import org.ofbiz.accounting.util.UtilAccounting; > import com.ibm.icu.util.Calendar; > > -if (organizationPartyId) { > +if (parameters.get('ApplicationDecorator|organizationPartyId')) { > onlyIncludePeriodTypeIdList = []; > onlyIncludePeriodTypeIdList.add("FISCAL_YEAR"); > - customTimePeriodResults = runService('findCustomTimePeriods', > [findDate : UtilDateTime.nowTimestamp(), organizationPartyId : > organizationPartyId, onlyIncludePeriodTypeIdList : > onlyIncludePeriodTypeIdList, userLogin : userLogin]); > + customTimePeriodResults = runService('findCustomTimePeriods', > [findDate : UtilDateTime.nowTimestamp(), organizationPartyId : > parameters.get('ApplicationDecorator|organizationPartyId'), > onlyIncludePeriodTypeIdList : onlyIncludePeriodTypeIdList, userLogin : > userLogin]); > customTimePeriodList = customTimePeriodResults.customTimePeriodList; > if (UtilValidate.isNotEmpty(customTimePeriodList)) { > context.timePeriod = > customTimePeriodList.first().customTimePeriodId; > } > decimals = UtilNumber.getBigDecimalScale("ledger.decimals"); > rounding = UtilNumber.getBigDecimalRoundingMode("ledger.rounding"); > - context.currentOrganization = from("PartyNameView").where("partyId", > organizationPartyId).queryOne(); > + context.currentOrganization = from("PartyNameView").where("partyId", > parameters.get('ApplicationDecorator|organizationPartyId')).queryOne(); > if (parameters.glAccountId) { > glAccount = from("GlAccount").where("glAccountId", > parameters.glAccountId).queryOne(); > isDebitAccount = UtilAccounting.isDebitAccount(glAccount); > @@ -49,7 +49,7 @@ if (organizationPartyId) { > previousTimePeriodResult = runService('getPreviousTimePeriod', > [customTimePeriodId : parameters.timePeriod, userLogin : userLogin]); > previousTimePeriod = previousTimePeriodResult.previousTimePeriod; > if (UtilValidate.isNotEmpty(previousTimePeriod)) { > - glAccountHistory = > from("GlAccountHistory").where("customTimePeriodId", > previousTimePeriod.customTimePeriodId, "glAccountId", > parameters.glAccountId, "organizationPartyId", > organizationPartyId).queryOne(); > + glAccountHistory = > from("GlAccountHistory").where("customTimePeriodId", > previousTimePeriod.customTimePeriodId, "glAccountId", > parameters.glAccountId, "organizationPartyId", > parameters.get('ApplicationDecorator|organizationPartyId')).queryOne(); > if (glAccountHistory && glAccountHistory.endingBalance != > null) { > context.openingBalance = glAccountHistory.endingBalance; > balanceOfTheAcctgForYear = glAccountHistory.endingBalance; > @@ -75,7 +75,7 @@ if (organizationPartyId) { > isPosted = ""; > } > acctgTransEntriesAndTransTotal = > runService('getAcctgTransEntriesAndTransTotal', > - [customTimePeriodStartDate : > customTimePeriodStartDate, customTimePeriodEndDate : > customTimePeriodEndDate, organizationPartyId : organizationPartyId, > glAccountId : parameters.glAccountId, isPosted : isPosted, userLogin : > userLogin]); > + [customTimePeriodStartDate : > customTimePeriodStartDate, customTimePeriodEndDate : > customTimePeriodEndDate, organizationPartyId : > parameters.get('ApplicationDecorator|organizationPartyId'), glAccountId : > parameters.glAccountId, isPosted : isPosted, userLogin : userLogin]); > totalOfYearToDateDebit = totalOfYearToDateDebit + > acctgTransEntriesAndTransTotal.debitTotal; > acctgTransEntriesAndTransTotal.totalOfYearToDateDebit = > totalOfYearToDateDebit.setScale(decimals, rounding); > totalOfYearToDateCredit = totalOfYearToDateCredit + > acctgTransEntriesAndTransTotal.creditTotal; > > Modified: > ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/reports/IncomeStatement.groovy > URL: > http://svn.apache.org/viewvc/ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/reports/IncomeStatement.groovy?rev=1728584&r1=1728583&r2=1728584&view=diff > > ============================================================================== > --- > ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/reports/IncomeStatement.groovy > (original) > +++ > ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/reports/IncomeStatement.groovy > Fri Feb 5 01:45:50 2016 > @@ -36,8 +36,8 @@ if (!glFiscalTypeId) { > } > > // Setup the divisions for which the report is executed > -List partyIds = > PartyWorker.getAssociatedPartyIdsByRelationshipType(delegator, > organizationPartyId, 'GROUP_ROLLUP'); > -partyIds.add(organizationPartyId); > +List partyIds = > PartyWorker.getAssociatedPartyIdsByRelationshipType(delegator, > parameters.get('ApplicationDecorator|organizationPartyId'), 'GROUP_ROLLUP'); > +partyIds.add(parameters.get('ApplicationDecorator|organizationPartyId')); > > // Get the group of account classes that will be used to position > accounts in the proper section of the financial statement > GenericValue revenueGlAccountClass = > from("GlAccountClass").where("glAccountClassId", > "REVENUE").cache(true).queryOne(); > > Modified: > ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/reports/TransactionTotals.groovy > URL: > http://svn.apache.org/viewvc/ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/reports/TransactionTotals.groovy?rev=1728584&r1=1728583&r2=1728584&view=diff > > ============================================================================== > --- > ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/reports/TransactionTotals.groovy > (original) > +++ > ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/reports/TransactionTotals.groovy > Fri Feb 5 01:45:50 2016 > @@ -41,7 +41,7 @@ if (!glFiscalTypeId) { > } > > // Find the last closed time period to get the fromDate for the > transactions in the current period and the ending balances of the last > closed period > -Map lastClosedTimePeriodResult = runService('findLastClosedDate', > ["organizationPartyId": organizationPartyId, "findDate": new > Date(fromDate.getTime()),"userLogin": userLogin]); > +Map lastClosedTimePeriodResult = runService('findLastClosedDate', > ["organizationPartyId": > parameters.get('ApplicationDecorator|organizationPartyId'), "findDate": new > Date(fromDate.getTime()),"userLogin": userLogin]); > Timestamp lastClosedDate = > (Timestamp)lastClosedTimePeriodResult.lastClosedDate; > GenericValue lastClosedTimePeriod = null; > if (lastClosedDate) { > @@ -71,7 +71,7 @@ if (postedTransactionTotals) { > // Get the opening balances at the end of the last closed > time period > if (UtilAccounting.isAssetAccount(glAccount) || > UtilAccounting.isLiabilityAccount(glAccount) || > UtilAccounting.isEquityAccount(glAccount)) { > if (lastClosedTimePeriod) { > - lastTimePeriodHistory = > from("GlAccountAndHistory").where("organizationPartyId", > organizationPartyId, "glAccountId", postedTransactionTotal.glAccountId, > "customTimePeriodId", lastClosedTimePeriod.customTimePeriodId).queryFirst(); > + lastTimePeriodHistory = > from("GlAccountAndHistory").where("organizationPartyId", > parameters.get('ApplicationDecorator|organizationPartyId'), "glAccountId", > postedTransactionTotal.glAccountId, "customTimePeriodId", > lastClosedTimePeriod.customTimePeriodId).queryFirst(); > if (lastTimePeriodHistory) { > accountMap = UtilMisc.toMap("glAccountId", > lastTimePeriodHistory.glAccountId, "accountCode", > lastTimePeriodHistory.accountCode, "accountName", > lastTimePeriodHistory.accountName, "balance", > lastTimePeriodHistory.getBigDecimal("endingBalance"), "openingD", > lastTimePeriodHistory.getBigDecimal("postedDebits"), "openingC", > lastTimePeriodHistory.getBigDecimal("postedCredits"), "D", BigDecimal.ZERO, > "C", BigDecimal.ZERO); > } > @@ -162,7 +162,7 @@ if (unpostedTransactionTotals) { > // Get the opening balances at the end of the last closed > time period > if (UtilAccounting.isAssetAccount(glAccount) || > UtilAccounting.isLiabilityAccount(glAccount) || > UtilAccounting.isEquityAccount(glAccount)) { > if (lastClosedTimePeriod) { > - lastTimePeriodHistory = > from("GlAccountAndHistory").where("organizationPartyId", > organizationPartyId, "glAccountId", unpostedTransactionTotal.glAccountId, > "customTimePeriodId", lastClosedTimePeriod.customTimePeriodId).queryFirst(); > + lastTimePeriodHistory = > from("GlAccountAndHistory").where("organizationPartyId", > parameters.get('ApplicationDecorator|organizationPartyId'), "glAccountId", > unpostedTransactionTotal.glAccountId, "customTimePeriodId", > lastClosedTimePeriod.customTimePeriodId).queryFirst(); > if (lastTimePeriodHistory) { > accountMap = UtilMisc.toMap("glAccountId", > lastTimePeriodHistory.glAccountId, "accountCode", > lastTimePeriodHistory.accountCode, "accountName", > lastTimePeriodHistory.accountName, "balance", > lastTimePeriodHistory.getBigDecimal("endingBalance"), "openingD", > lastTimePeriodHistory.getBigDecimal("postedDebits"), "openingC", > lastTimePeriodHistory.getBigDecimal("postedCredits"), "D", BigDecimal.ZERO, > "C", BigDecimal.ZERO); > } > @@ -254,7 +254,7 @@ if (allTransactionTotals) { > if (UtilAccounting.isAssetAccount(glAccount) || > UtilAccounting.isLiabilityAccount(glAccount) || > UtilAccounting.isEquityAccount(glAccount)) { > if (lastClosedTimePeriod) { > List timePeriodAndExprs = []; > - > timePeriodAndExprs.add(EntityCondition.makeCondition("organizationPartyId", > EntityOperator.EQUALS, organizationPartyId)); > + > timePeriodAndExprs.add(EntityCondition.makeCondition("organizationPartyId", > EntityOperator.EQUALS, > parameters.get('ApplicationDecorator|organizationPartyId'))); > > timePeriodAndExprs.add(EntityCondition.makeCondition("glAccountId", > EntityOperator.EQUALS, allTransactionTotal.glAccountId)); > > timePeriodAndExprs.add(EntityCondition.makeCondition("customTimePeriodId", > EntityOperator.EQUALS, lastClosedTimePeriod.customTimePeriodId)); > lastTimePeriodHistory = > from("GlAccountAndHistory").where(timePeriodAndExprs).queryFirst(); > > Modified: > ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/controller.xml > URL: > http://svn.apache.org/viewvc/ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/controller.xml?rev=1728584&r1=1728583&r2=1728584&view=diff > > ============================================================================== > --- > ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/controller.xml > (original) > +++ > ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/controller.xml > Fri Feb 5 01:45:50 2016 > @@ -629,6 +629,7 @@ under the License. > <!-- Party Accounts requests --> > <request-map uri="PartyAccountsSummary"> > <security https="true" auth="true"/> > + <event type="service" invoke="setAcctgCompany"/> > <response name="success" type="view" > value="PartyAccountsSummary"/> > </request-map> > <request-map uri="quickCreateAcctgTransAndEntries"> > @@ -777,6 +778,7 @@ under the License. > <!-- Import export --> > <request-map uri="ImportExport"> > <security https="true" auth="true"/> > + <event type="service" invoke="setAcctgCompany"/> > <response name="success" type="view" value="ImportExport"/> > </request-map> > <request-map uri="ExportInvoiceCsv.csv"> > @@ -1598,6 +1600,7 @@ under the License. > </request-map> > <request-map uri="AdminMain"> > <security https="true" auth="true"/> > + <event type="service" invoke="setAcctgCompany"/> > <response name="success" type="view" > value="PartyAcctgPreference"/> > </request-map> > <request-map uri="TimePeriods"> > @@ -1618,6 +1621,7 @@ under the License. > </request-map> > <request-map uri="PartyAcctgPreference"> > <security https="true" auth="true"/> > + <event type="service" invoke="setAcctgCompany"/> > <response name="success" type="view" > value="PartyAcctgPreference"/> > </request-map> > <request-map uri="createPartyAcctgPreference"> > > Modified: > ofbiz/trunk/applications/accounting/webapp/accounting/reports/GlAccountTrialBalanceReport.ftl > URL: > http://svn.apache.org/viewvc/ofbiz/trunk/applications/accounting/webapp/accounting/reports/GlAccountTrialBalanceReport.ftl?rev=1728584&r1=1728583&r2=1728584&view=diff > > ============================================================================== > --- > ofbiz/trunk/applications/accounting/webapp/accounting/reports/GlAccountTrialBalanceReport.ftl > (original) > +++ > ofbiz/trunk/applications/accounting/webapp/accounting/reports/GlAccountTrialBalanceReport.ftl > Fri Feb 5 01:45:50 2016 > @@ -21,7 +21,7 @@ under the License. > <div> > <form name="glAccountTrialBalanceReport" > id="glAccountTrialBalanceReport"> > <div> > - <a > href="<@ofbizUrl>GlAccountTrialBalanceReportPdf.pdf?organizationPartyId=${organizationPartyId}&timePeriod=${parameters.timePeriod}&isPosted=${parameters.isPosted}&glAccountId=${parameters.glAccountId}</@ofbizUrl>" > target="_BLANK" class="buttontext">${uiLabelMap.AccountingInvoicePDF}</a> > + <a > href="<@ofbizUrl>GlAccountTrialBalanceReportPdf.pdf?timePeriod=${parameters.timePeriod}&isPosted=${parameters.isPosted}&glAccountId=${parameters.glAccountId}</@ofbizUrl>" > target="_BLANK" class="buttontext">${uiLabelMap.AccountingInvoicePDF}</a> > </div> > <h3>${uiLabelMap.AccountingSubsidiaryLedger}</h3> > <h3>${uiLabelMap.FormFieldTitle_companyName} : > ${(currentOrganization.groupName)!}</h3> > > Modified: ofbiz/trunk/applications/accounting/widget/CommonScreens.xml > URL: > http://svn.apache.org/viewvc/ofbiz/trunk/applications/accounting/widget/CommonScreens.xml?rev=1728584&r1=1728583&r2=1728584&view=diff > > ============================================================================== > --- ofbiz/trunk/applications/accounting/widget/CommonScreens.xml (original) > +++ ofbiz/trunk/applications/accounting/widget/CommonScreens.xml Fri Feb > 5 01:45:50 2016 > @@ -196,7 +196,6 @@ under the License. > <section> > <actions> > <set field="headerItem" value="companies"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId" global="true"/> > </actions> > <widgets> > <decorator-screen name="main-decorator" > location="${parameters.mainDecoratorLocation}"> > @@ -230,7 +229,7 @@ under the License. > <actions> > <set field="tabButtonItemTop" value="PartyAccounts"/> > <entity-one entity-name="PartyNameView" > value-field="currentOrganization" auto-field-map="false"> > - <field-map field-name="partyId" > from-field="organizationPartyId"/> > + <field-map field-name="partyId" > value="${groovy:parameters.get('ApplicationDecorator|organizationPartyId')}"/> > </entity-one> > </actions> > <widgets> > @@ -251,7 +250,7 @@ under the License. > <actions> > <set field="tabButtonItemTop" value="PartyAccounts"/> > <entity-one entity-name="PartyNameView" > value-field="currentOrganization" auto-field-map="false"> > - <field-map field-name="partyId" > from-field="organizationPartyId"/> > + <field-map field-name="partyId" > value="${groovy:parameters.get('ApplicationDecorator|organizationPartyId')}"/> > </entity-one> > </actions> > <widgets> > > Modified: ofbiz/trunk/applications/accounting/widget/GlScreens.xml > URL: > http://svn.apache.org/viewvc/ofbiz/trunk/applications/accounting/widget/GlScreens.xml?rev=1728584&r1=1728583&r2=1728584&view=diff > > ============================================================================== > --- ofbiz/trunk/applications/accounting/widget/GlScreens.xml (original) > +++ ofbiz/trunk/applications/accounting/widget/GlScreens.xml Fri Feb 5 > 01:45:50 2016 > @@ -26,7 +26,7 @@ under the License. > <actions> > <set field="tabButtonItemTop" value="PartyAccounts"/> > <entity-one entity-name="PartyNameView" > value-field="currentOrganization" auto-field-map="false"> > - <field-map field-name="partyId" > from-field="organizationPartyId"/> > + <field-map field-name="partyId" > value="${groovy:parameters.get('ApplicationDecorator|organizationPartyId')}"/> > </entity-one> > </actions> > <widgets> > @@ -47,7 +47,6 @@ under the License. > <set field="titleProperty" > value="AccountingPartyAccountsSummary"/> > <set field="tabButtonItem" value="PartyAccountsSummary"/> > <set field="labelTitleProperty" > value="AccountingPartyAccountsSummary"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId" global="true"/> > <!-- entity-condition entity-name="GlAccountOrganization" > list="entityList" use-cache="true" > > <condition-expr field-name="glAccountId" > operator="greater" value="0"/> > </entity-condition --> > @@ -74,7 +73,6 @@ under the License. > <set field="titleProperty" value="AccountingAcctgTrans"/> > <set field="tabButtonItem" value="FindAcctgTrans"/> > <set field="labelTitleProperty" > value="AccountingAcctgTrans"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId" global="true"/> > </actions> > <widgets> > <decorator-screen name="CommonPartyGlDecorator" > location="${parameters.partyGlDecoratorLocation}"> > @@ -144,7 +142,6 @@ under the License. > <set field="titleProperty" > value="AccountingAcctgTransEntries"/> > <set field="tabButtonItem" value="FindAcctgTransEntries"/> > <set field="labelTitleProperty" > value="AccountingAcctgTransEntries"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId" global="true"/> > </actions> > <widgets> > <decorator-screen name="CommonPartyGlDecorator" > location="${parameters.partyGlDecoratorLocation}"> > @@ -274,7 +271,6 @@ under the License. > <actions> > <set field="titleProperty" > value="AccountingCreateAcctgTransAndEntries"/> > <set field="tabButtonItem" value="FindAcctgTrans"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId" global="true"/> > <set field="labelTitleProperty" > value="AccountingCreateAcctgTransAndEntries"/> > </actions> > <widgets> > @@ -295,7 +291,6 @@ under the License. > <property-map resource="AccountingUiLabels" > map-name="uiLabelMap" global="true"/> > <set field="titleProperty" > value="PageTitleEditTransaction"/> > <set field="tabButtonItem" value="FindAcctgTrans"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId" global="true"/> > <set field="acctgTransId" > from-field="parameters.acctgTransId"/> > > <entity-one entity-name="AcctgTrans" > value-field="acctgTrans"/> > @@ -355,9 +350,7 @@ under the License. > <property-map resource="AccountingUiLabels" > map-name="uiLabelMap" global="true"/> > <set field="titleProperty" > value="PageTitleUnpostedTransactions"/> > <set field="tabButtonItem" value="FindAcctgTrans"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId" global="true"/> > <set field="labelTitleProperty" > value="${uiLabelMap.PageTitleUnpostedTransactions}"/> > - <set field="partyId" > from-field="parameters.organizationPartyId"/> > <entity-condition entity-name="AcctgTrans" > list="transactions"> > <condition-expr field-name="isPosted" > operator="not-equals" value="Y"/> > <order-by field-name="transactionDate"/> > @@ -383,12 +376,11 @@ under the License. > <set field="tabButtonItem" value="ChecksTabButton"/> > <set field="tabButtonItem2" value="PrintChecksTabButton"/> > <set field="labelTitleProperty" > value="${uiLabelMap.AccountingPrintChecks}"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId"/> > > <!-- find payments of paymentMethodType PERSONAL_CHECK or > COMPANY_CHECK with statusId NOT_PAID --> > <entity-condition entity-name="Payment" list="payments"> > <condition-list combine="and"> > - <condition-expr field-name="partyIdFrom" > operator="equals" from-field="organizationPartyId"/> > + <condition-expr field-name="partyIdFrom" > operator="equals" > value="${groovy:parameters.get('ApplicationDecorator|organizationPartyId')}"/> > <condition-expr field-name="statusId" > operator="equals" value="PMNT_NOT_PAID"/> > <condition-list combine="or"> > <condition-expr > field-name="paymentMethodTypeId" operator="equals" value="PERSONAL_CHECK"/> > @@ -425,12 +417,11 @@ under the License. > <set field="titleProperty" value="AccountingSendChecks"/> > <set field="tabButtonItem" value="ChecksTabButton"/> > <set field="tabButtonItem2" value="SendChecksTabButton"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId"/> > > <!-- find payments of paymentMethodType PERSONAL_CHECK or > COMPANY_CHECK with statusId NOT_PAID --> > <entity-condition entity-name="Payment" list="payments"> > <condition-list combine="and"> > - <condition-expr field-name="partyIdFrom" > operator="equals" from-field="organizationPartyId"/> > + <condition-expr field-name="partyIdFrom" > operator="equals" > value="${groovy:parameters.get('ApplicationDecorator|organizationPartyId')}"/> > <condition-expr field-name="statusId" > operator="equals" value="PMNT_NOT_PAID"/> > <condition-list combine="or"> > <condition-expr > field-name="paymentMethodTypeId" operator="equals" value="PERSONAL_CHECK"/> > @@ -470,7 +461,6 @@ under the License. > <actions> > <set field="titleProperty" > value="AccountingCreateAnAccountingTransaction"/> > <set field="tabButtonItem" value="FindAcctgTrans"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId" global="true"/> > <set field="labelTitleProperty" > value="AccountingCreateAnAccountingTransaction"/> > </actions> > <widgets> > @@ -491,7 +481,6 @@ under the License. > <set field="titleProperty" value="AccountingAcctRecon"/> > <set field="tabButtonItem" value="AccountReconciliation"/> > <set field="labelTitleProperty" > value="AccountingAcctRecon"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId" global="true"/> > <set field="glAccountId" > from-field="parameters.glAccountId"/> > </actions> > <widgets> > @@ -520,7 +509,6 @@ under the License. > <actions> > <set field="titleProperty" > value="AccountingEditAcctRecon"/> > <set field="tabButtonItem" > from-field="parameters.tabButtonItem" global="true"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId" global="true"/> > <set field="glReconciliationId" > from-field="parameters.glReconciliationId" global="true"/> > <entity-one entity-name="GlReconciliation" > value-field="glReconciliation"/> > </actions> > @@ -544,7 +532,6 @@ under the License. > <set field="titleProperty" value="AccountingAcctRecons"/> > <set field="tabButtonItem" > value="AccountReconciliations"/> > <set field="labelTitleProperty" > value="AccountingAcctRecons"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId" global="true"/> > <set field="glAccountId" > from-field="parameters.glAccountId"/> > </actions> > <widgets> > @@ -573,7 +560,6 @@ under the License. > <section> > <actions> > <property-map resource="AccountingUiLabels" > map-name="uiLabelMap" global="true"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId"/> > </actions> > <widgets> > <container> > @@ -587,7 +573,6 @@ under the License. > <section> > <actions> > <property-map resource="AccountingUiLabels" > map-name="uiLabelMap" global="true"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId"/> > </actions> > <widgets> > <container> > @@ -603,10 +588,9 @@ under the License. > <property-map resource="CommonUiLabels" > map-name="uiLabelMap" global="true"/> > <property-map resource="AccountingUiLabels" > map-name="uiLabelMap" global="true"/> > <property-map resource="WorkEffortUiLabels" > map-name="uiLabelMap" global="true"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId" global="true"/> > <entity-condition entity-name="AcctgTransAndEntries" > list="acctgTransEntryList"> > <condition-list> > - <condition-expr field-name="organizationPartyId" > operator="equals" from-field="parameters.organizationPartyId"/> > + <condition-expr field-name="organizationPartyId" > operator="equals" > value="${groovy:parameters.get('ApplicationDecorator|organizationPartyId')}"/> > <condition-expr field-name="glAccountId" > operator="equals" from-field="parameters.glAccountId" > ignore-if-empty="true"/> > <condition-expr field-name="acctgTransTypeId" > operator="equals" from-field="parameters.acctgTransTypeId" > ignore-if-empty="true"/> > <condition-expr field-name="glFiscalTypeId" > operator="equals" from-field="parameters.glFiscalTypeId" > ignore-if-empty="true"/> > @@ -640,10 +624,9 @@ under the License. > <property-map resource="CommonUiLabels" > map-name="uiLabelMap" global="true"/> > <property-map resource="AccountingUiLabels" > map-name="uiLabelMap" global="true"/> > <property-map resource="WorkEffortUiLabels" > map-name="uiLabelMap" global="true"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId" global="true"/> > <entity-condition entity-name="AcctgTransAndEntries" > list="acctgTransList" distinct="true" > > <condition-list> > - <condition-expr field-name="organizationPartyId" > operator="equals" from-field="organizationPartyId"/> > + <condition-expr field-name="organizationPartyId" > operator="equals" > value="${groovy:parameters.get('ApplicationDecorator|organizationPartyId')}"/> > <condition-expr field-name="acctgTransTypeId" > operator="equals" from-field="parameters.acctgTransTypeId" > ignore-if-empty="true"/> > <condition-expr field-name="glFiscalTypeId" > operator="equals" from-field="parameters.glFiscalTypeId" > ignore-if-empty="true"/> > <condition-expr field-name="glJournalId" > operator="equals" from-field="parameters.glJournalId" > ignore-if-empty="true"/> > > Modified: ofbiz/trunk/applications/accounting/widget/GlSetupForms.xml > URL: > http://svn.apache.org/viewvc/ofbiz/trunk/applications/accounting/widget/GlSetupForms.xml?rev=1728584&r1=1728583&r2=1728584&view=diff > > ============================================================================== > --- ofbiz/trunk/applications/accounting/widget/GlSetupForms.xml (original) > +++ ofbiz/trunk/applications/accounting/widget/GlSetupForms.xml Fri Feb 5 > 01:45:50 2016 > @@ -156,7 +156,7 @@ under the License. > </actions> > <alt-target use-when="partyAcctgPreference!=null" > target="updatePartyAcctgPreference"/> > <auto-fields-service service-name="createPartyAcctgPreference"/> > - <field name="organizationPartyId"><hidden > value="${parameters.organizationPartyId}"/></field> > + <field name="organizationPartyId"><hidden > value="${organizationPartyId}"/></field> > <!-- the partyId is always displayed --> > <field name="partyId" > title="${uiLabelMap.AccountingOrganizationPartyId}"><display/></field> > <!-- if there is no partyAcctgPreference yet, then we show > drop-downs for the fields and a submit button --> > @@ -1092,7 +1092,7 @@ under the License. > odd-row-style="alternate-row" header-row-style="header-row-2" > default-table-style="basic-table hover-bar" paginate="false"> > <actions> > <entity-condition entity-name="GlAccountOrganizationAndClass"> > - <condition-expr field-name="organizationPartyId" > from-field="organizationPartyId"/> > + <condition-expr field-name="organizationPartyId" > value="${groovy:parameters.get('ApplicationDecorator|organizationPartyId')}"/> > <order-by field-name="glAccountId"/> > </entity-condition> > </actions> > > Modified: ofbiz/trunk/applications/accounting/widget/GlSetupScreens.xml > URL: > http://svn.apache.org/viewvc/ofbiz/trunk/applications/accounting/widget/GlSetupScreens.xml?rev=1728584&r1=1728583&r2=1728584&view=diff > > ============================================================================== > --- ofbiz/trunk/applications/accounting/widget/GlSetupScreens.xml > (original) > +++ ofbiz/trunk/applications/accounting/widget/GlSetupScreens.xml Fri Feb > 5 01:45:50 2016 > @@ -26,7 +26,7 @@ under the License. > <actions> > <set field="tabButtonItemTop" value="Admin"/> > <entity-one entity-name="PartyNameView" > value-field="currentOrganization" auto-field-map="false"> > - <field-map field-name="partyId" > from-field="organizationPartyId"/> > + <field-map field-name="partyId" > value="${groovy:if(parameters.organizationPartyId!=null) return > parameters.organizationPartyId else return > parameters.get('ApplicationDecorator|organizationPartyId')}"/> > </entity-one> > </actions> > <widgets> > @@ -97,13 +97,13 @@ under the License. > <actions> > <set field="titleProperty" value="CommonImportExport"/> > <entity-one entity-name="PartyGroup" > value-field="partyGroup"> > - <field-map field-name="partyId" > from-field="parameters.organizationPartyId"/> > + <field-map field-name="partyId" > value="${groovy:parameters.get('ApplicationDecorator|organizationPartyId')}"/> > </entity-one> > </actions> > <widgets> > <decorator-screen name="main-decorator" > location="${parameters.mainDecoratorLocation}"> > <decorator-section name="body"> > - <screenlet title="${uiLabelMap.AccountingInvoice} > ${uiLabelMap.CommonImportExport} ${uiLabelMap.CommonFor}: > ${partyGroup.groupName} [${parameters.organizationPartyId}]"> > + <screenlet title="${uiLabelMap.AccountingInvoice} > ${uiLabelMap.CommonImportExport} ${uiLabelMap.CommonFor}: > ${partyGroup.groupName} [${organizationPartyId}]"> > <container style="lefthalf"> > <label > style="h2">${uiLabelMap.CommonImport}</label> > <include-form name="ImportInvoice" > location="component://accounting/widget/GlSetupForms.xml"/> > @@ -126,7 +126,7 @@ under the License. > <set field="organizationPartyId" > from-field="parameters.organizationPartyId"/> > </actions> > <widgets> > - <include-form name="ExportInvoiceCsv" > location="component://accounting/widget/GlSetupForms.xml"/> > + <include-form name="ExportInvoiceCsv" > location="component://accounting/widget/GlSetupForms.xml"/> > </widgets> > </section> > </screen> > @@ -163,17 +163,16 @@ under the License. > <set field="titleProperty" value="AccountingTimePeriod"/> > <set field="labelTitleProperty" > value="${uiLabelMap.AccountingTimePeriod}"/> > <set field="tabButtonItem" value="TimePeriods"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId"/> > <entity-condition entity-name="CustomTimePeriod" > list="openTimePeriods"> > <condition-list> > - <condition-expr field-name="organizationPartyId" > operator="equals" from-field="organizationPartyId"/> > + <condition-expr field-name="organizationPartyId" > operator="equals" > value="${groovy:parameters.get('ApplicationDecorator|organizationPartyId')}"/> > <condition-expr field-name="isClosed" > operator="equals" value="N"/> > </condition-list> > <order-by field-name="thruDate"/> > </entity-condition> > <entity-condition entity-name="CustomTimePeriod" > list="closedTimePeriods"> > <condition-list> > - <condition-expr field-name="organizationPartyId" > operator="equals" from-field="organizationPartyId"/> > + <condition-expr field-name="organizationPartyId" > operator="equals" > value="${groovy:parameters.get('ApplicationDecorator|organizationPartyId')}"/> > <condition-expr field-name="isClosed" > operator="equals" value="Y"/> > </condition-list> > <order-by field-name="periodTypeId"/> > @@ -205,9 +204,8 @@ under the License. > <set field="titleProperty" value="AccountingPreference"/> > <set field="labelTitleProperty" > value="${uiLabelMap.AccountingPreference}"/> > <set field="tabButtonItem" value="PartyAcctgPreference"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId"/> > <property-to-field field="defaultCurrencyUomId" > resource="general" property="currency.uom.id.default" default="USD"/> > - <set field="partyId" > from-field="parameters.organizationPartyId"/> > + <set field="partyId" > value="${groovy:if(parameters.organizationPartyId!=null) return > parameters.organizationPartyId else return > parameters.get('ApplicationDecorator|organizationPartyId')}"/> > <entity-one entity-name="PartyAcctgPreference" > value-field="partyAcctgPreference"/> > </actions> > <widgets> > @@ -228,7 +226,6 @@ under the License. > <set field="titleProperty" value="AccountingGlJournals"/> > <set field="labelTitleProperty" > value="${uiLabelMap.AccountingGlJournals}"/> > <set field="tabButtonItem" value="SetupGlJournals"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId"/> > <entity-one entity-name="GlJournal" > value-field="glJournal"/> > </actions> > <widgets> > @@ -251,7 +248,6 @@ under the License. > <set field="labelTitleProperty" > value="${uiLabelMap.AccountingGlAccountTypeDefaults}"/> > <set field="tabButtonItem" value="GlAccountAssignment"/> > <set field="tabButtonItem2" > value="GlAccountTypeDefaults"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId"/> > </actions> > <widgets> > <decorator-screen name="CommonGlSetupDecorator" > location="${parameters.commonGlSetupDecoratorLocation}"> > @@ -273,7 +269,6 @@ under the License. > <set field="labelTitleProperty" > value="${uiLabelMap.AccountingInvoiceSales}"/> > <set field="tabButtonItem" value="GlAccountAssignment"/> > <set field="tabButtonItem2" value="GlAccountSalInvoice"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId"/> > </actions> > <widgets> > <decorator-screen name="CommonGlSetupDecorator" > location="${parameters.commonGlSetupDecoratorLocation}"> > @@ -294,7 +289,6 @@ under the License. > <set field="titleProperty" > value="AccountingInvoicePurchase"/> > <set field="tabButtonItem" value="GlAccountAssignment"/> > <set field="tabButtonItem2" value="GlAccountPurInvoice"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId"/> > </actions> > <widgets> > <decorator-screen name="CommonGlSetupDecorator" > location="${parameters.commonGlSetupDecoratorLocation}"> > @@ -315,7 +309,6 @@ under the License. > <set field="titleProperty" > value="${uiLabelMap.AccountingPaymentType}/${uiLabelMap.FormFieldTitle_glAccountTypeId}"/> > <set field="tabButtonItem" value="GlAccountAssignment"/> > <set field="tabButtonItem2" > value="GlAccountTypePaymentType"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId"/> > </actions> > <widgets> > <decorator-screen name="CommonGlSetupDecorator" > location="${parameters.commonGlSetupDecoratorLocation}"> > @@ -336,7 +329,6 @@ under the License. > <set field="titleProperty" > value="${uiLabelMap.AccountingPaymentMethodId}/${uiLabelMap.AccountingGlAccountId}"/> > <set field="tabButtonItem" value="GlAccountAssignment"/> > <set field="tabButtonItem2" > value="GlAccountNrPaymentMethod"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId"/> > </actions> > <widgets> > <decorator-screen name="CommonGlSetupDecorator" > location="${parameters.commonGlSetupDecoratorLocation}"> > @@ -358,10 +350,9 @@ under the License. > <set field="labelTitleProperty" > value="${uiLabelMap.AccountingProductGlAccount}"/> > <set field="tabButtonItem" value="GlAccountAssignment"/> > <set field="tabButtonItem2" value="ProductGlAccounts"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId"/> > > <entity-condition entity-name="ProductGlAccount" > list="productGlAccounts"> > - <condition-expr field-name="organizationPartyId" > from-field="organizationPartyId"/> > + <condition-expr field-name="organizationPartyId" > value="${groovy:parameters.get('ApplicationDecorator|organizationPartyId')}"/> > <order-by field-name="glAccountTypeId"/> > </entity-condition> > </actions> > @@ -385,10 +376,9 @@ under the License. > <set field="labelTitleProperty" > value="${uiLabelMap.AccountingFinAccountTypeGlAccount}"/> > <set field="tabButtonItem" value="GlAccountAssignment"/> > <set field="tabButtonItem2" > value="FinAccountTypeGlAccounts"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId"/> > > <entity-condition entity-name="FinAccountTypeGlAccount" > list="finAccountTypeGlAccounts"> > - <condition-expr field-name="organizationPartyId" > operator="equals" from-field="organizationPartyId"/> > + <condition-expr field-name="organizationPartyId" > operator="equals" > value="${groovy:parameters.get('ApplicationDecorator|organizationPartyId')}"/> > <order-by field-name="finAccountTypeId"/> > </entity-condition> > <entity-condition entity-name="FinAccountType" > list="finAccountTypes" use-cache="true"> > @@ -416,10 +406,9 @@ under the License. > <set field="labelTitleProperty" > value="${uiLabelMap.AccountingProductCategoryGlAccount}"/> > <set field="tabButtonItem" value="GlAccountAssignment"/> > <set field="tabButtonItem2" > value="ProductCategoryGlAccounts"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId"/> > > <entity-condition entity-name="ProductCategoryGlAccount" > list="productCategoryGlAccounts"> > - <condition-expr field-name="organizationPartyId" > from-field="organizationPartyId"/> > + <condition-expr field-name="organizationPartyId" > value="${groovy:parameters.get('ApplicationDecorator|organizationPartyId')}"/> > <order-by field-name="glAccountTypeId"/> > </entity-condition> > </actions> > @@ -443,10 +432,9 @@ under the License. > <set field="tabButtonItem" value="GlAccountAssignment"/> > <set field="tabButtonItem2" > value="VarianceReasonGlAccounts"/> > <set field="labelTitleProperty" > value="${uiLabelMap.AccountingVarianceReasonGlAccounts}"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId"/> > > <entity-condition entity-name="VarianceReasonGlAccount" > list="varianceReasonGlAccounts"> > - <condition-expr field-name="organizationPartyId" > from-field="organizationPartyId"/> > + <condition-expr field-name="organizationPartyId" > value="${groovy:parameters.get('ApplicationDecorator|organizationPartyId')}"/> > <order-by field-name="glAccountId"/> > </entity-condition> > </actions> > @@ -470,9 +458,8 @@ under the License. > <set field="tabButtonItem" value="GlAccountAssignment"/> > <set field="tabButtonItem2" > value="CreditCardTypeGlAccount"/> > <set field="labelTitleProperty" > value="${uiLabelMap.AccountingCreditCardTypeGlAccount}"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId"/> > <entity-condition entity-name="CreditCardTypeGlAccount" > list="creditCardTypeGlAccounts"> > - <condition-expr field-name="organizationPartyId" > from-field="organizationPartyId"/> > + <condition-expr field-name="organizationPartyId" > value="${groovy:parameters.get('ApplicationDecorator|organizationPartyId')}"/> > </entity-condition> > </actions> > <widgets> > @@ -495,9 +482,8 @@ under the License. > <set field="tabButtonItem" value="GlAccountAssignment"/> > <set field="tabButtonItem2" > value="TaxAuthorityGlAccounts"/> > <set field="labelTitleProperty" > value="${uiLabelMap.PageTitleEditTaxAuthorityGlAccounts}"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId"/> > <entity-condition entity-name="TaxAuthorityGlAccount" > list="taxAuthorityGlAccounts"> > - <condition-expr field-name="organizationPartyId" > from-field="organizationPartyId"/> > + <condition-expr field-name="organizationPartyId" > value="${groovy:parameters.get('ApplicationDecorator|organizationPartyId')}"/> > <order-by field-name="taxAuthGeoId"/> > <order-by field-name="taxAuthPartyId"/> > </entity-condition> > @@ -523,9 +509,8 @@ under the License. > <set field="labelTitleProperty" > value="${uiLabelMap.PageTitleEditPartyGlAccounts}"/> > <set field="tabButtonItem" value="GlAccountAssignment"/> > <set field="tabButtonItem2" value="PartyGlAccounts"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId"/> > <entity-condition entity-name="PartyGlAccount" > list="partyGlAccounts"> > - <condition-expr field-name="organizationPartyId" > from-field="organizationPartyId"/> > + <condition-expr field-name="organizationPartyId" > value="${groovy:parameters.get('ApplicationDecorator|organizationPartyId')}"/> > <order-by field-name="partyId"/> > </entity-condition> > </actions> > @@ -549,7 +534,6 @@ under the License. > <set field="labelTitleProperty" > value="${uiLabelMap.FixedAssetTypeGlAccounts}"/> > <set field="tabButtonItem" value="GlAccountAssignment"/> > <set field="tabButtonItem2" > value="FixedAssetTypeGlAccounts"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId"/> > </actions> > <widgets> > <decorator-screen name="CommonGlSetupDecorator" > location="${parameters.commonGlSetupDecoratorLocation}"> > @@ -568,9 +552,8 @@ under the License. > <actions> > <property-map resource="CommonUiLabels" > map-name="uiLabelMap" global="true"/> > <property-map resource="AccountingUiLabels" > map-name="uiLabelMap" global="true"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId"/> > <entity-condition > entity-name="GlAccountOrganizationAndClass" list="glAccountOrgAndClassList"> > - <condition-expr field-name="organizationPartyId" > from-field="organizationPartyId"/> > + <condition-expr field-name="organizationPartyId" > value="${groovy:parameters.get('ApplicationDecorator|organizationPartyId')}"/> > <order-by field-name="glAccountId"/> > </entity-condition> > </actions> > @@ -588,10 +571,9 @@ under the License. > <actions> > <property-map resource="CommonUiLabels" > map-name="uiLabelMap" global="true"/> > <property-map resource="AccountingUiLabels" > map-name="uiLabelMap" global="true"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId"/> > </actions> > <widgets> > - <include-form name="ListGlAccountOrgCsv" > location="component://accounting/widget/GlSetupForms.xml"/> > + <include-form name="ListGlAccountOrgCsv" > location="component://accounting/widget/GlSetupForms.xml"/> > </widgets> > </section> > </screen> > > Modified: > ofbiz/trunk/applications/accounting/widget/ReportFinancialSummaryForms.xml > URL: > http://svn.apache.org/viewvc/ofbiz/trunk/applications/accounting/widget/ReportFinancialSummaryForms.xml?rev=1728584&r1=1728583&r2=1728584&view=diff > > ============================================================================== > --- > ofbiz/trunk/applications/accounting/widget/ReportFinancialSummaryForms.xml > (original) > +++ > ofbiz/trunk/applications/accounting/widget/ReportFinancialSummaryForms.xml > Fri Feb 5 01:45:50 2016 > @@ -508,7 +508,7 @@ under the License. > <actions> > <entity-condition entity-name="InventoryItemDetailForSum" > list="inventoryValuationList" use-cache="false"> > <condition-list> > - <condition-expr field-name="ownerPartyId" > operator="equals" from-field="parameters.organizationPartyId"/> > + <condition-expr field-name="ownerPartyId" > operator="equals" > value="${groovy:parameters.get('ApplicationDecorator|organizationPartyId')}"/> > <condition-expr field-name="accountingQuantityDiff" > operator="not-equals" value="0.0"/> > <condition-expr field-name="effectiveDate" > operator="less-equals" from-field="parameters.thruDate"/> > <condition-expr field-name="facilityId" > operator="equals" from-field="parameters.facilityId" > ignore-if-empty="true"/> > > > |
Absolutely Jacopo,
I have asked the original creator to provide an additional patch today. Regards, Hans On 18/02/16 23:44, Jacopo Cappellato wrote: > Hi Hans, > > this commit has broken the accounting report (trial balance etc...); > see for example: > > https://demo-trunk-ofbiz.apache.org/accounting/control/IncomeStatement?organizationPartyId=Company > > Could you please look into it? > > Thank you > > Jacopo > > > On Fri, Feb 5, 2016 at 2:45 AM, <[hidden email] > <mailto:[hidden email]>> wrote: > > Author: hansbak > Date: Fri Feb 5 01:45:50 2016 > New Revision: 1728584 > > URL: http://svn.apache.org/viewvc?rev=1728584&view=rev > Log: > be able to set accounting company in the header, so other > companent can change it too. > https://issues.apache.org/jira/browse/OFBIZ-6802 > > Modified: > ofbiz/trunk/applications/accounting/script/org/ofbiz/accounting/admin/AcctgAdminServices.xml > ofbiz/trunk/applications/accounting/servicedef/secas.xml > ofbiz/trunk/applications/accounting/servicedef/services_admin.xml > ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/chartofaccounts/TaxAuthorityGlAccounts.groovy > ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/reports/BalanceSheet.groovy > ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/reports/CashFlowStatement.groovy > ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/reports/GlAccountTrialBalance.groovy > ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/reports/IncomeStatement.groovy > ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/reports/TransactionTotals.groovy > ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/controller.xml > ofbiz/trunk/applications/accounting/webapp/accounting/reports/GlAccountTrialBalanceReport.ftl > ofbiz/trunk/applications/accounting/widget/CommonScreens.xml > ofbiz/trunk/applications/accounting/widget/GlScreens.xml > ofbiz/trunk/applications/accounting/widget/GlSetupForms.xml > ofbiz/trunk/applications/accounting/widget/GlSetupScreens.xml > ofbiz/trunk/applications/accounting/widget/ReportFinancialSummaryForms.xml > ofbiz/trunk/applications/accounting/widget/ReportFinancialSummaryScreens.xml > ofbiz/trunk/applications/commonext/webapp/ofbizsetup/organization/changeOrgPartyId.groovy > ofbiz/trunk/applications/commonext/widget/CommonScreens.xml > ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/order/CompanyHeader.groovy > ofbiz/trunk/framework/common/config/CommonUiLabels.xml > ofbiz/trunk/framework/common/webcommon/WEB-INF/common-controller.xml > ofbiz/trunk/framework/common/webcommon/includes/listVisualThemes.ftl > ofbiz/trunk/framework/common/widget/CommonScreens.xml > ofbiz/trunk/framework/common/widget/LookupScreens.xml > ofbiz/trunk/themes/bizznesstime/includes/header.ftl > ofbiz/trunk/themes/bizznesstime/webapp/bizznesstime/js/application.js > ofbiz/trunk/themes/bluelight/includes/header.ftl > ofbiz/trunk/themes/droppingcrumbs/includes/header.ftl > ofbiz/trunk/themes/tomahawk/includes/appbarClose.ftl > > Modified: > ofbiz/trunk/applications/accounting/script/org/ofbiz/accounting/admin/AcctgAdminServices.xml > URL: > http://svn.apache.org/viewvc/ofbiz/trunk/applications/accounting/script/org/ofbiz/accounting/admin/AcctgAdminServices.xml?rev=1728584&r1=1728583&r2=1728584&view=diff > ============================================================================== > --- > ofbiz/trunk/applications/accounting/script/org/ofbiz/accounting/admin/AcctgAdminServices.xml > (original) > +++ > ofbiz/trunk/applications/accounting/script/org/ofbiz/accounting/admin/AcctgAdminServices.xml > Fri Feb 5 01:45:50 2016 > @@ -101,6 +101,20 @@ under the License. > </if-not-empty> > </simple-method> > > + <simple-method method-name="setAcctgCompany" > short-description="Set Accounting Company when select or create an > accounting company"> > + <!-- set user preference --> > + <entity-one entity-name="PartyAcctgPreference" > value-field="partyAcctgPreference"> > + <field-map field-name="partyId" > from-field="parameters.organizationPartyId"/> > + </entity-one> > + <if-not-empty field="partyAcctgPreference"> > + <set field="setUserPref.userPrefGroupTypeId" > value="GLOBAL_PREFERENCES"/> > + <set field="setUserPref.userPrefTypeId" > value="ORGANIZATION_PARTY"/> > + <set field="setUserPref.userPrefValue" > from-field="parameters.organizationPartyId"/> > + <call-service service-name="setUserPreference" > in-map-name="setUserPref"/> > + </if-not-empty> > + <field-to-result field="parameters.organizationPartyId" > result-name="organizationPartyId"/> > + </simple-method> > + > <!-- update currency conversion rates in the > UomConversionDated entity --> > <simple-method method-name="updateFXConversion" > short-description="Update Foreign Exchange conversion rate"> > <!-- set the FX rate changes as of now --> > > Modified: ofbiz/trunk/applications/accounting/servicedef/secas.xml > URL: > http://svn.apache.org/viewvc/ofbiz/trunk/applications/accounting/servicedef/secas.xml?rev=1728584&r1=1728583&r2=1728584&view=diff > ============================================================================== > --- ofbiz/trunk/applications/accounting/servicedef/secas.xml > (original) > +++ ofbiz/trunk/applications/accounting/servicedef/secas.xml Fri > Feb 5 01:45:50 2016 > @@ -158,4 +158,10 @@ under the License. > <condition field-name="productTypeId" operator="equals" > value="ASSET_USAGE"/> > <action service="createFixedAssetAndLinkToProduct" > mode="sync"/> > </eca> > + > + <!-- automatically set company to user when create an > accounting company --> > + <eca service="createPartyAcctgPreference" event="return"> > + <set field-name="organizationPartyId" env-name="partyId"/> > + <action service="setAcctgCompany" mode="sync"/> > + </eca> > </service-eca> > > Modified: > ofbiz/trunk/applications/accounting/servicedef/services_admin.xml > URL: > http://svn.apache.org/viewvc/ofbiz/trunk/applications/accounting/servicedef/services_admin.xml?rev=1728584&r1=1728583&r2=1728584&view=diff > ============================================================================== > --- > ofbiz/trunk/applications/accounting/servicedef/services_admin.xml > (original) > +++ > ofbiz/trunk/applications/accounting/servicedef/services_admin.xml > Fri Feb 5 01:45:50 2016 > @@ -65,6 +65,12 @@ under the License. > <attribute type="String" mode="IN" > name="organizationPartyId" optional="false"/> > <attribute name="partyAccountingPreference" > type="org.ofbiz.entity.GenericValue" mode="OUT" optional="true"/> > </service> > + <service name="setAcctgCompany" engine="simple" > + > location="component://accounting/script/org/ofbiz/accounting/admin/AcctgAdminServices.xml" > invoke="setAcctgCompany" auth="true"> > + <description>Set Accounting Company when select</description> > + <permission-service > service-name="acctgPrefPermissionCheck" main-action="CREATE"/> > + <attribute type="String" mode="INOUT" > name="organizationPartyId" optional="true"/> > + </service> > > <service name="updateFXConversion" engine="simple" > location="component://accounting/script/org/ofbiz/accounting/admin/AcctgAdminServices.xml" > invoke="updateFXConversion"> > > Modified: > ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/chartofaccounts/TaxAuthorityGlAccounts.groovy > URL: > http://svn.apache.org/viewvc/ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/chartofaccounts/TaxAuthorityGlAccounts.groovy?rev=1728584&r1=1728583&r2=1728584&view=diff > ============================================================================== > --- > ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/chartofaccounts/TaxAuthorityGlAccounts.groovy > (original) > +++ > ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/chartofaccounts/TaxAuthorityGlAccounts.groovy > Fri Feb 5 01:45:50 2016 > @@ -22,5 +22,5 @@ import org.ofbiz.base.util.UtilMisc; > taxAuthorities = from('TaxAuthority').orderBy("taxAuthGeoId", > "taxAuthPartyId").queryList(); > > context.taxAuthorityHavingNoGlAccountList = > taxAuthorities.findAll { taxAuthority -> > - !taxAuthority.getRelated('TaxAuthorityGlAccount', > [organizationPartyId : organizationPartyId], null, false) > + !taxAuthority.getRelated('TaxAuthorityGlAccount', > [organizationPartyId : > parameters.get('ApplicationDecorator|organizationPartyId')], null, > false) > } > > Modified: > ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/reports/BalanceSheet.groovy > URL: > http://svn.apache.org/viewvc/ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/reports/BalanceSheet.groovy?rev=1728584&r1=1728583&r2=1728584&view=diff > ============================================================================== > --- > ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/reports/BalanceSheet.groovy > (original) > +++ > ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/reports/BalanceSheet.groovy > Fri Feb 5 01:45:50 2016 > @@ -39,8 +39,8 @@ if (!glFiscalTypeId) { > } > > // Setup the divisions for which the report is executed > -List partyIds = > PartyWorker.getAssociatedPartyIdsByRelationshipType(delegator, > organizationPartyId, 'GROUP_ROLLUP'); > -partyIds.add(organizationPartyId); > +List partyIds = > PartyWorker.getAssociatedPartyIdsByRelationshipType(delegator, > parameters.get('ApplicationDecorator|organizationPartyId'), > 'GROUP_ROLLUP'); > +partyIds.add(parameters.get('ApplicationDecorator|organizationPartyId')); > > // Get the group of account classes that will be used to position > accounts in the proper section of the financial statement > GenericValue assetGlAccountClass = > from("GlAccountClass").where("glAccountClassId", > "ASSET").cache(true).queryOne(); > @@ -63,7 +63,7 @@ GenericValue accumAmortizationGlAccountC > List accumAmortizationAccountClassIds = > UtilAccounting.getDescendantGlAccountClassIds(accumAmortizationGlAccountClass); > > // Find the last closed time period to get the fromDate for the > transactions in the current period and the ending balances of the > last closed period > -Map lastClosedTimePeriodResult = runService('findLastClosedDate', > ["organizationPartyId": organizationPartyId, "findDate": new > Date(thruDate.getTime()),"userLogin": userLogin]); > +Map lastClosedTimePeriodResult = runService('findLastClosedDate', > ["organizationPartyId": > parameters.get('ApplicationDecorator|organizationPartyId'), > "findDate": new Date(thruDate.getTime()),"userLogin": userLogin]); > Timestamp fromDate = > (Timestamp)lastClosedTimePeriodResult.lastClosedDate; > if (!fromDate) { > return; > @@ -407,9 +407,9 @@ transactionTotals.each { transactionTota > transactionTotalsMap.put(transactionTotal.glAccountId, > accountMap); > } > // Add the "retained earnings" account > -Map netIncomeResult = runService('prepareIncomeStatement', > ["organizationPartyId": organizationPartyId, "glFiscalTypeId": > glFiscalTypeId, "fromDate": fromDate, "thruDate": thruDate, > "userLogin": userLogin]); > +Map netIncomeResult = runService('prepareIncomeStatement', > ["organizationPartyId": > parameters.get('ApplicationDecorator|organizationPartyId'), > "glFiscalTypeId": glFiscalTypeId, "fromDate": fromDate, > "thruDate": thruDate, "userLogin": userLogin]); > BigDecimal netIncome = (BigDecimal)netIncomeResult.totalNetIncome; > -GenericValue retainedEarningsAccount = > from("GlAccountTypeDefault").where("glAccountTypeId", > "RETAINED_EARNINGS", "organizationPartyId", > organizationPartyId).cache(true).queryOne(); > +GenericValue retainedEarningsAccount = > from("GlAccountTypeDefault").where("glAccountTypeId", > "RETAINED_EARNINGS", "organizationPartyId", > parameters.get('ApplicationDecorator|organizationPartyId')).cache(true).queryOne(); > if (retainedEarningsAccount) { > GenericValue retainedEarningsGlAccount = > retainedEarningsAccount.getRelatedOne("GlAccount", false); > transactionTotalsMap.put(retainedEarningsGlAccount.glAccountId, > UtilMisc.toMap("glAccountId", > retainedEarningsGlAccount.glAccountId,"accountName", > retainedEarningsGlAccount.accountName, "accountCode", > retainedEarningsGlAccount.accountCode, "balance", netIncome)); > > Modified: > ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/reports/CashFlowStatement.groovy > URL: > http://svn.apache.org/viewvc/ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/reports/CashFlowStatement.groovy?rev=1728584&r1=1728583&r2=1728584&view=diff > ============================================================================== > --- > ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/reports/CashFlowStatement.groovy > (original) > +++ > ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/reports/CashFlowStatement.groovy > Fri Feb 5 01:45:50 2016 > @@ -43,8 +43,8 @@ uiLabelMap = UtilProperties.getResourceB > parametersFromDate = fromDate; > > // Setup the divisions for which the report is executed > -List partyIds = > PartyWorker.getAssociatedPartyIdsByRelationshipType(delegator, > organizationPartyId, 'GROUP_ROLLUP'); > -partyIds.add(organizationPartyId); > +List partyIds = > PartyWorker.getAssociatedPartyIdsByRelationshipType(delegator, > parameters.get('ApplicationDecorator|organizationPartyId'), > 'GROUP_ROLLUP'); > +partyIds.add(parameters.get('ApplicationDecorator|organizationPartyId')); > > // Get the group of account classes that will be used to position > accounts in the proper section of the Cash Flow statement > GenericValue glAccountClass = > from("GlAccountClass").where("glAccountClassId", > "CASH_EQUIVALENT").cache(true).queryOne(); > @@ -53,7 +53,7 @@ List glAccountClassIds = UtilAccounting. > List cashFlowBalanceTotalList = []; > > // Find the last closed time period to get the fromDate for the > transactions in the current period and the ending balances of the > last closed period > -Map lastClosedTimePeriodResult = runService('findLastClosedDate', > ["organizationPartyId":organizationPartyId, "findDate":new > Date(parametersFromDate.getTime()),"userLogin":userLogin]); > +Map lastClosedTimePeriodResult = runService('findLastClosedDate', > ["organizationPartyId":parameters.get('ApplicationDecorator|organizationPartyId'), > "findDate":new > Date(parametersFromDate.getTime()),"userLogin":userLogin]); > Timestamp periodClosingFromDate = > (Timestamp)lastClosedTimePeriodResult.lastClosedDate; > if (!periodClosingFromDate) { > return; > > Modified: > ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/reports/GlAccountTrialBalance.groovy > URL: > http://svn.apache.org/viewvc/ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/reports/GlAccountTrialBalance.groovy?rev=1728584&r1=1728583&r2=1728584&view=diff > ============================================================================== > --- > ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/reports/GlAccountTrialBalance.groovy > (original) > +++ > ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/reports/GlAccountTrialBalance.groovy > Fri Feb 5 01:45:50 2016 > @@ -23,17 +23,17 @@ import org.ofbiz.base.util.UtilNumber; > import org.ofbiz.accounting.util.UtilAccounting; > import com.ibm.icu.util.Calendar; > > -if (organizationPartyId) { > +if (parameters.get('ApplicationDecorator|organizationPartyId')) { > onlyIncludePeriodTypeIdList = []; > onlyIncludePeriodTypeIdList.add("FISCAL_YEAR"); > - customTimePeriodResults = runService('findCustomTimePeriods', > [findDate : UtilDateTime.nowTimestamp(), organizationPartyId : > organizationPartyId, onlyIncludePeriodTypeIdList : > onlyIncludePeriodTypeIdList, userLogin : userLogin]); > + customTimePeriodResults = runService('findCustomTimePeriods', > [findDate : UtilDateTime.nowTimestamp(), organizationPartyId : > parameters.get('ApplicationDecorator|organizationPartyId'), > onlyIncludePeriodTypeIdList : onlyIncludePeriodTypeIdList, > userLogin : userLogin]); > customTimePeriodList = > customTimePeriodResults.customTimePeriodList; > if (UtilValidate.isNotEmpty(customTimePeriodList)) { > context.timePeriod = > customTimePeriodList.first().customTimePeriodId; > } > decimals = UtilNumber.getBigDecimalScale("ledger.decimals"); > rounding = > UtilNumber.getBigDecimalRoundingMode("ledger.rounding"); > - context.currentOrganization = > from("PartyNameView").where("partyId", > organizationPartyId).queryOne(); > + context.currentOrganization = > from("PartyNameView").where("partyId", > parameters.get('ApplicationDecorator|organizationPartyId')).queryOne(); > if (parameters.glAccountId) { > glAccount = from("GlAccount").where("glAccountId", > parameters.glAccountId).queryOne(); > isDebitAccount = UtilAccounting.isDebitAccount(glAccount); > @@ -49,7 +49,7 @@ if (organizationPartyId) { > previousTimePeriodResult = > runService('getPreviousTimePeriod', [customTimePeriodId : > parameters.timePeriod, userLogin : userLogin]); > previousTimePeriod = > previousTimePeriodResult.previousTimePeriod; > if (UtilValidate.isNotEmpty(previousTimePeriod)) { > - glAccountHistory = > from("GlAccountHistory").where("customTimePeriodId", > previousTimePeriod.customTimePeriodId, "glAccountId", > parameters.glAccountId, "organizationPartyId", > organizationPartyId).queryOne(); > + glAccountHistory = > from("GlAccountHistory").where("customTimePeriodId", > previousTimePeriod.customTimePeriodId, "glAccountId", > parameters.glAccountId, "organizationPartyId", > parameters.get('ApplicationDecorator|organizationPartyId')).queryOne(); > if (glAccountHistory && > glAccountHistory.endingBalance != null) { > context.openingBalance = > glAccountHistory.endingBalance; > balanceOfTheAcctgForYear = > glAccountHistory.endingBalance; > @@ -75,7 +75,7 @@ if (organizationPartyId) { > isPosted = ""; > } > acctgTransEntriesAndTransTotal = > runService('getAcctgTransEntriesAndTransTotal', > - [customTimePeriodStartDate : > customTimePeriodStartDate, customTimePeriodEndDate : > customTimePeriodEndDate, organizationPartyId : > organizationPartyId, glAccountId : parameters.glAccountId, > isPosted : isPosted, userLogin : userLogin]); > + [customTimePeriodStartDate : > customTimePeriodStartDate, customTimePeriodEndDate : > customTimePeriodEndDate, organizationPartyId : > parameters.get('ApplicationDecorator|organizationPartyId'), > glAccountId : parameters.glAccountId, isPosted : isPosted, > userLogin : userLogin]); > totalOfYearToDateDebit = totalOfYearToDateDebit + > acctgTransEntriesAndTransTotal.debitTotal; > acctgTransEntriesAndTransTotal.totalOfYearToDateDebit = > totalOfYearToDateDebit.setScale(decimals, rounding); > totalOfYearToDateCredit = totalOfYearToDateCredit + > acctgTransEntriesAndTransTotal.creditTotal; > > Modified: > ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/reports/IncomeStatement.groovy > URL: > http://svn.apache.org/viewvc/ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/reports/IncomeStatement.groovy?rev=1728584&r1=1728583&r2=1728584&view=diff > ============================================================================== > --- > ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/reports/IncomeStatement.groovy > (original) > +++ > ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/reports/IncomeStatement.groovy > Fri Feb 5 01:45:50 2016 > @@ -36,8 +36,8 @@ if (!glFiscalTypeId) { > } > > // Setup the divisions for which the report is executed > -List partyIds = > PartyWorker.getAssociatedPartyIdsByRelationshipType(delegator, > organizationPartyId, 'GROUP_ROLLUP'); > -partyIds.add(organizationPartyId); > +List partyIds = > PartyWorker.getAssociatedPartyIdsByRelationshipType(delegator, > parameters.get('ApplicationDecorator|organizationPartyId'), > 'GROUP_ROLLUP'); > +partyIds.add(parameters.get('ApplicationDecorator|organizationPartyId')); > > // Get the group of account classes that will be used to position > accounts in the proper section of the financial statement > GenericValue revenueGlAccountClass = > from("GlAccountClass").where("glAccountClassId", > "REVENUE").cache(true).queryOne(); > > Modified: > ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/reports/TransactionTotals.groovy > URL: > http://svn.apache.org/viewvc/ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/reports/TransactionTotals.groovy?rev=1728584&r1=1728583&r2=1728584&view=diff > ============================================================================== > --- > ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/reports/TransactionTotals.groovy > (original) > +++ > ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/actions/reports/TransactionTotals.groovy > Fri Feb 5 01:45:50 2016 > @@ -41,7 +41,7 @@ if (!glFiscalTypeId) { > } > > // Find the last closed time period to get the fromDate for the > transactions in the current period and the ending balances of the > last closed period > -Map lastClosedTimePeriodResult = runService('findLastClosedDate', > ["organizationPartyId": organizationPartyId, "findDate": new > Date(fromDate.getTime()),"userLogin": userLogin]); > +Map lastClosedTimePeriodResult = runService('findLastClosedDate', > ["organizationPartyId": > parameters.get('ApplicationDecorator|organizationPartyId'), > "findDate": new Date(fromDate.getTime()),"userLogin": userLogin]); > Timestamp lastClosedDate = > (Timestamp)lastClosedTimePeriodResult.lastClosedDate; > GenericValue lastClosedTimePeriod = null; > if (lastClosedDate) { > @@ -71,7 +71,7 @@ if (postedTransactionTotals) { > // Get the opening balances at the end of the > last closed time period > if (UtilAccounting.isAssetAccount(glAccount) || > UtilAccounting.isLiabilityAccount(glAccount) || > UtilAccounting.isEquityAccount(glAccount)) { > if (lastClosedTimePeriod) { > - lastTimePeriodHistory = > from("GlAccountAndHistory").where("organizationPartyId", > organizationPartyId, "glAccountId", > postedTransactionTotal.glAccountId, "customTimePeriodId", > lastClosedTimePeriod.customTimePeriodId).queryFirst(); > + lastTimePeriodHistory = > from("GlAccountAndHistory").where("organizationPartyId", > parameters.get('ApplicationDecorator|organizationPartyId'), > "glAccountId", postedTransactionTotal.glAccountId, > "customTimePeriodId", > lastClosedTimePeriod.customTimePeriodId).queryFirst(); > if (lastTimePeriodHistory) { > accountMap = > UtilMisc.toMap("glAccountId", lastTimePeriodHistory.glAccountId, > "accountCode", lastTimePeriodHistory.accountCode, "accountName", > lastTimePeriodHistory.accountName, "balance", > lastTimePeriodHistory.getBigDecimal("endingBalance"), "openingD", > lastTimePeriodHistory.getBigDecimal("postedDebits"), "openingC", > lastTimePeriodHistory.getBigDecimal("postedCredits"), "D", > BigDecimal.ZERO, "C", BigDecimal.ZERO); > } > @@ -162,7 +162,7 @@ if (unpostedTransactionTotals) { > // Get the opening balances at the end of the > last closed time period > if (UtilAccounting.isAssetAccount(glAccount) || > UtilAccounting.isLiabilityAccount(glAccount) || > UtilAccounting.isEquityAccount(glAccount)) { > if (lastClosedTimePeriod) { > - lastTimePeriodHistory = > from("GlAccountAndHistory").where("organizationPartyId", > organizationPartyId, "glAccountId", > unpostedTransactionTotal.glAccountId, "customTimePeriodId", > lastClosedTimePeriod.customTimePeriodId).queryFirst(); > + lastTimePeriodHistory = > from("GlAccountAndHistory").where("organizationPartyId", > parameters.get('ApplicationDecorator|organizationPartyId'), > "glAccountId", unpostedTransactionTotal.glAccountId, > "customTimePeriodId", > lastClosedTimePeriod.customTimePeriodId).queryFirst(); > if (lastTimePeriodHistory) { > accountMap = > UtilMisc.toMap("glAccountId", lastTimePeriodHistory.glAccountId, > "accountCode", lastTimePeriodHistory.accountCode, "accountName", > lastTimePeriodHistory.accountName, "balance", > lastTimePeriodHistory.getBigDecimal("endingBalance"), "openingD", > lastTimePeriodHistory.getBigDecimal("postedDebits"), "openingC", > lastTimePeriodHistory.getBigDecimal("postedCredits"), "D", > BigDecimal.ZERO, "C", BigDecimal.ZERO); > } > @@ -254,7 +254,7 @@ if (allTransactionTotals) { > if (UtilAccounting.isAssetAccount(glAccount) || > UtilAccounting.isLiabilityAccount(glAccount) || > UtilAccounting.isEquityAccount(glAccount)) { > if (lastClosedTimePeriod) { > List timePeriodAndExprs = []; > - > timePeriodAndExprs.add(EntityCondition.makeCondition("organizationPartyId", > EntityOperator.EQUALS, organizationPartyId)); > + > timePeriodAndExprs.add(EntityCondition.makeCondition("organizationPartyId", > EntityOperator.EQUALS, > parameters.get('ApplicationDecorator|organizationPartyId'))); > timePeriodAndExprs.add(EntityCondition.makeCondition("glAccountId", > EntityOperator.EQUALS, allTransactionTotal.glAccountId)); > timePeriodAndExprs.add(EntityCondition.makeCondition("customTimePeriodId", > EntityOperator.EQUALS, lastClosedTimePeriod.customTimePeriodId)); > lastTimePeriodHistory = > from("GlAccountAndHistory").where(timePeriodAndExprs).queryFirst(); > > Modified: > ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/controller.xml > URL: > http://svn.apache.org/viewvc/ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/controller.xml?rev=1728584&r1=1728583&r2=1728584&view=diff > ============================================================================== > --- > ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/controller.xml > (original) > +++ > ofbiz/trunk/applications/accounting/webapp/accounting/WEB-INF/controller.xml > Fri Feb 5 01:45:50 2016 > @@ -629,6 +629,7 @@ under the License. > <!-- Party Accounts requests --> > <request-map uri="PartyAccountsSummary"> > <security https="true" auth="true"/> > + <event type="service" invoke="setAcctgCompany"/> > <response name="success" type="view" > value="PartyAccountsSummary"/> > </request-map> > <request-map uri="quickCreateAcctgTransAndEntries"> > @@ -777,6 +778,7 @@ under the License. > <!-- Import export --> > <request-map uri="ImportExport"> > <security https="true" auth="true"/> > + <event type="service" invoke="setAcctgCompany"/> > <response name="success" type="view" value="ImportExport"/> > </request-map> > <request-map uri="ExportInvoiceCsv.csv"> > @@ -1598,6 +1600,7 @@ under the License. > </request-map> > <request-map uri="AdminMain"> > <security https="true" auth="true"/> > + <event type="service" invoke="setAcctgCompany"/> > <response name="success" type="view" > value="PartyAcctgPreference"/> > </request-map> > <request-map uri="TimePeriods"> > @@ -1618,6 +1621,7 @@ under the License. > </request-map> > <request-map uri="PartyAcctgPreference"> > <security https="true" auth="true"/> > + <event type="service" invoke="setAcctgCompany"/> > <response name="success" type="view" > value="PartyAcctgPreference"/> > </request-map> > <request-map uri="createPartyAcctgPreference"> > > Modified: > ofbiz/trunk/applications/accounting/webapp/accounting/reports/GlAccountTrialBalanceReport.ftl > URL: > http://svn.apache.org/viewvc/ofbiz/trunk/applications/accounting/webapp/accounting/reports/GlAccountTrialBalanceReport.ftl?rev=1728584&r1=1728583&r2=1728584&view=diff > ============================================================================== > --- > ofbiz/trunk/applications/accounting/webapp/accounting/reports/GlAccountTrialBalanceReport.ftl > (original) > +++ > ofbiz/trunk/applications/accounting/webapp/accounting/reports/GlAccountTrialBalanceReport.ftl > Fri Feb 5 01:45:50 2016 > @@ -21,7 +21,7 @@ under the License. > <div> > <form name="glAccountTrialBalanceReport" > id="glAccountTrialBalanceReport"> > <div> > - <a > href="<@ofbizUrl>GlAccountTrialBalanceReportPdf.pdf?organizationPartyId=${organizationPartyId}&timePeriod=${parameters.timePeriod}&isPosted=${parameters.isPosted}&glAccountId=${parameters.glAccountId}</@ofbizUrl>" > target="_BLANK" > class="buttontext">${uiLabelMap.AccountingInvoicePDF}</a> > + <a > href="<@ofbizUrl>GlAccountTrialBalanceReportPdf.pdf?timePeriod=${parameters.timePeriod}&isPosted=${parameters.isPosted}&glAccountId=${parameters.glAccountId}</@ofbizUrl>" > target="_BLANK" > class="buttontext">${uiLabelMap.AccountingInvoicePDF}</a> > </div> > <h3>${uiLabelMap.AccountingSubsidiaryLedger}</h3> > <h3>${uiLabelMap.FormFieldTitle_companyName} : > ${(currentOrganization.groupName)!}</h3> > > Modified: ofbiz/trunk/applications/accounting/widget/CommonScreens.xml > URL: > http://svn.apache.org/viewvc/ofbiz/trunk/applications/accounting/widget/CommonScreens.xml?rev=1728584&r1=1728583&r2=1728584&view=diff > ============================================================================== > --- ofbiz/trunk/applications/accounting/widget/CommonScreens.xml > (original) > +++ ofbiz/trunk/applications/accounting/widget/CommonScreens.xml > Fri Feb 5 01:45:50 2016 > @@ -196,7 +196,6 @@ under the License. > <section> > <actions> > <set field="headerItem" value="companies"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId" global="true"/> > </actions> > <widgets> > <decorator-screen name="main-decorator" > location="${parameters.mainDecoratorLocation}"> > @@ -230,7 +229,7 @@ under the License. > <actions> > <set field="tabButtonItemTop" value="PartyAccounts"/> > <entity-one entity-name="PartyNameView" > value-field="currentOrganization" auto-field-map="false"> > - <field-map field-name="partyId" > from-field="organizationPartyId"/> > + <field-map field-name="partyId" > value="${groovy:parameters.get('ApplicationDecorator|organizationPartyId')}"/> > </entity-one> > </actions> > <widgets> > @@ -251,7 +250,7 @@ under the License. > <actions> > <set field="tabButtonItemTop" value="PartyAccounts"/> > <entity-one entity-name="PartyNameView" > value-field="currentOrganization" auto-field-map="false"> > - <field-map field-name="partyId" > from-field="organizationPartyId"/> > + <field-map field-name="partyId" > value="${groovy:parameters.get('ApplicationDecorator|organizationPartyId')}"/> > </entity-one> > </actions> > <widgets> > > Modified: ofbiz/trunk/applications/accounting/widget/GlScreens.xml > URL: > http://svn.apache.org/viewvc/ofbiz/trunk/applications/accounting/widget/GlScreens.xml?rev=1728584&r1=1728583&r2=1728584&view=diff > ============================================================================== > --- ofbiz/trunk/applications/accounting/widget/GlScreens.xml > (original) > +++ ofbiz/trunk/applications/accounting/widget/GlScreens.xml Fri > Feb 5 01:45:50 2016 > @@ -26,7 +26,7 @@ under the License. > <actions> > <set field="tabButtonItemTop" value="PartyAccounts"/> > <entity-one entity-name="PartyNameView" > value-field="currentOrganization" auto-field-map="false"> > - <field-map field-name="partyId" > from-field="organizationPartyId"/> > + <field-map field-name="partyId" > value="${groovy:parameters.get('ApplicationDecorator|organizationPartyId')}"/> > </entity-one> > </actions> > <widgets> > @@ -47,7 +47,6 @@ under the License. > <set field="titleProperty" > value="AccountingPartyAccountsSummary"/> > <set field="tabButtonItem" > value="PartyAccountsSummary"/> > <set field="labelTitleProperty" > value="AccountingPartyAccountsSummary"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId" global="true"/> > <!-- entity-condition > entity-name="GlAccountOrganization" list="entityList" > use-cache="true" > > <condition-expr field-name="glAccountId" > operator="greater" value="0"/> > </entity-condition --> > @@ -74,7 +73,6 @@ under the License. > <set field="titleProperty" > value="AccountingAcctgTrans"/> > <set field="tabButtonItem" value="FindAcctgTrans"/> > <set field="labelTitleProperty" > value="AccountingAcctgTrans"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId" global="true"/> > </actions> > <widgets> > <decorator-screen name="CommonPartyGlDecorator" > location="${parameters.partyGlDecoratorLocation}"> > @@ -144,7 +142,6 @@ under the License. > <set field="titleProperty" > value="AccountingAcctgTransEntries"/> > <set field="tabButtonItem" > value="FindAcctgTransEntries"/> > <set field="labelTitleProperty" > value="AccountingAcctgTransEntries"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId" global="true"/> > </actions> > <widgets> > <decorator-screen name="CommonPartyGlDecorator" > location="${parameters.partyGlDecoratorLocation}"> > @@ -274,7 +271,6 @@ under the License. > <actions> > <set field="titleProperty" > value="AccountingCreateAcctgTransAndEntries"/> > <set field="tabButtonItem" value="FindAcctgTrans"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId" global="true"/> > <set field="labelTitleProperty" > value="AccountingCreateAcctgTransAndEntries"/> > </actions> > <widgets> > @@ -295,7 +291,6 @@ under the License. > <property-map resource="AccountingUiLabels" > map-name="uiLabelMap" global="true"/> > <set field="titleProperty" > value="PageTitleEditTransaction"/> > <set field="tabButtonItem" value="FindAcctgTrans"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId" global="true"/> > <set field="acctgTransId" > from-field="parameters.acctgTransId"/> > > <entity-one entity-name="AcctgTrans" > value-field="acctgTrans"/> > @@ -355,9 +350,7 @@ under the License. > <property-map resource="AccountingUiLabels" > map-name="uiLabelMap" global="true"/> > <set field="titleProperty" > value="PageTitleUnpostedTransactions"/> > <set field="tabButtonItem" value="FindAcctgTrans"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId" global="true"/> > <set field="labelTitleProperty" > value="${uiLabelMap.PageTitleUnpostedTransactions}"/> > - <set field="partyId" > from-field="parameters.organizationPartyId"/> > <entity-condition entity-name="AcctgTrans" > list="transactions"> > <condition-expr field-name="isPosted" > operator="not-equals" value="Y"/> > <order-by field-name="transactionDate"/> > @@ -383,12 +376,11 @@ under the License. > <set field="tabButtonItem" value="ChecksTabButton"/> > <set field="tabButtonItem2" > value="PrintChecksTabButton"/> > <set field="labelTitleProperty" > value="${uiLabelMap.AccountingPrintChecks}"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId"/> > > <!-- find payments of paymentMethodType > PERSONAL_CHECK or COMPANY_CHECK with statusId NOT_PAID --> > <entity-condition entity-name="Payment" > list="payments"> > <condition-list combine="and"> > - <condition-expr field-name="partyIdFrom" > operator="equals" from-field="organizationPartyId"/> > + <condition-expr field-name="partyIdFrom" > operator="equals" > value="${groovy:parameters.get('ApplicationDecorator|organizationPartyId')}"/> > <condition-expr field-name="statusId" > operator="equals" value="PMNT_NOT_PAID"/> > <condition-list combine="or"> > <condition-expr > field-name="paymentMethodTypeId" operator="equals" > value="PERSONAL_CHECK"/> > @@ -425,12 +417,11 @@ under the License. > <set field="titleProperty" > value="AccountingSendChecks"/> > <set field="tabButtonItem" value="ChecksTabButton"/> > <set field="tabButtonItem2" > value="SendChecksTabButton"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId"/> > > <!-- find payments of paymentMethodType > PERSONAL_CHECK or COMPANY_CHECK with statusId NOT_PAID --> > <entity-condition entity-name="Payment" > list="payments"> > <condition-list combine="and"> > - <condition-expr field-name="partyIdFrom" > operator="equals" from-field="organizationPartyId"/> > + <condition-expr field-name="partyIdFrom" > operator="equals" > value="${groovy:parameters.get('ApplicationDecorator|organizationPartyId')}"/> > <condition-expr field-name="statusId" > operator="equals" value="PMNT_NOT_PAID"/> > <condition-list combine="or"> > <condition-expr > field-name="paymentMethodTypeId" operator="equals" > value="PERSONAL_CHECK"/> > @@ -470,7 +461,6 @@ under the License. > <actions> > <set field="titleProperty" > value="AccountingCreateAnAccountingTransaction"/> > <set field="tabButtonItem" value="FindAcctgTrans"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId" global="true"/> > <set field="labelTitleProperty" > value="AccountingCreateAnAccountingTransaction"/> > </actions> > <widgets> > @@ -491,7 +481,6 @@ under the License. > <set field="titleProperty" > value="AccountingAcctRecon"/> > <set field="tabButtonItem" > value="AccountReconciliation"/> > <set field="labelTitleProperty" > value="AccountingAcctRecon"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId" global="true"/> > <set field="glAccountId" > from-field="parameters.glAccountId"/> > </actions> > <widgets> > @@ -520,7 +509,6 @@ under the License. > <actions> > <set field="titleProperty" > value="AccountingEditAcctRecon"/> > <set field="tabButtonItem" > from-field="parameters.tabButtonItem" global="true"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId" global="true"/> > <set field="glReconciliationId" > from-field="parameters.glReconciliationId" global="true"/> > <entity-one entity-name="GlReconciliation" > value-field="glReconciliation"/> > </actions> > @@ -544,7 +532,6 @@ under the License. > <set field="titleProperty" > value="AccountingAcctRecons"/> > <set field="tabButtonItem" > value="AccountReconciliations"/> > <set field="labelTitleProperty" > value="AccountingAcctRecons"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId" global="true"/> > <set field="glAccountId" > from-field="parameters.glAccountId"/> > </actions> > <widgets> > @@ -573,7 +560,6 @@ under the License. > <section> > <actions> > <property-map resource="AccountingUiLabels" > map-name="uiLabelMap" global="true"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId"/> > </actions> > <widgets> > <container> > @@ -587,7 +573,6 @@ under the License. > <section> > <actions> > <property-map resource="AccountingUiLabels" > map-name="uiLabelMap" global="true"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId"/> > </actions> > <widgets> > <container> > @@ -603,10 +588,9 @@ under the License. > <property-map resource="CommonUiLabels" > map-name="uiLabelMap" global="true"/> > <property-map resource="AccountingUiLabels" > map-name="uiLabelMap" global="true"/> > <property-map resource="WorkEffortUiLabels" > map-name="uiLabelMap" global="true"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId" global="true"/> > <entity-condition > entity-name="AcctgTransAndEntries" list="acctgTransEntryList"> > <condition-list> > - <condition-expr > field-name="organizationPartyId" operator="equals" > from-field="parameters.organizationPartyId"/> > + <condition-expr > field-name="organizationPartyId" operator="equals" > value="${groovy:parameters.get('ApplicationDecorator|organizationPartyId')}"/> > <condition-expr field-name="glAccountId" > operator="equals" from-field="parameters.glAccountId" > ignore-if-empty="true"/> > <condition-expr > field-name="acctgTransTypeId" operator="equals" > from-field="parameters.acctgTransTypeId" ignore-if-empty="true"/> > <condition-expr > field-name="glFiscalTypeId" operator="equals" > from-field="parameters.glFiscalTypeId" ignore-if-empty="true"/> > @@ -640,10 +624,9 @@ under the License. > <property-map resource="CommonUiLabels" > map-name="uiLabelMap" global="true"/> > <property-map resource="AccountingUiLabels" > map-name="uiLabelMap" global="true"/> > <property-map resource="WorkEffortUiLabels" > map-name="uiLabelMap" global="true"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId" global="true"/> > <entity-condition > entity-name="AcctgTransAndEntries" list="acctgTransList" > distinct="true" > > <condition-list> > - <condition-expr > field-name="organizationPartyId" operator="equals" > from-field="organizationPartyId"/> > + <condition-expr > field-name="organizationPartyId" operator="equals" > value="${groovy:parameters.get('ApplicationDecorator|organizationPartyId')}"/> > <condition-expr > field-name="acctgTransTypeId" operator="equals" > from-field="parameters.acctgTransTypeId" ignore-if-empty="true"/> > <condition-expr > field-name="glFiscalTypeId" operator="equals" > from-field="parameters.glFiscalTypeId" ignore-if-empty="true"/> > <condition-expr field-name="glJournalId" > operator="equals" from-field="parameters.glJournalId" > ignore-if-empty="true"/> > > Modified: ofbiz/trunk/applications/accounting/widget/GlSetupForms.xml > URL: > http://svn.apache.org/viewvc/ofbiz/trunk/applications/accounting/widget/GlSetupForms.xml?rev=1728584&r1=1728583&r2=1728584&view=diff > ============================================================================== > --- ofbiz/trunk/applications/accounting/widget/GlSetupForms.xml > (original) > +++ ofbiz/trunk/applications/accounting/widget/GlSetupForms.xml > Fri Feb 5 01:45:50 2016 > @@ -156,7 +156,7 @@ under the License. > </actions> > <alt-target use-when="partyAcctgPreference!=null" > target="updatePartyAcctgPreference"/> > <auto-fields-service > service-name="createPartyAcctgPreference"/> > - <field name="organizationPartyId"><hidden > value="${parameters.organizationPartyId}"/></field> > + <field name="organizationPartyId"><hidden > value="${organizationPartyId}"/></field> > <!-- the partyId is always displayed --> > <field name="partyId" > title="${uiLabelMap.AccountingOrganizationPartyId}"><display/></field> > <!-- if there is no partyAcctgPreference yet, then we > show drop-downs for the fields and a submit button --> > @@ -1092,7 +1092,7 @@ under the License. > odd-row-style="alternate-row" > header-row-style="header-row-2" default-table-style="basic-table > hover-bar" paginate="false"> > <actions> > <entity-condition > entity-name="GlAccountOrganizationAndClass"> > - <condition-expr field-name="organizationPartyId" > from-field="organizationPartyId"/> > + <condition-expr field-name="organizationPartyId" > value="${groovy:parameters.get('ApplicationDecorator|organizationPartyId')}"/> > <order-by field-name="glAccountId"/> > </entity-condition> > </actions> > > Modified: > ofbiz/trunk/applications/accounting/widget/GlSetupScreens.xml > URL: > http://svn.apache.org/viewvc/ofbiz/trunk/applications/accounting/widget/GlSetupScreens.xml?rev=1728584&r1=1728583&r2=1728584&view=diff > ============================================================================== > --- ofbiz/trunk/applications/accounting/widget/GlSetupScreens.xml > (original) > +++ ofbiz/trunk/applications/accounting/widget/GlSetupScreens.xml > Fri Feb 5 01:45:50 2016 > @@ -26,7 +26,7 @@ under the License. > <actions> > <set field="tabButtonItemTop" value="Admin"/> > <entity-one entity-name="PartyNameView" > value-field="currentOrganization" auto-field-map="false"> > - <field-map field-name="partyId" > from-field="organizationPartyId"/> > + <field-map field-name="partyId" > value="${groovy:if(parameters.organizationPartyId!=null) return > parameters.organizationPartyId else return > parameters.get('ApplicationDecorator|organizationPartyId')}"/> > </entity-one> > </actions> > <widgets> > @@ -97,13 +97,13 @@ under the License. > <actions> > <set field="titleProperty" > value="CommonImportExport"/> > <entity-one entity-name="PartyGroup" > value-field="partyGroup"> > - <field-map field-name="partyId" > from-field="parameters.organizationPartyId"/> > + <field-map field-name="partyId" > value="${groovy:parameters.get('ApplicationDecorator|organizationPartyId')}"/> > </entity-one> > </actions> > <widgets> > <decorator-screen name="main-decorator" > location="${parameters.mainDecoratorLocation}"> > <decorator-section name="body"> > - <screenlet > title="${uiLabelMap.AccountingInvoice} > ${uiLabelMap.CommonImportExport} ${uiLabelMap.CommonFor}: > ${partyGroup.groupName} [${parameters.organizationPartyId}]"> > + <screenlet > title="${uiLabelMap.AccountingInvoice} > ${uiLabelMap.CommonImportExport} ${uiLabelMap.CommonFor}: > ${partyGroup.groupName} [${organizationPartyId}]"> > <container style="lefthalf"> > <label > style="h2">${uiLabelMap.CommonImport}</label> > <include-form > name="ImportInvoice" > location="component://accounting/widget/GlSetupForms.xml"/> > @@ -126,7 +126,7 @@ under the License. > <set field="organizationPartyId" > from-field="parameters.organizationPartyId"/> > </actions> > <widgets> > - <include-form name="ExportInvoiceCsv" > location="component://accounting/widget/GlSetupForms.xml"/> > + <include-form name="ExportInvoiceCsv" > location="component://accounting/widget/GlSetupForms.xml"/> > </widgets> > </section> > </screen> > @@ -163,17 +163,16 @@ under the License. > <set field="titleProperty" > value="AccountingTimePeriod"/> > <set field="labelTitleProperty" > value="${uiLabelMap.AccountingTimePeriod}"/> > <set field="tabButtonItem" value="TimePeriods"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId"/> > <entity-condition entity-name="CustomTimePeriod" > list="openTimePeriods"> > <condition-list> > - <condition-expr > field-name="organizationPartyId" operator="equals" > from-field="organizationPartyId"/> > + <condition-expr > field-name="organizationPartyId" operator="equals" > value="${groovy:parameters.get('ApplicationDecorator|organizationPartyId')}"/> > <condition-expr field-name="isClosed" > operator="equals" value="N"/> > </condition-list> > <order-by field-name="thruDate"/> > </entity-condition> > <entity-condition entity-name="CustomTimePeriod" > list="closedTimePeriods"> > <condition-list> > - <condition-expr > field-name="organizationPartyId" operator="equals" > from-field="organizationPartyId"/> > + <condition-expr > field-name="organizationPartyId" operator="equals" > value="${groovy:parameters.get('ApplicationDecorator|organizationPartyId')}"/> > <condition-expr field-name="isClosed" > operator="equals" value="Y"/> > </condition-list> > <order-by field-name="periodTypeId"/> > @@ -205,9 +204,8 @@ under the License. > <set field="titleProperty" > value="AccountingPreference"/> > <set field="labelTitleProperty" > value="${uiLabelMap.AccountingPreference}"/> > <set field="tabButtonItem" > value="PartyAcctgPreference"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId"/> > <property-to-field field="defaultCurrencyUomId" > resource="general" property="currency.uom.id.default" default="USD"/> > - <set field="partyId" > from-field="parameters.organizationPartyId"/> > + <set field="partyId" > value="${groovy:if(parameters.organizationPartyId!=null) return > parameters.organizationPartyId else return > parameters.get('ApplicationDecorator|organizationPartyId')}"/> > <entity-one entity-name="PartyAcctgPreference" > value-field="partyAcctgPreference"/> > </actions> > <widgets> > @@ -228,7 +226,6 @@ under the License. > <set field="titleProperty" > value="AccountingGlJournals"/> > <set field="labelTitleProperty" > value="${uiLabelMap.AccountingGlJournals}"/> > <set field="tabButtonItem" value="SetupGlJournals"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId"/> > <entity-one entity-name="GlJournal" > value-field="glJournal"/> > </actions> > <widgets> > @@ -251,7 +248,6 @@ under the License. > <set field="labelTitleProperty" > value="${uiLabelMap.AccountingGlAccountTypeDefaults}"/> > <set field="tabButtonItem" > value="GlAccountAssignment"/> > <set field="tabButtonItem2" > value="GlAccountTypeDefaults"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId"/> > </actions> > <widgets> > <decorator-screen name="CommonGlSetupDecorator" > location="${parameters.commonGlSetupDecoratorLocation}"> > @@ -273,7 +269,6 @@ under the License. > <set field="labelTitleProperty" > value="${uiLabelMap.AccountingInvoiceSales}"/> > <set field="tabButtonItem" > value="GlAccountAssignment"/> > <set field="tabButtonItem2" > value="GlAccountSalInvoice"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId"/> > </actions> > <widgets> > <decorator-screen name="CommonGlSetupDecorator" > location="${parameters.commonGlSetupDecoratorLocation}"> > @@ -294,7 +289,6 @@ under the License. > <set field="titleProperty" > value="AccountingInvoicePurchase"/> > <set field="tabButtonItem" > value="GlAccountAssignment"/> > <set field="tabButtonItem2" > value="GlAccountPurInvoice"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId"/> > </actions> > <widgets> > <decorator-screen name="CommonGlSetupDecorator" > location="${parameters.commonGlSetupDecoratorLocation}"> > @@ -315,7 +309,6 @@ under the License. > <set field="titleProperty" > value="${uiLabelMap.AccountingPaymentType}/${uiLabelMap.FormFieldTitle_glAccountTypeId}"/> > <set field="tabButtonItem" > value="GlAccountAssignment"/> > <set field="tabButtonItem2" > value="GlAccountTypePaymentType"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId"/> > </actions> > <widgets> > <decorator-screen name="CommonGlSetupDecorator" > location="${parameters.commonGlSetupDecoratorLocation}"> > @@ -336,7 +329,6 @@ under the License. > <set field="titleProperty" > value="${uiLabelMap.AccountingPaymentMethodId}/${uiLabelMap.AccountingGlAccountId}"/> > <set field="tabButtonItem" > value="GlAccountAssignment"/> > <set field="tabButtonItem2" > value="GlAccountNrPaymentMethod"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId"/> > </actions> > <widgets> > <decorator-screen name="CommonGlSetupDecorator" > location="${parameters.commonGlSetupDecoratorLocation}"> > @@ -358,10 +350,9 @@ under the License. > <set field="labelTitleProperty" > value="${uiLabelMap.AccountingProductGlAccount}"/> > <set field="tabButtonItem" > value="GlAccountAssignment"/> > <set field="tabButtonItem2" > value="ProductGlAccounts"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId"/> > > <entity-condition entity-name="ProductGlAccount" > list="productGlAccounts"> > - <condition-expr > field-name="organizationPartyId" from-field="organizationPartyId"/> > + <condition-expr > field-name="organizationPartyId" > value="${groovy:parameters.get('ApplicationDecorator|organizationPartyId')}"/> > <order-by field-name="glAccountTypeId"/> > </entity-condition> > </actions> > @@ -385,10 +376,9 @@ under the License. > <set field="labelTitleProperty" > value="${uiLabelMap.AccountingFinAccountTypeGlAccount}"/> > <set field="tabButtonItem" > value="GlAccountAssignment"/> > <set field="tabButtonItem2" > value="FinAccountTypeGlAccounts"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId"/> > > <entity-condition > entity-name="FinAccountTypeGlAccount" list="finAccountTypeGlAccounts"> > - <condition-expr > field-name="organizationPartyId" operator="equals" > from-field="organizationPartyId"/> > + <condition-expr > field-name="organizationPartyId" operator="equals" > value="${groovy:parameters.get('ApplicationDecorator|organizationPartyId')}"/> > <order-by field-name="finAccountTypeId"/> > </entity-condition> > <entity-condition entity-name="FinAccountType" > list="finAccountTypes" use-cache="true"> > @@ -416,10 +406,9 @@ under the License. > <set field="labelTitleProperty" > value="${uiLabelMap.AccountingProductCategoryGlAccount}"/> > <set field="tabButtonItem" > value="GlAccountAssignment"/> > <set field="tabButtonItem2" > value="ProductCategoryGlAccounts"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId"/> > > <entity-condition > entity-name="ProductCategoryGlAccount" > list="productCategoryGlAccounts"> > - <condition-expr > field-name="organizationPartyId" from-field="organizationPartyId"/> > + <condition-expr > field-name="organizationPartyId" > value="${groovy:parameters.get('ApplicationDecorator|organizationPartyId')}"/> > <order-by field-name="glAccountTypeId"/> > </entity-condition> > </actions> > @@ -443,10 +432,9 @@ under the License. > <set field="tabButtonItem" > value="GlAccountAssignment"/> > <set field="tabButtonItem2" > value="VarianceReasonGlAccounts"/> > <set field="labelTitleProperty" > value="${uiLabelMap.AccountingVarianceReasonGlAccounts}"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId"/> > > <entity-condition > entity-name="VarianceReasonGlAccount" list="varianceReasonGlAccounts"> > - <condition-expr > field-name="organizationPartyId" from-field="organizationPartyId"/> > + <condition-expr > field-name="organizationPartyId" > value="${groovy:parameters.get('ApplicationDecorator|organizationPartyId')}"/> > <order-by field-name="glAccountId"/> > </entity-condition> > </actions> > @@ -470,9 +458,8 @@ under the License. > <set field="tabButtonItem" > value="GlAccountAssignment"/> > <set field="tabButtonItem2" > value="CreditCardTypeGlAccount"/> > <set field="labelTitleProperty" > value="${uiLabelMap.AccountingCreditCardTypeGlAccount}"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId"/> > <entity-condition > entity-name="CreditCardTypeGlAccount" list="creditCardTypeGlAccounts"> > - <condition-expr > field-name="organizationPartyId" from-field="organizationPartyId"/> > + <condition-expr > field-name="organizationPartyId" > value="${groovy:parameters.get('ApplicationDecorator|organizationPartyId')}"/> > </entity-condition> > </actions> > <widgets> > @@ -495,9 +482,8 @@ under the License. > <set field="tabButtonItem" > value="GlAccountAssignment"/> > <set field="tabButtonItem2" > value="TaxAuthorityGlAccounts"/> > <set field="labelTitleProperty" > value="${uiLabelMap.PageTitleEditTaxAuthorityGlAccounts}"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId"/> > <entity-condition > entity-name="TaxAuthorityGlAccount" list="taxAuthorityGlAccounts"> > - <condition-expr > field-name="organizationPartyId" from-field="organizationPartyId"/> > + <condition-expr > field-name="organizationPartyId" > value="${groovy:parameters.get('ApplicationDecorator|organizationPartyId')}"/> > <order-by field-name="taxAuthGeoId"/> > <order-by field-name="taxAuthPartyId"/> > </entity-condition> > @@ -523,9 +509,8 @@ under the License. > <set field="labelTitleProperty" > value="${uiLabelMap.PageTitleEditPartyGlAccounts}"/> > <set field="tabButtonItem" > value="GlAccountAssignment"/> > <set field="tabButtonItem2" value="PartyGlAccounts"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId"/> > <entity-condition entity-name="PartyGlAccount" > list="partyGlAccounts"> > - <condition-expr > field-name="organizationPartyId" from-field="organizationPartyId"/> > + <condition-expr > field-name="organizationPartyId" > value="${groovy:parameters.get('ApplicationDecorator|organizationPartyId')}"/> > <order-by field-name="partyId"/> > </entity-condition> > </actions> > @@ -549,7 +534,6 @@ under the License. > <set field="labelTitleProperty" > value="${uiLabelMap.FixedAssetTypeGlAccounts}"/> > <set field="tabButtonItem" > value="GlAccountAssignment"/> > <set field="tabButtonItem2" > value="FixedAssetTypeGlAccounts"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId"/> > </actions> > <widgets> > <decorator-screen name="CommonGlSetupDecorator" > location="${parameters.commonGlSetupDecoratorLocation}"> > @@ -568,9 +552,8 @@ under the License. > <actions> > <property-map resource="CommonUiLabels" > map-name="uiLabelMap" global="true"/> > <property-map resource="AccountingUiLabels" > map-name="uiLabelMap" global="true"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId"/> > <entity-condition > entity-name="GlAccountOrganizationAndClass" > list="glAccountOrgAndClassList"> > - <condition-expr > field-name="organizationPartyId" from-field="organizationPartyId"/> > + <condition-expr > field-name="organizationPartyId" > value="${groovy:parameters.get('ApplicationDecorator|organizationPartyId')}"/> > <order-by field-name="glAccountId"/> > </entity-condition> > </actions> > @@ -588,10 +571,9 @@ under the License. > <actions> > <property-map resource="CommonUiLabels" > map-name="uiLabelMap" global="true"/> > <property-map resource="AccountingUiLabels" > map-name="uiLabelMap" global="true"/> > - <set field="organizationPartyId" > from-field="parameters.organizationPartyId"/> > </actions> > <widgets> > - <include-form name="ListGlAccountOrgCsv" > location="component://accounting/widget/GlSetupForms.xml"/> > + <include-form name="ListGlAccountOrgCsv" > location="component://accounting/widget/GlSetupForms.xml"/> > </widgets> > </section> > </screen> > > Modified: > ofbiz/trunk/applications/accounting/widget/ReportFinancialSummaryForms.xml > URL: > http://svn.apache.org/viewvc/ofbiz/trunk/applications/accounting/widget/ReportFinancialSummaryForms.xml?rev=1728584&r1=1728583&r2=1728584&view=diff > ============================================================================== > --- > ofbiz/trunk/applications/accounting/widget/ReportFinancialSummaryForms.xml > (original) > +++ > ofbiz/trunk/applications/accounting/widget/ReportFinancialSummaryForms.xml > Fri Feb 5 01:45:50 2016 > @@ -508,7 +508,7 @@ under the License. > <actions> > <entity-condition > entity-name="InventoryItemDetailForSum" > list="inventoryValuationList" use-cache="false"> > <condition-list> > - <condition-expr field-name="ownerPartyId" > operator="equals" from-field="parameters.organizationPartyId"/> > + <condition-expr field-name="ownerPartyId" > operator="equals" > value="${groovy:parameters.get('ApplicationDecorator|organizationPartyId')}"/> > <condition-expr > field-name="accountingQuantityDiff" operator="not-equals" > value="0.0"/> > <condition-expr field-name="effectiveDate" > operator="less-equals" from-field="parameters.thruDate"/> > <condition-expr field-name="facilityId" > operator="equals" from-field="parameters.facilityId" > ignore-if-empty="true"/> > > > -- Regards, Hans Bakker CEO, http://antwebsystems.com |
Free forum by Nabble | Edit this page |