@ieeesa-npm/tenants 0.4.3 → 0.4.4
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/.eslintrc.json +31 -0
- package/ng-package.json +8 -0
- package/package.json +12 -25
- package/src/lib/assets/constants.json +454 -0
- package/src/lib/assets/tenant-validations.ts +18 -0
- package/src/lib/assets/tenants-mock.ts +1240 -0
- package/src/lib/components/create-modify-group-type/create-modify-group-type.component.html +15 -0
- package/src/lib/components/create-modify-group-type/create-modify-group-type.component.scss +44 -0
- package/src/lib/components/create-modify-group-type/create-modify-group-type.component.spec.ts +574 -0
- package/src/lib/components/create-modify-group-type/create-modify-group-type.component.ts +602 -0
- package/src/lib/components/create-modify-role/create-modify-role.component.html +15 -0
- package/src/lib/components/create-modify-role/create-modify-role.component.scss +83 -0
- package/src/lib/components/create-modify-role/create-modify-role.component.spec.ts +346 -0
- package/src/lib/components/create-modify-role/create-modify-role.component.ts +321 -0
- package/src/lib/components/create-tenant-application/create-tenant-application.component.html +18 -0
- package/src/lib/components/create-tenant-application/create-tenant-application.component.scss +73 -0
- package/src/lib/components/create-tenant-application/create-tenant-application.component.spec.ts +775 -0
- package/src/lib/components/create-tenant-application/create-tenant-application.component.ts +638 -0
- package/src/lib/components/roles-and-permissions-mapping/roles-and-permissions-mapping.component.html +22 -0
- package/src/lib/components/roles-and-permissions-mapping/roles-and-permissions-mapping.component.scss +79 -0
- package/src/lib/components/roles-and-permissions-mapping/roles-and-permissions-mapping.component.spec.ts +716 -0
- package/src/lib/components/roles-and-permissions-mapping/roles-and-permissions-mapping.component.ts +504 -0
- package/src/lib/components/tenant-basic-details/tenant-basic-details.component.html +44 -0
- package/src/lib/components/tenant-basic-details/tenant-basic-details.component.scss +16 -0
- package/src/lib/components/tenant-basic-details/tenant-basic-details.component.spec.ts +115 -0
- package/src/lib/components/tenant-basic-details/tenant-basic-details.component.ts +109 -0
- package/src/lib/components/view-tenant-details/view-tenant-details.component.html +195 -0
- package/src/lib/components/view-tenant-details/view-tenant-details.component.scss +163 -0
- package/src/lib/components/view-tenant-details/view-tenant-details.component.spec.ts +1221 -0
- package/src/lib/components/view-tenant-details/view-tenant-details.component.ts +876 -0
- package/src/lib/components/view-tenant-group-types/view-tenant-group-types.component.html +10 -0
- package/src/lib/components/view-tenant-group-types/view-tenant-group-types.component.scss +44 -0
- package/src/lib/components/view-tenant-group-types/view-tenant-group-types.component.spec.ts +410 -0
- package/src/lib/components/view-tenant-group-types/view-tenant-group-types.component.ts +219 -0
- package/src/lib/components/view-tenants-list/view-tenants-list.component.html +32 -0
- package/src/lib/components/view-tenants-list/view-tenants-list.component.scss +35 -0
- package/src/lib/components/view-tenants-list/view-tenants-list.component.spec.ts +464 -0
- package/src/lib/components/view-tenants-list/view-tenants-list.component.ts +388 -0
- package/src/lib/models/app-type-config.model.ts +14 -0
- package/src/lib/models/app-type.model.ts +5 -0
- package/src/lib/models/create-group-type-config.model.ts +18 -0
- package/src/lib/models/create-group-type.model.ts +46 -0
- package/src/lib/models/feature-permission-id.model.ts +6 -0
- package/src/lib/models/features.model.ts +15 -0
- package/src/lib/models/form-status.model.ts +5 -0
- package/src/lib/models/permission-type.model.ts +9 -0
- package/src/lib/models/role-menu-action.model.ts +5 -0
- package/src/lib/models/role-type.model.ts +34 -0
- package/src/lib/models/roles-and-permissions-table-type.model.ts +5 -0
- package/src/lib/models/roles-and-permissions.model.ts +113 -0
- package/src/lib/models/route-config.model.ts +4 -0
- package/src/lib/models/table-column-schema-view-tenant-list.model.ts +21 -0
- package/src/lib/models/tenant-function-type.model.ts +10 -0
- package/src/lib/models/tenant.model.ts +47 -0
- package/src/lib/models/tenants-permission.model.ts +9 -0
- package/src/lib/models/update-tenant-status.model.ts +12 -0
- package/src/lib/models/view-tenant-group-types.model.ts +34 -0
- package/src/lib/services/tenant-applications.service.spec.ts +1245 -0
- package/src/lib/services/tenant-applications.service.ts +798 -0
- package/src/lib/services/tenant-permissions-map.service.spec.ts +25 -0
- package/src/lib/services/tenant-permissions-map.service.ts +28 -0
- package/src/lib/services/tenant-permissions.service.spec.ts +62 -0
- package/src/lib/services/tenant-permissions.service.ts +49 -0
- package/src/lib/tenant-applications.component.html +0 -0
- package/src/lib/tenant-applications.component.scss +0 -0
- package/src/lib/tenant-applications.component.spec.ts +28 -0
- package/src/lib/tenant-applications.component.ts +12 -0
- package/src/lib/tenant-applications.module.ts +8 -0
- package/{public-api.d.ts → src/public-api.ts} +40 -33
- package/tsconfig.lib.json +14 -0
- package/tsconfig.lib.prod.json +10 -0
- package/tsconfig.spec.json +14 -0
- package/esm2022/ieeesa-npm-tenants.mjs +0 -5
- package/esm2022/lib/assets/constants.json +0 -454
- package/esm2022/lib/assets/tenant-validations.mjs +0 -17
- package/esm2022/lib/components/create-modify-group-type/create-modify-group-type.component.mjs +0 -477
- package/esm2022/lib/components/create-modify-role/create-modify-role.component.mjs +0 -280
- package/esm2022/lib/components/create-tenant-application/create-tenant-application.component.mjs +0 -512
- package/esm2022/lib/components/roles-and-permissions-mapping/roles-and-permissions-mapping.component.mjs +0 -391
- package/esm2022/lib/components/tenant-basic-details/tenant-basic-details.component.mjs +0 -95
- package/esm2022/lib/components/view-tenant-details/view-tenant-details.component.mjs +0 -732
- package/esm2022/lib/components/view-tenant-group-types/view-tenant-group-types.component.mjs +0 -194
- package/esm2022/lib/components/view-tenants-list/view-tenants-list.component.mjs +0 -334
- package/esm2022/lib/models/app-type-config.model.mjs +0 -2
- package/esm2022/lib/models/app-type.model.mjs +0 -7
- package/esm2022/lib/models/create-group-type-config.model.mjs +0 -22
- package/esm2022/lib/models/create-group-type.model.mjs +0 -2
- package/esm2022/lib/models/feature-permission-id.model.mjs +0 -8
- package/esm2022/lib/models/features.model.mjs +0 -2
- package/esm2022/lib/models/form-status.model.mjs +0 -7
- package/esm2022/lib/models/permission-type.model.mjs +0 -12
- package/esm2022/lib/models/role-menu-action.model.mjs +0 -7
- package/esm2022/lib/models/role-type.model.mjs +0 -2
- package/esm2022/lib/models/roles-and-permissions-table-type.model.mjs +0 -7
- package/esm2022/lib/models/roles-and-permissions.model.mjs +0 -2
- package/esm2022/lib/models/route-config.model.mjs +0 -2
- package/esm2022/lib/models/table-column-schema-view-tenant-list.model.mjs +0 -16
- package/esm2022/lib/models/tenant-function-type.model.mjs +0 -12
- package/esm2022/lib/models/tenant.model.mjs +0 -2
- package/esm2022/lib/models/tenants-permission.model.mjs +0 -2
- package/esm2022/lib/models/update-tenant-status.model.mjs +0 -2
- package/esm2022/lib/models/view-tenant-group-types.model.mjs +0 -11
- package/esm2022/lib/services/tenant-applications.service.mjs +0 -618
- package/esm2022/lib/services/tenant-permissions-map.service.mjs +0 -36
- package/esm2022/lib/services/tenant-permissions.service.mjs +0 -38
- package/esm2022/lib/tenant-applications.component.mjs +0 -14
- package/esm2022/lib/tenant-applications.module.mjs +0 -16
- package/esm2022/public-api.mjs +0 -37
- package/fesm2022/ieeesa-npm-tenants.mjs +0 -4241
- package/fesm2022/ieeesa-npm-tenants.mjs.map +0 -1
- package/index.d.ts +0 -5
- package/lib/assets/tenant-validations.d.ts +0 -15
- package/lib/components/create-modify-group-type/create-modify-group-type.component.d.ts +0 -129
- package/lib/components/create-modify-role/create-modify-role.component.d.ts +0 -103
- package/lib/components/create-tenant-application/create-tenant-application.component.d.ts +0 -128
- package/lib/components/roles-and-permissions-mapping/roles-and-permissions-mapping.component.d.ts +0 -106
- package/lib/components/tenant-basic-details/tenant-basic-details.component.d.ts +0 -472
- package/lib/components/view-tenant-details/view-tenant-details.component.d.ts +0 -223
- package/lib/components/view-tenant-group-types/view-tenant-group-types.component.d.ts +0 -63
- package/lib/components/view-tenants-list/view-tenants-list.component.d.ts +0 -134
- package/lib/models/app-type-config.model.d.ts +0 -14
- package/lib/models/app-type.model.d.ts +0 -4
- package/lib/models/create-group-type-config.model.d.ts +0 -16
- package/lib/models/create-group-type.model.d.ts +0 -49
- package/lib/models/feature-permission-id.model.d.ts +0 -4
- package/lib/models/features.model.d.ts +0 -15
- package/lib/models/form-status.model.d.ts +0 -4
- package/lib/models/permission-type.model.d.ts +0 -8
- package/lib/models/role-menu-action.model.d.ts +0 -4
- package/lib/models/role-type.model.d.ts +0 -27
- package/lib/models/roles-and-permissions-table-type.model.d.ts +0 -4
- package/lib/models/roles-and-permissions.model.d.ts +0 -119
- package/lib/models/route-config.model.d.ts +0 -4
- package/lib/models/table-column-schema-view-tenant-list.model.d.ts +0 -20
- package/lib/models/tenant-function-type.model.d.ts +0 -9
- package/lib/models/tenant.model.d.ts +0 -51
- package/lib/models/tenants-permission.model.d.ts +0 -9
- package/lib/models/update-tenant-status.model.d.ts +0 -14
- package/lib/models/view-tenant-group-types.model.d.ts +0 -29
- package/lib/services/tenant-applications.service.d.ts +0 -398
- package/lib/services/tenant-permissions-map.service.d.ts +0 -13
- package/lib/services/tenant-permissions.service.d.ts +0 -22
- package/lib/tenant-applications.component.d.ts +0 -5
- package/lib/tenant-applications.module.d.ts +0 -6
package/index.d.ts
DELETED
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
export declare const TenantsValidationPatterns: {
|
|
2
|
-
appTitleMaxLength: number;
|
|
3
|
-
appIdMaxLength: number;
|
|
4
|
-
appHeadingMaxLength: number;
|
|
5
|
-
appDescriptionMaxLength: number;
|
|
6
|
-
url: RegExp;
|
|
7
|
-
alphaNumeric: RegExp;
|
|
8
|
-
};
|
|
9
|
-
export declare const RolesValidation: {
|
|
10
|
-
roleNameMaxLength: number;
|
|
11
|
-
};
|
|
12
|
-
export declare const GroupTypeValidation: {
|
|
13
|
-
groupTypeMaxLength: number;
|
|
14
|
-
descriptionMaxLength: number;
|
|
15
|
-
};
|
|
@@ -1,129 +0,0 @@
|
|
|
1
|
-
import { ComponentRef, ElementRef, EventEmitter, OnDestroy, OnInit, Renderer2, ViewContainerRef } from '@angular/core';
|
|
2
|
-
import { FormGroup } from '@angular/forms';
|
|
3
|
-
import { Subject } from 'rxjs';
|
|
4
|
-
import { SharedService, FormUtilityService } from '@ieeesa-npm/shared';
|
|
5
|
-
import { AlignType, CheckboxOption, FieldConfig, FormGrid, FormModel, RadioOption, DynamicFormComponent } from '@ieeesa-npm/presentation';
|
|
6
|
-
import { TenantApplicationsService } from '../../services/tenant-applications.service';
|
|
7
|
-
import { TenantFunctionType } from '../../models/tenant-function-type.model';
|
|
8
|
-
import { ViewGroupTypeResponse } from '../../models/view-tenant-group-types.model';
|
|
9
|
-
import { CreatedOrModifiedGroupTypeInfo } from '../../models/create-group-type.model';
|
|
10
|
-
import * as i0 from "@angular/core";
|
|
11
|
-
/**
|
|
12
|
-
* CreateModifyGroupTypeComponent uses DynamicFormComponent to build create add group type form or edit group type form and implement the functionalities of submission of form and handling success and error scenarios.
|
|
13
|
-
* @class CreateModifyGroupTypeComponent
|
|
14
|
-
* @implements {OnInit}
|
|
15
|
-
* @implements {OnDestroy}
|
|
16
|
-
*/
|
|
17
|
-
export declare class CreateModifyGroupTypeComponent implements OnInit, OnDestroy {
|
|
18
|
-
private tenantAppService;
|
|
19
|
-
private sharedService;
|
|
20
|
-
private renderer;
|
|
21
|
-
private elementRef;
|
|
22
|
-
private formUtilityService;
|
|
23
|
-
destroy$: Subject<boolean>;
|
|
24
|
-
constants: any;
|
|
25
|
-
createGroupTypeScreenTexts: any;
|
|
26
|
-
leftButtonLabel: any;
|
|
27
|
-
rightButtonLabel: any;
|
|
28
|
-
colWidth: FormGrid;
|
|
29
|
-
createGroupTypeFormGroup: FormModel;
|
|
30
|
-
createModifyGroupTypeFormGroupRef: FormGroup;
|
|
31
|
-
actionButtonAlign: AlignType;
|
|
32
|
-
tenantFunctionType: TenantFunctionType;
|
|
33
|
-
isRootGroupOptions: {
|
|
34
|
-
id: number;
|
|
35
|
-
label: any;
|
|
36
|
-
checked: boolean;
|
|
37
|
-
}[];
|
|
38
|
-
rosterTypeOptions: RadioOption[];
|
|
39
|
-
settingOptions: CheckboxOption[];
|
|
40
|
-
officerRolesOptions: CheckboxOption[];
|
|
41
|
-
memberLevelOptions: CheckboxOption[];
|
|
42
|
-
allowedSubGroupTypesOptions: CheckboxOption[];
|
|
43
|
-
allowedSubGroupTypesFieldConfig: FieldConfig;
|
|
44
|
-
appId: string;
|
|
45
|
-
groupTypeDetails: ViewGroupTypeResponse;
|
|
46
|
-
selectedGroupTypeInfo: CreatedOrModifiedGroupTypeInfo;
|
|
47
|
-
dynamicFormComponent: DynamicFormComponent;
|
|
48
|
-
dynamicFormComponentViewRef: ViewContainerRef;
|
|
49
|
-
componentRef: ComponentRef<any>;
|
|
50
|
-
/**
|
|
51
|
-
* Event emitter for form submission response.
|
|
52
|
-
* @memberof CreateModifyGroupTypeComponent
|
|
53
|
-
*/
|
|
54
|
-
submitFormResponse: EventEmitter<any>;
|
|
55
|
-
/**
|
|
56
|
-
* Event emitter for form cancel action.
|
|
57
|
-
* @memberof CreateModifyGroupTypeComponent
|
|
58
|
-
*/
|
|
59
|
-
formCancel: EventEmitter<any>;
|
|
60
|
-
constructor(tenantAppService: TenantApplicationsService, sharedService: SharedService, renderer: Renderer2, elementRef: ElementRef, formUtilityService: FormUtilityService);
|
|
61
|
-
/**
|
|
62
|
-
* Sets appId, tenantFunctionType and calls getGroupTypes() & getRosterTypes() to get group and roster types.
|
|
63
|
-
* @memberof CreateModifyGroupTypeComponent
|
|
64
|
-
*/
|
|
65
|
-
ngOnInit(): void;
|
|
66
|
-
/**
|
|
67
|
-
* Gets the list of roster types and updates the form control.
|
|
68
|
-
* @memberof CreateModifyGroupTypeComponent
|
|
69
|
-
*/
|
|
70
|
-
getRosterTypes(): void;
|
|
71
|
-
/**
|
|
72
|
-
* Gets the list of settings and updates the form control.
|
|
73
|
-
* @memberof CreateModifyGroupTypeComponent
|
|
74
|
-
*/
|
|
75
|
-
getSettings(): void;
|
|
76
|
-
/**
|
|
77
|
-
* Gets the list of roles and updates the form control.
|
|
78
|
-
* @memberof CreateModifyGroupTypeComponent
|
|
79
|
-
*/
|
|
80
|
-
getRoles(): void;
|
|
81
|
-
/**
|
|
82
|
-
* Gets and filters non SYSTEM_USER group types, constructs allowed sub-group types options and form field config.
|
|
83
|
-
* @memberof CreateModifyGroupTypeComponent
|
|
84
|
-
*/
|
|
85
|
-
getGroupTypes(): void;
|
|
86
|
-
/**
|
|
87
|
-
* Initialize the create/edit group type form group array.
|
|
88
|
-
* @param {*} [formValue]
|
|
89
|
-
* @memberof CreateModifyGroupTypeComponent
|
|
90
|
-
*/
|
|
91
|
-
initializeCreateGroupTypeFormGroup(): void;
|
|
92
|
-
/**
|
|
93
|
-
* Add or removes allowed sub groups form control (checkbox group control and options) as when allow sub group selection and updates the form state.
|
|
94
|
-
* @param {*} selectedCheckbox
|
|
95
|
-
* @memberof CreateModifyGroupTypeComponent
|
|
96
|
-
*/
|
|
97
|
-
onCheckboxSelectionChange(selectedCheckbox: CheckboxOption): void;
|
|
98
|
-
/**
|
|
99
|
-
* Sets create/modify group type reactive form group reference.
|
|
100
|
-
* @param {FormGroup[]} form -The form group array containing the form to be referenced.
|
|
101
|
-
* @memberof CreateModifyGroupTypeComponent
|
|
102
|
-
*/
|
|
103
|
-
getCreateModifyGroupTypeFormGroupRef(form: FormGroup[]): void;
|
|
104
|
-
/**
|
|
105
|
-
* Find the provided setting name in setting option and return the boolean value.
|
|
106
|
-
* @param {string} settingName
|
|
107
|
-
* @return {*} {boolean}
|
|
108
|
-
* @memberof CreateModifyGroupTypeComponent
|
|
109
|
-
*/
|
|
110
|
-
isSettingSelectedByName(settingName: string): boolean;
|
|
111
|
-
/**
|
|
112
|
-
* Creates a new group type on form submission and the form is valid.
|
|
113
|
-
* @param {FormGroup[]} form
|
|
114
|
-
* @memberof CreateModifyGroupTypeComponent
|
|
115
|
-
*/
|
|
116
|
-
onCreateModifyGroupTypeFormSubmit(form: FormGroup[]): void;
|
|
117
|
-
/**
|
|
118
|
-
* Emits form cancel event.
|
|
119
|
-
* @memberof CreateModifyGroupTypeComponent
|
|
120
|
-
*/
|
|
121
|
-
onFormCancel(): void;
|
|
122
|
-
/**
|
|
123
|
-
* Implementation of ngOnDestroy lifecycle hook method to unsubscribe the open observable subscriptions.
|
|
124
|
-
* @memberof CreateModifyGroupTypeComponent
|
|
125
|
-
*/
|
|
126
|
-
ngOnDestroy(): void;
|
|
127
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<CreateModifyGroupTypeComponent, never>;
|
|
128
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<CreateModifyGroupTypeComponent, "ieeesa-create-modify-group-type", never, {}, { "submitFormResponse": "submitFormResponse"; "formCancel": "formCancel"; }, never, never, true, never>;
|
|
129
|
-
}
|
|
@@ -1,103 +0,0 @@
|
|
|
1
|
-
import { EventEmitter, OnDestroy, OnInit } from '@angular/core';
|
|
2
|
-
import { Subject } from 'rxjs';
|
|
3
|
-
import { FormGroup } from '@angular/forms';
|
|
4
|
-
import { AlignType, DynamicFormComponent, FieldConfig, FormGrid, FormModel, SelectOption } from '@ieeesa-npm/presentation';
|
|
5
|
-
import { TenantApplicationsService } from '../../services/tenant-applications.service';
|
|
6
|
-
import { SharedService } from '@ieeesa-npm/shared';
|
|
7
|
-
import { TenantFunctionType } from '../../models/tenant-function-type.model';
|
|
8
|
-
import { TenantBasicInfo } from '../../models/tenant.model';
|
|
9
|
-
import { RoleDetails, Role, CreateModifyRoleRequestPayload } from '../../models/roles-and-permissions.model';
|
|
10
|
-
import { GlobalErrorHandlerService } from '@ieeesa-npm/utility';
|
|
11
|
-
import * as i0 from "@angular/core";
|
|
12
|
-
export declare class CreateModifyRoleComponent implements OnInit, OnDestroy {
|
|
13
|
-
private tenantAppService;
|
|
14
|
-
private sharedService;
|
|
15
|
-
private globalErrorHandlerService;
|
|
16
|
-
destroy$: Subject<boolean>;
|
|
17
|
-
constants: any;
|
|
18
|
-
createRoleTexts: any;
|
|
19
|
-
leftButtonLabel: any;
|
|
20
|
-
rightButtonLabel: any;
|
|
21
|
-
colWidth: FormGrid;
|
|
22
|
-
createRoleFormGroup: FormModel;
|
|
23
|
-
createModifyRoleFormGroupRef: FormGroup;
|
|
24
|
-
actionButtonAlign: AlignType;
|
|
25
|
-
dynamicFormComponent: DynamicFormComponent;
|
|
26
|
-
submitFormResponse: EventEmitter<any>;
|
|
27
|
-
formCancel: EventEmitter<any>;
|
|
28
|
-
tenantFunctionType: TenantFunctionType;
|
|
29
|
-
selectedTenantInfo: TenantBasicInfo | undefined;
|
|
30
|
-
createModifyRolePayload: CreateModifyRoleRequestPayload;
|
|
31
|
-
roleTypeOptions: SelectOption[];
|
|
32
|
-
selectedRoleDetails: RoleDetails;
|
|
33
|
-
selectedRole: Role;
|
|
34
|
-
constructor(tenantAppService: TenantApplicationsService, sharedService: SharedService, globalErrorHandlerService: GlobalErrorHandlerService);
|
|
35
|
-
ngOnInit(): void;
|
|
36
|
-
/**
|
|
37
|
-
* Constructs and returns the role type form field based on credit or edit role.
|
|
38
|
-
* @return {FieldConfig} -role type form field.
|
|
39
|
-
* @memberof CreateModifyRoleComponent
|
|
40
|
-
*/
|
|
41
|
-
getRoleTypeField(): FieldConfig;
|
|
42
|
-
/**
|
|
43
|
-
* Initialize the create/edit role form group array.
|
|
44
|
-
* @memberof CreateModifyRoleComponent
|
|
45
|
-
*/
|
|
46
|
-
initializeCreateRoleFormGroup(): void;
|
|
47
|
-
/**
|
|
48
|
-
* Gets create/edit role form group reference.
|
|
49
|
-
* @param {FormGroup[]} form
|
|
50
|
-
* @memberof CreateModifyRoleComponent
|
|
51
|
-
*/
|
|
52
|
-
getCreateModifyRoleFormGroupRef(form: FormGroup[]): void;
|
|
53
|
-
/**
|
|
54
|
-
* Updates createModifyRoleFormGroupRef on add role form change event.
|
|
55
|
-
* @param {FormGroup[]} form
|
|
56
|
-
* @memberof CreateModifyRoleComponent
|
|
57
|
-
*/
|
|
58
|
-
onCreateModifyRoleFormChange(form: FormGroup[]): void;
|
|
59
|
-
/**
|
|
60
|
-
* Creates a new role on form submission and the form is valid.
|
|
61
|
-
* @param {FormGroup[]} form
|
|
62
|
-
* @memberof CreateModifyRoleComponent
|
|
63
|
-
*/
|
|
64
|
-
onCreateModifyRoleFormSubmit(form: FormGroup[]): void;
|
|
65
|
-
/**
|
|
66
|
-
* Constructs create/edit role payload from the form data and returns.
|
|
67
|
-
* @param {*} formData
|
|
68
|
-
* @return {CreateModifyRoleRequestPayload}
|
|
69
|
-
* @memberof CreateModifyRoleComponent
|
|
70
|
-
*/
|
|
71
|
-
getCreateModifyRolePayload(formData: any): CreateModifyRoleRequestPayload;
|
|
72
|
-
/**
|
|
73
|
-
* Post the creates new role form data to the server on form submission to create a new role.
|
|
74
|
-
* @param {CreateRoleRequestPayload} createModifyRolePayload
|
|
75
|
-
* @memberof CreateModifyRoleComponent
|
|
76
|
-
*/
|
|
77
|
-
createRole(): void;
|
|
78
|
-
/**
|
|
79
|
-
* Post the edited role form data to server on form submission to update the selected role information.
|
|
80
|
-
* @param {CreateModifyRoleRequestPayload} createModifyRolePayload
|
|
81
|
-
* @memberof CreateModifyRoleComponent
|
|
82
|
-
*/
|
|
83
|
-
editRole(): void;
|
|
84
|
-
/**
|
|
85
|
-
* Captures the server side errors and handles it based on the custom or Http errors.
|
|
86
|
-
* @param {HttpErrorResponse} error
|
|
87
|
-
* @return -returns nothing
|
|
88
|
-
* @memberof CreateModifyRoleComponent
|
|
89
|
-
*/
|
|
90
|
-
handleErrors(error: any): void;
|
|
91
|
-
/**
|
|
92
|
-
* Emits form cancel event.
|
|
93
|
-
* @memberof CreateModifyRoleComponent
|
|
94
|
-
*/
|
|
95
|
-
onFormCancel(): void;
|
|
96
|
-
/**
|
|
97
|
-
* Implementation of ngOnDestroy lifecycle hook method to unsubscribe the open observable subscriptions.
|
|
98
|
-
* @memberof CreateModifyRoleComponent
|
|
99
|
-
*/
|
|
100
|
-
ngOnDestroy(): void;
|
|
101
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<CreateModifyRoleComponent, never>;
|
|
102
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<CreateModifyRoleComponent, "ieeesa-create-modify-role", never, {}, { "submitFormResponse": "submitFormResponse"; "formCancel": "formCancel"; }, never, never, true, never>;
|
|
103
|
-
}
|
|
@@ -1,128 +0,0 @@
|
|
|
1
|
-
import { EventEmitter, OnDestroy, OnInit } from '@angular/core';
|
|
2
|
-
import { AlignType, CheckboxOption, FormGrid, AllowedFileTypes, RadioOption, DynamicFormComponent, FormModel, FileUploadService } from '@ieeesa-npm/presentation';
|
|
3
|
-
import { Subject } from 'rxjs';
|
|
4
|
-
import { FormGroup } from '@angular/forms';
|
|
5
|
-
import { TenantApplicationsService } from '../../services/tenant-applications.service';
|
|
6
|
-
import { CreateTenantRequestPayload, NewTenantInfo, TenantBasicInfo } from '../../models/tenant.model';
|
|
7
|
-
import { SharedService } from '@ieeesa-npm/shared';
|
|
8
|
-
import { TenantFunctionType } from '../../models/tenant-function-type.model';
|
|
9
|
-
import * as i0 from "@angular/core";
|
|
10
|
-
export declare class CreateTenantApplicationComponent implements OnInit, OnDestroy {
|
|
11
|
-
fileUploadService: FileUploadService;
|
|
12
|
-
private tenantAppService;
|
|
13
|
-
private sharedService;
|
|
14
|
-
destroy$: Subject<boolean>;
|
|
15
|
-
constants: any;
|
|
16
|
-
createTenantTexts: any;
|
|
17
|
-
leftButtonLabel: any;
|
|
18
|
-
rightButtonLabel: any;
|
|
19
|
-
colWidth: FormGrid;
|
|
20
|
-
createTenantFormGroup: FormModel;
|
|
21
|
-
actionButtonAlign: AlignType;
|
|
22
|
-
createTenantFormGroupRef: FormGroup;
|
|
23
|
-
dynamicFormComponent: DynamicFormComponent;
|
|
24
|
-
submitFormResponse: EventEmitter<any>;
|
|
25
|
-
formCancel: EventEmitter<any>;
|
|
26
|
-
featuresOptions: CheckboxOption[];
|
|
27
|
-
appTypeOptions: RadioOption[];
|
|
28
|
-
createTenantPayload: CreateTenantRequestPayload;
|
|
29
|
-
fileUploadPresignedUrl: string;
|
|
30
|
-
fileDownloadPresignedUrl: string;
|
|
31
|
-
file: File | FileList;
|
|
32
|
-
allowedFileTypes: AllowedFileTypes[];
|
|
33
|
-
selectedColor: string;
|
|
34
|
-
selectedAppTypeOption: RadioOption;
|
|
35
|
-
tenantFunctionType: TenantFunctionType;
|
|
36
|
-
selectedTenantInfo: TenantBasicInfo | undefined;
|
|
37
|
-
isAppLogoModified: boolean;
|
|
38
|
-
updatedTenantBasicInfo: NewTenantInfo;
|
|
39
|
-
constructor(fileUploadService: FileUploadService, tenantAppService: TenantApplicationsService, sharedService: SharedService);
|
|
40
|
-
ngOnInit(): void;
|
|
41
|
-
/**
|
|
42
|
-
* Gets the list of features and updates the form control.
|
|
43
|
-
* @memberof CreateTenantApplicationComponent
|
|
44
|
-
*/
|
|
45
|
-
getFeatures(): void;
|
|
46
|
-
/**
|
|
47
|
-
* Gets the application/tenant types and updates the form control.
|
|
48
|
-
* @memberof CreateTenantApplicationComponent
|
|
49
|
-
*/
|
|
50
|
-
getApplicationTypes(): void;
|
|
51
|
-
/**
|
|
52
|
-
* Initialize the create tenant form group array.
|
|
53
|
-
* @memberof CreateTenantApplicationComponent
|
|
54
|
-
*/
|
|
55
|
-
initializeCreateTenantFormGroup(): void;
|
|
56
|
-
/**
|
|
57
|
-
* Creates Payload and gets presigned url for file upload on form submission.
|
|
58
|
-
* @param {FormGroup[]} form
|
|
59
|
-
* @memberof CreateTenantApplicationComponent
|
|
60
|
-
*/
|
|
61
|
-
onCreateTenantFormSubmit(form: FormGroup[]): void;
|
|
62
|
-
/**
|
|
63
|
-
* Creates a new tenant on form submission.
|
|
64
|
-
* @memberof CreateTenantApplicationComponent
|
|
65
|
-
*/
|
|
66
|
-
createTenant(): void;
|
|
67
|
-
/**
|
|
68
|
-
* Updates the modified tenant information on form submission.
|
|
69
|
-
* @memberof CreateTenantApplicationComponent
|
|
70
|
-
*/
|
|
71
|
-
editTenant(): void;
|
|
72
|
-
/**
|
|
73
|
-
* Constructs create tenant payload from the form data and returns.
|
|
74
|
-
* @param {*} formData
|
|
75
|
-
* @return {CreateTenantRequestPayload}
|
|
76
|
-
* @memberof CreateTenantApplicationComponent
|
|
77
|
-
*/
|
|
78
|
-
getCreateTenantPayload(formData: any): CreateTenantRequestPayload;
|
|
79
|
-
/**
|
|
80
|
-
* Gets create tenant form group reference and disables default features.
|
|
81
|
-
* @param {FormGroup[]} form
|
|
82
|
-
* @memberof CreateTenantApplicationComponent
|
|
83
|
-
*/
|
|
84
|
-
getCreateTenantFormGroupRef(form: FormGroup[]): void;
|
|
85
|
-
/**
|
|
86
|
-
* Updates createTenantFormGroupRef on add or edit tenant form change event.
|
|
87
|
-
* @param {FormGroup[]} form
|
|
88
|
-
* @memberof CreateTenantApplicationComponent
|
|
89
|
-
*/
|
|
90
|
-
onCreateTenantFormChange(form: FormGroup[]): void;
|
|
91
|
-
/**
|
|
92
|
-
* Emits form cancel event.
|
|
93
|
-
* @memberof CreateTenantApplicationComponent
|
|
94
|
-
*/
|
|
95
|
-
onFormCancel(): void;
|
|
96
|
-
/**
|
|
97
|
-
* Gets the selected file when the file is browsed and on formFileUpload event is triggered.
|
|
98
|
-
* @param {File | FileList} file
|
|
99
|
-
*/
|
|
100
|
-
onFormFileUpload(file: File | FileList): void;
|
|
101
|
-
/**
|
|
102
|
-
* Gets pre-signed URL to upload the selected file to AWS S3 bucket.
|
|
103
|
-
* @param {File | FileList} file
|
|
104
|
-
*/
|
|
105
|
-
getFileUploadPresignedUrl(file: File | FileList, appId: string): void;
|
|
106
|
-
/**
|
|
107
|
-
* Uploads the file to AWS S3 bucket and submit the form data to API to create new tenant.
|
|
108
|
-
* @param {File | FileList} file
|
|
109
|
-
*/
|
|
110
|
-
uploadFileToS3(file: File | FileList): void;
|
|
111
|
-
/**
|
|
112
|
-
* Triggers when the color picker values has been changed.
|
|
113
|
-
* @param {string} color
|
|
114
|
-
*/
|
|
115
|
-
onColorPickerChange(color: string): void;
|
|
116
|
-
/**
|
|
117
|
-
* Triggers when the radio option has been changed.
|
|
118
|
-
* @param {RadioOption} radioOption
|
|
119
|
-
*/
|
|
120
|
-
onRadioOptionSelected(radioOption: RadioOption): void;
|
|
121
|
-
/**
|
|
122
|
-
* Implementation of ngOnDestroy lifecycle hook method to unsubscribe the open observable subscriptions.
|
|
123
|
-
* @memberof CreateTenantApplicationComponent
|
|
124
|
-
*/
|
|
125
|
-
ngOnDestroy(): void;
|
|
126
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<CreateTenantApplicationComponent, never>;
|
|
127
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<CreateTenantApplicationComponent, "ieeesa-create-tenant-application", never, {}, { "submitFormResponse": "submitFormResponse"; "formCancel": "formCancel"; }, never, never, true, never>;
|
|
128
|
-
}
|
package/lib/components/roles-and-permissions-mapping/roles-and-permissions-mapping.component.d.ts
DELETED
|
@@ -1,106 +0,0 @@
|
|
|
1
|
-
import { ElementRef, EventEmitter, OnDestroy, OnInit } from '@angular/core';
|
|
2
|
-
import { FormGroup } from '@angular/forms';
|
|
3
|
-
import { Subject } from 'rxjs';
|
|
4
|
-
import { AlignType, FormGrid, FormModel, SelectOption, SlideToggleOption, DynamicFormComponent, TableColumnSchema } from '@ieeesa-npm/presentation';
|
|
5
|
-
import { TenantApplicationsService } from '../../services/tenant-applications.service';
|
|
6
|
-
import { Permission, ModifiedRolesAndPermissionsMapping, RoleDetails, RoleOrPermissionMapping, RolePermissionMappingRequestPayload } from '../../models/roles-and-permissions.model';
|
|
7
|
-
import { RoleAndPermissionsTableType } from '../../models/roles-and-permissions-table-type.model';
|
|
8
|
-
import { FormUtilityService, SharedService } from '@ieeesa-npm/shared';
|
|
9
|
-
import * as i0 from "@angular/core";
|
|
10
|
-
export declare class RolesAndPermissionsMappingComponent implements OnInit, OnDestroy {
|
|
11
|
-
private tenantAppService;
|
|
12
|
-
private sharedService;
|
|
13
|
-
elementRef: ElementRef;
|
|
14
|
-
private formUtilityService;
|
|
15
|
-
constants: any;
|
|
16
|
-
mapRolesAndPermissionsScreenTexts: any;
|
|
17
|
-
formGroup: FormModel;
|
|
18
|
-
colWidth: FormGrid;
|
|
19
|
-
actionButtonAlign: AlignType;
|
|
20
|
-
leftButtonLabel: any;
|
|
21
|
-
rightButtonLabel: any;
|
|
22
|
-
roles: SelectOption[];
|
|
23
|
-
permissions: SelectOption[];
|
|
24
|
-
appId: string;
|
|
25
|
-
destroy$: Subject<boolean>;
|
|
26
|
-
tableColumnSchema: TableColumnSchema[];
|
|
27
|
-
tableData: RoleOrPermissionMapping[];
|
|
28
|
-
selectedRole: RoleDetails;
|
|
29
|
-
selectedPermission: Permission;
|
|
30
|
-
modifiedRolesAndPermissionsMapping: ModifiedRolesAndPermissionsMapping[];
|
|
31
|
-
tableHeading: string;
|
|
32
|
-
rolePermissionMappingPayload: RolePermissionMappingRequestPayload;
|
|
33
|
-
formCancel: EventEmitter<any>;
|
|
34
|
-
dynamicFormComponent: DynamicFormComponent;
|
|
35
|
-
constructor(tenantAppService: TenantApplicationsService, sharedService: SharedService, elementRef: ElementRef, formUtilityService: FormUtilityService);
|
|
36
|
-
/**
|
|
37
|
-
* Initializes form group and all the page defaults.
|
|
38
|
-
* @memberof MapPermissionsRolesComponent
|
|
39
|
-
* @returns {void}
|
|
40
|
-
*/
|
|
41
|
-
ngOnInit(): void;
|
|
42
|
-
/**
|
|
43
|
-
* Constructs the role or permission table schema to display the associated mapping in a table view.
|
|
44
|
-
* @param {FormGroup[]} formGroups
|
|
45
|
-
* @memberof MapPermissionsRolesComponent
|
|
46
|
-
* @returns {void}
|
|
47
|
-
*/
|
|
48
|
-
onRoleOrPermissionSelected(formGroups: FormGroup[]): void;
|
|
49
|
-
/**
|
|
50
|
-
* Gets the list of roles and displayed in the role dropdown.
|
|
51
|
-
* @memberof MapPermissionsRolesComponent
|
|
52
|
-
* @returns {void}
|
|
53
|
-
*/
|
|
54
|
-
getRoles(): void;
|
|
55
|
-
/**
|
|
56
|
-
* Gets the list of permissions and displayed in the permission dropdown.
|
|
57
|
-
* @memberof MapPermissionsRolesComponent
|
|
58
|
-
* @returns {void}
|
|
59
|
-
*/
|
|
60
|
-
getPermissions(): void;
|
|
61
|
-
/**
|
|
62
|
-
* Gets the list of mapped roles/permissions from the backend api.
|
|
63
|
-
* @param {RolePermissionMappingRequestPayload} payload
|
|
64
|
-
* @memberof MapPermissionsRolesComponent
|
|
65
|
-
* @returns {void}
|
|
66
|
-
*/
|
|
67
|
-
getRolePermissionMapping(payload: RolePermissionMappingRequestPayload): void;
|
|
68
|
-
/**
|
|
69
|
-
* Displaying the mapped roles and permissions data into the data table.
|
|
70
|
-
* @param {SelectOption[]} roleOrPermissions
|
|
71
|
-
* @param {RoleDetails[] | Permission[]} mappedRoleOrPermissions
|
|
72
|
-
* @param {RoleAndPermissionsTableType} tableType
|
|
73
|
-
* @memberof MapPermissionsRolesComponent
|
|
74
|
-
* @returns {void}
|
|
75
|
-
*/
|
|
76
|
-
setTableData(roleOrPermissions: SelectOption[], mappedRoleOrPermissions: RoleDetails[] | Permission[], tableType: RoleAndPermissionsTableType): void;
|
|
77
|
-
/**
|
|
78
|
-
* Constructs the payload based on the roles and permissions mapping (selection or deselection).
|
|
79
|
-
* @param roleOrPermissionStatus
|
|
80
|
-
* @memberof MapPermissionsRolesComponent
|
|
81
|
-
* @returns {void}
|
|
82
|
-
*/
|
|
83
|
-
roleOrPermissionStatusChange(roleOrPermissionStatus: {
|
|
84
|
-
slideToggle: SlideToggleOption;
|
|
85
|
-
rowData: RoleOrPermissionMapping;
|
|
86
|
-
}): void;
|
|
87
|
-
/**
|
|
88
|
-
* Submits the roles and permissions mappings to the server.
|
|
89
|
-
* @memberof MapPermissionsRolesComponent
|
|
90
|
-
* @returns {void}
|
|
91
|
-
*/
|
|
92
|
-
onMapAndPermissionsFormSubmit(): void;
|
|
93
|
-
/**
|
|
94
|
-
* Closes the map and permissions modal.
|
|
95
|
-
* @memberof MapPermissionsRolesComponent
|
|
96
|
-
* @returns {void}
|
|
97
|
-
*/
|
|
98
|
-
onMapAndPermissionsFormCancel(): void;
|
|
99
|
-
/**
|
|
100
|
-
* Performs necessary cleanup tasks, such as unsubscribing from subscription when the component is being destroyed.
|
|
101
|
-
* @memberof ViewTenantDetailsComponent
|
|
102
|
-
*/
|
|
103
|
-
ngOnDestroy(): void;
|
|
104
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<RolesAndPermissionsMappingComponent, never>;
|
|
105
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<RolesAndPermissionsMappingComponent, "ieeesa-roles-and-permissions-mapping", never, {}, { "formCancel": "formCancel"; }, never, never, true, never>;
|
|
106
|
-
}
|