fixing schemas interdependences

This commit is contained in:
Cayo Puigdefabregas 2021-06-15 15:22:49 +02:00
parent f7070dbbf7
commit 0a96d4f6ef
2 changed files with 1 additions and 2 deletions

View File

@ -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)

View File

@ -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__)