@nomalism-com/types 0.10.61 → 0.10.63

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.
@@ -271,6 +271,7 @@ export interface ICreateProviderCreditNoteFromReturnRequest {
271
271
  document_headers: ICreateProviderCreditNoteFromReturnDocumentHeaders[];
272
272
  }
273
273
  export interface ICreateFromHeaderResponse {
274
+ rollbackIds: string[];
274
275
  brokerMessages: IShared.IBrokerMessage<IShared.IBrokerTopic>[];
275
276
  tasks: IShared.ITaskCluster[];
276
277
  }
@@ -1,10 +1,9 @@
1
1
  import * as IShared from '../../../shared/interface';
2
- import { DocumentLine, DocumentLineBaseVirtuals, DocumentLineVirtuals, DocumentLineFolder } from '../../../shared/entities';
2
+ import { DocumentLine, DocumentLineBaseVirtuals, DocumentLineVirtuals, DocumentLineFolder, DocumentLinePendingConflict } from '../../../shared/entities';
3
3
  import * as IDocumentLineAssoc from '../documentLineAssoc/interfaces';
4
4
  import * as IDocumentHeader from '../documentHeader/interfaces';
5
5
  import * as IDocumentType from '../documentType/interfaces';
6
6
  import * as IPlot from '../../stock/plot/interface';
7
- import { IConflictFindByOwnerIdResponse } from '../propostaSheets/interface';
8
7
  export type Entity = DocumentLine;
9
8
  export declare const Route = "documentLine";
10
9
  export declare const UpperName = "DocumentLine";
@@ -140,7 +139,7 @@ export interface IEntityExtended extends DocumentLine {
140
139
  document_headers: IDocumentLineDocuments[];
141
140
  document_line_folder: DocumentLineFolder | null;
142
141
  plot: IPlot.IFindDetailedResponseWithoutCurrentDocumentLine | null;
143
- pending_conflict: IConflictFindByOwnerIdResponse | null;
142
+ pending_conflict: DocumentLinePendingConflict | null;
144
143
  }
145
144
  export interface ICreateRequest extends Omit<IDocumentLineAssoc.ICreateRequest, 'document_line_id'> {
146
145
  document_line_id?: string;
@@ -19,19 +19,17 @@ export interface IConflictFindByOwnerIdResponse extends Entity {
19
19
  designation: string;
20
20
  reference: string;
21
21
  };
22
- updated_price_sale: number;
23
22
  }
24
23
  export interface ICreateSheetFromDocumentResponse {
25
24
  google_sheet_id: string;
26
25
  }
27
26
  export interface IRepository {
28
27
  importFromSheet(params: IShared.IFindByIdRequest): Promise<IFindByGooglesheetIdResponse>;
29
- conflictCreate(params: IShared.IFindByIdRequest, data: IConflictCreateRequest): Promise<void>;
30
28
  conflictAccept(params: IShared.IFindByIdRequest): Promise<void>;
31
29
  conflictDelete(params: IShared.IFindByIdRequest): Promise<void>;
32
30
  conflictFindByOwnerId(params: IShared.IFindByOwnerIdRequest): Promise<IConflictFindByOwnerIdResponse[]>;
33
31
  }
34
- export type IApi = Omit<IRepository, 'conflictCreate' | 'createSheetFromDocument'> & {
32
+ export type IApi = Omit<IRepository, 'createSheetFromDocument'> & {
35
33
  createSheetFromDocument(params: IShared.IFindByIdRequest): Promise<ICreateSheetFromDocumentResponse>;
36
34
  };
37
35
  export type IController = IShared.IEntityWithUserToken<IRepository>;
@@ -1,3 +1,2 @@
1
1
  import joi from 'joi';
2
2
  export declare const findByGoogleSheetId: joi.ObjectSchema<any>;
3
- export declare const createConflict: joi.ObjectSchema<any>;
@@ -3,10 +3,9 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
3
3
  return (mod && mod.__esModule) ? mod : { "default": mod };
4
4
  };
5
5
  Object.defineProperty(exports, "__esModule", { value: true });
6
- exports.createConflict = exports.findByGoogleSheetId = void 0;
6
+ exports.findByGoogleSheetId = void 0;
7
7
  var joi_1 = __importDefault(require("joi"));
8
8
  var messages_1 = require("../../../shared/messages");
9
- var interface_1 = require("./interface");
10
9
  var findByGoogleSheetIdKeys = {
11
10
  id: joi_1.default.string().required(),
12
11
  };
@@ -14,15 +13,3 @@ exports.findByGoogleSheetId = joi_1.default
14
13
  .object()
15
14
  .keys(findByGoogleSheetIdKeys)
16
15
  .messages(messages_1.messages);
17
- var createConflictKeys = {
18
- document_line_id: joi_1.default.string().uuid().required(),
19
- designation: joi_1.default.string().optional(),
20
- quantity: joi_1.default.number().positive().optional(),
21
- price_sale: joi_1.default.number().positive().optional(),
22
- discount: joi_1.default.number().positive().allow(0).max(99).optional(),
23
- conflict: joi_1.default.string().valid(interface_1.IConflictEnum).optional(),
24
- };
25
- exports.createConflict = joi_1.default
26
- .object()
27
- .keys(createConflictKeys)
28
- .messages(messages_1.messages);
@@ -793,6 +793,7 @@ export type DocumentLinePendingConflict = {
793
793
  designation: string;
794
794
  quantity: number;
795
795
  price_sale: number;
796
+ updated_product_price_sale?: number | null;
796
797
  discount: number;
797
798
  conflict: IConflict;
798
799
  created_at: Date;
package/package.json CHANGED
@@ -9,7 +9,7 @@
9
9
  "typescript",
10
10
  "helper"
11
11
  ],
12
- "version": "0.10.61",
12
+ "version": "0.10.63",
13
13
  "main": "./dist/index.js",
14
14
  "types": "./dist/index.d.ts",
15
15
  "files": [