Browse Source

Proper error message and group order fix in select

Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
tags/v14.0.0beta1
John Molakvoæ (skjnldsv) 6 years ago
parent
commit
746f3c9053
No account linked to committer's email address

+ 2
- 2
settings/js/main.js
File diff suppressed because it is too large
View File


+ 1
- 1
settings/js/main.js.map
File diff suppressed because it is too large
View File


+ 3
- 1
settings/src/components/userList.vue View File

@@ -183,7 +183,9 @@ export default {
},
groups() {
// data provided php side + remove the disabled group
return this.$store.getters.getGroups.filter(group => group.id !== 'disabled');
return this.$store.getters.getGroups
.filter(group => group.id !== 'disabled')
.sort((a, b) => a.name.localeCompare(b.name));
},
subAdminsGroups() {
// data provided php side

+ 4
- 2
settings/src/store/index.js View File

@@ -10,9 +10,11 @@ const debug = process.env.NODE_ENV !== 'production';

const mutations = {
API_FAILURE(state, error) {
OC.Notification.showTemporary(t('settings','An error occured during the request. Unable to proceed.'));
let message = error.error.response.data.ocs.meta.message;
OC.Notification.showHtml(t('settings','An error occured during the request. Unable to proceed.')+'<br>'+message, {timeout: 7});
// throw to raise exception of the promise and allow a `.then` in the Vue methods
throw error;
console.log(state, error);
throw new Error(error);
}
};


Loading…
Cancel
Save