Rev 209 | Go to most recent revision | Details | Last modification | View Log | RSS feed
| Rev | Author | Line No. | Line |
|---|---|---|---|
| 207 | espaco | 1 | /* |
| 2 | * Copyright 2009-2014 PrimeTek. |
||
| 3 | * |
||
| 4 | * Licensed under the Apache License, Version 2.0 (the "License"); |
||
| 5 | * you may not use this file except in compliance with the License. |
||
| 6 | * You may obtain a copy of the License at |
||
| 7 | * |
||
| 8 | * http://www.apache.org/licenses/LICENSE-2.0 |
||
| 9 | * |
||
| 10 | * Unless required by applicable law or agreed to in writing, software |
||
| 11 | * distributed under the License is distributed on an "AS IS" BASIS, |
||
| 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
||
| 13 | * See the License for the specific language governing permissions and |
||
| 14 | * limitations under the License. |
||
| 15 | */ |
||
| 16 | package br.com.ec.controller; |
||
| 17 | |||
| 18 | import java.io.Serializable; |
||
| 19 | |||
| 20 | import org.springframework.context.annotation.Scope; |
||
| 21 | import org.springframework.stereotype.Controller; |
||
| 22 | |||
| 23 | @Controller |
||
| 24 | @Scope("session") |
||
| 25 | public class GuestPreferences implements Serializable { |
||
| 26 | |||
| 27 | private String inputStyleClass = ""; |
||
| 28 | private String topbarTheme = "light"; |
||
| 29 | private String menuTheme = "dim"; |
||
| 30 | private String menuMode = ""; |
||
| 31 | private String darkMode = "light"; |
||
| 32 | private String componentTheme = ""; |
||
| 33 | private boolean orientationRTL; |
||
| 34 | |||
| 35 | public String getInputStyleClass() { |
||
| 36 | return inputStyleClass; |
||
| 37 | } |
||
| 38 | public void setInputStyleClass(String inputStyleClass) { |
||
| 39 | this.inputStyleClass = inputStyleClass; |
||
| 40 | } |
||
| 41 | |||
| 42 | public String getTopbarTheme() { |
||
| 43 | return topbarTheme; |
||
| 44 | } |
||
| 45 | public void setTopbarTheme(String topbarTheme) { |
||
| 46 | this.topbarTheme = topbarTheme; |
||
| 47 | } |
||
| 48 | |||
| 49 | public String getMenuTheme() { |
||
| 50 | return menuTheme; |
||
| 51 | } |
||
| 52 | public void setMenuTheme(String menuTheme) { |
||
| 53 | this.menuTheme = menuTheme; |
||
| 54 | } |
||
| 55 | |||
| 56 | public String getMenuMode() { |
||
| 57 | return menuMode; |
||
| 58 | } |
||
| 59 | public void setMenuMode(String menuMode) { |
||
| 60 | this.menuMode = menuMode; |
||
| 61 | } |
||
| 62 | |||
| 63 | public String getDarkMode() { |
||
| 64 | return darkMode; |
||
| 65 | } |
||
| 66 | public void setDarkMode(String darkMode) { |
||
| 67 | this.darkMode = darkMode; |
||
| 68 | } |
||
| 69 | |||
| 70 | public boolean isOrientationRTL() { |
||
| 71 | return orientationRTL; |
||
| 72 | } |
||
| 73 | public void setOrientationRTL(boolean orientationRTL) { |
||
| 74 | this.orientationRTL = orientationRTL; |
||
| 75 | } |
||
| 76 | |||
| 77 | /* |
||
| 78 | private Map<String,String> themeColors; |
||
| 79 | |||
| 80 | private String theme = "blue"; |
||
| 81 | |||
| 82 | private String menuLayout = "static"; |
||
| 83 | |||
| 84 | @PostConstruct |
||
| 85 | public void init() { |
||
| 86 | themeColors = new HashMap<String,String>(); |
||
| 87 | themeColors.put("turquoise", "#00acac"); |
||
| 88 | themeColors.put("blue", "#2f8ee5"); |
||
| 89 | themeColors.put("orange", "#efa64c"); |
||
| 90 | themeColors.put("purple", "#6c76af"); |
||
| 91 | themeColors.put("pink", "#f16383"); |
||
| 92 | themeColors.put("light-blue", "#63c9f1"); |
||
| 93 | themeColors.put("green", "#57c279"); |
||
| 94 | themeColors.put("deep-purple", "#7e57c2"); |
||
| 95 | } |
||
| 96 | |||
| 97 | public String getTopbarTheme() { |
||
| 98 | return "light"; |
||
| 99 | } |
||
| 100 | |||
| 101 | public String getTheme() { |
||
| 102 | return theme; |
||
| 103 | } |
||
| 104 | |||
| 105 | public String getMenuLayout() { |
||
| 106 | if(this.menuLayout.equals("static")) |
||
| 107 | return "menu-layout-static"; |
||
| 108 | else if(this.menuLayout.equals("overlay")) |
||
| 109 | return "menu-layout-overlay"; |
||
| 110 | else if(this.menuLayout.equals("horizontal")) |
||
| 111 | return "menu-layout-static menu-layout-horizontal"; |
||
| 112 | else |
||
| 113 | return "menu-layout-static"; |
||
| 114 | } |
||
| 115 | |||
| 116 | public void setTheme(String theme) { |
||
| 117 | this.theme = theme; |
||
| 118 | } |
||
| 119 | |||
| 120 | public void setMenuLayout(String menuLayout) { |
||
| 121 | this.menuLayout = menuLayout; |
||
| 122 | } |
||
| 123 | |||
| 124 | public Map getThemeColors() { |
||
| 125 | return this.themeColors; |
||
| 126 | } |
||
| 127 | */ |
||
| 128 | } |