コード例 #1
0
 def action_editlist(self, user, timestamp, name, new):
     from user.models import List
     l = List.get_or_create(user.id, name)
     if 'name' in new:
         l.name = new['name']
     l.save()
     user.clear_list_cache()
     return True
コード例 #2
0
 def action_editlist(self, user, timestamp, name, new):
     from user.models import List
     l = List.get_or_create(user.id, name)
     if 'name' in new:
         l.name = new['name']
     l.save()
     user.clear_list_cache()
     return True
コード例 #3
0
 def action_orderlists(self, user, timestamp, lists):
     from user.models import List
     idx = 0
     for name in lists:
         l = List.get_or_create(user.id, name)
         l.index_ = idx
         l.save()
         idx += 1
     return True
コード例 #4
0
 def action_orderlists(self, user, timestamp, lists):
     from user.models import List
     idx = 0
     for name in lists:
         l = List.get_or_create(user.id, name)
         l.index_ = idx
         l.save()
         idx += 1
     return True
コード例 #5
0
 def action_addlistitems(self, user, timestamp, name, ids):
     from user.models import List
     l = List.get_or_create(user.id, name)
     l.add_items(ids)
     return True
コード例 #6
0
 def action_addlistitems(self, user, timestamp, name, ids):
     from user.models import List
     l = List.get_or_create(user.id, name)
     l.add_items(ids)
     return True