@nomalism-com/types 0.40.52 → 0.40.54

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.cjs CHANGED
@@ -1804,10 +1804,12 @@ var valueByVatTaxKeys = {
1804
1804
  total: joi16.number().positive().required()
1805
1805
  };
1806
1806
  var createProviderFinancialCreditNoteBodyKeys = {
1807
- emission_date: joi16.date().required(),
1807
+ provider_id: joi16.string().uuid().optional(),
1808
+ nif: joi16.string().optional(),
1808
1809
  external_document_name: joi16.string().required(),
1809
1810
  account_code: joi16.string().allow(null, "").empty("").optional(),
1810
- provider_id: joi16.string().uuid().required(),
1811
+ auto_pay: joi16.boolean().default(false).optional(),
1812
+ emission_date: joi16.date().required(),
1811
1813
  parent_document_header_id: joi16.string().uuid().optional().allow(null, ""),
1812
1814
  observations: joi16.string().allow(null, "").required(),
1813
1815
  values: joi16.array().unique("taxPercentage").items(joi16.object().keys(valueByVatTaxKeys).required()).required()
@@ -4555,6 +4557,7 @@ var purchaseFromProviderBodyKeys = {
4555
4557
  invoice_due_date: joi83.date().required(),
4556
4558
  document_line_ids: joi83.array().items(joi83.string().required()).required(),
4557
4559
  global_discount: joi83.number().min(0).max(100).allow(null).optional(),
4560
+ account_code: joi83.string().allow(null, "").empty("").optional(),
4558
4561
  shipping: joi83.object().keys({
4559
4562
  product_id: joi83.string().required(),
4560
4563
  price: joi83.number().allow(0).positive().required()
package/dist/index.js CHANGED
@@ -1804,10 +1804,12 @@ var valueByVatTaxKeys = {
1804
1804
  total: joi16.number().positive().required()
1805
1805
  };
1806
1806
  var createProviderFinancialCreditNoteBodyKeys = {
1807
- emission_date: joi16.date().required(),
1807
+ provider_id: joi16.string().uuid().optional(),
1808
+ nif: joi16.string().optional(),
1808
1809
  external_document_name: joi16.string().required(),
1809
1810
  account_code: joi16.string().allow(null, "").empty("").optional(),
1810
- provider_id: joi16.string().uuid().required(),
1811
+ auto_pay: joi16.boolean().default(false).optional(),
1812
+ emission_date: joi16.date().required(),
1811
1813
  parent_document_header_id: joi16.string().uuid().optional().allow(null, ""),
1812
1814
  observations: joi16.string().allow(null, "").required(),
1813
1815
  values: joi16.array().unique("taxPercentage").items(joi16.object().keys(valueByVatTaxKeys).required()).required()
@@ -4555,6 +4557,7 @@ var purchaseFromProviderBodyKeys = {
4555
4557
  invoice_due_date: joi83.date().required(),
4556
4558
  document_line_ids: joi83.array().items(joi83.string().required()).required(),
4557
4559
  global_discount: joi83.number().min(0).max(100).allow(null).optional(),
4560
+ account_code: joi83.string().allow(null, "").empty("").optional(),
4558
4561
  shipping: joi83.object().keys({
4559
4562
  product_id: joi83.string().required(),
4560
4563
  price: joi83.number().allow(0).positive().required()
@@ -13,11 +13,13 @@ export interface IValueByVatTax {
13
13
  total: number;
14
14
  }
15
15
  export interface ICreateProviderFinancialCreditNoteRequest {
16
+ provider_id?: string;
17
+ nif?: string;
16
18
  external_document_name: string;
17
- provider_id: string;
18
- parent_document_header_id: string | null;
19
19
  account_code?: string | null;
20
+ auto_pay?: boolean;
20
21
  emission_date: Date;
22
+ parent_document_header_id: string | null;
21
23
  observations: string;
22
24
  values: IValueByVatTax[];
23
25
  }
@@ -67,6 +67,7 @@ export interface IPurchaseFromProviderRequest {
67
67
  note?: string;
68
68
  vat_self_accounting?: boolean;
69
69
  purchase_without_invoice: boolean;
70
+ account_code: string | null;
70
71
  }
71
72
  export interface ISyncRequest {
72
73
  provider_id: string;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@nomalism-com/types",
3
3
  "description": "A nomalism package with all necessary types and validations for developing APIs",
4
- "version": "0.40.52",
4
+ "version": "0.40.54",
5
5
  "author": "Nomalism <it.nomalism@gmail.com> (https://nomalism.com/)",
6
6
  "license": "UNLICENSED",
7
7
  "type": "module",