Esempio n. 1
0
 def action_editmeta(self, user, timestamp, key, value, data):
     from item.models import Metadata
     m = Metadata.get(key, value)
     if not m or m.timestamp < timestamp:
         if not m:
             m = Metadata.get_or_create(key, value)
         if m.edit(data):
             m.update_items()
     user.clear_smart_list_cache()
     return True
Esempio n. 2
0
 def action_editmeta(self, user, timestamp, key, value, data):
     from item.models import Metadata
     m = Metadata.get(key, value)
     if not m or m.timestamp < timestamp:
         if not m:
             m = Metadata.get_or_create(key, value)
         if m.edit(data):
             m.update_items()
     user.clear_smart_list_cache()
     return True
Esempio n. 3
0
 def action_resetmeta(self, user, timestamp, key, value):
     from item.models import Metadata
     m = Metadata.get(key, value)
     if m and m.timestamp < timestamp:
         m.reset()
     user.clear_smart_list_cache()
     return True
Esempio n. 4
0
 def action_resetmeta(self, user, timestamp, key, value):
     from item.models import Metadata
     m = Metadata.get(key, value)
     if m and m.timestamp < timestamp:
         m.reset()
     user.clear_smart_list_cache()
     return True