Refactor user management component
Removing dedicated methods to get user accounts and settings
since component methods aren't reused and subsequent requests
after initial load are handled on Store level.
Signed-off-by: Yoshie Muranaka <yoshiemuranaka@gmail.com>
Change-Id: I18bc18eea0e2e47af01afb518ccd7f0e99c414ab
diff --git a/src/views/AccessControl/LocalUserManagement/LocalUserManagement.vue b/src/views/AccessControl/LocalUserManagement/LocalUserManagement.vue
index 23b06dd..c08b39b 100644
--- a/src/views/AccessControl/LocalUserManagement/LocalUserManagement.vue
+++ b/src/views/AccessControl/LocalUserManagement/LocalUserManagement.vue
@@ -198,16 +198,10 @@
}
},
created() {
- this.getUsers();
- this.getAccountSettings();
+ this.$store.dispatch('localUsers/getUsers');
+ this.$store.dispatch('localUsers/getAccountSettings');
},
methods: {
- getUsers() {
- this.$store.dispatch('localUsers/getUsers');
- },
- getAccountSettings() {
- this.$store.dispatch('localUsers/getAccountSettings');
- },
initModalUser(user) {
this.activeUser = user;
this.$bvModal.show('modal-user');