feat(invoices|receipts|estimates|payments): auto-increment backend logic based.

This commit is contained in:
a.bouhuolia
2021-03-07 16:14:59 +02:00
parent c245f4249d
commit 42ce791713
17 changed files with 482 additions and 201 deletions

View File

@@ -432,6 +432,13 @@ export default class SaleInvoicesController extends BaseController {
],
});
}
if (error.errorType === 'SALE_INVOICE_NO_IS_REQUIRED') {
return res.boom.badRequest(null, {
errors: [
{ type: 'SALE_INVOICE_NO_IS_REQUIRED', code: 1500 },
],
});
}
}
next(error);
}