You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ofbiz.apache.org by ha...@apache.org on 2013/07/12 05:29:23 UTC

svn commit: r1502418 - in /ofbiz/trunk/applications/accounting: script/org/ofbiz/accounting/ledger/GeneralLedgerServices.xml webapp/accounting/ledger/CostCenters.ftl

Author: hansbak
Date: Fri Jul 12 03:29:22 2013
New Revision: 1502418

URL: http://svn.apache.org/r1502418
Log:
add orghanizationParty Id to the costcenter list, because the referenced glaccountId can come from several different companies in the hierarchy

Modified:
    ofbiz/trunk/applications/accounting/script/org/ofbiz/accounting/ledger/GeneralLedgerServices.xml
    ofbiz/trunk/applications/accounting/webapp/accounting/ledger/CostCenters.ftl

Modified: ofbiz/trunk/applications/accounting/script/org/ofbiz/accounting/ledger/GeneralLedgerServices.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/accounting/script/org/ofbiz/accounting/ledger/GeneralLedgerServices.xml?rev=1502418&r1=1502417&r2=1502418&view=diff
==============================================================================
--- ofbiz/trunk/applications/accounting/script/org/ofbiz/accounting/ledger/GeneralLedgerServices.xml (original)
+++ ofbiz/trunk/applications/accounting/script/org/ofbiz/accounting/ledger/GeneralLedgerServices.xml Fri Jul 12 03:29:22 2013
@@ -2864,6 +2864,9 @@ under the License.
             <if-not-empty field="glAccountCategories">
                 <iterate list="glAccountOrganizations" entry="glAccountOrganization">
                     <iterate list="glAccountCategories" entry="glAccountCategory">
+                        <entity-one entity-name="PartyGroup" value-field="organizationParty">
+                            <field-map field-name="partyId" from-field="glAccountOrganization.organizationPartyId"/>
+                        </entity-one>
                         <entity-and entity-name="GlAccountCategoryMember" list="glAccountCategoryMembers" filter-by-date="true">
                              <field-map field-name="glAccountId" from-field="glAccountOrganization.glAccountId"/>
                              <field-map field-name="glAccountCategoryId" from-field="glAccountCategory.glAccountCategoryId"/>
@@ -2872,6 +2875,7 @@ under the License.
                             <first-from-list list="glAccountCategoryMembers" entry="glAccountCategoryMember"/>
                             <set field="glAcctgOrgAndCostCenterMap[glAccountCategory.glAccountCategoryId]" from-field="glAccountCategoryMember.amountPercentage" type="BigDecimal"/>
                             <get-related-one value-field="glAccountCategoryMember" relation-name="GlAccount" to-value-field="glAccount"/>
+                            <set field="glAcctgOrgAndCostCenterMap.organizationPartyId" value="${organizationParty.groupName} [${glAccountOrganization.organizationPartyId}]"/>
                             <set field="glAcctgOrgAndCostCenterMap.glAccountId" from-field="glAccount.glAccountId"/>
                             <set field="glAcctgOrgAndCostCenterMap.accountCode" from-field="glAccount.accountCode"/>
                             <set field="glAcctgOrgAndCostCenterMap.accountName" from-field="glAccount.accountName"/>

Modified: ofbiz/trunk/applications/accounting/webapp/accounting/ledger/CostCenters.ftl
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/accounting/webapp/accounting/ledger/CostCenters.ftl?rev=1502418&r1=1502417&r2=1502418&view=diff
==============================================================================
--- ofbiz/trunk/applications/accounting/webapp/accounting/ledger/CostCenters.ftl (original)
+++ ofbiz/trunk/applications/accounting/webapp/accounting/ledger/CostCenters.ftl Fri Jul 12 03:29:22 2013
@@ -24,6 +24,7 @@ under the License.
     <input type="hidden" name="_useRowSubmit" value="Y" />
     <table class="basic-table hover-bar" cellspacing="0">
       <tr class="header-row">
+        <th>${uiLabelMap.FormFieldTitle_organizationPartyId}</th>
         <th>${uiLabelMap.FormFieldTitle_glAccountId}</th>
         <th>${uiLabelMap.FormFieldTitle_accountCode}</th>
         <th>${uiLabelMap.FormFieldTitle_accountName}</th>
@@ -35,6 +36,7 @@ under the License.
     <#assign alt_row = false>
       <#list glAcctgAndAmountPercentageList as glAcctgAndAmountPercentage>
         <tr id="row_${glAcctgAndAmountPercentage.glAccountId}" <#if alt_row> class="alternate-row"</#if>>
+          <td>${glAcctgAndAmountPercentage.organizationPartyId}</td>
           <td><input type="hidden" id="glAccountId_${glAcctgAndAmountPercentage.glAccountId}" name="glAccountId_o_${glAcctgAndAmountPercentage_index}" value="${glAcctgAndAmountPercentage.glAccountId!}"/>
               <input name="_rowSubmit_o_${glAcctgAndAmountPercentage_index}" type="hidden" value="Y"/>          
           ${glAcctgAndAmountPercentage.glAccountId}</td>