update ui

Signed-off-by: Jörn Friedrich Dreyer <jfd@butonic.de>
This commit is contained in:
Jörn Friedrich Dreyer
2020-07-09 15:54:54 +02:00
parent 9d63ca148a
commit 0f64397e79
2 changed files with 4 additions and 4 deletions

View File

@@ -15,9 +15,9 @@
<oc-table-group>
<oc-table-row v-for="account in accounts" :key="`account-list-row-${account.id}`">
<oc-table-cell>
<avatar :user-name="account.displayName || account.preferredName" :userid="account.id" :width="35" />
<avatar :user-name="account.displayName || account.onPremisesSamAccountName" :userid="account.id" :width="35" />
</oc-table-cell>
<oc-table-cell v-text="account.preferredName" />
<oc-table-cell v-text="account.onPremisesSamAccountName" />
<oc-table-cell v-text="account.displayName || '-'" />
<oc-table-cell v-text="account.mail" />
<oc-table-cell v-text="account.uidNumber || '-'" />

View File

@@ -15,10 +15,10 @@ const getters = {
isInitialized: state => state.initialized,
getAccountsSorted: state => {
return Object.values(state.accounts).sort((a1, a2) => {
if (a1.preferredName === a2.preferredName) {
if (a1.onPremisesSamAccountName === a2.onPremisesSamAccountName) {
return a1.id.localeCompare(a2.id)
}
return a1.preferredName.localeCompare(a2.preferredName)
return a1.onPremisesSamAccountName.localeCompare(a2.onPremisesSamAccountName)
})
}
}