@tiledesk/tiledesk-server 2.19.13 → 2.19.14
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/CHANGELOG.md +3 -0
- package/channels/chat21/chat21WebHook.js +13 -2
- package/docs/activities-client.md +864 -0
- package/event/requestEvent.js +14 -0
- package/jobs.js +1 -0
- package/jobsManager.js +2 -0
- package/package.json +1 -1
- package/pubmodules/activities/activityArchiver.js +699 -377
- package/pubmodules/activities/activityMessageUtil.js +336 -0
- package/pubmodules/activities/index.js +1 -1
- package/pubmodules/activities/models/activity.js +99 -2
- package/pubmodules/activities/routes/activity.js +114 -144
- package/pubmodules/messageActions/messageActionsInterceptor.js +15 -2
- package/pubmodules/queue/reconnect.js +307 -2
- package/pubmodules/rules/conciergeBot.js +7 -1
- package/pubmodules/trigger/rulesTrigger.js +33 -5
- package/routes/faq_kb.js +24 -1
- package/routes/kb.js +90 -2
- package/routes/project_user.js +66 -17
- package/routes/request.js +20 -8
- package/services/chatbotService.js +6 -3
- package/services/requestService.js +159 -11
- package/test/faqkbRoute.js +1 -0
- package/test/kbRoute.js +59 -0
- package/utils/activityActorUtil.js +167 -0
- package/utils/assignmentContextUtil.js +283 -0
- package/utils/projectUserUpdateContextUtil.js +325 -0
package/CHANGELOG.md
CHANGED
|
@@ -10,6 +10,7 @@ var RequestConstants = require("../../models/requestConstants");
|
|
|
10
10
|
|
|
11
11
|
var cacheUtil = require('../../utils/cacheUtil');
|
|
12
12
|
var cacheEnabler = require("../../services/cacheEnabler");
|
|
13
|
+
var assignmentContextUtil = require('../../utils/assignmentContextUtil');
|
|
13
14
|
|
|
14
15
|
|
|
15
16
|
var mongoose = require('mongoose');
|
|
@@ -515,7 +516,12 @@ router.post('/', function (req, res) {
|
|
|
515
516
|
}else {
|
|
516
517
|
|
|
517
518
|
// se gia in participants scarta
|
|
518
|
-
return requestService.addParticipantByRequestId(
|
|
519
|
+
return requestService.addParticipantByRequestId(
|
|
520
|
+
request_id,
|
|
521
|
+
id_project,
|
|
522
|
+
new_member,
|
|
523
|
+
assignmentContextUtil.buildInternalOptions('webhook', 'self_join')
|
|
524
|
+
).then(function(updatedRequest) {
|
|
519
525
|
winston.debug("Join memeber ok");
|
|
520
526
|
return res.json(updatedRequest);
|
|
521
527
|
}).catch(function(err){
|
|
@@ -563,7 +569,12 @@ router.post('/', function (req, res) {
|
|
|
563
569
|
|
|
564
570
|
winston.verbose("Chat21WebHook: leaving member : " + new_member +" from the request with request_id: " + request_id +" from the project with id: " + id_project);
|
|
565
571
|
|
|
566
|
-
return requestService.removeParticipantByRequestId(
|
|
572
|
+
return requestService.removeParticipantByRequestId(
|
|
573
|
+
request_id,
|
|
574
|
+
id_project,
|
|
575
|
+
new_member,
|
|
576
|
+
assignmentContextUtil.buildLeaveParticipantOptions('webhook', new_member)
|
|
577
|
+
).then(function(updatedRequest) {
|
|
567
578
|
winston.debug("Leave memeber ok");
|
|
568
579
|
return res.json(updatedRequest);
|
|
569
580
|
}).catch(function(err){
|