|
1 |
| -import { RequestOptions, URLSearchParams, RequestMethod } from '@angular/http'; |
| 1 | +import { RequestMethod, RequestOptions, URLSearchParams } from '@angular/http'; |
2 | 2 |
|
3 |
| -import { CFEntityConfig } from '../../cf-types'; |
4 |
| -import { |
5 |
| - cfEntityFactory, |
6 |
| - cfUserEntityType, |
7 |
| - organizationEntityType, |
8 |
| - spaceEntityType, |
9 |
| -} from '../cf-entity-factory'; |
10 | 3 | import { IUpdateOrganization } from '../../../core/src/core/cf-api.types';
|
11 |
| -import { EntityInlineChildAction, EntityInlineParentAction } from '../entity-relations/entity-relations.types'; |
12 |
| -import { PaginatedAction } from '../../../store/src/types/pagination.types'; |
13 |
| -import { CFStartAction, ICFAction } from '../../../store/src/types/request.types'; |
14 | 4 | import { getActions } from '../../../store/src/actions/action.helper';
|
| 5 | + |
| 6 | +import { PaginatedAction } from '../../../store/src/types/pagination.types'; |
| 7 | +import { ICFAction } from '../../../store/src/types/request.types'; |
| 8 | +import { CFEntityConfig } from '../../cf-types'; |
| 9 | +import { CFStartAction } from './cf-action.types'; |
| 10 | +import { cfEntityFactory, cfUserEntityType, organizationEntityType, spaceEntityType, spaceWithOrgEntityType } from '../cf-entity-factory'; |
15 | 11 | import { createDefaultUserRelations } from './user.actions.helpers';
|
| 12 | +import { EntityInlineParentAction, EntityInlineChildAction } from '../entity-relations/entity-relations.types'; |
16 | 13 |
|
17 | 14 | export const GET_ORGANIZATION = '[Organization] Get one';
|
18 | 15 | export const GET_ORGANIZATION_SUCCESS = '[Organization] Get one success';
|
@@ -57,6 +54,7 @@ export class GetOrganization extends CFStartAction implements ICFAction, EntityI
|
57 | 54 | }
|
58 | 55 |
|
59 | 56 | export class GetAllOrganizationSpaces extends CFStartAction implements PaginatedAction, EntityInlineParentAction, EntityInlineChildAction {
|
| 57 | + public schemaKey: string; |
60 | 58 | constructor(
|
61 | 59 | public paginationKey: string,
|
62 | 60 | public orgGuid: string,
|
@@ -84,6 +82,12 @@ export class GetAllOrganizationSpaces extends CFStartAction implements Paginated
|
84 | 82 | parentEntityConfig = new CFEntityConfig(organizationEntityType);
|
85 | 83 | }
|
86 | 84 |
|
| 85 | +export class GetAllOrganizationSpacesWithOrgs extends GetAllOrganizationSpaces { |
| 86 | + entity = cfEntityFactory(spaceWithOrgEntityType); |
| 87 | + entityType = spaceEntityType; |
| 88 | + schemaKey = spaceWithOrgEntityType; |
| 89 | +} |
| 90 | + |
87 | 91 | export class GetAllOrganizations extends CFStartAction implements PaginatedAction, EntityInlineParentAction {
|
88 | 92 | constructor(
|
89 | 93 | public paginationKey: string,
|
|
0 commit comments