diff --git a/models/resources/data.go b/models/resources/data.go index eb3f6b5..5e24e6f 100644 --- a/models/resources/data.go +++ b/models/resources/data.go @@ -50,7 +50,7 @@ func (abs *DataResource) ConvertToPricedResource( type DataInstance struct { ResourceInstance[*DataResourcePartnership] - Source string `json:"source" bson:"source"` // Source is the source of the data + Source string `json:"source,omitempty" bson:"source,omitempty"` // Source is the source of the data } func (ri *DataInstance) StoreDraftDefault() { diff --git a/models/resources/storage.go b/models/resources/storage.go index 10bb53a..dfd1cc8 100644 --- a/models/resources/storage.go +++ b/models/resources/storage.go @@ -43,7 +43,7 @@ func (abs *StorageResource) ConvertToPricedResource( type StorageResourceInstance struct { ResourceInstance[*StorageResourcePartnership] - Source string `bson:"source" json:"source"` // Source is the source of the storage + Source string `bson:"source,omitempty" json:"source,omitempty"` // Source is the source of the storage Local bool `bson:"local" json:"local"` SecurityLevel string `bson:"security_level,omitempty" json:"security_level,omitempty"` SizeType enum.StorageSize `bson:"size_type" json:"size_type" default:"0"` // SizeType is the type of the storage size