mirror of
https://github.com/GSA/notifications-api.git
synced 2026-09-04 19:18:25 -04:00
Split schema for provider and provider history
This commit is contained in:
@@ -169,9 +169,19 @@ class ProviderDetailsSchema(BaseSchema):
|
|||||||
strict = True
|
strict = True
|
||||||
|
|
||||||
|
|
||||||
class ProviderDetailsHistorySchema(ProviderDetailsSchema):
|
class ProviderDetailsHistorySchema(BaseSchema):
|
||||||
|
created_by_user = fields.Nested(
|
||||||
|
UserSchema,
|
||||||
|
attribute='created_by',
|
||||||
|
dump_to='created_by',
|
||||||
|
only=['id', 'name', 'email_address'],
|
||||||
|
dump_only=True
|
||||||
|
)
|
||||||
|
|
||||||
class Meta:
|
class Meta:
|
||||||
model = models.ProviderDetailsHistory
|
model = models.ProviderDetailsHistory
|
||||||
|
exclude = ("provider_rates", "provider_stats")
|
||||||
|
strict = True
|
||||||
|
|
||||||
|
|
||||||
class ServiceSchema(BaseSchema):
|
class ServiceSchema(BaseSchema):
|
||||||
|
|||||||
Reference in New Issue
Block a user