forked from uncloud/uncloud
Cleanup VMProduct serializer, add name field to VMProduct
This commit is contained in:
parent
b3bbfafa04
commit
181005ad6c
2 changed files with 7 additions and 5 deletions
|
|
@ -12,11 +12,9 @@ class VMHostSerializer(serializers.HyperlinkedModelSerializer):
|
|||
class VMProductSerializer(serializers.HyperlinkedModelSerializer):
|
||||
class Meta:
|
||||
model = VMProduct
|
||||
fields = '__all__'
|
||||
|
||||
|
||||
# def create(self, validated_data):
|
||||
# return VMSnapshotProduct()
|
||||
fields = ['uuid', 'description', 'order', 'owner', 'status', 'name', \
|
||||
'cores', 'ram_in_gb']
|
||||
read_only_fields = ['uuid', 'description', 'order', 'owner', 'status']
|
||||
|
||||
class VMSnapshotProductSerializer(serializers.ModelSerializer):
|
||||
class Meta:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue