Mercurial > gemma
comparison client/src/stores/application.js @ 389:e7d5383bc358
feat: Primitive validation and error messages
Added simple error messages to the usermanagement
Added simple validation rules for fields:
* password rules according issue70
* email used the regex from gocode
author | Thomas Junk <thomas.junk@intevation.de> |
---|---|
date | Mon, 13 Aug 2018 16:21:26 +0200 |
parents | 88d0d60924cf |
children | 9869bc03155e |
comparison
equal
deleted
inserted
replaced
384:af82a8989b44 | 389:e7d5383bc358 |
---|---|
1 const Application = { | 1 const Application = { |
2 namespaced: true, | 2 namespaced: true, |
3 state: { | 3 state: { |
4 appTitle: process.env.VUE_APP_TITLE, | 4 appTitle: process.env.VUE_APP_TITLE, |
5 secondaryLogo: process.env.VUE_APP_SECONDARY_LOGO_URL | 5 secondaryLogo: process.env.VUE_APP_SECONDARY_LOGO_URL, |
6 sidebar: { | |
7 iscollapsed: false | |
8 } | |
6 }, | 9 }, |
7 getters: { | 10 getters: { |
11 sidebarCollapsed: state => { | |
12 return state.sidebar.iscollapsed; | |
13 }, | |
8 appTitle: state => { | 14 appTitle: state => { |
9 return state.appTitle; | 15 return state.appTitle; |
10 }, | 16 }, |
11 secondaryLogo: state => { | 17 secondaryLogo: state => { |
12 return state.secondaryLogo; | 18 return state.secondaryLogo; |
13 } | 19 } |
14 }, | 20 }, |
15 mutations: {}, | 21 mutations: { |
22 toggleSidebar: () => { | |
23 this.sidebar.iscollapsed = !this.sidebar.iscollapsed; | |
24 } | |
25 }, | |
16 actions: {} | 26 actions: {} |
17 }; | 27 }; |
18 | 28 |
19 export default Application; | 29 export default Application; |