Author: ashish
Date: Fri Jun 19 05:11:31 2009
New Revision: 786373
URL:
http://svn.apache.org/viewvc?rev=786373&view=revLog:
Applied fix from jira issue OFBIZ-2627 (Clicking on expire button shows only expired record in List Contact List Party form of marketing component, it should show active records only. )
In this patch the "Edit" & "Expire" button is not shown when thruDate < nowTimeStamp.
Thanks Divesh for your contribution.
Modified:
ofbiz/trunk/applications/marketing/webapp/marketing/contact/ContactListForms.xml
Modified: ofbiz/trunk/applications/marketing/webapp/marketing/contact/ContactListForms.xml
URL:
http://svn.apache.org/viewvc/ofbiz/trunk/applications/marketing/webapp/marketing/contact/ContactListForms.xml?rev=786373&r1=786372&r2=786373&view=diff==============================================================================
--- ofbiz/trunk/applications/marketing/webapp/marketing/contact/ContactListForms.xml (original)
+++ ofbiz/trunk/applications/marketing/webapp/marketing/contact/ContactListForms.xml Fri Jun 19 05:11:31 2009
@@ -202,6 +202,10 @@
<field-map field-name="entityName" value="ContactListParty"/>
</service>
</actions>
+ <row-actions>
+ <set field="thruDate" from-field="thruDate" type="Timestamp"/>
+ <set field="isDateAfterNow" value="${groovy:org.ofbiz.base.util.UtilValidate.isDateAfterNow(thruDate)}" type="Boolean"/>
+ </row-actions>
<field name="contactListId"><hidden/></field>
<field name="partyId" title="${uiLabelMap.MarketingContactListPartyId}"><display-entity entity-name="PartyNameView" description="${firstName} ${lastName} ${groupName} [${partyId}]"/></field>
@@ -211,14 +215,14 @@
<field name="preferredContactMechId" title="${uiLabelMap.MarketingContactListPreferredContactMech}">
<display-entity entity-name="ContactMechDetail" key-field-name="contactMechId" description="[${contactMechId}]: [${infoString}] [${tnCountryCode}-${tnAreaCode}-${tnContactNumber}] [${paAddress1}, ${paAddress1}, ${paCity}, ${paStateProvinceGeoId}, ${paPostalCode}, ${paPostalCodeExt} ${paCountryGeoId}]"/>
</field>
- <field name="editLink" title=" " widget-style="buttontext">
+ <field name="editLink" use-when="${groovy:thruDate == null || isDateAfterNow == true}" widget-style="buttontext">
<hyperlink target="EditContactListParty" description="${uiLabelMap.CommonEdit}" also-hidden="false">
<parameter param-name="contactListId"/>
<parameter param-name="partyId"/>
<parameter param-name="fromDate"/>
</hyperlink>
</field>
- <field name="expireLink" title=" " widget-style="buttontext">
+ <field name="expireLink" use-when="${groovy:thruDate == null || isDateAfterNow == true}" widget-style="buttontext">
<hyperlink target="expireContactListParty" description="${uiLabelMap.CommonExpire}" link-type="hidden-form" also-hidden="false">
<parameter param-name="contactListId"/>
<parameter param-name="partyId"/>