1
0
mirror of https://github.com/nerzhul/ocsms.git synced 2025-06-07 07:56:23 +00:00

ContactList is now working properly

This commit is contained in:
Loic Blot 2018-09-06 22:59:27 +02:00 committed by Loïc Blot
parent ffdb597b1e
commit b5f67d59f2
2 changed files with 3 additions and 3 deletions

View File

@ -54,7 +54,7 @@ var ContactList = new Vue({
contactObj.uid = peerLabel; contactObj.uid = peerLabel;
} }
ContactList.addContact(contactObj); self.addContact(contactObj);
bufferedContacts.push(peerLabel); bufferedContacts.push(peerLabel);
} }
}); });

View File

@ -21,8 +21,8 @@ use \OCA\OcSms\Lib\CountryCodes;
<div id="app-contacts-loader" class="icon-loading" v-if="isContactsLoading"> <div id="app-contacts-loader" class="icon-loading" v-if="isContactsLoading">
</div> </div>
<div v-if="!isContactsLoading"> <div v-if="!isContactsLoading">
<div class="contact-list-no-contact" v-if="orderedContacts | length == 0 && !isContactsLoading"><?php p($l->t('No contact found.'));?></div> <div class="contact-list-no-contact" v-if="orderedContacts.length == 0 && !isContactsLoading"><?php p($l->t('No contact found.'));?></div>
<ul class="ng-cloak contact-list" v-if="orderedContacts | length > 0"> <ul class="contact-list" v-if="orderedContacts.length > 0">
<li v-for="contact in orderedContacts" peer-label="{{ contact.label }}" v-on:click="loadConversation(contact);" href="#"> <li v-for="contact in orderedContacts" peer-label="{{ contact.label }}" v-on:click="loadConversation(contact);" href="#">
<img class="ocsms-plavatar" ng-src="{{ contact.avatar }}" ng-show="contact.avatar !== undefined" /> <img class="ocsms-plavatar" ng-src="{{ contact.avatar }}" ng-show="contact.avatar !== undefined" />
<div class="ocsms-plavatar" v-if="contact.avatar === undefined" ng-style="{'background-color': (contact.uid | peerColor)}">{{ contact.label | firstCharacter }}</div> <div class="ocsms-plavatar" v-if="contact.avatar === undefined" ng-style="{'background-color': (contact.uid | peerColor)}">{{ contact.label | firstCharacter }}</div>