-
-
+
+
-
-
-
+
+
+
@@ -31,8 +35,9 @@ export default {
}
},
computed: {
- getterDashboard() {
- return this.$store.getters.getDashboardByRole(this.roleUuid)
+ listDashboard() {
+ const list = this.$store.getters.getDashboard
+ return list.filter(dashboard => this.maindashboard.id !== dashboard.id)
},
currentRole() {
return this.$store.getters['user/getRole']
@@ -40,7 +45,7 @@ export default {
getterRol() {
return this.$store.getters.getRoleUuid
},
- mainashboard() {
+ maindashboard() {
return this.$store.getters.getMainDashboard
}
},
@@ -48,7 +53,7 @@ export default {
getterRol(value) {
this.getDashboardListFromServer()
},
- mainashboard(value) {
+ maindashboard(value) {
this.getDashboardListFromServer()
}
},
@@ -62,8 +67,8 @@ export default {
roleUuid: this.currentRole.uuid
})
.then(response => {
- if (this.isEmptyValue(this.mainashboard)) {
- this.$store.dispatch('mainDashboard', response.dashboardsList[1])
+ if (this.isEmptyValue(this.maindashboard)) {
+ this.$store.dispatch('mainDashboard', response.dashboardsList[0])
}
this.dashboardList = response.dashboardsList
this.$forceUpdate()