svn commit: r792885 - /ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/order/CompanyHeader.groovy

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

svn commit: r792885 - /ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/order/CompanyHeader.groovy

mor-2
Author: mor
Date: Fri Jul 10 11:10:35 2009
New Revision: 792885

URL: http://svn.apache.org/viewvc?rev=792885&view=rev
Log:
Added company fax number information and this can be used on various reports, if required. Patch from Ratnesh Upadhyay.

Modified:
    ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/order/CompanyHeader.groovy

Modified: ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/order/CompanyHeader.groovy
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/order/CompanyHeader.groovy?rev=792885&r1=792884&r2=792885&view=diff
==============================================================================
--- ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/order/CompanyHeader.groovy (original)
+++ ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/order/CompanyHeader.groovy Fri Jul 10 11:10:35 2009
@@ -151,6 +151,13 @@
     context.phone = delegator.findByPrimaryKey("TelecomNumber", [contactMechId : selPhones[0].contactMechId]);
 }
 
+// Fax
+faxNumbers = delegator.findByAnd("PartyContactMechPurpose", [partyId : partyId, contactMechPurposeTypeId : "FAX_NUMBER"]);
+faxNumbers = EntityUtil.filterByDate(faxContactMechs, nowTimestamp, null, null, true);
+if (faxNumbers) {  
+    context.fax = delegator.findOne("TelecomNumber", [contactMechId : faxNumbers[0]], false);
+}
+
 //Email
 emails = delegator.findByAnd("PartyContactMechPurpose", [partyId : partyId, contactMechPurposeTypeId : "PRIMARY_EMAIL"]);
 selEmails = EntityUtil.filterByDate(emails, nowTimestamp, "fromDate", "thruDate", true);