vcomply-workflow-engine 2.6.131 → 2.6.133
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/bundles/vcomply-workflow-engine.umd.js +30 -29
- package/bundles/vcomply-workflow-engine.umd.js.map +1 -1
- package/esm2015/lib/workflow-compliance/workflow-compliance.component.js +31 -30
- package/fesm2015/vcomply-workflow-engine.js +30 -29
- package/fesm2015/vcomply-workflow-engine.js.map +1 -1
- package/package.json +1 -1
|
@@ -3852,9 +3852,9 @@
|
|
|
3852
3852
|
var overseerUserList = [];
|
|
3853
3853
|
var overseerUserNotifyList = [];
|
|
3854
3854
|
var overseerEmployeesList = (res === null || res === void 0 ? void 0 : res.cc_email) ? Object.keys(res === null || res === void 0 ? void 0 : res.cc_email).map(Number) : [];
|
|
3855
|
-
overseerUserList = ((
|
|
3855
|
+
overseerUserList = ((overseerEmployeesList === null || overseerEmployeesList === void 0 ? void 0 : overseerEmployeesList.length) > 0 && ((_b = (_a = res === null || res === void 0 ? void 0 : res.userGroupIds) === null || _a === void 0 ? void 0 : _a.ccEmailGroupIds) === null || _b === void 0 ? void 0 : _b.length) > 0) ? overseerEmployeesList.filter(function (employeeIds) { var _a, _b; return (_b = (_a = res === null || res === void 0 ? void 0 : res.existingUserIds) === null || _a === void 0 ? void 0 : _a.ccEmailEmpIds) === null || _b === void 0 ? void 0 : _b.includes(employeeIds); }) : __spreadArray([], __read(overseerEmployeesList));
|
|
3856
3856
|
var overseerEmployeeNotifyList = (res === null || res === void 0 ? void 0 : res.failure_cc_email) ? Object.keys(res === null || res === void 0 ? void 0 : res.failure_cc_email).map(Number) : [];
|
|
3857
|
-
overseerUserNotifyList = ((
|
|
3857
|
+
overseerUserNotifyList = ((overseerEmployeeNotifyList === null || overseerEmployeeNotifyList === void 0 ? void 0 : overseerEmployeeNotifyList.length) > 0 && ((_d = (_c = res === null || res === void 0 ? void 0 : res.userGroupIds) === null || _c === void 0 ? void 0 : _c.failureCCEmailGroupIds) === null || _d === void 0 ? void 0 : _d.length) > 0) ? overseerEmployeeNotifyList.filter(function (employeeIds) { var _a, _b; return (_b = (_a = res === null || res === void 0 ? void 0 : res.existingUserIds) === null || _a === void 0 ? void 0 : _a.failureCCEmailEmpIds) === null || _b === void 0 ? void 0 : _b.includes(employeeIds); }) : __spreadArray([], __read(overseerEmployeeNotifyList));
|
|
3858
3858
|
this.responsibilityForm["overseers"] = {
|
|
3859
3859
|
list: (res === null || res === void 0 ? void 0 : res.cc_email) ? this.setList(this.overseersList, overseerUserList, 'employee_id') : [],
|
|
3860
3860
|
notifyList: (res === null || res === void 0 ? void 0 : res.failure_cc_email) ? this.setList(this.overseersList, overseerUserNotifyList, 'employee_id') : [],
|
|
@@ -3865,23 +3865,23 @@
|
|
|
3865
3865
|
};
|
|
3866
3866
|
};
|
|
3867
3867
|
WorkflowComplianceComponent.prototype.populateReviewerData = function (res) {
|
|
3868
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m;
|
|
3868
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t;
|
|
3869
3869
|
var reviewerDetails = Object.keys(res === null || res === void 0 ? void 0 : res.reviewer_arr);
|
|
3870
|
-
this.hasReviewer = reviewerDetails.length > 0;
|
|
3871
|
-
var groupReviewerDetails = ((_a = res === null || res === void 0 ? void 0 : res.userGroupIds) === null || _a === void 0 ? void 0 : _a.reviewerGroupIds.length) ? Object.assign((
|
|
3870
|
+
this.hasReviewer = (reviewerDetails === null || reviewerDetails === void 0 ? void 0 : reviewerDetails.length) > 0;
|
|
3871
|
+
var groupReviewerDetails = ((_b = (_a = res === null || res === void 0 ? void 0 : res.userGroupIds) === null || _a === void 0 ? void 0 : _a.reviewerGroupIds) === null || _b === void 0 ? void 0 : _b.length) ? Object.assign((_c = res === null || res === void 0 ? void 0 : res.userGroupIds) === null || _c === void 0 ? void 0 : _c.reviewerGroupIds) : [];
|
|
3872
3872
|
var reviewer_users = [];
|
|
3873
|
-
reviewer_users = (((
|
|
3873
|
+
reviewer_users = (((_f = (_e = (_d = res === null || res === void 0 ? void 0 : res.reviewer_arr) === null || _d === void 0 ? void 0 : _d.level1) === null || _e === void 0 ? void 0 : _e.reviewers) === null || _f === void 0 ? void 0 : _f.length) > 0 && ((_h = (_g = res === null || res === void 0 ? void 0 : res.userGroupIds) === null || _g === void 0 ? void 0 : _g.reviewerGroupIds) === null || _h === void 0 ? void 0 : _h.length) > 0) ? (_k = (_j = res === null || res === void 0 ? void 0 : res.reviewer_arr) === null || _j === void 0 ? void 0 : _j.level1) === null || _k === void 0 ? void 0 : _k.reviewers.filter(function (memberId) { var _a, _b; return (_b = (_a = res === null || res === void 0 ? void 0 : res.existingUserIds) === null || _a === void 0 ? void 0 : _a.reviewerIds) === null || _b === void 0 ? void 0 : _b.includes(memberId === null || memberId === void 0 ? void 0 : memberId.member_id); }) : (_m = (_l = res === null || res === void 0 ? void 0 : res.reviewer_arr) === null || _l === void 0 ? void 0 : _l.level1) === null || _m === void 0 ? void 0 : _m.reviewers;
|
|
3874
3874
|
this.responsibilityForm["reviewers"] = {
|
|
3875
|
-
sequentialWorkflow: (((
|
|
3875
|
+
sequentialWorkflow: (((_p = (_o = res === null || res === void 0 ? void 0 : res.reviewer_arr) === null || _o === void 0 ? void 0 : _o.level1) === null || _p === void 0 ? void 0 : _p.type) == 'SEQUENTIAL') ? true : false,
|
|
3876
3876
|
reviewFrequency: {
|
|
3877
3877
|
reviewCompleteDays: ((reviewerDetails === null || reviewerDetails === void 0 ? void 0 : reviewerDetails.length) > 0) ? res === null || res === void 0 ? void 0 : res.review_after_days : 2,
|
|
3878
3878
|
reviewNOtCompletedDays: ((reviewerDetails === null || reviewerDetails === void 0 ? void 0 : reviewerDetails.length) > 0) ? res === null || res === void 0 ? void 0 : res.review_failed_after_days : 2
|
|
3879
3879
|
},
|
|
3880
3880
|
acceptedData: (reviewerDetails === null || reviewerDetails === void 0 ? void 0 : reviewerDetails.length) > 0 ? reviewer_users : [],
|
|
3881
|
-
list: (reviewerDetails === null || reviewerDetails === void 0 ? void 0 : reviewerDetails.length) > 0 ? this.setReviewerPayload(reviewer_users, 'object', (
|
|
3881
|
+
list: (reviewerDetails === null || reviewerDetails === void 0 ? void 0 : reviewerDetails.length) > 0 ? this.setReviewerPayload(reviewer_users, 'object', (_r = (_q = res === null || res === void 0 ? void 0 : res.reviewer_arr) === null || _q === void 0 ? void 0 : _q.level1) === null || _r === void 0 ? void 0 : _r.type) : []
|
|
3882
3882
|
};
|
|
3883
3883
|
this.responsibilityForm["groupReviewers"] = {
|
|
3884
|
-
sequentialWorkflow: (((
|
|
3884
|
+
sequentialWorkflow: (((_t = (_s = res === null || res === void 0 ? void 0 : res.reviewer_arr) === null || _s === void 0 ? void 0 : _s.level1) === null || _t === void 0 ? void 0 : _t.type) == 'SEQUENTIAL') ? true : false,
|
|
3885
3885
|
reviewFrequency: {
|
|
3886
3886
|
reviewCompleteDays: ((reviewerDetails === null || reviewerDetails === void 0 ? void 0 : reviewerDetails.length) > 0) ? res === null || res === void 0 ? void 0 : res.review_after_days : 2,
|
|
3887
3887
|
reviewNOtCompletedDays: ((reviewerDetails === null || reviewerDetails === void 0 ? void 0 : reviewerDetails.length) > 0) ? res === null || res === void 0 ? void 0 : res.review_failed_after_days : 2
|
|
@@ -3890,23 +3890,23 @@
|
|
|
3890
3890
|
};
|
|
3891
3891
|
};
|
|
3892
3892
|
WorkflowComplianceComponent.prototype.populateAssigneeData = function (res) {
|
|
3893
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
3893
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l;
|
|
3894
3894
|
var AssigneeAnyUserList = [];
|
|
3895
3895
|
var AssigneeAllUserList = [];
|
|
3896
3896
|
var assigneeAnyOneList = ((res === null || res === void 0 ? void 0 : res.assigned_to_member_id) && this.isEntrust) ? res === null || res === void 0 ? void 0 : res.assigned_to_member_id : [];
|
|
3897
|
-
AssigneeAnyUserList = ((res === null || res === void 0 ? void 0 : res.assigned_to_member_id.length) > 0 && ((
|
|
3897
|
+
AssigneeAnyUserList = (((_a = res === null || res === void 0 ? void 0 : res.assigned_to_member_id) === null || _a === void 0 ? void 0 : _a.length) > 0 && ((_c = (_b = res === null || res === void 0 ? void 0 : res.userGroupIds) === null || _b === void 0 ? void 0 : _b.assigneeAnyoneGroupIds) === null || _c === void 0 ? void 0 : _c.length) > 0) ? assigneeAnyOneList.filter(function (employeeIds) { var _a, _b; return (_b = (_a = res === null || res === void 0 ? void 0 : res.existingUserIds) === null || _a === void 0 ? void 0 : _a.assigneeAnyoneIds) === null || _b === void 0 ? void 0 : _b.includes(employeeIds); }) : __spreadArray([], __read(assigneeAnyOneList));
|
|
3898
3898
|
AssigneeAllUserList = ((res === null || res === void 0 ? void 0 : res.assigned_to) && !this.isEntrust) ? res === null || res === void 0 ? void 0 : res.assigned_to : [];
|
|
3899
3899
|
this.responsibilityForm["assignees"] = {
|
|
3900
3900
|
whoCanComplete: (res.isGroupAssignTo) ? 'ANY_ONE' : 'ALL',
|
|
3901
|
-
list: (res.assigned_to_member_id.length == 0) ? this.setList(this.assigneesList, [Number(AssigneeAllUserList)], 'employee_id') :
|
|
3901
|
+
list: (((_d = res === null || res === void 0 ? void 0 : res.assigned_to_member_id) === null || _d === void 0 ? void 0 : _d.length) == 0) ? this.setList(this.assigneesList, [Number(AssigneeAllUserList)], 'employee_id') :
|
|
3902
3902
|
this.setList(this.assigneesList, AssigneeAnyUserList, 'my_member_id'),
|
|
3903
3903
|
};
|
|
3904
3904
|
this.responsibilityForm["assigneeGroups"] = {
|
|
3905
|
-
whoCanComplete: (res.isGroupAssignTo) ? 'ANY_ONE' : 'ALL',
|
|
3906
|
-
list: (((
|
|
3907
|
-
this.setList(this.OrgGroup, (
|
|
3905
|
+
whoCanComplete: (res === null || res === void 0 ? void 0 : res.isGroupAssignTo) ? 'ANY_ONE' : 'ALL',
|
|
3906
|
+
list: (((_f = (_e = res === null || res === void 0 ? void 0 : res.userGroupIds) === null || _e === void 0 ? void 0 : _e.assigneeAnyoneGroupIds) === null || _f === void 0 ? void 0 : _f.length) == 0) ? this.setList(this.OrgGroup, (_g = res === null || res === void 0 ? void 0 : res.userGroupIds) === null || _g === void 0 ? void 0 : _g.assigneeAllGroupIds, 'group_id') :
|
|
3907
|
+
this.setList(this.OrgGroup, (_h = res === null || res === void 0 ? void 0 : res.userGroupIds) === null || _h === void 0 ? void 0 : _h.assigneeAnyoneGroupIds, 'group_id'),
|
|
3908
3908
|
};
|
|
3909
|
-
this.allGroupAssignee = (((
|
|
3909
|
+
this.allGroupAssignee = (((_l = (_k = (_j = this.responsibilityForm) === null || _j === void 0 ? void 0 : _j.assigneeGroups) === null || _k === void 0 ? void 0 : _k.list) === null || _l === void 0 ? void 0 : _l.length) > 0 && !this.isEntrust);
|
|
3910
3910
|
};
|
|
3911
3911
|
/**
|
|
3912
3912
|
* this function is for getting the users data based on member_id of users of selected User Group
|
|
@@ -3917,11 +3917,11 @@
|
|
|
3917
3917
|
WorkflowComplianceComponent.prototype.getGroupsUserEmployeesId = function (userList, selectedGroups) {
|
|
3918
3918
|
var groupMemberIds = [];
|
|
3919
3919
|
var groupUserEmployee = [];
|
|
3920
|
-
selectedGroups.forEach(function (group) {
|
|
3921
|
-
groupMemberIds = __spreadArray([], __read(new Set(__spreadArray(__spreadArray([], __read(groupMemberIds)), __read(group.member_ids)))));
|
|
3920
|
+
selectedGroups === null || selectedGroups === void 0 ? void 0 : selectedGroups.forEach(function (group) {
|
|
3921
|
+
groupMemberIds = __spreadArray([], __read(new Set(__spreadArray(__spreadArray([], __read(groupMemberIds)), __read(group === null || group === void 0 ? void 0 : group.member_ids)))));
|
|
3922
3922
|
});
|
|
3923
|
-
userList.forEach(function (ele) {
|
|
3924
|
-
if (groupMemberIds.includes(ele.my_member_id)) {
|
|
3923
|
+
userList === null || userList === void 0 ? void 0 : userList.forEach(function (ele) {
|
|
3924
|
+
if (groupMemberIds === null || groupMemberIds === void 0 ? void 0 : groupMemberIds.includes(ele.my_member_id)) {
|
|
3925
3925
|
groupUserEmployee.push(ele);
|
|
3926
3926
|
}
|
|
3927
3927
|
});
|
|
@@ -4929,11 +4929,12 @@
|
|
|
4929
4929
|
};
|
|
4930
4930
|
WorkflowComplianceComponent.prototype.uniqueIdUserGroups = function (totalUserList, selectedGroup, selectedUsers) {
|
|
4931
4931
|
var groupUserList = this.getGroupsUserEmployeesId(totalUserList, selectedGroup);
|
|
4932
|
-
var ids = new Set(selectedUsers.map(function (
|
|
4933
|
-
var userList = __spreadArray(__spreadArray([], __read(selectedUsers)), __read(groupUserList.filter(function (
|
|
4932
|
+
var ids = new Set(selectedUsers.map(function (user) { return user === null || user === void 0 ? void 0 : user.my_member_id; }));
|
|
4933
|
+
var userList = __spreadArray(__spreadArray([], __read(selectedUsers)), __read(groupUserList.filter(function (groupUser) { return !ids.has(groupUser === null || groupUser === void 0 ? void 0 : groupUser.my_member_id); })));
|
|
4934
4934
|
return userList;
|
|
4935
4935
|
};
|
|
4936
4936
|
WorkflowComplianceComponent.prototype.combineUserAndUserGroupMembers = function () {
|
|
4937
|
+
var _a, _b, _c, _d, _e, _f, _g, _h;
|
|
4937
4938
|
if (this.featureFlag_groups) {
|
|
4938
4939
|
this.assigneeUserList = this.uniqueIdUserGroups(this.allUsersList, this.responsibilityForm.assigneeGroups.list, this.responsibilityForm.assignees.list);
|
|
4939
4940
|
this.reviewerUserList = this.uniqueIdUserGroups(this.allUsersList, this.responsibilityForm.groupReviewers.list, this.responsibilityForm.reviewers.list);
|
|
@@ -4941,10 +4942,10 @@
|
|
|
4941
4942
|
this.overseerUserNotifyList = this.uniqueIdUserGroups(this.allUsersList, this.responsibilityForm.overseersGroups.notifyList, this.responsibilityForm.overseers.notifyList);
|
|
4942
4943
|
}
|
|
4943
4944
|
else {
|
|
4944
|
-
this.assigneeUserList = this.responsibilityForm.assignees.list;
|
|
4945
|
-
this.reviewerUserList = this.responsibilityForm.reviewers.list;
|
|
4946
|
-
this.overseerUserList = this.responsibilityForm.overseers.list;
|
|
4947
|
-
this.overseerUserNotifyList = this.responsibilityForm.overseers.notifyList;
|
|
4945
|
+
this.assigneeUserList = (_b = (_a = this.responsibilityForm) === null || _a === void 0 ? void 0 : _a.assignees) === null || _b === void 0 ? void 0 : _b.list;
|
|
4946
|
+
this.reviewerUserList = (_d = (_c = this.responsibilityForm) === null || _c === void 0 ? void 0 : _c.reviewers) === null || _d === void 0 ? void 0 : _d.list;
|
|
4947
|
+
this.overseerUserList = (_f = (_e = this.responsibilityForm) === null || _e === void 0 ? void 0 : _e.overseers) === null || _f === void 0 ? void 0 : _f.list;
|
|
4948
|
+
this.overseerUserNotifyList = (_h = (_g = this.responsibilityForm) === null || _g === void 0 ? void 0 : _g.overseers) === null || _h === void 0 ? void 0 : _h.notifyList;
|
|
4948
4949
|
}
|
|
4949
4950
|
};
|
|
4950
4951
|
/**
|
|
@@ -5508,7 +5509,7 @@
|
|
|
5508
5509
|
* @param {any} [res] - is the response from the API
|
|
5509
5510
|
*/
|
|
5510
5511
|
WorkflowComplianceComponent.prototype.getEditMoreOptions = function (res) {
|
|
5511
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
5512
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t;
|
|
5512
5513
|
var checkedMoreOptions = [];
|
|
5513
5514
|
if (this.responsibilityForm.objective !== '') {
|
|
5514
5515
|
checkedMoreOptions.push('OBJECTIVE');
|
|
@@ -5532,11 +5533,11 @@
|
|
|
5532
5533
|
checkedMoreOptions.push('CHECKPOINTS');
|
|
5533
5534
|
this.moreOptions.CHECKPOINTS = true;
|
|
5534
5535
|
}
|
|
5535
|
-
if (this.responsibilityForm.reviewers.list.length > 0 || ((
|
|
5536
|
+
if (((_c = (_b = (_a = this.responsibilityForm) === null || _a === void 0 ? void 0 : _a.reviewers) === null || _b === void 0 ? void 0 : _b.list) === null || _c === void 0 ? void 0 : _c.length) > 0 || ((_f = (_e = (_d = this.responsibilityForm) === null || _d === void 0 ? void 0 : _d.groupReviewer) === null || _e === void 0 ? void 0 : _e.list) === null || _f === void 0 ? void 0 : _f.length) > 0) {
|
|
5536
5537
|
checkedMoreOptions.push('REVIEWER');
|
|
5537
5538
|
this.moreOptions.REVIEWER = true;
|
|
5538
5539
|
}
|
|
5539
|
-
if (this.responsibilityForm.overseers.list.length > 0 || this.responsibilityForm.overseers.notifyList.length > 0 || ((
|
|
5540
|
+
if (((_j = (_h = (_g = this.responsibilityForm) === null || _g === void 0 ? void 0 : _g.overseers) === null || _h === void 0 ? void 0 : _h.list) === null || _j === void 0 ? void 0 : _j.length) > 0 || ((_m = (_l = (_k = this.responsibilityForm) === null || _k === void 0 ? void 0 : _k.overseers) === null || _l === void 0 ? void 0 : _l.notifyList) === null || _m === void 0 ? void 0 : _m.length) > 0 || ((_q = (_p = (_o = this.responsibilityForm) === null || _o === void 0 ? void 0 : _o.overseersGroups) === null || _p === void 0 ? void 0 : _p.list) === null || _q === void 0 ? void 0 : _q.length) > 0 || ((_t = (_s = (_r = this.responsibilityForm) === null || _r === void 0 ? void 0 : _r.overseersGroups) === null || _s === void 0 ? void 0 : _s.notifyList) === null || _t === void 0 ? void 0 : _t.length) > 0) {
|
|
5540
5541
|
checkedMoreOptions.push('OVERSEER');
|
|
5541
5542
|
this.moreOptions.OVERSEER = true;
|
|
5542
5543
|
}
|