-
Type:
Bug
-
Status: Closed
-
Resolution: Duplicate
-
Affects Version/s: 6.2.5 CE GA6, 6.2.10 EE GA1
-
Component/s: Liferay Themes
-
Labels:
-
Liferay Contributor's Agreement:Accept
-
Git Pull Request:
Issue
Liferay Portal site admin theme selector always chooses default colour scheme for theme by name, not by colour scheme ID, hence incorrect default theme is applied when theme is applied.
Test Case
Test Case Purpose
Show the default color scheme is not selected (as expected) when a theme (containing color schemes) is applied.
We will toggle between a sample theme and the Classic theme to exhibit the default color scheme selection issue.
Test Case Steps
1/ Install Liferay Portal 6.2 CE or EE + Apache Tomcat bundle
2/ Start portal
3/ Configure portal using setup wizard
4/ Sign in as test user
5/ Download and install any Liferay Portal 6.2 compatible theme
e.g.
- Manzanita theme
- NOTE: We will refer to the new theme as NEW-SAMPLE-THEME)
- NOTE: Many sample themes available from Liferay Marketplace or the Liferay Portal community.
6/ Navigate to Dockbar > Admin > (Site Administration) > Pages
7/ Select NEW-SAMPLE-THEME theme
8/ Click Save button to apply NEW-SAMPLE-THEME theme to pages
9/ Select Classic theme
10/ Click Save button to apply Classic theme to pages
11/ Review outcomes
11.1/ Expected Outcome
Default color scheme is applied.
11.2 Actual Outcome
Dark color scheme is applied.
12/ Test case FAIL
Review
The Default color scheme has name "Default" and scheme id "01".
The Dark color scheme has name "Dark" and scheme id "02".
Based on the test case and observed behaviour, the color schemes as sorted according to their name, not their scheme ID, resulting in the selection of color scheme "Dark", not "Default", as expected.
Sample Liferay Portal 6.2 look and feel definition file (liferay-look-and-feel.xml)
FILE: liferay-portal-6.2.10.1-ee-ga1/tomcat/webapps/ROOT/WEB-INF/liferay-look-and-feel.xml
<?xml version="1.0"?> <!DOCTYPE look-and-feel PUBLIC "-//Liferay//DTD Look and Feel 6.2.0//EN" "http://www.liferay.com/dtd/liferay-look-and-feel_6_2_0.dtd"> <look-and-feel> <compatibility> <version>6.2.0+</version> </compatibility> <company-limit> <!-- ... --> </company-limit> <theme id="classic" name="Classic"> <root-path>/html/themes/classic</root-path> <templates-path>${root-path}/templates</templates-path> <images-path>${root-path}/images</images-path> <template-extension>vm</template-extension> <settings> <!-- ... --> </settings> <!-- ... --> <color-scheme id="01" name="Default"> <css-class>default</css-class> <color-scheme-images-path>${images-path}/color_schemes/${css-class}</color-scheme-images-path> </color-scheme> <color-scheme id="02" name="Dark"> <css-class>dark</css-class> </color-scheme> <color-scheme id="03" name="Light"> <css-class>light</css-class> </color-scheme> </theme> <!-- ... --> </look-and-feel>
Actions
- Review theme color sorting and selection logic to apply default theme according to scheme ID, not scheme name.
- duplicates
-
LPS-44156 Dark scheme is selected by default
- Closed