equal
deleted
inserted
replaced
82 renkan.save_renkan(updator=updator, timestamp=self.validation_timestamp, title=title, content=content, create_new_revision=create_new_revision) |
82 renkan.save_renkan(updator=updator, timestamp=self.validation_timestamp, title=title, content=content, create_new_revision=create_new_revision) |
83 except ValidationError as ve: |
83 except ValidationError as ve: |
84 raise serializers.ValidationError(str(ve.args[0])) |
84 raise serializers.ValidationError(str(ve.args[0])) |
85 # FORCE Renkan reload. |
85 # FORCE Renkan reload. |
86 # TODO: How to avoid the reload ??? |
86 # TODO: How to avoid the reload ??? |
87 return Renkan.objects.get(id=renkan.id) |
87 return Renkan.objects.select_related('current_revision').get(id=renkan.id) |
88 |
88 |
89 def validate_workspace_id(self, value): |
89 def validate_workspace_id(self, value): |
90 if self.instance is not None: |
90 if self.instance is not None: |
91 raise serializers.ValidationError("You cannot update workspace_guid") |
91 raise serializers.ValidationError("You cannot update workspace_guid") |
92 return value |
92 return value |