establishment back list
This commit is contained in:
parent
35d94e6f76
commit
851c9fc830
|
|
@ -97,6 +97,10 @@ class Review(BaseAttributes, TranslatedFieldsMixin):
|
||||||
|
|
||||||
objects = ReviewQuerySet.as_manager()
|
objects = ReviewQuerySet.as_manager()
|
||||||
|
|
||||||
|
@property
|
||||||
|
def status_display(self):
|
||||||
|
return self.REVIEW_STATUSES[self.status][1]
|
||||||
|
|
||||||
class Meta:
|
class Meta:
|
||||||
"""Meta class."""
|
"""Meta class."""
|
||||||
verbose_name = _('Review')
|
verbose_name = _('Review')
|
||||||
|
|
|
||||||
|
|
@ -4,14 +4,19 @@ from review.models import Review, Inquiries, GridItems
|
||||||
|
|
||||||
|
|
||||||
class ReviewBaseSerializer(serializers.ModelSerializer):
|
class ReviewBaseSerializer(serializers.ModelSerializer):
|
||||||
|
text_translated = serializers.CharField(read_only=True)
|
||||||
|
status_display = serializers.CharField(read_only=True)
|
||||||
|
|
||||||
class Meta:
|
class Meta:
|
||||||
model = Review
|
model = Review
|
||||||
fields = (
|
fields = (
|
||||||
'id',
|
'id',
|
||||||
'reviewer',
|
'reviewer',
|
||||||
'text',
|
'text',
|
||||||
|
'text_translated',
|
||||||
'priority',
|
'priority',
|
||||||
'status',
|
'status',
|
||||||
|
'status_display',
|
||||||
'child',
|
'child',
|
||||||
'published_at',
|
'published_at',
|
||||||
'vintage',
|
'vintage',
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user