docs: expand input and output object types in API signatures

This commit is contained in:
seb
2026-09-16 17:45:46 +02:00
parent 9b1b7615e2
commit 5a7773df79
22 changed files with 128 additions and 89 deletions

View File

@@ -25,8 +25,8 @@ export default function update(pool) {
* @param {string} [patch.date] - The new delivery date.
* @param {number} [patch.supplierId] - The new supplier id.
* @param {string} [patch.externalNumber] - The new external (supplier) reference number.
* @param {Array<object>} [patch.lines] - The new delivery lines.
* @returns {Promise<{id: number, number: string, type: string, entityId: number, externalNumber: string|null, date: string, lines: Array<object>}>} The updated delivery.
* @param {Array<{sku?: string, name?: string, pu?: number, amount: number, net: number, rebate?: number, tax: number, comment?: string|null}>} [patch.lines] - The new delivery lines.
* @returns {Promise<{id: number, number: string, type: string, entityId: number, externalNumber: string|null, date: string, lines: Array<{id: number, sku: string|null, name: string|null, pu: number, amount: number, net: number, rebate: number, tax: number, comment: string|null}>}>} The updated delivery.
* @throws {Error} If the delivery is not found.
*
* @example