diff --git a/ereuse_devicehub/resources/lot/schemas.py b/ereuse_devicehub/resources/lot/schemas.py index 5dcf9f63..5604cc2e 100644 --- a/ereuse_devicehub/resources/lot/schemas.py +++ b/ereuse_devicehub/resources/lot/schemas.py @@ -28,5 +28,5 @@ class Lot(Thing): transfer_state = EnumField(TransferState, description=m.Lot.transfer_state.comment) receiver_address = SanitizedStr(validate=f.validate.Length(max=42)) deliverynote = NestedOn(s_deliverynote.Deliverynote, dump_only=True) - documents = NestedOn(s_document.TradeDocument, dump_only=True) + documents = NestedOn('TradeDocument', many=True, dump_only=True) trade = NestedOn(s_action.Trade, dump_only=True) diff --git a/ereuse_devicehub/resources/tradedocument/schemas.py b/ereuse_devicehub/resources/tradedocument/schemas.py index e63610ec..8e96e54a 100644 --- a/ereuse_devicehub/resources/tradedocument/schemas.py +++ b/ereuse_devicehub/resources/tradedocument/schemas.py @@ -25,4 +25,3 @@ class TradeDocument(Thing): description=m.TradeDocument.file_hash.comment) url = URL(description=m.TradeDocument.url.comment) lot = NestedOn('Lot', only_query='id', description=m.TradeDocument.lot.__doc__) - # lot = NestedOn(s_lot.Lot, only_query='id', description=m.TradeDocument.lot.__doc__)