@ieeesa-npm/groups 0.10.7 → 0.10.8
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/esm2022/lib/assets/constants.json +4 -0
- package/esm2022/lib/components/edit-user-roles/edit-user-roles.component.mjs +8 -3
- package/esm2022/lib/components/view-roster/view-roster.component.mjs +31 -23
- package/esm2022/lib/groups.component.mjs +5 -2
- package/esm2022/lib/models/group-user-info.model.mjs +1 -1
- package/esm2022/lib/models/user.model.mjs +1 -1
- package/esm2022/lib/services/groups.service.mjs +19 -1
- package/fesm2022/ieeesa-npm-groups.mjs +62 -25
- package/fesm2022/ieeesa-npm-groups.mjs.map +1 -1
- package/lib/components/view-roster/view-roster.component.d.ts +2 -1
- package/lib/groups.component.d.ts +3 -1
- package/lib/models/group-user-info.model.d.ts +1 -0
- package/lib/models/user.model.d.ts +11 -0
- package/lib/services/groups.service.d.ts +21 -14
- package/package.json +3 -3
|
@@ -5,7 +5,7 @@ import { MatDialog } from '@angular/material/dialog';
|
|
|
5
5
|
import { TableColumnSchema, TableActions, AlignType, ChipOption, CheckboxOption, FiltersAndOptions } from '@ieeesa-npm/presentation';
|
|
6
6
|
import { AlertType, AlertsService, GlobalErrorHandlerService } from '@ieeesa-npm/utility';
|
|
7
7
|
import { GroupsService } from '../../services/groups.service';
|
|
8
|
-
import { User } from '../../models/user.model';
|
|
8
|
+
import { User, UserDetails } from '../../models/user.model';
|
|
9
9
|
import { GroupUserInfo } from '../../models/group-user-info.model';
|
|
10
10
|
import { GroupRosterType } from '../../models/roster-type.model';
|
|
11
11
|
import { FilterType } from '../../models/filter-type.model';
|
|
@@ -51,6 +51,7 @@ export declare class ViewRosterComponent implements AfterViewInit, OnDestroy, On
|
|
|
51
51
|
tableColumnsForIndividual: any;
|
|
52
52
|
tableColumnsForSystemUsers: any;
|
|
53
53
|
emptyFieldValueReplacedBy: any;
|
|
54
|
+
userInfo: UserDetails;
|
|
54
55
|
constructor(dialog: MatDialog, groupService: GroupsService, alertService: AlertsService, cdr: ChangeDetectorRef, globalErrorHandlerService: GlobalErrorHandlerService);
|
|
55
56
|
ngOnInit(): void;
|
|
56
57
|
/**
|
|
@@ -14,6 +14,7 @@ import { UserPermissionsService } from './services/user-permissions.service';
|
|
|
14
14
|
import { GroupPermission, UserPermission } from './models/group-permissions.model';
|
|
15
15
|
import { PermissionType } from './models/permission-type.model';
|
|
16
16
|
import { GroupPermissionsMapService } from './services/group-permissions-map-service';
|
|
17
|
+
import { UserDetails } from './models/user.model';
|
|
17
18
|
import * as i0 from "@angular/core";
|
|
18
19
|
/**
|
|
19
20
|
* Groups component is a wrapper or container component for groups management reusable component and in this component integrates all group management functionalities and this will be entry component for managing groups when it is consumed in other applications.
|
|
@@ -59,6 +60,7 @@ export declare class GroupsComponent implements OnInit, OnDestroy {
|
|
|
59
60
|
applicationId: string;
|
|
60
61
|
apiBaseURL: string;
|
|
61
62
|
userPermissions: UserPermission[];
|
|
63
|
+
userInfo: UserDetails;
|
|
62
64
|
permissionType: typeof PermissionType;
|
|
63
65
|
functionType: GroupFunctionType;
|
|
64
66
|
alignmentType: typeof AlignType;
|
|
@@ -202,5 +204,5 @@ export declare class GroupsComponent implements OnInit, OnDestroy {
|
|
|
202
204
|
*/
|
|
203
205
|
ngOnDestroy(): void;
|
|
204
206
|
static ɵfac: i0.ɵɵFactoryDeclaration<GroupsComponent, never>;
|
|
205
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<GroupsComponent, "ieeesa-groups", never, { "groupsPageInfo": { "alias": "groupsPageInfo"; "required": false; }; "applicationId": { "alias": "applicationId"; "required": false; }; "apiBaseURL": { "alias": "apiBaseURL"; "required": false; }; "userPermissions": { "alias": "userPermissions"; "required": false; }; }, {}, never, never, true, never>;
|
|
207
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<GroupsComponent, "ieeesa-groups", never, { "groupsPageInfo": { "alias": "groupsPageInfo"; "required": false; }; "applicationId": { "alias": "applicationId"; "required": false; }; "apiBaseURL": { "alias": "apiBaseURL"; "required": false; }; "userPermissions": { "alias": "userPermissions"; "required": false; }; "userInfo": { "alias": "userInfo"; "required": false; }; }, {}, never, never, true, never>;
|
|
206
208
|
}
|
|
@@ -12,6 +12,7 @@ export interface User {
|
|
|
12
12
|
organization: string | null;
|
|
13
13
|
employer: string | null;
|
|
14
14
|
checked?: boolean;
|
|
15
|
+
canDelete?: boolean;
|
|
15
16
|
}
|
|
16
17
|
export interface Employer {
|
|
17
18
|
orgId: string | null;
|
|
@@ -29,6 +30,7 @@ export interface GetGroupUsersResponse {
|
|
|
29
30
|
memberStatus: MemberType | null;
|
|
30
31
|
organization: Organization | null;
|
|
31
32
|
employer: Employer | null;
|
|
33
|
+
canDelete?: boolean;
|
|
32
34
|
}[];
|
|
33
35
|
}
|
|
34
36
|
export interface FilterUsersPayload {
|
|
@@ -48,3 +50,12 @@ export interface SearchUsersPayload {
|
|
|
48
50
|
ascendingOrder: boolean;
|
|
49
51
|
};
|
|
50
52
|
}
|
|
53
|
+
export interface UserDetails {
|
|
54
|
+
appId: string;
|
|
55
|
+
userId: string;
|
|
56
|
+
ssoId: string;
|
|
57
|
+
firstName: string;
|
|
58
|
+
lastName: string;
|
|
59
|
+
email: string;
|
|
60
|
+
canDelete?: boolean;
|
|
61
|
+
}
|
|
@@ -5,7 +5,7 @@ import { AlertsService, HttpService } from '@ieeesa-npm/utility';
|
|
|
5
5
|
import { GetGroupResponse, GetGroupsPayload } from '../models/view-group.model';
|
|
6
6
|
import { DeleteGroupPayload } from '../models/delete-group.model';
|
|
7
7
|
import { GroupInfo } from '../models/group-info.model';
|
|
8
|
-
import { SearchUsersPayload, FilterUsersPayload, GetGroupUsersResponse, User } from '../models/user.model';
|
|
8
|
+
import { SearchUsersPayload, FilterUsersPayload, GetGroupUsersResponse, User, UserDetails } from '../models/user.model';
|
|
9
9
|
import { CheckboxOption } from '@ieeesa-npm/presentation';
|
|
10
10
|
import { EditGroupPayload } from '../models/edit-group.model';
|
|
11
11
|
import { GroupFunctionType } from '../models/group-function-type.model';
|
|
@@ -53,7 +53,11 @@ export declare class GroupsService {
|
|
|
53
53
|
"1014": string;
|
|
54
54
|
"1015": string;
|
|
55
55
|
"1016": string;
|
|
56
|
-
"1017": string;
|
|
56
|
+
"1017": string; /**
|
|
57
|
+
* Returns the selected group parent group info.
|
|
58
|
+
* @return {(GroupInfo | undefined)} -group info.
|
|
59
|
+
* @memberof GroupsService
|
|
60
|
+
*/
|
|
57
61
|
"1018": string;
|
|
58
62
|
"1019": string;
|
|
59
63
|
"1020": string;
|
|
@@ -69,17 +73,13 @@ export declare class GroupsService {
|
|
|
69
73
|
"1030": string;
|
|
70
74
|
"1031": string;
|
|
71
75
|
"1032": string;
|
|
72
|
-
"1033": string;
|
|
73
|
-
* Gets the group users for the given group id.
|
|
74
|
-
* @param {string} groupId
|
|
75
|
-
* @return {Observable<GetGroupUsersResponse>}
|
|
76
|
-
* @memberof GroupsService
|
|
77
|
-
*/
|
|
76
|
+
"1033": string;
|
|
78
77
|
"1034": string;
|
|
79
78
|
"1035": string;
|
|
80
79
|
"1036": string;
|
|
81
80
|
"1037": string;
|
|
82
81
|
"1038": string;
|
|
82
|
+
"1039": string;
|
|
83
83
|
"2001": string;
|
|
84
84
|
"2002": string;
|
|
85
85
|
"2010": string;
|
|
@@ -97,12 +97,6 @@ export declare class GroupsService {
|
|
|
97
97
|
"2022": string;
|
|
98
98
|
"2023": string;
|
|
99
99
|
"2024": string;
|
|
100
|
-
/**
|
|
101
|
-
* Gets the group users based on searched name or email
|
|
102
|
-
* @param {SearchUsersPayload} payload
|
|
103
|
-
* @return {Observable<GetGroupUsersResponse>}
|
|
104
|
-
* @memberof GroupsService
|
|
105
|
-
*/
|
|
106
100
|
"3004": string;
|
|
107
101
|
};
|
|
108
102
|
apiBaseUrl: string;
|
|
@@ -118,6 +112,7 @@ export declare class GroupsService {
|
|
|
118
112
|
userGroupPermissions: GroupPermission[];
|
|
119
113
|
groupTypes: GroupTypeConfiguration[];
|
|
120
114
|
isParentGroupChanged: boolean;
|
|
115
|
+
userInfo: UserDetails;
|
|
121
116
|
constructor(httpService: HttpService, userPermissionsService: UserPermissionsService, groupPermissionsService: GroupPermissionsMapService, alertService: AlertsService);
|
|
122
117
|
setAppConfig(apiBaseUrl: string, userPermission: any): void;
|
|
123
118
|
/**
|
|
@@ -346,6 +341,18 @@ export declare class GroupsService {
|
|
|
346
341
|
* @memberof GroupsService
|
|
347
342
|
*/
|
|
348
343
|
getUserGroupPermissions(): GroupPermission[];
|
|
344
|
+
/**
|
|
345
|
+
* Sets the logged In user Info
|
|
346
|
+
* @param {UserDetails} userInfo
|
|
347
|
+
* @memberof GroupsService
|
|
348
|
+
*/
|
|
349
|
+
setUserInfo(userInfo: UserDetails): void;
|
|
350
|
+
/**
|
|
351
|
+
* Returns the logged in user Info
|
|
352
|
+
* @return {User}
|
|
353
|
+
* @memberof GroupsService
|
|
354
|
+
*/
|
|
355
|
+
getUserInfo(): UserDetails;
|
|
349
356
|
/**
|
|
350
357
|
* Validates permission based access for provided feature.
|
|
351
358
|
* Checks for group level permissions, and provides access based on individual group permissions.
|
package/package.json
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ieeesa-npm/groups",
|
|
3
|
-
"version": "0.10.
|
|
3
|
+
"version": "0.10.8",
|
|
4
4
|
"peerDependencies": {
|
|
5
5
|
"@angular/common": "^16.1.0",
|
|
6
6
|
"@angular/core": "^16.1.0",
|
|
7
|
-
"@ieeesa-npm/presentation": "^0.11.
|
|
7
|
+
"@ieeesa-npm/presentation": "^0.11.2",
|
|
8
8
|
"@ieeesa-npm/shared-styles": "^0.2.6",
|
|
9
|
-
"@ieeesa-npm/utility": "^0.
|
|
9
|
+
"@ieeesa-npm/utility": "^0.10.1"
|
|
10
10
|
},
|
|
11
11
|
"dependencies": {
|
|
12
12
|
"tslib": "^2.3.0"
|