<% var favoriteList = data.models; var isMobileView = isMobileView; var maxCount = isMobileView ? 3 : 4; var totalCount = (data.totalCount) ? data.totalCount : 0; var defaultPicURL = _staticContentURL+"styles/images/contacts/avatar-contact-defualt.svg"; %>
Favorites (<%=totalCount%>)
Right
<% var favLength = favoriteList.length > maxCount ? maxCount : favoriteList.length; if(favLength === 0){ %>
No Favorites
You don't have any Favorites. Select a contact below to create a Favorite.
<% } if(favLength !== 0){ %>
<% for(var favLoop= 0; favLoop< favLength; favLoop++){ var currentContact = favoriteList[favLoop]; var imgURL; if(currentContact.get('photo')){ imgURL = "../contacts/image.action?cdRequest.contactId="+currentContact.get('contactId')+"&version="+currentContact.get('version')+"&cdRequest.photoreference="+currentContact.get('photoreference') + "&csrf_string="+ csrfToken; }else{ imgURL = defaultPicURL; } %>
<%=_.escape(currentContact.get('displayName'))%>
<% } %>
<% } %>