{"$schema":"http://json-schema.org/draft-07/schema#","additionalProperties":false,"description":"Data describing the reception of an order.","properties":{"$schema":{"default":"https://bib.rero.ch/schemas/acq_receipts/acq_receipt-v0.0.1.json","pattern":"^https://bib.rero.ch/schemas/acq_receipts/acq_receipt-v([0-9]+?\\.){3}json$","title":"Schema","type":"string"},"acq_order":{"additionalProperties":false,"properties":{"$ref":{"pattern":"^https://bib.rero.ch/api/acq_orders/.*?$","title":"Order","type":"string"}},"required":["$ref"],"title":"Order","type":"object"},"amount_adjustments":{"items":{"additionalProperties":false,"properties":{"acq_account":{"properties":{"$ref":{"pattern":"^https://bib.rero.ch/api/acq_accounts/.*?$","title":"Acquisition account URI","type":"string","widget":{"formlyConfig":{"focus":true,"hideLabel":true,"type":"account-select"}}}},"required":["$ref"],"title":"Acquisition account","type":"object"},"amount":{"title":"Amount","type":"number"},"label":{"minLength":3,"title":"Label","type":"string"}},"propertiesOrder":["label","amount","acq_account"],"required":["label","amount","acq_account"],"title":"Fee","type":"object"},"minItems":1,"title":"Additional fees, discount and credit","type":"array"},"library":{"additionalProperties":false,"properties":{"$ref":{"pattern":"^https://bib.rero.ch/api/libraries/.*?$","title":"Library URI","type":"string"}},"required":["$ref"],"title":"Library","type":"object"},"notes":{"items":{"additionalProperties":false,"properties":{"content":{"maxLength":2000,"minLength":1,"title":"Content","type":"string","widget":{"formlyConfig":{"props":{"rows":3},"type":"textarea"}}},"type":{"default":"staff_note","enum":["staff_note"],"title":"Type","type":"string","widget":{"formlyConfig":{"props":{"options":[{"label":"staff_note","value":"staff_note"}],"sort":true},"type":"select"}}}},"propertiesOrder":["type","content"],"required":["type","content"],"title":"Note","type":"object"},"maxItems":1,"minItems":1,"title":"Notes","type":"array","widget":{"formlyConfig":{"props":{"validation":{"messages":{"uniqueValueKeysInObjectMessage":"Only one note per type is allowed"},"validators":{"uniqueValueKeysInObject":{"keys":["type"]}}}}}}},"organisation":{"additionalProperties":false,"properties":{"$ref":{"pattern":"^https://bib.rero.ch/api/organisations/.*?$","title":"Organisation URI","type":"string"}},"required":["$ref"],"title":"Organisation","type":"object"},"pid":{"minLength":1,"title":"Acquisition receipt ID","type":"string"},"reference":{"minLength":3,"title":"Reference","type":"string"}},"propertiesOrder":["reference","amount_adjustments","notes"],"required":["$schema","pid","acq_order"],"title":"Acquisition receipt","type":"object"}
