@ieeesa-npm/groups 0.1.8 → 0.2.0

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.
@@ -1,23 +1,27 @@
1
- export interface GroupTypeResponse {
2
- status: boolean;
3
- message: string;
4
- body: {
5
- configFieldName: string;
6
- configFieldValue: {
7
- [key: string]: GroupType;
8
- };
9
- };
1
+ export interface BusinessRule {
2
+ allowSubGroup: boolean;
3
+ allowRoster: boolean;
4
+ rosterType: string;
5
+ allowAlternateVoting: boolean;
6
+ manageRosterInApp: boolean;
7
+ allowedGroupType: string[];
10
8
  }
11
9
  export interface GroupType {
12
10
  name: string;
13
11
  legendColor: string;
14
12
  description: string;
15
- businessRule: {
16
- allowSubGroup: boolean;
17
- allowRoster: boolean;
18
- rosterType: string;
19
- allowAlternateVoting: boolean;
20
- manageRosterInApp: boolean;
21
- allowedGroupType: string[];
22
- };
13
+ businessRule: BusinessRule;
14
+ }
15
+ export interface GroupTypeConfiguration {
16
+ configFieldName: string;
17
+ configFieldId: string;
18
+ configFieldValue: GroupType;
19
+ }
20
+ export interface GroupTypeResponse {
21
+ status: boolean;
22
+ message: string;
23
+ body: GroupTypeConfiguration[];
24
+ }
25
+ export interface GroupTypeConfigValue {
26
+ [key: string]: GroupType;
23
27
  }
@@ -1,6 +1,6 @@
1
1
  import { Observable } from 'rxjs';
2
2
  import { CreateGroupPayload, CreateGroupResponse } from '../models/create-group.model';
3
- import { GroupTypeResponse } from '../models/group-types.model';
3
+ import { GroupTypeConfiguration, GroupTypeConfigValue, GroupTypeResponse } from '../models/group-types.model';
4
4
  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';
@@ -114,6 +114,13 @@ export declare class GroupsService {
114
114
  * @memberof GroupsService
115
115
  */
116
116
  getGroupFunctionType(): GroupFunctionType;
117
+ /**
118
+ * Returns formatted group types.
119
+ * @param {GroupTypeConfiguration[]} groupTypeResponse
120
+ * @return {GroupTypeConfigValue}
121
+ * @memberof GroupsService
122
+ */
123
+ getFormattedGroupTypes(groupTypeResponse: GroupTypeConfiguration[]): GroupTypeConfigValue;
117
124
  static ɵfac: i0.ɵɵFactoryDeclaration<GroupsService, never>;
118
125
  static ɵprov: i0.ɵɵInjectableDeclaration<GroupsService>;
119
126
  }
package/package.json CHANGED
@@ -1,12 +1,12 @@
1
1
  {
2
2
  "name": "@ieeesa-npm/groups",
3
- "version": "0.1.8",
3
+ "version": "0.2.0",
4
4
  "peerDependencies": {
5
5
  "@angular/common": "^16.1.0",
6
6
  "@angular/core": "^16.1.0",
7
- "@ieeesa-npm/presentation": "^0.4.3",
8
- "@ieeesa-npm/shared-styles": "^0.1.0",
9
- "@ieeesa-npm/utility": "^0.3.4"
7
+ "@ieeesa-npm/presentation": "^0.4.4",
8
+ "@ieeesa-npm/shared-styles": "^0.1.1",
9
+ "@ieeesa-npm/utility": "^0.3.5"
10
10
  },
11
11
  "dependencies": {
12
12
  "tslib": "^2.3.0"