rez_core 5.0.303 → 5.0.304
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/module/workflow-automation/service/schedule-handler.service.d.ts +3 -3
- package/dist/module/workflow-automation/service/schedule-handler.service.js +7 -6
- package/dist/module/workflow-automation/service/schedule-handler.service.js.map +1 -1
- package/dist/tsconfig.build.tsbuildinfo +1 -1
- package/package.json +1 -1
- package/src/module/workflow-automation/service/schedule-handler.service.ts +6 -4
|
@@ -3,16 +3,16 @@ import { DataSource, Repository } from 'typeorm';
|
|
|
3
3
|
import { WorkflowAutomationEngineService } from './workflow-automation-engine.service';
|
|
4
4
|
import { WorkflowAutomation } from '../entity/workflow-automation.entity';
|
|
5
5
|
import { EntityMaster } from 'src/module/meta/entity/entity-master.entity';
|
|
6
|
-
import {
|
|
6
|
+
import { ReflectionHelper } from 'src/utils/service/reflection-helper.service';
|
|
7
7
|
export declare class ScheduleHandlerService {
|
|
8
8
|
private readonly dataSource;
|
|
9
9
|
private readonly filterEvaluator;
|
|
10
10
|
private readonly workflowAutomationEngineService;
|
|
11
11
|
private readonly workflowAutomation;
|
|
12
12
|
private readonly entityMasterRepository;
|
|
13
|
-
|
|
13
|
+
readonly reflectionHelper: ReflectionHelper;
|
|
14
14
|
private readonly logger;
|
|
15
|
-
constructor(dataSource: DataSource, filterEvaluator: FilterEvaluatorService, workflowAutomationEngineService: WorkflowAutomationEngineService, workflowAutomation: Repository<WorkflowAutomation>, entityMasterRepository: Repository<EntityMaster>,
|
|
15
|
+
constructor(dataSource: DataSource, filterEvaluator: FilterEvaluatorService, workflowAutomationEngineService: WorkflowAutomationEngineService, workflowAutomation: Repository<WorkflowAutomation>, entityMasterRepository: Repository<EntityMaster>, reflectionHelper: ReflectionHelper);
|
|
16
16
|
scheduleQueryBuilder(workflow_id: number, jobData: any): Promise<{
|
|
17
17
|
results: any[];
|
|
18
18
|
workflow: WorkflowAutomation;
|
|
@@ -21,15 +21,15 @@ const workflow_automation_engine_service_1 = require("./workflow-automation-engi
|
|
|
21
21
|
const workflow_automation_entity_1 = require("../entity/workflow-automation.entity");
|
|
22
22
|
const typeorm_2 = require("@nestjs/typeorm");
|
|
23
23
|
const entity_master_entity_1 = require("../../meta/entity/entity-master.entity");
|
|
24
|
-
const
|
|
24
|
+
const reflection_helper_service_1 = require("../../../utils/service/reflection-helper.service");
|
|
25
25
|
let ScheduleHandlerService = ScheduleHandlerService_1 = class ScheduleHandlerService {
|
|
26
|
-
constructor(dataSource, filterEvaluator, workflowAutomationEngineService, workflowAutomation, entityMasterRepository,
|
|
26
|
+
constructor(dataSource, filterEvaluator, workflowAutomationEngineService, workflowAutomation, entityMasterRepository, reflectionHelper) {
|
|
27
27
|
this.dataSource = dataSource;
|
|
28
28
|
this.filterEvaluator = filterEvaluator;
|
|
29
29
|
this.workflowAutomationEngineService = workflowAutomationEngineService;
|
|
30
30
|
this.workflowAutomation = workflowAutomation;
|
|
31
31
|
this.entityMasterRepository = entityMasterRepository;
|
|
32
|
-
this.
|
|
32
|
+
this.reflectionHelper = reflectionHelper;
|
|
33
33
|
this.logger = new common_1.Logger(ScheduleHandlerService_1.name);
|
|
34
34
|
}
|
|
35
35
|
async scheduleQueryBuilder(workflow_id, jobData) {
|
|
@@ -55,7 +55,8 @@ let ScheduleHandlerService = ScheduleHandlerService_1 = class ScheduleHandlerSer
|
|
|
55
55
|
if (!entity?.data_source)
|
|
56
56
|
throw new Error(`Entity ${entityType} not found`);
|
|
57
57
|
const tableName = entity.data_source;
|
|
58
|
-
const
|
|
58
|
+
const listMasterItemsRepo = this.reflectionHelper.getRepoService('ListMasterItems');
|
|
59
|
+
const executionDateItem = await listMasterItemsRepo.findOne({
|
|
59
60
|
where: {
|
|
60
61
|
id: scheduleJson.executionDate,
|
|
61
62
|
},
|
|
@@ -154,12 +155,12 @@ exports.ScheduleHandlerService = ScheduleHandlerService = ScheduleHandlerService
|
|
|
154
155
|
(0, common_1.Injectable)(),
|
|
155
156
|
__param(3, (0, typeorm_2.InjectRepository)(workflow_automation_entity_1.WorkflowAutomation)),
|
|
156
157
|
__param(4, (0, typeorm_2.InjectRepository)(entity_master_entity_1.EntityMaster)),
|
|
157
|
-
__param(5, (0,
|
|
158
|
+
__param(5, (0, common_1.Inject)()),
|
|
158
159
|
__metadata("design:paramtypes", [typeorm_1.DataSource,
|
|
159
160
|
filter_evaluator_service_1.FilterEvaluatorService,
|
|
160
161
|
workflow_automation_engine_service_1.WorkflowAutomationEngineService,
|
|
161
162
|
typeorm_1.Repository,
|
|
162
163
|
typeorm_1.Repository,
|
|
163
|
-
|
|
164
|
+
reflection_helper_service_1.ReflectionHelper])
|
|
164
165
|
], ScheduleHandlerService);
|
|
165
166
|
//# sourceMappingURL=schedule-handler.service.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"schedule-handler.service.js","sourceRoot":"","sources":["../../../../src/module/workflow-automation/service/schedule-handler.service.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,2CAA4D;AAC5D,4FAA4F;AAC5F,qCAAiD;AACjD,6FAAuF;AACvF,qFAA0E;AAC1E,6CAAmD;AACnD,iFAA2E;AAC3E,
|
|
1
|
+
{"version":3,"file":"schedule-handler.service.js","sourceRoot":"","sources":["../../../../src/module/workflow-automation/service/schedule-handler.service.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,2CAA4D;AAC5D,4FAA4F;AAC5F,qCAAiD;AACjD,6FAAuF;AACvF,qFAA0E;AAC1E,6CAAmD;AACnD,iFAA2E;AAC3E,gGAA+E;AAGxE,IAAM,sBAAsB,8BAA5B,MAAM,sBAAsB;IAGjC,YACmB,UAAsB,EACtB,eAAuC,EACvC,+BAAgE,EAEjF,kBAAmE,EAEnE,sBAAiE,EACvD,gBAA2C;QAPpC,eAAU,GAAV,UAAU,CAAY;QACtB,oBAAe,GAAf,eAAe,CAAwB;QACvC,oCAA+B,GAA/B,+BAA+B,CAAiC;QAEhE,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