|
Author: jleroux
Date: Sat Feb 2 10:55:01 2013 New Revision: 1441729 URL: http://svn.apache.org/viewvc?rev=1441729&view=rev Log: Merge trunk HEAD Modified: ofbiz/branches/webhelp-2012-12-07/ (props changed) ofbiz/branches/webhelp-2012-12-07/applications/accounting/config/AccountingEntityLabels.xml ofbiz/branches/webhelp-2012-12-07/applications/order/config/OrderUiLabels.xml ofbiz/branches/webhelp-2012-12-07/applications/order/src/org/ofbiz/order/order/OrderReturnServices.java ofbiz/branches/webhelp-2012-12-07/applications/product/webapp/catalog/price/setPriceRulesCondEventJs.ftl ofbiz/branches/webhelp-2012-12-07/framework/base/src/org/ofbiz/base/concurrent/ExecutionPool.java ofbiz/branches/webhelp-2012-12-07/framework/common/config/general.properties ofbiz/branches/webhelp-2012-12-07/framework/common/webcommon/includes/setDependentDropdownValuesJs.ftl ofbiz/branches/webhelp-2012-12-07/framework/images/webapp/images/miscAjaxFunctions.js ofbiz/branches/webhelp-2012-12-07/framework/widget/src/org/ofbiz/widget/screen/MacroScreenRenderer.java Propchange: ofbiz/branches/webhelp-2012-12-07/ ------------------------------------------------------------------------------ Merged /ofbiz/trunk:r1435516-1441728 Modified: ofbiz/branches/webhelp-2012-12-07/applications/accounting/config/AccountingEntityLabels.xml URL: http://svn.apache.org/viewvc/ofbiz/branches/webhelp-2012-12-07/applications/accounting/config/AccountingEntityLabels.xml?rev=1441729&r1=1441728&r2=1441729&view=diff ============================================================================== --- ofbiz/branches/webhelp-2012-12-07/applications/accounting/config/AccountingEntityLabels.xml (original) +++ ofbiz/branches/webhelp-2012-12-07/applications/accounting/config/AccountingEntityLabels.xml Sat Feb 2 10:55:01 2013 @@ -1765,7 +1765,7 @@ <value xml:lang="zh_TW">婿¯æ¶å ¥</value> </property> <property key="GlAccountType.description.INTRSTINC_RECEIVABLE"> - <value xml:lang="en">Zinsertragsforderungen</value> + <value xml:lang="de">Zinsertragsforderungen</value> <value xml:lang="en">Interest Income Receivables</value> <value xml:lang="hi_IN">बà¥à¤¯à¤¾à¤ à¤à¤¯ पà¥à¤°à¤¾à¤ªà¥à¤¤à¤¿à¤¯à¥à¤</value> <value xml:lang="it">Reddito da interessi a credito</value> Modified: ofbiz/branches/webhelp-2012-12-07/applications/order/config/OrderUiLabels.xml URL: http://svn.apache.org/viewvc/ofbiz/branches/webhelp-2012-12-07/applications/order/config/OrderUiLabels.xml?rev=1441729&r1=1441728&r2=1441729&view=diff ============================================================================== --- ofbiz/branches/webhelp-2012-12-07/applications/order/config/OrderUiLabels.xml (original) +++ ofbiz/branches/webhelp-2012-12-07/applications/order/config/OrderUiLabels.xml Sat Feb 2 10:55:01 2013 @@ -2285,6 +2285,8 @@ <value xml:lang="ja">注æã«æ»ã</value> <value xml:lang="pt_BR">Voltar ao pedido</value> <value xml:lang="vi">Quay vá» Äặt hà ng</value> + <value xml:lang="zh">è¿å订å</value> + <value xml:lang="zh_CN">è¿å订å</value> <value xml:lang="zh_TW">è¿åè¨å®</value> </property> <property key="OrderBacktoShoppingCart"> @@ -2667,6 +2669,9 @@ <value xml:lang="fr">Par l'utilisateur</value> <value xml:lang="ja">ã¦ã¼ã¶ã夿´</value> <value xml:lang="vi">Thay Äá»i bá»i ngưá»i dùng</value> + <value xml:lang="zh">æ´æ¹äºº</value> + <value xml:lang="zh_CN">æ´æ¹äºº</value> + <value xml:lang="zh_TW">æ´æ¹äºº</value> </property> <property key="OrderCheckout"> <value xml:lang="cs">Objednávka</value> @@ -3445,6 +3450,8 @@ <value xml:lang="it">Creare Nuovo Gruppo di Spedizione</value> <value xml:lang="ja">æ°è¦çºéã°ã«ã¼ãã使</value> <value xml:lang="vi">Thêm má»i nhóm chuyá»n hà ng bằng ÄÆ°á»ng thá»§y</value> + <value xml:lang="zh">å建æ°è´§è¿ç»</value> + <value xml:lang="zh_CN">å建æ°è´§è¿ç»</value> <value xml:lang="zh_TW">å»ºç«æ°éé群çµ</value> </property> <property key="OrderCreateShippingAddress"> @@ -4649,6 +4656,8 @@ <value xml:lang="ja">å±¥æ´ã¯æå¹ã§ã¯ããã¾ãã</value> <value xml:lang="pt_BR">Histórico indisponÃvel</value> <value xml:lang="vi">Không có lá»ch sá» nà o</value> + <value xml:lang="zh">æ åå²èµæ</value> + <value xml:lang="zh_CN">æ åå²èµæ</value> <value xml:lang="zh_TW">ç¡æ·å²è³æ</value> </property> <property key="OrderHold"> @@ -5517,6 +5526,8 @@ <value xml:lang="ja">表示æ¸ãã¼ã¯</value> <value xml:lang="pt_BR">Marcar como visualizado</value> <value xml:lang="vi">Äánh dấu Äã xem</value> + <value xml:lang="zh">æ è®°å·²æµè§</value> + <value xml:lang="zh_CN">æ è®°å·²æµè§</value> <value xml:lang="zh_TW">æ¨ç¤ºå·²æª¢è¦</value> </property> <property key="OrderMarketingPackageComposedBy"> @@ -5891,6 +5902,8 @@ <value xml:lang="ja">æ°è¦çºéå 使</value> <value xml:lang="pt_BR">Novo endereço de envio</value> <value xml:lang="vi">Äá»a chá» chuyá»n hà ng má»i</value> + <value xml:lang="zh">æ°çè´§è¿å°å</value> + <value xml:lang="zh_CN">æ°çè´§è¿å°å</value> <value xml:lang="zh_TW">æ°çééå°å</value> </property> <property key="OrderNewShoppingList"> @@ -6998,6 +7011,8 @@ <value xml:lang="it">Storia ordine</value> <value xml:lang="ja">注æå±¥æ´</value> <value xml:lang="pt_BR">Histórico do pedido</value> + <value xml:lang="zh">订ååå²</value> + <value xml:lang="zh_CN">订ååå²</value> <value xml:lang="zh_TW">è¨å®æ·å²</value> </property> <property key="OrderOrderId"> @@ -9770,6 +9785,8 @@ <value xml:lang="ja">ã¢ã¤ãã æ°éå±¥æ´</value> <value xml:lang="pt_BR">Histórico de quantidade de item</value> <value xml:lang="vi">Lá»ch sá» sá» lượng hà ng hóa</value> + <value xml:lang="zh">æç»æ°éåå²</value> + <value xml:lang="zh_CN">æç»æ°éåå²</value> <value xml:lang="zh_TW">æç´°æ¸éæ·å²</value> </property> <property key="OrderQuantityInShipGroup"> @@ -11736,6 +11753,9 @@ <value xml:lang="it">Venditori</value> <value xml:lang="ja">販売ã¬ãã¼ã</value> <value xml:lang="vi">Äại diá»n bán hà ng</value> + <value xml:lang="zh">éå®ä»£è¡¨</value> + <value xml:lang="zh_CN">éå®ä»£è¡¨</value> + <value xml:lang="zh_TW">é·å®ä»£è¡¨</value> </property> <property key="OrderSalesTax"> <value xml:lang="cs">DPH</value> @@ -12551,6 +12571,8 @@ <value xml:lang="ja">çºéæ¹æ³å±¥æ´</value> <value xml:lang="pt_BR">Histórico de método de envio</value> <value xml:lang="vi">Lá»ch sá» phương thức chuyá»n váºn</value> + <value xml:lang="zh">è´§è¿æ¹å¼åå²</value> + <value xml:lang="zh_CN">è´§è¿æ¹å¼åå²</value> <value xml:lang="zh_TW">è²¨éæ¹å¼æ·å²</value> </property> <property key="OrderShipmentReceived"> @@ -13536,6 +13558,8 @@ <value xml:lang="ja">ã¢ã¤ãã å価履æ´</value> <value xml:lang="pt_BR">Histórico do preço unitário do item</value> <value xml:lang="vi">Lá»ch sá» giá ÄÆ¡n vá» hà ng hóa</value> + <value xml:lang="zh">æç»åä»·åå²</value> + <value xml:lang="zh_CN">æç»åä»·åå²</value> <value xml:lang="zh_TW">æç´°æ·å²å®å¹</value> </property> <property key="OrderUnitsPieces"> @@ -13839,6 +13863,8 @@ <value xml:lang="nl">Bekijk eerdere bestellingen</value> <value xml:lang="pt_BR">Visualizar histórico de pedido</value> <value xml:lang="vi">Xem lá»ch sá» Äặt hà ng</value> + <value xml:lang="zh">æµè§è®¢ååå²</value> + <value xml:lang="zh_CN">æ¥ç订ååå²</value> <value xml:lang="zh_TW">檢è¦è¨å®æ·å²</value> </property> <property key="OrderViewPermissionError"> Modified: ofbiz/branches/webhelp-2012-12-07/applications/order/src/org/ofbiz/order/order/OrderReturnServices.java URL: http://svn.apache.org/viewvc/ofbiz/branches/webhelp-2012-12-07/applications/order/src/org/ofbiz/order/order/OrderReturnServices.java?rev=1441729&r1=1441728&r2=1441729&view=diff ============================================================================== --- ofbiz/branches/webhelp-2012-12-07/applications/order/src/org/ofbiz/order/order/OrderReturnServices.java (original) +++ ofbiz/branches/webhelp-2012-12-07/applications/order/src/org/ofbiz/order/order/OrderReturnServices.java Sat Feb 2 10:55:01 2013 @@ -753,13 +753,15 @@ public class OrderReturnServices { } // if both billingAccountId and finAccountId are supplied, look for productStore.storeCreditAccountEnumId preference - if (finAccountId != null && billingAccountId != null) { - Debug.logWarning("FinAccount and BillingAccount both are supplied for storing credit, priority will be given to ProductStore preference. Default is FinAccount.", module); - if (productStore != null && productStore.getString("storeCreditAccountEnumId") != null && "BILLING_ACCOUNT".equals(productStore.getString("storeCreditAccountEnumId"))) { + if (finAccountId != null && billingAccountId != null && productStore != null && productStore.getString("storeCreditAccountEnumId") != null) { + Debug.logWarning("You have entered both financial account and billing account for store credit. Based on the configuration on product store, only one of them will be selected.", module); + if ("BILLING_ACCOUNT".equals(productStore.getString("storeCreditAccountEnumId"))) { finAccountId = null; + Debug.logWarning("Default setting on product store is billing account. Store credit will goes to billing account [" + billingAccountId + "]", module); } else { billingAccountId = null; - } + Debug.logWarning("Default setting on product store is financial account. Store credit will goes to financial account [" + finAccountId + "]", module); + } } if (finAccountId == null && billingAccountId == null) { Modified: ofbiz/branches/webhelp-2012-12-07/applications/product/webapp/catalog/price/setPriceRulesCondEventJs.ftl URL: http://svn.apache.org/viewvc/ofbiz/branches/webhelp-2012-12-07/applications/product/webapp/catalog/price/setPriceRulesCondEventJs.ftl?rev=1441729&r1=1441728&r2=1441729&view=diff ============================================================================== --- ofbiz/branches/webhelp-2012-12-07/applications/product/webapp/catalog/price/setPriceRulesCondEventJs.ftl (original) +++ ofbiz/branches/webhelp-2012-12-07/applications/product/webapp/catalog/price/setPriceRulesCondEventJs.ftl Sat Feb 2 10:55:01 2013 @@ -23,18 +23,18 @@ jQuery(document).ready( function() { if (document.getElementById('EditProductPriceRulesCond_o_${i}')) { jQuery('#EditProductPriceRulesCond_condValueInput_o_${i}').hide(); jQuery('#EditProductPriceRulesCond_inputParamEnumId_o_${i}').change( function() { - getDependentDropdownValues('getAssociatedPriceRulesConds', 'inputParamEnumId', 'EditProductPriceRulesCond_inputParamEnumId_o_${i}', 'EditProductPriceRulesCond_condValue_o_${i}', 'productPriceRulesCondValues', 'condValue_o_${i}', 'description', '${productPriceConds[i].condValue}', '', '', '', 'EditProductPriceRulesCond_condValueInput_o_${i}'); + getDependentDropdownValues('getAssociatedPriceRulesConds', 'inputParamEnumId', 'EditProductPriceRulesCond_inputParamEnumId_o_${i}', 'EditProductPriceRulesCond_condValue_o_${i}', 'productPriceRulesCondValues', 'condValue_o_${i}', 'description', '${productPriceConds[i].condValue}', '', '', '', '', 'EditProductPriceRulesCond_condValueInput_o_${i}'); }); - getDependentDropdownValues('getAssociatedPriceRulesConds', 'inputParamEnumId', 'EditProductPriceRulesCond_inputParamEnumId_o_${i}', 'EditProductPriceRulesCond_condValue_o_${i}', 'productPriceRulesCondValues', 'condValue_o_${i}', 'description', '${productPriceConds[i].condValue}', '', '', '', 'EditProductPriceRulesCond_condValueInput_o_${i}'); + getDependentDropdownValues('getAssociatedPriceRulesConds', 'inputParamEnumId', 'EditProductPriceRulesCond_inputParamEnumId_o_${i}', 'EditProductPriceRulesCond_condValue_o_${i}', 'productPriceRulesCondValues', 'condValue_o_${i}', 'description', '${productPriceConds[i].condValue}', '', '', '', '', 'EditProductPriceRulesCond_condValueInput_o_${i}'); } </#list> </#if> if (document.getElementById('AddProductPriceRulesCond_o_0')) { jQuery('#AddProductPriceRulesCond_condValueInput_o_0').hide(); jQuery('#AddProductPriceRulesCond_inputParamEnumId_o_0').change( function() { - getDependentDropdownValues('getAssociatedPriceRulesConds', 'inputParamEnumId', 'AddProductPriceRulesCond_inputParamEnumId_o_0', 'AddProductPriceRulesCond_condValue_o_0', 'productPriceRulesCondValues', 'condValue_o_0', 'description', '', '', '', '', 'AddProductPriceRulesCond_condValueInput_o_0'); + getDependentDropdownValues('getAssociatedPriceRulesConds', 'inputParamEnumId', 'AddProductPriceRulesCond_inputParamEnumId_o_0', 'AddProductPriceRulesCond_condValue_o_0', 'productPriceRulesCondValues', 'condValue_o_0', 'description', '', '', '', '', '', 'AddProductPriceRulesCond_condValueInput_o_0'); }); - getDependentDropdownValues('getAssociatedPriceRulesConds', 'inputParamEnumId', 'AddProductPriceRulesCond_inputParamEnumId_o_0', 'AddProductPriceRulesCond_condValue_o_0', 'productPriceRulesCondValues', 'condValue_o_0', 'description', '', '', '', '', 'AddProductPriceRulesCond_condValueInput_o_0'); + getDependentDropdownValues('getAssociatedPriceRulesConds', 'inputParamEnumId', 'AddProductPriceRulesCond_inputParamEnumId_o_0', 'AddProductPriceRulesCond_condValue_o_0', 'productPriceRulesCondValues', 'condValue_o_0', 'description', '', '', '', '', '', 'AddProductPriceRulesCond_condValueInput_o_0'); } }) </script> Modified: ofbiz/branches/webhelp-2012-12-07/framework/base/src/org/ofbiz/base/concurrent/ExecutionPool.java URL: http://svn.apache.org/viewvc/ofbiz/branches/webhelp-2012-12-07/framework/base/src/org/ofbiz/base/concurrent/ExecutionPool.java?rev=1441729&r1=1441728&r2=1441729&view=diff ============================================================================== --- ofbiz/branches/webhelp-2012-12-07/framework/base/src/org/ofbiz/base/concurrent/ExecutionPool.java (original) +++ ofbiz/branches/webhelp-2012-12-07/framework/base/src/org/ofbiz/base/concurrent/ExecutionPool.java Sat Feb 2 10:55:01 2013 @@ -18,12 +18,11 @@ *******************************************************************************/ package org.ofbiz.base.concurrent; -import java.lang.Runtime; import java.util.Collection; import java.util.Iterator; import java.util.List; -import java.util.concurrent.Delayed; import java.util.concurrent.DelayQueue; +import java.util.concurrent.Delayed; import java.util.concurrent.ExecutionException; import java.util.concurrent.Future; import java.util.concurrent.ScheduledExecutorService; @@ -39,7 +38,7 @@ import org.ofbiz.base.util.Debug; @SourceMonitored public final class ExecutionPool { public static final String module = ExecutionPool.class.getName(); - public static final ScheduledExecutorService GLOBAL_EXECUTOR = getExecutor(null, "OFBiz-config", -1, true); + public static final ScheduledExecutorService GLOBAL_EXECUTOR = getExecutor(null, "OFBiz-config", -1, false); protected static class ExecutionPoolThreadFactory implements ThreadFactory { private final ThreadGroup group; @@ -60,20 +59,10 @@ public final class ExecutionPool { } } - @Deprecated - public static ThreadFactory createThreadFactory(String namePrefix) { - return createThreadFactory(null, namePrefix); - } - public static ThreadFactory createThreadFactory(ThreadGroup group, String namePrefix) { return new ExecutionPoolThreadFactory(group, namePrefix); } - @Deprecated - public static ScheduledExecutorService getExecutor(String namePrefix, int threadCount) { - return getExecutor(null, namePrefix, threadCount, true); - } - public static ScheduledExecutorService getExecutor(ThreadGroup group, String namePrefix, int threadCount, boolean preStart) { if (threadCount == 0) { threadCount = 1; @@ -89,16 +78,6 @@ public final class ExecutionPool { return executor; } - @Deprecated - public static ScheduledExecutorService getNewExactExecutor(String namePrefix) { - return getExecutor(null, namePrefix, -1, true); - } - - @Deprecated - public static ScheduledExecutorService getNewOptimalExecutor(String namePrefix) { - return getExecutor(null, namePrefix, -2, true); - } - public static <F> List<F> getAllFutures(Collection<Future<F>> futureList) { List<F> result = FastList.newInstance(); for (Future<F> future: futureList) { Modified: ofbiz/branches/webhelp-2012-12-07/framework/common/config/general.properties URL: http://svn.apache.org/viewvc/ofbiz/branches/webhelp-2012-12-07/framework/common/config/general.properties?rev=1441729&r1=1441728&r2=1441729&view=diff ============================================================================== --- ofbiz/branches/webhelp-2012-12-07/framework/common/config/general.properties (original) +++ ofbiz/branches/webhelp-2012-12-07/framework/common/config/general.properties Sat Feb 2 10:55:01 2013 @@ -132,8 +132,6 @@ mail.spam.value=YES https.demo-trunk.ofbiz.apache.org=ABQIAAAAtt0d8djaYFkk8N5LJVcDSBTl26GJHIFzHZYG8GNWSTKWDUTxchRLjgT9hY3-DDYk27lvZS84RH4aiQ https.demo-stable.ofbiz.apache.org=ABQIAAAAtt0d8djaYFkk8N5LJVcDSBR8L_-1UdAfCE2bleqTaEvMtKARZxSrkTzKktKY2_Znm0TRq2DF4YhGPg -https.www.ofbiz.it=ABQIAAAAtt0d8djaYFkk8N5LJVcDSBQUlpTe-xmKVkX0xosnXLpfGrWfqBTaTBsLPVxB5fgaomcHPo0N2h6IXg - https.localhost=ABQIAAAAtt0d8djaYFkk8N5LJVcDSBQN-clGH2vvMMwJjYtcwF78UzZgEBTN70S6uIgRoAtXRkADNoesbw5etg http.localhost=ABQIAAAAtt0d8djaYFkk8N5LJVcDSBT2yXp_ZAY8_ufC3CFXhHIE1NvwkxR3euHYk9bpwvdF2Qg1EYO1LQitHA Modified: ofbiz/branches/webhelp-2012-12-07/framework/common/webcommon/includes/setDependentDropdownValuesJs.ftl URL: http://svn.apache.org/viewvc/ofbiz/branches/webhelp-2012-12-07/framework/common/webcommon/includes/setDependentDropdownValuesJs.ftl?rev=1441729&r1=1441728&r2=1441729&view=diff ============================================================================== --- ofbiz/branches/webhelp-2012-12-07/framework/common/webcommon/includes/setDependentDropdownValuesJs.ftl (original) +++ ofbiz/branches/webhelp-2012-12-07/framework/common/webcommon/includes/setDependentDropdownValuesJs.ftl Sat Feb 2 10:55:01 2013 @@ -20,9 +20,9 @@ under the License. jQuery(document).ready(function() { if (jQuery('#${dependentForm}').length) { jQuery("#${dependentForm}_${mainId}").change(function(e, data) { - getDependentDropdownValues('${requestName}', '${paramKey}', '${dependentForm}_${mainId}', '${dependentForm}_${dependentId}', '${responseName}', '${dependentId}', '${descName}'); + getDependentDropdownValues('${requestName}', '${paramKey}', '${dependentForm}_${mainId}', '${dependentForm}_${dependentId}', '${responseName}', '${dependentKeyName}', '${descName}'); }); - getDependentDropdownValues('${requestName}', '${paramKey}', '${dependentForm}_${mainId}', '${dependentForm}_${dependentId}', '${responseName}', '${dependentId}', '${descName}', '${selectedDependentOption}'); + getDependentDropdownValues('${requestName}', '${paramKey}', '${dependentForm}_${mainId}', '${dependentForm}_${dependentId}', '${responseName}', '${dependentKeyName}', '${descName}', '${selectedDependentOption}'); } }) </script> \ No newline at end of file Modified: ofbiz/branches/webhelp-2012-12-07/framework/images/webapp/images/miscAjaxFunctions.js URL: http://svn.apache.org/viewvc/ofbiz/branches/webhelp-2012-12-07/framework/images/webapp/images/miscAjaxFunctions.js?rev=1441729&r1=1441728&r2=1441729&view=diff ============================================================================== --- ofbiz/branches/webhelp-2012-12-07/framework/images/webapp/images/miscAjaxFunctions.js (original) +++ ofbiz/branches/webhelp-2012-12-07/framework/images/webapp/images/miscAjaxFunctions.js Sat Feb 2 10:55:01 2013 @@ -26,13 +26,14 @@ // descName = name of the dependent drop-down description // selected = optional name of a selected option // callback = optional javascript function called at end +// allowEmpty = optional boolean argument, allow selection of an empty value for the dependentId // hide = optional boolean argument, if true the dependent drop-down field (targetField) will be hidden when no options are available else only disabled. False by default. // hideTitle = optional boolean argument (hide must be set to true), if true the title of the dependent drop-down field (targetField) will be hidden when no options are available else only disabled. False by default. // inputField = optional name of an input field // this is to handle a specific case where an input field is needed instead of a drop-down when no values are returned by the request // this will be maybe extended later to use an auto-completed drop-down or a lookup, instead of straight drop-down currently, when there are too much values to populate // this is e.g. currently used in the Product Price Rules screen -function getDependentDropdownValues(request, paramKey, paramField, targetField, responseName, keyName, descName, selected, callback, hide, hideTitle, inputField){ +function getDependentDropdownValues(request, paramKey, paramField, targetField, responseName, keyName, descName, selected, callback, allowEmpty, hide, hideTitle, inputField){ target = '#' + targetField; input = '#' + inputField; targetTitle = target + '_title' @@ -49,6 +50,14 @@ function getDependentDropdownValues(requ list = result[responseName]; // Create and show dependent select options if (list) { + if(allowEmpty) { + // Allow null selection in dependent and set it as default if no selection exists. + if (selected == undefined || selected == "_none_") { + optionList += "<option selected='selected' value=''></option>"; + } else { + optionList += "<option value=''></option>"; + } + } jQuery.each(list, function(key, value){ if (typeof value == 'string') { values = value.split(': '); Modified: ofbiz/branches/webhelp-2012-12-07/framework/widget/src/org/ofbiz/widget/screen/MacroScreenRenderer.java URL: http://svn.apache.org/viewvc/ofbiz/branches/webhelp-2012-12-07/framework/widget/src/org/ofbiz/widget/screen/MacroScreenRenderer.java?rev=1441729&r1=1441728&r2=1441729&view=diff ============================================================================== --- ofbiz/branches/webhelp-2012-12-07/framework/widget/src/org/ofbiz/widget/screen/MacroScreenRenderer.java (original) +++ ofbiz/branches/webhelp-2012-12-07/framework/widget/src/org/ofbiz/widget/screen/MacroScreenRenderer.java Sat Feb 2 10:55:01 2013 @@ -74,6 +74,7 @@ public class MacroScreenRenderer impleme private int elementId = 999; protected boolean widgetCommentsEnabled = false; private static final String formrenderer = UtilProperties.getPropertyValue("widget", "screen.formrenderer"); + private int screenLetsIdCounter = 1; public MacroScreenRenderer(String name, String macroLibraryPath) throws TemplateException, IOException { macroLibrary = FreeMarkerWorker.getTemplate(macroLibraryPath); @@ -627,11 +628,17 @@ public class MacroScreenRenderer impleme } Map<String, Object> parameters = FastMap.newInstance(); - parameters.put("id", screenlet.getId(context)); parameters.put("title", title); parameters.put("collapsible", collapsible); parameters.put("saveCollapsed", screenlet.saveCollapsed()); - parameters.put("collapsibleAreaId", screenlet.getId(context) + "_col"); + if (UtilValidate.isNotEmpty (screenlet.getId(context))) { + parameters.put("id", screenlet.getId(context)); + parameters.put("collapsibleAreaId", screenlet.getId(context) + "_col"); + } else { + parameters.put("id", "screenlet_" + screenLetsIdCounter); + parameters.put("collapsibleAreaId","screenlet_" + screenLetsIdCounter + "_col"); + screenLetsIdCounter++; + } parameters.put("expandToolTip", expandToolTip); parameters.put("collapseToolTip", collapseToolTip); parameters.put("fullUrlString", fullUrlString); |
| Free forum by Nabble | Edit this page |
