(js) Show loading progress for messages and cards

This commit is contained in:
Francis Lachapelle
2016-05-30 12:29:58 -04:00
parent c46a5f8df7
commit 5c2aedb3c9
11 changed files with 135 additions and 30 deletions
@@ -483,7 +483,7 @@
// Add new cards matching the search query
_.forEach(results, function(cardId, index) {
if (_.isUndefined(_.find(cards, _.bind(compareIds, cardId)))) {
var data = { id: cardId };
var data = { pid: addressbookId, id: cardId };
var card = new AddressBook.$Card(data, search);
cards.splice(index, 0, card);
}
@@ -686,7 +686,7 @@
// Instanciate Card objects
_.reduce(_this.ids, function(cards, card, i) {
var data = { id: card };
var data = { pid: _this.id, id: card };
// Build map of ID <=> index
_this.idsMap[data.id] = i;