ichec-angular-core 0.2.3 → 0.2.5
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/package.json
CHANGED
|
@@ -1,9 +1,8 @@
|
|
|
1
1
|
import { FormGroup, FormControl, FormArray, FormBuilder, AbstractControl } from '@angular/forms';
|
|
2
|
-
import * as rxjs from 'rxjs';
|
|
3
2
|
import { Observable, BehaviorSubject } from 'rxjs';
|
|
4
|
-
import { HttpClient, HttpErrorResponse } from '@angular/common/http';
|
|
3
|
+
import { HttpClient, HttpParams, HttpHeaders, HttpErrorResponse } from '@angular/common/http';
|
|
5
4
|
import * as _angular_core from '@angular/core';
|
|
6
|
-
import { InjectionToken,
|
|
5
|
+
import { InjectionToken, AfterViewInit, OnInit, TemplateRef } from '@angular/core';
|
|
7
6
|
import { CookieService } from 'ngx-cookie-service';
|
|
8
7
|
import * as ichec_angular_core from 'ichec-angular-core';
|
|
9
8
|
import { MatSidenavContent } from '@angular/material/sidenav';
|
|
@@ -281,11 +280,22 @@ interface LeftNavCategory {
|
|
|
281
280
|
|
|
282
281
|
interface RestServiceConfig {
|
|
283
282
|
endpoint_url: string;
|
|
283
|
+
self_url: string;
|
|
284
284
|
auth_type: string;
|
|
285
|
-
|
|
285
|
+
}
|
|
286
|
+
interface IRequestBase {
|
|
287
|
+
headers: HttpHeaders;
|
|
288
|
+
credentials: RequestCredentials;
|
|
289
|
+
params: HttpParams;
|
|
290
|
+
}
|
|
291
|
+
interface IServerManifest {
|
|
292
|
+
login_url: string;
|
|
293
|
+
logout_url: string;
|
|
294
|
+
supports_cors: boolean;
|
|
286
295
|
}
|
|
287
296
|
declare const REST_SERVICE_CONFIG: InjectionToken<RestServiceConfig>;
|
|
288
297
|
declare class RestService<D extends Identifiable, L extends Identifiable = D, C = D, U extends Identifiable = D> {
|
|
298
|
+
manifest: IServerManifest;
|
|
289
299
|
readonly _url: string;
|
|
290
300
|
protected config: RestServiceConfig;
|
|
291
301
|
protected _http: HttpClient;
|
|
@@ -304,10 +314,10 @@ declare class RestService<D extends Identifiable, L extends Identifiable = D, C
|
|
|
304
314
|
putFileStandalone(url: string, file: File): Observable<void>;
|
|
305
315
|
patchItem(item: U, include_keys: string[], exclude_keys: string[]): Observable<D>;
|
|
306
316
|
postItem(item: C): Observable<D>;
|
|
307
|
-
getCsrfCookie(): string;
|
|
308
317
|
private getHeaders;
|
|
309
|
-
protected
|
|
310
|
-
private
|
|
318
|
+
protected get baseUrl(): string;
|
|
319
|
+
private get mediaUrl();
|
|
320
|
+
protected getRequestBase(content_type?: string, params?: HttpParams, file?: string): IRequestBase;
|
|
311
321
|
handleError(error: HttpErrorResponse): Observable<never>;
|
|
312
322
|
}
|
|
313
323
|
|
|
@@ -336,16 +346,16 @@ declare class UserService extends ItemService<IPortalMemberDetail, IPortalMember
|
|
|
336
346
|
readonly _url: string;
|
|
337
347
|
typename: string;
|
|
338
348
|
private permissions;
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
349
|
+
login(next?: string): Observable<IPortalMemberDetail | null>;
|
|
350
|
+
private _getServiceManifest;
|
|
351
|
+
private _getSelf;
|
|
352
|
+
private _login;
|
|
353
|
+
private _do_login_redirect;
|
|
354
|
+
logout(next?: string): void;
|
|
343
355
|
hasAddPermission(feature: string): boolean;
|
|
344
356
|
hasDeletePermission(feature: string): boolean;
|
|
345
357
|
hasEditPermission(feature: string): boolean;
|
|
346
358
|
hasViewPermission(feature: string): boolean;
|
|
347
|
-
logout(): void;
|
|
348
|
-
private onLoginToken;
|
|
349
359
|
private onLoggedIn;
|
|
350
360
|
private parsePermission;
|
|
351
361
|
private processPermissions;
|
|
@@ -356,6 +366,7 @@ declare class UserService extends ItemService<IPortalMemberDetail, IPortalMember
|
|
|
356
366
|
declare class ItemWithUserService<D extends Identifiable, L extends Identifiable = D, C = D, U extends Identifiable = D> extends ItemService<D, L, C, U> {
|
|
357
367
|
protected userService: UserService;
|
|
358
368
|
userItems: BehaviorSubject<L[]>;
|
|
369
|
+
constructor();
|
|
359
370
|
canCreate(): boolean;
|
|
360
371
|
canView(): boolean;
|
|
361
372
|
canEdit(): boolean;
|
|
@@ -442,16 +453,14 @@ declare class MockItemService {
|
|
|
442
453
|
typePlural(): string;
|
|
443
454
|
}
|
|
444
455
|
|
|
445
|
-
declare class TopBarComponent
|
|
456
|
+
declare class TopBarComponent {
|
|
446
457
|
readonly title: _angular_core.InputSignal<string | undefined>;
|
|
447
|
-
|
|
458
|
+
readonly user: _angular_core.InputSignal<ichec_angular_core.IPortalMemberList>;
|
|
448
459
|
private userService;
|
|
449
|
-
private leftNavService;
|
|
450
|
-
ngOnInit(): void;
|
|
451
460
|
onLogout(): void;
|
|
452
|
-
|
|
461
|
+
get initials(): string;
|
|
453
462
|
static ɵfac: _angular_core.ɵɵFactoryDeclaration<TopBarComponent, never>;
|
|
454
|
-
static ɵcmp: _angular_core.ɵɵComponentDeclaration<TopBarComponent, "lib-top-bar", never, { "title": { "alias": "title"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
|
|
463
|
+
static ɵcmp: _angular_core.ɵɵComponentDeclaration<TopBarComponent, "lib-top-bar", never, { "title": { "alias": "title"; "required": false; "isSignal": true; }; "user": { "alias": "user"; "required": true; "isSignal": true; }; }, {}, never, never, true, never>;
|
|
455
464
|
}
|
|
456
465
|
|
|
457
466
|
declare class LeftNavComponent {
|
|
@@ -462,26 +471,6 @@ declare class LeftNavComponent {
|
|
|
462
471
|
static ɵcmp: _angular_core.ɵɵComponentDeclaration<LeftNavComponent, "lib-left-nav", never, {}, {}, never, never, true, never>;
|
|
463
472
|
}
|
|
464
473
|
|
|
465
|
-
interface LoginUser {
|
|
466
|
-
password: string;
|
|
467
|
-
name: string;
|
|
468
|
-
}
|
|
469
|
-
|
|
470
|
-
declare const LOGIN_USER: InjectionToken<LoginUser>;
|
|
471
|
-
declare class LandingComponent implements OnInit {
|
|
472
|
-
loginUser: LoginUser;
|
|
473
|
-
loginError: _angular_core.WritableSignal<string>;
|
|
474
|
-
message: _angular_core.InputSignal<string | undefined>;
|
|
475
|
-
private userService;
|
|
476
|
-
private router;
|
|
477
|
-
ngOnInit(): void;
|
|
478
|
-
login(): rxjs.Subscription;
|
|
479
|
-
onLoginError(error: HttpErrorResponse): void;
|
|
480
|
-
onLoggedIn(): void;
|
|
481
|
-
static ɵfac: _angular_core.ɵɵFactoryDeclaration<LandingComponent, never>;
|
|
482
|
-
static ɵcmp: _angular_core.ɵɵComponentDeclaration<LandingComponent, "lib-landing", never, { "message": { "alias": "message"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
|
|
483
|
-
}
|
|
484
|
-
|
|
485
474
|
declare class FeedbackComponent {
|
|
486
475
|
static ɵfac: _angular_core.ɵɵFactoryDeclaration<FeedbackComponent, never>;
|
|
487
476
|
static ɵcmp: _angular_core.ɵɵComponentDeclaration<FeedbackComponent, "lib-feedback", never, {}, {}, never, never, true, never>;
|
|
@@ -967,5 +956,5 @@ declare class OrganizationEditComponent extends EditView<IOrganizationDetail, IO
|
|
|
967
956
|
static ɵcmp: _angular_core.ɵɵComponentDeclaration<OrganizationEditComponent, "lib-organization-edit", never, {}, {}, never, never, true, never>;
|
|
968
957
|
}
|
|
969
958
|
|
|
970
|
-
export { Address, AddressDetailComponent, AddressEditComponent, AddressForm, AddressService, ApiError, AvatarComponent, BackButtonComponent, DetailHeaderComponent, DetailView, DynamicFormBuilderComponent, DynamicFormComponent, DynamicFormForm, EditView, ErrorCode, FORM_FIELD_CHOICES, FeedbackComponent, FieldType, FileRecord, FileUploadComponent, FormFieldDetailComponent, FormFieldEditComponent, FormFieldValueForm, FormService, Group, GroupComponent, GroupDetailComponent, GroupService, ItemQuery, ItemService, ItemWithUserService,
|
|
971
|
-
export type { IAddressBase, IAddressCreate, IAddressDetail, IAddressForm, IAddressList, ICountry, IDynamicFormForm, IFieldFile, IFileRecord, IForm, IFormCreate, IFormDetail, IFormFieldBase, IFormFieldCreate, IFormFieldDetail, IFormFieldValueBase, IFormFieldValueCreate, IFormFieldValueDetail, IFormFieldValueForm, IFormFieldValueUpdate, IFormGroupBase, IFormGroupCreate, IFormGroupDetail, IFormGroupUpdate, IFormUpdate, IGroupBase, IGroupCreate, IGroupDetail, IGroupList, IItemQuery, IMemberIdentifierBase, IMemberIdentifierCreate, IMemberIdentifierDetail, IOrganizationBase, IOrganizationCreate, IOrganizationDetail, IOrganizationList, IPaginated, IPermission, IPopulatedFormCreate, IPopulatedFormDetail, IPopulatedFormForm, IPopulatedFormUpdate, IPortalMemberBase, IPortalMemberCreate, IPortalMemberDetail, IPortalMemberList, IRestOptions, Identifiable, LeftNavCategory, LeftNavOption, NavGroup, NavOption, OptionAction, OptionActionChoice, RestServiceConfig, Selectable, TableColumn, TypeChoice };
|
|
959
|
+
export { Address, AddressDetailComponent, AddressEditComponent, AddressForm, AddressService, ApiError, AvatarComponent, BackButtonComponent, DetailHeaderComponent, DetailView, DynamicFormBuilderComponent, DynamicFormComponent, DynamicFormForm, EditView, ErrorCode, FORM_FIELD_CHOICES, FeedbackComponent, FieldType, FileRecord, FileUploadComponent, FormFieldDetailComponent, FormFieldEditComponent, FormFieldValueForm, FormService, Group, GroupComponent, GroupDetailComponent, GroupService, ItemQuery, ItemService, ItemWithUserService, LeftNavComponent, LeftNavService, ListTableViewComponent, ListViewComponent, MemberSelectionManager, MockItemService, Organization, OrganizationComponent, OrganizationDetailComponent, OrganizationEditComponent, OrganizationService, Paginated, Permission, PopulatedFormComponent, PopulatedFormForm, PortalMember, REST_SERVICE_CONFIG, ResolvedPermission, RestService, SearchBarComponent, SelectTableComponent, SelectionManager, TopBarComponent, UserComponent, UserDetailComponent, UserEditComponent, UserService, getFieldTypeFromKey };
|
|
960
|
+
export type { IAddressBase, IAddressCreate, IAddressDetail, IAddressForm, IAddressList, ICountry, IDynamicFormForm, IFieldFile, IFileRecord, IForm, IFormCreate, IFormDetail, IFormFieldBase, IFormFieldCreate, IFormFieldDetail, IFormFieldValueBase, IFormFieldValueCreate, IFormFieldValueDetail, IFormFieldValueForm, IFormFieldValueUpdate, IFormGroupBase, IFormGroupCreate, IFormGroupDetail, IFormGroupUpdate, IFormUpdate, IGroupBase, IGroupCreate, IGroupDetail, IGroupList, IItemQuery, IMemberIdentifierBase, IMemberIdentifierCreate, IMemberIdentifierDetail, IOrganizationBase, IOrganizationCreate, IOrganizationDetail, IOrganizationList, IPaginated, IPermission, IPopulatedFormCreate, IPopulatedFormDetail, IPopulatedFormForm, IPopulatedFormUpdate, IPortalMemberBase, IPortalMemberCreate, IPortalMemberDetail, IPortalMemberList, IRestOptions, IServerManifest, Identifiable, LeftNavCategory, LeftNavOption, NavGroup, NavOption, OptionAction, OptionActionChoice, RestServiceConfig, Selectable, TableColumn, TypeChoice };
|