add user_user support to atlas collections
This commit is contained in:
@@ -542,6 +542,16 @@ class BaseReportAnswer(models.Model):
|
||||
def get_answer_score(self):
|
||||
return self.score
|
||||
|
||||
def set_cid_or_user(self, cid=None, user=None):
|
||||
if cid is not None:
|
||||
self.cid = cid
|
||||
elif user is not None:
|
||||
self.user = user
|
||||
else:
|
||||
raise ValueError("No cid or user specified")
|
||||
|
||||
|
||||
|
||||
class Meta:
|
||||
abstract = True
|
||||
|
||||
|
||||
Reference in New Issue
Block a user