Changeset View
Changeset View
Standalone View
Standalone View
src/resources/js/app.js
Show First 20 Lines • Show All 327 Lines • ▼ Show 20 Lines | methods: { | ||||
} | } | ||||
if (!list.isLdapReady) { | if (!list.isLdapReady) { | ||||
return this.$t('status.notready') | return this.$t('status.notready') | ||||
} | } | ||||
return this.$t('status.active') | return this.$t('status.active') | ||||
}, | }, | ||||
isDegraded() { | |||||
return store.state.authInfo.isAccountDegraded | |||||
}, | |||||
pageName(path) { | pageName(path) { | ||||
let page = this.$route.path | let page = this.$route.path | ||||
// check if it is a "menu page", find the page name | // check if it is a "menu page", find the page name | ||||
// otherwise we'll use the real path as page name | // otherwise we'll use the real path as page name | ||||
window.config.menu.every(item => { | window.config.menu.every(item => { | ||||
if (item.location == page && item.page) { | if (item.location == page && item.page) { | ||||
page = item.page | page = item.page | ||||
Show All 22 Lines | methods: { | ||||
dialog.find('input').first().focus() | dialog.find('input').first().focus() | ||||
}).modal() | }).modal() | ||||
}, | }, | ||||
userStatusClass(user) { | userStatusClass(user) { | ||||
if (user.isDeleted) { | if (user.isDeleted) { | ||||
return 'text-muted' | return 'text-muted' | ||||
} | } | ||||
if (user.isSuspended) { | if (user.isDegraded || user.isAccountDegraded || user.isSuspended) { | ||||
return 'text-warning' | return 'text-warning' | ||||
} | } | ||||
if (!user.isImapReady || !user.isLdapReady) { | if (!user.isImapReady || !user.isLdapReady) { | ||||
return 'text-danger' | return 'text-danger' | ||||
} | } | ||||
return 'text-success' | return 'text-success' | ||||
}, | }, | ||||
userStatusText(user) { | userStatusText(user) { | ||||
if (user.isDeleted) { | if (user.isDeleted) { | ||||
return this.$t('status.deleted') | return this.$t('status.deleted') | ||||
} | } | ||||
if (user.isDegraded || user.isAccountDegraded) { | |||||
return this.$t('status.degraded') | |||||
} | |||||
if (user.isSuspended) { | if (user.isSuspended) { | ||||
return this.$t('status.suspended') | return this.$t('status.suspended') | ||||
} | } | ||||
if (!user.isImapReady || !user.isLdapReady) { | if (!user.isImapReady || !user.isLdapReady) { | ||||
return this.$t('status.notready') | return this.$t('status.notready') | ||||
} | } | ||||
▲ Show 20 Lines • Show All 125 Lines • Show Last 20 Lines |