@nomalism-com/types 0.40.4 → 0.40.6

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
@@ -2085,7 +2085,6 @@ var updateBodyKeys13 = {
2085
2085
  var updateBody13 = joi22.object().keys(updateBodyKeys13).messages(messages);
2086
2086
  var sendEmailDocumentBodyKeys = {
2087
2087
  template: joi22.string().valid(...IUserSendEmailDocumentTemplateTypes).required(),
2088
- document_line_assoc_ids: joi22.array().items(joi22.string().uuid()),
2089
2088
  external_document_header_ids: joi22.array().items(joi22.string().uuid()),
2090
2089
  user: joi22.object().keys({
2091
2090
  name: joi22.string().required(),
@@ -5821,8 +5820,7 @@ __export(route_schema_exports112, {
5821
5820
  findQuery: () => findQuery34,
5822
5821
  findSettledMaterialEntranceBuDateParams: () => findSettledMaterialEntranceBuDateParams2,
5823
5822
  findSettledMaterialEntranceQuery: () => findSettledMaterialEntranceQuery2,
5824
- findWithPaginationQuery: () => findWithPaginationQuery28,
5825
- providerPaymentBody: () => providerPaymentBody2
5823
+ findWithPaginationQuery: () => findWithPaginationQuery28
5826
5824
  });
5827
5825
  import joi113 from "joi";
5828
5826
  var findQueryKeys32 = {};
@@ -5837,23 +5835,6 @@ var findSettledMaterialEntranceQueryKeys2 = {
5837
5835
  client_id: joi113.string().uuid().allow(null).required()
5838
5836
  };
5839
5837
  var findSettledMaterialEntranceQuery2 = joi113.object().keys(findSettledMaterialEntranceQueryKeys2).messages(messages);
5840
- var providerPaymentDocumentKeys2 = {
5841
- document_header_id: joi113.string().uuid().required(),
5842
- value: joi113.number().required(),
5843
- discount_value: joi113.number().optional().allow(0, "", null).when("value", {
5844
- is: joi113.number().positive(),
5845
- then: joi113.number().max(joi113.ref("value")),
5846
- otherwise: joi113.number().min(joi113.ref("value"))
5847
- })
5848
- };
5849
- var providerPaymentDocument2 = joi113.object().keys(providerPaymentDocumentKeys2).required();
5850
- var providerPaymentBodyKeys2 = {
5851
- provider_id: joi113.string().uuid().required(),
5852
- client_id: joi113.string().uuid().allow(null).optional(),
5853
- documents: joi113.array().items(providerPaymentDocument2).required(),
5854
- total: joi113.number().positive().allow(0).required()
5855
- };
5856
- var providerPaymentBody2 = joi113.array().items(joi113.object().keys(providerPaymentBodyKeys2)).messages(messages);
5857
5838
  var exportPaymentsBodyKeys = {
5858
5839
  value: joi113.number().positive().required(),
5859
5840
  provider: joi113.string().required(),
package/dist/index.js CHANGED
@@ -2085,7 +2085,6 @@ var updateBodyKeys13 = {
2085
2085
  var updateBody13 = joi22.object().keys(updateBodyKeys13).messages(messages);
2086
2086
  var sendEmailDocumentBodyKeys = {
2087
2087
  template: joi22.string().valid(...IUserSendEmailDocumentTemplateTypes).required(),
2088
- document_line_assoc_ids: joi22.array().items(joi22.string().uuid()),
2089
2088
  external_document_header_ids: joi22.array().items(joi22.string().uuid()),
2090
2089
  user: joi22.object().keys({
2091
2090
  name: joi22.string().required(),
@@ -5821,8 +5820,7 @@ __export(route_schema_exports112, {
5821
5820
  findQuery: () => findQuery34,
5822
5821
  findSettledMaterialEntranceBuDateParams: () => findSettledMaterialEntranceBuDateParams2,
5823
5822
  findSettledMaterialEntranceQuery: () => findSettledMaterialEntranceQuery2,
5824
- findWithPaginationQuery: () => findWithPaginationQuery28,
5825
- providerPaymentBody: () => providerPaymentBody2
5823
+ findWithPaginationQuery: () => findWithPaginationQuery28
5826
5824
  });
5827
5825
  import joi113 from "joi";
5828
5826
  var findQueryKeys32 = {};
@@ -5837,23 +5835,6 @@ var findSettledMaterialEntranceQueryKeys2 = {
5837
5835
  client_id: joi113.string().uuid().allow(null).required()
5838
5836
  };
5839
5837
  var findSettledMaterialEntranceQuery2 = joi113.object().keys(findSettledMaterialEntranceQueryKeys2).messages(messages);
5840
- var providerPaymentDocumentKeys2 = {
5841
- document_header_id: joi113.string().uuid().required(),
5842
- value: joi113.number().required(),
5843
- discount_value: joi113.number().optional().allow(0, "", null).when("value", {
5844
- is: joi113.number().positive(),
5845
- then: joi113.number().max(joi113.ref("value")),
5846
- otherwise: joi113.number().min(joi113.ref("value"))
5847
- })
5848
- };
5849
- var providerPaymentDocument2 = joi113.object().keys(providerPaymentDocumentKeys2).required();
5850
- var providerPaymentBodyKeys2 = {
5851
- provider_id: joi113.string().uuid().required(),
5852
- client_id: joi113.string().uuid().allow(null).optional(),
5853
- documents: joi113.array().items(providerPaymentDocument2).required(),
5854
- total: joi113.number().positive().allow(0).required()
5855
- };
5856
- var providerPaymentBody2 = joi113.array().items(joi113.object().keys(providerPaymentBodyKeys2)).messages(messages);
5857
5838
  var exportPaymentsBodyKeys = {
5858
5839
  value: joi113.number().positive().required(),
5859
5840
  provider: joi113.string().required(),
@@ -72,17 +72,6 @@ export interface IUnpaidPurchasesResponse extends Pick<Entity, 'date' | 'debit'
72
72
  maturity_days: number;
73
73
  observations: IObservation.IFindByOwnerResponse[];
74
74
  }
75
- export interface IProviderPaymentDocument {
76
- document_header_id: string;
77
- value: number;
78
- discount_value?: number | null;
79
- }
80
- export interface IProviderPaymentRequest {
81
- provider_id: string;
82
- client_id: string | null;
83
- documents: IProviderPaymentDocument[];
84
- total: number;
85
- }
86
75
  export interface IPaymentsNotExportedRequest {
87
76
  whiteList?: string[];
88
77
  }
@@ -3,7 +3,6 @@ import { IPaymentsNotExportedRequest } from './interface';
3
3
  export declare const findQuery: joi.ObjectSchema<any>;
4
4
  export declare const findWithPaginationQuery: joi.ObjectSchema<any>;
5
5
  export declare const findSettledMaterialEntranceQuery: joi.ObjectSchema<any>;
6
- export declare const providerPaymentBody: joi.ArraySchema<any[]>;
7
6
  export declare const exportPaymentsBody: joi.ArraySchema<any[]>;
8
7
  export declare const exportCurrentAccountBetweenDatesQuery: joi.ObjectSchema<any>;
9
8
  export declare const findSettledMaterialEntranceBuDateParams: joi.ObjectSchema<any>;
@@ -37,15 +37,6 @@ export interface IUpdateRequest {
37
37
  external_pdf_link?: string;
38
38
  pdf_link?: string;
39
39
  }
40
- export interface ISendEmailDocument {
41
- template: IShared.IUserSendEmailDocumentTemplate;
42
- external_document_header_ids: string[];
43
- document_line_assoc_ids: string[];
44
- user: {
45
- name: string;
46
- email: string;
47
- };
48
- }
49
40
  export declare enum IPublicDocumentHeaderNoteType {
50
41
  Provider = "Provider",
51
42
  Client = "Client"
@@ -59,7 +50,14 @@ export interface PublicDocumentHeaderNote {
59
50
  created_by: string;
60
51
  updated_by: string;
61
52
  }
62
- export type ISendEmailDocumentRequest = IShared.RequireOnlyOne<ISendEmailDocument, 'document_line_assoc_ids' | 'external_document_header_ids'>;
53
+ export interface ISendEmailDocumentRequest {
54
+ template: IShared.IUserSendEmailDocumentTemplate;
55
+ external_document_header_ids: string[];
56
+ user: {
57
+ name: string;
58
+ email: string;
59
+ };
60
+ }
63
61
  export interface IPublicFindByOwnerIdResponse {
64
62
  start_document_header_id: string;
65
63
  label: string;
@@ -198,10 +198,8 @@ export type IBrokerTopicPayload = {
198
198
  owner_id: string;
199
199
  document_header_id: string;
200
200
  start_document_name: string;
201
- documents: {
202
- document_header_id: string;
203
- document_name: string;
204
- document_fullname: string;
201
+ attachments: {
202
+ filename: string;
205
203
  multimedia_id: string;
206
204
  }[];
207
205
  };
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.4",
4
+ "version": "0.40.6",
5
5
  "author": "Nomalism <it.nomalism@gmail.com> (https://nomalism.com/)",
6
6
  "license": "UNLICENSED",
7
7
  "type": "module",