Modified: ofbiz/branches/20111205EmailHandling/applications/order/webapp/ordermgr/entry/catalog/productsummary.ftl
URL: http://svn.apache.org/viewvc/ofbiz/branches/20111205EmailHandling/applications/order/webapp/ordermgr/entry/catalog/productsummary.ftl?rev=1305581&r1=1305580&r2=1305581&view=diff ============================================================================== --- ofbiz/branches/20111205EmailHandling/applications/order/webapp/ordermgr/entry/catalog/productsummary.ftl (original) +++ ofbiz/branches/20111205EmailHandling/applications/order/webapp/ordermgr/entry/catalog/productsummary.ftl Mon Mar 26 20:56:02 2012 @@ -101,7 +101,7 @@ ${virtualJavaScript?if_exists} <#elseif product.productTypeId?if_exists == "ASSET_USAGE"> <a href="${productUrl}" class="buttontext">${uiLabelMap.OrderMakeBooking}...</a> <#-- check to see if it is an aggregated or configurable product; will enter parameters on the detail screen--> - <#elseif product.productTypeId?if_exists == "AGGREGATED"> + <#elseif product.productTypeId?if_exists == "AGGREGATED" || product.productTypeId?if_exists == "AGGREGATED_SERVICE"> <a href="${productUrl}" class="buttontext">${uiLabelMap.OrderConfigure}...</a> <#-- check to see if the product is a virtual product --> <#elseif product.isVirtual?exists && product.isVirtual == "Y"> @@ -116,7 +116,7 @@ ${virtualJavaScript?if_exists} <input type="hidden" name="add_product_id" value="${product.productId}"/> <input type="text" size="5" name="quantity" value="1"/> <input type="hidden" name="clearSearch" value="N"/> - <input type="hidden" name="mainSubmited" value="Y"/> + <input type="hidden" name="mainSubmitted" value="Y"/> <a href="javascript:document.the${requestAttributes.formNamePrefix?if_exists}${requestAttributes.listIndex?if_exists}form.submit()" class="buttontext">${uiLabelMap.OrderAddToCart}</a> <#if mainProducts?has_content> <input type="hidden" name="product_id" value=""/> @@ -138,7 +138,7 @@ ${virtualJavaScript?if_exists} <input type="hidden" name="add_product_id" value="${prodCatMem.productId?if_exists}"/> <input type="hidden" name="quantity" value="${prodCatMem.quantity?if_exists}"/> <input type="hidden" name="clearSearch" value="N"/> - <input type="hidden" name="mainSubmited" value="Y"/> + <input type="hidden" name="mainSubmitted" value="Y"/> <a href="javascript:document.the${requestAttributes.formNamePrefix?if_exists}${requestAttributes.listIndex?if_exists}defaultform.submit()" class="buttontext">${uiLabelMap.CommonAddDefault}(${prodCatMem.quantity?string.number}) ${uiLabelMap.OrderToCart}</a> </form> <#assign productCategory = delegator.findByPrimaryKey("ProductCategory", Static["org.ofbiz.base.util.UtilMisc"].toMap("productCategoryId", prodCatMem.productCategoryId))/> @@ -147,7 +147,7 @@ ${virtualJavaScript?if_exists} <input type="hidden" name="add_product_id" value="${prodCatMem.productId?if_exists}"/> <input type="hidden" name="quantity" value="${prodCatMem.quantity?if_exists}"/> <input type="hidden" name="clearSearch" value="N"/> - <input type="hidden" name="mainSubmited" value="Y"/> + <input type="hidden" name="mainSubmitted" value="Y"/> <a href="javascript:document.the${requestAttributes.formNamePrefix?if_exists}${requestAttributes.listIndex?if_exists}defaultform.submit()" class="buttontext">${uiLabelMap.CommonAddDefault}(${prodCatMem.quantity?string.number}) ${uiLabelMap.OrderToCart}</a> </form> </#if> @@ -221,7 +221,7 @@ ${virtualJavaScript?if_exists} </#if> <form method="post" action="<@ofbizUrl secure="${request.isSecure()?string}">addToCompare</@ofbizUrl>" name="addToCompare${requestAttributes.listIndex?if_exists}form"> <input type="hidden" name="productId" value="${product.productId}"/> - <input type="hidden" name="mainSubmited" value="Y"/> + <input type="hidden" name="mainSubmitted" value="Y"/> </form> <a href="javascript:document.addToCompare${requestAttributes.listIndex?if_exists}form.submit()" class="buttontext">${uiLabelMap.ProductAddToCompare}</a> </div> Modified: ofbiz/branches/20111205EmailHandling/applications/order/webapp/ordermgr/entry/catalog/quickadd.ftl URL: http://svn.apache.org/viewvc/ofbiz/branches/20111205EmailHandling/applications/order/webapp/ordermgr/entry/catalog/quickadd.ftl?rev=1305581&r1=1305580&r2=1305581&view=diff ============================================================================== --- ofbiz/branches/20111205EmailHandling/applications/order/webapp/ordermgr/entry/catalog/quickadd.ftl (original) +++ ofbiz/branches/20111205EmailHandling/applications/order/webapp/ordermgr/entry/catalog/quickadd.ftl Mon Mar 26 20:56:02 2012 @@ -45,7 +45,7 @@ under the License. <td valign="top" width="0" colspan='2'> <div> <#if productCategory.categoryImageUrl?exists> - <img src="<@ofbizContentUrl>${productCategory.categoryImageUrl}</@ofbizContentUrl>" vspace="5" hspace="5" border="1" height='100' alt="" /> + <img src="<@ofbizContentUrl>${productCategory.categoryImageUrl}</@ofbizContentUrl>" vspace="5" hspace="5" class="cssImgLarge" alt="" /> </#if> ${productCategory.longDescription?if_exists} </div> Modified: ofbiz/branches/20111205EmailHandling/applications/order/webapp/ordermgr/entry/catalog/sidedeepcategory.ftl URL: http://svn.apache.org/viewvc/ofbiz/branches/20111205EmailHandling/applications/order/webapp/ordermgr/entry/catalog/sidedeepcategory.ftl?rev=1305581&r1=1305580&r2=1305581&view=diff ============================================================================== --- ofbiz/branches/20111205EmailHandling/applications/order/webapp/ordermgr/entry/catalog/sidedeepcategory.ftl (original) +++ ofbiz/branches/20111205EmailHandling/applications/order/webapp/ordermgr/entry/catalog/sidedeepcategory.ftl Mon Mar 26 20:56:02 2012 @@ -22,9 +22,10 @@ under the License. <#-- looping macro --> <#macro categoryList parentCategory category> - <#if parentCategory.productCategoryId != category.productCategoryId> + <#-- jleroux: This whole block does not make sense to me --> + <#--if parentCategory.productCategoryId != category.productCategoryId> <#local pStr = "/~pcategory=" + parentCategory.productCategoryId> - </#if> + </#if--> <#if curCategoryId?exists && curCategoryId == category.productCategoryId> <div class="browsecategorytext"> <#if catContentWrappers?exists && catContentWrappers[category.productCategoryId]?exists && catContentWrappers[category.productCategoryId].get("CATEGORY_NAME")?has_content> Modified: ofbiz/branches/20111205EmailHandling/applications/order/webapp/ordermgr/images/js/order.js URL: http://svn.apache.org/viewvc/ofbiz/branches/20111205EmailHandling/applications/order/webapp/ordermgr/images/js/order.js?rev=1305581&r1=1305580&r2=1305581&view=diff ============================================================================== --- ofbiz/branches/20111205EmailHandling/applications/order/webapp/ordermgr/images/js/order.js (original) +++ ofbiz/branches/20111205EmailHandling/applications/order/webapp/ordermgr/images/js/order.js Mon Mar 26 20:56:02 2012 @@ -22,7 +22,7 @@ function markOrderViewed() { url: 'markOrderViewed', type: "POST", data: jQuery('#orderViewed').serialize(), - succes: function(data) { + success: function(data) { jQuery("#isViewed").fadeOut('fast'); jQuery("#viewed").fadeIn('fast'); } Modified: ofbiz/branches/20111205EmailHandling/applications/order/webapp/ordermgr/order/editorderitems.ftl URL: http://svn.apache.org/viewvc/ofbiz/branches/20111205EmailHandling/applications/order/webapp/ordermgr/order/editorderitems.ftl?rev=1305581&r1=1305580&r2=1305581&view=diff ============================================================================== --- ofbiz/branches/20111205EmailHandling/applications/order/webapp/ordermgr/order/editorderitems.ftl (original) +++ ofbiz/branches/20111205EmailHandling/applications/order/webapp/ordermgr/order/editorderitems.ftl Mon Mar 26 20:56:02 2012 @@ -30,7 +30,7 @@ under the License. <div class="screenlet-title-bar"> <ul> <li class="h3"> ${uiLabelMap.OrderOrderItems}</li> - <#if security.hasEntityPermission("ORDERMGR", "_UPDATE", session) || security.hasRolePermission("ORDERMGR", "_UPDATE", "", "", session)> + <#if security.hasEntityPermission("ORDERMGR", "_UPDATE", session)> <#if orderHeader?has_content && orderHeader.statusId != "ORDER_CANCELLED" && orderHeader.statusId != "ORDER_COMPLETED"> <li><a href="javascript:document.updateItemInfo.action='<@ofbizUrl>cancelSelectedOrderItems</@ofbizUrl>';document.updateItemInfo.submit()">${uiLabelMap.OrderCancelSelectedItems}</a></li> <li><a href="javascript:document.updateItemInfo.action='<@ofbizUrl>cancelOrderItem</@ofbizUrl>';document.updateItemInfo.submit()">${uiLabelMap.OrderCancelAllItems}</a></li> @@ -333,7 +333,7 @@ under the License. </#list> <#-- add new adjustment --> - <#if (security.hasEntityPermission("ORDERMGR", "_UPDATE", session) || security.hasRolePermission("ORDERMGR", "_UPDATE", "", "", session)) && orderHeader.statusId != "ORDER_COMPLETED" && orderHeader.statusId != "ORDER_CANCELLED" && orderHeader.statusId != "ORDER_REJECTED"> + <#if security.hasEntityPermission("ORDERMGR", "_UPDATE", session) && orderHeader.statusId != "ORDER_COMPLETED" && orderHeader.statusId != "ORDER_CANCELLED" && orderHeader.statusId != "ORDER_REJECTED"> <form name="addAdjustmentForm" method="post" action="<@ofbizUrl>createOrderAdjustment</@ofbizUrl>"> <input type="hidden" name="comments" value="Added manually by [${userLogin.userLoginId}]"/> <input type="hidden" name="orderId" value="${orderId?if_exists}"/> Modified: ofbiz/branches/20111205EmailHandling/applications/order/webapp/ordermgr/order/orderinfo.ftl URL: http://svn.apache.org/viewvc/ofbiz/branches/20111205EmailHandling/applications/order/webapp/ordermgr/order/orderinfo.ftl?rev=1305581&r1=1305580&r2=1305581&view=diff ============================================================================== --- ofbiz/branches/20111205EmailHandling/applications/order/webapp/ordermgr/order/orderinfo.ftl (original) +++ ofbiz/branches/20111205EmailHandling/applications/order/webapp/ordermgr/order/orderinfo.ftl Mon Mar 26 20:56:02 2012 @@ -26,8 +26,8 @@ under the License. <#assign orderType = orderHeader.getRelatedOne("OrderType")/> <li class="h3"> ${orderType?if_exists.get("description", locale)?default(uiLabelMap.OrderOrder)} ${uiLabelMap.CommonNbr} <a href="<@ofbizUrl>orderview?orderId=${orderId}</@ofbizUrl>">${orderId}</a> ${externalOrder?if_exists} [ <a href="<@ofbizUrl>order.pdf?orderId=${orderId}</@ofbizUrl>" target="_blank">PDF</a> ]</li> <#if currentStatus.statusId == "ORDER_APPROVED" && orderHeader.orderTypeId == "SALES_ORDER"> - <li class="h3"><a target="_BLANK" href="javascript:document.PrintOrderPickSheet.submit()">${uiLabelMap.FormFieldTitle_printPickSheet}</a> - <form name="PrintOrderPickSheet" method="post" action="<@ofbizUrl>orderPickSheet.pdf</@ofbizUrl>"> + <li class="h3"><a href="javascript:document.PrintOrderPickSheet.submit()">${uiLabelMap.FormFieldTitle_printPickSheet}</a> + <form name="PrintOrderPickSheet" method="post" action="<@ofbizUrl>orderPickSheet.pdf</@ofbizUrl>" target="_BLANK"> <input type="hidden" name="facilityId" value="${storeFacilityId?if_exists}"/> <input type="hidden" name="orderId" value="${orderHeader.orderId?if_exists}"/> <input type="hidden" name="maxNumberOfOrdersToPrint" value="1"/> Modified: ofbiz/branches/20111205EmailHandling/applications/order/webapp/ordermgr/order/orderitems.ftl URL: http://svn.apache.org/viewvc/ofbiz/branches/20111205EmailHandling/applications/order/webapp/ordermgr/order/orderitems.ftl?rev=1305581&r1=1305580&r2=1305581&view=diff ============================================================================== --- ofbiz/branches/20111205EmailHandling/applications/order/webapp/ordermgr/order/orderitems.ftl (original) +++ ofbiz/branches/20111205EmailHandling/applications/order/webapp/ordermgr/order/orderitems.ftl Mon Mar 26 20:56:02 2012 @@ -69,8 +69,24 @@ under the License. <#else> ${orderItem.itemDescription?if_exists} </#if> + <#assign orderItemAttributes = orderItem.getRelated("OrderItemAttribute")/> + <#if orderItemAttributes?has_content> + <ul> + <#list orderItemAttributes as orderItemAttribute> + <li> + ${orderItemAttribute.attrName} : ${orderItemAttribute.attrValue} + </li> + </#list> + </ul> + </#if> </div> <div style="float:right;"> + <#assign downloadContents = delegator.findByAnd("OrderItemAndProductContentInfo", {"orderId" : orderId, "orderItemSeqId" : orderItem.orderItemSeqId, "productContentTypeId" : "DIGITAL_DOWNLOAD", "statusId" : "ITEM_COMPLETED"})/> + <#if downloadContents?has_content> + <#list downloadContents as downloadContent> + <a href="/content/control/ViewSimpleContent?contentId=${downloadContent.contentId}" class="buttontext" target="_blank">${uiLabelMap.ContentDownload}</a> + </#list> + </#if> <a href="/catalog/control/EditProduct?productId=${productId}${externalKeyParam}" class="buttontext" target="_blank">${uiLabelMap.ProductCatalog}</a> <a href="/ecommerce/control/product?product_id=${productId}" class="buttontext" target="_blank">${uiLabelMap.OrderEcommerce}</a> <#if orderItemContentWrapper.get("IMAGE_URL")?has_content> @@ -171,7 +187,7 @@ under the License. <div class="current-status"> <span class="label">${uiLabelMap.CommonCurrent}</span> ${currentItemStatus.get("description",locale)?default(currentItemStatus.statusId)} </div> - <#if ("ITEM_CREATED" == (currentItemStatus.statusId) && "ORDER_APPROVED" == (orderHeader.statusId)) && (security.hasEntityPermission("ORDERMGR", "_UPDATE", session) || security.hasRolePermission("ORDERMGR", "_UPDATE", "", "", session))> + <#if ("ITEM_CREATED" == (currentItemStatus.statusId) && "ORDER_APPROVED" == (orderHeader.statusId)) && security.hasEntityPermission("ORDERMGR", "_UPDATE", session)> <div> <a href="javascript:document.OrderApproveOrderItem_${orderItem.orderItemSeqId?default("")}.submit()" class="buttontext">${uiLabelMap.OrderApproveOrder}</a> <form name="OrderApproveOrderItem_${orderItem.orderItemSeqId?default("")}" method="post" action="<@ofbizUrl>changeOrderItemStatus</@ofbizUrl>"> @@ -718,4 +734,3 @@ under the License. </div> </div> </#if> - Modified: ofbiz/branches/20111205EmailHandling/applications/order/webapp/ordermgr/order/orderlist.ftl URL: http://svn.apache.org/viewvc/ofbiz/branches/20111205EmailHandling/applications/order/webapp/ordermgr/order/orderlist.ftl?rev=1305581&r1=1305580&r2=1305581&view=diff ============================================================================== --- ofbiz/branches/20111205EmailHandling/applications/order/webapp/ordermgr/order/orderlist.ftl (original) +++ ofbiz/branches/20111205EmailHandling/applications/order/webapp/ordermgr/order/orderlist.ftl Mon Mar 26 20:56:02 2012 @@ -151,6 +151,7 @@ under the License. <tr class="header-row"> <td width="15%">${uiLabelMap.CommonDate}</td> <td width="10%">${uiLabelMap.OrderOrder} ${uiLabelMap.CommonNbr}</td> + <td width="10%">${uiLabelMap.OrderOrderName}</td> <td width="10%">${uiLabelMap.OrderOrderType}</td> <td width="10%">${uiLabelMap.OrderOrderBillFromParty}</td> <td width="10%">${uiLabelMap.OrderOrderBillToParty}</td> @@ -187,6 +188,7 @@ under the License. <td> <a href="<@ofbizUrl>orderview?orderId=${orderHeader.orderId}</@ofbizUrl>" class="buttontext">${orderHeader.orderId}</a> </td> + <td>${orderHeader.orderName?if_exists}</td> <td>${orderHeader.getRelatedOneCache("OrderType").get("description",locale)}</td> <td>${billFrom?if_exists}</td> <td>${billTo?if_exists}</td> Modified: ofbiz/branches/20111205EmailHandling/applications/order/webapp/ordermgr/order/orderpaymentinfo.ftl URL: http://svn.apache.org/viewvc/ofbiz/branches/20111205EmailHandling/applications/order/webapp/ordermgr/order/orderpaymentinfo.ftl?rev=1305581&r1=1305580&r2=1305581&view=diff ============================================================================== --- ofbiz/branches/20111205EmailHandling/applications/order/webapp/ordermgr/order/orderpaymentinfo.ftl (original) +++ ofbiz/branches/20111205EmailHandling/applications/order/webapp/ordermgr/order/orderpaymentinfo.ftl Mon Mar 26 20:56:02 2012 @@ -336,7 +336,7 @@ under the License. <#if creditCard?has_content> <#if creditCard.companyNameOnCard?exists>${creditCard.companyNameOnCard}<br /></#if> <#if creditCard.titleOnCard?has_content>${creditCard.titleOnCard} </#if> - ${creditCard.firstNameOnCard} + ${creditCard.firstNameOnCard?default("N/A")} <#if creditCard.middleNameOnCard?has_content>${creditCard.middleNameOnCard} </#if> ${creditCard.lastNameOnCard?default("N/A")} <#if creditCard.suffixOnCard?has_content> ${creditCard.suffixOnCard}</#if> Modified: ofbiz/branches/20111205EmailHandling/applications/order/webapp/ordermgr/order/ordershippinginfo.ftl URL: http://svn.apache.org/viewvc/ofbiz/branches/20111205EmailHandling/applications/order/webapp/ordermgr/order/ordershippinginfo.ftl?rev=1305581&r1=1305580&r2=1305581&view=diff ============================================================================== --- ofbiz/branches/20111205EmailHandling/applications/order/webapp/ordermgr/order/ordershippinginfo.ftl (original) +++ ofbiz/branches/20111205EmailHandling/applications/order/webapp/ordermgr/order/ordershippinginfo.ftl Mon Mar 26 20:56:02 2012 @@ -18,37 +18,37 @@ under the License. --> <script language="JavaScript" type="text/javascript"> - function editInstruction() { - jQuery('#shippingInstructions').css({display:'block'}); - jQuery('#saveInstruction').css({display:'inline'}); - jQuery('#editInstruction').css({display:'none'}); - jQuery('#instruction').css({display:'none'}); + function editInstruction(shipGroupSeqId) { + jQuery('#shippingInstructions_' + shipGroupSeqId).css({display:'block'}); + jQuery('#saveInstruction_' + shipGroupSeqId).css({display:'inline'}); + jQuery('#editInstruction_' + shipGroupSeqId).css({display:'none'}); + jQuery('#instruction_' + shipGroupSeqId).css({display:'none'}); } - function addInstruction() { - jQuery('#shippingInstructions').css({display:'block'}); - jQuery('#saveInstruction').css({display:'inline'}); - jQuery('#addInstruction').css({display:'none'}); + function addInstruction(shipGroupSeqId) { + jQuery('#shippingInstructions_' + shipGroupSeqId).css({display:'block'}); + jQuery('#saveInstruction_' + shipGroupSeqId).css({display:'inline'}); + jQuery('#addInstruction_' + shipGroupSeqId).css({display:'none'}); } - function saveInstruction() { - document.updateShippingInstructionsForm.submit(); + function saveInstruction(shipGroupSeqId) { + jQuery("#updateShippingInstructionsForm_" + shipGroupSeqId).submit(); } - function editGiftMessage() { - jQuery('#giftMessage').css({display:'block'}); - jQuery('#saveGiftMessage').css({display:'inline'}); - jQuery('#editGiftMessage').css({display:'none'}); - jQuery('#message').css({display:'none'}); + function editGiftMessage(shipGroupSeqId) { + jQuery('#giftMessage_' + shipGroupSeqId).css({display:'block'}); + jQuery('#saveGiftMessage_' + shipGroupSeqId).css({display:'inline'}); + jQuery('#editGiftMessage_' + shipGroupSeqId).css({display:'none'}); + jQuery('#message_' + shipGroupSeqId).css({display:'none'}); } - function addGiftMessage() { - jQuery('#giftMessage').css({display:'block'}); - jQuery('#saveGiftMessage').css({display:'inline'}); - jQuery('#addGiftMessage').css({display:'none'}); + function addGiftMessage(shipGroupSeqId) { + jQuery('#giftMessage_' + shipGroupSeqId).css({display:'block'}); + jQuery('#saveGiftMessage_' + shipGroupSeqId).css({display:'inline'}); + jQuery('#addGiftMessage_' + shipGroupSeqId).css({display:'none'}); } - function saveGiftMessage() { - document.setGiftMessageForm.submit(); + function saveGiftMessage(shipGroupSeqId) { + jQuery("#setGiftMessageForm_" + shipGroupSeqId).submit(); } </script> -<#if (security.hasEntityPermission("ORDERMGR", "_UPDATE", session) || security.hasRolePermission("ORDERMGR", "_UPDATE", "", "", session)) && (!orderHeader.salesChannelEnumId?exists || orderHeader.salesChannelEnumId != "POS_SALES_CHANNEL")> +<#if security.hasEntityPermission("ORDERMGR", "_UPDATE", session) && (!orderHeader.salesChannelEnumId?exists || orderHeader.salesChannelEnumId != "POS_SALES_CHANNEL")> <div class="screenlet"> <div class="screenlet-title-bar"> <ul><li class="h3"> ${uiLabelMap.OrderActions}</li></ul> @@ -264,10 +264,12 @@ under the License. </#list> </select> <#else> - <#if shipGroup.carrierPartyId != "_NA_"> - ${shipGroup.carrierPartyId?if_exists} - </#if> - ${shipmentMethodType?if_exists.get("description",locale)?default("")} + <#if (shipGroup.carrierPartyId)?default("_NA_") != "_NA_"> + ${shipGroup.carrierPartyId?if_exists} + </#if> + <#if shipmentMethodType?has_content> + ${shipmentMethodType.get("description",locale)?default("")} + </#if> </#if> </div> </td> @@ -491,7 +493,7 @@ under the License. <td width="5"> </td> <td align="left" valign="top" width="80%"> <#if (!orderHeader.statusId.equals("ORDER_COMPLETED")) && !(orderHeader.statusId.equals("ORDER_REJECTED")) && !(orderHeader.statusId.equals("ORDER_CANCELLED"))> - <form name="updateShippingInstructionsForm" method="post" action="<@ofbizUrl>setShippingInstructions</@ofbizUrl>"> + <form id="updateShippingInstructionsForm_${shipGroup.shipGroupSeqId}" name="updateShippingInstructionsForm" method="post" action="<@ofbizUrl>setShippingInstructions</@ofbizUrl>"> <input type="hidden" name="orderId" value="${orderHeader.orderId}"/> <input type="hidden" name="shipGroupSeqId" value="${shipGroup.shipGroupSeqId}"/> <#if shipGroup.shippingInstructions?has_content> @@ -501,15 +503,15 @@ under the License. <label>${shipGroup.shippingInstructions}</label> </td> <td> - <a href="javascript:editInstruction();" class="buttontext" id="editInstruction">${uiLabelMap.CommonEdit}</a> + <a href="javascript:editInstruction('${shipGroup.shipGroupSeqId}');" class="buttontext" id="editInstruction_${shipGroup.shipGroupSeqId}">${uiLabelMap.CommonEdit}</a> </td> </tr> </table> <#else> - <a href="javascript:addInstruction();" class="buttontext" id="addInstruction">${uiLabelMap.CommonAdd}</a> + <a href="javascript:addInstruction('${shipGroup.shipGroupSeqId}');" class="buttontext" id="addInstruction_${shipGroup.shipGroupSeqId}">${uiLabelMap.CommonAdd}</a> </#if> - <a href="javascript:saveInstruction();" class="buttontext" id="saveInstruction" style="display:none">${uiLabelMap.CommonSave}</a> - <textarea name="shippingInstructions" id="shippingInstructions" style="display:none" rows="0" cols="0">${shipGroup.shippingInstructions?if_exists}</textarea> + <a href="javascript:saveInstruction('${shipGroup.shipGroupSeqId}');" class="buttontext" id="saveInstruction_${shipGroup.shipGroupSeqId}" style="display:none">${uiLabelMap.CommonSave}</a> + <textarea name="shippingInstructions" id="shippingInstructions_${shipGroup.shipGroupSeqId}" style="display:none" rows="0" cols="0">${shipGroup.shippingInstructions?if_exists}</textarea> </form> <#else> <#if shipGroup.shippingInstructions?has_content> @@ -529,17 +531,17 @@ under the License. </td> <td width="5"> </td> <td> - <form name="setGiftMessageForm" method="post" action="<@ofbizUrl>setGiftMessage</@ofbizUrl>"> + <form id="setGiftMessageForm_${shipGroup.shipGroupSeqId}" name="setGiftMessageForm" method="post" action="<@ofbizUrl>setGiftMessage</@ofbizUrl>"> <input type="hidden" name="orderId" value="${orderHeader.orderId}"/> <input type="hidden" name="shipGroupSeqId" value="${shipGroup.shipGroupSeqId}"/> <#if shipGroup.giftMessage?has_content> <label>${shipGroup.giftMessage}</label> - <a href="javascript:editGiftMessage();" class="buttontext" id="editGiftMessage">${uiLabelMap.CommonEdit}</a> + <a href="javascript:editGiftMessage('${shipGroup.shipGroupSeqId}');" class="buttontext" id="editGiftMessage_${shipGroup.shipGroupSeqId}">${uiLabelMap.CommonEdit}</a> <#else> - <a href="javascript:addGiftMessage();" class="buttontext" id="addGiftMessage">${uiLabelMap.CommonAdd}</a> + <a href="javascript:addGiftMessage('${shipGroup.shipGroupSeqId}');" class="buttontext" id="addGiftMessage_${shipGroup.shipGroupSeqId}">${uiLabelMap.CommonAdd}</a> </#if> - <textarea name="giftMessage" id="giftMessage" style="display:none" rows="0" cols="0">${shipGroup.giftMessage?if_exists}</textarea> - <a href="javascript:saveGiftMessage();" class="buttontext" id="saveGiftMessage" style="display:none">${uiLabelMap.CommonSave}</a> + <textarea name="giftMessage" id="giftMessage_${shipGroup.shipGroupSeqId}" style="display:none" rows="0" cols="0">${shipGroup.giftMessage?if_exists}</textarea> + <a href="javascript:saveGiftMessage('${shipGroup.shipGroupSeqId}');" class="buttontext" id="saveGiftMessage_${shipGroup.shipGroupSeqId}" style="display:none">${uiLabelMap.CommonSave}</a> </form> </td> </tr> Modified: ofbiz/branches/20111205EmailHandling/applications/order/webapp/ordermgr/order/orderstats.ftl URL: http://svn.apache.org/viewvc/ofbiz/branches/20111205EmailHandling/applications/order/webapp/ordermgr/order/orderstats.ftl?rev=1305581&r1=1305580&r2=1305581&view=diff ============================================================================== --- ofbiz/branches/20111205EmailHandling/applications/order/webapp/ordermgr/order/orderstats.ftl (original) +++ ofbiz/branches/20111205EmailHandling/applications/order/webapp/ordermgr/order/orderstats.ftl Mon Mar 26 20:56:02 2012 @@ -17,7 +17,7 @@ specific language governing permissions under the License. --> -<#if security.hasRolePermission("ORDERMGR", "_VIEW", "", "", session)> +<#if security.hasEntityPermission("ORDERMGR", "_VIEW", session)> <div class="screenlet"> <div class="screenlet-title-bar"> <h3>${uiLabelMap.OrderOrderStatisticsPage}</h3> Modified: ofbiz/branches/20111205EmailHandling/applications/order/webapp/ordermgr/return/returnLinks.ftl URL: http://svn.apache.org/viewvc/ofbiz/branches/20111205EmailHandling/applications/order/webapp/ordermgr/return/returnLinks.ftl?rev=1305581&r1=1305580&r2=1305581&view=diff ============================================================================== --- ofbiz/branches/20111205EmailHandling/applications/order/webapp/ordermgr/return/returnLinks.ftl (original) +++ ofbiz/branches/20111205EmailHandling/applications/order/webapp/ordermgr/return/returnLinks.ftl Mon Mar 26 20:56:02 2012 @@ -20,15 +20,22 @@ under the License. <#if returnHeader?exists> <div class="button-bar tab-bar"> <ul> + <li> + <ul> <li<#if selected="OrderReturnHeader"> class="selected"</#if>><a href="<@ofbizUrl>returnMain?returnId=${returnId?if_exists}</@ofbizUrl>">${uiLabelMap.OrderReturnHeader}</a></li> <li<#if selected="OrderReturnItems"> class="selected"</#if>><a href="<@ofbizUrl>returnItems?returnId=${returnId?if_exists}</@ofbizUrl>">${uiLabelMap.OrderReturnItems}</a></li> <li<#if selected="OrderReturnHistory"> class="selected"</#if>><a href="<@ofbizUrl>ReturnHistory?returnId=${returnId?if_exists}</@ofbizUrl>">${uiLabelMap.OrderReturnHistory}</a></li> </ul> + </li> + </ul> <br /> </div> - <div> - <#if selected != "OrderReturnHistory"> - <a href="<@ofbizUrl>return.pdf?returnId=${returnId?if_exists}</@ofbizUrl>" class="buttontext">PDF</a> + <#if selected != "OrderReturnHistory"> + <div class="button-bar button-style-1"> + <ul> + <li> + <ul> + <li><a href="<@ofbizUrl>return.pdf?returnId=${returnId?if_exists}</@ofbizUrl>">PDF</a></li> <#if returnId?exists> <#assign returnItems = delegator.findByAnd("ReturnItem", Static["org.ofbiz.base.util.UtilMisc"].toMap("returnId", returnId, "returnTypeId", "RTN_REFUND"))/> <#if returnItems?has_content> @@ -48,12 +55,12 @@ under the License. <#assign shipmentRouteSegment = Static["org.ofbiz.entity.util.EntityUtil"].getFirst(delegator.findByAnd("ShipmentRouteSegment", {"shipmentId" : shipGroupShipment.shipmentId}))> <#if shipmentRouteSegment?exists> <#if "UPS" == shipmentRouteSegment.carrierPartyId> - <a href="javascript:document.upsEmailReturnLabel.submit();" class="buttontext">${uiLabelMap.ProductEmailReturnShippingLabelUPS}</a> - <form name="upsEmailReturnLabel" method="post" action="<@ofbizUrl>upsEmailReturnLabelReturn</@ofbizUrl>"> + <li><a href="javascript:document.upsEmailReturnLabel.submit();" class="buttontext">${uiLabelMap.ProductEmailReturnShippingLabelUPS}</a></li> + <li><form name="upsEmailReturnLabel" method="post" action="<@ofbizUrl>upsEmailReturnLabelReturn</@ofbizUrl>"> <input type="hidden" name="returnId" value="${returnId}"/> <input type="hidden" name="shipmentId" value="${shipGroupShipment.shipmentId}"/> <input type="hidden" name="shipmentRouteSegmentId" value="${shipmentRouteSegment.shipmentRouteSegmentId}" /> - </form> + </form></li> </#if> </#if> </#if> @@ -61,8 +68,11 @@ under the License. </#if> </#if> </#if> - </#if> - </div> + </ul> + </li> + </ul> + </div> + </#if> <#else> <h1>${uiLabelMap.OrderCreateNewReturn}</h1> <#if requestParameters.returnId?has_content> Modified: ofbiz/branches/20111205EmailHandling/applications/order/webapp/ordermgr/task/ordertasklist.ftl URL: http://svn.apache.org/viewvc/ofbiz/branches/20111205EmailHandling/applications/order/webapp/ordermgr/task/ordertasklist.ftl?rev=1305581&r1=1305580&r2=1305581&view=diff ============================================================================== --- ofbiz/branches/20111205EmailHandling/applications/order/webapp/ordermgr/task/ordertasklist.ftl (original) +++ ofbiz/branches/20111205EmailHandling/applications/order/webapp/ordermgr/task/ordertasklist.ftl Mon Mar 26 20:56:02 2012 @@ -38,7 +38,7 @@ under the License. // --> </script> -<#if security.hasRolePermission("ORDERMGR", "_VIEW", "", "", session) || security.hasRolePermission("ORDERMGR_ROLE", "_VIEW", "", "", session)> +<#if security.hasEntityPermission("ORDERMGR", "_VIEW", session)> <#assign tasksFound = false> <div class="screenlet"> <div class="screenlet-title-bar"> Modified: ofbiz/branches/20111205EmailHandling/applications/order/widget/ordermgr/CustRequestForms.xml URL: http://svn.apache.org/viewvc/ofbiz/branches/20111205EmailHandling/applications/order/widget/ordermgr/CustRequestForms.xml?rev=1305581&r1=1305580&r2=1305581&view=diff ============================================================================== --- ofbiz/branches/20111205EmailHandling/applications/order/widget/ordermgr/CustRequestForms.xml (original) +++ ofbiz/branches/20111205EmailHandling/applications/order/widget/ordermgr/CustRequestForms.xml Mon Mar 26 20:56:02 2012 @@ -721,4 +721,28 @@ under the License. <sort-field name="submit"/> </sort-order> </form> + <form name="EditCustRetStatusId" extends="CommonPortletEdit" extends-resource="component://common/widget/PortletEditForms.xml"> + <field name="statusId" entry-name="attributeMap.statusId"> + <drop-down> + <entity-options description="${description}" entity-name="StatusItem" key-field-name="statusId"> + <entity-constraint name="statusTypeId" operator="equals" value="ORDER_RETURN_STTS"/> + <entity-order-by field-name="description"/> + </entity-options> + </drop-down> + </field> + <field name="saveButton"><submit/></field> + </form> + <form name="ListReturns" type="list" title="" list-name="listIt" + odd-row-style="alternate-row" default-table-style="basic-table hover-bar"> + <actions> + <entity-and entity-name="ReturnHeader"> + <field-map field-name="fromPartyId" from-field="partyId"/> + <field-map field-name="statusId" from-field="statusId"/> + </entity-and> + </actions> + <field name="returnId" title="${uiLabelMap.OrderReturnId}"><display/></field> + <field name="entryDate" title="${uiLabelMap.OrderEntryDate}"><display/></field> + <field name="destinationFacilityId" title="${uiLabelMap.OrderReturnDestinationFacility}"><display/></field> + <field name="statusId"><display/></field> + </form> </forms> Modified: ofbiz/branches/20111205EmailHandling/applications/order/widget/ordermgr/CustRequestScreens.xml URL: http://svn.apache.org/viewvc/ofbiz/branches/20111205EmailHandling/applications/order/widget/ordermgr/CustRequestScreens.xml?rev=1305581&r1=1305580&r2=1305581&view=diff ============================================================================== --- ofbiz/branches/20111205EmailHandling/applications/order/widget/ordermgr/CustRequestScreens.xml (original) +++ ofbiz/branches/20111205EmailHandling/applications/order/widget/ordermgr/CustRequestScreens.xml Mon Mar 26 20:56:02 2012 @@ -75,9 +75,17 @@ under the License. <entity-and entity-name="CustRequestContent" list="custRequestContents" filter-by-date="true"> <field-map field-name="custRequestId" from-field="custRequestId"/> </entity-and> - <entity-and entity-name="CustRequestAndContent" list="custRequestAndContents"> - <field-map field-name="custRequestId" from-field="custRequestId"/> - </entity-and> + <entity-condition entity-name="CustRequestAndContent" list="custRequestAndContents"> + <condition-list combine="and"> + <condition-expr field-name="custRequestId" from-field="custRequestId"/> + <condition-expr field-name="fromDate" operator="less-equals" from-field="nowTimestamp"/> + <condition-list combine="or"> + <condition-expr field-name="thruDate" operator="greater-equals" from-field="nowTimestamp"/> + <condition-expr field-name="thruDate" from-field="null"/> + </condition-list> + </condition-list> + <order-by field-name="fromDate"/> + </entity-condition> <entity-and entity-name="CustRequestItemNoteView" list="notes"> <field-map field-name="custRequestId" from-field="custRequestId"/> </entity-and> @@ -476,9 +484,17 @@ under the License. <set field="tabButtonItem" value="custRequestContent"/> <set field="headerItem" value="request"/> <set field="custRequestId" from-field="parameters.custRequestId"/> - <entity-and entity-name="CustRequestAndContent" list="custRequestAndContents"> - <field-map field-name="custRequestId" from-field="custRequestId"/> - </entity-and> + <entity-condition entity-name="CustRequestAndContent" list="custRequestAndContents"> + <condition-list combine="and"> + <condition-expr field-name="custRequestId" from-field="custRequestId"/> + <condition-expr field-name="fromDate" operator="less-equals" from-field="nowTimestamp"/> + <condition-list combine="or"> + <condition-expr field-name="thruDate" operator="greater-equals" from-field="nowTimestamp"/> + <condition-expr field-name="thruDate" from-field="null"/> + </condition-list> + </condition-list> + <order-by field-name="fromDate"/> + </entity-condition> </actions> <widgets> <decorator-screen name="CommonRequestDecorator" location="${parameters.mainDecoratorLocation}"> @@ -701,5 +717,21 @@ under the License. </fail-widgets> </section> </screen> - + + <screen name="ListCustReturns"> + <section> + <actions> + <set field="partyId" from-field="userLogin.partyId"/> + <set field="screenletTitle" from-field="uiLabelMap.OrderMyReturns"/> + <entity-one entity-name="StatusItem" value-field="statusItem"> + <field-map field-name="statusId" from-field="statusId"/> + </entity-one> + </actions> + <widgets> + <screenlet title="${screenletTitle} (${statusItem.description})" navigation-form-name="ListCustReturns" > + <include-form name="ListReturns" location="component://order/widget/ordermgr/CustRequestForms.xml"/> + </screenlet> + </widgets> + </section> + </screen> </screens> Modified: ofbiz/branches/20111205EmailHandling/applications/order/widget/ordermgr/LookupScreens.xml URL: http://svn.apache.org/viewvc/ofbiz/branches/20111205EmailHandling/applications/order/widget/ordermgr/LookupScreens.xml?rev=1305581&r1=1305580&r2=1305581&view=diff ============================================================================== --- ofbiz/branches/20111205EmailHandling/applications/order/widget/ordermgr/LookupScreens.xml (original) +++ ofbiz/branches/20111205EmailHandling/applications/order/widget/ordermgr/LookupScreens.xml Mon Mar 26 20:56:02 2012 @@ -89,6 +89,7 @@ under the License. <set field="viewSize" from-field="parameters.VIEW_SIZE" type="Integer" default-value="20"/> <set field="entityName" value="OrderHeaderAndShipGroups"/> <set field="searchFields" value="[orderId, orderName, toName]"/> + <set field="andCondition" value="${groovy: return org.ofbiz.entity.condition.EntityCondition.makeCondition(org.ofbiz.base.util.UtilMisc.toMap('orderTypeId', 'PURCHASE_ORDER', 'roleTypeId', 'SHIP_FROM_VENDOR'))}"/> </actions> <widgets> <decorator-screen name="LookupDecorator" location="component://common/widget/CommonScreens.xml"> Modified: ofbiz/branches/20111205EmailHandling/applications/order/widget/ordermgr/OrderEntryForms.xml URL: http://svn.apache.org/viewvc/ofbiz/branches/20111205EmailHandling/applications/order/widget/ordermgr/OrderEntryForms.xml?rev=1305581&r1=1305580&r2=1305581&view=diff ============================================================================== --- ofbiz/branches/20111205EmailHandling/applications/order/widget/ordermgr/OrderEntryForms.xml (original) +++ ofbiz/branches/20111205EmailHandling/applications/order/widget/ordermgr/OrderEntryForms.xml Mon Mar 26 20:56:02 2012 @@ -151,6 +151,11 @@ under the License. <form name="LookupBulkAddProducts" type="multi" use-row-submit="true" list-name="productList" title="" target="BulkAddProducts" odd-row-style="alternate-row" default-table-style="basic-table hover-bar" paginate-target="LookupBulkAddProducts"> + <row-actions> + <entity-one entity-name="Product" value-field="product" auto-field-map="true"/> + <set field=""/> + <set field="hasAmount" value="${groovy:product.getString('requireAmount')?:'N'}"/> + </row-actions> <field name="productId" title="${uiLabelMap.ProductProductId}" widget-style="buttontext"> <hyperlink description="${productId}" target="/catalog/control/EditProductInventoryItems" target-type="inter-app"> <parameter param-name="productId"/> @@ -161,9 +166,12 @@ under the License. <field name="quantity" title="${uiLabelMap.OrderQuantity}"> <text size="5" maxlength="10"/> </field> - <field name="amount" title="${uiLabelMap.OrderAmount}"> + <field use-when="${groovy: 'Y'.equals(context.hasAmount)}" name="amount" title="${uiLabelMap.OrderAmount}" > <text size="5" maxlength="10"/> </field> + <field use-when="${groovy: 'N'.equals(context.hasAmount)}" name="amount" title="${uiLabelMap.OrderAmount}" widget-style="disabled"> + <text size="5" maxlength="10" disabled="true"/> + </field> <field name="itemDesiredDeliveryDate" title="${uiLabelMap.OrderDesiredDeliveryDate}"> <date-time/> </field> Modified: ofbiz/branches/20111205EmailHandling/applications/party/config/PartyEntityLabels.xml URL: http://svn.apache.org/viewvc/ofbiz/branches/20111205EmailHandling/applications/party/config/PartyEntityLabels.xml?rev=1305581&r1=1305580&r2=1305581&view=diff ============================================================================== --- ofbiz/branches/20111205EmailHandling/applications/party/config/PartyEntityLabels.xml (original) +++ ofbiz/branches/20111205EmailHandling/applications/party/config/PartyEntityLabels.xml Mon Mar 26 20:56:02 2012 @@ -1273,7 +1273,7 @@ <value xml:lang="fr">Contact</value> <value xml:lang="hi_IN">सà¤à¤ªà¤°à¥à¤</value> <value xml:lang="it">Contatto</value> - <value xml:lang="nl">Contact</value> + <value xml:lang="nl">Contact</value> <value xml:lang="pt_BR">Contato</value> <value xml:lang="ro">Contact</value> <value xml:lang="ru">ÐонÑакÑ</value> @@ -2114,7 +2114,7 @@ <value xml:lang="fr">Contact</value> <value xml:lang="hi_IN">सà¤à¤ªà¤°à¥à¤</value> <value xml:lang="it">Contatto</value> - <value xml:lang="nl">Contact</value> + <value xml:lang="nl">Contact</value> <value xml:lang="pt_BR">Contato</value> <value xml:lang="ro">Contat</value> <value xml:lang="ru">ÐонÑакÑ</value> Modified: ofbiz/branches/20111205EmailHandling/applications/party/config/PartyUiLabels.xml URL: http://svn.apache.org/viewvc/ofbiz/branches/20111205EmailHandling/applications/party/config/PartyUiLabels.xml?rev=1305581&r1=1305580&r2=1305581&view=diff ============================================================================== --- ofbiz/branches/20111205EmailHandling/applications/party/config/PartyUiLabels.xml (original) +++ ofbiz/branches/20111205EmailHandling/applications/party/config/PartyUiLabels.xml Mon Mar 26 20:56:02 2012 @@ -1196,6 +1196,9 @@ <value xml:lang="zh">称è°</value> <value xml:lang="zh_TW">稱è¬</value> </property> + <property key="FormFieldTitle_personalImage"> + <value xml:lang="en">Personal Image</value> + </property> <property key="FormFieldTitle_preferredContactMechId"> <value xml:lang="de">Bevorzugter Kontaktmechanismus ID</value> <value xml:lang="en">Preferred Contact Mech Id</value> @@ -7795,6 +7798,7 @@ <property key="PartyNoProductStoreFoundForThisParty"> <value xml:lang="de">Kein Laden für diesen Akteur gefunden.</value> <value xml:lang="en">No product store(s) found for this party.</value> + <value xml:lang="fr">Aucun centre de profit trouvé pour cet acteur</value> <value xml:lang="zh_TW">æ¤æå¡æ²æç¢åååºã</value> </property> <property key="PartyNoServerHitsFound"> Modified: ofbiz/branches/20111205EmailHandling/applications/party/data/PartyDemoData.xml URL: http://svn.apache.org/viewvc/ofbiz/branches/20111205EmailHandling/applications/party/data/PartyDemoData.xml?rev=1305581&r1=1305580&r2=1305581&view=diff ============================================================================== --- ofbiz/branches/20111205EmailHandling/applications/party/data/PartyDemoData.xml (original) +++ ofbiz/branches/20111205EmailHandling/applications/party/data/PartyDemoData.xml Mon Mar 26 20:56:02 2012 @@ -24,7 +24,6 @@ <Party partyId="Company"/> <Party partyId="DemoEmployee"/> <PartyRole partyId="admin" roleTypeId="EMAIL_ADMIN"/> - <PartyRole partyId="admin" roleTypeId="IMAGEAPPROVER"/> <PartyRole partyId="Company" roleTypeId="_NA_"/> <PartyRelationship partyIdFrom="admin" roleTypeIdFrom="EMAIL_ADMIN" partyIdTo="Company" roleTypeIdTo="_NA_" fromDate="2000-01-01 00:00:00"/> <PartyRole partyId="DemoEmployee" roleTypeId="EMAIL_ADMIN"/> @@ -48,9 +47,9 @@ <!-- new registration notification --> <EmailTemplateSetting emailTemplateSettingId="PARTY_REGISTER" bodyScreenLocation="component://party/widget/partymgr/PartyScreens.xml#CreateUserNotification" subject="New Account Created" bccAddress="[hidden email]" fromAddress="[hidden email]"/> - <!-- make admin an employee of Company --> + <!-- make admin an employee of Company --> <PartyRole partyId="admin" roleTypeId="CONTACT"/> <PartyRole partyId="Company" roleTypeId="ACCOUNT"/> <PartyRelationship partyIdFrom="Company" roleTypeIdFrom="ACCOUNT" partyIdTo="admin" roleTypeIdTo="CONTACT" fromDate="2000-01-01 00:00:00.000" partyRelationshipTypeId="EMPLOYMENT"/> - + </entity-engine-xml> Modified: ofbiz/branches/20111205EmailHandling/applications/party/entitydef/entitymodel.xml URL: http://svn.apache.org/viewvc/ofbiz/branches/20111205EmailHandling/applications/party/entitydef/entitymodel.xml?rev=1305581&r1=1305580&r2=1305581&view=diff ============================================================================== --- ofbiz/branches/20111205EmailHandling/applications/party/entitydef/entitymodel.xml (original) +++ ofbiz/branches/20111205EmailHandling/applications/party/entitydef/entitymodel.xml Mon Mar 26 20:56:02 2012 @@ -1352,48 +1352,20 @@ under the License. </relation> </view-entity> <view-entity entity-name="PartyAndTelecomNumber" - package-name="org.ofbiz.party.contact" - title="Party and Contact Mech/Postal Address View Entity"> - <member-entity entity-alias="PTY" entity-name="Party"/> - <member-entity entity-alias="PCM" entity-name="PartyContactMech"/> - <member-entity entity-alias="CM" entity-name="ContactMech"/> - <member-entity entity-alias="TN" entity-name="TelecomNumber"/> - <alias entity-alias="CM" name="contactMechId"/> - <alias entity-alias="PTY" name="partyId"/> - <alias entity-alias="PTY" name="statusId"/> - <alias entity-alias="PCM" name="fromDate"/> - <alias entity-alias="PCM" name="thruDate"/> - <alias entity-alias="PTY" name="partyTypeId"/> - <alias entity-alias="CM" name="contactMechTypeId"/> - <alias entity-alias="CM" name="infoString"/> - <alias entity-alias="PCM" name="comments"/> - <alias entity-alias="PCM" name="extension"/> - <alias entity-alias="PCM" name="allowSolicitation"/> - <alias entity-alias="TN" name="countryCode"/> - <alias entity-alias="TN" name="areaCode"/> - <alias entity-alias="TN" name="contactNumber"/> + package-name="org.ofbiz.party.contact" + title="Party and TelecomNumber View Entity"> + <member-entity entity-alias="PTY" entity-name="Party" /> + <member-entity entity-alias="PCM" entity-name="PartyContactMech" /> + <member-entity entity-alias="TN" entity-name="TelecomNumber" /> + <alias-all entity-alias="PTY" /> + <alias-all entity-alias="PCM" /> + <alias-all entity-alias="TN" /> <view-link entity-alias="PTY" rel-entity-alias="PCM"> - <key-map field-name="partyId"/> + <key-map field-name="partyId" /> </view-link> - <view-link entity-alias="PCM" rel-entity-alias="CM"> - <key-map field-name="contactMechId"/> + <view-link entity-alias="PCM" rel-entity-alias="TN"> + <key-map field-name="contactMechId" /> </view-link> - <view-link entity-alias="CM" rel-entity-alias="TN"> - <key-map field-name="contactMechId"/> - </view-link> - <relation type="many" rel-entity-name="PartyContactMech"> - <key-map field-name="partyId"/> - <key-map field-name="contactMechId"/> - </relation> - <relation type="one-nofk" rel-entity-name="Party"> - <key-map field-name="partyId"/> - </relation> - <relation type="one-nofk" rel-entity-name="ContactMech"> - <key-map field-name="contactMechId"/> - </relation> - <relation type="one-nofk" rel-entity-name="TelecomNumber"> - <key-map field-name="contactMechId"/> - </relation> </view-entity> <view-entity entity-name="ContactListPartyAndContactMech" package-name="org.ofbiz.party.contact"> Modified: ofbiz/branches/20111205EmailHandling/applications/party/ofbiz-component.xml URL: http://svn.apache.org/viewvc/ofbiz/branches/20111205EmailHandling/applications/party/ofbiz-component.xml?rev=1305581&r1=1305580&r2=1305581&view=diff ============================================================================== --- ofbiz/branches/20111205EmailHandling/applications/party/ofbiz-component.xml (original) +++ ofbiz/branches/20111205EmailHandling/applications/party/ofbiz-component.xml Mon Mar 26 20:56:02 2012 @@ -43,6 +43,7 @@ under the License. <webapp name="party" title="Party" + description="PartyComponentDescription" server="default-server" location="webapp/partymgr" base-permission="OFBTOOLS,PARTYMGR" Modified: ofbiz/branches/20111205EmailHandling/applications/party/script/org/ofbiz/party/contact/PartyContactMechServices.xml URL: http://svn.apache.org/viewvc/ofbiz/branches/20111205EmailHandling/applications/party/script/org/ofbiz/party/contact/PartyContactMechServices.xml?rev=1305581&r1=1305580&r2=1305581&view=diff ============================================================================== --- ofbiz/branches/20111205EmailHandling/applications/party/script/org/ofbiz/party/contact/PartyContactMechServices.xml (original) +++ ofbiz/branches/20111205EmailHandling/applications/party/script/org/ofbiz/party/contact/PartyContactMechServices.xml Mon Mar 26 20:56:02 2012 @@ -318,29 +318,23 @@ under the License. <simple-method method-name="findPartyFromEmailAddress" short-description="Find partyId from email address"> <set field="input.filterByDate" value="Y"/> <set field="input.inputFields.infoString" from-field="parameters.address"/> - <if-empty field="parameters.caseInsensitive"> - <call-bsh><![CDATA[ - String caseInsensitiveEmail = org.ofbiz.base.util.UtilProperties.getPropertyValue("general.properties", "mail.address.caseInsensitive", "N"); - parameters.put("caseInsensitive", caseInsensitiveEmail); - ]]></call-bsh> + <set field="caseInsensitive" from-field="parameters.caseInsensitive"/> + <if-empty field="caseInsensitive"> + <property-to-field resource="general.properties" property="mail.address.caseInsensitive" field="caseInsensitive" default="N"/> </if-empty> - <set field="input.inputFields.infoString_ic" from-field="parameters.caseInsensitive"/> - <log level="info" message="findPartyFromEmailAddress with case insensitive search: ${parameters.caseInsensitive}"/> - + <set field="input.inputFields.infoString_ic" from-field="caseInsensitive"/> <if-empty field="parameters.fromDate"> <set field="input.filterByDate" value="Y"/> <else> <set field="input.filterByDateValue" from-field="parameters.fromDate"/> </else> </if-empty> - <!-- try primary email address --> <set field="input.inputFields.contactMechPurposeTypeId" value="PRIMARY_EMAIL"/> <set field="input.entityName" value="PartyContactDetailByPurpose"/> <call-service service-name="performFindItem" in-map-name="input"> <results-to-map map-name="results"/> </call-service> - <!-- any other email address --> <if-empty field="results.item"> <set field="input.entityName" value="PartyAndContactMech"/> @@ -349,12 +343,10 @@ under the License. <results-to-map map-name="results"/> </call-service> </if-empty> - <if-not-empty field="results.item"> <field-to-result field="results.item.partyId" result-name="partyId"/> <field-to-result field="results.item.contactMechId" result-name="contactMechId"/> </if-not-empty> - </simple-method> <simple-method method-name="findPartyFromTelephone" short-description="Find partyId from the telephone number"> Modified: ofbiz/branches/20111205EmailHandling/applications/party/servicedef/secas.xml URL: http://svn.apache.org/viewvc/ofbiz/branches/20111205EmailHandling/applications/party/servicedef/secas.xml?rev=1305581&r1=1305580&r2=1305581&view=diff ============================================================================== --- ofbiz/branches/20111205EmailHandling/applications/party/servicedef/secas.xml (original) +++ ofbiz/branches/20111205EmailHandling/applications/party/servicedef/secas.xml Mon Mar 26 20:56:02 2012 @@ -104,4 +104,75 @@ under the License. <eca service="createEmailAddressVerification" event="commit"> <action service="sendVerifyEmailAddressNotification" mode="async"/> </eca> + + <!-- send a note when a communicationevent is created for a certain loginId when an + existing comm event's status changes into status: entered--> + <eca service="updateCommunicationEvent" event="commit"> + <condition field-name="statusId" operator="equals" value="COM_ENTERED"/> + <condition field-name="communicationEventTypeId" operator="equals" value="AUTO_EMAIL_COM"/> + <condition field-name="partyIdTo" operator="is-not-empty"/> + <set field-name="noteParty" env-name="partyIdTo"/> + <set field-name="noteInfo" env-name="subject"/> + <set field-name="moreInfoItemName" value="communicationEventId"/> + <set field-name="moreInfoItemId" env-name="communicationEventId"/> + <set field-name="moreInfoUrl" value="/partymgr/control/MyCommunicationEvents"/> + <action service="createSystemInfoNote" mode="sync"/> + </eca> + <eca service="updateCommunicationEvent" event="commit"> + <condition field-name="statusId" operator="equals" value="COM_ENTERED"/> + <condition field-name="communicationEventTypeId" operator="equals" value="EMAIL_COMMUNICATION"/> + <condition field-name="partyIdTo" operator="is-not-empty"/> + <set field-name="noteParty" env-name="partyIdTo"/> + <set field-name="noteInfo" env-name="subject"/> + <set field-name="moreInfoItemName" value="communicationEventId"/> + <set field-name="moreInfoItemId" env-name="communicationEventId"/> + <set field-name="moreInfoUrl" value="/partymgr/control/MyCommunicationEvents"/> + <action service="createSystemInfoNote" mode="sync"/> + </eca> + <eca service="updateCommunicationEvent" event="commit"> + <condition field-name="statusId" operator="equals" value="COM_ENTERED"/> + <condition field-name="communicationEventTypeId" operator="equals" value="COMMENT_NOTE"/> + <condition field-name="partyIdTo" operator="is-not-empty"/> + <set field-name="noteParty" env-name="partyIdTo"/> + <set field-name="noteInfo" env-name="subject"/> + <set field-name="moreInfoItemName" value="communicationEventId"/> + <set field-name="moreInfoItemId" env-name="communicationEventId"/> + <set field-name="moreInfoUrl" value="/partymgr/control/MyCommunicationEvents"/> + <action service="createSystemInfoNote" mode="sync"/> + </eca> + <!-- send a note when a communicationevent is created for a certain loginId + with the status entered --> + <eca service="createCommunicationEvent" event="commit"> + <condition field-name="statusId" operator="equals" value="COM_ENTERED"/> + <condition field-name="communicationEventTypeId" operator="equals" value="AUTO_EMAIL_COM"/> + <condition field-name="partyIdTo" operator="is-not-empty"/> + <set field-name="noteParty" env-name="partyIdTo"/> + <set field-name="noteInfo" env-name="subject"/> + <set field-name="moreInfoItemName" value="communicationEventId"/> + <set field-name="moreInfoItemId" env-name="communicationEventId"/> + <set field-name="moreInfoUrl" value="/partymgr/control/MyCommunicationEvents"/> + <action service="createSystemInfoNote" mode="sync"/> + </eca> + <eca service="createCommunicationEvent" event="commit"> + <condition field-name="statusId" operator="equals" value="COM_ENTERED"/> + <condition field-name="communicationEventTypeId" operator="equals" value="EMAIL_COMMUNICATION"/> + <condition field-name="partyIdTo" operator="is-not-empty"/> + <set field-name="noteParty" env-name="partyIdTo"/> + <set field-name="noteInfo" env-name="subject"/> + <set field-name="moreInfoItemName" value="communicationEventId"/> + <set field-name="moreInfoItemId" env-name="communicationEventId"/> + <set field-name="moreInfoUrl" value="/partymgr/control/MyCommunicationEvents"/> + <action service="createSystemInfoNote" mode="sync"/> + </eca> + <eca service="createCommunicationEvent" event="commit"> + <condition field-name="statusId" operator="equals" value="COM_ENTERED"/> + <condition field-name="communicationEventTypeId" operator="equals" value="COMMENT_NOTE"/> + <condition field-name="partyIdTo" operator="is-not-empty"/> + <set field-name="noteParty" env-name="partyIdTo"/> + <set field-name="noteInfo" env-name="subject"/> + <set field-name="moreInfoItemName" value="communicationEventId"/> + <set field-name="moreInfoItemId" env-name="communicationEventId"/> + <set field-name="moreInfoUrl" value="/partymgr/control/MyCommunicationEvents"/> + <action service="createSystemInfoNote" mode="sync"/> + </eca> </service-eca> Modified: ofbiz/branches/20111205EmailHandling/applications/party/src/org/ofbiz/party/contact/ContactHelper.java URL: http://svn.apache.org/viewvc/ofbiz/branches/20111205EmailHandling/applications/party/src/org/ofbiz/party/contact/ContactHelper.java?rev=1305581&r1=1305580&r2=1305581&view=diff ============================================================================== --- ofbiz/branches/20111205EmailHandling/applications/party/src/org/ofbiz/party/contact/ContactHelper.java (original) +++ ofbiz/branches/20111205EmailHandling/applications/party/src/org/ofbiz/party/contact/ContactHelper.java Mon Mar 26 20:56:02 2012 @@ -36,6 +36,8 @@ public class ContactHelper { public static final String module = ContactHelper.class.getName(); + private ContactHelper() {} + public static Collection<GenericValue> getContactMech(GenericValue party, boolean includeOld) { return getContactMech(party, null, null, includeOld); } Modified: ofbiz/branches/20111205EmailHandling/applications/party/src/org/ofbiz/party/contact/ContactMechWorker.java URL: http://svn.apache.org/viewvc/ofbiz/branches/20111205EmailHandling/applications/party/src/org/ofbiz/party/contact/ContactMechWorker.java?rev=1305581&r1=1305580&r2=1305581&view=diff ============================================================================== --- ofbiz/branches/20111205EmailHandling/applications/party/src/org/ofbiz/party/contact/ContactMechWorker.java (original) +++ ofbiz/branches/20111205EmailHandling/applications/party/src/org/ofbiz/party/contact/ContactMechWorker.java Mon Mar 26 20:56:02 2012 @@ -19,15 +19,19 @@ package org.ofbiz.party.contact; +import java.io.UnsupportedEncodingException; +import java.net.URLEncoder; import java.util.Collection; import java.util.Iterator; import java.util.List; import java.util.Map; import javax.servlet.ServletRequest; + import javolution.util.FastList; import javolution.util.FastMap; +import org.ofbiz.base.util.Assert; import org.ofbiz.base.util.Debug; import org.ofbiz.base.util.UtilMisc; import org.ofbiz.base.util.UtilProperties; @@ -37,6 +41,7 @@ import org.ofbiz.entity.GenericEntityExc import org.ofbiz.entity.GenericValue; import org.ofbiz.entity.condition.EntityCondition; import org.ofbiz.entity.util.EntityUtil; +import org.ofbiz.entity.util.EntityUtilProperties; /** * Worker methods for Contact Mechanisms @@ -45,6 +50,8 @@ public class ContactMechWorker { public static final String module = ContactMechWorker.class.getName(); + private ContactMechWorker() {} + public static List<Map<String, Object>> getPartyContactMechValueMaps(Delegator delegator, String partyId, boolean showOld) { return getPartyContactMechValueMaps(delegator, partyId, showOld, null); } @@ -788,7 +795,7 @@ public class ContactMechWorker { String addr2 = postalAddress.getString("address2"); // get the matching string from general.properties - String matcher = UtilProperties.getPropertyValue("general.properties", "usps.address.match"); + String matcher = EntityUtilProperties.getPropertyValue("general.properties", "usps.address.match", postalAddress.getDelegator()); if (UtilValidate.isNotEmpty(matcher)) { if (addr1 != null && addr1.toLowerCase().matches(matcher)) { return true; @@ -941,4 +948,54 @@ public class ContactMechWorker { // nothing found, return null return null; } + + /** + * Returns a <b>PostalAddress</b> <code>GenericValue</code> as a URL encoded <code>String</code>. + * + * @param postalAddress A <b>PostalAddress</b> <code>GenericValue</code>. + * @return A URL encoded <code>String</code>. + * @throws GenericEntityException + * @throws UnsupportedEncodingException + */ + public static String urlEncodePostalAddress(GenericValue postalAddress) throws GenericEntityException, UnsupportedEncodingException { + Assert.notNull("postalAddress", postalAddress); + if (!"PostalAddress".equals(postalAddress.getEntityName())) { + throw new IllegalArgumentException("postalAddress argument is not a PostalAddress entity"); + } + StringBuilder sb = new StringBuilder(); + if (postalAddress.get("address1") != null) { + sb.append(postalAddress.get("address1")); + } + if (postalAddress.get("address2") != null) { + sb.append(", ").append(postalAddress.get("address2")); + } + if (postalAddress.get("city") != null) { + sb.append(", ").append(postalAddress.get("city")); + } + if (postalAddress.get("stateProvinceGeoId") != null) { + GenericValue geoValue = postalAddress.getRelatedOne("StateProvinceGeo"); + if (geoValue != null) { + sb.append(", ").append(geoValue.get("geoName")); + } + } else if (postalAddress.get("countyGeoId") != null) { + GenericValue geoValue = postalAddress.getRelatedOne("CountyGeo"); + if (geoValue != null) { + sb.append(", ").append(geoValue.get("geoName")); + } + } + if (postalAddress.get("postalCode") != null) { + sb.append(", ").append(postalAddress.get("postalCode")); + } + if (postalAddress.get("countryGeoId") != null) { + GenericValue geoValue = postalAddress.getRelatedOne("CountryGeo"); + if (geoValue != null) { + sb.append(", ").append(geoValue.get("geoName")); + } + } + String postalAddressString = sb.toString().trim(); + while (postalAddressString.contains(" ")) { + postalAddressString = postalAddressString.replace(" ", " "); + } + return URLEncoder.encode(postalAddressString, "UTF-8"); + } } Modified: ofbiz/branches/20111205EmailHandling/applications/party/src/org/ofbiz/party/party/PartyHelper.java URL: http://svn.apache.org/viewvc/ofbiz/branches/20111205EmailHandling/applications/party/src/org/ofbiz/party/party/PartyHelper.java?rev=1305581&r1=1305580&r2=1305581&view=diff ============================================================================== --- ofbiz/branches/20111205EmailHandling/applications/party/src/org/ofbiz/party/party/PartyHelper.java (original) +++ ofbiz/branches/20111205EmailHandling/applications/party/src/org/ofbiz/party/party/PartyHelper.java Mon Mar 26 20:56:02 2012 @@ -34,6 +34,8 @@ public class PartyHelper { public static final String module = PartyHelper.class.getName(); + private PartyHelper() {} + public static String getPartyName(GenericValue partyObject) { return getPartyName(partyObject, false); } Modified: ofbiz/branches/20111205EmailHandling/applications/party/src/org/ofbiz/party/party/PartyServices.java URL: http://svn.apache.org/viewvc/ofbiz/branches/20111205EmailHandling/applications/party/src/org/ofbiz/party/party/PartyServices.java?rev=1305581&r1=1305580&r2=1305581&view=diff ============================================================================== --- ofbiz/branches/20111205EmailHandling/applications/party/src/org/ofbiz/party/party/PartyServices.java (original) +++ ofbiz/branches/20111205EmailHandling/applications/party/src/org/ofbiz/party/party/PartyServices.java Mon Mar 26 20:56:02 2012 @@ -1516,7 +1516,7 @@ public class PartyServices { try { partyTo = delegator.findByPrimaryKey("Party", UtilMisc.toMap("partyId", partyIdTo)); } catch (GenericEntityException e) { - Debug.log(e, module); + Debug.logInfo(e, module); return ServiceUtil.returnError(e.getMessage()); } if (partyTo == null) { @@ -1532,7 +1532,7 @@ public class PartyServices { try { party = delegator.findByPrimaryKey("Party", UtilMisc.toMap("partyId", partyId)); } catch (GenericEntityException e) { - Debug.log(e, module); + Debug.logInfo(e, module); return ServiceUtil.returnError(e.getMessage()); } if (party == null) { @@ -1782,7 +1782,7 @@ public class PartyServices { } addrMap.put("sequenceNum", Long.valueOf(seq)); - Debug.log("Creating map entry: " + addrMap, module); + Debug.logInfo("Creating map entry: " + addrMap, module); try { delegator.create(addrMap); } catch (GenericEntityException e) { Modified: ofbiz/branches/20111205EmailHandling/applications/party/src/org/ofbiz/party/party/PartyWorker.java URL: http://svn.apache.org/viewvc/ofbiz/branches/20111205EmailHandling/applications/party/src/org/ofbiz/party/party/PartyWorker.java?rev=1305581&r1=1305580&r2=1305581&view=diff ============================================================================== --- ofbiz/branches/20111205EmailHandling/applications/party/src/org/ofbiz/party/party/PartyWorker.java (original) +++ ofbiz/branches/20111205EmailHandling/applications/party/src/org/ofbiz/party/party/PartyWorker.java Mon Mar 26 20:56:02 2012 @@ -52,6 +52,8 @@ public class PartyWorker { public static String module = PartyWorker.class.getName(); + private PartyWorker() {} + public static Map<String, GenericValue> getPartyOtherValues(ServletRequest request, String partyId, String partyAttr, String personAttr, String partyGroupAttr) { Delegator delegator = (Delegator) request.getAttribute("delegator"); Map<String, GenericValue> result = FastMap.newInstance(); @@ -357,7 +359,7 @@ public class PartyWorker { List<String> sort = UtilMisc.toList("-fromDate"); EntityCondition addrCond = EntityCondition.makeCondition(addrExprs, EntityOperator.AND); List<GenericValue> addresses = EntityUtil.filterByDate(delegator.findList("PartyAndPostalAddress", addrCond, null, sort, null, false)); - //Debug.log("Checking for matching address: " + addrCond.toString() + "[" + addresses.size() + "]", module); + //Debug.logInfo("Checking for matching address: " + addrCond.toString() + "[" + addresses.size() + "]", module); if (UtilValidate.isEmpty(addresses)) { // No address matches, return an empty list @@ -372,7 +374,7 @@ public class PartyWorker { String addr1Target = PartyWorker.makeMatchingString(delegator, address.getString("address1")); if (addr1Target != null) { - Debug.log("Comparing address1 : " + addr1Source + " / " + addr1Target, module); + Debug.logInfo("Comparing address1 : " + addr1Source + " / " + addr1Target, module); if (addr1Target.equals(addr1Source)) { // address 2 field @@ -380,17 +382,17 @@ public class PartyWorker { String addr2Source = PartyWorker.makeMatchingString(delegator, address2); String addr2Target = PartyWorker.makeMatchingString(delegator, address.getString("address2")); if (addr2Target != null) { - Debug.log("Comparing address2 : " + addr2Source + " / " + addr2Target, module); + Debug.logInfo("Comparing address2 : " + addr2Source + " / " + addr2Target, module); if (addr2Source.equals(addr2Target)) { - Debug.log("Matching address2; adding valid address", module); + Debug.logInfo("Matching address2; adding valid address", module); validFound.add(address); //validParty.put(address.getString("partyId"), address.getString("contactMechId")); } } } else { if (address.get("address2") == null) { - Debug.log("No address2; adding valid address", module); + Debug.logInfo("No address2; adding valid address", module); validFound.add(address); //validParty.put(address.getString("partyId"), address.getString("contactMechId")); } Modified: ofbiz/branches/20111205EmailHandling/applications/party/webapp/partymgr/WEB-INF/actions/party/GetGeoLocation.groovy URL: http://svn.apache.org/viewvc/ofbiz/branches/20111205EmailHandling/applications/party/webapp/partymgr/WEB-INF/actions/party/GetGeoLocation.groovy?rev=1305581&r1=1305580&r2=1305581&view=diff ============================================================================== --- ofbiz/branches/20111205EmailHandling/applications/party/webapp/partymgr/WEB-INF/actions/party/GetGeoLocation.groovy (original) +++ ofbiz/branches/20111205EmailHandling/applications/party/webapp/partymgr/WEB-INF/actions/party/GetGeoLocation.groovy Mon Mar 26 20:56:02 2012 @@ -1,3 +1,22 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + import org.ofbiz.entity.*; import org.ofbiz.entity.util.EntityUtil; import org.ofbiz.base.util.*; Propchange: ofbiz/branches/20111205EmailHandling/applications/party/webapp/partymgr/WEB-INF/actions/party/PartyFinancialHistory.groovy ------------------------------------------------------------------------------ Merged /ofbiz/trunk/applications/party/webapp/partymgr/WEB-INF/actions/party/PartyFinancialHistory.groovy:r1210494-1305499 Modified: ofbiz/branches/20111205EmailHandling/applications/party/webapp/partymgr/party/findparty.ftl URL: http://svn.apache.org/viewvc/ofbiz/branches/20111205EmailHandling/applications/party/webapp/partymgr/party/findparty.ftl?rev=1305581&r1=1305580&r2=1305581&view=diff ============================================================================== --- ofbiz/branches/20111205EmailHandling/applications/party/webapp/partymgr/party/findparty.ftl (original) +++ ofbiz/branches/20111205EmailHandling/applications/party/webapp/partymgr/party/findparty.ftl Mon Mar 26 20:56:02 2012 @@ -337,7 +337,7 @@ under the License. <td>${partyDate.lastModifiedDate?if_exists}</td> <td class="button-col align-float"> <a href="<@ofbizUrl>viewprofile?partyId=${partyRow.partyId}</@ofbizUrl>">${uiLabelMap.CommonDetails}</a> - <#if security.hasRolePermission("ORDERMGR", "_VIEW", "", "", session)> + <#if security.hasEntityPermission("ORDERMGR", "_VIEW", session)> <form name= "searchorders_o_${rowCount}" method= "post" action= "/ordermgr/control/searchorders"> <input type= "hidden" name= "lookupFlag" value= "Y" /> <input type= "hidden" name= "hideFields" value= "Y" /> Modified: ofbiz/branches/20111205EmailHandling/applications/party/webapp/partymgr/party/profileblocks/Attributes.ftl URL: http://svn.apache.org/viewvc/ofbiz/branches/20111205EmailHandling/applications/party/webapp/partymgr/party/profileblocks/Attributes.ftl?rev=1305581&r1=1305580&r2=1305581&view=diff ============================================================================== --- ofbiz/branches/20111205EmailHandling/applications/party/webapp/partymgr/party/profileblocks/Attributes.ftl (original) +++ ofbiz/branches/20111205EmailHandling/applications/party/webapp/partymgr/party/profileblocks/Attributes.ftl Mon Mar 26 20:56:02 2012 @@ -22,7 +22,7 @@ under the License. <ul> <li class="h3">${uiLabelMap.PartyAttributes}</li> <#if security.hasEntityPermission("PARTYMGR", "_CREATE", session)> - <li><a href="<@ofbizUrl>editPartyAttribute?partyId=${party.partyId}</@ofbizUrl>">${uiLabelMap.CommonCreateNew}</a></li> + <li><a href="<@ofbizUrl>editPartyAttribute?partyId=${party.partyId?if_exists}</@ofbizUrl>">${uiLabelMap.CommonCreateNew}</a></li> </#if> </ul> <br class="clear"/> @@ -39,13 +39,13 @@ under the License. <#list attributes as attr> <tr valign="middle"<#if alt_row> class="alternate-row"</#if>> <td> - ${attr.attrName} + ${attr.attrName?if_exists} </td> <td> - ${attr.attrValue} + ${attr.attrValue?if_exists} </td> <td class="button-col"> - <a href="<@ofbizUrl>editPartyAttribute?partyId=${partyId}&attrName=${attr.attrName}</@ofbizUrl>">${uiLabelMap.CommonEdit}</a> + <a href="<@ofbizUrl>editPartyAttribute?partyId=${partyId?if_exists}&attrName=${attr.attrName?if_exists}</@ofbizUrl>">${uiLabelMap.CommonEdit}</a> </td> </tr> <#-- toggle the row color --> Modified: ofbiz/branches/20111205EmailHandling/applications/party/webapp/partymgr/party/profileblocks/Contact.ftl URL: http://svn.apache.org/viewvc/ofbiz/branches/20111205EmailHandling/applications/party/webapp/partymgr/party/profileblocks/Contact.ftl?rev=1305581&r1=1305580&r2=1305581&view=diff ============================================================================== --- ofbiz/branches/20111205EmailHandling/applications/party/webapp/partymgr/party/profileblocks/Contact.ftl (original) +++ ofbiz/branches/20111205EmailHandling/applications/party/webapp/partymgr/party/profileblocks/Contact.ftl Mon Mar 26 20:56:02 2012 @@ -57,50 +57,30 @@ under the License. </div> </#list> <#if "POSTAL_ADDRESS" = contactMech.contactMechTypeId> - <#assign postalAddress = contactMechMap.postalAddress> - <#if postalAddress?has_content> - <div> - <#if postalAddress.toName?has_content><b>${uiLabelMap.PartyAddrToName}:</b> ${postalAddress.toName}<br /></#if> - <#if postalAddress.attnName?has_content><b>${uiLabelMap.PartyAddrAttnName}:</b> ${postalAddress.attnName}<br /></#if> - ${postalAddress.address1?if_exists}<br /> - <#if postalAddress.address2?has_content>${postalAddress.address2}<br /></#if> - ${postalAddress.city?if_exists}, - <#if postalAddress.stateProvinceGeoId?has_content> - <#assign stateProvince = postalAddress.getRelatedOneCache("StateProvinceGeo")> - ${stateProvince.abbreviation?default(stateProvince.geoId)} - </#if> - ${postalAddress.postalCode?if_exists} - <#if postalAddress.countryGeoId?has_content><br /> - <#assign country = postalAddress.getRelatedOneCache("CountryGeo")> - ${country.geoName?default(country.geoId)} - </#if> - </div> - </#if> - <#if (postalAddress?has_content && !postalAddress.countryGeoId?has_content) || postalAddress.countryGeoId = "USA"> - <#assign addr1 = postalAddress.address1?if_exists> - <#if addr1?has_content && (addr1.indexOf(" ") > 0)> - <#assign addressNum = addr1.substring(0, addr1.indexOf(" "))> - <#assign addressOther = addr1.substring(addr1.indexOf(" ")+1)> - <a target="_blank" href="${uiLabelMap.CommonLookupWhitepagesAddressLink}" class="buttontext">${uiLabelMap.CommonLookupWhitepages}</a> - </#if> - </#if> - <#if postalAddress.geoPointId?has_content> - <#if contactMechPurposeType?has_content> - <#assign popUptitle = contactMechPurposeType.get("description",locale) + uiLabelMap.CommonGeoLocation> + <#if contactMechMap.postalAddress?has_content> + <#assign postalAddress = contactMechMap.postalAddress> + ${setRequestAttribute("postalAddress", postalAddress)} + ${screens.render("component://party/widget/partymgr/PartyScreens.xml#postalAddress")} + <#if postalAddress.geoPointId?has_content> + <#if contactMechPurposeType?has_content> + <#assign popUptitle = contactMechPurposeType.get("description",locale) + uiLabelMap.CommonGeoLocation> + </#if> + <a href="javascript:popUp('<@ofbizUrl>PartyGeoLocation?geoPointId=${postalAddress.geoPointId}&partyId=${partyId}</@ofbizUrl>', '${popUptitle?if_exists}', '450', '550')" class="buttontext">${uiLabelMap.CommonGeoLocation}</a> </#if> - <a href="javascript:popUp('<@ofbizUrl>PartyGeoLocation?geoPointId=${postalAddress.geoPointId}&partyId=${partyId}</@ofbizUrl>', '${popUptitle?if_exists}', '450', '550')" class="buttontext">${uiLabelMap.CommonGeoLocation}</a> </#if> <#elseif "TELECOM_NUMBER" = contactMech.contactMechTypeId> - <#assign telecomNumber = contactMechMap.telecomNumber> - <div> - ${telecomNumber.countryCode?if_exists} - <#if telecomNumber.areaCode?has_content>${telecomNumber.areaCode?default("000")}-</#if>${telecomNumber.contactNumber?default("000-0000")} - <#if partyContactMech.extension?has_content>${uiLabelMap.PartyContactExt} ${partyContactMech.extension}</#if> - <#if (telecomNumber?has_content && !telecomNumber.countryCode?has_content) || telecomNumber.countryCode = "011"> - <a target="_blank" href="${uiLabelMap.CommonLookupAnywhoLink}" class="buttontext">${uiLabelMap.CommonLookupAnywho}</a> - <a target="_blank" href="${uiLabelMap.CommonLookupWhitepagesTelNumberLink}" class="buttontext">${uiLabelMap.CommonLookupWhitepages}</a> - </#if> - </div> + <#if contactMechMap.telecomNumber?has_content> + <#assign telecomNumber = contactMechMap.telecomNumber> + <div> + ${telecomNumber.countryCode?if_exists} + <#if telecomNumber.areaCode?has_content>${telecomNumber.areaCode?default("000")}-</#if><#if telecomNumber.contactNumber?has_content>${telecomNumber.contactNumber?default("000-0000")}</#if> + <#if partyContactMech.extension?has_content>${uiLabelMap.PartyContactExt} ${partyContactMech.extension}</#if> + <#if !telecomNumber.countryCode?has_content || telecomNumber.countryCode = "011"> + <a target="_blank" href="${uiLabelMap.CommonLookupAnywhoLink}" class="buttontext">${uiLabelMap.CommonLookupAnywho}</a> + <a target="_blank" href="${uiLabelMap.CommonLookupWhitepagesTelNumberLink}" class="buttontext">${uiLabelMap.CommonLookupWhitepages}</a> + </#if> + </div> + </#if> <#elseif "EMAIL_ADDRESS" = contactMech.contactMechTypeId> <div> ${contactMech.infoString?if_exists} Modified: ofbiz/branches/20111205EmailHandling/applications/party/widget/partymgr/CommunicationEventForms.xml URL: http://svn.apache.org/viewvc/ofbiz/branches/20111205EmailHandling/applications/party/widget/partymgr/CommunicationEventForms.xml?rev=1305581&r1=1305580&r2=1305581&view=diff ============================================================================== --- ofbiz/branches/20111205EmailHandling/applications/party/widget/partymgr/CommunicationEventForms.xml (original) +++ ofbiz/branches/20111205EmailHandling/applications/party/widget/partymgr/CommunicationEventForms.xml Mon Mar 26 20:56:02 2012 @@ -489,7 +489,7 @@ under the License. <form name="ListPartyCommEvents" type="list" target="RemoveCommunicationEventRole" list-name="listIt" odd-row-style="alternate-row" header-row-style="header-row-2" default-table-style="basic-table hover-bar"> <actions> - <set field="parameters.sortField" from-field="parameters.sortField" default-value="${groovy: "true".equals(parameters.all)?"-entryDate":"entryDate"}"/> + <set field="parameters.sortField" from-field="parameters.sortField" default-value="${groovy: 'true'.equals(parameters.all)?'-entryDate':'entryDate'}"/> <set field="searchParameters.partyId" from-field="partyId"/> <set field="searchParameters.statusId" value="COM_UNKNOWN_PARTY"/> <set field="searchParameters.statusId_op" value="notEqual"/> |
Free forum by Nabble | Edit this page |