svn commit: r1177199 - /ofbiz/trunk/specialpurpose/ecommerce/webapp/ecommerce/customer/profile/ViewProfile.ftl

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

svn commit: r1177199 - /ofbiz/trunk/specialpurpose/ecommerce/webapp/ecommerce/customer/profile/ViewProfile.ftl

sascharodekamp
Author: sascharodekamp
Date: Thu Sep 29 08:01:12 2011
New Revision: 1177199

URL: http://svn.apache.org/viewvc?rev=1177199&view=rev
Log:
FIX: If no mail address for a user is set, an Error Trace was rendered in the ViewProfile.ftl. Simple check if the mail address attribute exists fixes this problem.

Modified:
    ofbiz/trunk/specialpurpose/ecommerce/webapp/ecommerce/customer/profile/ViewProfile.ftl

Modified: ofbiz/trunk/specialpurpose/ecommerce/webapp/ecommerce/customer/profile/ViewProfile.ftl
URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/ecommerce/webapp/ecommerce/customer/profile/ViewProfile.ftl?rev=1177199&r1=1177198&r2=1177199&view=diff
==============================================================================
--- ofbiz/trunk/specialpurpose/ecommerce/webapp/ecommerce/customer/profile/ViewProfile.ftl (original)
+++ ofbiz/trunk/specialpurpose/ecommerce/webapp/ecommerce/customer/profile/ViewProfile.ftl Thu Sep 29 08:01:12 2011
@@ -24,11 +24,13 @@ under the License.
       <a class="button" href="<@ofbizUrl>editProfile</@ofbizUrl>">${uiLabelMap.EcommerceEditProfile}</a>
       <h3>${uiLabelMap.PartyContactInformation}</h3>
       <label>${firstName?if_exists} ${lastName?if_exists}</label>
-      <input type="hidden" id="updatedEmailContactMechId" name="emailContactMechId" value="${emailContactMechId}" />
-      <input type="hidden" id="updatedEmailAddress" name="updatedEmailAddress" value="${emailAddress}" />
-      <label>${emailAddress}</label>
-      <a href="mailto:${emailAddress}" class="linktext">(${uiLabelMap.PartySendEmail})</a>
-      <div id="serverError_${emailContactMechId}" class="errorMessage"></div>
+      <input type="hidden" id="updatedEmailContactMechId" name="emailContactMechId" value="${emailContactMechId?if_exists}" />
+      <input type="hidden" id="updatedEmailAddress" name="updatedEmailAddress" value="${emailAddress?if_exists}" />
+      <#if emailAddress?exists>
+        <label>${emailAddress?if_exists}</label>
+        <a href="mailto:${emailAddress?if_exists}" class="linktext">(${uiLabelMap.PartySendEmail})</a>
+      </#if>
+      <div id="serverError_${emailContactMechId?if_exists}" class="errorMessage"></div>
     </div>
     <#-- Manage Addresses -->
     <div>