@nomalism-com/types 0.10.8 → 0.10.10
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.
|
@@ -207,8 +207,8 @@ export interface IFindByDocumentLineStateResponse {
|
|
|
207
207
|
name: string;
|
|
208
208
|
count: number;
|
|
209
209
|
}
|
|
210
|
-
export interface IUpdateLineStatesTriggerResponse
|
|
211
|
-
|
|
210
|
+
export interface IUpdateLineStatesTriggerResponse {
|
|
211
|
+
document_header_id: string;
|
|
212
212
|
trigger_event: boolean;
|
|
213
213
|
broker_topic?: IShared.IBrokerTopic;
|
|
214
214
|
}
|
|
@@ -223,15 +223,14 @@ export interface IRepository {
|
|
|
223
223
|
findByOwnerId(params: IShared.IFindByOwnerIdRequest): Promise<DocumentLine[]>;
|
|
224
224
|
findUnallocatedStock(): Promise<IFindUnallocatedStockResponse[]>;
|
|
225
225
|
findByState(data: IFindByDocumentLineStateRequest): Promise<IFindByDocumentLineStateResponse[]>;
|
|
226
|
-
create(data: ICreateRequest[]): Promise<
|
|
226
|
+
create(data: ICreateRequest[]): Promise<IDocumentLineAssoc.IEntityWithDocumentLine[]>;
|
|
227
227
|
update(selector: IShared.IFindByIdRequest, data: IUpdateRequest): Promise<void>;
|
|
228
|
-
updateData(data: IUpdateDataRequest): Promise<IUpdateLineStatesTriggerResponse
|
|
228
|
+
updateData(data: IUpdateDataRequest): Promise<IUpdateLineStatesTriggerResponse>;
|
|
229
229
|
updateMany(data: IUpdateManyRequest): Promise<void>;
|
|
230
230
|
updateIndexes(document_line_ids: string[]): Promise<void>;
|
|
231
231
|
deleteMany(document_line_ids: string[]): Promise<void>;
|
|
232
232
|
}
|
|
233
|
-
export type IApi = Omit<IRepository, '
|
|
234
|
-
|
|
235
|
-
updateData(data: IUpdateDataRequestWithoutStamps): Promise<IDocumentLineAssoc.Entity[]>;
|
|
233
|
+
export type IApi = Omit<IRepository, 'updateData'> & {
|
|
234
|
+
updateData(data: IUpdateDataRequestWithoutStamps): Promise<IDocumentLineAssoc.IEntityWithDocumentLine[]>;
|
|
236
235
|
};
|
|
237
236
|
export type IController = IShared.IEntityWithUserToken<IRepository>;
|
|
@@ -1,11 +1,14 @@
|
|
|
1
1
|
import * as IShared from '../../../shared/interface';
|
|
2
|
-
import { DocumentLineAssoc } from '../../../shared/entities';
|
|
2
|
+
import { DocumentLineAssoc, DocumentLine } from '../../../shared/entities';
|
|
3
3
|
import * as IDocumentLine from '../documentLine/interfaces';
|
|
4
4
|
import * as IPlot from '../../stock/plot/interface';
|
|
5
5
|
export type Entity = DocumentLineAssoc;
|
|
6
6
|
export declare const Route = "documentLineAssoc";
|
|
7
7
|
export declare const UpperName = "DocumentLineAssoc";
|
|
8
8
|
export declare const LowerName: string;
|
|
9
|
+
export interface IEntityWithDocumentLine extends Entity {
|
|
10
|
+
document_line: DocumentLine;
|
|
11
|
+
}
|
|
9
12
|
export interface IEntityExtended extends Entity {
|
|
10
13
|
document_line: IDocumentLine.IEntityExtended;
|
|
11
14
|
}
|
|
@@ -27,8 +30,8 @@ export interface IDeleteInventoryLossRequest {
|
|
|
27
30
|
export interface IRepository {
|
|
28
31
|
findById(selector: IShared.IFindByIdRequest): Promise<Entity | null>;
|
|
29
32
|
findByOwnerId(data: IShared.IFindByOwnerIdRequest): Promise<IEntityExtended[]>;
|
|
30
|
-
create(data: ICreateRequest[]): Promise<
|
|
31
|
-
update(selector: IShared.IFindByIdRequest, data: IUpdateRequest): Promise<
|
|
33
|
+
create(data: ICreateRequest[]): Promise<IEntityWithDocumentLine[]>;
|
|
34
|
+
update(selector: IShared.IFindByIdRequest, data: IUpdateRequest): Promise<IEntityWithDocumentLine>;
|
|
32
35
|
deleteInventoryLosses(data: IDeleteInventoryLossRequest): Promise<void>;
|
|
33
36
|
}
|
|
34
37
|
export type IApi = IRepository;
|