Author: jleroux
Date: Sat Jan 31 19:58:33 2009 New Revision: 739594 URL: http://svn.apache.org/viewvc?rev=739594&view=rev Log: A patch from Bruno Busco "Removing Login/Logout from AppBarMenu" '(https://issues.apache.org/jira/browse/OFBIZ-2156) - OFBIZ-2156 Modified: ofbiz/trunk/framework/common/webcommon/includes/header.ftl ofbiz/trunk/framework/common/widget/CommonMenus.xml ofbiz/trunk/themes/bluelight/includes/header.ftl Modified: ofbiz/trunk/framework/common/webcommon/includes/header.ftl URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/common/webcommon/includes/header.ftl?rev=739594&r1=739593&r2=739594&view=diff ============================================================================== --- ofbiz/trunk/framework/common/webcommon/includes/header.ftl (original) +++ ofbiz/trunk/framework/common/webcommon/includes/header.ftl Sat Jan 31 19:58:33 2009 @@ -116,7 +116,10 @@ </li> <li>${nowTimestamp?datetime?string.short}</li> <li class="control-area"> - <p class="collapsed"><a href="setUserPreference?userPrefGroupTypeId=GLOBAL_PREFERENCES&userPrefTypeId=COMPACT_HEADER&userPrefValue=N"> </a></p> + <p class="collapsed"> + <a href="<@ofbizUrl>logout</@ofbizUrl>">${uiLabelMap.CommonLogout}</a> + <a href="setUserPreference?userPrefGroupTypeId=GLOBAL_PREFERENCES&userPrefTypeId=COMPACT_HEADER&userPrefValue=N"> </a> + </p> </li> <#else> <#if layoutSettings.headerImageUrl?exists> @@ -132,7 +135,7 @@ <li class="control-area"<#if layoutSettings.headerRightBackgroundUrl?has_content> background="${layoutSettings.headerRightBackgroundUrl}"</#if>> <#if userLogin?exists> <p class="expanded"> - <a href="<@ofbizUrl>LookupVisualThemes</@ofbizUrl>" class="buttontext">${uiLabelMap.CommonVisualThemes}</a> + <a href="<@ofbizUrl>logout</@ofbizUrl>">${uiLabelMap.CommonLogout}</a> <a href="setUserPreference?userPrefGroupTypeId=GLOBAL_PREFERENCES&userPrefTypeId=COMPACT_HEADER&userPrefValue=Y"> </a> </p> </#if> @@ -146,12 +149,20 @@ </p> <#if defaultOrganizationPartyId?exists><p>${uiLabelMap.CommonDefaultOrganizationPartyId} : ${defaultOrganizationPartyGroupName?if_exists} [${defaultOrganizationPartyId}]</p></#if> <#else> - ${uiLabelMap.CommonWelcome}! + ${uiLabelMap.CommonWelcome}! <a href="<@ofbizUrl>${checkLoginUrl}</@ofbizUrl>">${uiLabelMap.CommonLogin}</a> </p> </#if> <p>${nowTimestamp?datetime?string.short}</p> - <p>${uiLabelMap.CommonLanguageTitle} : ${locale.getDisplayName(locale)} <a href="<@ofbizUrl>LookupLocales</@ofbizUrl>" class="buttontext">${uiLabelMap.CommonChange}</a></p> - <p>${timeZone.getDisplayName(timeZone.useDaylightTime(), Static["java.util.TimeZone"].LONG, locale)} <a href="<@ofbizUrl>LookupTimezones</@ofbizUrl>" class="buttontext">${uiLabelMap.CommonChange}</a></p> + <ul id="preferences-menu"> +<!-- + <li class="first"><a href="<@ofbizUrl>Preferences</@ofbizUrl>">${uiLabelMap.CommonPreferences}</a></li> +--> + <li class="first"><a href="<@ofbizUrl>LookupLocales</@ofbizUrl>">${uiLabelMap.CommonLanguageTitle} : ${locale.getDisplayName(locale)}</a></li> + <li><a href="<@ofbizUrl>LookupTimezones</@ofbizUrl>">${timeZone.getDisplayName(timeZone.useDaylightTime(), Static["java.util.TimeZone"].LONG, locale)}</a></li> + <#if userLogin?exists> + <li><a href="<@ofbizUrl>LookupVisualThemes</@ofbizUrl>">${uiLabelMap.CommonVisualThemes}</a></li> + </#if> + </ul> </li> </#if> </ul> Modified: ofbiz/trunk/framework/common/widget/CommonMenus.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/common/widget/CommonMenus.xml?rev=739594&r1=739593&r2=739594&view=diff ============================================================================== --- ofbiz/trunk/framework/common/widget/CommonMenus.xml (original) +++ ofbiz/trunk/framework/common/widget/CommonMenus.xml Sat Jan 31 19:58:33 2009 @@ -25,15 +25,7 @@ <condition><not><if-empty field-name="userLogin"/></not></condition> <link target="main"/> </menu-item> - <menu-item name="Logout" title="${uiLabelMap.CommonLogout}" align-style="opposed"> - <condition><not><if-empty field-name="userLogin"/></not></condition> - <link target="logout"/> - </menu-item> - <menu-item name="Login" title="${uiLabelMap.CommonLogin}" align-style="opposed"> - <condition><if-empty field-name="userLogin"/></condition> - <link target="logout"/> - </menu-item> - </menu> + </menu> <menu name="CommonTabBarMenu" selected-menuitem-context-field-name="tabButtonItem" type="simple" menu-container-style="button-bar tab-bar no-clear" default-selected-style="selected" /> Modified: ofbiz/trunk/themes/bluelight/includes/header.ftl URL: http://svn.apache.org/viewvc/ofbiz/trunk/themes/bluelight/includes/header.ftl?rev=739594&r1=739593&r2=739594&view=diff ============================================================================== --- ofbiz/trunk/themes/bluelight/includes/header.ftl (original) +++ ofbiz/trunk/themes/bluelight/includes/header.ftl Sat Jan 31 19:58:33 2009 @@ -45,13 +45,13 @@ <#list layoutSettings.javaScripts as javaScript> <#if javaScriptsSet.contains(javaScript)> <#assign nothing = javaScriptsSet.remove(javaScript)/> - <script type="text/javascript" src="<@ofbizContentUrl>${javaScript}</@ofbizContentUrl>" type="text/javascript"></script> + <script src="<@ofbizContentUrl>${javaScript}</@ofbizContentUrl>" type="text/javascript"></script> </#if> </#list> </#if> <#if layoutSettings.VT_HDR_JAVASCRIPT?has_content> <#list layoutSettings.VT_HDR_JAVASCRIPT as javaScript> - <script type="text/javascript" src="<@ofbizContentUrl>${javaScript}</@ofbizContentUrl>" type="text/javascript"></script> + <script src="<@ofbizContentUrl>${javaScript}</@ofbizContentUrl>" type="text/javascript"></script> </#list> </#if> <#if layoutSettings.styleSheets?has_content> @@ -117,6 +117,7 @@ <li class="control-area"> <p class="collapsed"> ${nowTimestamp?datetime?string.short} + <a href="<@ofbizUrl>logout</@ofbizUrl>">${uiLabelMap.CommonLogout}</a> <a href="setUserPreference?userPrefGroupTypeId=GLOBAL_PREFERENCES&userPrefTypeId=COMPACT_HEADER&userPrefValue=N"> </a> </p> </li> @@ -135,6 +136,7 @@ <#if userLogin?exists> <p class="expanded"> <span class="clock">${nowTimestamp?datetime?string.short}</span> + <a href="<@ofbizUrl>logout</@ofbizUrl>">${uiLabelMap.CommonLogout}</a> <a href="setUserPreference?userPrefGroupTypeId=GLOBAL_PREFERENCES&userPrefTypeId=COMPACT_HEADER&userPrefValue=Y"> </a> </p> </#if> @@ -149,12 +151,15 @@ ${uiLabelMap.CommonWelcome}! </#if> </p> - <ul id="preferences-menu"> +<!-- + <li class="first"><a href="<@ofbizUrl>Preferences</@ofbizUrl>">${uiLabelMap.CommonPreferences}</a></li> +--> <li class="first"><a href="<@ofbizUrl>LookupLocales</@ofbizUrl>">${uiLabelMap.CommonLanguageTitle} : ${locale.getDisplayName(locale)}</a></li> <li><a href="<@ofbizUrl>LookupTimezones</@ofbizUrl>">${timeZone.getDisplayName(timeZone.useDaylightTime(), Static["java.util.TimeZone"].LONG, locale)}</a></li> - <li><a href="<@ofbizUrl>LookupVisualThemes</@ofbizUrl>">${uiLabelMap.VisualThemes}</a></li> - <li><a href="<@ofbizUrl>logout</@ofbizUrl>">${uiLabelMap.CommonLogout}</a></li> + <#if userLogin?exists> + <li><a href="<@ofbizUrl>LookupVisualThemes</@ofbizUrl>">${uiLabelMap.CommonVisualThemes}</a></li> + </#if> </ul> </li> </#if> |
Free forum by Nabble | Edit this page |