rez_core 3.1.24 → 3.1.26
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/.vscode/extensions.json +5 -0
- package/dist/module/workflow/repository/stage-group.repository.js +2 -2
- package/dist/module/workflow/service/workflow-meta.service.d.ts +4 -4
- package/dist/module/workflow/service/workflow-meta.service.js +5 -4
- package/dist/module/workflow/service/workflow-meta.service.js.map +1 -1
- package/dist/tsconfig.build.tsbuildinfo +1 -1
- package/package.json +1 -1
- package/src/module/workflow/repository/stage-group.repository.ts +2 -2
- package/src/module/workflow/service/workflow-meta.service.ts +7 -7
package/package.json
CHANGED
|
@@ -111,7 +111,7 @@ export class StageGroupRepository {
|
|
|
111
111
|
`
|
|
112
112
|
SELECT stage_id, COUNT(*) AS meeting_count
|
|
113
113
|
FROM crm_lead_meeting
|
|
114
|
-
WHERE stage_id IN (${stageIds.map(() => '?').join(',')}) AND
|
|
114
|
+
WHERE stage_id IN (${stageIds.map(() => '?').join(',')}) AND mapped_entity_id = ?
|
|
115
115
|
GROUP BY stage_id
|
|
116
116
|
`,
|
|
117
117
|
[...stageIds, lead_id],
|
|
@@ -122,7 +122,7 @@ export class StageGroupRepository {
|
|
|
122
122
|
`
|
|
123
123
|
SELECT stage_id, COUNT(*) AS send_comm_count
|
|
124
124
|
FROM crm_lead_communication
|
|
125
|
-
WHERE stage_id IN (${stageIds.map(() => '?').join(',')}) AND
|
|
125
|
+
WHERE stage_id IN (${stageIds.map(() => '?').join(',')}) AND mapped_entity_id = ?
|
|
126
126
|
AND type IN ('SEND', 'LOG')
|
|
127
127
|
GROUP BY stage_id
|
|
128
128
|
`,
|
|
@@ -1,16 +1,15 @@
|
|
|
1
|
-
import { log } from 'console';
|
|
2
1
|
import { Inject, Injectable } from '@nestjs/common';
|
|
3
2
|
import { InjectRepository } from '@nestjs/typeorm';
|
|
4
|
-
import {
|
|
5
|
-
import { StageMovementData } from '../entity/stage-movement-data.entity';
|
|
3
|
+
import { EntityServiceImpl } from 'src/module/meta/service/entity-service-impl.service';
|
|
6
4
|
import { UserData } from 'src/module/user/entity/user.entity';
|
|
5
|
+
import { DataSource, Repository } from 'typeorm';
|
|
6
|
+
import { StageMovementData } from '../entity/stage-movement-data.entity';
|
|
7
|
+
import { ACTIVITY_CATEGORIES } from '../repository/activity-log.repository';
|
|
7
8
|
import { StageMovementRepository } from '../repository/stage-movement.repository';
|
|
8
|
-
import { EntityServiceImpl } from 'src/module/meta/service/entity-service-impl.service';
|
|
9
9
|
import { ActionDataService } from './action-data.service';
|
|
10
|
-
import { TaskService } from './task.service';
|
|
11
|
-
import { ACTIVITY_CATEGORIES } from '../repository/activity-log.repository';
|
|
12
10
|
import { ActivityLogService } from './activity-log.service';
|
|
13
11
|
import { EntityModificationService } from './entity-modification.service';
|
|
12
|
+
import { TaskService } from './task.service';
|
|
14
13
|
|
|
15
14
|
@Injectable()
|
|
16
15
|
export class WorkflowMetaService extends EntityServiceImpl {
|
|
@@ -390,7 +389,8 @@ export class WorkflowMetaService extends EntityServiceImpl {
|
|
|
390
389
|
await this.dataSource.query(
|
|
391
390
|
`UPDATE crm_lead_meeting SET user_id=?
|
|
392
391
|
WHERE stage_id = ?
|
|
393
|
-
AND
|
|
392
|
+
AND mapped_entity_id = ?
|
|
393
|
+
AND mapped_entity_type = "LEAD"
|
|
394
394
|
AND (status='scheduled' OR status='rescheduled')
|
|
395
395
|
`,
|
|
396
396
|
[lead_owner, stage_id, lead_id],
|