@pksep/zod-shared 0.0.515 → 0.0.517
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/action/dto/actions-by-param.dto.d.ts +3 -0
- package/dist/action/dto/actions-by-param.dto.js +1 -0
- package/dist/action/enums/enums.d.ts +1 -6
- package/dist/action/enums/enums.js +0 -5
- package/dist/action/schemas/actions.schema.d.ts +3 -0
- package/dist/action/schemas/actions.schema.js +2 -1
- package/dist/action/types/types.d.ts +3 -0
- package/dist/equipment/schemas/equipment.schema.d.ts +5 -0
- package/dist/moving/schemas/moving.schema.d.ts +7 -0
- package/dist/production-tasks/dto/get-production-task-by-equipment.dto.d.ts +3 -0
- package/dist/production-tasks/dto/get-production-task-by-equipment.dto.js +1 -0
- package/dist/production-tasks/dto/get-production-task-by-operation.dto.d.ts +3 -0
- package/dist/production-tasks/dto/get-production-task-by-operation.dto.js +1 -0
- package/dist/production-tasks/dto/get-production-task-by-user.dto.d.ts +3 -0
- package/dist/production-tasks/dto/get-production-task-by-user.dto.js +1 -0
- package/dist/production-tasks/dto/workload-by-entity.dto.d.ts +9 -0
- package/dist/production-tasks/dto/workload-by-entity.dto.js +4 -1
- package/dist/production-tasks/interfaces/production-tasks.d.ts +11 -6
- package/dist/role/schemas/role.schema.d.ts +7 -0
- package/dist/user/index.d.ts +0 -2
- package/dist/user/index.js +0 -2
- package/dist/user/schemas/user.schema.d.ts +5 -0
- package/dist/utils/date.methods.d.ts +8 -0
- package/dist/utils/date.methods.js +13 -0
- package/dist/utils/index.d.ts +0 -3
- package/dist/utils/index.js +0 -3
- package/dist/utils/tables-config/enum.d.ts +1 -0
- package/dist/utils/tables-config/enum.js +3 -0
- package/dist/utils/tables-config/tables-array.js +1 -0
- package/dist/utils/types/types.d.ts +2 -0
- package/package.json +1 -1
|
@@ -6,6 +6,7 @@ export declare const ActionsByParamDtoZod: z.ZodObject<{
|
|
|
6
6
|
searchString: z.ZodOptional<z.ZodString>;
|
|
7
7
|
typeObject: z.ZodDefault<z.ZodNullable<z.ZodNativeEnum<typeof ActionEntityTypes>>>;
|
|
8
8
|
idObject: z.ZodNullable<z.ZodOptional<z.ZodNumber>>;
|
|
9
|
+
relativeActionType: z.ZodDefault<z.ZodOptional<z.ZodNullable<z.ZodNativeEnum<typeof ActionEntityTypes>>>>;
|
|
9
10
|
operationId: z.ZodNullable<z.ZodOptional<z.ZodNumber>>;
|
|
10
11
|
rangeDate: z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
11
12
|
start: z.ZodAny;
|
|
@@ -19,6 +20,7 @@ export declare const ActionsByParamDtoZod: z.ZodObject<{
|
|
|
19
20
|
}>>>;
|
|
20
21
|
}, "strip", z.ZodTypeAny, {
|
|
21
22
|
typeObject: ActionEntityTypes | null;
|
|
23
|
+
relativeActionType: ActionEntityTypes | null;
|
|
22
24
|
operationId?: number | null | undefined;
|
|
23
25
|
searchString?: string | undefined;
|
|
24
26
|
responsibleId?: number[] | undefined;
|
|
@@ -35,6 +37,7 @@ export declare const ActionsByParamDtoZod: z.ZodObject<{
|
|
|
35
37
|
offset?: number | undefined;
|
|
36
38
|
typeObject?: ActionEntityTypes | null | undefined;
|
|
37
39
|
idObject?: number | null | undefined;
|
|
40
|
+
relativeActionType?: ActionEntityTypes | null | undefined;
|
|
38
41
|
rangeDate?: {
|
|
39
42
|
start?: any;
|
|
40
43
|
end?: any;
|
|
@@ -9,6 +9,7 @@ exports.ActionsByParamDtoZod = zod_1.z.object({
|
|
|
9
9
|
searchString: zod_1.z.string().optional(),
|
|
10
10
|
typeObject: zod_1.z.nativeEnum(enums_1.ActionEntityTypes).nullable().default(null),
|
|
11
11
|
idObject: zod_1.z.number().optional().nullable(),
|
|
12
|
+
relativeActionType: zod_1.z.nativeEnum(enums_1.ActionEntityTypes).nullish().default(null),
|
|
12
13
|
operationId: zod_1.z.number().optional().nullable(),
|
|
13
14
|
rangeDate: zod_1.z
|
|
14
15
|
.object({
|
|
@@ -34,8 +34,7 @@ export declare enum ActionEntityTypes {
|
|
|
34
34
|
contact = "contact",
|
|
35
35
|
company = "company",
|
|
36
36
|
revision = "revision",
|
|
37
|
-
thread_entity = "thread_entity"
|
|
38
|
-
user_table_config = "user_table_config"
|
|
37
|
+
thread_entity = "thread_entity"
|
|
39
38
|
}
|
|
40
39
|
/**
|
|
41
40
|
* enum для обращения к моделям в бд
|
|
@@ -181,8 +180,4 @@ export declare const ActionEntityTypesDB: {
|
|
|
181
180
|
readonly name: "thread_entity";
|
|
182
181
|
readonly attributes: readonly ["id"];
|
|
183
182
|
};
|
|
184
|
-
readonly user_table_config: {
|
|
185
|
-
readonly name: "user_table_configs";
|
|
186
|
-
readonly attributes: readonly ["id"];
|
|
187
|
-
};
|
|
188
183
|
};
|
|
@@ -39,7 +39,6 @@ var ActionEntityTypes;
|
|
|
39
39
|
ActionEntityTypes["company"] = "company";
|
|
40
40
|
ActionEntityTypes["revision"] = "revision";
|
|
41
41
|
ActionEntityTypes["thread_entity"] = "thread_entity";
|
|
42
|
-
ActionEntityTypes["user_table_config"] = "user_table_config";
|
|
43
42
|
})(ActionEntityTypes || (exports.ActionEntityTypes = ActionEntityTypes = {}));
|
|
44
43
|
/**
|
|
45
44
|
* enum для обращения к моделям в бд
|
|
@@ -127,9 +126,5 @@ exports.ActionEntityTypesDB = {
|
|
|
127
126
|
[ActionEntityTypes.thread_entity]: {
|
|
128
127
|
name: 'thread_entity',
|
|
129
128
|
attributes: ['id']
|
|
130
|
-
},
|
|
131
|
-
[ActionEntityTypes.user_table_config]: {
|
|
132
|
-
name: 'user_table_configs',
|
|
133
|
-
attributes: ['id']
|
|
134
129
|
}
|
|
135
130
|
};
|
|
@@ -57,6 +57,7 @@ export declare const ActionsSchema: z.ZodObject<{
|
|
|
57
57
|
role_id: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
58
58
|
parent_action_idL: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
59
59
|
production_task_id: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
60
|
+
createdAt: z.ZodOptional<z.ZodUnion<[z.ZodDate, z.ZodString]>>;
|
|
60
61
|
}, "strip", z.ZodTypeAny, {
|
|
61
62
|
ban: boolean;
|
|
62
63
|
action: IActionText[];
|
|
@@ -71,6 +72,7 @@ export declare const ActionsSchema: z.ZodObject<{
|
|
|
71
72
|
inventary_id?: number | null | undefined;
|
|
72
73
|
responsible_id?: number | null | undefined;
|
|
73
74
|
tech_process_id?: number | null | undefined;
|
|
75
|
+
createdAt?: string | Date | undefined;
|
|
74
76
|
equipment_id?: number | null | undefined;
|
|
75
77
|
movement_object_id?: number | null | undefined;
|
|
76
78
|
deliveries_id?: number | null | undefined;
|
|
@@ -105,6 +107,7 @@ export declare const ActionsSchema: z.ZodObject<{
|
|
|
105
107
|
inventary_id?: number | null | undefined;
|
|
106
108
|
responsible_id?: number | null | undefined;
|
|
107
109
|
tech_process_id?: number | null | undefined;
|
|
110
|
+
createdAt?: string | Date | undefined;
|
|
108
111
|
equipment_id?: number | null | undefined;
|
|
109
112
|
movement_object_id?: number | null | undefined;
|
|
110
113
|
deliveries_id?: number | null | undefined;
|
|
@@ -35,5 +35,6 @@ exports.ActionsSchema = zod_1.z.object({
|
|
|
35
35
|
mark_id: zod_1.z.number().nullish(),
|
|
36
36
|
role_id: zod_1.z.number().nullish(),
|
|
37
37
|
parent_action_idL: zod_1.z.number().nullable().optional(),
|
|
38
|
-
production_task_id: zod_1.z.number().nullish()
|
|
38
|
+
production_task_id: zod_1.z.number().nullish(),
|
|
39
|
+
createdAt: zod_1.z.union([zod_1.z.date(), zod_1.z.string()]).optional()
|
|
39
40
|
});
|
|
@@ -1,4 +1,7 @@
|
|
|
1
1
|
import { ModelActions } from '../schemas/actions.schema';
|
|
2
2
|
export type ActionWithParsedTextType = ModelActions & {
|
|
3
3
|
parsedActionsText: string[];
|
|
4
|
+
nameEntity: string | undefined | null;
|
|
5
|
+
relatedEntityName: string | undefined | null;
|
|
6
|
+
entityId: number | undefined | null;
|
|
4
7
|
};
|
|
@@ -356,6 +356,7 @@ export declare const EquipmentSchema: z.ZodObject<{
|
|
|
356
356
|
role_id: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
357
357
|
parent_action_idL: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
358
358
|
production_task_id: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
359
|
+
createdAt: z.ZodOptional<z.ZodUnion<[z.ZodDate, z.ZodString]>>;
|
|
359
360
|
}, "strip", z.ZodTypeAny, {
|
|
360
361
|
ban: boolean;
|
|
361
362
|
action: import("../../action").IActionText[];
|
|
@@ -370,6 +371,7 @@ export declare const EquipmentSchema: z.ZodObject<{
|
|
|
370
371
|
inventary_id?: number | null | undefined;
|
|
371
372
|
responsible_id?: number | null | undefined;
|
|
372
373
|
tech_process_id?: number | null | undefined;
|
|
374
|
+
createdAt?: string | Date | undefined;
|
|
373
375
|
equipment_id?: number | null | undefined;
|
|
374
376
|
movement_object_id?: number | null | undefined;
|
|
375
377
|
deliveries_id?: number | null | undefined;
|
|
@@ -404,6 +406,7 @@ export declare const EquipmentSchema: z.ZodObject<{
|
|
|
404
406
|
inventary_id?: number | null | undefined;
|
|
405
407
|
responsible_id?: number | null | undefined;
|
|
406
408
|
tech_process_id?: number | null | undefined;
|
|
409
|
+
createdAt?: string | Date | undefined;
|
|
407
410
|
equipment_id?: number | null | undefined;
|
|
408
411
|
movement_object_id?: number | null | undefined;
|
|
409
412
|
deliveries_id?: number | null | undefined;
|
|
@@ -545,6 +548,7 @@ export declare const EquipmentSchema: z.ZodObject<{
|
|
|
545
548
|
inventary_id?: number | null | undefined;
|
|
546
549
|
responsible_id?: number | null | undefined;
|
|
547
550
|
tech_process_id?: number | null | undefined;
|
|
551
|
+
createdAt?: string | Date | undefined;
|
|
548
552
|
equipment_id?: number | null | undefined;
|
|
549
553
|
movement_object_id?: number | null | undefined;
|
|
550
554
|
deliveries_id?: number | null | undefined;
|
|
@@ -686,6 +690,7 @@ export declare const EquipmentSchema: z.ZodObject<{
|
|
|
686
690
|
inventary_id?: number | null | undefined;
|
|
687
691
|
responsible_id?: number | null | undefined;
|
|
688
692
|
tech_process_id?: number | null | undefined;
|
|
693
|
+
createdAt?: string | Date | undefined;
|
|
689
694
|
equipment_id?: number | null | undefined;
|
|
690
695
|
movement_object_id?: number | null | undefined;
|
|
691
696
|
deliveries_id?: number | null | undefined;
|
|
@@ -293,6 +293,7 @@ export declare const MovingSchema: z.ZodObject<{
|
|
|
293
293
|
role_id: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
294
294
|
parent_action_idL: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
295
295
|
production_task_id: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
296
|
+
createdAt: z.ZodOptional<z.ZodUnion<[z.ZodDate, z.ZodString]>>;
|
|
296
297
|
}, "strip", z.ZodTypeAny, {
|
|
297
298
|
ban: boolean;
|
|
298
299
|
action: import("../..").IActionText[];
|
|
@@ -307,6 +308,7 @@ export declare const MovingSchema: z.ZodObject<{
|
|
|
307
308
|
inventary_id?: number | null | undefined;
|
|
308
309
|
responsible_id?: number | null | undefined;
|
|
309
310
|
tech_process_id?: number | null | undefined;
|
|
311
|
+
createdAt?: string | Date | undefined;
|
|
310
312
|
equipment_id?: number | null | undefined;
|
|
311
313
|
movement_object_id?: number | null | undefined;
|
|
312
314
|
deliveries_id?: number | null | undefined;
|
|
@@ -341,6 +343,7 @@ export declare const MovingSchema: z.ZodObject<{
|
|
|
341
343
|
inventary_id?: number | null | undefined;
|
|
342
344
|
responsible_id?: number | null | undefined;
|
|
343
345
|
tech_process_id?: number | null | undefined;
|
|
346
|
+
createdAt?: string | Date | undefined;
|
|
344
347
|
equipment_id?: number | null | undefined;
|
|
345
348
|
movement_object_id?: number | null | undefined;
|
|
346
349
|
deliveries_id?: number | null | undefined;
|
|
@@ -549,6 +552,7 @@ export declare const MovingSchema: z.ZodObject<{
|
|
|
549
552
|
inventary_id?: number | null | undefined;
|
|
550
553
|
responsible_id?: number | null | undefined;
|
|
551
554
|
tech_process_id?: number | null | undefined;
|
|
555
|
+
createdAt?: string | Date | undefined;
|
|
552
556
|
equipment_id?: number | null | undefined;
|
|
553
557
|
movement_object_id?: number | null | undefined;
|
|
554
558
|
deliveries_id?: number | null | undefined;
|
|
@@ -738,6 +742,7 @@ export declare const MovingSchema: z.ZodObject<{
|
|
|
738
742
|
inventary_id?: number | null | undefined;
|
|
739
743
|
responsible_id?: number | null | undefined;
|
|
740
744
|
tech_process_id?: number | null | undefined;
|
|
745
|
+
createdAt?: string | Date | undefined;
|
|
741
746
|
equipment_id?: number | null | undefined;
|
|
742
747
|
movement_object_id?: number | null | undefined;
|
|
743
748
|
deliveries_id?: number | null | undefined;
|
|
@@ -988,6 +993,7 @@ export declare const MovingSchema: z.ZodObject<{
|
|
|
988
993
|
inventary_id?: number | null | undefined;
|
|
989
994
|
responsible_id?: number | null | undefined;
|
|
990
995
|
tech_process_id?: number | null | undefined;
|
|
996
|
+
createdAt?: string | Date | undefined;
|
|
991
997
|
equipment_id?: number | null | undefined;
|
|
992
998
|
movement_object_id?: number | null | undefined;
|
|
993
999
|
deliveries_id?: number | null | undefined;
|
|
@@ -1200,6 +1206,7 @@ export declare const MovingSchema: z.ZodObject<{
|
|
|
1200
1206
|
inventary_id?: number | null | undefined;
|
|
1201
1207
|
responsible_id?: number | null | undefined;
|
|
1202
1208
|
tech_process_id?: number | null | undefined;
|
|
1209
|
+
createdAt?: string | Date | undefined;
|
|
1203
1210
|
equipment_id?: number | null | undefined;
|
|
1204
1211
|
movement_object_id?: number | null | undefined;
|
|
1205
1212
|
deliveries_id?: number | null | undefined;
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
2
|
export declare const GetProductionTaskByEquipmentDtoZod: z.ZodObject<{
|
|
3
3
|
equipmentId: z.ZodNumber;
|
|
4
|
+
searchString: z.ZodOptional<z.ZodString>;
|
|
4
5
|
taskId: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
5
6
|
range: z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
6
7
|
start: z.ZodAny;
|
|
@@ -15,6 +16,7 @@ export declare const GetProductionTaskByEquipmentDtoZod: z.ZodObject<{
|
|
|
15
16
|
onlyTOperation: z.ZodOptional<z.ZodNumber>;
|
|
16
17
|
}, "strip", z.ZodTypeAny, {
|
|
17
18
|
equipmentId: number;
|
|
19
|
+
searchString?: string | undefined;
|
|
18
20
|
range?: {
|
|
19
21
|
start?: any;
|
|
20
22
|
end?: any;
|
|
@@ -23,6 +25,7 @@ export declare const GetProductionTaskByEquipmentDtoZod: z.ZodObject<{
|
|
|
23
25
|
onlyTOperation?: number | undefined;
|
|
24
26
|
}, {
|
|
25
27
|
equipmentId: number;
|
|
28
|
+
searchString?: string | undefined;
|
|
26
29
|
range?: {
|
|
27
30
|
start?: any;
|
|
28
31
|
end?: any;
|
|
@@ -4,6 +4,7 @@ exports.GetProductionTaskByEquipmentDtoZod = void 0;
|
|
|
4
4
|
const zod_1 = require("zod");
|
|
5
5
|
exports.GetProductionTaskByEquipmentDtoZod = zod_1.z.object({
|
|
6
6
|
equipmentId: zod_1.z.number().int(),
|
|
7
|
+
searchString: zod_1.z.string().optional(),
|
|
7
8
|
taskId: zod_1.z.number().int().nullish(),
|
|
8
9
|
range: zod_1.z
|
|
9
10
|
.object({
|
|
@@ -2,6 +2,7 @@ import { z } from 'zod';
|
|
|
2
2
|
import { StockOrderType } from '../../utils';
|
|
3
3
|
export declare const GetProductionTaskByOperationDtoZod: z.ZodObject<{
|
|
4
4
|
operationTypeId: z.ZodNumber;
|
|
5
|
+
searchString: z.ZodOptional<z.ZodString>;
|
|
5
6
|
taskId: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodNumber>>>;
|
|
6
7
|
onlyTOperation: z.ZodOptional<z.ZodNumber>;
|
|
7
8
|
range: z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
@@ -19,6 +20,7 @@ export declare const GetProductionTaskByOperationDtoZod: z.ZodObject<{
|
|
|
19
20
|
}, "strip", z.ZodTypeAny, {
|
|
20
21
|
equipmentIds: number[] | null;
|
|
21
22
|
operationTypeId: number;
|
|
23
|
+
searchString?: string | undefined;
|
|
22
24
|
range?: {
|
|
23
25
|
start?: any;
|
|
24
26
|
end?: any;
|
|
@@ -29,6 +31,7 @@ export declare const GetProductionTaskByOperationDtoZod: z.ZodObject<{
|
|
|
29
31
|
}, {
|
|
30
32
|
operationTypeId: number;
|
|
31
33
|
equipmentIds?: number[] | null | undefined;
|
|
34
|
+
searchString?: string | undefined;
|
|
32
35
|
range?: {
|
|
33
36
|
start?: any;
|
|
34
37
|
end?: any;
|
|
@@ -5,6 +5,7 @@ const zod_1 = require("zod");
|
|
|
5
5
|
const utils_1 = require("../../utils");
|
|
6
6
|
exports.GetProductionTaskByOperationDtoZod = zod_1.z.object({
|
|
7
7
|
operationTypeId: zod_1.z.number().int(),
|
|
8
|
+
searchString: zod_1.z.string().optional(),
|
|
8
9
|
taskId: zod_1.z.number().int().nullable().default(null).optional(),
|
|
9
10
|
onlyTOperation: zod_1.z.number().int().optional(),
|
|
10
11
|
range: zod_1.z
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
2
|
export declare const GetProductionTaskByUserDtoZod: z.ZodObject<{
|
|
3
3
|
userId: z.ZodNumber;
|
|
4
|
+
searchString: z.ZodOptional<z.ZodString>;
|
|
4
5
|
taskId: z.ZodOptional<z.ZodDefault<z.ZodNullable<z.ZodNumber>>>;
|
|
5
6
|
onlyTOperation: z.ZodOptional<z.ZodNumber>;
|
|
6
7
|
range: z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
@@ -15,6 +16,7 @@ export declare const GetProductionTaskByUserDtoZod: z.ZodObject<{
|
|
|
15
16
|
}>>>;
|
|
16
17
|
}, "strip", z.ZodTypeAny, {
|
|
17
18
|
userId: number;
|
|
19
|
+
searchString?: string | undefined;
|
|
18
20
|
range?: {
|
|
19
21
|
start?: any;
|
|
20
22
|
end?: any;
|
|
@@ -23,6 +25,7 @@ export declare const GetProductionTaskByUserDtoZod: z.ZodObject<{
|
|
|
23
25
|
onlyTOperation?: number | undefined;
|
|
24
26
|
}, {
|
|
25
27
|
userId: number;
|
|
28
|
+
searchString?: string | undefined;
|
|
26
29
|
range?: {
|
|
27
30
|
start?: any;
|
|
28
31
|
end?: any;
|
|
@@ -4,6 +4,7 @@ exports.GetProductionTaskByUserDtoZod = void 0;
|
|
|
4
4
|
const zod_1 = require("zod");
|
|
5
5
|
exports.GetProductionTaskByUserDtoZod = zod_1.z.object({
|
|
6
6
|
userId: zod_1.z.number().int(),
|
|
7
|
+
searchString: zod_1.z.string().optional(),
|
|
7
8
|
taskId: zod_1.z.number().int().nullable().default(null).optional(),
|
|
8
9
|
onlyTOperation: zod_1.z.number().int().optional(),
|
|
9
10
|
range: zod_1.z
|
|
@@ -12,17 +12,26 @@ export declare const WorkloadByEntityDtoZod: z.ZodObject<{
|
|
|
12
12
|
start: string;
|
|
13
13
|
end: string;
|
|
14
14
|
}>;
|
|
15
|
+
userId: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
16
|
+
equipmentId: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
17
|
+
typeOperationId: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
15
18
|
}, "strip", z.ZodTypeAny, {
|
|
16
19
|
range: {
|
|
17
20
|
start: string;
|
|
18
21
|
end: string;
|
|
19
22
|
};
|
|
20
23
|
entityType: StockOrderType;
|
|
24
|
+
userId?: number | null | undefined;
|
|
25
|
+
equipmentId?: number | null | undefined;
|
|
26
|
+
typeOperationId?: number | null | undefined;
|
|
21
27
|
}, {
|
|
22
28
|
range: {
|
|
23
29
|
start: string;
|
|
24
30
|
end: string;
|
|
25
31
|
};
|
|
26
32
|
entityType: StockOrderType;
|
|
33
|
+
userId?: number | null | undefined;
|
|
34
|
+
equipmentId?: number | null | undefined;
|
|
35
|
+
typeOperationId?: number | null | undefined;
|
|
27
36
|
}>;
|
|
28
37
|
export type WorkloadByEntityDtoZodType = z.infer<typeof WorkloadByEntityDtoZod>;
|
|
@@ -8,5 +8,8 @@ exports.WorkloadByEntityDtoZod = zod_1.z.object({
|
|
|
8
8
|
range: zod_1.z.object({
|
|
9
9
|
start: zod_1.z.string(),
|
|
10
10
|
end: zod_1.z.string()
|
|
11
|
-
})
|
|
11
|
+
}),
|
|
12
|
+
userId: zod_1.z.number().nullish(),
|
|
13
|
+
equipmentId: zod_1.z.number().nullish(),
|
|
14
|
+
typeOperationId: zod_1.z.number().nullish()
|
|
12
15
|
});
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { ModelTechProcess } from '../../tech-process';
|
|
2
2
|
import { ModelUser } from '../../user';
|
|
3
|
-
import { EntityCommonSpecificationArray, IzdType, ProductionTimeType, StockOrderType } from '../../utils';
|
|
3
|
+
import { EntityCommonSpecificationArray, IzdType, Neo4jEntityTypes, ProductionTimeType, StockOrderType } from '../../utils';
|
|
4
4
|
import { ModelProductionTaskAssembly } from '../schemas/production-taks-assembly.schema';
|
|
5
5
|
import { ModelProductionTaskMetalloworking } from '../schemas/production-taks-metalloworkig.schema';
|
|
6
6
|
import { ModelProductionTask } from '../schemas/production-task.schema';
|
|
@@ -189,6 +189,15 @@ export interface IGetDeficitsDetalByProductionTask {
|
|
|
189
189
|
deficitByDetal: number;
|
|
190
190
|
relativesIds: IRelativeIds;
|
|
191
191
|
}
|
|
192
|
+
export interface IGetActualTaskRelative {
|
|
193
|
+
entityId: number;
|
|
194
|
+
entityType: Neo4jEntityTypes;
|
|
195
|
+
range?: {
|
|
196
|
+
start: any;
|
|
197
|
+
end: any;
|
|
198
|
+
};
|
|
199
|
+
transaction?: any;
|
|
200
|
+
}
|
|
192
201
|
export interface IActualOperationPos {
|
|
193
202
|
userId: number;
|
|
194
203
|
indexStartFrom?: number | null;
|
|
@@ -333,13 +342,9 @@ export interface IUnicalUsers extends IUnicalEntity {
|
|
|
333
342
|
tabel?: string;
|
|
334
343
|
}
|
|
335
344
|
export interface IWorkloadByEntityResponse {
|
|
336
|
-
operationName: string;
|
|
337
|
-
typeOperationId: number | string;
|
|
338
|
-
workloadData: IWorkloadData[];
|
|
339
|
-
}
|
|
340
|
-
export interface IWorkloadData {
|
|
341
345
|
responsibleInfo: any;
|
|
342
346
|
positionsByDate: IWorkloadPositionByDate[];
|
|
347
|
+
debt?: boolean;
|
|
343
348
|
}
|
|
344
349
|
export interface IWorkloadPositionSchema {
|
|
345
350
|
normHours: number;
|
|
@@ -289,6 +289,7 @@ export declare const RoleSchema: z.ZodObject<{
|
|
|
289
289
|
role_id: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
290
290
|
parent_action_idL: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
291
291
|
production_task_id: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
292
|
+
createdAt: z.ZodOptional<z.ZodUnion<[z.ZodDate, z.ZodString]>>;
|
|
292
293
|
}, "strip", z.ZodTypeAny, {
|
|
293
294
|
ban: boolean;
|
|
294
295
|
action: import("../..").IActionText[];
|
|
@@ -303,6 +304,7 @@ export declare const RoleSchema: z.ZodObject<{
|
|
|
303
304
|
inventary_id?: number | null | undefined;
|
|
304
305
|
responsible_id?: number | null | undefined;
|
|
305
306
|
tech_process_id?: number | null | undefined;
|
|
307
|
+
createdAt?: string | Date | undefined;
|
|
306
308
|
equipment_id?: number | null | undefined;
|
|
307
309
|
movement_object_id?: number | null | undefined;
|
|
308
310
|
deliveries_id?: number | null | undefined;
|
|
@@ -337,6 +339,7 @@ export declare const RoleSchema: z.ZodObject<{
|
|
|
337
339
|
inventary_id?: number | null | undefined;
|
|
338
340
|
responsible_id?: number | null | undefined;
|
|
339
341
|
tech_process_id?: number | null | undefined;
|
|
342
|
+
createdAt?: string | Date | undefined;
|
|
340
343
|
equipment_id?: number | null | undefined;
|
|
341
344
|
movement_object_id?: number | null | undefined;
|
|
342
345
|
deliveries_id?: number | null | undefined;
|
|
@@ -545,6 +548,7 @@ export declare const RoleSchema: z.ZodObject<{
|
|
|
545
548
|
inventary_id?: number | null | undefined;
|
|
546
549
|
responsible_id?: number | null | undefined;
|
|
547
550
|
tech_process_id?: number | null | undefined;
|
|
551
|
+
createdAt?: string | Date | undefined;
|
|
548
552
|
equipment_id?: number | null | undefined;
|
|
549
553
|
movement_object_id?: number | null | undefined;
|
|
550
554
|
deliveries_id?: number | null | undefined;
|
|
@@ -734,6 +738,7 @@ export declare const RoleSchema: z.ZodObject<{
|
|
|
734
738
|
inventary_id?: number | null | undefined;
|
|
735
739
|
responsible_id?: number | null | undefined;
|
|
736
740
|
tech_process_id?: number | null | undefined;
|
|
741
|
+
createdAt?: string | Date | undefined;
|
|
737
742
|
equipment_id?: number | null | undefined;
|
|
738
743
|
movement_object_id?: number | null | undefined;
|
|
739
744
|
deliveries_id?: number | null | undefined;
|
|
@@ -931,6 +936,7 @@ export declare const RoleSchema: z.ZodObject<{
|
|
|
931
936
|
inventary_id?: number | null | undefined;
|
|
932
937
|
responsible_id?: number | null | undefined;
|
|
933
938
|
tech_process_id?: number | null | undefined;
|
|
939
|
+
createdAt?: string | Date | undefined;
|
|
934
940
|
equipment_id?: number | null | undefined;
|
|
935
941
|
movement_object_id?: number | null | undefined;
|
|
936
942
|
deliveries_id?: number | null | undefined;
|
|
@@ -1125,6 +1131,7 @@ export declare const RoleSchema: z.ZodObject<{
|
|
|
1125
1131
|
inventary_id?: number | null | undefined;
|
|
1126
1132
|
responsible_id?: number | null | undefined;
|
|
1127
1133
|
tech_process_id?: number | null | undefined;
|
|
1134
|
+
createdAt?: string | Date | undefined;
|
|
1128
1135
|
equipment_id?: number | null | undefined;
|
|
1129
1136
|
movement_object_id?: number | null | undefined;
|
|
1130
1137
|
deliveries_id?: number | null | undefined;
|
package/dist/user/index.d.ts
CHANGED
package/dist/user/index.js
CHANGED
|
@@ -24,5 +24,3 @@ __exportStar(require("./dto/tabel-unique.dto"), exports);
|
|
|
24
24
|
__exportStar(require("./default-value/model"), exports);
|
|
25
25
|
__exportStar(require("./dto/auth-user.dto"), exports);
|
|
26
26
|
__exportStar(require("./enums"), exports);
|
|
27
|
-
__exportStar(require("./schemas/user-table-config.schema"), exports);
|
|
28
|
-
__exportStar(require("./dto/update-user-table-config.dto"), exports);
|
|
@@ -287,6 +287,7 @@ export declare const UserSchema: z.ZodObject<{
|
|
|
287
287
|
role_id: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
288
288
|
parent_action_idL: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
289
289
|
production_task_id: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
290
|
+
createdAt: z.ZodOptional<z.ZodUnion<[z.ZodDate, z.ZodString]>>;
|
|
290
291
|
}, "strip", z.ZodTypeAny, {
|
|
291
292
|
ban: boolean;
|
|
292
293
|
action: import("../..").IActionText[];
|
|
@@ -301,6 +302,7 @@ export declare const UserSchema: z.ZodObject<{
|
|
|
301
302
|
inventary_id?: number | null | undefined;
|
|
302
303
|
responsible_id?: number | null | undefined;
|
|
303
304
|
tech_process_id?: number | null | undefined;
|
|
305
|
+
createdAt?: string | Date | undefined;
|
|
304
306
|
equipment_id?: number | null | undefined;
|
|
305
307
|
movement_object_id?: number | null | undefined;
|
|
306
308
|
deliveries_id?: number | null | undefined;
|
|
@@ -335,6 +337,7 @@ export declare const UserSchema: z.ZodObject<{
|
|
|
335
337
|
inventary_id?: number | null | undefined;
|
|
336
338
|
responsible_id?: number | null | undefined;
|
|
337
339
|
tech_process_id?: number | null | undefined;
|
|
340
|
+
createdAt?: string | Date | undefined;
|
|
338
341
|
equipment_id?: number | null | undefined;
|
|
339
342
|
movement_object_id?: number | null | undefined;
|
|
340
343
|
deliveries_id?: number | null | undefined;
|
|
@@ -543,6 +546,7 @@ export declare const UserSchema: z.ZodObject<{
|
|
|
543
546
|
inventary_id?: number | null | undefined;
|
|
544
547
|
responsible_id?: number | null | undefined;
|
|
545
548
|
tech_process_id?: number | null | undefined;
|
|
549
|
+
createdAt?: string | Date | undefined;
|
|
546
550
|
equipment_id?: number | null | undefined;
|
|
547
551
|
movement_object_id?: number | null | undefined;
|
|
548
552
|
deliveries_id?: number | null | undefined;
|
|
@@ -732,6 +736,7 @@ export declare const UserSchema: z.ZodObject<{
|
|
|
732
736
|
inventary_id?: number | null | undefined;
|
|
733
737
|
responsible_id?: number | null | undefined;
|
|
734
738
|
tech_process_id?: number | null | undefined;
|
|
739
|
+
createdAt?: string | Date | undefined;
|
|
735
740
|
equipment_id?: number | null | undefined;
|
|
736
741
|
movement_object_id?: number | null | undefined;
|
|
737
742
|
deliveries_id?: number | null | undefined;
|
|
@@ -21,6 +21,14 @@ export declare class DateMethods {
|
|
|
21
21
|
* @returns
|
|
22
22
|
*/
|
|
23
23
|
comparison: (one_date?: string, two_date?: string, operation?: string) => boolean;
|
|
24
|
+
/**
|
|
25
|
+
* Выссчитываем дельту двух дат.
|
|
26
|
+
* Результат возвращается в минутах
|
|
27
|
+
* @param calculatedCreateTime
|
|
28
|
+
* @param planReadyTime
|
|
29
|
+
* @returns
|
|
30
|
+
*/
|
|
31
|
+
calculateDeltaTime: (calculatedCreateTime: Date, planReadyTime: Date) => number;
|
|
24
32
|
/**
|
|
25
33
|
* Функция возвращает текущее время в UTC формате
|
|
26
34
|
* @param config
|
|
@@ -47,6 +47,19 @@ class DateMethods {
|
|
|
47
47
|
}
|
|
48
48
|
return result;
|
|
49
49
|
};
|
|
50
|
+
/**
|
|
51
|
+
* Выссчитываем дельту двух дат.
|
|
52
|
+
* Результат возвращается в минутах
|
|
53
|
+
* @param calculatedCreateTime
|
|
54
|
+
* @param planReadyTime
|
|
55
|
+
* @returns
|
|
56
|
+
*/
|
|
57
|
+
this.calculateDeltaTime = (calculatedCreateTime, planReadyTime) => {
|
|
58
|
+
const calculateDate = new Date(calculatedCreateTime);
|
|
59
|
+
const planReadyDate = new Date(planReadyTime);
|
|
60
|
+
const diffInMs = planReadyDate.getTime() - calculateDate.getTime();
|
|
61
|
+
return Math.round(diffInMs / (1000 * 60));
|
|
62
|
+
};
|
|
50
63
|
/**
|
|
51
64
|
* Функция возвращает текущее время в UTC формате
|
|
52
65
|
* @param config
|
package/dist/utils/index.d.ts
CHANGED
|
@@ -24,6 +24,3 @@ export * from './interfaces';
|
|
|
24
24
|
export * from './methods/utils';
|
|
25
25
|
export * from './promise-pool';
|
|
26
26
|
export * from './default-value/default-value';
|
|
27
|
-
export * from './tables-config/enum';
|
|
28
|
-
export * from './tables-config/methods';
|
|
29
|
-
export * from './tables-config/tables-array';
|
package/dist/utils/index.js
CHANGED
|
@@ -40,6 +40,3 @@ __exportStar(require("./interfaces"), exports);
|
|
|
40
40
|
__exportStar(require("./methods/utils"), exports);
|
|
41
41
|
__exportStar(require("./promise-pool"), exports);
|
|
42
42
|
__exportStar(require("./default-value/default-value"), exports);
|
|
43
|
-
__exportStar(require("./tables-config/enum"), exports);
|
|
44
|
-
__exportStar(require("./tables-config/methods"), exports);
|
|
45
|
-
__exportStar(require("./tables-config/tables-array"), exports);
|
|
@@ -14,6 +14,7 @@ export declare enum tablesEnumConfig {
|
|
|
14
14
|
remainingByProductionTask = "remainingByProductionTask",
|
|
15
15
|
dateByUrgency = "dateByUrgency",
|
|
16
16
|
dateShipment = "dateShipment",
|
|
17
|
+
workpieceParameters = "workpieceParameters",
|
|
17
18
|
material = "material",
|
|
18
19
|
operationsLength = "operationsLength",
|
|
19
20
|
timeToProduction = "timeToProduction",
|
|
@@ -31,6 +31,9 @@ var tablesEnumConfig;
|
|
|
31
31
|
tablesEnumConfig["dateByUrgency"] = "dateByUrgency";
|
|
32
32
|
// планируемая дата отгрузки
|
|
33
33
|
tablesEnumConfig["dateShipment"] = "dateShipment";
|
|
34
|
+
// параметр заготовки
|
|
35
|
+
tablesEnumConfig["workpieceParameters"] = "workpieceParameters";
|
|
36
|
+
// материал
|
|
34
37
|
tablesEnumConfig["material"] = "material";
|
|
35
38
|
tablesEnumConfig["operationsLength"] = "operationsLength";
|
|
36
39
|
tablesEnumConfig["timeToProduction"] = "timeToProduction";
|
|
@@ -14,6 +14,7 @@ exports.metalloworkingTableConfig = [
|
|
|
14
14
|
enum_1.tablesEnumConfig.ordered,
|
|
15
15
|
enum_1.tablesEnumConfig.dateByUrgency,
|
|
16
16
|
enum_1.tablesEnumConfig.dateShipment,
|
|
17
|
+
enum_1.tablesEnumConfig.workpieceParameters,
|
|
17
18
|
enum_1.tablesEnumConfig.material,
|
|
18
19
|
enum_1.tablesEnumConfig.operationsLength,
|
|
19
20
|
enum_1.tablesEnumConfig.readyInProcent,
|
|
@@ -26,6 +26,8 @@ export type RelativesProductionTasksType = {
|
|
|
26
26
|
dueData: Date;
|
|
27
27
|
relativeName: string;
|
|
28
28
|
relativeDesignation: string;
|
|
29
|
+
equipmentId: number | null;
|
|
30
|
+
userId: number | null;
|
|
29
31
|
relativeAttention: boolean;
|
|
30
32
|
relativeDiscontinued: boolean;
|
|
31
33
|
relativeDescription: string;
|