Revision ff67242a snf-astakos-app/astakos/im/models.py

b/snf-astakos-app/astakos/im/models.py
1249 1249
            q = q | Q(name__icontains=s)
1250 1250
        return self.filter(q)
1251 1251

  
1252
    def latest_of_chain(self, chain_id):
1253
        try:
1254
            return self.filter(chain=chain_id).order_by('-id')[0]
1255
        except IndexError:
1256
            return None
1252 1257

  
1253 1258
USER_STATUS_DISPLAY = {
1254 1259
      0: _('Join requested'),

Also available in: Unified diff