Commit d66605fc authored by Florent Poittevin's avatar Florent Poittevin
Browse files

PROTO William-ngxs-memoized-solution

parent 3fc2db54
......@@ -38,7 +38,7 @@ export interface AdminUserStateModel extends ResourceStateModel<UserExtended> {
},
})
export class AdminUserState extends ResourceState<UserExtended> {
export class AdminUserState extends ResourceState<AdminUserStateModel, UserExtended> {
constructor(protected apiService: ApiService,
protected store: Store,
protected notificationService: NotificationService,
......
......@@ -73,7 +73,7 @@ export interface DepositDataFileStateModel extends CompositionStateModel<Deposit
DepositDataFileStatusHistoryState,
],
})
export class DepositDataFileState extends CompositionState<DepositDataFile> {
export class DepositDataFileState extends CompositionState<DepositDataFileStateModel, DepositDataFile> {
constructor(protected apiService: ApiService,
protected store: Store,
protected notificationService: NotificationService,
......
......@@ -27,7 +27,7 @@ export interface DepositDataFileStatusHistoryStateModel extends StatusHistorySta
...defaultStatusHistoryInitValue(),
},
})
export class DepositDataFileStatusHistoryState extends StatusHistoryState<DepositDataFile> {
export class DepositDataFileStatusHistoryState extends StatusHistoryState<DepositDataFileStatusHistoryStateModel, DepositDataFile> {
constructor(protected apiService: ApiService,
protected store: Store,
......
......@@ -103,7 +103,7 @@ export interface DepositStateModel extends ResourceStateModel<DepositExtended> {
DepositStatusHistoryState,
],
})
export class DepositState extends ResourceState<DepositExtended> {
export class DepositState extends ResourceState<DepositStateModel, DepositExtended> {
private readonly _FILE_KEY: string = "file";
private readonly _CATEGORY_KEY: string = "category";
private readonly _TYPE_KEY: string = "type";
......
......@@ -26,7 +26,7 @@ export interface DepositPersonStateModel extends AssociationRemoteStateModel<Per
...defaultAssociationRemoteStateInitValue(),
},
})
export class DepositPeopleState extends AssociationRemoteState<Person> {
export class DepositPeopleState extends AssociationRemoteState<DepositPersonStateModel, Person> {
constructor(protected apiService: ApiService,
protected store: Store,
......
......@@ -27,7 +27,7 @@ export interface DepositStatusHistoryStateModel extends StatusHistoryStateModel<
...defaultStatusHistoryInitValue(),
},
})
export class DepositStatusHistoryState extends StatusHistoryState<DepositExtended> {
export class DepositStatusHistoryState extends StatusHistoryState<DepositStatusHistoryStateModel, DepositExtended> {
constructor(protected apiService: ApiService,
protected store: Store,
......
......@@ -39,7 +39,7 @@ export interface HomeOrganizationalUnitArchiveStateModel extends AssociationNoSq
...defaultAssociationNoSqlReadOnlyStateInitValue(),
},
})
export class HomeOrganizationalUnitArchiveState extends AssociationNoSqlReadOnlyState<ArchiveMetadata> {
export class HomeOrganizationalUnitArchiveState extends AssociationNoSqlReadOnlyState<HomeOrganizationalUnitArchiveStateModel, ArchiveMetadata> {
constructor(protected apiService: ApiService,
protected store: Store,
......
......@@ -50,7 +50,7 @@ export interface HomeOrganizationalUnitStateModel extends ResourceStateModel<Acc
HomeOrganizationalUnitArchiveState,
],
})
export class HomeOrganizationalUnitState extends ResourceState<AccessOrganizationalUnit> {
export class HomeOrganizationalUnitState extends ResourceState<HomeOrganizationalUnitStateModel, AccessOrganizationalUnit> {
private readonly DEFAULT_SEARCH: string = "";
......
......@@ -63,7 +63,7 @@ export interface OrganizationalUnitStateModel extends ResourceStateModel<Organiz
OrganizationalUnitPersonRoleState,
],
})
export class OrganizationalUnitState extends ResourceState<OrganizationalUnitExtended> {
export class OrganizationalUnitState extends ResourceState<OrganizationalUnitStateModel, OrganizationalUnitExtended> {
constructor(protected apiService: ApiService,
protected store: Store,
......
......@@ -29,7 +29,7 @@ export interface OrganizationalUnitPersonRoleStateModel extends Relation3TiersSt
},
})
// OrganizationalUnitPersonController
export class OrganizationalUnitPersonRoleState extends Relation3TiersState<PersonRole, OrganizationalUnitPersonRole> {
export class OrganizationalUnitPersonRoleState extends Relation3TiersState<OrganizationalUnitPersonRoleStateModel, PersonRole, OrganizationalUnitPersonRole> {
constructor(protected apiService: ApiService,
protected store: Store,
protected notificationService: NotificationService,
......
......@@ -19,5 +19,5 @@ export interface DataTableColumns<T = any> {
filterableField?: keyof T & string;
sortableField?: keyof T & string;
resourceNameSpace?: ResourceNameSpace;
resourceState?: ResourceState<any>;
resourceState?: ResourceState<any, any>;
}
......@@ -33,7 +33,7 @@ export const defaultDlcmResourceStateInitValue: DlcmResourceStateModel<BaseResou
};
// @dynamic
export abstract class DlcmResourceState<TResource extends BaseResourceType> extends ResourceState<TResource> {
export abstract class DlcmResourceState<TResource extends BaseResourceType> extends ResourceState<BaseResourceType, TResource> {
protected readonly _nameSpace: DlcmResourceNameSpace;
protected constructor(protected apiService: ApiService,
......
......@@ -27,7 +27,7 @@ export interface SharedFundingAgencyStateModel extends ResourceStateModel<Fundin
queryParameters: new QueryParameters(environment.defaultEnumValuePageSizeOption),
},
})
export class SharedFundingAgencyState extends ResourceState<FundingAgency> {
export class SharedFundingAgencyState extends ResourceState<SharedFundingAgencyStateModel, FundingAgency> {
constructor(protected apiService: ApiService,
protected store: Store,
protected notificationService: NotificationService,
......
......@@ -27,7 +27,7 @@ export interface SharedInstitutionStateModel extends ResourceStateModel<Institut
queryParameters: new QueryParameters(environment.defaultEnumValuePageSizeOption),
},
})
export class SharedInstitutionState extends ResourceState<Institution> {
export class SharedInstitutionState extends ResourceState<SharedInstitutionStateModel, Institution> {
constructor(protected apiService: ApiService,
protected store: Store,
protected notificationService: NotificationService,
......
......@@ -27,7 +27,7 @@ export interface SharedLanguageStateModel extends ResourceStateModel<Language> {
queryParameters: new QueryParameters(environment.defaultEnumValuePageSizeOption),
},
})
export class SharedLanguageState extends ResourceState<Language> {
export class SharedLanguageState extends ResourceState<SharedLanguageStateModel, Language> {
constructor(protected apiService: ApiService,
protected store: Store,
protected notificationService: NotificationService,
......
......@@ -29,7 +29,7 @@ export interface SharedLicenseStateModel extends ResourceStateModel<License> {
queryParameters: new QueryParameters(environment.defaultEnumValuePageSizeOption),
},
})
export class SharedLicenseState extends ResourceState<License> {
export class SharedLicenseState extends ResourceState<SharedLicenseStateModel, License> {
constructor(protected apiService: ApiService,
protected store: Store,
protected notificationService: NotificationService,
......
......@@ -33,7 +33,7 @@ export interface SharedOrganizationalUnitPreservationPolicyStateModel extends Re
...defaultRelation2TiersStateInitValue(),
},
})
export class SharedOrganizationalUnitPreservationPolicyState extends Relation2TiersState<PreservationPolicy, OrganizationalUnitPreservationPolicy> {
export class SharedOrganizationalUnitPreservationPolicyState extends Relation2TiersState<SharedOrganizationalUnitPreservationPolicyStateModel, PreservationPolicy, OrganizationalUnitPreservationPolicy> {
constructor(protected apiService: ApiService,
protected store: Store,
protected notificationService: NotificationService,
......
......@@ -44,7 +44,7 @@ export interface SharedOrganizationalUnitStateModel extends ResourceStateModel<O
SharedOrganizationalUnitSubmissionPolicyState,
],
})
export class SharedOrganizationalUnitState extends ResourceState<OrganizationalUnitExtended> {
export class SharedOrganizationalUnitState extends ResourceState<SharedOrganizationalUnitStateModel, OrganizationalUnitExtended> {
constructor(protected apiService: ApiService,
protected store: Store,
......
......@@ -32,7 +32,7 @@ export interface SharedOrganizationalUnitSubmissionPolicyStateModel extends Rela
...defaultRelation2TiersStateInitValue(),
},
})
export class SharedOrganizationalUnitSubmissionPolicyState extends Relation2TiersState<SubmissionPolicy, OrganizationalUnitSubmissionPolicy> {
export class SharedOrganizationalUnitSubmissionPolicyState extends Relation2TiersState<SharedOrganizationalUnitSubmissionPolicyStateModel, SubmissionPolicy, OrganizationalUnitSubmissionPolicy> {
constructor(protected apiService: ApiService,
protected store: Store,
protected notificationService: NotificationService,
......
......@@ -55,7 +55,7 @@ export interface SharedPersonStateModel extends ResourceStateModel<PersonExtende
queryParameters: new QueryParameters(environment.defaultEnumValuePageSizeOption),
},
})
export class SharedPersonState extends ResourceState<PersonExtended> {
export class SharedPersonState extends ResourceState<SharedPersonStateModel, PersonExtended> {
constructor(protected apiService: ApiService,
protected store: Store,
protected notificationService: NotificationService,
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment