@nomalism-com/types 0.10.6 → 0.10.8
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<T> {
|
|
211
|
+
data: T;
|
|
212
212
|
trigger_event: boolean;
|
|
213
213
|
broker_topic?: IShared.IBrokerTopic;
|
|
214
214
|
}
|
|
@@ -225,14 +225,13 @@ export interface IRepository {
|
|
|
225
225
|
findByState(data: IFindByDocumentLineStateRequest): Promise<IFindByDocumentLineStateResponse[]>;
|
|
226
226
|
create(data: ICreateRequest[]): Promise<string>;
|
|
227
227
|
update(selector: IShared.IFindByIdRequest, data: IUpdateRequest): Promise<void>;
|
|
228
|
-
updateData(data: IUpdateDataRequest): Promise<IUpdateLineStatesTriggerResponse
|
|
228
|
+
updateData(data: IUpdateDataRequest): Promise<IUpdateLineStatesTriggerResponse<IDocumentLineAssoc.Entity[]>>;
|
|
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, 'create' | '
|
|
233
|
+
export type IApi = Omit<IRepository, 'create' | 'updateData'> & {
|
|
234
234
|
create(data: ICreateRequest[]): Promise<IDocumentLineAssoc.Entity[]>;
|
|
235
|
-
update(selector: IShared.IFindByIdRequest, data: IUpdateRequest): Promise<void>;
|
|
236
235
|
updateData(data: IUpdateDataRequestWithoutStamps): Promise<IDocumentLineAssoc.Entity[]>;
|
|
237
236
|
};
|
|
238
237
|
export type IController = IShared.IEntityWithUserToken<IRepository>;
|
|
@@ -27,12 +27,9 @@ export interface IDeleteInventoryLossRequest {
|
|
|
27
27
|
export interface IRepository {
|
|
28
28
|
findById(selector: IShared.IFindByIdRequest): Promise<Entity | null>;
|
|
29
29
|
findByOwnerId(data: IShared.IFindByOwnerIdRequest): Promise<IEntityExtended[]>;
|
|
30
|
-
create(data: ICreateRequest[]): Promise<string>;
|
|
31
|
-
update(selector: IShared.IFindByIdRequest, data: IUpdateRequest): Promise<string>;
|
|
32
|
-
deleteInventoryLosses(data: IDeleteInventoryLossRequest): Promise<void>;
|
|
33
|
-
}
|
|
34
|
-
export type IApi = Omit<IRepository, 'create' | 'update'> & {
|
|
35
30
|
create(data: ICreateRequest[]): Promise<Entity[]>;
|
|
36
31
|
update(selector: IShared.IFindByIdRequest, data: IUpdateRequest): Promise<Entity>;
|
|
37
|
-
|
|
32
|
+
deleteInventoryLosses(data: IDeleteInventoryLossRequest): Promise<void>;
|
|
33
|
+
}
|
|
34
|
+
export type IApi = IRepository;
|
|
38
35
|
export type IController = IShared.IEntityWithUserToken<IRepository>;
|