{{ '#LDS#Check the corresponding factor for your One-Time Password to verify.' | translate }}
+
{{ '#LDS#Use either the push notification or the One-Time Password in your OneLogin Protector app to verify.' | translate }}
+
{{ '#LDS#Check your authenticator app for your One-Time Password to verify.' | translate }}
+
+
+
+ {{ '#LDS#Verify' | translate }}
+
+
+
+
+
+
+
+ {{ '#LDS#Verify' | translate }}
+
+
+
+
+
+
+
+
+
diff --git a/imxweb/projects/olg/src/lib/mfa/mfa.component.scss b/imxweb/projects/olg/src/lib/mfa/mfa.component.scss
new file mode 100644
index 000000000..b5bede83b
--- /dev/null
+++ b/imxweb/projects/olg/src/lib/mfa/mfa.component.scss
@@ -0,0 +1,66 @@
+@import '@elemental-ui/core/src/styles/_palette.scss';
+
+:host {
+ overflow: auto;
+
+ ::ng-deep .eui-alert {
+ margin-bottom: 20px;
+ }
+
+ ::ng-deep .mat-card-header-text {
+ margin: 0;
+ }
+
+ ::ng-deep .mat-form-field-wrapper {
+ padding-bottom: 0;
+ }
+}
+
+.imx-info {
+ margin-bottom: 20px;
+}
+
+.auth-factor {
+ margin-bottom: 20px;
+}
+
+.spinner {
+ position: absolute;
+ top: 3px;
+ left: 20px;
+}
+
+.poll-spinner {
+ position: absolute;
+}
+
+.auth-text {
+ font-size: 14px;
+ color: $black-9;
+}
+
+.poll-content {
+ display: flex;
+ justify-content: space-between;
+}
+
+.poll-button {
+ display: flex;
+ width: 30%;
+ align-items: center;
+ justify-content: center;
+}
+
+.poll-otp {
+ width: 60%;
+}
+
+.otp {
+ display: flex;
+ flex-direction: column;
+}
+
+.otp-actions {
+ display: flex;
+ justify-content: flex-end;
+}
diff --git a/imxweb/projects/olg/src/lib/mfa/mfa.component.ts b/imxweb/projects/olg/src/lib/mfa/mfa.component.ts
new file mode 100644
index 000000000..d180cd401
--- /dev/null
+++ b/imxweb/projects/olg/src/lib/mfa/mfa.component.ts
@@ -0,0 +1,195 @@
+/*
+ * ONE IDENTITY LLC. PROPRIETARY INFORMATION
+ *
+ * This software is confidential. One Identity, LLC. or one of its affiliates or
+ * subsidiaries, has supplied this software to you under terms of a
+ * license agreement, nondisclosure agreement or both.
+ *
+ * You may not copy, disclose, or use this software except in accordance with
+ * those terms.
+ *
+ *
+ * Copyright 2022 One Identity LLC.
+ * ALL RIGHTS RESERVED.
+ *
+ * ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
+ * WARRANTIES ABOUT THE SUITABILITY OF THE SOFTWARE,
+ * EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
+ * TO THE IMPLIED WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE, OR
+ * NON-INFRINGEMENT. ONE IDENTITY LLC. SHALL NOT BE
+ * LIABLE FOR ANY DAMAGES SUFFERED BY LICENSEE
+ * AS A RESULT OF USING, MODIFYING OR DISTRIBUTING
+ * THIS SOFTWARE OR ITS DERIVATIVES.
+ *
+ */
+
+import { AfterContentChecked, ChangeDetectorRef, Component, Inject, OnInit } from '@angular/core';
+import { FormArray, FormBuilder, FormGroup } from '@angular/forms';
+import { EuiLoadingService, EuiSidesheetRef, EUI_SIDESHEET_DATA } from '@elemental-ui/core';
+import { ActivateFactorData, AuthFactors, VerifyPollingResult } from 'imx-api-olg';
+import { ValType } from 'imx-qbm-dbts';
+import { BaseCdr, ColumnDependentReference, EntityService } from 'qbm';
+import { PortalMfaService } from './portal-mfa.service';
+
+@Component({
+ templateUrl: './mfa.component.html',
+ styleUrls: ['./mfa.component.scss'],
+})
+export class MfaComponent implements OnInit, AfterContentChecked {
+ public formGroup: FormGroup;
+
+ public authFactors: AuthFactors = { Factors: [] };
+ public authCDRs: ColumnDependentReference[] = [];
+ public showCDRs: boolean[] = [];
+
+ public activatedFactor: ActivateFactorData;
+ public checkingPoll = false;
+ public checkingOTP = false;
+ private workflowActionId: string;
+
+ constructor(
+ private formBuilder: FormBuilder,
+ private cdref: ChangeDetectorRef,
+ private readonly busyService: EuiLoadingService,
+
+ private readonly mfa: PortalMfaService,
+ private readonly entityService: EntityService,
+ @Inject(EUI_SIDESHEET_DATA)
+ public readonly data: {
+ workflowActionId: string;
+ },
+ private readonly sideSheetRef: EuiSidesheetRef
+ ) {
+ this.workflowActionId = data.workflowActionId;
+ this.formGroup = new FormGroup({ formArray: this.formBuilder.array([]) });
+ }
+
+ public isOTP(factorName: string): boolean {
+ return ['OneLogin Email', 'SMS'].includes(factorName);
+ }
+
+ public isProtect(factorName: string): boolean {
+ return factorName === 'OneLogin';
+ }
+
+ public isAuthenticator(factorName: string): boolean {
+ return factorName === 'Google Authenticator';
+ }
+
+ public isCDRValid(cdr: ColumnDependentReference): boolean {
+ return cdr.column.GetValue().length > 0;
+ }
+
+ public get formArray(): FormArray {
+ return this.formGroup.get('formArray') as FormArray;
+ }
+
+ public get isActivated(): boolean {
+ if (this.activatedFactor) {
+ return true;
+ }
+ return false;
+ }
+
+ public async ngOnInit(): Promise {
+ this.busyService.show();
+ try {
+ this.authFactors = await this.mfa.getFactors();
+ this.authFactors.Factors.forEach((factor) => {
+ this.authCDRs.push(
+ new BaseCdr(
+ this.entityService.createLocalEntityColumn({
+ ColumnName: 'OTP',
+ Type: ValType.Text,
+ MinLen: 1,
+ }),
+ '#LDS#One-Time Password'
+ )
+ );
+ this.showCDRs.push(false);
+ });
+ } finally {
+ this.busyService.hide();
+ }
+ }
+
+ public resetState(index: number): void {
+ this.showCDRs.fill(false);
+ this.authCDRs[index].column.PutValue('');
+ this.activatedFactor = null;
+ }
+
+ public ngAfterContentChecked(): void {
+ this.cdref.detectChanges();
+ }
+
+ public onClose(): void {
+ this.sideSheetRef.close();
+ }
+
+ public async activateFactor(factorName: string, deviceId: string, index: number): Promise {
+ this.busyService.show();
+ try {
+ this.showCDRs = this.showCDRs.fill(false);
+ this.activatedFactor = await this.mfa.activateFactor(this.workflowActionId, deviceId);
+ this.showCDRs[index] = true;
+ if (this.isProtect(factorName)) {
+ this.verifyPoll(index);
+ }
+ } finally {
+ this.busyService.hide();
+ }
+ }
+
+ public async verifyWithOTP(index: number): Promise {
+ this.checkingOTP = true;
+ try {
+ const result = await this.mfa.verifyWithVerificationId(
+ this.workflowActionId,
+ this.activatedFactor.id,
+ this.authCDRs[index].column.GetValue()
+ );
+ if (result) {
+ this.sideSheetRef.close(true);
+ } else {
+ this.resetState(index);
+ }
+ } finally {
+ this.checkingOTP = false;
+ }
+ }
+
+ public async verifyWithOTPAndDevice(index: number): Promise {
+ this.checkingOTP = true;
+ try {
+ const result = await this.mfa.verifyWithVerificationId(
+ this.workflowActionId,
+ this.activatedFactor.id,
+ this.authCDRs[index].column.GetValue(),
+ this.activatedFactor.device_id
+ );
+ if (result) {
+ this.sideSheetRef.close(true);
+ } else {
+ this.resetState(index);
+ }
+ } finally {
+ this.checkingOTP = false;
+ }
+ }
+
+ public async verifyPoll(index: number): Promise {
+ this.checkingPoll = true;
+ try {
+ const pollResult = await this.mfa.verifyWithPolling(this.workflowActionId, this.activatedFactor.id);
+ if (pollResult === VerifyPollingResult.Accepted) {
+ this.sideSheetRef.close(true);
+ } else {
+ this.resetState(index);
+ }
+ } finally {
+ this.checkingPoll = false;
+ }
+ }
+}
diff --git a/imxweb/projects/olg/src/lib/mfa/mfa.service.ts b/imxweb/projects/olg/src/lib/mfa/mfa.service.ts
new file mode 100644
index 000000000..ed0ba1190
--- /dev/null
+++ b/imxweb/projects/olg/src/lib/mfa/mfa.service.ts
@@ -0,0 +1,37 @@
+/*
+ * ONE IDENTITY LLC. PROPRIETARY INFORMATION
+ *
+ * This software is confidential. One Identity, LLC. or one of its affiliates or
+ * subsidiaries, has supplied this software to you under terms of a
+ * license agreement, nondisclosure agreement or both.
+ *
+ * You may not copy, disclose, or use this software except in accordance with
+ * those terms.
+ *
+ *
+ * Copyright 2022 One Identity LLC.
+ * ALL RIGHTS RESERVED.
+ *
+ * ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
+ * WARRANTIES ABOUT THE SUITABILITY OF THE SOFTWARE,
+ * EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
+ * TO THE IMPLIED WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE, OR
+ * NON-INFRINGEMENT. ONE IDENTITY LLC. SHALL NOT BE
+ * LIABLE FOR ANY DAMAGES SUFFERED BY LICENSEE
+ * AS A RESULT OF USING, MODIFYING OR DISTRIBUTING
+ * THIS SOFTWARE OR ITS DERIVATIVES.
+ *
+ */
+
+import { ActivateFactorData, AuthFactors } from 'imx-api-olg';
+
+export abstract class MfaService {
+ public abstract activateFactor(workflowActionId: string, deviceId: string): Promise;
+
+ public abstract verifyWithVerificationId(workflowActionId: string, verificationId: string, code: string): Promise;
+
+ public abstract verify(workflowActionId: string, code: string): Promise;
+
+ public abstract getFactors(): Promise;
+}
diff --git a/imxweb/projects/olg/src/lib/mfa/portal-mfa.service.ts b/imxweb/projects/olg/src/lib/mfa/portal-mfa.service.ts
new file mode 100644
index 000000000..5e57ee49c
--- /dev/null
+++ b/imxweb/projects/olg/src/lib/mfa/portal-mfa.service.ts
@@ -0,0 +1,52 @@
+/*
+ * ONE IDENTITY LLC. PROPRIETARY INFORMATION
+ *
+ * This software is confidential. One Identity, LLC. or one of its affiliates or
+ * subsidiaries, has supplied this software to you under terms of a
+ * license agreement, nondisclosure agreement or both.
+ *
+ * You may not copy, disclose, or use this software except in accordance with
+ * those terms.
+ *
+ *
+ * Copyright 2022 One Identity LLC.
+ * ALL RIGHTS RESERVED.
+ *
+ * ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
+ * WARRANTIES ABOUT THE SUITABILITY OF THE SOFTWARE,
+ * EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
+ * TO THE IMPLIED WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE, OR
+ * NON-INFRINGEMENT. ONE IDENTITY LLC. SHALL NOT BE
+ * LIABLE FOR ANY DAMAGES SUFFERED BY LICENSEE
+ * AS A RESULT OF USING, MODIFYING OR DISTRIBUTING
+ * THIS SOFTWARE OR ITS DERIVATIVES.
+ *
+ */
+
+import { ActivateFactorData, AuthFactors, VerifyPollingResult } from 'imx-api-olg';
+import { OlgApiService } from '../olg-api-client.service';
+import { Injectable } from '@angular/core';
+
+@Injectable({ providedIn: 'root' })
+export class PortalMfaService {
+ constructor(private readonly api: OlgApiService) {}
+
+ public activateFactor(workflowActionId: string, deviceId: string): Promise {
+ return this.api.client.portal_onelogin_mfa_activate_post(workflowActionId, deviceId);
+ }
+
+ public verifyWithVerificationId(workflowActionId: string, verificationId: string, code: string, deviceId?: string): Promise {
+ return this.api.client.portal_onelogin_mfa_verifyotpwithverificationid_post(workflowActionId, verificationId, code, {
+ deviceid: deviceId,
+ });
+ }
+
+ public verifyWithPolling(workflowActionId: string, verificationId: string): Promise {
+ return this.api.client.portal_onelogin_mfa_poll_get(workflowActionId, verificationId);
+ }
+
+ public getFactors(): Promise {
+ return this.api.client.portal_onelogin_mfa_factors_get();
+ }
+}
diff --git a/imxweb/projects/olg/src/lib/olg-api-client.service.ts b/imxweb/projects/olg/src/lib/olg-api-client.service.ts
new file mode 100644
index 000000000..51b51d20d
--- /dev/null
+++ b/imxweb/projects/olg/src/lib/olg-api-client.service.ts
@@ -0,0 +1,64 @@
+/*
+ * ONE IDENTITY LLC. PROPRIETARY INFORMATION
+ *
+ * This software is confidential. One Identity, LLC. or one of its affiliates or
+ * subsidiaries, has supplied this software to you under terms of a
+ * license agreement, nondisclosure agreement or both.
+ *
+ * You may not copy, disclose, or use this software except in accordance with
+ * those terms.
+ *
+ *
+ * Copyright 2022 One Identity LLC.
+ * ALL RIGHTS RESERVED.
+ *
+ * ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
+ * WARRANTIES ABOUT THE SUITABILITY OF THE SOFTWARE,
+ * EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
+ * TO THE IMPLIED WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE, OR
+ * NON-INFRINGEMENT. ONE IDENTITY LLC. SHALL NOT BE
+ * LIABLE FOR ANY DAMAGES SUFFERED BY LICENSEE
+ * AS A RESULT OF USING, MODIFYING OR DISTRIBUTING
+ * THIS SOFTWARE OR ITS DERIVATIVES.
+ *
+ */
+
+import { Injectable } from '@angular/core';
+import { V2Client, TypedClient } from 'imx-api-olg';
+import { ApiClient } from 'imx-qbm-dbts';
+import { AppConfigService, ClassloggerService, ImxTranslationProviderService } from 'qbm';
+
+@Injectable({
+ providedIn: 'root'
+})
+export class OlgApiService {
+ private tc: TypedClient;
+ public get typedClient(): TypedClient {
+ return this.tc;
+ }
+
+ private c: V2Client;
+ public get client(): V2Client {
+ return this.c;
+ }
+
+ public get apiClient(): ApiClient {
+ return this.config.apiClient;
+ }
+
+ constructor(
+ private readonly config: AppConfigService,
+ private readonly logger: ClassloggerService,
+ private readonly translationProvider: ImxTranslationProviderService) {
+ try {
+ // Use schema loaded by QBM client
+ const schemaProvider = config.client;
+ this.c = new V2Client(this.config.apiClient, schemaProvider);
+ this.tc = new TypedClient(this.c, this.translationProvider);
+
+ } catch (e) {
+ this.logger.error(this, e);
+ }
+ }
+}
diff --git a/imxweb/projects/olg/src/lib/olg-config.module.ts b/imxweb/projects/olg/src/lib/olg-config.module.ts
new file mode 100644
index 000000000..f5e674e23
--- /dev/null
+++ b/imxweb/projects/olg/src/lib/olg-config.module.ts
@@ -0,0 +1,78 @@
+/*
+ * ONE IDENTITY LLC. PROPRIETARY INFORMATION
+ *
+ * This software is confidential. One Identity, LLC. or one of its affiliates or
+ * subsidiaries, has supplied this software to you under terms of a
+ * license agreement, nondisclosure agreement or both.
+ *
+ * You may not copy, disclose, or use this software except in accordance with
+ * those terms.
+ *
+ *
+ * Copyright 2022 One Identity LLC.
+ * ALL RIGHTS RESERVED.
+ *
+ * ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
+ * WARRANTIES ABOUT THE SUITABILITY OF THE SOFTWARE,
+ * EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
+ * TO THE IMPLIED WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE, OR
+ * NON-INFRINGEMENT. ONE IDENTITY LLC. SHALL NOT BE
+ * LIABLE FOR ANY DAMAGES SUFFERED BY LICENSEE
+ * AS A RESULT OF USING, MODIFYING OR DISTRIBUTING
+ * THIS SOFTWARE OR ITS DERIVATIVES.
+ *
+ */
+
+import { CommonModule } from '@angular/common';
+import { NgModule } from '@angular/core';
+import { FormsModule, ReactiveFormsModule } from '@angular/forms';
+import { MatButtonModule } from '@angular/material/button';
+import { MatCardModule } from '@angular/material/card';
+import { MatDividerModule } from '@angular/material/divider';
+import { MatFormFieldModule } from '@angular/material/form-field';
+import { MatInputModule } from '@angular/material/input';
+import { MatProgressSpinnerModule } from '@angular/material/progress-spinner';
+import { Routes, RouterModule } from '@angular/router';
+import { EuiCoreModule } from '@elemental-ui/core';
+import { TranslateModule } from '@ngx-translate/core';
+import { CdrModule, ClassloggerService } from 'qbm';
+import { InitService } from './init.service';
+
+import { MfaComponent } from './mfa/mfa.component';
+import { MfaService } from './mfa/mfa.service';
+import { PortalMfaService } from './mfa/portal-mfa.service';
+
+const routes: Routes = [
+];
+
+@NgModule({
+ imports: [
+ CommonModule,
+ FormsModule,
+ ReactiveFormsModule,
+ MatFormFieldModule,
+ MatInputModule,
+ MatCardModule,
+ MatButtonModule,
+ MatDividerModule,
+ RouterModule.forChild(routes),
+ TranslateModule,
+ EuiCoreModule,
+ CdrModule,
+ MatProgressSpinnerModule
+ ],
+ declarations: [
+ MfaComponent
+ ],
+ providers: [
+ PortalMfaService
+ ]
+})
+export class OlgConfigModule {
+ constructor(private readonly initializer: InitService, private readonly logger: ClassloggerService) {
+ this.logger.info(this, '🔥 OLG loaded');
+ this.initializer.onInit(routes);
+ this.logger.info(this, '▶️ OLG initialized');
+ }
+}
diff --git a/imxweb/projects/olg/src/lib/placeholder.spec.ts b/imxweb/projects/olg/src/lib/placeholder.spec.ts
new file mode 100644
index 000000000..a35de5e64
--- /dev/null
+++ b/imxweb/projects/olg/src/lib/placeholder.spec.ts
@@ -0,0 +1,33 @@
+/*
+ * ONE IDENTITY LLC. PROPRIETARY INFORMATION
+ *
+ * This software is confidential. One Identity, LLC. or one of its affiliates or
+ * subsidiaries, has supplied this software to you under terms of a
+ * license agreement, nondisclosure agreement or both.
+ *
+ * You may not copy, disclose, or use this software except in accordance with
+ * those terms.
+ *
+ *
+ * Copyright 2022 One Identity LLC.
+ * ALL RIGHTS RESERVED.
+ *
+ * ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
+ * WARRANTIES ABOUT THE SUITABILITY OF THE SOFTWARE,
+ * EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
+ * TO THE IMPLIED WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE, OR
+ * NON-INFRINGEMENT. ONE IDENTITY LLC. SHALL NOT BE
+ * LIABLE FOR ANY DAMAGES SUFFERED BY LICENSEE
+ * AS A RESULT OF USING, MODIFYING OR DISTRIBUTING
+ * THIS SOFTWARE OR ITS DERIVATIVES.
+ *
+ */
+
+describe('OLG placeholder test', () => {
+
+
+ it('should be executed', () => {
+ expect(true).toBeTruthy();
+ });
+});
\ No newline at end of file
diff --git a/imxweb/projects/olg/src/public_api.ts b/imxweb/projects/olg/src/public_api.ts
new file mode 100644
index 000000000..5bd4d020b
--- /dev/null
+++ b/imxweb/projects/olg/src/public_api.ts
@@ -0,0 +1,30 @@
+/*
+ * ONE IDENTITY LLC. PROPRIETARY INFORMATION
+ *
+ * This software is confidential. One Identity, LLC. or one of its affiliates or
+ * subsidiaries, has supplied this software to you under terms of a
+ * license agreement, nondisclosure agreement or both.
+ *
+ * You may not copy, disclose, or use this software except in accordance with
+ * those terms.
+ *
+ *
+ * Copyright 2022 One Identity LLC.
+ * ALL RIGHTS RESERVED.
+ *
+ * ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
+ * WARRANTIES ABOUT THE SUITABILITY OF THE SOFTWARE,
+ * EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
+ * TO THE IMPLIED WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE, OR
+ * NON-INFRINGEMENT. ONE IDENTITY LLC. SHALL NOT BE
+ * LIABLE FOR ANY DAMAGES SUFFERED BY LICENSEE
+ * AS A RESULT OF USING, MODIFYING OR DISTRIBUTING
+ * THIS SOFTWARE OR ITS DERIVATIVES.
+ *
+ */
+
+export { OlgConfigModule } from './lib/olg-config.module';
+export { MfaComponent } from './lib/mfa/mfa.component';
+export { PortalMfaService } from './lib/mfa/portal-mfa.service';
+
diff --git a/imxweb/projects/olg/src/test.ts b/imxweb/projects/olg/src/test.ts
new file mode 100644
index 000000000..8986070be
--- /dev/null
+++ b/imxweb/projects/olg/src/test.ts
@@ -0,0 +1,49 @@
+/*
+ * ONE IDENTITY LLC. PROPRIETARY INFORMATION
+ *
+ * This software is confidential. One Identity, LLC. or one of its affiliates or
+ * subsidiaries, has supplied this software to you under terms of a
+ * license agreement, nondisclosure agreement or both.
+ *
+ * You may not copy, disclose, or use this software except in accordance with
+ * those terms.
+ *
+ *
+ * Copyright 2022 One Identity LLC.
+ * ALL RIGHTS RESERVED.
+ *
+ * ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
+ * WARRANTIES ABOUT THE SUITABILITY OF THE SOFTWARE,
+ * EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
+ * TO THE IMPLIED WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE, OR
+ * NON-INFRINGEMENT. ONE IDENTITY LLC. SHALL NOT BE
+ * LIABLE FOR ANY DAMAGES SUFFERED BY LICENSEE
+ * AS A RESULT OF USING, MODIFYING OR DISTRIBUTING
+ * THIS SOFTWARE OR ITS DERIVATIVES.
+ *
+ */
+
+// This file is required by karma.conf.js and loads recursively all the .spec and framework files
+
+import 'core-js/es7/reflect';
+import 'zone.js/dist/zone';
+import 'zone.js/dist/zone-testing';
+import { getTestBed } from '@angular/core/testing';
+import {
+ BrowserDynamicTestingModule,
+ platformBrowserDynamicTesting
+} from '@angular/platform-browser-dynamic/testing';
+import { TestHelperModule } from 'qbm';
+
+declare const require: any;
+
+// First, initialize the Angular testing environment.
+getTestBed().initTestEnvironment(
+ [BrowserDynamicTestingModule, TestHelperModule],
+ platformBrowserDynamicTesting()
+);
+// Then we find all the tests.
+const context = require.context('./', true, /\.spec\.ts$/);
+// And load the modules.
+context.keys().map(context);
diff --git a/imxweb/projects/olg/summary.json b/imxweb/projects/olg/summary.json
new file mode 100644
index 000000000..fe51488c7
--- /dev/null
+++ b/imxweb/projects/olg/summary.json
@@ -0,0 +1 @@
+[]
diff --git a/imxweb/projects/olg/tsconfig.lib.json b/imxweb/projects/olg/tsconfig.lib.json
new file mode 100644
index 000000000..6bc419f84
--- /dev/null
+++ b/imxweb/projects/olg/tsconfig.lib.json
@@ -0,0 +1,16 @@
+/* To learn more about this file see: https://angular.io/config/tsconfig. */
+{
+ "extends": "../../tsconfig.json",
+ "compilerOptions": {
+ "outDir": "../../out-tsc/lib",
+ "declaration": true,
+ "declarationMap": true,
+ "sourceMap": true,
+ "inlineSources": true,
+ "types": []
+ },
+ "exclude": [
+ "src/test.ts",
+ "**/*.spec.ts"
+ ]
+}
diff --git a/imxweb/projects/olg/tsconfig.lib.prod.json b/imxweb/projects/olg/tsconfig.lib.prod.json
new file mode 100644
index 000000000..61c7592e7
--- /dev/null
+++ b/imxweb/projects/olg/tsconfig.lib.prod.json
@@ -0,0 +1,10 @@
+/* To learn more about this file see: https://angular.io/config/tsconfig. */
+{
+ "extends": "./tsconfig.lib.json",
+ "compilerOptions": {
+ "declarationMap": false
+ },
+ "angularCompilerOptions": {
+ "enableIvy": true
+ }
+}
diff --git a/imxweb/projects/olg/tsconfig.spec.json b/imxweb/projects/olg/tsconfig.spec.json
new file mode 100644
index 000000000..16da33db0
--- /dev/null
+++ b/imxweb/projects/olg/tsconfig.spec.json
@@ -0,0 +1,17 @@
+{
+ "extends": "../../tsconfig.json",
+ "compilerOptions": {
+ "outDir": "../../out-tsc/spec",
+ "types": [
+ "jasmine",
+ "node"
+ ]
+ },
+ "files": [
+ "src/test.ts"
+ ],
+ "include": [
+ "**/*.spec.ts",
+ "**/*.d.ts"
+ ]
+}
diff --git a/imxweb/projects/olg/tslint.json b/imxweb/projects/olg/tslint.json
new file mode 100644
index 000000000..8bab15f53
--- /dev/null
+++ b/imxweb/projects/olg/tslint.json
@@ -0,0 +1,17 @@
+{
+ "extends": "../../tslint.json",
+ "rules": {
+ "directive-selector": [
+ true,
+ "attribute",
+ "imx",
+ "camelCase"
+ ],
+ "component-selector": [
+ true,
+ "element",
+ "imx",
+ "kebab-case"
+ ]
+ }
+}
diff --git a/imxweb/projects/pol/ng-package.json b/imxweb/projects/pol/ng-package.json
index 4f2bbf3e1..19fcc0ce4 100644
--- a/imxweb/projects/pol/ng-package.json
+++ b/imxweb/projects/pol/ng-package.json
@@ -1,25 +1,5 @@
{
"$schema": "../../node_modules/ng-packagr/ng-package.schema.json",
- "allowedNonPeerDependencies": [
- "@angular/animations",
- "@angular/cdk",
- "@angular/common",
- "@angular/compiler",
- "@angular/core",
- "@angular/forms",
- "@angular/material",
- "@angular/material-moment-adapter",
- "@angular/platform-browser",
- "@angular/platform-browser-dynamic",
- "@angular/router",
- "@elemental-ui/cadence-icon",
- "@elemental-ui/core",
- "@ngx-translate/core",
- "@ngx-translate/http-loader",
- "applicationinsights-js",
- "billboard.js",
- "chap-timeline"
- ],
"dest": "../../dist/pol",
"lib": {
"entryFile": "src/public_api.ts",
diff --git a/imxweb/projects/pol/package.json b/imxweb/projects/pol/package.json
index 7b0db5e8f..1fcfffb4b 100644
--- a/imxweb/projects/pol/package.json
+++ b/imxweb/projects/pol/package.json
@@ -1,31 +1,7 @@
{
"name": "pol",
- "version": "8.2.0",
+ "version": "9.0.0",
"private": true,
- "peerDependencies": {
-
- },
- "dependencies": {
- "@angular/animations": "^11.2.14",
- "@angular/cdk": "^11.2.13",
- "@angular/common": "^11.2.14",
- "@angular/compiler": "^11.2.14",
- "@angular/core": "^11.2.14",
- "@angular/forms": "^11.2.14",
- "@angular/material": "^11.2.13",
- "@angular/material-moment-adapter": "^11.2.13",
- "@angular/platform-browser": "^11.2.14",
- "@angular/platform-browser-dynamic": "^11.2.14",
- "@angular/router": "^11.2.14",
- "@elemental-ui/cadence-icon": "file:imx-modules/elemental-ui_cadence-icon.tgz",
- "@elemental-ui/core": "file:imx-modules/elemental-ui_core.tgz",
- "@ngx-translate/core": "^11.0.1",
- "@ngx-translate/http-loader": "^4.0.0",
- "applicationinsights-js": "^1.0.21",
- "billboard.js": "^1.8.0",
- "chap-timeline": "^2.9.2"
-
- },
"bundledDependencies": [
"imx-api-pol"
]
diff --git a/imxweb/projects/qer/src/lib/starling/starling.service.ts b/imxweb/projects/pol/src/lib/admin/permissions-helper.ts
similarity index 75%
rename from imxweb/projects/qer/src/lib/starling/starling.service.ts
rename to imxweb/projects/pol/src/lib/admin/permissions-helper.ts
index b3b7b3c51..54c95da4b 100644
--- a/imxweb/projects/qer/src/lib/starling/starling.service.ts
+++ b/imxweb/projects/pol/src/lib/admin/permissions-helper.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -24,13 +24,6 @@
*
*/
-export abstract class StarlingService {
-
- public abstract sendPush(): Promise;
-
- public abstract verify(code: string): Promise;
-
- public abstract sendSms(): Promise;
-
- public abstract sendCall(): Promise;
+export function isExceptionApprover(groups: string[]): boolean {
+ return groups.find(item => item === 'vi_4_QERPOLICYADMIN_EXCEPTION') != null;
}
diff --git a/imxweb/projects/pol/src/lib/admin/permissions.service.ts b/imxweb/projects/pol/src/lib/admin/permissions.service.ts
new file mode 100644
index 000000000..f309cb3e1
--- /dev/null
+++ b/imxweb/projects/pol/src/lib/admin/permissions.service.ts
@@ -0,0 +1,42 @@
+/*
+ * ONE IDENTITY LLC. PROPRIETARY INFORMATION
+ *
+ * This software is confidential. One Identity, LLC. or one of its affiliates or
+ * subsidiaries, has supplied this software to you under terms of a
+ * license agreement, nondisclosure agreement or both.
+ *
+ * You may not copy, disclose, or use this software except in accordance with
+ * those terms.
+ *
+ *
+ * Copyright 2022 One Identity LLC.
+ * ALL RIGHTS RESERVED.
+ *
+ * ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
+ * WARRANTIES ABOUT THE SUITABILITY OF THE SOFTWARE,
+ * EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
+ * TO THE IMPLIED WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE, OR
+ * NON-INFRINGEMENT. ONE IDENTITY LLC. SHALL NOT BE
+ * LIABLE FOR ANY DAMAGES SUFFERED BY LICENSEE
+ * AS A RESULT OF USING, MODIFYING OR DISTRIBUTING
+ * THIS SOFTWARE OR ITS DERIVATIVES.
+ *
+ */
+
+import { Injectable } from '@angular/core';
+
+import { UserModelService } from 'qer';
+import { isExceptionApprover } from './permissions-helper';
+
+@Injectable({
+ providedIn: 'root'
+})
+export class PermissionsService {
+ constructor(private readonly userService: UserModelService) { }
+
+
+ public async isExceptionApprover(): Promise {
+ return isExceptionApprover((await this.userService.getGroups()).map(group => group.Name));
+ }
+}
diff --git a/imxweb/projects/pol/src/lib/api.service.ts b/imxweb/projects/pol/src/lib/api.service.ts
index 8b18e3627..f10981d6d 100644
--- a/imxweb/projects/pol/src/lib/api.service.ts
+++ b/imxweb/projects/pol/src/lib/api.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/pol/src/lib/dashboard-plugin/dashboard-plugin.component.html b/imxweb/projects/pol/src/lib/dashboard-plugin/dashboard-plugin.component.html
index 6f8796863..326933c14 100644
--- a/imxweb/projects/pol/src/lib/dashboard-plugin/dashboard-plugin.component.html
+++ b/imxweb/projects/pol/src/lib/dashboard-plugin/dashboard-plugin.component.html
@@ -1 +1,6 @@
+
+
\ No newline at end of file
diff --git a/imxweb/projects/pol/src/lib/dashboard-plugin/dashboard-plugin.component.ts b/imxweb/projects/pol/src/lib/dashboard-plugin/dashboard-plugin.component.ts
index 3879db07b..f6c943873 100644
--- a/imxweb/projects/pol/src/lib/dashboard-plugin/dashboard-plugin.component.ts
+++ b/imxweb/projects/pol/src/lib/dashboard-plugin/dashboard-plugin.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/pol/src/lib/guards/policy-violation-approver-guard.service.ts b/imxweb/projects/pol/src/lib/guards/policy-violation-approver-guard.service.ts
new file mode 100644
index 000000000..d24e15659
--- /dev/null
+++ b/imxweb/projects/pol/src/lib/guards/policy-violation-approver-guard.service.ts
@@ -0,0 +1,51 @@
+/*
+ * ONE IDENTITY LLC. PROPRIETARY INFORMATION
+ *
+ * This software is confidential. One Identity, LLC. or one of its affiliates or
+ * subsidiaries, has supplied this software to you under terms of a
+ * license agreement, nondisclosure agreement or both.
+ *
+ * You may not copy, disclose, or use this software except in accordance with
+ * those terms.
+ *
+ *
+ * Copyright 2022 One Identity LLC.
+ * ALL RIGHTS RESERVED.
+ *
+ * ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
+ * WARRANTIES ABOUT THE SUITABILITY OF THE SOFTWARE,
+ * EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
+ * TO THE IMPLIED WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE, OR
+ * NON-INFRINGEMENT. ONE IDENTITY LLC. SHALL NOT BE
+ * LIABLE FOR ANY DAMAGES SUFFERED BY LICENSEE
+ * AS A RESULT OF USING, MODIFYING OR DISTRIBUTING
+ * THIS SOFTWARE OR ITS DERIVATIVES.
+ *
+ */
+
+import { Injectable } from '@angular/core';
+import { CanActivate, Router } from '@angular/router';
+
+import { AppConfigService } from 'qbm';
+import { PermissionsService } from '../admin/permissions.service';
+
+@Injectable({
+ providedIn: 'root',
+})
+export class PolicyViolationApproverGuardService implements CanActivate {
+ constructor(
+ private readonly permissionService: PermissionsService,
+ private readonly appConfig: AppConfigService,
+ private readonly router: Router
+ ) { }
+
+ public async canActivate(): Promise {
+ const canApprovePolicyViolation = await this.permissionService.isExceptionApprover();
+ if (!canApprovePolicyViolation) {
+ this.router.navigate([this.appConfig.Config.routeConfig.start], { queryParams: {} });
+ return false;
+ }
+ return canApprovePolicyViolation;
+ }
+}
diff --git a/imxweb/projects/pol/src/lib/init.service.spec.ts b/imxweb/projects/pol/src/lib/init.service.spec.ts
index 02d7b7344..953cf84ab 100644
--- a/imxweb/projects/pol/src/lib/init.service.spec.ts
+++ b/imxweb/projects/pol/src/lib/init.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/pol/src/lib/init.service.ts b/imxweb/projects/pol/src/lib/init.service.ts
index b57e1f5ad..7aa65c89c 100644
--- a/imxweb/projects/pol/src/lib/init.service.ts
+++ b/imxweb/projects/pol/src/lib/init.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -27,15 +27,18 @@
import { Injectable } from '@angular/core';
import { Router, Route } from '@angular/router';
-import { ExtService } from 'qbm';
+import { ExtService, MenuItem, MenuService } from 'qbm';
+import { isExceptionApprover } from './admin/permissions-helper';
import { DashboardPluginComponent } from './dashboard-plugin/dashboard-plugin.component';
@Injectable({ providedIn: 'root' })
export class InitService {
constructor(
private readonly extService: ExtService,
+ private readonly menuService: MenuService,
private readonly router: Router
) {
+ this.setupMenu();
}
public onInit(routes: Route[]): void {
@@ -51,4 +54,28 @@ export class InitService {
});
this.router.resetConfig(config);
}
+
+ private setupMenu(): void {
+ this.menuService.addMenuFactories((preProps: string[], groups: string[]) => {
+ if (!preProps.includes('COMPLIANCE') || !isExceptionApprover(groups)) {
+ return null;
+ }
+
+ const menu: MenuItem = {
+ id: 'ROOT_Compliance',
+ title: '#LDS#Compliance',
+ sorting: '25',
+ items: [
+ {
+ id: 'POL_policy-violations',
+ route: 'compliance/policyviolations',
+ title: '#LDS#Menu Entry Policy violations',
+ sorting: '20-10',
+ }
+ ]
+ };
+
+ return menu;
+ });
+ }
}
diff --git a/imxweb/projects/pol/src/lib/pol-config.module.ts b/imxweb/projects/pol/src/lib/pol-config.module.ts
index 32b975382..8a3214ec5 100644
--- a/imxweb/projects/pol/src/lib/pol-config.module.ts
+++ b/imxweb/projects/pol/src/lib/pol-config.module.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -32,17 +32,33 @@ import { Routes, RouterModule } from '@angular/router';
import { TranslateModule } from '@ngx-translate/core';
import { EuiCoreModule } from '@elemental-ui/core';
+
import { ClassloggerService, RouteGuardService } from 'qbm';
import { InitService } from './init.service';
import { TilesModule } from 'qer';
import { DashboardPluginComponent } from './dashboard-plugin/dashboard-plugin.component';
+import { PolicyViolationsComponent } from './policy-violations/policy-violations.component';
+import { PolicyViolationsModule } from './policy-violations/policy-violations.module';
+import { PolicyViolationApproverGuardService } from './guards/policy-violation-approver-guard.service';
const routes: Routes = [
+ {
+ path: 'compliance/policyviolations/approve',
+ component: PolicyViolationsComponent,
+ canActivate: [RouteGuardService, PolicyViolationApproverGuardService],
+ resolve: [RouteGuardService]
+ },
+ {
+ path: 'compliance/policyviolations',
+ component: PolicyViolationsComponent,
+ canActivate: [RouteGuardService, PolicyViolationApproverGuardService],
+ resolve: [RouteGuardService]
+ }
];
@NgModule({
declarations: [
- DashboardPluginComponent
+ DashboardPluginComponent,
],
imports: [
CommonModule,
@@ -51,7 +67,8 @@ const routes: Routes = [
MatIconModule,
MatListModule,
TranslateModule,
- EuiCoreModule
+ EuiCoreModule,
+ PolicyViolationsModule
]
})
export class PolConfigModule {
diff --git a/imxweb/projects/pol/src/lib/policy-violations/policy-violation.ts b/imxweb/projects/pol/src/lib/policy-violations/policy-violation.ts
new file mode 100644
index 000000000..b1c81d13c
--- /dev/null
+++ b/imxweb/projects/pol/src/lib/policy-violations/policy-violation.ts
@@ -0,0 +1,93 @@
+/*
+ * ONE IDENTITY LLC. PROPRIETARY INFORMATION
+ *
+ * This software is confidential. One Identity, LLC. or one of its affiliates or
+ * subsidiaries, has supplied this software to you under terms of a
+ * license agreement, nondisclosure agreement or both.
+ *
+ * You may not copy, disclose, or use this software except in accordance with
+ * those terms.
+ *
+ *
+ * Copyright 2022 One Identity LLC.
+ * ALL RIGHTS RESERVED.
+ *
+ * ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
+ * WARRANTIES ABOUT THE SUITABILITY OF THE SOFTWARE,
+ * EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
+ * TO THE IMPLIED WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE, OR
+ * NON-INFRINGEMENT. ONE IDENTITY LLC. SHALL NOT BE
+ * LIABLE FOR ANY DAMAGES SUFFERED BY LICENSEE
+ * AS A RESULT OF USING, MODIFYING OR DISTRIBUTING
+ * THIS SOFTWARE OR ITS DERIVATIVES.
+ *
+ */
+
+import { PortalPoliciesViolationsApprove } from 'imx-api-pol';
+import { BaseReadonlyCdr, ColumnDependentReference } from 'qbm';
+
+export class PolicyViolation extends PortalPoliciesViolationsApprove {
+
+ public properties: ColumnDependentReference[];
+ /**
+ * The color and the caption depending on the value of the state of a {@link PortalPoliciesViolationsApprove}.
+ */
+ public get stateBadge(): { color: 'blue' | 'orange' | 'green', caption: string } {
+ return {
+ color: this.stateBadgeColor,
+ caption: this.stateCaption
+ };
+ }
+ private stateBadgeColor: 'blue' | 'orange' | 'green';
+ private stateCaption: string;
+
+ constructor(
+ private readonly baseObject: PortalPoliciesViolationsApprove
+ ) {
+ super(baseObject.GetEntity());
+ this.initPropertyInfo();
+ this.initStateBadge();
+ }
+
+ public get key(): string {
+ return this.baseObject.GetEntity().GetKeys()[0];
+ }
+
+ private initPropertyInfo(): void {
+ const props: any[] =
+ [
+ this.UID_QERPolicy,
+ this.ObjectKey
+ ];
+
+ if (this.State.value.toLowerCase() !== 'pending') {
+ props.push(...[
+ this.UID_PersonDecisionMade,
+ this.UID_QERJustification,
+ this.DecisionReason,
+ this.DecisionDate
+ ]);
+ }
+
+ this.properties = props
+ .filter(property => property.value != null && property.value !== '')
+ .map(property => new BaseReadonlyCdr(property.Column));
+ }
+
+ private async initStateBadge(): Promise {
+ switch (this.State.value) {
+ case 'approved':
+ this.stateBadgeColor = 'green';
+ this.stateCaption = '#LDS#Exception granted';
+ break;
+ case 'denied':
+ this.stateBadgeColor = 'orange';
+ this.stateCaption = '#LDS#Exception denied';
+ break;
+ default:
+ this.stateBadgeColor = 'blue';
+ this.stateCaption = '#LDS#Approval decision pending';
+ }
+ }
+}
diff --git a/imxweb/projects/pol/src/lib/policy-violations/policy-violations-action/policy-violations-action-multi-action/policy-violations-action-multi-action.component.html b/imxweb/projects/pol/src/lib/policy-violations/policy-violations-action/policy-violations-action-multi-action/policy-violations-action-multi-action.component.html
new file mode 100644
index 000000000..770f59261
--- /dev/null
+++ b/imxweb/projects/pol/src/lib/policy-violations/policy-violations-action/policy-violations-action-multi-action/policy-violations-action-multi-action.component.html
@@ -0,0 +1,28 @@
+
+ {{ '#LDS#Heading General Settings' | translate }}
+ {{ '#LDS#Here you can make settings that are applied to each selected policy violation.' | translate }}
+
+
+
+
+
\ No newline at end of file
diff --git a/imxweb/projects/pol/src/lib/policy-violations/policy-violations-action/policy-violations-action-multi-action/policy-violations-action-multi-action.component.scss b/imxweb/projects/pol/src/lib/policy-violations/policy-violations-action/policy-violations-action-multi-action/policy-violations-action-multi-action.component.scss
new file mode 100644
index 000000000..7ba872959
--- /dev/null
+++ b/imxweb/projects/pol/src/lib/policy-violations/policy-violations-action/policy-violations-action-multi-action/policy-violations-action-multi-action.component.scss
@@ -0,0 +1,42 @@
+:host {
+ display: flex;
+ flex-direction: column;
+ overflow: hidden;
+
+ ::ng-deep .mat-list-base .mat-list-item .mat-list-item-content{
+ padding-left: 0%;
+ }
+
+ ::ng-deep .mat-list-base .mat-list-item{
+ height: auto;
+ margin-bottom: 16px;
+ }
+}
+
+mat-card {
+ margin-bottom: 20px;
+}
+
+mat-card-content {
+ overflow: auto;
+}
+
+.imx-selection-card {
+ flex: 1 1 auto;
+ display: flex;
+ flex-direction: column;
+ overflow: hidden;
+}
+
+imx-bulk-editor {
+ margin-top: 20px;
+}
+
+
+.mat-list-base .mat-list-item .mat-line{
+ margin-left: 0px;
+ overflow: auto;
+ white-space: inherit;
+ word-wrap: break-word;
+ height: auto;
+}
diff --git a/imxweb/projects/pol/src/lib/policy-violations/policy-violations-action/policy-violations-action-multi-action/policy-violations-action-multi-action.component.ts b/imxweb/projects/pol/src/lib/policy-violations/policy-violations-action/policy-violations-action-multi-action/policy-violations-action-multi-action.component.ts
new file mode 100644
index 000000000..e48c30762
--- /dev/null
+++ b/imxweb/projects/pol/src/lib/policy-violations/policy-violations-action/policy-violations-action-multi-action/policy-violations-action-multi-action.component.ts
@@ -0,0 +1,59 @@
+/*
+ * ONE IDENTITY LLC. PROPRIETARY INFORMATION
+ *
+ * This software is confidential. One Identity, LLC. or one of its affiliates or
+ * subsidiaries, has supplied this software to you under terms of a
+ * license agreement, nondisclosure agreement or both.
+ *
+ * You may not copy, disclose, or use this software except in accordance with
+ * those terms.
+ *
+ *
+ * Copyright 2022 One Identity LLC.
+ * ALL RIGHTS RESERVED.
+ *
+ * ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
+ * WARRANTIES ABOUT THE SUITABILITY OF THE SOFTWARE,
+ * EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
+ * TO THE IMPLIED WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE, OR
+ * NON-INFRINGEMENT. ONE IDENTITY LLC. SHALL NOT BE
+ * LIABLE FOR ANY DAMAGES SUFFERED BY LICENSEE
+ * AS A RESULT OF USING, MODIFYING OR DISTRIBUTING
+ * THIS SOFTWARE OR ITS DERIVATIVES.
+ *
+ */
+
+import { Component, Input } from '@angular/core';
+import { FormGroup } from '@angular/forms';
+
+import { PolicyViolationsAction } from '../policy-violations-action.interface';
+
+/**
+ * @ignore since this is only an internal component.
+ *
+ * Component for making a decision for a multiple policy violations.
+ * There is an alternative component for the case of a decision for a single policy violation as well
+ * {@link PolicyViolationsActionSingleActionComponent}
+ */
+@Component({
+ selector: 'imx-policy-violations-action-multi-action',
+ templateUrl: './policy-violations-action-multi-action.component.html',
+ styleUrls: ['./policy-violations-action-multi-action.component.scss']
+})
+export class PolicyViolationsActionMultiActionComponent{
+
+ /**
+ * @ignore since this is only an internal component.
+ *
+ * Data coming from the service about the policy violations.
+ */
+ @Input() public data: PolicyViolationsAction;
+
+ /**
+ * @ignore since this is only an internal component.
+ *
+ * The form group to which the necessary form fields will be added.
+ */
+ @Input() public formGroup: FormGroup;
+}
diff --git a/imxweb/projects/pol/src/lib/policy-violations/policy-violations-action/policy-violations-action-parameters.interface.ts b/imxweb/projects/pol/src/lib/policy-violations/policy-violations-action/policy-violations-action-parameters.interface.ts
new file mode 100644
index 000000000..60ec517dd
--- /dev/null
+++ b/imxweb/projects/pol/src/lib/policy-violations/policy-violations-action/policy-violations-action-parameters.interface.ts
@@ -0,0 +1,42 @@
+/*
+ * ONE IDENTITY LLC. PROPRIETARY INFORMATION
+ *
+ * This software is confidential. One Identity, LLC. or one of its affiliates or
+ * subsidiaries, has supplied this software to you under terms of a
+ * license agreement, nondisclosure agreement or both.
+ *
+ * You may not copy, disclose, or use this software except in accordance with
+ * those terms.
+ *
+ *
+ * Copyright 2022 One Identity LLC.
+ * ALL RIGHTS RESERVED.
+ *
+ * ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
+ * WARRANTIES ABOUT THE SUITABILITY OF THE SOFTWARE,
+ * EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
+ * TO THE IMPLIED WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE, OR
+ * NON-INFRINGEMENT. ONE IDENTITY LLC. SHALL NOT BE
+ * LIABLE FOR ANY DAMAGES SUFFERED BY LICENSEE
+ * AS A RESULT OF USING, MODIFYING OR DISTRIBUTING
+ * THIS SOFTWARE OR ITS DERIVATIVES.
+ *
+ */
+
+import { ColumnDependentReference } from 'qbm';
+
+/**
+ * Defines the {@link ColumnDependentReference} for an action that can be performed on a policy violation
+ */
+export interface PolicyViolationsActionParameters {
+ /**
+ * A free text field for a reason
+ */
+ reason: ColumnDependentReference;
+
+ /**
+ * A FK-Editor for standard justifications
+ */
+ justification?: ColumnDependentReference;
+}
diff --git a/imxweb/projects/pol/src/lib/policy-violations/policy-violations-action/policy-violations-action-single-action/policy-violations-action-single-action.component.html b/imxweb/projects/pol/src/lib/policy-violations/policy-violations-action/policy-violations-action-single-action/policy-violations-action-single-action.component.html
new file mode 100644
index 000000000..880cc8072
--- /dev/null
+++ b/imxweb/projects/pol/src/lib/policy-violations/policy-violations-action/policy-violations-action-single-action/policy-violations-action-single-action.component.html
@@ -0,0 +1,10 @@
+
+ {{ policyViolation.GetEntity()?.GetDisplay() }}
+ {{ policyViolation.State.Column.GetDisplayValue() }}
+
+
+
+
+
\ No newline at end of file
diff --git a/imxweb/projects/pol/src/lib/policy-violations/policy-violations-action/policy-violations-action-single-action/policy-violations-action-single-action.component.scss b/imxweb/projects/pol/src/lib/policy-violations/policy-violations-action/policy-violations-action-single-action/policy-violations-action-single-action.component.scss
new file mode 100644
index 000000000..fed2b0eb2
--- /dev/null
+++ b/imxweb/projects/pol/src/lib/policy-violations/policy-violations-action/policy-violations-action-single-action/policy-violations-action-single-action.component.scss
@@ -0,0 +1,16 @@
+// Create a config with the default typography levels.
+// see: https://material.angular.io/guide/typography
+@import "~@angular/material/theming";
+$config: mat-typography-config();
+
+mat-card-content {
+ overflow: hidden;
+}
+
+mat-card-title {
+ font-size: mat-font-size($config, subheading-2);
+}
+
+mat-card-subtitle {
+ font-size: mat-font-size($config, subheading-1);
+}
diff --git a/imxweb/projects/pol/src/lib/policy-violations/policy-violations-action/policy-violations-action-single-action/policy-violations-action-single-action.component.ts b/imxweb/projects/pol/src/lib/policy-violations/policy-violations-action/policy-violations-action-single-action/policy-violations-action-single-action.component.ts
new file mode 100644
index 000000000..b1c927f7a
--- /dev/null
+++ b/imxweb/projects/pol/src/lib/policy-violations/policy-violations-action/policy-violations-action-single-action/policy-violations-action-single-action.component.ts
@@ -0,0 +1,92 @@
+/*
+ * ONE IDENTITY LLC. PROPRIETARY INFORMATION
+ *
+ * This software is confidential. One Identity, LLC. or one of its affiliates or
+ * subsidiaries, has supplied this software to you under terms of a
+ * license agreement, nondisclosure agreement or both.
+ *
+ * You may not copy, disclose, or use this software except in accordance with
+ * those terms.
+ *
+ *
+ * Copyright 2022 One Identity LLC.
+ * ALL RIGHTS RESERVED.
+ *
+ * ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
+ * WARRANTIES ABOUT THE SUITABILITY OF THE SOFTWARE,
+ * EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
+ * TO THE IMPLIED WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE, OR
+ * NON-INFRINGEMENT. ONE IDENTITY LLC. SHALL NOT BE
+ * LIABLE FOR ANY DAMAGES SUFFERED BY LICENSEE
+ * AS A RESULT OF USING, MODIFYING OR DISTRIBUTING
+ * THIS SOFTWARE OR ITS DERIVATIVES.
+ *
+ */
+
+import { Component, Input, OnInit } from '@angular/core';
+import { AbstractControl, FormGroup } from '@angular/forms';
+
+import { ColumnDependentReference } from 'qbm';
+import { PolicyViolation } from '../../policy-violation';
+import { PolicyViolationsAction } from '../policy-violations-action.interface';
+
+/**
+ * @ignore since this is only an internal component.
+ *
+ * Component for making a decision for a single policy violation.
+ * There is an alternative component for the case of a decision for multiple policy violations as
+ * well: {@link PolicyViolationActionMultiActionComponent}.
+ */
+@Component({
+ selector: 'imx-policy-violations-action-single-action',
+ templateUrl: './policy-violations-action-single-action.component.html',
+ styleUrls: ['./policy-violations-action-single-action.component.scss']
+})
+export class PolicyViolationsActionSingleActionComponent implements OnInit {
+
+ /**
+ * @ignore since this is only an internal component.
+ *
+ * Data coming from the service about the policy violation.
+ */
+ @Input() public data: PolicyViolationsAction;
+
+ /**
+ * @ignore since this is only an internal component.
+ *
+ * The form group to which the necessary form fields will be added.
+ */
+ @Input() public formGroup: FormGroup;
+
+ /**
+ * @ignore since this is only public because of databinding to the template
+ *
+ * The single policy violation taken from {@link data}
+ */
+ public policyViolation: PolicyViolation;
+
+ /**
+ * @ignore since this is only an internal component
+ *
+ * Sets up the {@link columns} to be displayed/edited during OnInit lifecycle hook.
+ */
+ public ngOnInit(): void {
+ this.policyViolation = this.data.policyViolations[0];
+ }
+
+ /**
+ * @ignore since this is only public because of databinding to the template
+ *
+ * Handles the event emitted when a cdr editor created a new form control.
+ *
+ * @param name The name of the form control
+ * @param control The form control
+ */
+ public onFormControlCreated(name: string, control: AbstractControl): void {
+ // use setTimeout to make addControl asynchronous in order to avoid "NG0100: Expression has changed after it was checked"
+ setTimeout(() =>
+ this.formGroup.addControl(name, control)
+ );
+ }
+}
diff --git a/imxweb/projects/pol/src/lib/policy-violations/policy-violations-action/policy-violations-action.component.html b/imxweb/projects/pol/src/lib/policy-violations/policy-violations-action/policy-violations-action.component.html
new file mode 100644
index 000000000..24b631628
--- /dev/null
+++ b/imxweb/projects/pol/src/lib/policy-violations/policy-violations-action/policy-violations-action.component.html
@@ -0,0 +1,16 @@
+
+
+
+
+
+ {{ '#LDS#Save' | translate }}
+
+
diff --git a/imxweb/projects/pol/src/lib/policy-violations/policy-violations-action/policy-violations-action.component.scss b/imxweb/projects/pol/src/lib/policy-violations/policy-violations-action/policy-violations-action.component.scss
new file mode 100644
index 000000000..d8efa71bd
--- /dev/null
+++ b/imxweb/projects/pol/src/lib/policy-violations/policy-violations-action/policy-violations-action.component.scss
@@ -0,0 +1,18 @@
+.eui-sidesheet-content {
+ padding: 32px;
+ overflow: hidden;
+ height: 100%;
+ flex: 1;
+ display: flex;
+ flex-direction: column;
+}
+
+.eui-sidesheet-actions.mat-card {
+ margin: 16px 32px;
+}
+
+.imx-policy-violation-content{
+ overflow: hidden;
+ display: flex;
+ flex-direction: column;
+}
\ No newline at end of file
diff --git a/imxweb/projects/pol/src/lib/policy-violations/policy-violations-action/policy-violations-action.component.ts b/imxweb/projects/pol/src/lib/policy-violations/policy-violations-action/policy-violations-action.component.ts
new file mode 100644
index 000000000..838d17080
--- /dev/null
+++ b/imxweb/projects/pol/src/lib/policy-violations/policy-violations-action/policy-violations-action.component.ts
@@ -0,0 +1,66 @@
+/*
+ * ONE IDENTITY LLC. PROPRIETARY INFORMATION
+ *
+ * This software is confidential. One Identity, LLC. or one of its affiliates or
+ * subsidiaries, has supplied this software to you under terms of a
+ * license agreement, nondisclosure agreement or both.
+ *
+ * You may not copy, disclose, or use this software except in accordance with
+ * those terms.
+ *
+ *
+ * Copyright 2022 One Identity LLC.
+ * ALL RIGHTS RESERVED.
+ *
+ * ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
+ * WARRANTIES ABOUT THE SUITABILITY OF THE SOFTWARE,
+ * EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
+ * TO THE IMPLIED WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE, OR
+ * NON-INFRINGEMENT. ONE IDENTITY LLC. SHALL NOT BE
+ * LIABLE FOR ANY DAMAGES SUFFERED BY LICENSEE
+ * AS A RESULT OF USING, MODIFYING OR DISTRIBUTING
+ * THIS SOFTWARE OR ITS DERIVATIVES.
+ *
+ */
+
+import { Component, Inject } from '@angular/core';
+import { FormGroup } from '@angular/forms';
+import { EUI_SIDESHEET_DATA, EuiSidesheetRef } from '@elemental-ui/core';
+import { PolicyViolationsAction } from './policy-violations-action.interface';
+
+/**
+ * Component displayed in a sidesheet to make a decision for one or more policy violations.
+ *
+ * Uses two alternate views
+ *
+ *
a) a simple view for a single policy violation
+ *
b) a complex view using bulk items for multiple policy violations.
+ *
+ *
+ * Therefore this component is not meant to be used directly but rather be called
+ * from a service that does the pre-calculation and opens this component in a
+ * sidesheet passing the pre-calculated values.
+ *
+ */
+@Component({
+ templateUrl: './policy-violations-action.component.html',
+ styleUrls: ['./policy-violations-action.component.scss']
+})
+export class PolicyViolationsActionComponent {
+ /**
+ * The form group to which the created form controls will be added.
+ */
+ public readonly formGroup = new FormGroup({});
+
+ /**
+ * Creates a new PolicyViolationsActionComponent
+ * @param data The pre-calculated data object.
+ * @param sideSheetRef A reference to the sidesheet containing this component.
+ */
+ constructor(
+ @Inject(EUI_SIDESHEET_DATA) public readonly data: PolicyViolationsAction,
+ public readonly sideSheetRef: EuiSidesheetRef
+ ) {
+ }
+}
diff --git a/imxweb/projects/pol/src/lib/policy-violations/policy-violations-action/policy-violations-action.interface.ts b/imxweb/projects/pol/src/lib/policy-violations/policy-violations-action/policy-violations-action.interface.ts
new file mode 100644
index 000000000..eff74fd64
--- /dev/null
+++ b/imxweb/projects/pol/src/lib/policy-violations/policy-violations-action/policy-violations-action.interface.ts
@@ -0,0 +1,53 @@
+/*
+ * ONE IDENTITY LLC. PROPRIETARY INFORMATION
+ *
+ * This software is confidential. One Identity, LLC. or one of its affiliates or
+ * subsidiaries, has supplied this software to you under terms of a
+ * license agreement, nondisclosure agreement or both.
+ *
+ * You may not copy, disclose, or use this software except in accordance with
+ * those terms.
+ *
+ *
+ * Copyright 2022 One Identity LLC.
+ * ALL RIGHTS RESERVED.
+ *
+ * ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
+ * WARRANTIES ABOUT THE SUITABILITY OF THE SOFTWARE,
+ * EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
+ * TO THE IMPLIED WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE, OR
+ * NON-INFRINGEMENT. ONE IDENTITY LLC. SHALL NOT BE
+ * LIABLE FOR ANY DAMAGES SUFFERED BY LICENSEE
+ * AS A RESULT OF USING, MODIFYING OR DISTRIBUTING
+ * THIS SOFTWARE OR ITS DERIVATIVES.
+ *
+ */
+
+import { PolicyViolation } from '../policy-violation';
+import { PolicyViolationsActionParameters } from './policy-violations-action-parameters.interface';
+
+/**
+ * Common View Model for making a decision for one or more policy violations.
+ */
+export interface PolicyViolationsAction {
+ /**
+ * Parameters according to the type of decision.
+ */
+ actionParameters: PolicyViolationsActionParameters;
+
+ /**
+ * The policy violations to make a decision for.
+ */
+ policyViolations: PolicyViolation[];
+
+ /**
+ * Whether or not the decision is an approval.
+ */
+ approve?: boolean;
+
+ /**
+ * A description for the type of decision to be made.
+ */
+ description?: string;
+}
diff --git a/imxweb/projects/pol/src/lib/policy-violations/policy-violations-sidesheet/policy-violations-sidesheet.component.html b/imxweb/projects/pol/src/lib/policy-violations/policy-violations-sidesheet/policy-violations-sidesheet.component.html
new file mode 100644
index 000000000..76f5b9115
--- /dev/null
+++ b/imxweb/projects/pol/src/lib/policy-violations/policy-violations-sidesheet/policy-violations-sidesheet.component.html
@@ -0,0 +1,21 @@
+
\ No newline at end of file
diff --git a/imxweb/projects/pol/src/lib/policy-violations/policy-violations-sidesheet/policy-violations-sidesheet.component.scss b/imxweb/projects/pol/src/lib/policy-violations/policy-violations-sidesheet/policy-violations-sidesheet.component.scss
new file mode 100644
index 000000000..2081b6df7
--- /dev/null
+++ b/imxweb/projects/pol/src/lib/policy-violations/policy-violations-sidesheet/policy-violations-sidesheet.component.scss
@@ -0,0 +1,30 @@
+@import "@elemental-ui/core/src/styles/_palette.scss";
+
+:host {
+ .eui-sidesheet-content {
+ display: flex;
+ flex-direction: column;
+ }
+
+ .eui-sidesheet-actions.mat-card {
+ margin: 16px 32px;
+ }
+
+ .eui-badge ::ng-deep .eui-badge-content {
+ font-size: 12px;
+ line-height: 12px;
+ margin-bottom: 20px;
+ }
+
+ .imx-state-caption {
+ font-size: 12px;
+ color: $black-9;
+ padding-bottom: 5px;
+ }
+
+ .eui-sidesheet-actions {
+ button:not(:last-of-type) {
+ margin-right: 10px;
+ }
+ }
+}
diff --git a/imxweb/projects/pol/src/lib/policy-violations/policy-violations-sidesheet/policy-violations-sidesheet.component.ts b/imxweb/projects/pol/src/lib/policy-violations/policy-violations-sidesheet/policy-violations-sidesheet.component.ts
new file mode 100644
index 000000000..288e9a99f
--- /dev/null
+++ b/imxweb/projects/pol/src/lib/policy-violations/policy-violations-sidesheet/policy-violations-sidesheet.component.ts
@@ -0,0 +1,71 @@
+/*
+ * ONE IDENTITY LLC. PROPRIETARY INFORMATION
+ *
+ * This software is confidential. One Identity, LLC. or one of its affiliates or
+ * subsidiaries, has supplied this software to you under terms of a
+ * license agreement, nondisclosure agreement or both.
+ *
+ * You may not copy, disclose, or use this software except in accordance with
+ * those terms.
+ *
+ *
+ * Copyright 2022 One Identity LLC.
+ * ALL RIGHTS RESERVED.
+ *
+ * ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
+ * WARRANTIES ABOUT THE SUITABILITY OF THE SOFTWARE,
+ * EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
+ * TO THE IMPLIED WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE, OR
+ * NON-INFRINGEMENT. ONE IDENTITY LLC. SHALL NOT BE
+ * LIABLE FOR ANY DAMAGES SUFFERED BY LICENSEE
+ * AS A RESULT OF USING, MODIFYING OR DISTRIBUTING
+ * THIS SOFTWARE OR ITS DERIVATIVES.
+ *
+ */
+
+import { Component, Inject } from '@angular/core';
+import { EuiSidesheetRef, EUI_SIDESHEET_DATA } from '@elemental-ui/core';
+
+import { ColumnDependentReference } from 'qbm';
+import { PolicyViolation } from '../policy-violation';
+import { PolicyViolationsService } from '../policy-violations.service';
+
+@Component({
+ selector: 'imx-policy-violations-sidesheet',
+ templateUrl: './policy-violations-sidesheet.component.html',
+ styleUrls: ['./policy-violations-sidesheet.component.scss']
+})
+export class PolicyViolationsSidesheetComponent {
+
+ public cdrList: ColumnDependentReference[] = [];
+
+ public get isPending(): boolean {
+ return this.data.State.value?.toLocaleLowerCase() === 'pending';
+ }
+
+ constructor(
+ @Inject(EUI_SIDESHEET_DATA) public data: PolicyViolation,
+ private readonly policyViolationService: PolicyViolationsService,
+ private readonly sideSheetRef: EuiSidesheetRef
+ ) {
+ this.cdrList = this.data.properties;
+ }
+
+ /**
+ * Opens the Approve-Sidesheet for the current selected rules violations and closes the sidesheet afterwards.
+ */
+ public async approve(): Promise {
+ await this.policyViolationService.approve([this.data]);
+ return this.sideSheetRef.close(true);
+ }
+
+ /**
+ * Opens the Deny-Sidesheet for the current selected rules violations and closes the sidesheet afterwards.
+ */
+ public async deny(): Promise {
+ await this.policyViolationService.deny([this.data]);
+ return this.sideSheetRef.close(true);
+ }
+
+}
diff --git a/imxweb/projects/pol/src/lib/policy-violations/policy-violations.component.html b/imxweb/projects/pol/src/lib/policy-violations/policy-violations.component.html
new file mode 100644
index 000000000..d779a8449
--- /dev/null
+++ b/imxweb/projects/pol/src/lib/policy-violations/policy-violations.component.html
@@ -0,0 +1,78 @@
+
\ No newline at end of file
diff --git a/imxweb/projects/pol/src/lib/policy-violations/policy-violations.component.scss b/imxweb/projects/pol/src/lib/policy-violations/policy-violations.component.scss
new file mode 100644
index 000000000..70c4ac200
--- /dev/null
+++ b/imxweb/projects/pol/src/lib/policy-violations/policy-violations.component.scss
@@ -0,0 +1,116 @@
+@mixin imx-flex-column-container {
+ display: flex;
+ flex-direction: column;
+}
+
+@mixin imx-flex-row-container {
+ display: flex;
+ flex-direction: row;
+}
+
+.eui-sidesheet-content {
+ @include imx-flex-column-container();
+}
+
+.heading-wrapper {
+ @include imx-flex-row-container();
+ flex: 0 0 auto;
+
+ .helper-alert {
+ display: flex;
+ margin-bottom: 15px;
+ }
+
+ .alert-wrapper {
+ margin: 0 0 0 auto;
+ align-self: flex-end;
+ width: 50%;
+ }
+}
+
+:host {
+ @include imx-flex-column-container();
+ overflow: hidden;
+ height: inherit;
+ width: inherit;
+ max-width: 100%;
+}
+
+.imx-policyviolation-page {
+ background-color: inherit;
+ @include imx-flex-column-container();
+ overflow: hidden;
+
+ div.imx-table-container {
+ @include imx-flex-column-container();
+ overflow: hidden;
+ height: inherit;
+
+ .imx-policyviolation-table {
+ flex-grow: 1;
+ overflow: auto;
+
+ .imx-main-column {
+ max-width: 600px;
+ margin-right: 10px;
+ }
+
+ .imx-decision {
+ min-width: 210px;
+ > * {
+ margin-bottom: 3px;
+ margin-top: 3px;
+ margin-left: 10px;
+ }
+ }
+ }
+ }
+
+ .imx-button-bar {
+ @include imx-flex-row-container();
+ margin-top: 20px;
+ flex: 0 0 auto;
+
+ .imx-badge {
+ background-color: inherit;
+
+ ::ng-deep .eui-badge-content {
+ font-size: 14px;
+ line-height: 14px;
+ }
+ }
+
+ .imx-selected-items {
+ margin: 0;
+ line-height: 36px;
+ }
+
+ button {
+ margin-left: 10px;
+ }
+
+ .imx-menu-spacer {
+ flex-grow: 1;
+ }
+ }
+}
+
+@media screen and (max-width: 768px) {
+ .imx-rules-violations-page {
+ .heading-wrapper {
+ display: block;
+
+ .alert-wrapper {
+ margin: 0 0 20px 0;
+ width: 100%;
+ }
+ }
+ }
+}
+
+
+@media only screen and (max-width: 1024px) {
+ ::ng-deep .mat-column-decision {
+ display: none;
+ }
+}
\ No newline at end of file
diff --git a/imxweb/projects/pol/src/lib/policy-violations/policy-violations.component.ts b/imxweb/projects/pol/src/lib/policy-violations/policy-violations.component.ts
new file mode 100644
index 000000000..f6eb0bc57
--- /dev/null
+++ b/imxweb/projects/pol/src/lib/policy-violations/policy-violations.component.ts
@@ -0,0 +1,221 @@
+/*
+ * ONE IDENTITY LLC. PROPRIETARY INFORMATION
+ *
+ * This software is confidential. One Identity, LLC. or one of its affiliates or
+ * subsidiaries, has supplied this software to you under terms of a
+ * license agreement, nondisclosure agreement or both.
+ *
+ * You may not copy, disclose, or use this software except in accordance with
+ * those terms.
+ *
+ *
+ * Copyright 2022 One Identity LLC.
+ * ALL RIGHTS RESERVED.
+ *
+ * ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
+ * WARRANTIES ABOUT THE SUITABILITY OF THE SOFTWARE,
+ * EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
+ * TO THE IMPLIED WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE, OR
+ * NON-INFRINGEMENT. ONE IDENTITY LLC. SHALL NOT BE
+ * LIABLE FOR ANY DAMAGES SUFFERED BY LICENSEE
+ * AS A RESULT OF USING, MODIFYING OR DISTRIBUTING
+ * THIS SOFTWARE OR ITS DERIVATIVES.
+ *
+ */
+
+import { OverlayRef } from '@angular/cdk/overlay';
+import { Component, OnInit, ViewChild } from '@angular/core';
+import { EuiLoadingService, EuiSidesheetService } from '@elemental-ui/core';
+import { TranslateService } from '@ngx-translate/core';
+import { Subscription } from 'rxjs';
+import { ActivatedRoute, Params } from '@angular/router';
+
+import { CollectionLoadParameters, DataModel, DisplayColumns, IClientProperty, TypedEntity, ValType } from 'imx-qbm-dbts';
+import { DataSourceToolbarFilter, DataSourceToolbarGroupData, DataSourceToolbarSettings, DataTableComponent, DataTableGroupedData, ClientPropertyForTableColumns } from 'qbm';
+import { createGroupData } from 'qbm';
+import { PolicyViolation } from './policy-violation';
+import { PolicyViolationsSidesheetComponent } from './policy-violations-sidesheet/policy-violations-sidesheet.component';
+import { PolicyViolationsService } from './policy-violations.service';
+
+@Component({
+ selector: 'imx-policy-violations',
+ templateUrl: './policy-violations.component.html',
+ styleUrls: ['./policy-violations.component.scss']
+})
+export class PolicyViolationsComponent implements OnInit {
+
+ public DisplayColumns = DisplayColumns;
+ public selectedViolations: PolicyViolation[] = [];
+ public dstSettings: DataSourceToolbarSettings;
+ public approveOnly: boolean;
+ public groupedData: { [key: string]: DataTableGroupedData } = {};
+
+ @ViewChild(DataTableComponent) public table: DataTableComponent;
+
+ public readonly itemStatus = {
+ enabled: (item: PolicyViolation): boolean =>
+ item.State?.value?.toLocaleLowerCase() === 'pending'
+ };
+
+ private filterOptions: DataSourceToolbarFilter[] = [];
+ private groupData: DataSourceToolbarGroupData;
+ private dataModel: DataModel;
+ private navigationState: CollectionLoadParameters;
+ private displayedColumns: ClientPropertyForTableColumns[] = [];
+ private readonly subscriptions: Subscription[] = [];
+
+ constructor(
+ private readonly busyService: EuiLoadingService,
+ public policyViolationsService: PolicyViolationsService,
+ private readonly sidesheet: EuiSidesheetService,
+ private readonly translate: TranslateService,
+ private readonly actRoute: ActivatedRoute
+ ) {
+
+ this.approveOnly = actRoute.snapshot.url[actRoute.snapshot.url.length - 1].path === 'approve';
+
+ this.navigationState = {};
+
+ this.subscriptions.push(this.policyViolationsService.applied.subscribe(async () => {
+ this.getData();
+ this.table.clearSelection();
+ }));
+ }
+
+ public async ngOnInit(): Promise {
+ const entitySchema = this.policyViolationsService.policyViolationsSchema;
+ this.displayedColumns = [
+ entitySchema?.Columns.UID_QERPolicy,
+ entitySchema?.Columns.ObjectKey,
+ entitySchema?.Columns.State,
+ {
+ ColumnName: 'actions',
+ Type: ValType.String,
+ afterAdditionals: true
+ }
+ ];
+
+ let busyIndicator: OverlayRef;
+ setTimeout(() => (busyIndicator = this.busyService.show()));
+
+ try {
+ this.dataModel = await this.policyViolationsService.getPolicyViolationsDataModel();
+ this.filterOptions = this.dataModel.Filters;
+
+ this.subscriptions.push(this.actRoute.queryParams.subscribe(params => this.updateFiltersFromRouteParams(params)));
+
+ if (this.approveOnly) {
+ this.tryApplyFilter('state', 'pending');
+ }
+ this.groupData = createGroupData(
+ this.dataModel,
+ (parameters) =>
+ this.policyViolationsService.getGroupInfo({
+ ...{
+ PageSize: this.navigationState.PageSize,
+ StartIndex: 0,
+ },
+ ...parameters,
+ }),
+ []
+ );
+ } finally {
+ setTimeout(() => this.busyService.hide(busyIndicator));
+ }
+ return this.getData();
+ }
+
+ public async viewDetails(selectedRulesViolation: PolicyViolation): Promise {
+ const result = await this.sidesheet.open(PolicyViolationsSidesheetComponent, {
+ title: await this.translate.get('#LDS#Heading View Policy Violation Details').toPromise(),
+ headerColour: 'iris-blue',
+ bodyColour: 'asher-gray',
+ panelClass: 'imx-sidesheet',
+ padding: '0',
+ width: '600px',
+ testId: 'rules-violations-details-sidesheet',
+ data: selectedRulesViolation,
+ }).afterClosed().toPromise();
+
+ if (result) {
+ this.getData();
+ }
+ }
+
+ public onSelectionChanged(cases: PolicyViolation[]): void {
+ this.selectedViolations = cases;
+ }
+
+ public async search(search: string): Promise {
+ return this.getData({ ...this.navigationState, ...{ search } });
+ }
+
+ public async onGroupingChange(groupKey: string): Promise {
+ let overlayRef: OverlayRef;
+ setTimeout(() => (overlayRef = this.busyService.show()));
+
+ try {
+ const groupedData = this.groupedData[groupKey];
+ groupedData.data = await this.policyViolationsService.get(groupedData.navigationState);
+ groupedData.settings = {
+ displayedColumns: this.dstSettings.displayedColumns,
+ dataSource: groupedData.data,
+ entitySchema: this.dstSettings.entitySchema,
+ navigationState: groupedData.navigationState,
+ };
+ } finally {
+ setTimeout(() => this.busyService.hide(overlayRef));
+ }
+ }
+
+ public async getData(newState?: CollectionLoadParameters): Promise {
+ if (newState) {
+ this.navigationState = { ...newState, ...{ OrderBy: 'XDateInserted' } };
+ }
+
+ let busyIndicator: OverlayRef;
+ setTimeout(() => (busyIndicator = this.busyService.show()));
+
+ try {
+ const dataSource = await this.policyViolationsService.get(this.navigationState);
+ const entitySchema = this.policyViolationsService.policyViolationsSchema;
+ this.dstSettings = {
+ dataSource,
+ entitySchema,
+ navigationState: this.navigationState,
+ filters: this.filterOptions,
+ dataModel: this.dataModel,
+ groupData: this.groupData,
+ displayedColumns: this.displayedColumns,
+ };
+ } finally {
+ setTimeout(() => this.busyService.hide(busyIndicator));
+ }
+ }
+
+ private updateFiltersFromRouteParams(params: Params): void {
+ let foundMatchingParam = false;
+ for (const [key, value] of Object.entries(params)) {
+ if (this.tryApplyFilter(key, value)) {
+ foundMatchingParam = true;
+ }
+ }
+ }
+
+ private tryApplyFilter(name: string, value: string): boolean {
+ const index = this.dataModel.Filters.findIndex(elem => elem.Name.toLowerCase() === name.toLowerCase());
+
+ if (index > -1) {
+ const filter = this.dataModel.Filters[index] as DataSourceToolbarFilter;
+ if (filter) {
+ filter.InitialValue = value;
+ filter.CurrentValue = value;
+ this.navigationState[name] = value;
+ return true;
+ }
+ }
+
+ return false;
+ }
+}
diff --git a/imxweb/projects/pol/src/lib/policy-violations/policy-violations.module.ts b/imxweb/projects/pol/src/lib/policy-violations/policy-violations.module.ts
new file mode 100644
index 000000000..ba0f1261d
--- /dev/null
+++ b/imxweb/projects/pol/src/lib/policy-violations/policy-violations.module.ts
@@ -0,0 +1,68 @@
+/*
+ * ONE IDENTITY LLC. PROPRIETARY INFORMATION
+ *
+ * This software is confidential. One Identity, LLC. or one of its affiliates or
+ * subsidiaries, has supplied this software to you under terms of a
+ * license agreement, nondisclosure agreement or both.
+ *
+ * You may not copy, disclose, or use this software except in accordance with
+ * those terms.
+ *
+ *
+ * Copyright 2022 One Identity LLC.
+ * ALL RIGHTS RESERVED.
+ *
+ * ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
+ * WARRANTIES ABOUT THE SUITABILITY OF THE SOFTWARE,
+ * EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
+ * TO THE IMPLIED WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE, OR
+ * NON-INFRINGEMENT. ONE IDENTITY LLC. SHALL NOT BE
+ * LIABLE FOR ANY DAMAGES SUFFERED BY LICENSEE
+ * AS A RESULT OF USING, MODIFYING OR DISTRIBUTING
+ * THIS SOFTWARE OR ITS DERIVATIVES.
+ *
+ */
+
+import { NgModule } from '@angular/core';
+import { CommonModule } from '@angular/common';
+import { MatButtonModule } from '@angular/material/button';
+import { MatCardModule } from '@angular/material/card';
+import { ReactiveFormsModule } from '@angular/forms';
+import { EuiCoreModule } from '@elemental-ui/core';
+import { TranslateModule } from '@ngx-translate/core';
+import { MatListModule } from '@angular/material/list';
+
+import { BulkPropertyEditorModule, CdrModule, DataSourceToolbarModule, DataTableModule } from 'qbm';
+import { JustificationModule } from 'qer';
+import { PolicyViolationsComponent } from './policy-violations.component';
+import { PolicyViolationsActionComponent } from './policy-violations-action/policy-violations-action.component';
+import { PolicyViolationsActionMultiActionComponent } from './policy-violations-action/policy-violations-action-multi-action/policy-violations-action-multi-action.component';
+import { PolicyViolationsActionSingleActionComponent } from './policy-violations-action/policy-violations-action-single-action/policy-violations-action-single-action.component';
+import { PolicyViolationsSidesheetComponent } from './policy-violations-sidesheet/policy-violations-sidesheet.component';
+
+@NgModule({
+ declarations: [
+ PolicyViolationsComponent,
+ PolicyViolationsActionComponent,
+ PolicyViolationsActionMultiActionComponent,
+ PolicyViolationsActionSingleActionComponent,
+ PolicyViolationsSidesheetComponent
+ ],
+ imports: [
+ EuiCoreModule,
+ MatButtonModule,
+ MatCardModule,
+ MatListModule,
+ CommonModule,
+ TranslateModule,
+ ReactiveFormsModule,
+ BulkPropertyEditorModule,
+ CdrModule,
+ JustificationModule,
+ DataTableModule,
+ DataSourceToolbarModule
+ ],
+ exports: [PolicyViolationsComponent]
+})
+export class PolicyViolationsModule { }
diff --git a/imxweb/projects/pol/src/lib/policy-violations/policy-violations.service.ts b/imxweb/projects/pol/src/lib/policy-violations/policy-violations.service.ts
new file mode 100644
index 000000000..a3e183766
--- /dev/null
+++ b/imxweb/projects/pol/src/lib/policy-violations/policy-violations.service.ts
@@ -0,0 +1,224 @@
+/*
+ * ONE IDENTITY LLC. PROPRIETARY INFORMATION
+ *
+ * This software is confidential. One Identity, LLC. or one of its affiliates or
+ * subsidiaries, has supplied this software to you under terms of a
+ * license agreement, nondisclosure agreement or both.
+ *
+ * You may not copy, disclose, or use this software except in accordance with
+ * those terms.
+ *
+ *
+ * Copyright 2022 One Identity LLC.
+ * ALL RIGHTS RESERVED.
+ *
+ * ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
+ * WARRANTIES ABOUT THE SUITABILITY OF THE SOFTWARE,
+ * EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
+ * TO THE IMPLIED WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE, OR
+ * NON-INFRINGEMENT. ONE IDENTITY LLC. SHALL NOT BE
+ * LIABLE FOR ANY DAMAGES SUFFERED BY LICENSEE
+ * AS A RESULT OF USING, MODIFYING OR DISTRIBUTING
+ * THIS SOFTWARE OR ITS DERIVATIVES.
+ *
+ */
+
+import { OverlayRef } from '@angular/cdk/overlay';
+import { Injectable } from '@angular/core';
+import { EuiLoadingService, EuiSidesheetService } from '@elemental-ui/core';
+import { TranslateService } from '@ngx-translate/core';
+import { Subject } from 'rxjs';
+
+import { PortalPoliciesViolationsApprove } from 'imx-api-pol';
+import { DecisionInput } from 'imx-api-qer';
+import { CollectionLoadParameters, DataModel, EntitySchema, GroupInfo, TypedEntityCollectionData, ValType } from 'imx-qbm-dbts';
+import { BaseCdr, EntityService, SnackBarService } from 'qbm';
+import { JustificationService, JustificationType, ParameterDataService } from 'qer';
+import { ApiService } from '../api.service';
+import { PolicyViolationsActionParameters } from './policy-violations-action/policy-violations-action-parameters.interface';
+import { PolicyViolationsActionComponent } from './policy-violations-action/policy-violations-action.component';
+import { PolicyViolation } from './policy-violation';
+
+@Injectable({
+ providedIn: 'root'
+})
+export class PolicyViolationsService {
+
+ public readonly applied = new Subject();
+
+ constructor(
+ public readonly justificationService: JustificationService,
+ private readonly api: ApiService,
+ private readonly busyService: EuiLoadingService,
+ private readonly entityService: EntityService,
+ private readonly translate: TranslateService,
+ private readonly snackBar: SnackBarService,
+ private readonly sideSheet: EuiSidesheetService
+ ) { }
+
+ public get policyViolationsSchema(): EntitySchema {
+ return this.api.typedClient.PortalPoliciesViolationsApprove.GetSchema();
+ }
+
+ public getPolicyViolationsDataModel(): Promise {
+ return this.api.client.portal_policies_violations_approve_datamodel_get();
+ }
+
+ public async get(polDecisionParameters?: CollectionLoadParameters): Promise> {
+ const collection = await this.api.typedClient.PortalPoliciesViolationsApprove.Get(polDecisionParameters);
+ return {
+ tableName: collection.tableName,
+ totalCount: collection.totalCount,
+ Data: collection.Data.map((item: PortalPoliciesViolationsApprove) => {
+ return new PolicyViolation(item);
+ })
+ };
+ }
+
+ public async getGroupInfo(parameters: { by?: string, def?: string } & CollectionLoadParameters = {}): Promise {
+ return this.api.client.portal_policies_violations_approve_group_get({
+ ...parameters,
+ withcount: true
+ });
+ }
+
+ // Methods for decision making
+
+ public async approve(policyViolations: PolicyViolation[]): Promise {
+ let justification: BaseCdr;
+ let busyIndicator: OverlayRef;
+ setTimeout(() => busyIndicator = this.busyService.show());
+
+ try {
+ justification = await this.justificationService.createCdr(JustificationType.approve);
+ } finally {
+ setTimeout(() => this.busyService.hide(busyIndicator));
+ }
+
+ const actionParameters: any = {
+ justification,
+ reason: this.createCdrReason(justification ? '#LDS#Additional comments about your decision' : undefined)
+ };
+
+ return this.editAction({
+ title: '#LDS#Heading Grant Exception',
+ headerColour: 'aspen-green',
+ message: '#LDS#Exceptions have been successfully granted for {0} policy violations.',
+ discardChangesOnAbort: true,
+ data: {
+ policyViolations,
+ approve: true,
+ actionParameters,
+ },
+ apply: async (violation: PolicyViolation) => {
+ await this.makeDecision(violation, {
+ Reason: actionParameters.reason.column.GetValue(),
+ UidJustification: actionParameters.justification?.column?.GetValue(),
+ Decision: true
+ });
+ }
+ });
+ }
+
+ public async deny(policyViolations: PolicyViolation[]): Promise {
+ let justification: BaseCdr;
+
+ let busyIndicator: OverlayRef;
+ setTimeout(() => busyIndicator = this.busyService.show());
+
+ try {
+ justification = await this.justificationService.createCdr(JustificationType.deny);
+ } finally {
+ setTimeout(() => this.busyService.hide(busyIndicator));
+ }
+
+ const actionParameters: PolicyViolationsActionParameters = {
+ justification,
+ reason: this.createCdrReason(justification ? '#LDS#Additional comments about your decision' : undefined)
+ };
+
+ return this.editAction(
+ {
+ title: '#LDS#Heading Deny Exception',
+ headerColour: 'corbin-orange',
+ message: '#LDS#Exceptions have been successfully denied for {0} policy violations.',
+ discardChangesOnAbort: true,
+ data: {
+ policyViolations,
+ actionParameters,
+ customValidation: undefined
+ },
+ apply: async (policyViolation: PolicyViolation) => {
+ try {
+ await policyViolation.GetEntity().Commit(true);
+ await this.makeDecision(policyViolation, {
+ Reason: actionParameters.reason.column.GetValue(),
+ UidJustification: actionParameters.justification?.column?.GetValue(),
+ Decision: false
+ });
+ } catch (error) {
+ await policyViolation.GetEntity().DiscardChanges();
+ throw error;
+ }
+ }
+ }
+ );
+ }
+
+ private async makeDecision(pwo: PolicyViolation, decision: DecisionInput): Promise {
+ await this.api.client.portal_policies_violations_approve_post(pwo.GetEntity().GetKeys()[0], decision);
+ }
+
+ private createCdrReason(display?: string): BaseCdr {
+ const column = this.entityService.createLocalEntityColumn({
+ ColumnName: 'ReasonHead',
+ Type: ValType.Text,
+ IsMultiLine: true
+ });
+
+ return new BaseCdr(column, display || '#LDS#Reason for your decision');
+ }
+
+ private async editAction(config: any): Promise {
+ const result = await this.sideSheet.open(PolicyViolationsActionComponent, {
+ title: await this.translate.get(config.title).toPromise(),
+ headerColour: config.headerColour ?? 'iris-blue',
+ bodyColour: 'asher-gray',
+ padding: '0',
+ width: '600px',
+ testId: 'policy-violations-action',
+ data: config.data
+ }).afterClosed().toPromise();
+
+ if (result) {
+ let busyIndicator: OverlayRef;
+ setTimeout(() => busyIndicator = this.busyService.show());
+
+ let success: boolean;
+ try {
+ for (const policyViolation of config.data.policyViolations) {
+ await config.apply(policyViolation);
+ }
+ success = true;
+ } finally {
+ setTimeout(() => this.busyService.hide(busyIndicator));
+ }
+
+ if (success) {
+ this.snackBar.open({
+ key: config.message, parameters: [config.data.policyViolations.length,
+ config.data.actionParameters.uidPerson ? config.data.actionParameters.uidPerson.column.GetDisplayValue() : '']
+ });
+ this.applied.next();
+ }
+ } else {
+ if (config.discardChangesOnAbort) {
+ for (const approval of config.data.policyViolations) {
+ await approval.GetEntity().DiscardChanges();
+ }
+ }
+ this.snackBar.open({ key: '#LDS#You have canceled the action.' });
+ }
+ }
+}
diff --git a/imxweb/projects/pol/src/public_api.ts b/imxweb/projects/pol/src/public_api.ts
index 31f7909d8..087ec271f 100644
--- a/imxweb/projects/pol/src/public_api.ts
+++ b/imxweb/projects/pol/src/public_api.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -30,3 +30,8 @@
export { PolConfigModule } from './lib/pol-config.module';
export { ApiService } from './lib/api.service';
+export { PolicyViolationsModule } from './lib/policy-violations/policy-violations.module';
+export { PolicyViolationsComponent } from './lib/policy-violations/policy-violations.component';
+export { PolicyViolationApproverGuardService } from './lib/guards/policy-violation-approver-guard.service';
+export { PermissionsService } from './lib/admin/permissions.service';
+
diff --git a/imxweb/projects/pol/src/test.ts b/imxweb/projects/pol/src/test.ts
index 3acb047da..8986070be 100644
--- a/imxweb/projects/pol/src/test.ts
+++ b/imxweb/projects/pol/src/test.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/pol/tsconfig.lib.json b/imxweb/projects/pol/tsconfig.lib.json
index 009b845fc..6bc419f84 100644
--- a/imxweb/projects/pol/tsconfig.lib.json
+++ b/imxweb/projects/pol/tsconfig.lib.json
@@ -1,29 +1,13 @@
+/* To learn more about this file see: https://angular.io/config/tsconfig. */
{
"extends": "../../tsconfig.json",
"compilerOptions": {
"outDir": "../../out-tsc/lib",
- "declarationMap": true,
- "target": "es2015",
- "module": "es2015",
- "moduleResolution": "node",
"declaration": true,
+ "declarationMap": true,
"sourceMap": true,
"inlineSources": true,
- "emitDecoratorMetadata": true,
- "experimentalDecorators": true,
- "importHelpers": true,
- "types": [],
- "lib": [
- "dom",
- "es2018"
- ]
- },
- "angularCompilerOptions": {
- "skipTemplateCodegen": true,
- "strictMetadataEmit": true,
- "fullTemplateTypeCheck": true,
- "strictInjectionParameters": true,
- "enableResourceInlining": true
+ "types": []
},
"exclude": [
"src/test.ts",
diff --git a/imxweb/projects/pol/tsconfig.lib.prod.json b/imxweb/projects/pol/tsconfig.lib.prod.json
index a05c79305..61c7592e7 100644
--- a/imxweb/projects/pol/tsconfig.lib.prod.json
+++ b/imxweb/projects/pol/tsconfig.lib.prod.json
@@ -1,3 +1,4 @@
+/* To learn more about this file see: https://angular.io/config/tsconfig. */
{
"extends": "./tsconfig.lib.json",
"compilerOptions": {
diff --git a/imxweb/projects/qbm-app-landingpage/package.json b/imxweb/projects/qbm-app-landingpage/package.json
index 9dc5b7e29..c89733803 100644
--- a/imxweb/projects/qbm-app-landingpage/package.json
+++ b/imxweb/projects/qbm-app-landingpage/package.json
@@ -1,6 +1,6 @@
{
"name": "qbm-app-landingpage",
- "version": "8.2.0",
+ "version": "9.0.0",
"private": true,
"peerDependencies": {
diff --git a/imxweb/projects/qbm-app-landingpage/src/app/app-routing.module.ts b/imxweb/projects/qbm-app-landingpage/src/app/app-routing.module.ts
index 8575bf2a1..1daa97857 100644
--- a/imxweb/projects/qbm-app-landingpage/src/app/app-routing.module.ts
+++ b/imxweb/projects/qbm-app-landingpage/src/app/app-routing.module.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm-app-landingpage/src/app/app.component.spec.ts b/imxweb/projects/qbm-app-landingpage/src/app/app.component.spec.ts
index 5da87d5a5..5de301ebd 100644
--- a/imxweb/projects/qbm-app-landingpage/src/app/app.component.spec.ts
+++ b/imxweb/projects/qbm-app-landingpage/src/app/app.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm-app-landingpage/src/app/app.component.ts b/imxweb/projects/qbm-app-landingpage/src/app/app.component.ts
index c8ed07496..2618feafc 100644
--- a/imxweb/projects/qbm-app-landingpage/src/app/app.component.ts
+++ b/imxweb/projects/qbm-app-landingpage/src/app/app.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm-app-landingpage/src/app/app.module.ts b/imxweb/projects/qbm-app-landingpage/src/app/app.module.ts
index 6d1e80ba4..9bb4fa1b6 100644
--- a/imxweb/projects/qbm-app-landingpage/src/app/app.module.ts
+++ b/imxweb/projects/qbm-app-landingpage/src/app/app.module.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -29,7 +29,7 @@ import { NgModule, APP_INITIALIZER, ErrorHandler } from '@angular/core';
import { BrowserAnimationsModule } from '@angular/platform-browser/animations';
import { HttpClientModule } from '@angular/common/http';
import { MatCardModule } from '@angular/material/card';
-import { EuiMaterialModule } from '@elemental-ui/core';
+import { EuiCoreModule, EuiMaterialModule } from '@elemental-ui/core';
import { TranslateModule, TranslateLoader, MissingTranslationHandler } from '@ngx-translate/core';
import { LoggerModule, NgxLoggerLevel } from 'ngx-logger';
@@ -66,6 +66,7 @@ import appConfigJson from '../appconfig.json';
AuthenticationModule,
BrowserAnimationsModule,
BrowserModule,
+ EuiCoreModule,
EuiMaterialModule,
HttpClientModule,
MastHeadModule,
diff --git a/imxweb/projects/qbm-app-landingpage/src/app/app.service.spec.ts b/imxweb/projects/qbm-app-landingpage/src/app/app.service.spec.ts
index 66a144812..7d7a5d967 100644
--- a/imxweb/projects/qbm-app-landingpage/src/app/app.service.spec.ts
+++ b/imxweb/projects/qbm-app-landingpage/src/app/app.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm-app-landingpage/src/app/app.service.ts b/imxweb/projects/qbm-app-landingpage/src/app/app.service.ts
index b69276053..e7de07be9 100644
--- a/imxweb/projects/qbm-app-landingpage/src/app/app.service.ts
+++ b/imxweb/projects/qbm-app-landingpage/src/app/app.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm-app-landingpage/src/app/appcontainer.service.spec.ts b/imxweb/projects/qbm-app-landingpage/src/app/appcontainer.service.spec.ts
index fb45c83b2..e24b95e7e 100644
--- a/imxweb/projects/qbm-app-landingpage/src/app/appcontainer.service.spec.ts
+++ b/imxweb/projects/qbm-app-landingpage/src/app/appcontainer.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm-app-landingpage/src/app/appcontainer.service.ts b/imxweb/projects/qbm-app-landingpage/src/app/appcontainer.service.ts
index a0a70714a..d23348c94 100644
--- a/imxweb/projects/qbm-app-landingpage/src/app/appcontainer.service.ts
+++ b/imxweb/projects/qbm-app-landingpage/src/app/appcontainer.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm-app-landingpage/src/app/start/start.component.spec.ts b/imxweb/projects/qbm-app-landingpage/src/app/start/start.component.spec.ts
index a03837ddf..6de15f5c9 100644
--- a/imxweb/projects/qbm-app-landingpage/src/app/start/start.component.spec.ts
+++ b/imxweb/projects/qbm-app-landingpage/src/app/start/start.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm-app-landingpage/src/app/start/start.component.ts b/imxweb/projects/qbm-app-landingpage/src/app/start/start.component.ts
index 8e8a9a52e..c2df4382e 100644
--- a/imxweb/projects/qbm-app-landingpage/src/app/start/start.component.ts
+++ b/imxweb/projects/qbm-app-landingpage/src/app/start/start.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm-app-landingpage/src/app/swagger/swagger.component.scss b/imxweb/projects/qbm-app-landingpage/src/app/swagger/swagger.component.scss
index 4e260749b..986094494 100644
--- a/imxweb/projects/qbm-app-landingpage/src/app/swagger/swagger.component.scss
+++ b/imxweb/projects/qbm-app-landingpage/src/app/swagger/swagger.component.scss
@@ -1,4 +1,4 @@
-@import "~@elemental-ui/core/src/styles/_palette.scss";
+@import '@elemental-ui/core/src/styles/_palette.scss';
:host {
overflow: auto;
diff --git a/imxweb/projects/qbm-app-landingpage/src/app/swagger/swagger.component.spec.ts b/imxweb/projects/qbm-app-landingpage/src/app/swagger/swagger.component.spec.ts
index 2854b0f17..63327ef67 100644
--- a/imxweb/projects/qbm-app-landingpage/src/app/swagger/swagger.component.spec.ts
+++ b/imxweb/projects/qbm-app-landingpage/src/app/swagger/swagger.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm-app-landingpage/src/app/swagger/swagger.component.ts b/imxweb/projects/qbm-app-landingpage/src/app/swagger/swagger.component.ts
index 89293af45..b313d98f1 100644
--- a/imxweb/projects/qbm-app-landingpage/src/app/swagger/swagger.component.ts
+++ b/imxweb/projects/qbm-app-landingpage/src/app/swagger/swagger.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm-app-landingpage/src/environments/environment.prod.ts b/imxweb/projects/qbm-app-landingpage/src/environments/environment.prod.ts
index 8fad6cf3b..52a93e138 100644
--- a/imxweb/projects/qbm-app-landingpage/src/environments/environment.prod.ts
+++ b/imxweb/projects/qbm-app-landingpage/src/environments/environment.prod.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm-app-landingpage/src/environments/environment.ts b/imxweb/projects/qbm-app-landingpage/src/environments/environment.ts
index 3009fb675..32cf6057b 100644
--- a/imxweb/projects/qbm-app-landingpage/src/environments/environment.ts
+++ b/imxweb/projects/qbm-app-landingpage/src/environments/environment.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm-app-landingpage/src/main.ts b/imxweb/projects/qbm-app-landingpage/src/main.ts
index a179beaf4..a3b8c0c08 100644
--- a/imxweb/projects/qbm-app-landingpage/src/main.ts
+++ b/imxweb/projects/qbm-app-landingpage/src/main.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm-app-landingpage/src/polyfills.ts b/imxweb/projects/qbm-app-landingpage/src/polyfills.ts
index c478f53e2..9abe86b1e 100644
--- a/imxweb/projects/qbm-app-landingpage/src/polyfills.ts
+++ b/imxweb/projects/qbm-app-landingpage/src/polyfills.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -56,12 +56,17 @@
// Used for reflect-metadata in JIT. If you use AOT (and only Angular decorators), you can remove.
import 'core-js/es7/reflect';
+// Used for support array.includes
+import 'core-js/es7/array';
+
+// Used for support object.values
+import 'core-js/es7/object';
/**
* Required to support Web Animations `@angular/platform-browser/animations`.
* Needed for: All but Chrome, Firefox and Opera. http://caniuse.com/#feat=web-animation
*/
-// import 'web-animations-js'; // Run `npm install --save web-animations-js`.
+import 'web-animations-js';
diff --git a/imxweb/projects/qbm-app-landingpage/src/styles.scss b/imxweb/projects/qbm-app-landingpage/src/styles.scss
index 34afc2f35..321a29c3a 100644
--- a/imxweb/projects/qbm-app-landingpage/src/styles.scss
+++ b/imxweb/projects/qbm-app-landingpage/src/styles.scss
@@ -1,7 +1,8 @@
/* You can add global styles to this file, and also import other style files */
+@use '@angular/material' as mat;
-$material_icons_font_path: "~@elemental-ui/core/assets/MaterialIcons";
-$cadence_font_path: "~@elemental-ui/cadence-icon/dist";
-$source_sans_pro_font_path: "~@elemental-ui/core/assets/Source_Sans_Pro";
+$material_icons_font_path: "~node_modules/@elemental-ui/core/assets/MaterialIcons";
+$cadence_font_path: "~node_modules/@elemental-ui/core/assets/Cadence";
+$source_sans_pro_font_path: "~node_modules/@elemental-ui/core/assets/Source_Sans_Pro";
-@import '~@elemental-ui/core/src/styles/core.scss';
+@import '@elemental-ui/core/src/styles/core.scss';
diff --git a/imxweb/projects/qbm-app-landingpage/src/test.ts b/imxweb/projects/qbm-app-landingpage/src/test.ts
index 9b3203350..3a63345a3 100644
--- a/imxweb/projects/qbm-app-landingpage/src/test.ts
+++ b/imxweb/projects/qbm-app-landingpage/src/test.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/legalStuff.md b/imxweb/projects/qbm/legalStuff.md
deleted file mode 100644
index f6fc65436..000000000
--- a/imxweb/projects/qbm/legalStuff.md
+++ /dev/null
@@ -1 +0,0 @@
-# Legal QBM stuff.
diff --git a/imxweb/projects/qbm/package.json b/imxweb/projects/qbm/package.json
index c63ff5195..5f5f1ee0e 100644
--- a/imxweb/projects/qbm/package.json
+++ b/imxweb/projects/qbm/package.json
@@ -1,6 +1,6 @@
{
"name": "qbm",
- "version": "8.2.0",
+ "version": "9.0.0",
"private": true,
"dependencies": {
diff --git a/imxweb/projects/qbm/src/lib/about/About.component.html b/imxweb/projects/qbm/src/lib/about/About.component.html
index e35285277..00dd8dbbb 100644
--- a/imxweb/projects/qbm/src/lib/about/About.component.html
+++ b/imxweb/projects/qbm/src/lib/about/About.component.html
@@ -3,7 +3,7 @@
-
+
{{ product['Name'] }}
diff --git a/imxweb/projects/qbm/src/lib/about/About.component.spec.ts b/imxweb/projects/qbm/src/lib/about/About.component.spec.ts
index d93991377..ae0fcea98 100644
--- a/imxweb/projects/qbm/src/lib/about/About.component.spec.ts
+++ b/imxweb/projects/qbm/src/lib/about/About.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/about/About.component.ts b/imxweb/projects/qbm/src/lib/about/About.component.ts
index 25d1efd65..b6008d915 100644
--- a/imxweb/projects/qbm/src/lib/about/About.component.ts
+++ b/imxweb/projects/qbm/src/lib/about/About.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -62,33 +62,33 @@ export class AboutComponent implements OnInit {
) {
this.entitySchema = aboutInfoService.EntitySchema;
this.displayedColumns = [
- this.entitySchema.Columns.ComponentName,
- this.entitySchema.Columns.CopyRight,
- this.entitySchema.Columns.EmailOrURl,
- this.entitySchema.Columns.LicenceName
+ this.entitySchema.Columns['ComponentName'],
+ this.entitySchema.Columns['CopyRight'],
+ this.entitySchema.Columns['EmailOrURl'],
+ this.entitySchema.Columns['LicenceName']
];
- this.product.Name = Globals.QIM_ProductNameFull;
- this.product.Version = Globals.Version;
- this.product.Copyright = Globals.QBM_Copyright;
+ this.product['Name'] = Globals.QIM_ProductNameFull;
+ this.product['Version'] = Globals.Version;
+ this.product['Copyright'] = Globals.QBM_Copyright;
- this.product.ThirdPartyLicencesUrl = 'https://www.oneidentity.com/legal/third-party-licenses.aspx';
- this.product.OpenSourceUrl = 'https://opensource.quest.com';
- this.product.ContactUrl = 'https://www.oneidentity.com/company/contact-us.aspx';
- this.product.ProductSupportPortalUrl = 'https://support.oneidentity.com/';
- this.product.ProductPageUrl = 'https://www.oneidentity.com/products/identity-manager/';
+ this.product['ThirdPartyLicencesUrl'] = 'https://www.oneidentity.com/legal/third-party-licenses.aspx';
+ this.product['OpenSourceUrl'] = 'https://opensource.quest.com';
+ this.product['ContactUrl'] = 'https://www.oneidentity.com/company/contact-us.aspx';
+ this.product['ProductSupportPortalUrl'] = 'https://support.oneidentity.com/';
+ this.product['ProductPageUrl'] = 'https://www.oneidentity.com/products/identity-manager/';
}
public async ngOnInit(): Promise {
const imxConfig = await this.config.getImxConfig();
const name = imxConfig.ProductName;
if (name)
- this.product.Name = name;
+ this.product['Name'] = name;
await this.update({ PageSize: this.settings.DefaultPageSize, StartIndex: 0, OrderBy: 'ComponentName' });
}
public ShowSystemOverviewTab(): boolean {
- return this.extService.Registry.SystemOverview && this.extService.Registry.SystemOverview.length > 0;
+ return this.extService.Registry['SystemOverview'] && this.extService.Registry['SystemOverview'].length > 0;
}
public async update(parameters?: CollectionLoadParameters): Promise {
diff --git a/imxweb/projects/qbm/src/lib/about/About.service.spec.ts b/imxweb/projects/qbm/src/lib/about/About.service.spec.ts
index 3616e9518..f5fb37b3a 100644
--- a/imxweb/projects/qbm/src/lib/about/About.service.spec.ts
+++ b/imxweb/projects/qbm/src/lib/about/About.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/about/About.service.ts b/imxweb/projects/qbm/src/lib/about/About.service.ts
index a309e0bd7..17ec7d459 100644
--- a/imxweb/projects/qbm/src/lib/about/About.service.ts
+++ b/imxweb/projects/qbm/src/lib/about/About.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/admin/add-config-sidesheet.component.html b/imxweb/projects/qbm/src/lib/admin/add-config-sidesheet.component.html
index 8f1b4f7c9..3f060e0ce 100644
--- a/imxweb/projects/qbm/src/lib/admin/add-config-sidesheet.component.html
+++ b/imxweb/projects/qbm/src/lib/admin/add-config-sidesheet.component.html
@@ -11,7 +11,7 @@
-
+
{{selectedKey.Description}}
@@ -26,4 +26,4 @@
{{'#LDS#Create' | translate}}
-
\ No newline at end of file
+
diff --git a/imxweb/projects/qbm/src/lib/admin/add-config-sidesheet.component.ts b/imxweb/projects/qbm/src/lib/admin/add-config-sidesheet.component.ts
index 7093c0a9b..be2ac1659 100644
--- a/imxweb/projects/qbm/src/lib/admin/add-config-sidesheet.component.ts
+++ b/imxweb/projects/qbm/src/lib/admin/add-config-sidesheet.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/admin/admin-component.interface.ts b/imxweb/projects/qbm/src/lib/admin/admin-component.interface.ts
index d1eed0056..6f18d1be1 100644
--- a/imxweb/projects/qbm/src/lib/admin/admin-component.interface.ts
+++ b/imxweb/projects/qbm/src/lib/admin/admin-component.interface.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/admin/admin-routes.ts b/imxweb/projects/qbm/src/lib/admin/admin-routes.ts
index 1ec794742..607fa1db8 100644
--- a/imxweb/projects/qbm/src/lib/admin/admin-routes.ts
+++ b/imxweb/projects/qbm/src/lib/admin/admin-routes.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/admin/admin.module.ts b/imxweb/projects/qbm/src/lib/admin/admin.module.ts
index 47f1492c4..399c4975c 100644
--- a/imxweb/projects/qbm/src/lib/admin/admin.module.ts
+++ b/imxweb/projects/qbm/src/lib/admin/admin.module.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/admin/apply-config-sidesheet.component.html b/imxweb/projects/qbm/src/lib/admin/apply-config-sidesheet.component.html
index f7242566f..14d86b612 100644
--- a/imxweb/projects/qbm/src/lib/admin/apply-config-sidesheet.component.html
+++ b/imxweb/projects/qbm/src/lib/admin/apply-config-sidesheet.component.html
@@ -1,7 +1,7 @@
-
+ {{'#LDS#You have changed the following configuration settings.' | translate}}
{{'#LDS#Select how the configuration changes should be applied.' | translate}}
@@ -28,4 +28,4 @@
{{'#LDS#Apply' | translate}}
-
\ No newline at end of file
+
diff --git a/imxweb/projects/qbm/src/lib/admin/apply-config-sidesheet.component.scss b/imxweb/projects/qbm/src/lib/admin/apply-config-sidesheet.component.scss
index b3d957323..ab1bedd45 100644
--- a/imxweb/projects/qbm/src/lib/admin/apply-config-sidesheet.component.scss
+++ b/imxweb/projects/qbm/src/lib/admin/apply-config-sidesheet.component.scss
@@ -1,4 +1,4 @@
-@import "~@elemental-ui/core/src/styles/_palette.scss";
+@import "@elemental-ui/core/src/styles/_palette.scss";
.admin-config-apply-sidesheet {
background-color: $asher-gray;
diff --git a/imxweb/projects/qbm/src/lib/admin/apply-config-sidesheet.component.ts b/imxweb/projects/qbm/src/lib/admin/apply-config-sidesheet.component.ts
index 7f5c5f54a..c721a378c 100644
--- a/imxweb/projects/qbm/src/lib/admin/apply-config-sidesheet.component.ts
+++ b/imxweb/projects/qbm/src/lib/admin/apply-config-sidesheet.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/admin/config-key-path.component.scss b/imxweb/projects/qbm/src/lib/admin/config-key-path.component.scss
index 1e926879a..b6812b34d 100644
--- a/imxweb/projects/qbm/src/lib/admin/config-key-path.component.scss
+++ b/imxweb/projects/qbm/src/lib/admin/config-key-path.component.scss
@@ -1,5 +1,5 @@
-@import "~@elemental-ui/core/src/styles/_palette.scss";
-
+@import "@elemental-ui/core/src/styles/_palette.scss";
+
.key-path-separator {
margin: 0 .15em;
color: $black-9;
diff --git a/imxweb/projects/qbm/src/lib/admin/config-key-path.component.ts b/imxweb/projects/qbm/src/lib/admin/config-key-path.component.ts
index ba9359f20..481c4fb56 100644
--- a/imxweb/projects/qbm/src/lib/admin/config-key-path.component.ts
+++ b/imxweb/projects/qbm/src/lib/admin/config-key-path.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/admin/config-section.ts b/imxweb/projects/qbm/src/lib/admin/config-section.ts
index 3a433300d..a8bf55a95 100644
--- a/imxweb/projects/qbm/src/lib/admin/config-section.ts
+++ b/imxweb/projects/qbm/src/lib/admin/config-section.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/admin/config.component.html b/imxweb/projects/qbm/src/lib/admin/config.component.html
index 0baf4e210..c831ab911 100644
--- a/imxweb/projects/qbm/src/lib/admin/config.component.html
+++ b/imxweb/projects/qbm/src/lib/admin/config.component.html
@@ -46,7 +46,9 @@
#LDS#Configuration
{{'#LDS#Create configuration key' | translate}}
-
{{ 'No configuration settings were found.' | translate}}
+
+ {{ 'No configuration settings were found.' | translate}}
+
{{ section.Title }}
diff --git a/imxweb/projects/qbm/src/lib/admin/config.component.scss b/imxweb/projects/qbm/src/lib/admin/config.component.scss
index 7acc1a351..8739479b1 100644
--- a/imxweb/projects/qbm/src/lib/admin/config.component.scss
+++ b/imxweb/projects/qbm/src/lib/admin/config.component.scss
@@ -1,5 +1,5 @@
@import "variables.scss";
-@import "~@angular/material/theming";
+@import "@angular/material/theming";
:host {
min-width: 800px;
@@ -75,3 +75,18 @@
overflow: auto;
}
+.no-results {
+ text-align: center;
+ margin: 20px 0;
+
+ .eui-icon {
+ font-size: 100px;
+ color: rgba($black-c, 0.55);
+ }
+
+ p {
+ margin: 0;
+ font-size: 18px;
+ color: $black-9;
+ }
+}
\ No newline at end of file
diff --git a/imxweb/projects/qbm/src/lib/admin/config.component.ts b/imxweb/projects/qbm/src/lib/admin/config.component.ts
index a0ee8420d..39d5b0e8f 100644
--- a/imxweb/projects/qbm/src/lib/admin/config.component.ts
+++ b/imxweb/projects/qbm/src/lib/admin/config.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -27,7 +27,7 @@
import { Component } from '@angular/core';
import { EuiSidesheetService } from '@elemental-ui/core';
import { TranslateService } from '@ngx-translate/core';
-import { ConfigNodeData, ConfigSettingType } from 'imx-api-qbm';
+import { ConfigSettingType } from 'imx-api-qbm';
import { AppConfigService } from '../appConfig/appConfig.service';
import { DataSourceToolbarSettings } from '../data-source-toolbar/data-source-toolbar-settings';
import { AddConfigSidesheetComponent } from './add-config-sidesheet.component';
@@ -85,6 +85,8 @@ export class ConfigComponent {
}
};
+ this.configSvc.filter.keywords = null;
+
this.apiProjects = (await this.appConfigSvc.client.admin_projects_get()).map(x => x.AppId);
if (this.apiProjects.length > 0) {
this.optionSelected(this.apiProjects[0]);
diff --git a/imxweb/projects/qbm/src/lib/admin/config.service.ts b/imxweb/projects/qbm/src/lib/admin/config.service.ts
index 78023265c..ca6c70076 100644
--- a/imxweb/projects/qbm/src/lib/admin/config.service.ts
+++ b/imxweb/projects/qbm/src/lib/admin/config.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -127,7 +127,7 @@ export class ConfigService {
const confObj = {};
// setting to null value, meaning: revert
confObj[conf.Path] = null;
- await this.session.Client.admin_apiconfig_post(this.appId, !conf.HasCustomLocalValue, confObj);
+ await this.session.Client.admin_apiconfig_post(this.appId, confObj, { global: !conf.HasCustomLocalValue });
delete this.pendingChanges[this.appId];
// reload all to get the effective value. there is no good way to get just
@@ -141,7 +141,7 @@ export class ConfigService {
Message: '#LDS#Are you sure you want to reset all customized configuration values?',
identifier: 'config-confirm-reset-configuration'
})) {
- await this.session.Client.admin_apiconfig_revert_post(this.appId, isGlobal);
+ await this.session.Client.admin_apiconfig_revert_post(this.appId, { global: isGlobal });
delete this.pendingChanges[this.appId];
this.load();
}
@@ -160,7 +160,7 @@ export class ConfigService {
}
for (let appId in this.pendingChanges) {
- await this.session.Client.admin_apiconfig_post(appId, isGlobal, changeObj);
+ await this.session.Client.admin_apiconfig_post(appId, changeObj, { global: isGlobal });
}
this.pendingChanges = {};
this.load();
@@ -219,6 +219,7 @@ export class ConfigService {
const thisPath = path + node.Key;
for (const n of node.Settings) {
const searchTerms = [
+ ...displayPath.map(d => d?.toLowerCase()),
n.Name?.toLowerCase(),
n.Key?.toLowerCase(),
n.Description?.toLowerCase()
diff --git a/imxweb/projects/qbm/src/lib/admin/convert-config-sidesheet.component.html b/imxweb/projects/qbm/src/lib/admin/convert-config-sidesheet.component.html
index 94f3bc4ea..012d3e65a 100644
--- a/imxweb/projects/qbm/src/lib/admin/convert-config-sidesheet.component.html
+++ b/imxweb/projects/qbm/src/lib/admin/convert-config-sidesheet.component.html
@@ -1,7 +1,7 @@
\ No newline at end of file
+
diff --git a/imxweb/projects/qbm/src/lib/admin/convert-config-sidesheet.component.scss b/imxweb/projects/qbm/src/lib/admin/convert-config-sidesheet.component.scss
index 2c9535bf8..93585a4f6 100644
--- a/imxweb/projects/qbm/src/lib/admin/convert-config-sidesheet.component.scss
+++ b/imxweb/projects/qbm/src/lib/admin/convert-config-sidesheet.component.scss
@@ -1,4 +1,4 @@
-@import "~@elemental-ui/core/src/styles/_palette.scss";
+@import "@elemental-ui/core/src/styles/_palette.scss";
ul {
margin: 1em;
diff --git a/imxweb/projects/qbm/src/lib/admin/convert-config-sidesheet.component.ts b/imxweb/projects/qbm/src/lib/admin/convert-config-sidesheet.component.ts
index f24cfa726..c750ad113 100644
--- a/imxweb/projects/qbm/src/lib/admin/convert-config-sidesheet.component.ts
+++ b/imxweb/projects/qbm/src/lib/admin/convert-config-sidesheet.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/admin/dashboard.component.scss b/imxweb/projects/qbm/src/lib/admin/dashboard.component.scss
index d0975716d..2ae4b9365 100644
--- a/imxweb/projects/qbm/src/lib/admin/dashboard.component.scss
+++ b/imxweb/projects/qbm/src/lib/admin/dashboard.component.scss
@@ -1,4 +1,4 @@
-@import '~@elemental-ui/core/src/styles/_palette.scss';
+@import '@elemental-ui/core/src/styles/_palette.scss';
:host {
height: 100%;
diff --git a/imxweb/projects/qbm/src/lib/admin/dashboard.component.ts b/imxweb/projects/qbm/src/lib/admin/dashboard.component.ts
index 9428abeef..e0d2abd55 100644
--- a/imxweb/projects/qbm/src/lib/admin/dashboard.component.ts
+++ b/imxweb/projects/qbm/src/lib/admin/dashboard.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/admin/list-setting.component.ts b/imxweb/projects/qbm/src/lib/admin/list-setting.component.ts
index 9e95db8b8..54c1d4e68 100644
--- a/imxweb/projects/qbm/src/lib/admin/list-setting.component.ts
+++ b/imxweb/projects/qbm/src/lib/admin/list-setting.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/admin/packages.component.ts b/imxweb/projects/qbm/src/lib/admin/packages.component.ts
index d737b7039..f9a560ea3 100644
--- a/imxweb/projects/qbm/src/lib/admin/packages.component.ts
+++ b/imxweb/projects/qbm/src/lib/admin/packages.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/admin/select-value.component.ts b/imxweb/projects/qbm/src/lib/admin/select-value.component.ts
index 61b446b33..b2748ae16 100644
--- a/imxweb/projects/qbm/src/lib/admin/select-value.component.ts
+++ b/imxweb/projects/qbm/src/lib/admin/select-value.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/admin/status.component.ts b/imxweb/projects/qbm/src/lib/admin/status.component.ts
index e9072d185..9afac461d 100644
--- a/imxweb/projects/qbm/src/lib/admin/status.component.ts
+++ b/imxweb/projects/qbm/src/lib/admin/status.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/api-client/api-client-angular.service.spec.ts b/imxweb/projects/qbm/src/lib/api-client/api-client-angular.service.spec.ts
index bb40c90a1..69502ade2 100644
--- a/imxweb/projects/qbm/src/lib/api-client/api-client-angular.service.spec.ts
+++ b/imxweb/projects/qbm/src/lib/api-client/api-client-angular.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/api-client/api-client-angular.service.ts b/imxweb/projects/qbm/src/lib/api-client/api-client-angular.service.ts
index f7111f3b2..1c28b0002 100644
--- a/imxweb/projects/qbm/src/lib/api-client/api-client-angular.service.ts
+++ b/imxweb/projects/qbm/src/lib/api-client/api-client-angular.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/api-client/api-client-fetch.spec.ts b/imxweb/projects/qbm/src/lib/api-client/api-client-fetch.spec.ts
index c5296eaeb..801d7e85e 100644
--- a/imxweb/projects/qbm/src/lib/api-client/api-client-fetch.spec.ts
+++ b/imxweb/projects/qbm/src/lib/api-client/api-client-fetch.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -108,7 +108,6 @@ describe('ApiClientFetch', () => {
].forEach(testcase =>
it(`has a method ${method.path}`, async () => {
const client = new ApiClientFetch(
- { handleError: (_: any): void => { } },
'',
{
debug: jasmine.createSpy('debug')
diff --git a/imxweb/projects/qbm/src/lib/api-client/api-client-fetch.ts b/imxweb/projects/qbm/src/lib/api-client/api-client-fetch.ts
index 43338142f..26eec80db 100644
--- a/imxweb/projects/qbm/src/lib/api-client/api-client-fetch.ts
+++ b/imxweb/projects/qbm/src/lib/api-client/api-client-fetch.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -24,8 +24,6 @@
*
*/
-import { ErrorHandler } from '@angular/core';
-
import { MethodDefinition, MethodDescriptor, ApiClient } from 'imx-qbm-dbts';
import { ServerExceptionError } from '../base/server-exception-error';
import { ServerError } from '../base/server-error';
@@ -33,26 +31,13 @@ import { ClassloggerService } from '../classlogger/classlogger.service';
import { TranslateService } from '@ngx-translate/core';
export class ApiClientFetch implements ApiClient {
- constructor(private readonly errorHandler: ErrorHandler,
+ constructor(
private readonly baseUrl: string = '',
- logger: ClassloggerService,
+ private readonly logger: ClassloggerService,
private readonly translation: TranslateService,
private readonly http: { fetch(input: RequestInfo, init?: RequestInit): Promise } = window) {
-
- // is API running on same host than the web app?
- const apiHost = baseUrl ? new URL(baseUrl).host : null;
- const htmlHost = window.location.host;
- this.xsrfProtectionEnabled = !baseUrl || apiHost == htmlHost;
- if (this.xsrfProtectionEnabled) {
- logger.debug(this, "XSRF protection token is active for this session.");
- }
- else {
- logger.info(this, `XSRF protection is not enabled for this session (API host=${apiHost} HTML host=${htmlHost})`);
- }
}
- private readonly xsrfProtectionEnabled: boolean;
-
public async processRequest(methodDescriptor: MethodDescriptor): Promise {
const method = new MethodDefinition(methodDescriptor);
const headers = new Headers(method.headers);
@@ -67,11 +52,8 @@ export class ApiClientFetch implements ApiClient {
headers: headers,
body: method.body
});
- } catch {
- this.errorHandler.handleError(new ServerError(await this.GetUnexpectedErrorText()));
-
-//TODO: or throw?
- return null;
+ } catch (e) {
+ throw new ServerError(await this.GetUnexpectedErrorText());
}
if (response) {
@@ -103,9 +85,7 @@ export class ApiClientFetch implements ApiClient {
throw new ServerExceptionError(await response.json());
}
- this.errorHandler.handleError(new ServerError(await this.GetUnexpectedErrorText()));
- //TODO: or throw?
- return null;
+ throw new ServerError(await this.GetUnexpectedErrorText());
}
private append(input: string, statusText: string): string {
@@ -125,15 +105,9 @@ export class ApiClientFetch implements ApiClient {
private addXsrfProtectionHeader(headers: Headers, method: MethodDefinition) {
// Sending XSRF-TOKEN as an additional header, if:
// - there is one
- // - the base URL is not set or equivalent to window.location.origin (XSRF protection does not work across domains)
// - the request is not a GET or HEAD request (which does not require XSRF protection)
- if (!this.xsrfProtectionEnabled) {
- // when connecting to an API server on a different domain, XSRF protection cookies
- // do not work -> requesting that the server emits no protection cookie
- headers.set("X-NO-XSRF", "true");
- }
- else if (document.cookie && !["GET", "HEAD"].includes(method.httpMethod.toUpperCase())) {
+ if (document.cookie && !["GET", "HEAD"].includes(method.httpMethod.toUpperCase())) {
const token = this.getCookie("XSRF-TOKEN");
if (token) {
headers.set("X-XSRF-TOKEN", token);
diff --git a/imxweb/projects/qbm/src/lib/api-client/api-client.service.spec.ts b/imxweb/projects/qbm/src/lib/api-client/api-client.service.spec.ts
index 9b94b53a8..12c37c334 100644
--- a/imxweb/projects/qbm/src/lib/api-client/api-client.service.spec.ts
+++ b/imxweb/projects/qbm/src/lib/api-client/api-client.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/api-client/api-client.service.ts b/imxweb/projects/qbm/src/lib/api-client/api-client.service.ts
index 7111e1399..d6a1497d8 100644
--- a/imxweb/projects/qbm/src/lib/api-client/api-client.service.ts
+++ b/imxweb/projects/qbm/src/lib/api-client/api-client.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/api-client/api-client.spec.ts b/imxweb/projects/qbm/src/lib/api-client/api-client.spec.ts
index b6ff6deeb..94859d9f2 100644
--- a/imxweb/projects/qbm/src/lib/api-client/api-client.spec.ts
+++ b/imxweb/projects/qbm/src/lib/api-client/api-client.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/api-client/dynamic-method.ts b/imxweb/projects/qbm/src/lib/api-client/dynamic-method.ts
index 4a736c53c..99d2b9c9e 100644
--- a/imxweb/projects/qbm/src/lib/api-client/dynamic-method.ts
+++ b/imxweb/projects/qbm/src/lib/api-client/dynamic-method.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/api-client/dynamic-method/dynamic-collection-load-parameters.interface.ts b/imxweb/projects/qbm/src/lib/api-client/dynamic-method/dynamic-collection-load-parameters.interface.ts
index 130690d49..e56401023 100644
--- a/imxweb/projects/qbm/src/lib/api-client/dynamic-method/dynamic-collection-load-parameters.interface.ts
+++ b/imxweb/projects/qbm/src/lib/api-client/dynamic-method/dynamic-collection-load-parameters.interface.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/api-client/dynamic-method/dynamic-method-type-wrapper.interface.ts b/imxweb/projects/qbm/src/lib/api-client/dynamic-method/dynamic-method-type-wrapper.interface.ts
index 748b462a1..3bc32c0d7 100644
--- a/imxweb/projects/qbm/src/lib/api-client/dynamic-method/dynamic-method-type-wrapper.interface.ts
+++ b/imxweb/projects/qbm/src/lib/api-client/dynamic-method/dynamic-method-type-wrapper.interface.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/api-client/dynamic-method/dynamic-method.service.spec.ts b/imxweb/projects/qbm/src/lib/api-client/dynamic-method/dynamic-method.service.spec.ts
index f8e1a6cc0..228d6a462 100644
--- a/imxweb/projects/qbm/src/lib/api-client/dynamic-method/dynamic-method.service.spec.ts
+++ b/imxweb/projects/qbm/src/lib/api-client/dynamic-method/dynamic-method.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/api-client/dynamic-method/dynamic-method.service.ts b/imxweb/projects/qbm/src/lib/api-client/dynamic-method/dynamic-method.service.ts
index e2042549a..63611221b 100644
--- a/imxweb/projects/qbm/src/lib/api-client/dynamic-method/dynamic-method.service.ts
+++ b/imxweb/projects/qbm/src/lib/api-client/dynamic-method/dynamic-method.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/api-client/dynamic-method/interactive-parameter.interface.ts b/imxweb/projects/qbm/src/lib/api-client/dynamic-method/interactive-parameter.interface.ts
index 0241a0f0d..f9d125ba3 100644
--- a/imxweb/projects/qbm/src/lib/api-client/dynamic-method/interactive-parameter.interface.ts
+++ b/imxweb/projects/qbm/src/lib/api-client/dynamic-method/interactive-parameter.interface.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/api-client/dynamic-method/method-descriptor.service.spec.ts b/imxweb/projects/qbm/src/lib/api-client/dynamic-method/method-descriptor.service.spec.ts
index 11fd38b8a..7cf54d6fa 100644
--- a/imxweb/projects/qbm/src/lib/api-client/dynamic-method/method-descriptor.service.spec.ts
+++ b/imxweb/projects/qbm/src/lib/api-client/dynamic-method/method-descriptor.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/api-client/dynamic-method/method-descriptor.service.ts b/imxweb/projects/qbm/src/lib/api-client/dynamic-method/method-descriptor.service.ts
index 57c65aafd..efaad7ce6 100644
--- a/imxweb/projects/qbm/src/lib/api-client/dynamic-method/method-descriptor.service.ts
+++ b/imxweb/projects/qbm/src/lib/api-client/dynamic-method/method-descriptor.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/api-client/dynamic-method/typed-entity-builder.service.spec.ts b/imxweb/projects/qbm/src/lib/api-client/dynamic-method/typed-entity-builder.service.spec.ts
index fcd531c68..f5805b5ac 100644
--- a/imxweb/projects/qbm/src/lib/api-client/dynamic-method/typed-entity-builder.service.spec.ts
+++ b/imxweb/projects/qbm/src/lib/api-client/dynamic-method/typed-entity-builder.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/api-client/dynamic-method/typed-entity-builder.service.ts b/imxweb/projects/qbm/src/lib/api-client/dynamic-method/typed-entity-builder.service.ts
index dcffa16e6..3b9f10401 100644
--- a/imxweb/projects/qbm/src/lib/api-client/dynamic-method/typed-entity-builder.service.ts
+++ b/imxweb/projects/qbm/src/lib/api-client/dynamic-method/typed-entity-builder.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/appConfig/appConfig.service.ts b/imxweb/projects/qbm/src/lib/appConfig/appConfig.service.ts
index 084557659..f0a27b95f 100644
--- a/imxweb/projects/qbm/src/lib/appConfig/appConfig.service.ts
+++ b/imxweb/projects/qbm/src/lib/appConfig/appConfig.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -27,9 +27,9 @@
import { HttpClient } from '@angular/common/http';
import { Injectable, ErrorHandler, Injector } from '@angular/core';
-import { AppConfig } from './appConfig.interface';
+import { AppConfig } from './appconfig.interface';
import { ApiClientFetch } from '../api-client/api-client-fetch';
-import { V2Client, Client, ImxConfig } from 'imx-api-qbm';
+import { V2Client, ImxConfig } from 'imx-api-qbm';
import { ClassloggerService } from '../classlogger/classlogger.service';
import { TranslateService } from '@ngx-translate/core';
import { ApiClient } from 'imx-qbm-dbts';
@@ -40,8 +40,7 @@ export class AppConfigService {
public get Config(): AppConfig { return this.config; }
public get BaseUrl(): string { return this.baseUrl; }
- private _client: Client;
- public get client(): Client { return this._client; }
+ public get client(): V2Client { return this._v2client; }
private _v2client: V2Client;
public get v2client(): V2Client { return this._v2client; }
@@ -55,7 +54,6 @@ export class AppConfigService {
constructor(
private readonly httpClient: HttpClient,
private readonly logger: ClassloggerService,
- private readonly errorHandler: ErrorHandler,
private readonly injector: Injector
) { }
@@ -81,9 +79,8 @@ export class AppConfigService {
// avoid cyclic dependency
const translation = this.injector.get(TranslateService);
- this._apiClient = new ApiClientFetch(this.errorHandler, this.baseUrl, this.logger, translation);
- this._client = new Client(this._apiClient);
- this._v2client = new V2Client(this._apiClient, this._client);
+ this._apiClient = new ApiClientFetch(this.baseUrl, this.logger, translation);
+ this._v2client = new V2Client(this._apiClient);
}
diff --git a/imxweb/projects/qbm/src/lib/appConfig/appconfig.interface.ts b/imxweb/projects/qbm/src/lib/appConfig/appconfig.interface.ts
index 72056fe84..d575f782d 100644
--- a/imxweb/projects/qbm/src/lib/appConfig/appconfig.interface.ts
+++ b/imxweb/projects/qbm/src/lib/appConfig/appconfig.interface.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/appConfig/appconfig.service.spec.ts b/imxweb/projects/qbm/src/lib/appConfig/appconfig.service.spec.ts
index 861291ba9..3e2430c04 100644
--- a/imxweb/projects/qbm/src/lib/appConfig/appconfig.service.spec.ts
+++ b/imxweb/projects/qbm/src/lib/appConfig/appconfig.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -29,7 +29,7 @@ import { HttpClient } from '@angular/common/http';
import { configureTestSuite } from 'ng-bullet';
import { of } from 'rxjs';
-import { AppConfig } from './appConfig.interface';
+import { AppConfig } from './appconfig.interface';
import { AppConfigService } from './appConfig.service';
import { ClassloggerService } from '../classlogger/classlogger.service';
diff --git a/imxweb/projects/qbm/src/lib/appConfig/route-config.interface.ts b/imxweb/projects/qbm/src/lib/appConfig/route-config.interface.ts
index 7bd16848e..6b9f5a7a6 100644
--- a/imxweb/projects/qbm/src/lib/appConfig/route-config.interface.ts
+++ b/imxweb/projects/qbm/src/lib/appConfig/route-config.interface.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/appConfig/translationConfiguration.interface.ts b/imxweb/projects/qbm/src/lib/appConfig/translationConfiguration.interface.ts
index 8c88e58f6..357dcd59f 100644
--- a/imxweb/projects/qbm/src/lib/appConfig/translationConfiguration.interface.ts
+++ b/imxweb/projects/qbm/src/lib/appConfig/translationConfiguration.interface.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/authentication/auth-config-provider.interface.ts b/imxweb/projects/qbm/src/lib/authentication/auth-config-provider.interface.ts
index de1b678e2..ebb872956 100644
--- a/imxweb/projects/qbm/src/lib/authentication/auth-config-provider.interface.ts
+++ b/imxweb/projects/qbm/src/lib/authentication/auth-config-provider.interface.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/authentication/authentication-guard.service.spec.ts b/imxweb/projects/qbm/src/lib/authentication/authentication-guard.service.spec.ts
index c1f93f748..2ab11cd20 100644
--- a/imxweb/projects/qbm/src/lib/authentication/authentication-guard.service.spec.ts
+++ b/imxweb/projects/qbm/src/lib/authentication/authentication-guard.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/authentication/authentication-guard.service.ts b/imxweb/projects/qbm/src/lib/authentication/authentication-guard.service.ts
index 1653d1c2a..35b352095 100644
--- a/imxweb/projects/qbm/src/lib/authentication/authentication-guard.service.ts
+++ b/imxweb/projects/qbm/src/lib/authentication/authentication-guard.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/authentication/authentication.module.ts b/imxweb/projects/qbm/src/lib/authentication/authentication.module.ts
index cb4ec6846..a59164d6c 100644
--- a/imxweb/projects/qbm/src/lib/authentication/authentication.module.ts
+++ b/imxweb/projects/qbm/src/lib/authentication/authentication.module.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/authentication/authentication.service.spec.ts b/imxweb/projects/qbm/src/lib/authentication/authentication.service.spec.ts
index 3756ef926..96201c3c4 100644
--- a/imxweb/projects/qbm/src/lib/authentication/authentication.service.spec.ts
+++ b/imxweb/projects/qbm/src/lib/authentication/authentication.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/authentication/authentication.service.ts b/imxweb/projects/qbm/src/lib/authentication/authentication.service.ts
index 78efc7a77..ab6bdbebb 100644
--- a/imxweb/projects/qbm/src/lib/authentication/authentication.service.ts
+++ b/imxweb/projects/qbm/src/lib/authentication/authentication.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -152,7 +152,9 @@ export class AuthenticationService {
}
public registerAuthConfigProvider(authConfig: AuthConfigProvider): void {
- this.providers.push(authConfig);
+ if (this.providers?.length === 0 || this.providers.findIndex(prov => prov.name === authConfig.name) === -1) {
+ this.providers.push(authConfig);
+ }
}
private async handleSessionState(getSessionState: () => Promise): Promise {
diff --git a/imxweb/projects/qbm/src/lib/authentication/custom-auth-flow.interface.ts b/imxweb/projects/qbm/src/lib/authentication/custom-auth-flow.interface.ts
index 5c5b06692..93d44394a 100644
--- a/imxweb/projects/qbm/src/lib/authentication/custom-auth-flow.interface.ts
+++ b/imxweb/projects/qbm/src/lib/authentication/custom-auth-flow.interface.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/authentication/oauth.service.spec.ts b/imxweb/projects/qbm/src/lib/authentication/oauth.service.spec.ts
index 7b0612d11..6d7cc8145 100644
--- a/imxweb/projects/qbm/src/lib/authentication/oauth.service.spec.ts
+++ b/imxweb/projects/qbm/src/lib/authentication/oauth.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/authentication/oauth.service.ts b/imxweb/projects/qbm/src/lib/authentication/oauth.service.ts
index c98d50b8c..f81f82a19 100644
--- a/imxweb/projects/qbm/src/lib/authentication/oauth.service.ts
+++ b/imxweb/projects/qbm/src/lib/authentication/oauth.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -36,19 +36,27 @@ export class OAuthService {
public async GetProviderUrl(authentifier: string): Promise {
const module = '?Module=' + authentifier;
- return this.sessionService.Client.imx_oauth_get(authentifier, this.config.Config.WebAppIndex, window.location.pathname + module);
+ return this.sessionService.Client.imx_oauth_get(authentifier, this.config.Config.WebAppIndex, {
+ redirecturi: window.location.pathname + module
+ });
}
public IsOAuthParameter(name: string): boolean {
return name === 'Module' || name === 'code' || name === 'Code' || name === 'state';
}
+ public hasRequiredOAuthParameter(params: { [key: string]: any }): boolean {
+ const keys = Object.keys(params);
+ // both parameter are required "state" and "code" for OAuth
+ return keys.length > 0 && keys.includes('state') && (keys.includes('Code') || keys.includes('code'));
+ }
+
public convertToOAuthLoginData(loginData: { [key: string]: any }): {
Module: string,
Code: string
} {
- const moduleName = loginData.Module || (new DefaultUrlSerializer()).parse(loginData.state).queryParamMap.get('Module');
- const code = loginData.Code || loginData.code;
+ const moduleName = loginData['Module'] || (new DefaultUrlSerializer()).parse(loginData['state']).queryParamMap.get('Module');
+ const code = loginData['Code'] || loginData['code'];
return moduleName && code ? {
Module: moduleName,
diff --git a/imxweb/projects/qbm/src/lib/authentication/redirect.service.spec.ts b/imxweb/projects/qbm/src/lib/authentication/redirect.service.spec.ts
index c48c4d901..ee29e4c31 100644
--- a/imxweb/projects/qbm/src/lib/authentication/redirect.service.spec.ts
+++ b/imxweb/projects/qbm/src/lib/authentication/redirect.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/authentication/redirect.service.ts b/imxweb/projects/qbm/src/lib/authentication/redirect.service.ts
index d8b7a08c1..f76441153 100644
--- a/imxweb/projects/qbm/src/lib/authentication/redirect.service.ts
+++ b/imxweb/projects/qbm/src/lib/authentication/redirect.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/auto-complete/auto-complete.component.spec.ts b/imxweb/projects/qbm/src/lib/auto-complete/auto-complete.component.spec.ts
index 502bedb16..586d5e81f 100644
--- a/imxweb/projects/qbm/src/lib/auto-complete/auto-complete.component.spec.ts
+++ b/imxweb/projects/qbm/src/lib/auto-complete/auto-complete.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/auto-complete/auto-complete.component.ts b/imxweb/projects/qbm/src/lib/auto-complete/auto-complete.component.ts
index ccf91e79b..bbbfc1318 100644
--- a/imxweb/projects/qbm/src/lib/auto-complete/auto-complete.component.ts
+++ b/imxweb/projects/qbm/src/lib/auto-complete/auto-complete.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/auto-complete/auto-complete.module.ts b/imxweb/projects/qbm/src/lib/auto-complete/auto-complete.module.ts
index 8cda1e70c..fd437be30 100644
--- a/imxweb/projects/qbm/src/lib/auto-complete/auto-complete.module.ts
+++ b/imxweb/projects/qbm/src/lib/auto-complete/auto-complete.module.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/base/Guid.ts b/imxweb/projects/qbm/src/lib/base/Guid.ts
index d9f960548..e667cec37 100644
--- a/imxweb/projects/qbm/src/lib/base/Guid.ts
+++ b/imxweb/projects/qbm/src/lib/base/Guid.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/base/error.service.ts b/imxweb/projects/qbm/src/lib/base/error.service.ts
index 2e6084189..d6cde6362 100644
--- a/imxweb/projects/qbm/src/lib/base/error.service.ts
+++ b/imxweb/projects/qbm/src/lib/base/error.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/base/global-error-handler.spec.ts b/imxweb/projects/qbm/src/lib/base/global-error-handler.spec.ts
index 0a46c65f3..ca85adebe 100644
--- a/imxweb/projects/qbm/src/lib/base/global-error-handler.spec.ts
+++ b/imxweb/projects/qbm/src/lib/base/global-error-handler.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/base/global-error-handler.ts b/imxweb/projects/qbm/src/lib/base/global-error-handler.ts
index 7de00c2c6..60c4556cf 100644
--- a/imxweb/projects/qbm/src/lib/base/global-error-handler.ts
+++ b/imxweb/projects/qbm/src/lib/base/global-error-handler.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/base/ie-warning.service.spec.ts b/imxweb/projects/qbm/src/lib/base/ie-warning.service.spec.ts
index efd84a005..e81d1c79f 100644
--- a/imxweb/projects/qbm/src/lib/base/ie-warning.service.spec.ts
+++ b/imxweb/projects/qbm/src/lib/base/ie-warning.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/base/ie-warning.service.ts b/imxweb/projects/qbm/src/lib/base/ie-warning.service.ts
index ddeb25920..ae57494a4 100644
--- a/imxweb/projects/qbm/src/lib/base/ie-warning.service.ts
+++ b/imxweb/projects/qbm/src/lib/base/ie-warning.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/base/metadata.service.spec.ts b/imxweb/projects/qbm/src/lib/base/metadata.service.spec.ts
index 52e811c93..36b535b0e 100644
--- a/imxweb/projects/qbm/src/lib/base/metadata.service.spec.ts
+++ b/imxweb/projects/qbm/src/lib/base/metadata.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -88,6 +88,6 @@ describe('MetadataService', () => {
await service.updateNonExisting(['dummyTable', 'another table']);
- expect(clientSpy.imx_metadata_table_get).toHaveBeenCalledWith('another table', 'de');
+ expect(clientSpy.imx_metadata_table_get).toHaveBeenCalledWith('another table', { cultureName: 'de' });
});
});
diff --git a/imxweb/projects/qbm/src/lib/base/metadata.service.ts b/imxweb/projects/qbm/src/lib/base/metadata.service.ts
index 11a50a194..40140a44a 100644
--- a/imxweb/projects/qbm/src/lib/base/metadata.service.ts
+++ b/imxweb/projects/qbm/src/lib/base/metadata.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -60,7 +60,7 @@ export class MetadataService {
*/
public async update(tableNames: string[]): Promise {
for (const tableName of tableNames) {
- this.tables[tableName] = await this.sessionService.Client.imx_metadata_table_get(tableName, this.translateService.currentLang);
+ this.tables[tableName] = await this.sessionService.Client.imx_metadata_table_get(tableName, { cultureName: this.translateService.currentLang });
}
}
@@ -72,7 +72,7 @@ export class MetadataService {
if (this.tableMetadata[table] == null) {
this.tableMetadata[
table
- ] = await this.sessionService.Client.imx_metadata_table_get(table, this.translateService.currentLang);
+ ] = await this.sessionService.Client.imx_metadata_table_get(table, { cultureName: this.translateService.currentLang });
}
return this.tableMetadata[table];
diff --git a/imxweb/projects/qbm/src/lib/base/multi-language-captions.ts b/imxweb/projects/qbm/src/lib/base/multi-language-captions.ts
index 0fe7063ad..394c1eb01 100644
--- a/imxweb/projects/qbm/src/lib/base/multi-language-captions.ts
+++ b/imxweb/projects/qbm/src/lib/base/multi-language-captions.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/base/opsupport-db-object.service.spec.ts b/imxweb/projects/qbm/src/lib/base/opsupport-db-object.service.spec.ts
index 8d4f73bcb..696e45c73 100644
--- a/imxweb/projects/qbm/src/lib/base/opsupport-db-object.service.spec.ts
+++ b/imxweb/projects/qbm/src/lib/base/opsupport-db-object.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/base/opsupport-db-object.service.ts b/imxweb/projects/qbm/src/lib/base/opsupport-db-object.service.ts
index e65835511..42454b657 100644
--- a/imxweb/projects/qbm/src/lib/base/opsupport-db-object.service.ts
+++ b/imxweb/projects/qbm/src/lib/base/opsupport-db-object.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/base/paginator.spec.ts b/imxweb/projects/qbm/src/lib/base/paginator.spec.ts
index f6906db35..e0f6e0b8e 100644
--- a/imxweb/projects/qbm/src/lib/base/paginator.spec.ts
+++ b/imxweb/projects/qbm/src/lib/base/paginator.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/base/paginator.ts b/imxweb/projects/qbm/src/lib/base/paginator.ts
index f62ff495c..3705d415d 100644
--- a/imxweb/projects/qbm/src/lib/base/paginator.ts
+++ b/imxweb/projects/qbm/src/lib/base/paginator.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/base/query-parameters-handler.spec.ts b/imxweb/projects/qbm/src/lib/base/query-parameters-handler.spec.ts
index 2e064f127..269faf4cd 100644
--- a/imxweb/projects/qbm/src/lib/base/query-parameters-handler.spec.ts
+++ b/imxweb/projects/qbm/src/lib/base/query-parameters-handler.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/base/query-parameters-handler.ts b/imxweb/projects/qbm/src/lib/base/query-parameters-handler.ts
index 5871cdd6d..68c483e3a 100644
--- a/imxweb/projects/qbm/src/lib/base/query-parameters-handler.ts
+++ b/imxweb/projects/qbm/src/lib/base/query-parameters-handler.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/base/registry.service.spec.ts b/imxweb/projects/qbm/src/lib/base/registry.service.spec.ts
index 1a0c1431e..62df18092 100644
--- a/imxweb/projects/qbm/src/lib/base/registry.service.spec.ts
+++ b/imxweb/projects/qbm/src/lib/base/registry.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/base/registry.service.ts b/imxweb/projects/qbm/src/lib/base/registry.service.ts
index bae2f4fd9..d0e39cae5 100644
--- a/imxweb/projects/qbm/src/lib/base/registry.service.ts
+++ b/imxweb/projects/qbm/src/lib/base/registry.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/base/server-error.ts b/imxweb/projects/qbm/src/lib/base/server-error.ts
index 5f4af353d..bea0b8ebe 100644
--- a/imxweb/projects/qbm/src/lib/base/server-error.ts
+++ b/imxweb/projects/qbm/src/lib/base/server-error.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/base/server-exception-error.ts b/imxweb/projects/qbm/src/lib/base/server-exception-error.ts
index 1e6b38df5..0c4ef563d 100644
--- a/imxweb/projects/qbm/src/lib/base/server-exception-error.ts
+++ b/imxweb/projects/qbm/src/lib/base/server-exception-error.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/base/tab-control-helper.ts b/imxweb/projects/qbm/src/lib/base/tab-control-helper.ts
index 975bf1cb8..74229bed8 100644
--- a/imxweb/projects/qbm/src/lib/base/tab-control-helper.ts
+++ b/imxweb/projects/qbm/src/lib/base/tab-control-helper.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/base/timezone-info.spec.ts b/imxweb/projects/qbm/src/lib/base/timezone-info.spec.ts
index 2c74077d1..26c5b99f2 100644
--- a/imxweb/projects/qbm/src/lib/base/timezone-info.spec.ts
+++ b/imxweb/projects/qbm/src/lib/base/timezone-info.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/base/timezone-info.ts b/imxweb/projects/qbm/src/lib/base/timezone-info.ts
index 5aa4731f9..95abe3596 100644
--- a/imxweb/projects/qbm/src/lib/base/timezone-info.ts
+++ b/imxweb/projects/qbm/src/lib/base/timezone-info.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/base/user-action.service.spec.ts b/imxweb/projects/qbm/src/lib/base/user-action.service.spec.ts
index 33dd23447..a2969b369 100644
--- a/imxweb/projects/qbm/src/lib/base/user-action.service.spec.ts
+++ b/imxweb/projects/qbm/src/lib/base/user-action.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/base/user-action.service.ts b/imxweb/projects/qbm/src/lib/base/user-action.service.ts
index a06939836..b4c755d77 100644
--- a/imxweb/projects/qbm/src/lib/base/user-action.service.ts
+++ b/imxweb/projects/qbm/src/lib/base/user-action.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -28,23 +28,16 @@ import { ErrorHandler, Injectable } from '@angular/core';
@Injectable()
export class UserActionService {
-
- constructor(
- private errorHandler: ErrorHandler) { }
+ constructor(private errorHandler: ErrorHandler) {}
public downloadData(data: string, fileName: string, contentType: string): void {
try {
- if (window.navigator && window.navigator.msSaveOrOpenBlob) {
- const blob = new Blob([data], { type: contentType + ';charset=utf-8;' });
- window.navigator.msSaveOrOpenBlob(blob, fileName);
- } else {
- const link = document.createElement('a');
- link.href = 'data:' + contentType + ',' + encodeURIComponent(data);
- link.download = fileName;
- document.body.appendChild(link);
- link.click();
- document.body.removeChild(link);
- }
+ const link = document.createElement('a');
+ link.href = 'data:' + contentType + ',' + encodeURIComponent(data);
+ link.download = fileName;
+ document.body.appendChild(link);
+ link.click();
+ document.body.removeChild(link);
} catch (error) {
this.errorHandler.handleError(error);
}
diff --git a/imxweb/projects/qbm/src/lib/base/user-agent-helper.ts b/imxweb/projects/qbm/src/lib/base/user-agent-helper.ts
index dfa3383f5..0a62a13b4 100644
--- a/imxweb/projects/qbm/src/lib/base/user-agent-helper.ts
+++ b/imxweb/projects/qbm/src/lib/base/user-agent-helper.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/bulk-property-editor/bulk-item/bulk-item-icon.ts b/imxweb/projects/qbm/src/lib/bulk-property-editor/bulk-item/bulk-item-icon.ts
index 1b4ca53e7..380829bd1 100644
--- a/imxweb/projects/qbm/src/lib/bulk-property-editor/bulk-item/bulk-item-icon.ts
+++ b/imxweb/projects/qbm/src/lib/bulk-property-editor/bulk-item/bulk-item-icon.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/bulk-property-editor/bulk-item/bulk-item.component.scss b/imxweb/projects/qbm/src/lib/bulk-property-editor/bulk-item/bulk-item.component.scss
index 3ee28e11c..191950e7f 100644
--- a/imxweb/projects/qbm/src/lib/bulk-property-editor/bulk-item/bulk-item.component.scss
+++ b/imxweb/projects/qbm/src/lib/bulk-property-editor/bulk-item/bulk-item.component.scss
@@ -1,4 +1,4 @@
-@import '~@elemental-ui/core/src/styles/_palette.scss';
+@import '@elemental-ui/core/src/styles/_palette.scss';
eui-icon {
color: $aspen-green;
diff --git a/imxweb/projects/qbm/src/lib/bulk-property-editor/bulk-item/bulk-item.component.spec.ts b/imxweb/projects/qbm/src/lib/bulk-property-editor/bulk-item/bulk-item.component.spec.ts
index 618f13669..32049b3eb 100644
--- a/imxweb/projects/qbm/src/lib/bulk-property-editor/bulk-item/bulk-item.component.spec.ts
+++ b/imxweb/projects/qbm/src/lib/bulk-property-editor/bulk-item/bulk-item.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/bulk-property-editor/bulk-item/bulk-item.component.ts b/imxweb/projects/qbm/src/lib/bulk-property-editor/bulk-item/bulk-item.component.ts
index 7d97acef6..f961fde02 100644
--- a/imxweb/projects/qbm/src/lib/bulk-property-editor/bulk-item/bulk-item.component.ts
+++ b/imxweb/projects/qbm/src/lib/bulk-property-editor/bulk-item/bulk-item.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/bulk-property-editor/bulk-item/bulk-item.ts b/imxweb/projects/qbm/src/lib/bulk-property-editor/bulk-item/bulk-item.ts
index 25e97342c..0d74bc069 100644
--- a/imxweb/projects/qbm/src/lib/bulk-property-editor/bulk-item/bulk-item.ts
+++ b/imxweb/projects/qbm/src/lib/bulk-property-editor/bulk-item/bulk-item.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/bulk-property-editor/bulk-property-editor.component.spec.ts b/imxweb/projects/qbm/src/lib/bulk-property-editor/bulk-property-editor.component.spec.ts
index 2f39ff9f8..fa6a97458 100644
--- a/imxweb/projects/qbm/src/lib/bulk-property-editor/bulk-property-editor.component.spec.ts
+++ b/imxweb/projects/qbm/src/lib/bulk-property-editor/bulk-property-editor.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/bulk-property-editor/bulk-property-editor.component.ts b/imxweb/projects/qbm/src/lib/bulk-property-editor/bulk-property-editor.component.ts
index 8399c3c36..7a2494ffa 100644
--- a/imxweb/projects/qbm/src/lib/bulk-property-editor/bulk-property-editor.component.ts
+++ b/imxweb/projects/qbm/src/lib/bulk-property-editor/bulk-property-editor.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/bulk-property-editor/bulk-property-editor.module.ts b/imxweb/projects/qbm/src/lib/bulk-property-editor/bulk-property-editor.module.ts
index 5bed0dbfd..4dd988dd4 100644
--- a/imxweb/projects/qbm/src/lib/bulk-property-editor/bulk-property-editor.module.ts
+++ b/imxweb/projects/qbm/src/lib/bulk-property-editor/bulk-property-editor.module.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/captcha/captcha.component.ts b/imxweb/projects/qbm/src/lib/captcha/captcha.component.ts
index 21014ccad..bcce82801 100644
--- a/imxweb/projects/qbm/src/lib/captcha/captcha.component.ts
+++ b/imxweb/projects/qbm/src/lib/captcha/captcha.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/captcha/captcha.module.ts b/imxweb/projects/qbm/src/lib/captcha/captcha.module.ts
index f1cd66ea2..5d40585cc 100644
--- a/imxweb/projects/qbm/src/lib/captcha/captcha.module.ts
+++ b/imxweb/projects/qbm/src/lib/captcha/captcha.module.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/captcha/captcha.service.ts b/imxweb/projects/qbm/src/lib/captcha/captcha.service.ts
index 98f797f4e..7360bded1 100644
--- a/imxweb/projects/qbm/src/lib/captcha/captcha.service.ts
+++ b/imxweb/projects/qbm/src/lib/captcha/captcha.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/cdr/base-cdr-editor-provider.ts b/imxweb/projects/qbm/src/lib/cdr/base-cdr-editor-provider.ts
index 80778282f..f3dd34a15 100644
--- a/imxweb/projects/qbm/src/lib/cdr/base-cdr-editor-provider.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/base-cdr-editor-provider.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/cdr/base-cdr.spec.ts b/imxweb/projects/qbm/src/lib/cdr/base-cdr.spec.ts
index d03d5bfdb..444fe2111 100644
--- a/imxweb/projects/qbm/src/lib/cdr/base-cdr.spec.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/base-cdr.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/cdr/base-cdr.ts b/imxweb/projects/qbm/src/lib/cdr/base-cdr.ts
index 3cb3f3604..d0230e3ba 100644
--- a/imxweb/projects/qbm/src/lib/cdr/base-cdr.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/base-cdr.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/cdr/base-readonly-cdr.ts b/imxweb/projects/qbm/src/lib/cdr/base-readonly-cdr.ts
index 5da24f9ce..af234863b 100644
--- a/imxweb/projects/qbm/src/lib/cdr/base-readonly-cdr.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/base-readonly-cdr.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/cdr/cdr-editor-provider-registry.interface.ts b/imxweb/projects/qbm/src/lib/cdr/cdr-editor-provider-registry.interface.ts
index 7b086ae1b..f15186e40 100644
--- a/imxweb/projects/qbm/src/lib/cdr/cdr-editor-provider-registry.interface.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/cdr-editor-provider-registry.interface.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/cdr/cdr-editor-provider.interface.ts b/imxweb/projects/qbm/src/lib/cdr/cdr-editor-provider.interface.ts
index d258b89d9..47d23feb9 100644
--- a/imxweb/projects/qbm/src/lib/cdr/cdr-editor-provider.interface.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/cdr-editor-provider.interface.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/cdr/cdr-editor.interface.ts b/imxweb/projects/qbm/src/lib/cdr/cdr-editor.interface.ts
index 6fe4c5668..2d596f5e7 100644
--- a/imxweb/projects/qbm/src/lib/cdr/cdr-editor.interface.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/cdr-editor.interface.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -28,13 +28,29 @@ import { AbstractControl } from '@angular/forms';
import { ColumnDependentReference } from './column-dependent-reference.interface';
+/**
+ * Interface for the argument, that it emitted in the CDR editor
+ */
+export interface ValueHasChangedEventArg {
+ /**
+ * The new value of the editor
+ */
+ value: any;
+
+ /**
+ * A flag to show whether the emitting of a follow up event should be forced
+ * (evaluated by {@link CdrEditorComponent|CdrEditorComponent})
+ */
+ forceEmit?: boolean;
+}
+
/**
* Interface for an editor of a column dependent reference.
*/
export interface CdrEditor {
control: AbstractControl;
- valueHasChanged?: EventEmitter;
+ valueHasChanged?: EventEmitter;
/**
* Binds a column dependent reference to the editor.
diff --git a/imxweb/projects/qbm/src/lib/cdr/cdr-editor/cdr-editor.component.spec.ts b/imxweb/projects/qbm/src/lib/cdr/cdr-editor/cdr-editor.component.spec.ts
index e9ba4d846..dfcf6250c 100644
--- a/imxweb/projects/qbm/src/lib/cdr/cdr-editor/cdr-editor.component.spec.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/cdr-editor/cdr-editor.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/cdr/cdr-editor/cdr-editor.component.ts b/imxweb/projects/qbm/src/lib/cdr/cdr-editor/cdr-editor.component.ts
index 4d34f5b36..17d617d59 100644
--- a/imxweb/projects/qbm/src/lib/cdr/cdr-editor/cdr-editor.component.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/cdr-editor/cdr-editor.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -39,7 +39,7 @@ import { ClassloggerService } from '../../classlogger/classlogger.service';
@Component({
selector: 'imx-cdr-editor',
templateUrl: './cdr-editor.component.html',
- styleUrls: ['./cdr-editor.component.scss']
+ styleUrls: ['./cdr-editor.component.scss'],
})
export class CdrEditorComponent implements OnChanges {
/**
@@ -47,7 +47,6 @@ export class CdrEditorComponent implements OnChanges {
*/
@Input() public cdr: ColumnDependentReference;
-
@Output() public controlCreated = new EventEmitter();
@Output() public readonly valueChange = new EventEmitter();
@Output() public readonly readOnlyChanged = new EventEmitter();
@@ -57,19 +56,23 @@ export class CdrEditorComponent implements OnChanges {
// stores if the cdr is readonly, because otherwise you're unable to check if the value has changed
private isReadonly: boolean;
- constructor(private registry: CdrRegistryService, private logger: ClassloggerService, private readonly elementRef: ElementRef) {
- }
+ constructor(private registry: CdrRegistryService, private logger: ClassloggerService, private readonly elementRef: ElementRef) {}
public ngOnChanges(changes: SimpleChanges): void {
- if (changes.cdr && changes.cdr.currentValue) {
+ if (changes['cdr'] && changes['cdr'].currentValue) {
this.viewContainerRef.clear();
try {
const ref = this.registry.createEditor(this.viewContainerRef, this.cdr);
this.isReadonly = this.cdr.isReadOnly();
if (ref.instance.valueHasChanged) {
- ref.instance.valueHasChanged.subscribe(value => {
- if ((value || '') !== (this.cdr.column.GetValue() || '')) {
- this.valueChange.emit(value);
+ ref.instance.valueHasChanged.subscribe((value) => {
+ if (value?.forceEmit === true) {
+ this.valueChange.emit(value.value);
+ } else {
+ const val = value.value?.DataValue ?? value.value;
+ if ((val ?? '') !== (this.cdr.column.GetValue() ?? '')) {
+ this.valueChange.emit(value.value);
+ }
}
if (this.cdr.isReadOnly() !== this.isReadonly) {
this.isReadonly = this.cdr.isReadOnly();
diff --git a/imxweb/projects/qbm/src/lib/cdr/cdr-registry.service.spec.ts b/imxweb/projects/qbm/src/lib/cdr/cdr-registry.service.spec.ts
index 149ff4b0b..38be4570e 100644
--- a/imxweb/projects/qbm/src/lib/cdr/cdr-registry.service.spec.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/cdr-registry.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/cdr/cdr-registry.service.ts b/imxweb/projects/qbm/src/lib/cdr/cdr-registry.service.ts
index 12f992f54..7b54cc577 100644
--- a/imxweb/projects/qbm/src/lib/cdr/cdr-registry.service.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/cdr-registry.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/cdr/cdr.module.ts b/imxweb/projects/qbm/src/lib/cdr/cdr.module.ts
index 97ec7b840..40cfe6763 100644
--- a/imxweb/projects/qbm/src/lib/cdr/cdr.module.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/cdr.module.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/cdr/column-dependent-reference.interface.ts b/imxweb/projects/qbm/src/lib/cdr/column-dependent-reference.interface.ts
index 16b7782d3..e35207997 100644
--- a/imxweb/projects/qbm/src/lib/cdr/column-dependent-reference.interface.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/column-dependent-reference.interface.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/cdr/date-range/date-range.component.spec.ts b/imxweb/projects/qbm/src/lib/cdr/date-range/date-range.component.spec.ts
index 033800d3a..867a92b8a 100644
--- a/imxweb/projects/qbm/src/lib/cdr/date-range/date-range.component.spec.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/date-range/date-range.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/cdr/date-range/date-range.component.ts b/imxweb/projects/qbm/src/lib/cdr/date-range/date-range.component.ts
index 6acc25164..e629f4087 100644
--- a/imxweb/projects/qbm/src/lib/cdr/date-range/date-range.component.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/date-range/date-range.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -27,10 +27,10 @@
import { Component, ErrorHandler, EventEmitter, OnDestroy } from '@angular/core';
import { FormControl, Validators } from '@angular/forms';
import { Subscription } from 'rxjs';
-import * as moment from 'moment-timezone';
+import moment from 'moment-timezone';
import { ValType, ValueRange } from 'imx-qbm-dbts';
-import { CdrEditor } from '../cdr-editor.interface';
+import { CdrEditor, ValueHasChangedEventArg } from '../cdr-editor.interface';
import { ColumnDependentReference } from '../column-dependent-reference.interface';
import { EntityColumnContainer } from '../entity-column-container';
import { ParsedHostBindings } from '@angular/compiler';
@@ -49,7 +49,7 @@ export class DateRangeComponent implements CdrEditor, OnDestroy {
public readonly columnContainer = new EntityColumnContainer();
- public readonly valueHasChanged = new EventEmitter();
+ public readonly valueHasChanged = new EventEmitter();
public isLoading = false;
@@ -91,7 +91,7 @@ export class DateRangeComponent implements CdrEditor, OnDestroy {
if (this.control.value !== this.columnContainer.value) {
this.updateControlValues();
}
- this.valueHasChanged.emit(this.control.value);
+ this.valueHasChanged.emit({ value: this.control.value });
}));
}
}
@@ -128,7 +128,7 @@ export class DateRangeComponent implements CdrEditor, OnDestroy {
}
}
- this.valueHasChanged.emit(this.columnContainer.value);
+ this.valueHasChanged.emit({ value: this.columnContainer.value, forceEmit: true });
}
private updateControlValues(): void {
diff --git a/imxweb/projects/qbm/src/lib/cdr/default-cdr-editor-provider.spec.ts b/imxweb/projects/qbm/src/lib/cdr/default-cdr-editor-provider.spec.ts
index e55b19d68..e66a8d8a0 100644
--- a/imxweb/projects/qbm/src/lib/cdr/default-cdr-editor-provider.spec.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/default-cdr-editor-provider.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/cdr/default-cdr-editor-provider.ts b/imxweb/projects/qbm/src/lib/cdr/default-cdr-editor-provider.ts
index 4cb36cfee..14afe3827 100644
--- a/imxweb/projects/qbm/src/lib/cdr/default-cdr-editor-provider.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/default-cdr-editor-provider.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/cdr/edit-binary/edit-binary.component.spec.ts b/imxweb/projects/qbm/src/lib/cdr/edit-binary/edit-binary.component.spec.ts
index 45f019192..5e648265c 100644
--- a/imxweb/projects/qbm/src/lib/cdr/edit-binary/edit-binary.component.spec.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/edit-binary/edit-binary.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/cdr/edit-binary/edit-binary.component.ts b/imxweb/projects/qbm/src/lib/cdr/edit-binary/edit-binary.component.ts
index 7c5c85929..81393db8b 100644
--- a/imxweb/projects/qbm/src/lib/cdr/edit-binary/edit-binary.component.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/edit-binary/edit-binary.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/cdr/edit-boolean/edit-boolean.component.spec.ts b/imxweb/projects/qbm/src/lib/cdr/edit-boolean/edit-boolean.component.spec.ts
index 449c88d73..f1383d803 100644
--- a/imxweb/projects/qbm/src/lib/cdr/edit-boolean/edit-boolean.component.spec.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/edit-boolean/edit-boolean.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/cdr/edit-boolean/edit-boolean.component.ts b/imxweb/projects/qbm/src/lib/cdr/edit-boolean/edit-boolean.component.ts
index eae9684e5..0dd5add69 100644
--- a/imxweb/projects/qbm/src/lib/cdr/edit-boolean/edit-boolean.component.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/edit-boolean/edit-boolean.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/cdr/edit-date/edit-date.component.spec.ts b/imxweb/projects/qbm/src/lib/cdr/edit-date/edit-date.component.spec.ts
index 7a8bbe9ab..9b9c5272b 100644
--- a/imxweb/projects/qbm/src/lib/cdr/edit-date/edit-date.component.spec.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/edit-date/edit-date.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/cdr/edit-date/edit-date.component.ts b/imxweb/projects/qbm/src/lib/cdr/edit-date/edit-date.component.ts
index fdc6818aa..d31512e0c 100644
--- a/imxweb/projects/qbm/src/lib/cdr/edit-date/edit-date.component.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/edit-date/edit-date.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -25,11 +25,12 @@
*/
import { Component, ErrorHandler, EventEmitter, OnDestroy } from '@angular/core';
-import { FormControl, Validators } from '@angular/forms';
+import { FormControl } from '@angular/forms';
import { Subscription } from 'rxjs';
-import { CdrEditor } from '../cdr-editor.interface';
+import { CdrEditor, ValueHasChangedEventArg } from '../cdr-editor.interface';
import { ColumnDependentReference } from '../column-dependent-reference.interface';
-import * as moment from 'moment-timezone';
+import moment from 'moment-timezone';
+import { Moment } from 'moment-timezone';
import { EntityColumnContainer } from '../entity-column-container';
import { ClassloggerService } from '../../classlogger/classlogger.service';
@@ -48,7 +49,7 @@ export class EditDateComponent implements CdrEditor, OnDestroy {
public readonly columnContainer = new EntityColumnContainer();
- public readonly valueHasChanged = new EventEmitter();
+ public readonly valueHasChanged = new EventEmitter();
public isBusy = false;
@@ -91,7 +92,7 @@ export class EditDateComponent implements CdrEditor, OnDestroy {
if (!this.isWriting) {
this.logger.trace(this, 'Control set to new value');
this.resetControlValue();
- this.valueHasChanged.emit(this.control.value);
+ this.valueHasChanged.emit({value: this.control.value});
}
}));
@@ -103,7 +104,7 @@ export class EditDateComponent implements CdrEditor, OnDestroy {
this.updateControlValue(value);
}
- private updateControlValue(value: moment): void {
+ private updateControlValue(value: Moment): void {
if (this.control.value !== value) {
this.control.setValue(value, {emitEvent: false});
}
@@ -113,7 +114,7 @@ export class EditDateComponent implements CdrEditor, OnDestroy {
* updates the value for the CDR
* @param value the new value
*/
- private async writeValue(value: moment): Promise {
+ private async writeValue(value: Moment): Promise {
if (this.control.errors) {
return;
}
@@ -141,7 +142,7 @@ export class EditDateComponent implements CdrEditor, OnDestroy {
this.resetControlValue();
}
- this.valueHasChanged.emit(this.columnContainer.value);
+ this.valueHasChanged.emit({value: this.columnContainer.value, forceEmit: true});
}
}
diff --git a/imxweb/projects/qbm/src/lib/cdr/edit-default/edit-default.component.html b/imxweb/projects/qbm/src/lib/cdr/edit-default/edit-default.component.html
index 711a298ad..4aa4d83f2 100644
--- a/imxweb/projects/qbm/src/lib/cdr/edit-default/edit-default.component.html
+++ b/imxweb/projects/qbm/src/lib/cdr/edit-default/edit-default.component.html
@@ -8,10 +8,10 @@
-
+
{{ '#LDS#This field is mandatory.' | translate }}
-
+
{{validationErrorMessage}}
-
\ No newline at end of file
+
diff --git a/imxweb/projects/qbm/src/lib/cdr/edit-default/edit-default.component.scss b/imxweb/projects/qbm/src/lib/cdr/edit-default/edit-default.component.scss
index 9e50c3afb..d4992ad96 100644
--- a/imxweb/projects/qbm/src/lib/cdr/edit-default/edit-default.component.scss
+++ b/imxweb/projects/qbm/src/lib/cdr/edit-default/edit-default.component.scss
@@ -1,4 +1,4 @@
-@import "~@elemental-ui/core/src/styles/_palette.scss";
+@import "@elemental-ui/core/src/styles/_palette.scss";
:host {
display: flex;
@@ -21,4 +21,4 @@
margin-right: 5px;
margin-top: 0;
}
-}
\ No newline at end of file
+}
diff --git a/imxweb/projects/qbm/src/lib/cdr/edit-default/edit-default.component.spec.ts b/imxweb/projects/qbm/src/lib/cdr/edit-default/edit-default.component.spec.ts
index 6f77eefd2..4e33ada8d 100644
--- a/imxweb/projects/qbm/src/lib/cdr/edit-default/edit-default.component.spec.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/edit-default/edit-default.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/cdr/edit-default/edit-default.component.ts b/imxweb/projects/qbm/src/lib/cdr/edit-default/edit-default.component.ts
index 7fe15fb61..8f16c8684 100644
--- a/imxweb/projects/qbm/src/lib/cdr/edit-default/edit-default.component.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/edit-default/edit-default.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/cdr/edit-fk/edit-fk-datasource.ts b/imxweb/projects/qbm/src/lib/cdr/edit-fk/edit-fk-datasource.ts
deleted file mode 100644
index 162c1728e..000000000
--- a/imxweb/projects/qbm/src/lib/cdr/edit-fk/edit-fk-datasource.ts
+++ /dev/null
@@ -1,132 +0,0 @@
-/*
- * ONE IDENTITY LLC. PROPRIETARY INFORMATION
- *
- * This software is confidential. One Identity, LLC. or one of its affiliates or
- * subsidiaries, has supplied this software to you under terms of a
- * license agreement, nondisclosure agreement or both.
- *
- * You may not copy, disclose, or use this software except in accordance with
- * those terms.
- *
- *
- * Copyright 2021 One Identity LLC.
- * ALL RIGHTS RESERVED.
- *
- * ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
- * WARRANTIES ABOUT THE SUITABILITY OF THE SOFTWARE,
- * EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
- * TO THE IMPLIED WARRANTIES OF MERCHANTABILITY,
- * FITNESS FOR A PARTICULAR PURPOSE, OR
- * NON-INFRINGEMENT. ONE IDENTITY LLC. SHALL NOT BE
- * LIABLE FOR ANY DAMAGES SUFFERED BY LICENSEE
- * AS A RESULT OF USING, MODIFYING OR DISTRIBUTING
- * THIS SOFTWARE OR ITS DERIVATIVES.
- *
- */
-
-import { CollectionViewer } from '@angular/cdk/collections';
-import { DataSource } from '@angular/cdk/table';
-import { BehaviorSubject, Observable, Subject, Subscription } from 'rxjs';
-
-import { CollectionLoadParameters, IForeignKeyInfo } from 'imx-qbm-dbts';
-import { Candidate } from '../../fk-advanced-picker/candidate.interface';
-import { ClassloggerService } from '../../classlogger/classlogger.service';
-import { Injectable } from '@angular/core';
-
-export class EditFkDatasource extends DataSource {
- public loading: Subject = new Subject();
-
- private pageSize = 20;
- private cachedData: Candidate[] = [];
- private dataStream = new BehaviorSubject(this.cachedData);
- private subscription = new Subscription();
- private params: CollectionLoadParameters = {};
-
- constructor(
- private readonly logger: ClassloggerService,
- private readonly selectedTable: IForeignKeyInfo,
- private readonly fkRelations: readonly IForeignKeyInfo[]
- ) {
- super();
- }
-
- public connect(collectionViewer: CollectionViewer): Observable {
- console.log('*** Connected ***');
- this.params = {
- PageSize: this.pageSize,
- StartIndex: 0
- };
- this.fetchPage();
-
- this.subscription.add(collectionViewer.viewChange.subscribe(async range => {
- if (range.end === (this.pageSize + this.params.StartIndex)) {
- this.params.StartIndex = this.params.StartIndex + this.pageSize;
- await this.fetchPage();
- }
-
- }));
- return this.dataStream;
- }
-
- public disconnect(): void {
- console.log('*** Disconnected ***');
- this.subscription.unsubscribe();
- }
-
- public updateSearchParams(params: CollectionLoadParameters): void {
- this.params.filter = params.filter;
- this.params.search = params.search;
- this.cachedData = [];
- }
-
- public async fetchPage(): Promise {
- this.loading.next(true);
-
- try {
- this.logger.debug(this, `Gettting chunk with params ${this.params}`);
- const candidateCollection = await this.selectedTable.Get(this.params);
-
- const multipleFkRelations = this.fkRelations && this.fkRelations.length > 1;
- const identityRelatedTable = this.selectedTable.TableName === 'Person';
-
- const tempCache = candidateCollection.Entities.map(entityData => {
- let key: string = null;
- let detailValue: string = entityData.LongDisplay;
- const defaultEmailColumn = entityData.Columns.DefaultEmailAddress;
- /**
- * If the candidates data relate to identities (fkRelation Person table)
- * then we want to use the email address for the detail line (displayLong)
- */
- if (defaultEmailColumn && identityRelatedTable) {
- detailValue = defaultEmailColumn.Value;
- }
- if (multipleFkRelations) {
- this.logger.trace(this, 'dynamic foreign key');
- const xObjectKeyColumn = entityData.Columns.XObjectKey;
- key = xObjectKeyColumn ? xObjectKeyColumn.Value : undefined;
- } else {
- this.logger.trace(this, 'foreign key');
- const parentColumn = entityData.Columns ? entityData.Columns[this.fkRelations[0].ColumnName] : undefined;
- if (parentColumn != null) {
- this.logger.trace(this, 'Use value from explicit parent column');
- key = parentColumn.Value;
- } else {
- const keys = entityData.Keys;
- key = keys && keys.length ? keys[0] : undefined;
- }
- }
- return {
- DataValue: key,
- DisplayValue: entityData.Display,
- displayLong: detailValue
- // displayLong: (this.params.StartIndex / this.pageSize).toString()
- };
- });
-
- this.cachedData = this.cachedData.concat(tempCache);
- this.dataStream.next(this.cachedData);
- } finally {
- this.loading.next(false);
- }
- }
-}
diff --git a/imxweb/projects/qbm/src/lib/cdr/edit-fk/edit-fk-multi.component.html b/imxweb/projects/qbm/src/lib/cdr/edit-fk/edit-fk-multi.component.html
index aec4daa42..be0bf0f49 100644
--- a/imxweb/projects/qbm/src/lib/cdr/edit-fk/edit-fk-multi.component.html
+++ b/imxweb/projects/qbm/src/lib/cdr/edit-fk/edit-fk-multi.component.html
@@ -11,7 +11,7 @@
{{ columnContainer?.value?.length ? ('#LDS#Change' | translate) : ('#LDS#Assign' | translate) }}
-
+
{{ '#LDS#This field is mandatory.' | translate }}
-
\ No newline at end of file
+
diff --git a/imxweb/projects/qbm/src/lib/cdr/edit-fk/edit-fk-multi.component.spec.ts b/imxweb/projects/qbm/src/lib/cdr/edit-fk/edit-fk-multi.component.spec.ts
index 20d0804ce..e09126ef5 100644
--- a/imxweb/projects/qbm/src/lib/cdr/edit-fk/edit-fk-multi.component.spec.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/edit-fk/edit-fk-multi.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/cdr/edit-fk/edit-fk-multi.component.ts b/imxweb/projects/qbm/src/lib/cdr/edit-fk/edit-fk-multi.component.ts
index 4b93e7b7b..84ad60405 100644
--- a/imxweb/projects/qbm/src/lib/cdr/edit-fk/edit-fk-multi.component.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/edit-fk/edit-fk-multi.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -29,7 +29,7 @@ import { FormControl } from '@angular/forms';
import { TranslateService } from '@ngx-translate/core';
import { EuiSidesheetService } from '@elemental-ui/core';
-import { CdrEditor } from '../cdr-editor.interface';
+import { CdrEditor, ValueHasChangedEventArg } from '../cdr-editor.interface';
import { EntityColumnContainer } from '../entity-column-container';
import { ColumnDependentReference } from '../column-dependent-reference.interface';
import { ClassloggerService } from '../../classlogger/classlogger.service';
@@ -51,7 +51,7 @@ export class EditFkMultiComponent implements CdrEditor, OnInit, OnDestroy {
public readonly columnContainer = new EntityColumnContainer();
- public readonly valueHasChanged = new EventEmitter();
+ public readonly valueHasChanged = new EventEmitter();
public loading = false;
private isWriting = false;
@@ -121,7 +121,7 @@ export class EditFkMultiComponent implements CdrEditor, OnInit, OnDestroy {
{ emitEvent: false }
);
}
- this.valueHasChanged.emit(this.currentValueStruct);
+ this.valueHasChanged.emit({value: this.currentValueStruct});
}));
this.logger.trace(this, 'Control initialized');
} else {
@@ -217,7 +217,7 @@ export class EditFkMultiComponent implements CdrEditor, OnInit, OnDestroy {
this.logger.debug(this, 'writeValue - form control value is set to', this.control.value);
}
}
- this.valueHasChanged.emit(this.currentValueStruct);
+ this.valueHasChanged.emit({value: this.currentValueStruct, forceEmit: true});
}
private async multiValueToDisplay(value: ValueStruct): Promise {
diff --git a/imxweb/projects/qbm/src/lib/cdr/edit-fk/edit-fk.component.html b/imxweb/projects/qbm/src/lib/cdr/edit-fk/edit-fk.component.html
index 60fc6b73c..d6bc7e881 100644
--- a/imxweb/projects/qbm/src/lib/cdr/edit-fk/edit-fk.component.html
+++ b/imxweb/projects/qbm/src/lib/cdr/edit-fk/edit-fk.component.html
@@ -48,7 +48,7 @@
{{ '#LDS#The value entered in the {0} box could not be found. Please select a value from the list.' | translate |
ldsReplace:(columnContainer?.display | translate) }}
-
+
{{ '#LDS#This field is mandatory.' | translate }}
diff --git a/imxweb/projects/qbm/src/lib/cdr/edit-fk/edit-fk.component.scss b/imxweb/projects/qbm/src/lib/cdr/edit-fk/edit-fk.component.scss
index b415bc3d5..b07510519 100644
--- a/imxweb/projects/qbm/src/lib/cdr/edit-fk/edit-fk.component.scss
+++ b/imxweb/projects/qbm/src/lib/cdr/edit-fk/edit-fk.component.scss
@@ -1,4 +1,4 @@
-@import "~@elemental-ui/core/src/styles/_palette.scss";
+@import "@elemental-ui/core/src/styles/_palette.scss";
:host {
display: flex;
diff --git a/imxweb/projects/qbm/src/lib/cdr/edit-fk/edit-fk.component.spec.ts b/imxweb/projects/qbm/src/lib/cdr/edit-fk/edit-fk.component.spec.ts
index 9d5d27ab2..163a68507 100644
--- a/imxweb/projects/qbm/src/lib/cdr/edit-fk/edit-fk.component.spec.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/edit-fk/edit-fk.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/cdr/edit-fk/edit-fk.component.ts b/imxweb/projects/qbm/src/lib/cdr/edit-fk/edit-fk.component.ts
index 5ad68a95c..cf1ed94df 100644
--- a/imxweb/projects/qbm/src/lib/cdr/edit-fk/edit-fk.component.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/edit-fk/edit-fk.component.ts
@@ -1,462 +1,472 @@
-/*
- * ONE IDENTITY LLC. PROPRIETARY INFORMATION
- *
- * This software is confidential. One Identity, LLC. or one of its affiliates or
- * subsidiaries, has supplied this software to you under terms of a
- * license agreement, nondisclosure agreement or both.
- *
- * You may not copy, disclose, or use this software except in accordance with
- * those terms.
- *
- *
- * Copyright 2021 One Identity LLC.
- * ALL RIGHTS RESERVED.
- *
- * ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
- * WARRANTIES ABOUT THE SUITABILITY OF THE SOFTWARE,
- * EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
- * TO THE IMPLIED WARRANTIES OF MERCHANTABILITY,
- * FITNESS FOR A PARTICULAR PURPOSE, OR
- * NON-INFRINGEMENT. ONE IDENTITY LLC. SHALL NOT BE
- * LIABLE FOR ANY DAMAGES SUFFERED BY LICENSEE
- * AS A RESULT OF USING, MODIFYING OR DISTRIBUTING
- * THIS SOFTWARE OR ITS DERIVATIVES.
- *
- */
-
-import {
- Component,
- OnDestroy,
- ViewChild,
- AfterViewInit,
- ChangeDetectionStrategy,
- ChangeDetectorRef,
- EventEmitter,
- OnInit,
- ErrorHandler
-} from '@angular/core';
-import { MatAutocompleteSelectedEvent } from '@angular/material/autocomplete';
-import { FormControl } from '@angular/forms';
-import { Subscription } from 'rxjs';
-import { debounceTime } from 'rxjs/operators';
-import { CdkVirtualScrollViewport } from '@angular/cdk/scrolling';
-import { ListRange } from '@angular/cdk/collections';
-import { EuiSidesheetService } from '@elemental-ui/core';
-import { TranslateService } from '@ngx-translate/core';
-
-import { ClassloggerService } from '../../classlogger/classlogger.service';
-import { FkAdvancedPickerComponent } from '../../fk-advanced-picker/fk-advanced-picker.component';
-import { ValueStruct, IForeignKeyInfo, CollectionLoadParameters, DbObjectKey, FilterType, CompareOperator } from 'imx-qbm-dbts';
-import { ColumnDependentReference } from '../column-dependent-reference.interface';
-import { EntityColumnContainer } from '../entity-column-container';
-import { CdrEditor } from '../cdr-editor.interface';
-import { ForeignKeySelection } from '../../fk-advanced-picker/foreign-key-selection.interface';
-import { Candidate } from '../../fk-advanced-picker/candidate.interface';
-import { MetadataService } from '../../base/metadata.service';
-import { FkHierarchicalDialogComponent } from '../../fk-hierarchical-dialog/fk-hierarchical-dialog.component';
-import { LdsReplacePipe } from '../../lds-replace/lds-replace.pipe';
-import { I } from '@angular/cdk/keycodes';
-
-/**
- * A component for viewing / editing foreign key relations
- */
-// tslint:disable-next-line: max-classes-per-file
-@Component({
- selector: 'imx-edit-fk',
- templateUrl: './edit-fk.component.html',
- styleUrls: ['./edit-fk.component.scss'],
- changeDetection: ChangeDetectionStrategy.OnPush
-})
-/**
- * A component for viewing / editing foreign key relations
- */
-export class EditFkComponent implements CdrEditor, AfterViewInit, OnDestroy, OnInit {
- public get hasCandidatesOrIsLoading(): boolean {
-
- return true;
-
- // because of 298890
- /*
- return this.candidatesTotalCount > 0
- // make sure the user can change selectedTable even if there are no available candidates
- // in the first candidate table
- || this.columnContainer.fkRelations.length > 1
- || this.parameters?.search?.length > 0
- || this.parameters?.filter != null
- || this.loading;
- */
- }
-
- public readonly control = new FormControl(undefined);
- public readonly columnContainer = new EntityColumnContainer();
- public readonly pageSize = 20;
- public candidates: Candidate[];
- public loading = false;
- public selectedTable: IForeignKeyInfo;
- public isHierarchical: boolean;
-
-
- public readonly valueHasChanged = new EventEmitter();
-
- private parameters: CollectionLoadParameters = { PageSize: this.pageSize, StartIndex: 0 };
- private readonly subscribers: Subscription[] = [];
- private isWriting = false;
-
- @ViewChild('viewport') private viewport: CdkVirtualScrollViewport;
-
- /**
- * Creates a new EditFkComponent for column dependent reference with a foreign key relation.
- * @param logger Log service.
- * @param sidesheet Dialog to open the pickerdialog for selecting an object.
- * @param metadataProvider Service providing table meta data
- */
- constructor(
- private readonly logger: ClassloggerService,
- private readonly sidesheet: EuiSidesheetService,
- private readonly changeDetectorRef: ChangeDetectorRef,
- private readonly translator: TranslateService,
- private readonly ldsReplace: LdsReplacePipe,
- public readonly metadataProvider: MetadataService,
- private readonly errorHandler: ErrorHandler
- ) {
- this.subscribers.push(this.control.valueChanges.pipe(debounceTime(500)).subscribe(async keyword => {
- if (keyword != null && typeof keyword !== 'string') {
- this.control.setErrors(null);
- return;
- }
-
- return this.search(keyword);
- }));
- }
-
-
- public async ngOnInit(): Promise {
- return this.initCandidates();
- // Muss leider immer gemacht werden, damit klar ist, ob es sich um eine hierarchische Ansicht handelt oder nicht
- }
-
- public async ngAfterViewInit(): Promise {
- if (this.columnContainer && this.columnContainer.canEdit && this.viewport) {
- this.viewport.scrolledIndexChange.subscribe(async (value: number) => {
- const range = this.viewport.getRenderedRange();
- if (range.end >= this.parameters.StartIndex + this.pageSize) {
- const tmpCandidates: Candidate[] = Object.assign([], this.candidates);
- this.parameters.StartIndex += this.pageSize;
-
- await this.updateCandidates(this.parameters);
-
- this.candidates = tmpCandidates.concat(this.candidates);
- this.changeDetectorRef.detectChanges();
- this.viewport.scrollToIndex(value);
- }
- });
- }
- }
-
- public ngOnDestroy(): void {
- this.subscribers.forEach(s => s.unsubscribe());
- }
-
- public async inputFocus(): Promise {
- if (!this.candidates?.length && !this.loading) {
- await this.initCandidates();
- }
- }
-
- public async onOpened(): Promise {
- // Reset size
- this.parameters.StartIndex = 0;
- await this.updateCandidates();
- if (this.viewport) {
- this.viewport.scrollToIndex(0);
- this.viewport.checkViewportSize();
- }
- }
-
- public getDisplay(candidate: Candidate): string {
- return candidate ? candidate.DisplayValue : undefined;
- }
-
- public async optionSelected(event: MatAutocompleteSelectedEvent): Promise {
- return this.writeValue(event.option.value);
- }
-
- public async removeAssignment(event?: Event): Promise {
- if (event) {
- event.stopPropagation();
- }
-
- const value = { DataValue: undefined };
- this.control.setValue(value, { emitEvent: false });
- await this.writeValue(value);
-
- /* 298890
- if (this.candidatesTotalCount === 0) {
- return this.updateCandidates();
- }
- */
- }
-
- public close(event?: any): void {
- if (this.control.value == null || typeof (this.control.value) === 'string') {
- this.logger.debug(this, 'autoCompleteClose no match - reset to previous value', event);
- this.control.setValue(this.getValueStruct(), { emitEvent: false });
- }
- }
-
- /**
- * @ignore
- * Opens a dialog for selecting an object
- */
- public async editAssignment(event?: Event): Promise {
- if (event) {
- event.stopPropagation();
- }
-
- const dialogRef = this.sidesheet.open(this.isHierarchical ? FkHierarchicalDialogComponent : FkAdvancedPickerComponent, {
- title: this.ldsReplace.transform(await this.translator.get('#LDS#Heading {0}').toPromise(),
- await this.translator.get(this.columnContainer?.display).toPromise()),
- headerColour: 'iris-blue',
- panelClass: 'imx-sidesheet',
- padding: '0',
- disableClose: true,
- width: '60%',
- testId: this.isHierarchical ? 'edit-fk-hierarchy-sidesheet' : 'edit-fk-sidesheet',
- data: {
- fkRelations: this.columnContainer.fkRelations,
- selectedTableName: this.selectedTable.TableName,
- idList: this.columnContainer.value ? [this.columnContainer.value] : []
- }
- });
-
- dialogRef.afterClosed().subscribe(async (selection: ForeignKeySelection) => {
- if (selection) {
- this.logger.debug(this, 'dialog ok', selection);
- this.candidates = null;
- this.selectedTable = selection.table;
-
- if (!this.columnContainer.canEdit) {
- return;
- }
-
- const value = selection.candidates && selection.candidates.length > 0 ? selection.candidates[0] : { DataValue: undefined };
- this.control.setValue(value, { emitEvent: false });
- await this.writeValue(value);
-
- } else {
- this.logger.debug(this, 'dialog cancel');
- }
- });
- }
-
- /**
- * Binds a column dependent reference to the component
- * @param cdref a column dependent reference
- */
- public bind(cdref: ColumnDependentReference): void {
- if (cdref && cdref.column) {
- this.columnContainer.init(cdref);
- this.setControlValue();
-
- // bind to entity change event
- this.subscribers.push(this.columnContainer.subscribe(async () => {
- if (this.isWriting) {
- return;
- }
-
- if (this.control.value?.DataValue !== this.columnContainer.value) {
- this.loading = true;
- try {
- this.logger.trace(this, `Control (${this.columnContainer.name}) set to new value:`,
- this.columnContainer.value, this.control.value);
- this.candidates = [];
- this.setControlValue();
-
- } finally {
- this.loading = false;
- this.changeDetectorRef.detectChanges();
- }
- }
- this.valueHasChanged.emit(this.control.value);
- }));
- this.logger.trace(this, 'Control initialized', this.control.value);
- } else {
- this.logger.error(this, 'The Column Dependent Reference is undefined');
- }
- }
-
- private setControlValue(): void {
- if (this.columnContainer.fkRelations && this.columnContainer.fkRelations.length > 0) {
- let table: IForeignKeyInfo;
- if (this.columnContainer.fkRelations.length > 1 && this.columnContainer.value) {
- this.logger.trace(this, 'the column already has a value, and it is a dynamic foreign key');
- const dbObjectKey = DbObjectKey.FromXml(this.columnContainer.value);
- table = this.columnContainer.fkRelations.find(fkr => fkr.TableName === dbObjectKey.TableName);
- }
- this.selectedTable = table || this.columnContainer.fkRelations[0];
-
- this.metadataProvider.update(this.columnContainer.fkRelations.map(fkr => fkr.TableName));
- }
- this.control.setValue(this.getValueStruct(), { emitEvent: false });
- if (this.columnContainer.isValueRequired && this.columnContainer.canEdit) {
- this.control.setValidators(control => control.value == null || control.value.length === 0 ? { required: true } : null);
- }
- }
-
- /** loads the candidates and updates the listings */
- private async initCandidates(): Promise {
- if (this.columnContainer && this.columnContainer.canEdit) {
- await this.updateCandidates({
- StartIndex: 0,
- PageSize: this.pageSize,
- filter: undefined,
- search: undefined
- });
-
- this.changeDetectorRef.detectChanges();
- }
- }
-
- /**
- * updates the value for the CDR
- * @param value the new value
- */
- private async writeValue(value: ValueStruct): Promise {
-
- this.logger.debug(this, 'writeValue called with value', value);
-
- if (!this.columnContainer.canEdit || this.equal(this.getValueStruct(), value)) {
- return;
- }
-
- this.isWriting = true;
- this.loading = true;
- try {
-
- this.logger.debug(this, 'writeValue - updateCdrValue...');
- await this.columnContainer.updateValueStruct(value);
-
- const valueAfterWrite = this.getValueStruct();
-
- if (!this.equal(this.control.value, valueAfterWrite)) {
-
- this.control.setValue(valueAfterWrite, { emitEvent: false });
-
- this.logger.debug(
- this,
- 'writeValue - value has changed after interaction with the Entity. Value:',
- this.control.value
- );
- }
-
- this.control.markAsDirty();
- this.valueHasChanged.emit(value);
- } catch (error) {
- this.errorHandler.handleError(error);
- } finally {
- this.loading = false;
- this.isWriting = false;
- this.changeDetectorRef.detectChanges();
- }
- }
-
- private async updateCandidates(newState?: CollectionLoadParameters): Promise {
- if (this.selectedTable) {
- try {
- this.loading = true;
- this.parameters = { ...this.parameters, ...newState };
- const candidateCollection = await this.selectedTable.Get(this.parameters);
- // this.candidatesTotalCount = candidateCollection.TotalCount;
-
- this.isHierarchical = candidateCollection.Hierarchy != null;
-
- const multipleFkRelations = this.columnContainer.fkRelations && this.columnContainer.fkRelations.length > 1;
- const identityRelatedTable = this.selectedTable.TableName === 'Person';
-
- this.candidates = candidateCollection.Entities.map(entityData => {
- let key: string = null;
- let detailValue: string = entityData.LongDisplay;
- const defaultEmailColumn = entityData.Columns.DefaultEmailAddress;
- /**
- * If the candidates data relate to identities (fkRelation Person table)
- * then we want to use the email address for the detail line (displayLong)
- */
- if (defaultEmailColumn && identityRelatedTable) {
- detailValue = defaultEmailColumn.Value;
- }
- if (multipleFkRelations) {
- this.logger.trace(this, 'dynamic foreign key');
- const xObjectKeyColumn = entityData.Columns.XObjectKey;
- key = xObjectKeyColumn ? xObjectKeyColumn.Value : undefined;
- } else {
- this.logger.trace(this, 'foreign key');
-
- const parentColumn = entityData.Columns ? entityData.Columns[this.columnContainer.fkRelations[0].ColumnName] : undefined;
- if (parentColumn != null) {
- this.logger.trace(this, 'Use value from explicit parent column');
- key = parentColumn.Value;
- } else {
- this.logger.trace(this, 'Use the primary key');
- const keys = entityData.Keys;
- key = keys && keys.length ? keys[0] : undefined;
- }
- }
- return {
- DataValue: key,
- DisplayValue: entityData.Display,
- displayLong: detailValue
- };
- });
- } finally {
- this.loading = false;
- this.changeDetectorRef.detectChanges();
- }
- }
- }
-
- private getValueStruct(): ValueStruct {
- if (this.columnContainer.value) {
- return { DataValue: this.columnContainer.value, DisplayValue: this.columnContainer.displayValue || '' };
- }
-
- return undefined;
- }
-
- private equal(value: ValueStruct, value2: ValueStruct): boolean {
- if (value && value2) {
- return value.DataValue === value2.DataValue && value.DisplayValue === value.DisplayValue;
- }
-
- return value == null && value2 == null;
- }
-
- private async search(keyword: string): Promise {
- this.parameters.StartIndex = 0;
- await this.updateCandidates(
- (this.selectedTable && this.selectedTable.hasSearchParameter) || keyword == null || keyword.length === 0 ?
- {
- filter: undefined,
- search: keyword
- } :
- {
- filter: [
- {
- ColumnName: this.selectedTable.ColumnName,
- Type: FilterType.Compare,
- CompareOp: CompareOperator.Like,
- Value1: `%${keyword}%`
- }
- ],
- search: undefined
- }
- );
-
- this.changeDetectorRef.detectChanges();
-
- this.control.setErrors(
- (keyword == null || this.candidates == null || this.candidates.length > 0) ?
- null :
- { checkAutocomplete: true }
- );
- }
-}
+/*
+ * ONE IDENTITY LLC. PROPRIETARY INFORMATION
+ *
+ * This software is confidential. One Identity, LLC. or one of its affiliates or
+ * subsidiaries, has supplied this software to you under terms of a
+ * license agreement, nondisclosure agreement or both.
+ *
+ * You may not copy, disclose, or use this software except in accordance with
+ * those terms.
+ *
+ *
+ * Copyright 2022 One Identity LLC.
+ * ALL RIGHTS RESERVED.
+ *
+ * ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
+ * WARRANTIES ABOUT THE SUITABILITY OF THE SOFTWARE,
+ * EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
+ * TO THE IMPLIED WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE, OR
+ * NON-INFRINGEMENT. ONE IDENTITY LLC. SHALL NOT BE
+ * LIABLE FOR ANY DAMAGES SUFFERED BY LICENSEE
+ * AS A RESULT OF USING, MODIFYING OR DISTRIBUTING
+ * THIS SOFTWARE OR ITS DERIVATIVES.
+ *
+ */
+
+import {
+ Component,
+ OnDestroy,
+ ViewChild,
+ AfterViewInit,
+ ChangeDetectionStrategy,
+ ChangeDetectorRef,
+ EventEmitter,
+ OnInit,
+ ErrorHandler
+} from '@angular/core';
+import { MatAutocompleteSelectedEvent } from '@angular/material/autocomplete';
+import { FormControl } from '@angular/forms';
+import { Subscription } from 'rxjs';
+import { debounceTime } from 'rxjs/operators';
+import { CdkVirtualScrollViewport } from '@angular/cdk/scrolling';
+import { ListRange } from '@angular/cdk/collections';
+import { EuiSidesheetService } from '@elemental-ui/core';
+import { TranslateService } from '@ngx-translate/core';
+
+import { ClassloggerService } from '../../classlogger/classlogger.service';
+import { FkAdvancedPickerComponent } from '../../fk-advanced-picker/fk-advanced-picker.component';
+import { ValueStruct, IForeignKeyInfo, CollectionLoadParameters, DbObjectKey, FilterType, CompareOperator } from 'imx-qbm-dbts';
+import { ColumnDependentReference } from '../column-dependent-reference.interface';
+import { EntityColumnContainer } from '../entity-column-container';
+import { CdrEditor, ValueHasChangedEventArg } from '../cdr-editor.interface';
+import { ForeignKeySelection } from '../../fk-advanced-picker/foreign-key-selection.interface';
+import { Candidate } from '../../fk-advanced-picker/candidate.interface';
+import { MetadataService } from '../../base/metadata.service';
+import { FkHierarchicalDialogComponent } from '../../fk-hierarchical-dialog/fk-hierarchical-dialog.component';
+import { LdsReplacePipe } from '../../lds-replace/lds-replace.pipe';
+
+/**
+ * A component for viewing / editing foreign key relations
+ */
+// tslint:disable-next-line: max-classes-per-file
+@Component({
+ selector: 'imx-edit-fk',
+ templateUrl: './edit-fk.component.html',
+ styleUrls: ['./edit-fk.component.scss'],
+ changeDetection: ChangeDetectionStrategy.OnPush
+})
+/**
+ * A component for viewing / editing foreign key relations
+ */
+export class EditFkComponent implements CdrEditor, AfterViewInit, OnDestroy, OnInit {
+ public get hasCandidatesOrIsLoading(): boolean {
+
+ return true;
+
+ // because of 298890
+ /*
+ return this.candidatesTotalCount > 0
+ // make sure the user can change selectedTable even if there are no available candidates
+ // in the first candidate table
+ || this.columnContainer.fkRelations.length > 1
+ || this.parameters?.search?.length > 0
+ || this.parameters?.filter != null
+ || this.loading;
+ */
+ }
+
+ public readonly control = new FormControl(undefined);
+ public readonly columnContainer = new EntityColumnContainer();
+ public readonly pageSize = 20;
+ public candidates: Candidate[];
+ public loading = false;
+ public selectedTable: IForeignKeyInfo;
+ public isHierarchical: boolean;
+
+
+ public readonly valueHasChanged = new EventEmitter();
+
+ private parameters: CollectionLoadParameters = { PageSize: this.pageSize, StartIndex: 0 };
+ private savedParameters: CollectionLoadParameters;
+ private savedCandidates: Candidate[];
+ private readonly subscribers: Subscription[] = [];
+ private isWriting = false;
+
+ @ViewChild('viewport') private viewport: CdkVirtualScrollViewport;
+ /**
+ * Creates a new EditFkComponent for column dependent reference with a foreign key relation.
+ * @param logger Log service.
+ * @param sidesheet Dialog to open the pickerdialog for selecting an object.
+ * @param metadataProvider Service providing table meta data
+ */
+ constructor(
+ private readonly logger: ClassloggerService,
+ private readonly sidesheet: EuiSidesheetService,
+ private readonly changeDetectorRef: ChangeDetectorRef,
+ private readonly translator: TranslateService,
+ private readonly ldsReplace: LdsReplacePipe,
+ public readonly metadataProvider: MetadataService,
+ private readonly errorHandler: ErrorHandler
+ ) {
+ this.subscribers.push(this.control.valueChanges.pipe(debounceTime(500)).subscribe(async keyword => {
+ if (keyword != null && typeof keyword !== 'string') {
+ this.control.setErrors(null);
+ return;
+ }
+
+ return this.search(keyword);
+ }));
+ }
+
+
+ public async ngOnInit(): Promise {
+ return this.initCandidates();
+ // Muss leider immer gemacht werden, damit klar ist, ob es sich um eine hierarchische Ansicht handelt oder nicht
+ }
+
+ public async ngAfterViewInit(): Promise {
+ if (this.columnContainer && this.columnContainer.canEdit && this.viewport) {
+ // Give a debounce to the stream so we don't get multiple calls and lose data
+ this.subscribers.push(this.viewport.renderedRangeStream.pipe(debounceTime(100)).subscribe(async (value: ListRange) => {
+ const bottom = this.parameters.StartIndex + this.pageSize;
+ if (value.end >= bottom) {
+ // Save old data, extend start index and delay the detecting of changes until we call within this function
+ const tmpCandidates: Candidate[] = this.candidates.map(candidate => candidate);
+ this.parameters.StartIndex += this.pageSize;
+ await this.updateCandidates(this.parameters, false);
+
+ // Append new data to old, keep scroll at the bottom, check the size, and detect changes
+ this.candidates = tmpCandidates.concat(...this.candidates);
+ this.viewport.scrollToIndex(bottom);
+ this.viewport.checkViewportSize();
+ this.changeDetectorRef.detectChanges();
+ }
+ }));
+ }
+ }
+
+ public ngOnDestroy(): void {
+ this.subscribers.forEach(s => s.unsubscribe());
+ }
+
+ public async inputFocus(): Promise {
+ if (!this.candidates?.length && !this.loading) {
+ await this.initCandidates();
+ }
+ }
+
+ public async onOpened(): Promise {
+ if (this.control.value) {
+ // Use the stashed values if we already have a selected value
+ this.parameters = this.savedParameters ?? { PageSize: this.pageSize, StartIndex: 0 };
+ if ((this.savedCandidates?.length ?? 0) > 0) {
+ this.candidates = this.savedCandidates;
+ }
+ } else if (this.parameters.search || this.parameters.filter) {
+ // If we don't have a chosen value, then we have residual values, reset them and update
+ await this.updateCandidates({ search: undefined, filter: undefined }, false);
+ }
+ if (this.viewport) {
+ this.viewport.scrollToIndex(0);
+ this.viewport.checkViewportSize();
+ this.changeDetectorRef.detectChanges();
+ }
+ }
+
+ public getDisplay(candidate: Candidate): string {
+ return candidate ? candidate.DisplayValue : undefined;
+ }
+
+ public async optionSelected(event: MatAutocompleteSelectedEvent): Promise {
+ // Save these parameters for later use, set start index back to zero
+ this.savedParameters = this.parameters;
+ this.savedCandidates = this.candidates;
+ return this.writeValue(event.option.value);
+ }
+
+ public async removeAssignment(event?: Event): Promise {
+ if (event) {
+ event.stopPropagation();
+ }
+
+ const value = { DataValue: undefined };
+ this.control.setValue(value, { emitEvent: false });
+ await this.writeValue(value);
+
+ // Also reset search, filter and update
+ if (this.parameters.search || this.parameters.filter) {
+ this.parameters.StartIndex = 0;
+ await this.updateCandidates({ search: undefined, filter: undefined });
+ }
+ this.viewport.scrollToIndex(0);
+
+ /* 298890
+ if (this.candidatesTotalCount === 0) {
+ return this.updateCandidates();
+ }
+ */
+ }
+
+ public close(event?: any): void {
+ if (this.control.value == null || typeof (this.control.value) === 'string') {
+ this.logger.debug(this, 'autoCompleteClose no match - reset to previous value', event);
+ this.control.setValue(this.getValueStruct(), { emitEvent: false });
+ }
+ }
+
+ /**
+ * @ignore
+ * Opens a dialog for selecting an object
+ */
+ public async editAssignment(event?: Event): Promise {
+ if (event) {
+ event.stopPropagation();
+ }
+
+ const dialogRef = this.sidesheet.open(this.isHierarchical ? FkHierarchicalDialogComponent : FkAdvancedPickerComponent, {
+ title: this.ldsReplace.transform(await this.translator.get('#LDS#Heading {0}').toPromise(),
+ await this.translator.get(this.columnContainer?.display).toPromise()),
+ headerColour: 'iris-blue',
+ panelClass: 'imx-sidesheet',
+ padding: '0',
+ disableClose: true,
+ width: '60%',
+ testId: this.isHierarchical ? 'edit-fk-hierarchy-sidesheet' : 'edit-fk-sidesheet',
+ data: {
+ fkRelations: this.columnContainer.fkRelations,
+ selectedTableName: this.selectedTable.TableName,
+ idList: this.columnContainer.value ? [this.columnContainer.value] : []
+ }
+ });
+
+ dialogRef.afterClosed().subscribe(async (selection: ForeignKeySelection) => {
+ if (selection) {
+ this.logger.debug(this, 'dialog ok', selection);
+ this.candidates = null;
+ this.selectedTable = selection.table;
+
+ if (!this.columnContainer.canEdit) {
+ return;
+ }
+
+ const value = selection.candidates && selection.candidates.length > 0 ? selection.candidates[0] : { DataValue: undefined };
+ this.control.setValue(value, { emitEvent: false });
+ await this.writeValue(value);
+
+ } else {
+ this.logger.debug(this, 'dialog cancel');
+ }
+ });
+ }
+
+ /**
+ * Binds a column dependent reference to the component
+ * @param cdref a column dependent reference
+ */
+ public bind(cdref: ColumnDependentReference): void {
+ if (cdref && cdref.column) {
+ this.columnContainer.init(cdref);
+ this.setControlValue();
+
+ // bind to entity change event
+ this.subscribers.push(this.columnContainer.subscribe(async () => {
+ if (this.isWriting) {
+ return;
+ }
+
+ if (this.control.value?.DataValue !== this.columnContainer.value) {
+ this.loading = true;
+ try {
+ this.logger.trace(this, `Control (${this.columnContainer.name}) set to new value:`,
+ this.columnContainer.value, this.control.value);
+ this.candidates = [];
+ this.setControlValue();
+
+ } finally {
+ this.loading = false;
+ this.changeDetectorRef.detectChanges();
+ }
+ }
+ this.valueHasChanged.emit({ value: this.control.value });
+ }));
+ this.logger.trace(this, 'Control initialized', this.control.value);
+ } else {
+ this.logger.error(this, 'The Column Dependent Reference is undefined');
+ }
+ }
+
+ private setControlValue(): void {
+ if (this.columnContainer.fkRelations && this.columnContainer.fkRelations.length > 0) {
+ let table: IForeignKeyInfo;
+ if (this.columnContainer.fkRelations.length > 1 && this.columnContainer.value) {
+ this.logger.trace(this, 'the column already has a value, and it is a dynamic foreign key');
+ const dbObjectKey = DbObjectKey.FromXml(this.columnContainer.value);
+ table = this.columnContainer.fkRelations.find(fkr => fkr.TableName === dbObjectKey.TableName);
+ }
+ this.selectedTable = table || this.columnContainer.fkRelations[0];
+
+ this.metadataProvider.update(this.columnContainer.fkRelations.map(fkr => fkr.TableName));
+ }
+ this.control.setValue(this.getValueStruct(), { emitEvent: false });
+ if (this.columnContainer.isValueRequired && this.columnContainer.canEdit) {
+ this.control.setValidators(control => control.value == null || control.value.length === 0 ? { required: true } : null);
+ }
+ }
+
+ /** loads the candidates and updates the listings */
+ private async initCandidates(): Promise {
+ if (this.columnContainer && this.columnContainer.canEdit) {
+ await this.updateCandidates({
+ StartIndex: 0,
+ PageSize: this.pageSize,
+ filter: undefined,
+ search: undefined
+ });
+
+ this.changeDetectorRef.detectChanges();
+ }
+ }
+
+ /**
+ * updates the value for the CDR
+ * @param value the new value
+ */
+ private async writeValue(value: ValueStruct): Promise {
+
+ this.logger.debug(this, 'writeValue called with value', value);
+
+ if (!this.columnContainer.canEdit || this.equal(this.getValueStruct(), value)) {
+ return;
+ }
+
+ this.isWriting = true;
+ this.loading = true;
+ try {
+
+ this.logger.debug(this, 'writeValue - updateCdrValue...');
+ await this.columnContainer.updateValueStruct(value);
+
+ const valueAfterWrite = this.getValueStruct();
+
+ if (!this.equal(this.control.value, valueAfterWrite)) {
+
+ this.control.setValue(valueAfterWrite, { emitEvent: false });
+
+ this.logger.debug(
+ this,
+ 'writeValue - value has changed after interaction with the Entity. Value:',
+ this.control.value
+ );
+ }
+
+ this.control.markAsDirty();
+ this.valueHasChanged.emit({ value, forceEmit: true });
+ } catch (error) {
+ this.errorHandler.handleError(error);
+ } finally {
+ this.loading = false;
+ this.isWriting = false;
+ this.changeDetectorRef.detectChanges();
+ }
+ }
+
+ private async updateCandidates(newState?: CollectionLoadParameters, isCheck: boolean = true): Promise {
+ if (this.selectedTable) {
+ try {
+ this.loading = true;
+ if (isCheck) {
+ this.changeDetectorRef.detectChanges();
+ }
+ this.parameters = { ...this.parameters, ...newState };
+ const candidateCollection = await this.selectedTable.Get(this.parameters);
+ // this.candidatesTotalCount = candidateCollection.TotalCount;
+
+ this.isHierarchical = candidateCollection.Hierarchy != null;
+
+ const multipleFkRelations = this.columnContainer.fkRelations && this.columnContainer.fkRelations.length > 1;
+ const identityRelatedTable = this.selectedTable.TableName === 'Person';
+
+ this.candidates = candidateCollection.Entities.map(entityData => {
+ let key: string = null;
+ let detailValue: string = entityData.LongDisplay;
+ const defaultEmailColumn = entityData.Columns['DefaultEmailAddress'];
+ /**
+ * If the candidates data relate to identities (fkRelation Person table)
+ * then we want to use the email address for the detail line (displayLong)
+ */
+ if (defaultEmailColumn && identityRelatedTable) {
+ detailValue = defaultEmailColumn.Value;
+ }
+ if (multipleFkRelations) {
+ this.logger.trace(this, 'dynamic foreign key');
+ const xObjectKeyColumn = entityData.Columns['XObjectKey'];
+ key = xObjectKeyColumn ? xObjectKeyColumn.Value : undefined;
+ } else {
+ this.logger.trace(this, 'foreign key');
+
+ const parentColumn = entityData.Columns ? entityData.Columns[this.columnContainer.fkRelations[0].ColumnName] : undefined;
+ if (parentColumn != null) {
+ this.logger.trace(this, 'Use value from explicit parent column');
+ key = parentColumn.Value;
+ } else {
+ this.logger.trace(this, 'Use the primary key');
+ const keys = entityData.Keys;
+ key = keys && keys.length ? keys[0] : undefined;
+ }
+ }
+ return {
+ DataValue: key,
+ DisplayValue: entityData.Display,
+ displayLong: detailValue
+ };
+ });
+ } finally {
+ this.loading = false;
+ if (isCheck) {
+ this.changeDetectorRef.detectChanges();
+ }
+ }
+ }
+ }
+
+ private getValueStruct(): ValueStruct {
+ if (this.columnContainer.value) {
+ return { DataValue: this.columnContainer.value, DisplayValue: this.columnContainer.displayValue || '' };
+ }
+
+ return undefined;
+ }
+
+ private equal(value: ValueStruct, value2: ValueStruct): boolean {
+ if (value && value2) {
+ return value.DataValue === value2.DataValue && value.DisplayValue === value.DisplayValue;
+ }
+
+ return value == null && value2 == null;
+ }
+
+ private async search(keyword: string): Promise {
+ this.parameters.StartIndex = 0;
+
+ await this.updateCandidates({ search: keyword });
+ this.viewport.scrollToIndex(0);
+ this.changeDetectorRef.detectChanges();
+
+ this.control.setErrors(
+ (keyword == null || this.candidates == null || this.candidates.length > 0) ?
+ null :
+ { checkAutocomplete: true }
+ );
+ }
+}
diff --git a/imxweb/projects/qbm/src/lib/cdr/edit-image/edit-image.component.spec.ts b/imxweb/projects/qbm/src/lib/cdr/edit-image/edit-image.component.spec.ts
index d79ebdb6e..f77d4f8df 100644
--- a/imxweb/projects/qbm/src/lib/cdr/edit-image/edit-image.component.spec.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/edit-image/edit-image.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/cdr/edit-image/edit-image.component.ts b/imxweb/projects/qbm/src/lib/cdr/edit-image/edit-image.component.ts
index adc62941c..87220638b 100644
--- a/imxweb/projects/qbm/src/lib/cdr/edit-image/edit-image.component.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/edit-image/edit-image.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -29,7 +29,7 @@ import { FormControl, Validators } from '@angular/forms';
import { Subscription } from 'rxjs';
import { ColumnDependentReference } from '../column-dependent-reference.interface';
-import { CdrEditor } from '../cdr-editor.interface';
+import { CdrEditor, ValueHasChangedEventArg } from '../cdr-editor.interface';
import { EntityColumnContainer } from '../entity-column-container';
import { ClassloggerService } from '../../classlogger/classlogger.service';
import { Base64ImageService } from '../../images/base64-image.service';
@@ -51,7 +51,7 @@ export class EditImageComponent implements CdrEditor, OnDestroy {
public readonly control = new FormControl(undefined);
public readonly columnContainer = new EntityColumnContainer();
- public readonly valueHasChanged = new EventEmitter();
+ public readonly valueHasChanged = new EventEmitter();
public isLoading = false;
@@ -96,7 +96,7 @@ export class EditImageComponent implements CdrEditor, OnDestroy {
this.logger.trace(this, 'Control set to new value');
this.control.setValue(this.columnContainer.value, { emitEvent: false });
}
- this.valueHasChanged.emit(this.control.value);
+ this.valueHasChanged.emit({value: this.control.value});
}));
}
}
@@ -105,6 +105,7 @@ export class EditImageComponent implements CdrEditor, OnDestroy {
this.fileFormatError = false;
}
+ // TODO: Check Upgrade
public emitFiles(files: FileList): void {
this.fileSelector.emitFiles(files, 'image/png');
}
@@ -147,6 +148,7 @@ export class EditImageComponent implements CdrEditor, OnDestroy {
this.control.setValue(this.columnContainer.value, { emitEvent: false });
this.logger.debug(this, 'form control value is set to', this.control.value);
}
+ this.valueHasChanged.emit({value: this.control.value, forceEmit: true});
}
this.control.markAsDirty();
diff --git a/imxweb/projects/qbm/src/lib/cdr/edit-limited-value/edit-limited-value.component.html b/imxweb/projects/qbm/src/lib/cdr/edit-limited-value/edit-limited-value.component.html
index eb445997f..27a73afc0 100644
--- a/imxweb/projects/qbm/src/lib/cdr/edit-limited-value/edit-limited-value.component.html
+++ b/imxweb/projects/qbm/src/lib/cdr/edit-limited-value/edit-limited-value.component.html
@@ -23,7 +23,7 @@
-
+
{{ '#LDS#This field is mandatory.' | translate }}
diff --git a/imxweb/projects/qbm/src/lib/cdr/edit-limited-value/edit-limited-value.component.scss b/imxweb/projects/qbm/src/lib/cdr/edit-limited-value/edit-limited-value.component.scss
index 9e50c3afb..d4992ad96 100644
--- a/imxweb/projects/qbm/src/lib/cdr/edit-limited-value/edit-limited-value.component.scss
+++ b/imxweb/projects/qbm/src/lib/cdr/edit-limited-value/edit-limited-value.component.scss
@@ -1,4 +1,4 @@
-@import "~@elemental-ui/core/src/styles/_palette.scss";
+@import "@elemental-ui/core/src/styles/_palette.scss";
:host {
display: flex;
@@ -21,4 +21,4 @@
margin-right: 5px;
margin-top: 0;
}
-}
\ No newline at end of file
+}
diff --git a/imxweb/projects/qbm/src/lib/cdr/edit-limited-value/edit-limited-value.component.spec.ts b/imxweb/projects/qbm/src/lib/cdr/edit-limited-value/edit-limited-value.component.spec.ts
index 49ac7e8d4..8f394b1cb 100644
--- a/imxweb/projects/qbm/src/lib/cdr/edit-limited-value/edit-limited-value.component.spec.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/edit-limited-value/edit-limited-value.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/cdr/edit-limited-value/edit-limited-value.component.ts b/imxweb/projects/qbm/src/lib/cdr/edit-limited-value/edit-limited-value.component.ts
index 3e799ea07..03bd03f4f 100644
--- a/imxweb/projects/qbm/src/lib/cdr/edit-limited-value/edit-limited-value.component.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/edit-limited-value/edit-limited-value.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/cdr/edit-multi-limited-value/edit-multi-limited-value.component.html b/imxweb/projects/qbm/src/lib/cdr/edit-multi-limited-value/edit-multi-limited-value.component.html
index 504a3cb9b..ed96b7e33 100644
--- a/imxweb/projects/qbm/src/lib/cdr/edit-multi-limited-value/edit-multi-limited-value.component.html
+++ b/imxweb/projects/qbm/src/lib/cdr/edit-multi-limited-value/edit-multi-limited-value.component.html
@@ -1,12 +1,12 @@
-
+{{ columnContainer?.display | translate }}
-
-
+
+
{{ item.Description }}
-
+
{{ '#LDS#This field is mandatory.' | translate }}
diff --git a/imxweb/projects/qbm/src/lib/cdr/edit-multi-limited-value/edit-multi-limited-value.component.scss b/imxweb/projects/qbm/src/lib/cdr/edit-multi-limited-value/edit-multi-limited-value.component.scss
index 597123042..4dfd20681 100644
--- a/imxweb/projects/qbm/src/lib/cdr/edit-multi-limited-value/edit-multi-limited-value.component.scss
+++ b/imxweb/projects/qbm/src/lib/cdr/edit-multi-limited-value/edit-multi-limited-value.component.scss
@@ -1,4 +1,4 @@
-@import '~@elemental-ui/core/src/styles/_palette.scss';
+@import '@elemental-ui/core/src/styles/_palette.scss';
.mat-form-field {
width: 100%;
@@ -19,4 +19,4 @@
::ng-deep .mat-checkbox-frame {
border-color: $phoenix-red;
}
-}
\ No newline at end of file
+}
diff --git a/imxweb/projects/qbm/src/lib/cdr/edit-multi-limited-value/edit-multi-limited-value.component.spec.ts b/imxweb/projects/qbm/src/lib/cdr/edit-multi-limited-value/edit-multi-limited-value.component.spec.ts
index f1818d0c2..1130abd91 100644
--- a/imxweb/projects/qbm/src/lib/cdr/edit-multi-limited-value/edit-multi-limited-value.component.spec.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/edit-multi-limited-value/edit-multi-limited-value.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/cdr/edit-multi-limited-value/edit-multi-limited-value.component.ts b/imxweb/projects/qbm/src/lib/cdr/edit-multi-limited-value/edit-multi-limited-value.component.ts
index 9622d8fc4..4968c84d3 100644
--- a/imxweb/projects/qbm/src/lib/cdr/edit-multi-limited-value/edit-multi-limited-value.component.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/edit-multi-limited-value/edit-multi-limited-value.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -31,7 +31,7 @@ import { Subscription } from 'rxjs';
import { LimitedValueData } from 'imx-qbm-dbts';
import { ColumnDependentReference } from '../column-dependent-reference.interface';
import { ClassloggerService } from '../../classlogger/classlogger.service';
-import { CdrEditor } from '../cdr-editor.interface';
+import { CdrEditor, ValueHasChangedEventArg } from '../cdr-editor.interface';
import { EntityColumnContainer } from '../entity-column-container';
import { MultiValueService } from '../../multi-value/multi-value.service';
@@ -44,11 +44,13 @@ import { MultiValueService } from '../../multi-value/multi-value.service';
styleUrls: ['./edit-multi-limited-value.component.scss']
})
export class EditMultiLimitedValueComponent implements CdrEditor, OnDestroy {
+
+ // TODO: Check Upgrade
public control = new FormArray([]);
public readonly columnContainer = new EntityColumnContainer();
- public readonly valueHasChanged = new EventEmitter();
+ public readonly valueHasChanged = new EventEmitter();
private readonly subscriptions: Subscription[] = [];
private isWriting = false;
@@ -78,7 +80,7 @@ export class EditMultiLimitedValueComponent implements CdrEditor, OnDestroy {
if (this.control.value !== this.columnContainer.value) {
this.initValues();
}
- this.valueHasChanged.emit(this.columnContainer.value);
+ this.valueHasChanged.emit({value: this.columnContainer.value});
}));
this.logger.trace(this, 'Control initialized');
} else {
@@ -116,7 +118,7 @@ export class EditMultiLimitedValueComponent implements CdrEditor, OnDestroy {
return;
}
- this.valueHasChanged.emit(value);
+ this.valueHasChanged.emit({value, forceEmit: true});
try {
this.logger.debug(this, 'writeValue - updateCdrValue...');
diff --git a/imxweb/projects/qbm/src/lib/cdr/edit-multi-value/edit-multi-value.component.html b/imxweb/projects/qbm/src/lib/cdr/edit-multi-value/edit-multi-value.component.html
index 33af93dec..5dd00abf8 100644
--- a/imxweb/projects/qbm/src/lib/cdr/edit-multi-value/edit-multi-value.component.html
+++ b/imxweb/projects/qbm/src/lib/cdr/edit-multi-value/edit-multi-value.component.html
@@ -1,7 +1,7 @@
{{ columnContainer?.display | translate }}
-
+
{{ '#LDS#This field is mandatory.' | translate }}
diff --git a/imxweb/projects/qbm/src/lib/cdr/edit-multi-value/edit-multi-value.component.spec.ts b/imxweb/projects/qbm/src/lib/cdr/edit-multi-value/edit-multi-value.component.spec.ts
index 7087e5ac2..8159c685a 100644
--- a/imxweb/projects/qbm/src/lib/cdr/edit-multi-value/edit-multi-value.component.spec.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/edit-multi-value/edit-multi-value.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/cdr/edit-multi-value/edit-multi-value.component.ts b/imxweb/projects/qbm/src/lib/cdr/edit-multi-value/edit-multi-value.component.ts
index b1e70c44c..5b16fca53 100644
--- a/imxweb/projects/qbm/src/lib/cdr/edit-multi-value/edit-multi-value.component.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/edit-multi-value/edit-multi-value.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -31,7 +31,7 @@ import { Subscription } from 'rxjs';
import { ColumnDependentReference } from '../column-dependent-reference.interface';
import { ClassloggerService } from '../../classlogger/classlogger.service';
import { EntityColumnContainer } from '../entity-column-container';
-import { CdrEditor } from '../cdr-editor.interface';
+import { CdrEditor, ValueHasChangedEventArg } from '../cdr-editor.interface';
import { MultiValueService } from '../../multi-value/multi-value.service';
/**
@@ -47,7 +47,7 @@ export class EditMultiValueComponent implements CdrEditor, OnDestroy {
public readonly columnContainer = new EntityColumnContainer();
- public readonly valueHasChanged = new EventEmitter();
+ public readonly valueHasChanged = new EventEmitter();
private readonly subscribers: Subscription[] = [];
private isWriting = false;
@@ -75,7 +75,7 @@ export class EditMultiValueComponent implements CdrEditor, OnDestroy {
if (this.control.value !== this.columnContainer.value) {
this.control.setValue(this.columnContainer.value);
}
- this.valueHasChanged.emit(this.control.value);
+ this.valueHasChanged.emit({value: this.control.value});
}));
this.subscribers.push(this.control.valueChanges.subscribe(async value => this.writeValue(this.fromTextArea(value))));
this.logger.trace(this, 'Control initialized');
@@ -109,7 +109,7 @@ export class EditMultiValueComponent implements CdrEditor, OnDestroy {
}
}
- this.valueHasChanged.emit(value);
+ this.valueHasChanged.emit({value, forceEmit: true});
}
private toTextArea(value: string): string {
diff --git a/imxweb/projects/qbm/src/lib/cdr/edit-multiline/edit-multiline.component.html b/imxweb/projects/qbm/src/lib/cdr/edit-multiline/edit-multiline.component.html
index c8735a2d0..eaf6eb559 100644
--- a/imxweb/projects/qbm/src/lib/cdr/edit-multiline/edit-multiline.component.html
+++ b/imxweb/projects/qbm/src/lib/cdr/edit-multiline/edit-multiline.component.html
@@ -7,7 +7,7 @@
-
+
{{ '#LDS#This field is mandatory.' | translate }}
-
\ No newline at end of file
+
diff --git a/imxweb/projects/qbm/src/lib/cdr/edit-multiline/edit-multiline.component.spec.ts b/imxweb/projects/qbm/src/lib/cdr/edit-multiline/edit-multiline.component.spec.ts
index 8bb185fc3..8f62bf21b 100644
--- a/imxweb/projects/qbm/src/lib/cdr/edit-multiline/edit-multiline.component.spec.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/edit-multiline/edit-multiline.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/cdr/edit-multiline/edit-multiline.component.ts b/imxweb/projects/qbm/src/lib/cdr/edit-multiline/edit-multiline.component.ts
index 6809e817a..f4edb529d 100644
--- a/imxweb/projects/qbm/src/lib/cdr/edit-multiline/edit-multiline.component.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/edit-multiline/edit-multiline.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/cdr/edit-number/edit-number.component.html b/imxweb/projects/qbm/src/lib/cdr/edit-number/edit-number.component.html
index 093c0d6d9..c9516d529 100644
--- a/imxweb/projects/qbm/src/lib/cdr/edit-number/edit-number.component.html
+++ b/imxweb/projects/qbm/src/lib/cdr/edit-number/edit-number.component.html
@@ -8,13 +8,13 @@
-
+
{{ '#LDS#WD_InputInvalidInteger' | translate | ldsReplace: control.value }}
-
+
{{ '#LDS#Please enter a number greater than or equal to {0}.' | translate | ldsReplace: columnContainer.valueConstraint.MinValue }}
-
+
{{ '#LDS#Please enter a number less than or equal to {0}.' | translate | ldsReplace: columnContainer.valueConstraint.MaxValue }}
diff --git a/imxweb/projects/qbm/src/lib/cdr/edit-number/edit-number.component.scss b/imxweb/projects/qbm/src/lib/cdr/edit-number/edit-number.component.scss
index 9e50c3afb..d4992ad96 100644
--- a/imxweb/projects/qbm/src/lib/cdr/edit-number/edit-number.component.scss
+++ b/imxweb/projects/qbm/src/lib/cdr/edit-number/edit-number.component.scss
@@ -1,4 +1,4 @@
-@import "~@elemental-ui/core/src/styles/_palette.scss";
+@import "@elemental-ui/core/src/styles/_palette.scss";
:host {
display: flex;
@@ -21,4 +21,4 @@
margin-right: 5px;
margin-top: 0;
}
-}
\ No newline at end of file
+}
diff --git a/imxweb/projects/qbm/src/lib/cdr/edit-number/edit-number.component.spec.ts b/imxweb/projects/qbm/src/lib/cdr/edit-number/edit-number.component.spec.ts
index 50b725321..c15bbf3c0 100644
--- a/imxweb/projects/qbm/src/lib/cdr/edit-number/edit-number.component.spec.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/edit-number/edit-number.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/cdr/edit-number/edit-number.component.ts b/imxweb/projects/qbm/src/lib/cdr/edit-number/edit-number.component.ts
index f428ec680..bf79c5ae1 100644
--- a/imxweb/projects/qbm/src/lib/cdr/edit-number/edit-number.component.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/edit-number/edit-number.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/cdr/edit-number/number-error.interface.ts b/imxweb/projects/qbm/src/lib/cdr/edit-number/number-error.interface.ts
index d0f53e1cd..242930208 100644
--- a/imxweb/projects/qbm/src/lib/cdr/edit-number/number-error.interface.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/edit-number/number-error.interface.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/cdr/edit-number/number-validator.service.spec.ts b/imxweb/projects/qbm/src/lib/cdr/edit-number/number-validator.service.spec.ts
index a2d44b11a..8443c60d2 100644
--- a/imxweb/projects/qbm/src/lib/cdr/edit-number/number-validator.service.spec.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/edit-number/number-validator.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/cdr/edit-number/number-validator.service.ts b/imxweb/projects/qbm/src/lib/cdr/edit-number/number-validator.service.ts
index 6c6171a08..817b254c0 100644
--- a/imxweb/projects/qbm/src/lib/cdr/edit-number/number-validator.service.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/edit-number/number-validator.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/cdr/edit-risk-index/edit-risk-index.component.scss b/imxweb/projects/qbm/src/lib/cdr/edit-risk-index/edit-risk-index.component.scss
index 300a0e803..d4acc9db1 100644
--- a/imxweb/projects/qbm/src/lib/cdr/edit-risk-index/edit-risk-index.component.scss
+++ b/imxweb/projects/qbm/src/lib/cdr/edit-risk-index/edit-risk-index.component.scss
@@ -1,4 +1,4 @@
-@import '~@elemental-ui/core/src/styles/_palette.scss';
+@import '@elemental-ui/core/src/styles/_palette.scss';
.slider-container {
display: flex;
align-items: center;
diff --git a/imxweb/projects/qbm/src/lib/cdr/edit-risk-index/edit-risk-index.component.spec.ts b/imxweb/projects/qbm/src/lib/cdr/edit-risk-index/edit-risk-index.component.spec.ts
index 15fa85666..e57be08ed 100644
--- a/imxweb/projects/qbm/src/lib/cdr/edit-risk-index/edit-risk-index.component.spec.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/edit-risk-index/edit-risk-index.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/cdr/edit-risk-index/edit-risk-index.component.ts b/imxweb/projects/qbm/src/lib/cdr/edit-risk-index/edit-risk-index.component.ts
index 79f7b5a1c..3a58bdda1 100644
--- a/imxweb/projects/qbm/src/lib/cdr/edit-risk-index/edit-risk-index.component.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/edit-risk-index/edit-risk-index.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/cdr/edit-url/edit-url.component.html b/imxweb/projects/qbm/src/lib/cdr/edit-url/edit-url.component.html
index a1665b121..40e6e63ec 100644
--- a/imxweb/projects/qbm/src/lib/cdr/edit-url/edit-url.component.html
+++ b/imxweb/projects/qbm/src/lib/cdr/edit-url/edit-url.component.html
@@ -5,7 +5,7 @@
{{ '#LDS#Please enter a valid URL in the format https://www.example.com or http://www.example.com respectively.' | translate }}
-
+
{{ '#LDS#This field is mandatory.' | translate }}
diff --git a/imxweb/projects/qbm/src/lib/cdr/edit-url/edit-url.component.spec.ts b/imxweb/projects/qbm/src/lib/cdr/edit-url/edit-url.component.spec.ts
index f04deba4d..a3cb3d7b6 100644
--- a/imxweb/projects/qbm/src/lib/cdr/edit-url/edit-url.component.spec.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/edit-url/edit-url.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/cdr/edit-url/edit-url.component.ts b/imxweb/projects/qbm/src/lib/cdr/edit-url/edit-url.component.ts
index 27527c22a..d56c6ef7e 100644
--- a/imxweb/projects/qbm/src/lib/cdr/edit-url/edit-url.component.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/edit-url/edit-url.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -29,7 +29,7 @@ import { FormControl, Validators } from '@angular/forms';
import { Subscription } from 'rxjs';
import { UrlValidatorService } from './url-validator.service';
-import { CdrEditor } from '../cdr-editor.interface';
+import { CdrEditor, ValueHasChangedEventArg } from '../cdr-editor.interface';
import { ColumnDependentReference } from '../column-dependent-reference.interface';
import { EntityColumnContainer } from '../entity-column-container';
@@ -42,7 +42,7 @@ export class EditUrlComponent implements CdrEditor, OnDestroy {
public readonly control = new FormControl('', { updateOn: 'blur' });
public readonly columnContainer = new EntityColumnContainer();
- public readonly valueHasChanged = new EventEmitter();
+ public readonly valueHasChanged = new EventEmitter();
private readonly subscribers: Subscription[] = [];
private isWriting = false;
@@ -69,7 +69,7 @@ export class EditUrlComponent implements CdrEditor, OnDestroy {
if (this.control.value !== this.columnContainer.value) {
this.control.setValue(this.columnContainer.value, { emitEvent: false });
}
- this.valueHasChanged.emit(this.control.value);
+ this.valueHasChanged.emit({ value: this.control.value });
}));
this.control.setValidators(validators);
@@ -94,6 +94,7 @@ export class EditUrlComponent implements CdrEditor, OnDestroy {
if (this.control.value !== this.columnContainer.value) {
this.control.setValue(this.columnContainer.value, { emitEvent: false });
}
+ this.valueHasChanged.emit({ value: this.control.value, forceEmit: true });
}
}
}
diff --git a/imxweb/projects/qbm/src/lib/cdr/edit-url/url-validator.service.spec.ts b/imxweb/projects/qbm/src/lib/cdr/edit-url/url-validator.service.spec.ts
index 51fd82b64..aa64f7881 100644
--- a/imxweb/projects/qbm/src/lib/cdr/edit-url/url-validator.service.spec.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/edit-url/url-validator.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/cdr/edit-url/url-validator.service.ts b/imxweb/projects/qbm/src/lib/cdr/edit-url/url-validator.service.ts
index 5bf17b33e..9e175102b 100644
--- a/imxweb/projects/qbm/src/lib/cdr/edit-url/url-validator.service.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/edit-url/url-validator.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/cdr/editor-base.spec.ts b/imxweb/projects/qbm/src/lib/cdr/editor-base.spec.ts
index 71029a6cd..d792fa5a4 100644
--- a/imxweb/projects/qbm/src/lib/cdr/editor-base.spec.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/editor-base.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/cdr/editor-base.ts b/imxweb/projects/qbm/src/lib/cdr/editor-base.ts
index 85c701422..7af7ca674 100644
--- a/imxweb/projects/qbm/src/lib/cdr/editor-base.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/editor-base.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -27,7 +27,7 @@ import { OnDestroy, Component, EventEmitter, ErrorHandler } from '@angular/core'
import { AbstractControl, Validators } from '@angular/forms';
import { Subscription } from 'rxjs';
-import { CdrEditor } from './cdr-editor.interface';
+import { CdrEditor, ValueHasChangedEventArg } from './cdr-editor.interface';
import { ColumnDependentReference } from './column-dependent-reference.interface';
import { ClassloggerService } from '../classlogger/classlogger.service';
import { EntityColumnContainer } from './entity-column-container';
@@ -42,7 +42,7 @@ export abstract class EditorBase implements CdrEditor, OnDestroy {
public readonly columnContainer = new EntityColumnContainer();
- public readonly valueHasChanged = new EventEmitter();
+ public readonly valueHasChanged = new EventEmitter();
public isBusy = false;
public lastError: ServerError;
@@ -58,7 +58,7 @@ export abstract class EditorBase implements CdrEditor, OnDestroy {
}
public get validationErrorMessage(): string {
- if (this.control.errors?.generalError) {
+ if (this.control.errors?.['generalError']) {
return this.lastError.toString();
}
}
@@ -85,7 +85,7 @@ export abstract class EditorBase implements CdrEditor, OnDestroy {
this.columnContainer.value, this.control.value);
this.setControlValue();
}
- this.valueHasChanged.emit(this.control.value);
+ this.valueHasChanged.emit({value: this.control.value});
}));
this.logger.trace(this, 'Control initialized');
@@ -136,6 +136,6 @@ export abstract class EditorBase implements CdrEditor, OnDestroy {
}
}
- this.valueHasChanged.emit(value);
+ this.valueHasChanged.emit({ value, forceEmit: true });
}
}
diff --git a/imxweb/projects/qbm/src/lib/cdr/entity-column-container.spec.ts b/imxweb/projects/qbm/src/lib/cdr/entity-column-container.spec.ts
index c5c3f6c58..fa8fb6aa4 100644
--- a/imxweb/projects/qbm/src/lib/cdr/entity-column-container.spec.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/entity-column-container.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/cdr/entity-column-container.ts b/imxweb/projects/qbm/src/lib/cdr/entity-column-container.ts
index 79c4f24b6..58b10539a 100644
--- a/imxweb/projects/qbm/src/lib/cdr/entity-column-container.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/entity-column-container.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/cdr/entity-column-editor/entity-column-editor.component.spec.ts b/imxweb/projects/qbm/src/lib/cdr/entity-column-editor/entity-column-editor.component.spec.ts
index 678570325..4985b7380 100644
--- a/imxweb/projects/qbm/src/lib/cdr/entity-column-editor/entity-column-editor.component.spec.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/entity-column-editor/entity-column-editor.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/cdr/entity-column-editor/entity-column-editor.component.ts b/imxweb/projects/qbm/src/lib/cdr/entity-column-editor/entity-column-editor.component.ts
index 2a5796c35..8bdb311c6 100644
--- a/imxweb/projects/qbm/src/lib/cdr/entity-column-editor/entity-column-editor.component.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/entity-column-editor/entity-column-editor.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -44,7 +44,7 @@ export class EntityColumnEditorComponent implements OnChanges {
@Output() public controlCreated = new EventEmitter<{ name: string; control: AbstractControl; }>();
public ngOnChanges(changes: SimpleChanges): void {
- if (changes.column || changes.readonly) {
+ if (changes['column'] || changes['readonly']) {
this.cdr = this.column ?
{
column: this.column,
diff --git a/imxweb/projects/qbm/src/lib/cdr/fk-cdr-editor-provider.spec.ts b/imxweb/projects/qbm/src/lib/cdr/fk-cdr-editor-provider.spec.ts
index 4b9d48420..277b6af20 100644
--- a/imxweb/projects/qbm/src/lib/cdr/fk-cdr-editor-provider.spec.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/fk-cdr-editor-provider.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/cdr/fk-cdr-editor-provider.ts b/imxweb/projects/qbm/src/lib/cdr/fk-cdr-editor-provider.ts
index 935e8f214..44727b0c0 100644
--- a/imxweb/projects/qbm/src/lib/cdr/fk-cdr-editor-provider.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/fk-cdr-editor-provider.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/cdr/limited-values-container.spec.ts b/imxweb/projects/qbm/src/lib/cdr/limited-values-container.spec.ts
index cd9e1d1f3..529e1c778 100644
--- a/imxweb/projects/qbm/src/lib/cdr/limited-values-container.spec.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/limited-values-container.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/cdr/limited-values-container.ts b/imxweb/projects/qbm/src/lib/cdr/limited-values-container.ts
index 005218c84..cfaf0cc16 100644
--- a/imxweb/projects/qbm/src/lib/cdr/limited-values-container.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/limited-values-container.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/cdr/property-viewer/property-viewer.component.spec.ts b/imxweb/projects/qbm/src/lib/cdr/property-viewer/property-viewer.component.spec.ts
index 8805cc5d6..4324229f9 100644
--- a/imxweb/projects/qbm/src/lib/cdr/property-viewer/property-viewer.component.spec.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/property-viewer/property-viewer.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/cdr/property-viewer/property-viewer.component.ts b/imxweb/projects/qbm/src/lib/cdr/property-viewer/property-viewer.component.ts
index 4b6f454cf..885c15aea 100644
--- a/imxweb/projects/qbm/src/lib/cdr/property-viewer/property-viewer.component.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/property-viewer/property-viewer.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/cdr/view-property-default/view-property-default.component.spec.ts b/imxweb/projects/qbm/src/lib/cdr/view-property-default/view-property-default.component.spec.ts
index 609b2a82e..8925369e7 100644
--- a/imxweb/projects/qbm/src/lib/cdr/view-property-default/view-property-default.component.spec.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/view-property-default/view-property-default.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/cdr/view-property-default/view-property-default.component.ts b/imxweb/projects/qbm/src/lib/cdr/view-property-default/view-property-default.component.ts
index cd20f3a4c..37c709303 100644
--- a/imxweb/projects/qbm/src/lib/cdr/view-property-default/view-property-default.component.ts
+++ b/imxweb/projects/qbm/src/lib/cdr/view-property-default/view-property-default.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/cdr/view-property/view-property.component.html b/imxweb/projects/qbm/src/lib/cdr/view-property/view-property.component.html
index d63779631..33614b504 100644
--- a/imxweb/projects/qbm/src/lib/cdr/view-property/view-property.component.html
+++ b/imxweb/projects/qbm/src/lib/cdr/view-property/view-property.component.html
@@ -1,4 +1,4 @@
{{'#LDS#Narrow the selection further down by: {0}' | transl
-
+ 0">
0">
{{'#LDS#Selected item' |translate}}:{{currentlySelectedFilter[0].GetColumn('LongDisplay').GetValue()}}
diff --git a/imxweb/projects/qbm/src/lib/data-source-toolbar/filter-tree/filter-tree.component.scss b/imxweb/projects/qbm/src/lib/data-source-toolbar/filter-tree/filter-tree.component.scss
index ade7e91ce..c8dcdd2b2 100644
--- a/imxweb/projects/qbm/src/lib/data-source-toolbar/filter-tree/filter-tree.component.scss
+++ b/imxweb/projects/qbm/src/lib/data-source-toolbar/filter-tree/filter-tree.component.scss
@@ -1,10 +1,21 @@
-@import "~@elemental-ui/core/src/styles/_palette.scss";
+@import "@elemental-ui/core/src/styles/_palette.scss";
:host {
display: flex;
flex-direction: column;
flex: 1 1 auto;
overflow: hidden;
- padding-bottom: 15px;
+ height: 100%;
+
+ ::ng-deep .mat-list-base {
+ .mat-list-item.imx-list-item {
+ height: auto;
+ }
+ }
+
+ ::ng-deep .mat-menu-panel {
+ padding: 10px;
+ max-width: 500px;
+ }
}
.imx-dialog-content {
@@ -25,10 +36,6 @@
}
}
-::ng-deep .mat-menu-panel {
- padding: 10px;
- max-width: 500px;
-}
.imx-badge {
background-color: $white;
@@ -42,8 +49,3 @@
margin: 5px 0;
}
-::ng-deep .mat-list-base {
- .mat-list-item.imx-list-item {
- height: auto;
- }
-}
diff --git a/imxweb/projects/qbm/src/lib/data-source-toolbar/filter-tree/filter-tree.component.spec.ts b/imxweb/projects/qbm/src/lib/data-source-toolbar/filter-tree/filter-tree.component.spec.ts
index 5acdeb03e..05ffe23a7 100644
--- a/imxweb/projects/qbm/src/lib/data-source-toolbar/filter-tree/filter-tree.component.spec.ts
+++ b/imxweb/projects/qbm/src/lib/data-source-toolbar/filter-tree/filter-tree.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/data-source-toolbar/filter-tree/filter-tree.component.ts b/imxweb/projects/qbm/src/lib/data-source-toolbar/filter-tree/filter-tree.component.ts
index b18426e64..78adc77fa 100644
--- a/imxweb/projects/qbm/src/lib/data-source-toolbar/filter-tree/filter-tree.component.ts
+++ b/imxweb/projects/qbm/src/lib/data-source-toolbar/filter-tree/filter-tree.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/data-source-toolbar/selection-model-wrapper.spec.ts b/imxweb/projects/qbm/src/lib/data-source-toolbar/selection-model-wrapper.spec.ts
index bef062d61..fb3d022e1 100644
--- a/imxweb/projects/qbm/src/lib/data-source-toolbar/selection-model-wrapper.spec.ts
+++ b/imxweb/projects/qbm/src/lib/data-source-toolbar/selection-model-wrapper.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/data-source-toolbar/selection-model-wrapper.ts b/imxweb/projects/qbm/src/lib/data-source-toolbar/selection-model-wrapper.ts
index aa384e995..b7af746a8 100644
--- a/imxweb/projects/qbm/src/lib/data-source-toolbar/selection-model-wrapper.ts
+++ b/imxweb/projects/qbm/src/lib/data-source-toolbar/selection-model-wrapper.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/data-table/data-table-additional-info.model.ts b/imxweb/projects/qbm/src/lib/data-table/data-table-additional-info.model.ts
index 187157ab1..4c8df586b 100644
--- a/imxweb/projects/qbm/src/lib/data-table/data-table-additional-info.model.ts
+++ b/imxweb/projects/qbm/src/lib/data-table/data-table-additional-info.model.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/data-table/data-table-cell/data-table-cell.component.html b/imxweb/projects/qbm/src/lib/data-table/data-table-cell/data-table-cell.component.html
index 87b037e78..6b6a5c5ee 100644
--- a/imxweb/projects/qbm/src/lib/data-table/data-table-cell/data-table-cell.component.html
+++ b/imxweb/projects/qbm/src/lib/data-table/data-table-cell/data-table-cell.component.html
@@ -1,6 +1,6 @@
-
- {{ property.Type === ValType.Date
- ? (column?.GetValue() | shortDate )
- : column?.GetDisplayValue()
- }}
+
+ {{ property.Type === ValType.Date
+ ? (column?.GetValue() | shortDate )
+ : column?.GetDisplayValue()
+ }}
\ No newline at end of file
diff --git a/imxweb/projects/qbm/src/lib/data-table/data-table-cell/data-table-cell.component.spec.ts b/imxweb/projects/qbm/src/lib/data-table/data-table-cell/data-table-cell.component.spec.ts
index c30ad72fe..b5f928f65 100644
--- a/imxweb/projects/qbm/src/lib/data-table/data-table-cell/data-table-cell.component.spec.ts
+++ b/imxweb/projects/qbm/src/lib/data-table/data-table-cell/data-table-cell.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/data-table/data-table-cell/data-table-cell.component.ts b/imxweb/projects/qbm/src/lib/data-table/data-table-cell/data-table-cell.component.ts
index c566e9472..e195fda41 100644
--- a/imxweb/projects/qbm/src/lib/data-table/data-table-cell/data-table-cell.component.ts
+++ b/imxweb/projects/qbm/src/lib/data-table/data-table-cell/data-table-cell.component.ts
@@ -1,51 +1,51 @@
-/*
- * ONE IDENTITY LLC. PROPRIETARY INFORMATION
- *
- * This software is confidential. One Identity, LLC. or one of its affiliates or
- * subsidiaries, has supplied this software to you under terms of a
- * license agreement, nondisclosure agreement or both.
- *
- * You may not copy, disclose, or use this software except in accordance with
- * those terms.
- *
- *
- * Copyright 2021 One Identity LLC.
- * ALL RIGHTS RESERVED.
- *
- * ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
- * WARRANTIES ABOUT THE SUITABILITY OF THE SOFTWARE,
- * EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
- * TO THE IMPLIED WARRANTIES OF MERCHANTABILITY,
- * FITNESS FOR A PARTICULAR PURPOSE, OR
- * NON-INFRINGEMENT. ONE IDENTITY LLC. SHALL NOT BE
- * LIABLE FOR ANY DAMAGES SUFFERED BY LICENSEE
- * AS A RESULT OF USING, MODIFYING OR DISTRIBUTING
- * THIS SOFTWARE OR ITS DERIVATIVES.
- *
- */
-
-import { Component, Input } from '@angular/core';
-
-import { IClientProperty, IEntityColumn, TypedEntity, ValType } from 'imx-qbm-dbts';
-
-@Component({
- selector: 'imx-data-table-cell',
- templateUrl: './data-table-cell.component.html',
- styleUrls: ['./data-table-cell.component.scss']
-})
-export class DataTableCellComponent {
-
- public readonly ValType = ValType;
-
- @Input() public entity: TypedEntity;
- @Input() public property: IClientProperty;
-
-
- public get column(): IEntityColumn{
- try{
- return this.entity.GetEntity().GetColumn(this.property.ColumnName);
- }catch {
- return undefined;
- }
- }
-}
+/*
+ * ONE IDENTITY LLC. PROPRIETARY INFORMATION
+ *
+ * This software is confidential. One Identity, LLC. or one of its affiliates or
+ * subsidiaries, has supplied this software to you under terms of a
+ * license agreement, nondisclosure agreement or both.
+ *
+ * You may not copy, disclose, or use this software except in accordance with
+ * those terms.
+ *
+ *
+ * Copyright 2022 One Identity LLC.
+ * ALL RIGHTS RESERVED.
+ *
+ * ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
+ * WARRANTIES ABOUT THE SUITABILITY OF THE SOFTWARE,
+ * EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
+ * TO THE IMPLIED WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE, OR
+ * NON-INFRINGEMENT. ONE IDENTITY LLC. SHALL NOT BE
+ * LIABLE FOR ANY DAMAGES SUFFERED BY LICENSEE
+ * AS A RESULT OF USING, MODIFYING OR DISTRIBUTING
+ * THIS SOFTWARE OR ITS DERIVATIVES.
+ *
+ */
+
+import { Component, Input } from '@angular/core';
+
+import { IClientProperty, IEntityColumn, TypedEntity, ValType } from 'imx-qbm-dbts';
+
+@Component({
+ selector: 'imx-data-table-cell',
+ templateUrl: './data-table-cell.component.html',
+ styleUrls: ['./data-table-cell.component.scss']
+})
+export class DataTableCellComponent {
+
+ public readonly ValType = ValType;
+
+ @Input() public entity: TypedEntity;
+ @Input() public property: IClientProperty;
+
+
+ public get column(): IEntityColumn{
+ try{
+ return this.entity.GetEntity().GetColumn(this.property.ColumnName);
+ }catch {
+ return undefined;
+ }
+ }
+}
diff --git a/imxweb/projects/qbm/src/lib/data-table/data-table-column.component.scss b/imxweb/projects/qbm/src/lib/data-table/data-table-column.component.scss
index 35197df87..73f57bd78 100644
--- a/imxweb/projects/qbm/src/lib/data-table/data-table-column.component.scss
+++ b/imxweb/projects/qbm/src/lib/data-table/data-table-column.component.scss
@@ -1,4 +1,4 @@
-@import '~@elemental-ui/core/src/styles/_palette.scss';
+@import '@elemental-ui/core/src/styles/_palette.scss';
td.mat-cell,
th.mat-header-cell {
diff --git a/imxweb/projects/qbm/src/lib/data-table/data-table-column.component.spec.ts b/imxweb/projects/qbm/src/lib/data-table/data-table-column.component.spec.ts
index da247d23e..0bf64f46e 100644
--- a/imxweb/projects/qbm/src/lib/data-table/data-table-column.component.spec.ts
+++ b/imxweb/projects/qbm/src/lib/data-table/data-table-column.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/data-table/data-table-column.component.ts b/imxweb/projects/qbm/src/lib/data-table/data-table-column.component.ts
index 20bbd6172..dba35c5cf 100644
--- a/imxweb/projects/qbm/src/lib/data-table/data-table-column.component.ts
+++ b/imxweb/projects/qbm/src/lib/data-table/data-table-column.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/data-table/data-table-display-cell/data-table-display-cell.component.scss b/imxweb/projects/qbm/src/lib/data-table/data-table-display-cell/data-table-display-cell.component.scss
index 12433ae92..16694cef1 100644
--- a/imxweb/projects/qbm/src/lib/data-table/data-table-display-cell/data-table-display-cell.component.scss
+++ b/imxweb/projects/qbm/src/lib/data-table/data-table-display-cell/data-table-display-cell.component.scss
@@ -1,6 +1,6 @@
-@import '~@elemental-ui/core/src/styles/_palette.scss';
+@import '@elemental-ui/core/src/styles/_palette.scss';
div[subtitle] {
font-size: smaller;
color: $black-9;
-}
\ No newline at end of file
+}
diff --git a/imxweb/projects/qbm/src/lib/data-table/data-table-display-cell/data-table-display-cell.component.spec.ts b/imxweb/projects/qbm/src/lib/data-table/data-table-display-cell/data-table-display-cell.component.spec.ts
index 545131091..b929494d0 100644
--- a/imxweb/projects/qbm/src/lib/data-table/data-table-display-cell/data-table-display-cell.component.spec.ts
+++ b/imxweb/projects/qbm/src/lib/data-table/data-table-display-cell/data-table-display-cell.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/data-table/data-table-display-cell/data-table-display-cell.component.ts b/imxweb/projects/qbm/src/lib/data-table/data-table-display-cell/data-table-display-cell.component.ts
index 343da17cc..2ecd65f0c 100644
--- a/imxweb/projects/qbm/src/lib/data-table/data-table-display-cell/data-table-display-cell.component.ts
+++ b/imxweb/projects/qbm/src/lib/data-table/data-table-display-cell/data-table-display-cell.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/data-table/data-table-generic-column.component.spec.ts b/imxweb/projects/qbm/src/lib/data-table/data-table-generic-column.component.spec.ts
index b8bfb0b8c..22b28f539 100644
--- a/imxweb/projects/qbm/src/lib/data-table/data-table-generic-column.component.spec.ts
+++ b/imxweb/projects/qbm/src/lib/data-table/data-table-generic-column.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/data-table/data-table-generic-column.component.ts b/imxweb/projects/qbm/src/lib/data-table/data-table-generic-column.component.ts
index 96b455be3..28f5811f6 100644
--- a/imxweb/projects/qbm/src/lib/data-table/data-table-generic-column.component.ts
+++ b/imxweb/projects/qbm/src/lib/data-table/data-table-generic-column.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/data-table/data-table-groups.interface.ts b/imxweb/projects/qbm/src/lib/data-table/data-table-groups.interface.ts
index eeea30fbd..9f82e0870 100644
--- a/imxweb/projects/qbm/src/lib/data-table/data-table-groups.interface.ts
+++ b/imxweb/projects/qbm/src/lib/data-table/data-table-groups.interface.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/data-table/data-table-row-highlight.interface.ts b/imxweb/projects/qbm/src/lib/data-table/data-table-row-highlight.interface.ts
index a97fc8295..dfe0b3d77 100644
--- a/imxweb/projects/qbm/src/lib/data-table/data-table-row-highlight.interface.ts
+++ b/imxweb/projects/qbm/src/lib/data-table/data-table-row-highlight.interface.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/data-table/data-table.component.scss b/imxweb/projects/qbm/src/lib/data-table/data-table.component.scss
index 45d1e271e..d769c83b9 100644
--- a/imxweb/projects/qbm/src/lib/data-table/data-table.component.scss
+++ b/imxweb/projects/qbm/src/lib/data-table/data-table.component.scss
@@ -1,5 +1,5 @@
/* You can add styles to this file, and also import other style files */
-@import '~@elemental-ui/core/src/styles/_palette.scss';
+@import '@elemental-ui/core/src/styles/_palette.scss';
:host {
overflow-y: auto;
diff --git a/imxweb/projects/qbm/src/lib/data-table/data-table.component.spec.ts b/imxweb/projects/qbm/src/lib/data-table/data-table.component.spec.ts
index e9fc72bdd..411afa2d9 100644
--- a/imxweb/projects/qbm/src/lib/data-table/data-table.component.spec.ts
+++ b/imxweb/projects/qbm/src/lib/data-table/data-table.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/data-table/data-table.component.ts b/imxweb/projects/qbm/src/lib/data-table/data-table.component.ts
index 45dd8cceb..3d0aa090f 100644
--- a/imxweb/projects/qbm/src/lib/data-table/data-table.component.ts
+++ b/imxweb/projects/qbm/src/lib/data-table/data-table.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -324,7 +324,7 @@ export class DataTableComponent implements OnChanges, AfterViewInit, OnDestro
*/
public async ngOnChanges(changes: SimpleChanges): Promise {
- if (changes.mode && changes.mode.currentValue) {
+ if (changes['mode'] && changes['mode'].currentValue) {
if (this.mode === 'auto') {
if (this.dst.dataSourceChanged && this.columnDefs) {
this.columnDefs.forEach(colDef => this.table.removeColumnDef(colDef));
@@ -332,7 +332,7 @@ export class DataTableComponent implements OnChanges, AfterViewInit, OnDestro
}
}
- if (changes.dst && changes.dst.currentValue) {
+ if (changes['dst'] && changes['dst'].currentValue) {
this.subscriptions.push(this.dst.settingsChanged.subscribe(async (value: DataSourceToolbarSettings) => {
if (this.dst.dataSourceHasChanged) {
diff --git a/imxweb/projects/qbm/src/lib/data-table/data-table.module.ts b/imxweb/projects/qbm/src/lib/data-table/data-table.module.ts
index 19fcaf85b..cf1a0709f 100644
--- a/imxweb/projects/qbm/src/lib/data-table/data-table.module.ts
+++ b/imxweb/projects/qbm/src/lib/data-table/data-table.module.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/data-table/selection-list/selection-list.component.spec.ts b/imxweb/projects/qbm/src/lib/data-table/selection-list/selection-list.component.spec.ts
index 181e6d040..1f4c05d2a 100644
--- a/imxweb/projects/qbm/src/lib/data-table/selection-list/selection-list.component.spec.ts
+++ b/imxweb/projects/qbm/src/lib/data-table/selection-list/selection-list.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/data-table/selection-list/selection-list.component.ts b/imxweb/projects/qbm/src/lib/data-table/selection-list/selection-list.component.ts
index 0eab5cc21..d48f05bcd 100644
--- a/imxweb/projects/qbm/src/lib/data-table/selection-list/selection-list.component.ts
+++ b/imxweb/projects/qbm/src/lib/data-table/selection-list/selection-list.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/data-tiles/data-tile-menu-item.interface.ts b/imxweb/projects/qbm/src/lib/data-tiles/data-tile-menu-item.interface.ts
index 21f6e3892..402dc5e1f 100644
--- a/imxweb/projects/qbm/src/lib/data-tiles/data-tile-menu-item.interface.ts
+++ b/imxweb/projects/qbm/src/lib/data-tiles/data-tile-menu-item.interface.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -31,7 +31,8 @@ import { TypedEntity } from 'imx-qbm-dbts';
*/
export interface DataTileMenuItem {
name: string;
- description: string;
+ description?: string;
typedEntity?: TypedEntity;
- tileSelected?: boolean
+ tileSelected?: boolean;
+ useOnDisabledTile?: boolean;
}
diff --git a/imxweb/projects/qbm/src/lib/data-tiles/data-tile.component.html b/imxweb/projects/qbm/src/lib/data-tiles/data-tile.component.html
index e6faaebc6..ad4091763 100644
--- a/imxweb/projects/qbm/src/lib/data-tiles/data-tile.component.html
+++ b/imxweb/projects/qbm/src/lib/data-tiles/data-tile.component.html
@@ -35,8 +35,8 @@
[matTooltip]="getTitleDisplayValue(subtitleObject.ColumnName)">
{{getTitleDisplayValue(subtitleObject.ColumnName)}}
-
\ No newline at end of file
+
diff --git a/imxweb/projects/qbm/src/lib/data-tiles/data-tile.component.scss b/imxweb/projects/qbm/src/lib/data-tiles/data-tile.component.scss
index 2c44cf450..da9693549 100644
--- a/imxweb/projects/qbm/src/lib/data-tiles/data-tile.component.scss
+++ b/imxweb/projects/qbm/src/lib/data-tiles/data-tile.component.scss
@@ -1,4 +1,4 @@
-@import '~@elemental-ui/core/src/styles/_palette.scss';
+@import '@elemental-ui/core/src/styles/_palette.scss';
@mixin imx-data-tile-title-mixin {
white-space: nowrap;
diff --git a/imxweb/projects/qbm/src/lib/data-tiles/data-tile.component.spec.ts b/imxweb/projects/qbm/src/lib/data-tiles/data-tile.component.spec.ts
index e1ad968b2..1a200dec0 100644
--- a/imxweb/projects/qbm/src/lib/data-tiles/data-tile.component.spec.ts
+++ b/imxweb/projects/qbm/src/lib/data-tiles/data-tile.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -197,18 +197,22 @@ describe('DataTileComponent', () => {
});
}
- [
- { expected: false },
- { status: {}, expected: false },
- { status: { getImage: {} }, expected: true },
- { image: {}, expected: true },
- { fallbackIcon: 'some icon', expected: true }
- ].forEach(testcase =>
- it('should check if it has an image (or a fallback icon)', () => {
- component.image = testcase.image as IClientProperty;
- component.status = testcase.status as DataSourceItemStatus;
- component.fallbackIcon = testcase.fallbackIcon;
-
- expect(component.hasImage).toEqual(testcase.expected);
- }));
+ describe('should check if it has an image (or a fallback icon) - ', () => {
+ [
+ { description: 'has nothing', expected: false },
+ { description: 'has an empty status', status: {}, expected: false },
+ { description: 'has a status with an imagepath', status: { getImagePath: {} }, expected: true },
+ { description: 'has an image', image: {}, expected: true },
+ { description: 'has a fallback icon', fallbackIcon: 'some icon', expected: true }
+ ].forEach(testcase =>
+ it(`${testcase.description}`, () => {
+ component.image = testcase.image as IClientProperty;
+ component.status = testcase.status as DataSourceItemStatus;
+ component.fallbackIcon = testcase.fallbackIcon;
+
+ expect(component.hasImage).toEqual(testcase.expected);
+ }));
+ });
+
+
});
diff --git a/imxweb/projects/qbm/src/lib/data-tiles/data-tile.component.ts b/imxweb/projects/qbm/src/lib/data-tiles/data-tile.component.ts
index 34c0b2ef6..3917b870e 100644
--- a/imxweb/projects/qbm/src/lib/data-tiles/data-tile.component.ts
+++ b/imxweb/projects/qbm/src/lib/data-tiles/data-tile.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -60,7 +60,11 @@ export class DataTileComponent implements OnInit {
}
public get hasImage(): boolean {
- return this.image != null || this.status?.getImage != null || this.fallbackIcon != null;
+ return (this.image || this.status?.getImagePath || this.fallbackIcon) ? true : false;
+ }
+
+ public get filteredActions(): DataTileMenuItem[] {
+ return this.enabled ? this.actions : this.actions.filter(elem => elem.useOnDisabledTile);
}
public isLoadingImage: boolean;
@@ -157,6 +161,7 @@ export class DataTileComponent implements OnInit {
*/
@Output() public selectionChanged = new EventEmitter();
+ // TODO: Check Upgrade
@Output() public badgeClicked = new EventEmitter<{ entity: TypedEntity, badge: DataTileBadge }>();
/**
@@ -178,19 +183,10 @@ export class DataTileComponent implements OnInit {
this.selectedHint = 'background-color: #F2F2F2;'
}
- if (this.status?.getImage) {
+ if (this.status?.getImagePath) {
this.isLoadingImage = true;
- const blob = await this.status.getImage(this.typedEntity);
- if (blob) {
- const reader = new FileReader();
- reader.readAsDataURL(blob);
- reader.onload = () => {
- this.imageUrl = reader.result;
- this.isLoadingImage = false;
- }
- } else {
- this.isLoadingImage = false;
- }
+ this.imageUrl = await this.status.getImagePath(this.typedEntity);
+ this.isLoadingImage = false;
} else if (this.image?.ColumnName) {
this.imageUrl = this.base64ImageService.addBase64Prefix(
this.typedEntity.GetEntity().GetColumn(this.image.ColumnName).GetValue()
diff --git a/imxweb/projects/qbm/src/lib/data-tiles/data-tiles.component.scss b/imxweb/projects/qbm/src/lib/data-tiles/data-tiles.component.scss
index bf5f4f623..70bc55b57 100644
--- a/imxweb/projects/qbm/src/lib/data-tiles/data-tiles.component.scss
+++ b/imxweb/projects/qbm/src/lib/data-tiles/data-tiles.component.scss
@@ -1,5 +1,5 @@
/* You can add styles to this file, and also import other style files */
-@import '~@elemental-ui/core/src/styles/_palette.scss';
+@import '@elemental-ui/core/src/styles/_palette.scss';
:host {
display: flex;
diff --git a/imxweb/projects/qbm/src/lib/data-tiles/data-tiles.component.spec.ts b/imxweb/projects/qbm/src/lib/data-tiles/data-tiles.component.spec.ts
index 084f0734a..cf15ef03e 100644
--- a/imxweb/projects/qbm/src/lib/data-tiles/data-tiles.component.spec.ts
+++ b/imxweb/projects/qbm/src/lib/data-tiles/data-tiles.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/data-tiles/data-tiles.component.ts b/imxweb/projects/qbm/src/lib/data-tiles/data-tiles.component.ts
index c3af644b3..ae1200965 100644
--- a/imxweb/projects/qbm/src/lib/data-tiles/data-tiles.component.ts
+++ b/imxweb/projects/qbm/src/lib/data-tiles/data-tiles.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -125,12 +125,12 @@ export class DataTilesComponent implements OnChanges, OnDestroy {
/**
* The width of a tile.
*/
- @Input() public width = "340px";
+ @Input() public width = '340px';
/**
* The height of a tile.
*/
- @Input() public height: "140px";
+ @Input() public height: '140px';
@Input() public useActionMenu = true;
@@ -167,7 +167,7 @@ export class DataTilesComponent implements OnChanges, OnDestroy {
* Listens for changes of data table inputs e.g. checks it the datasource has changed.
*/
public ngOnChanges(changes: SimpleChanges): void {
- if (changes.dst && changes.dst.currentValue) {
+ if (changes['dst'] && changes['dst'].currentValue) {
this.subscriptions.push(this.dst.selectionChanged.subscribe((event: SelectionChange) =>
this.selectionChanged.emit(event.source.selected)
));
diff --git a/imxweb/projects/qbm/src/lib/data-tiles/data-tiles.module.ts b/imxweb/projects/qbm/src/lib/data-tiles/data-tiles.module.ts
index fac6f93c9..22665a304 100644
--- a/imxweb/projects/qbm/src/lib/data-tiles/data-tiles.module.ts
+++ b/imxweb/projects/qbm/src/lib/data-tiles/data-tiles.module.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/data-tree-wrapper/data-tree-wrapper.component.spec.ts b/imxweb/projects/qbm/src/lib/data-tree-wrapper/data-tree-wrapper.component.spec.ts
index 7cdb018dc..39389fa32 100644
--- a/imxweb/projects/qbm/src/lib/data-tree-wrapper/data-tree-wrapper.component.spec.ts
+++ b/imxweb/projects/qbm/src/lib/data-tree-wrapper/data-tree-wrapper.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/data-tree-wrapper/data-tree-wrapper.component.ts b/imxweb/projects/qbm/src/lib/data-tree-wrapper/data-tree-wrapper.component.ts
index 72de9bbcb..92f887d5d 100644
--- a/imxweb/projects/qbm/src/lib/data-tree-wrapper/data-tree-wrapper.component.ts
+++ b/imxweb/projects/qbm/src/lib/data-tree-wrapper/data-tree-wrapper.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/data-tree-wrapper/data-tree-wrapper.module.ts b/imxweb/projects/qbm/src/lib/data-tree-wrapper/data-tree-wrapper.module.ts
index 068003743..ad37be779 100644
--- a/imxweb/projects/qbm/src/lib/data-tree-wrapper/data-tree-wrapper.module.ts
+++ b/imxweb/projects/qbm/src/lib/data-tree-wrapper/data-tree-wrapper.module.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/data-tree/checkable-tree/checkable-tree.component.scss b/imxweb/projects/qbm/src/lib/data-tree/checkable-tree/checkable-tree.component.scss
index 8d666b83c..4522ecc1a 100644
--- a/imxweb/projects/qbm/src/lib/data-tree/checkable-tree/checkable-tree.component.scss
+++ b/imxweb/projects/qbm/src/lib/data-tree/checkable-tree/checkable-tree.component.scss
@@ -1,4 +1,4 @@
-@import "~@elemental-ui/core/src/styles/_palette.scss";
+@import "@elemental-ui/core/src/styles/_palette.scss";
.imx-background-highlight {
background-color: $asher-gray;
diff --git a/imxweb/projects/qbm/src/lib/data-tree/checkable-tree/checkable-tree.component.spec.ts b/imxweb/projects/qbm/src/lib/data-tree/checkable-tree/checkable-tree.component.spec.ts
index 3565e2f70..73692298e 100644
--- a/imxweb/projects/qbm/src/lib/data-tree/checkable-tree/checkable-tree.component.spec.ts
+++ b/imxweb/projects/qbm/src/lib/data-tree/checkable-tree/checkable-tree.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/data-tree/checkable-tree/checkable-tree.component.ts b/imxweb/projects/qbm/src/lib/data-tree/checkable-tree/checkable-tree.component.ts
index f7f7e9731..75eb6e7f9 100644
--- a/imxweb/projects/qbm/src/lib/data-tree/checkable-tree/checkable-tree.component.ts
+++ b/imxweb/projects/qbm/src/lib/data-tree/checkable-tree/checkable-tree.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -104,10 +104,10 @@ export class CheckableTreeComponent implements OnChanges, AfterViewInit, OnDestr
public async ngOnChanges(changes: SimpleChanges): Promise {
this.checklistSelection = new SelectionModel(this.withMultiSelect);
- if (changes.navigationState) {
+ if (changes['navigationState']) {
this.reload();
}
- if (changes.database) {
+ if (changes['database']) {
this.logger.debug(this, `initialize the treeDatasource`);
this.treeDataSource = new TreeDatasource(this.treeControl, this.database);
this.treeDataSource.emptyNodeCaption = this.emptyNodeCaption;
@@ -117,8 +117,8 @@ export class CheckableTreeComponent implements OnChanges, AfterViewInit, OnDestr
this.logger.debug(this, `toggle Node of the selected entity to load its children`);
}
- if (changes.selectedEntities && changes.selectedEntities.currentValue && changes.selectedEntities.currentValue.length === 1) {
- const key = this.getId(changes.selectedEntities.currentValue[0]);
+ if (changes['selectedEntities'] && changes['selectedEntities'].currentValue && changes['selectedEntities'].currentValue.length === 1) {
+ const key = this.getId(changes['selectedEntities'].currentValue[0]);
if (key !== '') {
if (this.treeControl.dataNodes != null) {
diff --git a/imxweb/projects/qbm/src/lib/data-tree/data-tree-no-results.scss b/imxweb/projects/qbm/src/lib/data-tree/data-tree-no-results.scss
index 0f1493a23..c32a9af28 100644
--- a/imxweb/projects/qbm/src/lib/data-tree/data-tree-no-results.scss
+++ b/imxweb/projects/qbm/src/lib/data-tree/data-tree-no-results.scss
@@ -1,4 +1,4 @@
-@import "~@elemental-ui/core/src/styles/_palette.scss";
+@import "@elemental-ui/core/src/styles/_palette.scss";
.imx-data-tree-no-results {
text-align: center;
diff --git a/imxweb/projects/qbm/src/lib/data-tree/data-tree-search-results/data-tree-search-results.component.scss b/imxweb/projects/qbm/src/lib/data-tree/data-tree-search-results/data-tree-search-results.component.scss
index 46de9c40b..7c2fec6fb 100644
--- a/imxweb/projects/qbm/src/lib/data-tree/data-tree-search-results/data-tree-search-results.component.scss
+++ b/imxweb/projects/qbm/src/lib/data-tree/data-tree-search-results/data-tree-search-results.component.scss
@@ -1,4 +1,4 @@
-@import "~@elemental-ui/core/src/styles/_palette.scss";
+@import "@elemental-ui/core/src/styles/_palette.scss";
:host {
flex: 1 1 auto;
diff --git a/imxweb/projects/qbm/src/lib/data-tree/data-tree-search-results/data-tree-search-results.component.spec.ts b/imxweb/projects/qbm/src/lib/data-tree/data-tree-search-results/data-tree-search-results.component.spec.ts
index 8e4e8be74..d788519d4 100644
--- a/imxweb/projects/qbm/src/lib/data-tree/data-tree-search-results/data-tree-search-results.component.spec.ts
+++ b/imxweb/projects/qbm/src/lib/data-tree/data-tree-search-results/data-tree-search-results.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/data-tree/data-tree-search-results/data-tree-search-results.component.ts b/imxweb/projects/qbm/src/lib/data-tree/data-tree-search-results/data-tree-search-results.component.ts
index b6cedb319..049c5bf3d 100644
--- a/imxweb/projects/qbm/src/lib/data-tree/data-tree-search-results/data-tree-search-results.component.ts
+++ b/imxweb/projects/qbm/src/lib/data-tree/data-tree-search-results/data-tree-search-results.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -66,7 +66,7 @@ export class DataTreeSearchResultsComponent implements OnChanges {
@Input() public database: TreeDatabase;
@Input() public navigationState: CollectionLoadParameters;
-
+
@Input() public withSelectedNodeHighlight: boolean;
@ContentChild(TemplateRef, { static: true }) public templateRef: TemplateRef;
@@ -95,7 +95,7 @@ export class DataTreeSearchResultsComponent implements OnChanges {
constructor(private readonly logger: ClassloggerService) { }
public async ngOnChanges(changes: SimpleChanges): Promise {
- if (changes.navigationState) {
+ if (changes['navigationState']) {
await this.reload();
}
}
@@ -178,7 +178,7 @@ export class DataTreeSearchResultsComponent implements OnChanges {
}
private getId(entity: IEntity): string {
- return this.database ? this.database.getId(entity) : entity.GetKeys()[0];
+ return this.database ? this.database.getId(entity) : entity.GetKeys()[0];
}
}
diff --git a/imxweb/projects/qbm/src/lib/data-tree/data-tree-search-results/search-result-action.interface.ts b/imxweb/projects/qbm/src/lib/data-tree/data-tree-search-results/search-result-action.interface.ts
index 449ec061d..2c702999c 100644
--- a/imxweb/projects/qbm/src/lib/data-tree/data-tree-search-results/search-result-action.interface.ts
+++ b/imxweb/projects/qbm/src/lib/data-tree/data-tree-search-results/search-result-action.interface.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/data-tree/data-tree.component.scss b/imxweb/projects/qbm/src/lib/data-tree/data-tree.component.scss
index d506eb709..d6cd09277 100644
--- a/imxweb/projects/qbm/src/lib/data-tree/data-tree.component.scss
+++ b/imxweb/projects/qbm/src/lib/data-tree/data-tree.component.scss
@@ -1,4 +1,4 @@
-@import "~@elemental-ui/core/src/styles/_palette.scss";
+@import "@elemental-ui/core/src/styles/_palette.scss";
:host {
display: flex;
diff --git a/imxweb/projects/qbm/src/lib/data-tree/data-tree.component.spec.ts b/imxweb/projects/qbm/src/lib/data-tree/data-tree.component.spec.ts
index 0ced8cae9..b98400d2d 100644
--- a/imxweb/projects/qbm/src/lib/data-tree/data-tree.component.spec.ts
+++ b/imxweb/projects/qbm/src/lib/data-tree/data-tree.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/data-tree/data-tree.component.ts b/imxweb/projects/qbm/src/lib/data-tree/data-tree.component.ts
index 1b3aee1db..7a361c831 100644
--- a/imxweb/projects/qbm/src/lib/data-tree/data-tree.component.ts
+++ b/imxweb/projects/qbm/src/lib/data-tree/data-tree.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -106,7 +106,7 @@ export class DataTreeComponent implements OnChanges, OnDestroy {
}
public async ngOnChanges(changes: SimpleChanges): Promise {
- if (changes.database) {
+ if (changes['database']) {
this.hasTreeData = true; // because of 298890: (await this.database.getData(true, { PageSize: -1 })).totalCount > 0;
}
}
diff --git a/imxweb/projects/qbm/src/lib/data-tree/data-tree.module.ts b/imxweb/projects/qbm/src/lib/data-tree/data-tree.module.ts
index 2c879ee91..772e6bada 100644
--- a/imxweb/projects/qbm/src/lib/data-tree/data-tree.module.ts
+++ b/imxweb/projects/qbm/src/lib/data-tree/data-tree.module.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/data-tree/entity-tree-database.ts b/imxweb/projects/qbm/src/lib/data-tree/entity-tree-database.ts
index 7c26b9561..d53793150 100644
--- a/imxweb/projects/qbm/src/lib/data-tree/entity-tree-database.ts
+++ b/imxweb/projects/qbm/src/lib/data-tree/entity-tree-database.ts
@@ -1,68 +1,68 @@
-/*
- * ONE IDENTITY LLC. PROPRIETARY INFORMATION
- *
- * This software is confidential. One Identity, LLC. or one of its affiliates or
- * subsidiaries, has supplied this software to you under terms of a
- * license agreement, nondisclosure agreement or both.
- *
- * You may not copy, disclose, or use this software except in accordance with
- * those terms.
- *
- *
- * Copyright 2021 One Identity LLC.
- * ALL RIGHTS RESERVED.
- *
- * ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
- * WARRANTIES ABOUT THE SUITABILITY OF THE SOFTWARE,
- * EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
- * TO THE IMPLIED WARRANTIES OF MERCHANTABILITY,
- * FITNESS FOR A PARTICULAR PURPOSE, OR
- * NON-INFRINGEMENT. ONE IDENTITY LLC. SHALL NOT BE
- * LIABLE FOR ANY DAMAGES SUFFERED BY LICENSEE
- * AS A RESULT OF USING, MODIFYING OR DISTRIBUTING
- * THIS SOFTWARE OR ITS DERIVATIVES.
- *
- */
-
-import { OverlayRef } from '@angular/cdk/overlay';
-import { EuiLoadingService } from '@elemental-ui/core';
-
-import { CollectionLoadParameters, IEntity } from 'imx-qbm-dbts';
-import { TreeDatabase } from './tree-database';
-import { TreeNodeResultParameter } from './tree-node-result-parameter.interface';
-
-export class EntityTreeDatabase extends TreeDatabase {
-
- private busyIndicator: OverlayRef;
-
- constructor(
- private readonly getEntities: (parameters: CollectionLoadParameters) => Promise,
- private readonly busyService: EuiLoadingService
- ) {
- super();
- }
-
- public async getData(showLoading: boolean, parameters: CollectionLoadParameters = {}): Promise {
- let entities: IEntity[];
- if (showLoading) {
- if (!this.busyIndicator) {
- setTimeout(() => (this.busyIndicator = this.busyService.show()));
- }
- }
-
- try {
- entities = await this.getEntities(parameters);
- } finally {
- if (showLoading) {
- if (this.busyIndicator) {
- setTimeout(() => {
- this.busyService.hide(this.busyIndicator);
- this.busyIndicator = undefined;
- });
- }
- }
- }
-
- return { entities, canLoadMore: false, totalCount: entities.length };
- }
-}
+/*
+ * ONE IDENTITY LLC. PROPRIETARY INFORMATION
+ *
+ * This software is confidential. One Identity, LLC. or one of its affiliates or
+ * subsidiaries, has supplied this software to you under terms of a
+ * license agreement, nondisclosure agreement or both.
+ *
+ * You may not copy, disclose, or use this software except in accordance with
+ * those terms.
+ *
+ *
+ * Copyright 2022 One Identity LLC.
+ * ALL RIGHTS RESERVED.
+ *
+ * ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
+ * WARRANTIES ABOUT THE SUITABILITY OF THE SOFTWARE,
+ * EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
+ * TO THE IMPLIED WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE, OR
+ * NON-INFRINGEMENT. ONE IDENTITY LLC. SHALL NOT BE
+ * LIABLE FOR ANY DAMAGES SUFFERED BY LICENSEE
+ * AS A RESULT OF USING, MODIFYING OR DISTRIBUTING
+ * THIS SOFTWARE OR ITS DERIVATIVES.
+ *
+ */
+
+import { OverlayRef } from '@angular/cdk/overlay';
+import { EuiLoadingService } from '@elemental-ui/core';
+
+import { CollectionLoadParameters, IEntity } from 'imx-qbm-dbts';
+import { TreeDatabase } from './tree-database';
+import { TreeNodeResultParameter } from './tree-node-result-parameter.interface';
+
+export class EntityTreeDatabase extends TreeDatabase {
+
+ private busyIndicator: OverlayRef;
+
+ constructor(
+ private readonly getEntities: (parameters: CollectionLoadParameters) => Promise,
+ private readonly busyService: EuiLoadingService
+ ) {
+ super();
+ }
+
+ public async getData(showLoading: boolean, parameters: CollectionLoadParameters = {}): Promise {
+ let entities: IEntity[];
+ if (showLoading) {
+ if (!this.busyIndicator) {
+ setTimeout(() => (this.busyIndicator = this.busyService.show()));
+ }
+ }
+
+ try {
+ entities = await this.getEntities(parameters);
+ } finally {
+ if (showLoading) {
+ if (this.busyIndicator) {
+ setTimeout(() => {
+ this.busyService.hide(this.busyIndicator);
+ this.busyIndicator = undefined;
+ });
+ }
+ }
+ }
+
+ return { entities, canLoadMore: false, totalCount: entities.length };
+ }
+}
diff --git a/imxweb/projects/qbm/src/lib/data-tree/mat-selection-list-multiple-directive.ts b/imxweb/projects/qbm/src/lib/data-tree/mat-selection-list-multiple-directive.ts
index 3025124f6..876e1f5c4 100644
--- a/imxweb/projects/qbm/src/lib/data-tree/mat-selection-list-multiple-directive.ts
+++ b/imxweb/projects/qbm/src/lib/data-tree/mat-selection-list-multiple-directive.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/data-tree/node-checked-change.interface.ts b/imxweb/projects/qbm/src/lib/data-tree/node-checked-change.interface.ts
index 1dc157f7c..58b1cd13d 100644
--- a/imxweb/projects/qbm/src/lib/data-tree/node-checked-change.interface.ts
+++ b/imxweb/projects/qbm/src/lib/data-tree/node-checked-change.interface.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/data-tree/tree-database.ts b/imxweb/projects/qbm/src/lib/data-tree/tree-database.ts
index c082c9c6c..b03177581 100644
--- a/imxweb/projects/qbm/src/lib/data-tree/tree-database.ts
+++ b/imxweb/projects/qbm/src/lib/data-tree/tree-database.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/data-tree/tree-datasource.spec.ts b/imxweb/projects/qbm/src/lib/data-tree/tree-datasource.spec.ts
index 4a0bdbc08..b1b02bac9 100644
--- a/imxweb/projects/qbm/src/lib/data-tree/tree-datasource.spec.ts
+++ b/imxweb/projects/qbm/src/lib/data-tree/tree-datasource.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/data-tree/tree-datasource.ts b/imxweb/projects/qbm/src/lib/data-tree/tree-datasource.ts
index 9ae08d2a3..552172324 100644
--- a/imxweb/projects/qbm/src/lib/data-tree/tree-datasource.ts
+++ b/imxweb/projects/qbm/src/lib/data-tree/tree-datasource.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/data-tree/tree-node-result-parameter.interface.ts b/imxweb/projects/qbm/src/lib/data-tree/tree-node-result-parameter.interface.ts
index c20e39bec..0a8ec7eb3 100644
--- a/imxweb/projects/qbm/src/lib/data-tree/tree-node-result-parameter.interface.ts
+++ b/imxweb/projects/qbm/src/lib/data-tree/tree-node-result-parameter.interface.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/data-tree/tree-node.ts b/imxweb/projects/qbm/src/lib/data-tree/tree-node.ts
index ab556952e..cb4b7e99f 100644
--- a/imxweb/projects/qbm/src/lib/data-tree/tree-node.ts
+++ b/imxweb/projects/qbm/src/lib/data-tree/tree-node.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/data-tree/tree-selection-list/tree-selection-list.component.scss b/imxweb/projects/qbm/src/lib/data-tree/tree-selection-list/tree-selection-list.component.scss
index 9d6821f0a..c6eb3f111 100644
--- a/imxweb/projects/qbm/src/lib/data-tree/tree-selection-list/tree-selection-list.component.scss
+++ b/imxweb/projects/qbm/src/lib/data-tree/tree-selection-list/tree-selection-list.component.scss
@@ -1,4 +1,4 @@
-@import "~@elemental-ui/core/src/styles/_palette.scss";
+@import "@elemental-ui/core/src/styles/_palette.scss";
:host {
display: flex;
flex-direction: column;
diff --git a/imxweb/projects/qbm/src/lib/data-tree/tree-selection-list/tree-selection-list.component.spec.ts b/imxweb/projects/qbm/src/lib/data-tree/tree-selection-list/tree-selection-list.component.spec.ts
index fbabea172..72556195c 100644
--- a/imxweb/projects/qbm/src/lib/data-tree/tree-selection-list/tree-selection-list.component.spec.ts
+++ b/imxweb/projects/qbm/src/lib/data-tree/tree-selection-list/tree-selection-list.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/data-tree/tree-selection-list/tree-selection-list.component.ts b/imxweb/projects/qbm/src/lib/data-tree/tree-selection-list/tree-selection-list.component.ts
index f7631528e..3afb4669d 100644
--- a/imxweb/projects/qbm/src/lib/data-tree/tree-selection-list/tree-selection-list.component.ts
+++ b/imxweb/projects/qbm/src/lib/data-tree/tree-selection-list/tree-selection-list.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/date/date.module.ts b/imxweb/projects/qbm/src/lib/date/date.module.ts
index e57a736ea..8f92f688d 100644
--- a/imxweb/projects/qbm/src/lib/date/date.module.ts
+++ b/imxweb/projects/qbm/src/lib/date/date.module.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -49,17 +49,20 @@ import { DateComponent } from './date/date.component';
import { CalendarComponent } from './date/calendar/calendar.component';
import { TimePickerComponent } from './date/time-picker/time-picker.component';
import { ShortDatePipe } from './short-date.pipe';
+import { LocalizedDatePipe } from './localized-date.pipe';
@NgModule({
declarations: [
ShortDatePipe,
+ LocalizedDatePipe,
DateComponent,
CalendarComponent,
TimePickerComponent
],
exports: [
DateComponent,
- ShortDatePipe
+ ShortDatePipe,
+ LocalizedDatePipe
],
imports: [
A11yModule,
diff --git a/imxweb/projects/qbm/src/lib/date/date/calendar/calendar.component.ts b/imxweb/projects/qbm/src/lib/date/date/calendar/calendar.component.ts
index d5bffbbd8..f36254b9d 100644
--- a/imxweb/projects/qbm/src/lib/date/date/calendar/calendar.component.ts
+++ b/imxweb/projects/qbm/src/lib/date/date/calendar/calendar.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -28,7 +28,8 @@ import { AfterViewInit, Component, EventEmitter, HostListener, Input, OnInit, Ou
import { AbstractControl } from '@angular/forms';
import { MatCalendar, MatCalendarUserEvent } from '@angular/material/datepicker';
import { DbVal } from 'imx-qbm-dbts';
-import * as moment from 'moment-timezone';
+import moment from 'moment-timezone';
+import { Moment } from 'moment-timezone';
/**
* Internal wrapper component around material calendar to pick a Moment date value.
@@ -93,7 +94,7 @@ export class CalendarComponent implements OnInit, AfterViewInit {
*
* the wrapped material calendar.
*/
- @ViewChild(MatCalendar) private calendar: MatCalendar;
+ @ViewChild(MatCalendar) private calendar: MatCalendar;
/**
* @ignore AfterViewInit lifecycle hook.
@@ -117,7 +118,7 @@ export class CalendarComponent implements OnInit, AfterViewInit {
*
* Handler for the dateChanged event of the material calendar.
*/
- public onDateChanged(event: MatCalendarUserEvent): void {
+ public onDateChanged(event: MatCalendarUserEvent): void {
this.datePickerDate = moment(event.value).clone();
this.control.setValue(this.datePickerDate);
}
diff --git a/imxweb/projects/qbm/src/lib/date/date/date-parser.spec.ts b/imxweb/projects/qbm/src/lib/date/date/date-parser.spec.ts
index 5243d2589..8657080e2 100644
--- a/imxweb/projects/qbm/src/lib/date/date/date-parser.spec.ts
+++ b/imxweb/projects/qbm/src/lib/date/date/date-parser.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -26,12 +26,12 @@
import { ClassloggerService } from '../../classlogger/classlogger.service';
import { DateParser } from './date-parser';
-import * as moment from 'moment-timezone';
+import moment from 'moment-timezone';
describe('DateParser', () => {
const mockLogger: ClassloggerService = jasmine.createSpyObj("ClassloggerService", ["debug"]);
-
+
beforeEach(() => {
// set en-US as default locale
moment.locale('en-US');
@@ -47,10 +47,10 @@ describe('DateParser', () => {
it('should cast away seconds in full format', () => {
let parser = new DateParser(mockLogger, true);
-
+
// note: month unlike the other nmbers is zero based, so december is month 11.
let m = moment({year: 2100, month:11, day: 31, hour:23, minute: 47, second: 42});
-
+
expect(parser.format(m)).toEqual('12/31/2100 11:47 PM');
});
@@ -83,10 +83,10 @@ describe('DateParser', () => {
{ text: '13/22/2100 11:47', valid: false},
].forEach(testcase => it(`should ${testcase.valid ? '' : 'not '}parse as date: ${testcase.text}`, () => {
let result = DateParser.parseDate(testcase.text);
-
- expect(result).toBeDefined();
+
+ expect(result).toBeDefined();
expect(result.isValid()).toBe(testcase.valid);
-
+
if (testcase.valid) {
expect(result.year()).toBe(testcase.year);
expect(result.month()).toBe(testcase.month);
@@ -114,10 +114,10 @@ describe('DateParser', () => {
{ text: '13/22/2100 11:47', valid: true, hour: 13, minute: 47},
].forEach(testcase => it(`should ${testcase.valid ? '' : 'not '}parse as time: ${testcase.text}`, () => {
let result = DateParser.parseTime(testcase.text);
-
- expect(result).toBeDefined();
+
+ expect(result).toBeDefined();
expect(result.isValid()).toBe(testcase.valid);
-
+
if (testcase.valid) {
const now = moment();
expect(result.year()).toBe(now.year());
@@ -143,7 +143,7 @@ describe('DateParser', () => {
expect(parser.parseDateAndTimeString('\t')).toBeUndefined();
});
- [
+ [
{ text: '12/22/2100 11:47', valid: true, year: 2100, month: 11, day: 22, hour: 11, minute: 47},
{ text: '12/22/2100 14:47', valid: true, year: 2100, month: 11, day: 22, hour: 14, minute: 47},
{ text: '12/22/2100 2:47 PM', valid: true, year: 2100, month: 11, day: 22, hour: 14, minute: 47},
@@ -156,20 +156,19 @@ describe('DateParser', () => {
{ locale: 'de-DE', text: '22.12.2100 2:47', valid: true, year: 2100, month: 11, day: 22, hour: 2, minute: 47},
{ locale: 'de-DE', text: '22.12.2100 2:47', valid: true, year: 2100, month: 11, day: 22, excludeTime: true},
{ locale: 'de-DE', text: '1.2.03 4:5', valid: true, year: 2003, month: 1, day: 1, excludeTime: true},
- // if time is required but not given, the result is invalid
- { locale: 'de-DE', text: '22.12.2100', valid: false},
+ { locale: 'de-DE', text: '22.12.2100', valid: true, year: 2100, month: 11, day: 22, hour: 0, minute: 0}, // because the time is added internally
].forEach(testcase => it(`should ${testcase.valid ? '' : 'not '}parse as date and time: ${testcase.text}`, () => {
-
+
if (testcase.locale) {
moment.locale(testcase.locale);
}
let withTime =! testcase.excludeTime;
let result = new DateParser(mockLogger, withTime).parseDateAndTimeString(testcase.text);
-
- expect(result).toBeDefined();
+
+ expect(result).toBeDefined();
expect(result.isValid()).toBe(testcase.valid);
-
+
if (testcase.valid) {
expect(result.year()).toBe(testcase.year);
expect(result.month()).toBe(testcase.month);
diff --git a/imxweb/projects/qbm/src/lib/date/date/date-parser.ts b/imxweb/projects/qbm/src/lib/date/date/date-parser.ts
index 81fb7f44f..4d51da715 100644
--- a/imxweb/projects/qbm/src/lib/date/date/date-parser.ts
+++ b/imxweb/projects/qbm/src/lib/date/date/date-parser.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -25,7 +25,8 @@
*/
import { ClassloggerService } from '../../classlogger/classlogger.service';
-import * as moment from 'moment-timezone';
+import moment from 'moment-timezone';
+import { Moment } from 'moment-timezone';
/**
@@ -67,14 +68,14 @@ export class DateParser {
* @param logger The logger
* @param withTime Whether the string should contain a time part.
*/
- constructor(private logger: ClassloggerService, private withTime: boolean) {}
+ constructor(private logger: ClassloggerService, private withTime: boolean) { }
/**
* Returns the formatted value for a given date (and time).
* @param date The date (and time).
* @returns The string representation of the date (and time).
*/
- public format(date: moment): string {
+ public format(date: Moment): string {
return date?.format(this.fullFormat) ?? '';
}
@@ -86,10 +87,10 @@ export class DateParser {
* @param text The string representation
* @returns A moment according to the date and time part.
*/
- public parseDateAndTimeString(dateAndTimeString: string): moment {
+ public parseDateAndTimeString(dateAndTimeString: string): Moment {
try {
- if (! dateAndTimeString || dateAndTimeString.trim().length === 0) {
+ if (!dateAndTimeString || dateAndTimeString.trim().length === 0) {
return undefined;
}
@@ -99,33 +100,33 @@ export class DateParser {
return moment.invalid();
}
- if (! this.withTime) {
+ if (!this.withTime) {
return moment(date.format(DateParser.FORMAT_DATE), DateParser.FORMAT_DATE, true);
}
const time = DateParser.parseTime(dateAndTimeString);
- if (! time.isValid()) {
- this.logger.debug(this, `Invalid time: '${dateAndTimeString}' does not define a valid time.`);
- return moment.invalid();
+ if (!time.isValid()) {
+ return moment(date.format(DateParser.FORMAT_DATEANDTIME), DateParser.FORMAT_DATEANDTIME, true);
}
// date and time have not necessarily been evaluated in 'strict' mode.
// that's ok, but at least their separate values need to match the combined value then.
const combined = moment(dateAndTimeString, DateParser.FORMAT_DATEANDTIME, false);
- if (! combined.isValid()
- || combined.year() !== date.year()
- || combined.month() !== date.month()
- || combined.date() !== date.date()
- || combined.hour() !== time.hour()
- || combined.seconds() !== time.seconds()) {
- return moment.invalid();
+ if (!combined.isValid()
+ || combined.year() !== date.year()
+ || combined.month() !== date.month()
+ || combined.date() !== date.date()
+ || combined.hour() !== time.hour()
+ || combined.seconds() !== time.seconds()) {
+ return moment.invalid();
+
}
// We cannot simply parse the date and time string, since the moment.js documentation suggests
// that this is not guaranteed to work in a pleasant manner.
// So we create the moment with just the date parts we need (no milliseconds or so).
- let m = moment({year: date.year(), month: date.month(), day: date.date(), hour: time.hour(), minute: time.minute()});
+ let m = moment({ year: date.year(), month: date.month(), day: date.date(), hour: time.hour(), minute: time.minute() });
// Right now the moment instance is missing the right formatting information.
// Reconstruction with the parsing constructor helps.
@@ -134,8 +135,8 @@ export class DateParser {
return m;
} catch (error) {
- this.logger.debug(this, `Invalid date string '${dateAndTimeString}': ${error}`);
- return moment('invalid');
+ this.logger.debug(this, `Invalid date string '${dateAndTimeString}': ${error}`);
+ return moment('invalid');
}
}
@@ -149,7 +150,7 @@ export class DateParser {
* @param value a moment possibly containing more than date
* @returns a clean date only moment
*/
- public static asDateOnly(value: moment): moment {
+ public static asDateOnly(value: Moment): Moment {
return value?.isValid() ? moment(moment(value).format(DateParser.FORMAT_DATE), DateParser.FORMAT_DATE, true) : undefined;
}
@@ -163,7 +164,7 @@ export class DateParser {
* @param value a moment possibly containing more than time
* @returns a clean time only moment
*/
- public static asTimeOnly(value: moment): moment {
+ public static asTimeOnly(value: Moment): Moment {
return value?.isValid() ? moment(moment(value).format(DateParser.FORMAT_TIME), DateParser.FORMAT_TIME, true) : undefined;
}
@@ -178,16 +179,19 @@ export class DateParser {
* @param text The string representation
* @returns A moment according to the date part.
*/
- public static parseDate(text: string): moment {
+ public static parseDate(text: string): Moment {
const s = (text ?? '').trim();
let date = moment(s, DateParser.FORMAT_DATE, true);
- if (!date.isValid()) {
+ if (!date.isValid()) {
// maybe it's s.th. like 3/4/21 instead of 04/04/2021
// we look for that.
const generous = moment(s, DateParser.FORMAT_DATE, false);
- if (generous.isValid() && (! generous.unusedInput || generous.unusedUnput.length === 0)) {
+
+ // TODO: Reactivate
+ // if (generous.isValid() && (! generous.unusedInput || generous.unusedInput.length === 0)) {
+ if (generous.isValid()) {
date = generous;
}
}
@@ -195,43 +199,44 @@ export class DateParser {
return date;
}
- /**
- * Parses the time part of a string representation of a date (and time).
- *
- * This function is half-strict.
- * The end of the string should be a strictly valid time but the start of the
- * string doesn't care as long as it is clearly {@link SEPARATOR_BETWEEN_DATE_AND_TIME|separated}.
- *
- * If parsing fails the return value will not be undefined but {@link https://momentjs.com/docs/#/parsing/|invalid}.
- * @param text The string representation
- * @returns A moment according to the time part.
- */
- public static parseTime(text: string): moment {
- const s = (text ?? '').trim();
- let time = moment(s, DateParser.FORMAT_TIME, true);
-
- // if invalid, maybe the time part is prefixed by a valid date?
- if (! time.isValid() && DateParser.parseDate(s).isValid()) {
- const separatorIndex = s.indexOf(DateParser.SEPARATOR_BETWEEN_DATE_AND_TIME);
-
- const suffix = separatorIndex > 0 ? s.substring(separatorIndex + 1).trim() : '';
- if (suffix.length === 0) {
- // if there is no suffix, there is no time
- return moment.invalid();
- } else {
- // try to parse the rest as time - this could still be invalid though
- time = moment(suffix, DateParser.FORMAT_TIME, false);
- }
- }
- // if still invalid, try being generous
- if (! time.isValid()) {
- time = moment(s, DateParser.FORMAT_TIME, false);
+ /**
+ * Parses the time part of a string representation of a date (and time).
+ *
+ * This function is half-strict.
+ * The end of the string should be a strictly valid time but the start of the
+ * string doesn't care as long as it is clearly {@link SEPARATOR_BETWEEN_DATE_AND_TIME|separated}.
+ *
+ * If parsing fails the return value will not be undefined but {@link https://momentjs.com/docs/#/parsing/|invalid}.
+ * @param text The string representation
+ * @returns A moment according to the time part.
+ */
+ public static parseTime(text: string): Moment {
+ const s = (text ?? '').trim();
+ let time = moment(s, DateParser.FORMAT_TIME, true);
+
+ // if invalid, maybe the time part is prefixed by a valid date?
+ if (!time.isValid() && DateParser.parseDate(s).isValid()) {
+ const separatorIndex = s.indexOf(DateParser.SEPARATOR_BETWEEN_DATE_AND_TIME);
+
+ const suffix = separatorIndex > 0 ? s.substring(separatorIndex + 1).trim() : '';
+ if (suffix.length === 0) {
+ // if there is no suffix, there is no time
+ return moment.invalid();
+ } else {
+ // try to parse the rest as time - this could still be invalid though
+ time = moment(suffix, DateParser.FORMAT_TIME, false);
}
+ }
- return time;
+ // if still invalid, try being generous
+ if (!time.isValid()) {
+ time = moment(s, DateParser.FORMAT_TIME, false);
}
+ return time;
+ }
+
/**
* @ignore
*
diff --git a/imxweb/projects/qbm/src/lib/date/date/date.component.html b/imxweb/projects/qbm/src/lib/date/date/date.component.html
index 94080a2e2..f5ca8bfba 100644
--- a/imxweb/projects/qbm/src/lib/date/date/date.component.html
+++ b/imxweb/projects/qbm/src/lib/date/date/date.component.html
@@ -1,6 +1,6 @@
{{ display | translate }}
-
@@ -8,14 +8,14 @@
mat-icon-button type="button" class="mat-focus-indicator mat-icon-button mat-button-base"
aria-haspopup="dialog" aria-label="Open calendar"
[class.mat-datepicker-toggle-active]="isDatePickerOpen">
-
+
-
+
diff --git a/imxweb/projects/qbm/src/lib/date/date/date.component.ts b/imxweb/projects/qbm/src/lib/date/date/date.component.ts
index 6eb3860f4..b0d5955e0 100644
--- a/imxweb/projects/qbm/src/lib/date/date/date.component.ts
+++ b/imxweb/projects/qbm/src/lib/date/date/date.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -27,7 +27,8 @@
import { Component, Input, OnInit, OnDestroy } from '@angular/core';
import { AbstractControl, FormControl, ValidationErrors, ValidatorFn, Validators } from '@angular/forms';
-import * as moment from 'moment-timezone';
+import moment from 'moment-timezone';
+import { Moment } from 'moment-timezone';
import { Subscription } from 'rxjs';
import { ClassloggerService } from '../../classlogger/classlogger.service';
import { DateParser } from './date-parser';
@@ -46,21 +47,21 @@ import { DateParser } from './date-parser';
styleUrls: ['./date.component.scss']
})
export class DateComponent implements OnInit, OnDestroy {
-// ######################################################################################################
-// INTERNAL REMARKS
-// This component utilizes three internal form fields
-// 1. a text form field bound to a text input - contains the text representation of the date (and time).
-// 2. a moment form field for the date part only bound to a calendar picker.
-// 3. a moment form field for the time part only bound to a time picker.
-//
-// @1: The text to date parsing logic (and vice versa) has been extracted to a separate DateParser class.
-// @2: The date picker is basically a wrapper around the material calendar.
-// @3: The time picker is basically a wrapper around the elemental time picker.
-//
-// Validation is done twice.
-// a) on the text input field within this form - simply necessary because this is the primary form field.
-// b) on the input control - necessary for proper integration into outside form validation.
-// ######################################################################################################
+ // ######################################################################################################
+ // INTERNAL REMARKS
+ // This component utilizes three internal form fields
+ // 1. a text form field bound to a text input - contains the text representation of the date (and time).
+ // 2. a moment form field for the date part only bound to a calendar picker.
+ // 3. a moment form field for the time part only bound to a time picker.
+ //
+ // @1: The text to date parsing logic (and vice versa) has been extracted to a separate DateParser class.
+ // @2: The date picker is basically a wrapper around the material calendar.
+ // @3: The time picker is basically a wrapper around the elemental time picker.
+ //
+ // Validation is done twice.
+ // a) on the text input field within this form - simply necessary because this is the primary form field.
+ // b) on the input control - necessary for proper integration into outside form validation.
+ // ######################################################################################################
/**
* The input form control holding the {@link https://momentjs.com/docs/|Moment} value to be displayed / edited.
@@ -111,7 +112,7 @@ export class DateComponent implements OnInit, OnDestroy {
*
* If true a time picker is accessible in addition to the calendar date picker.
*/
- @Input() public withTime: true;
+ @Input() public withTime = true;
/**
* @ignore only public because of databinding in template
@@ -139,7 +140,7 @@ export class DateComponent implements OnInit, OnDestroy {
*
* internal shadow form control for the calendar date picker. Only holds the date part (i.e. without time).
*/
- public shadowDate = new FormControl();
+ public shadowDate = new FormControl();
/**
* @ignore only public because of databinding in template
@@ -153,7 +154,7 @@ export class DateComponent implements OnInit, OnDestroy {
* the result of the internal shadow form control.
* Useful to avoid unecessay update loop when writing back the value to the input control.
*/
- private result: moment;
+ private result: Moment;
/**
* @ignore
@@ -189,15 +190,15 @@ export class DateComponent implements OnInit, OnDestroy {
public get validationErrorKey(): string {
const errors = this.shadowText.errors;
- if (errors?.matDatepickerMin || errors?.matDatepickerMax) {
+ if (errors?.['matDatepickerMin'] || errors?.['matDatepickerMax']) {
return '#LDS#The date you entered is outside of the allowed range.';
}
- if (errors?.matDatepickerParse) {
+ if (errors?.['matDatepickerParse']) {
return '#LDS#The value you entered is not a valid date.';
}
- if (errors?.required) {
+ if (errors?.['required']) {
return '#LDS#This field is mandatory.';
}
@@ -233,7 +234,7 @@ export class DateComponent implements OnInit, OnDestroy {
* Bound internally to the click on the calendar icon button.
*/
public toggleDatePickerOpen(event: Event): void {
- this.isDatePickerOpen = ! this.isDatePickerOpen;
+ this.isDatePickerOpen = !this.isDatePickerOpen;
event.stopPropagation();
}
@@ -244,7 +245,7 @@ export class DateComponent implements OnInit, OnDestroy {
* Bound internally to the click on clock icon button.
*/
public toggleTimePickerOpen(event: Event): void {
- this.isTimePickerOpen = ! this.isTimePickerOpen;
+ this.isTimePickerOpen = !this.isTimePickerOpen;
event.stopPropagation();
}
@@ -276,6 +277,10 @@ export class DateComponent implements OnInit, OnDestroy {
this.isTimePickerOpen = false;
}
+ public focusout(): void {
+ this.handleShadowTimeChanged();
+ }
+
/**
* Sets up the validators.
*
@@ -286,14 +291,14 @@ export class DateComponent implements OnInit, OnDestroy {
public setupValidators(): void {
const validators: ValidatorFn[] = [];
- if (this.isValueRequired && ! this.isReadonly) {
+ if (this.isValueRequired && !this.isReadonly) {
validators.push(Validators.required);
}
validators.push((control) => this.validateTextInDateRange(control.value as string));
this.shadowText.setValidators(validators);
- this.control.setValidators((control) => this.validateMomentInDateRange(control.value as moment));
+ this.control.setValidators((control) => this.validateMomentInDateRange(control.value as Moment));
}
/**
@@ -311,21 +316,24 @@ export class DateComponent implements OnInit, OnDestroy {
* Returns the string representation of the current (internal) shadow pickers.
*/
private getDateTextFromShadowDateTime(): string {
- let value: moment;
+ let value: Moment;
if (this.shadowDate.value) {
const d = moment(this.shadowDate.value);
- value = new moment({year: d.year(), month: d.month(), day: d.date()});
+ value = moment({year: d.year(), month: d.month(), day: d.date()});
}
if (this.shadowTime.value) {
// Apply the time part to the given date part.
// If no date has been set, use either min or today as date part.
const t = moment(this.shadowTime.value);
- value = value ?? (this.min ? new moment(this.min) : new moment());
+
+ // @ts-ignore
+ value = value ?? (this.min ? moment(this.min) : moment());
value = value.hour(t.hour()).minute(t.minute());
}
+ // @ts-ignore
return this.parser.format(value);
}
@@ -335,7 +343,7 @@ export class DateComponent implements OnInit, OnDestroy {
* handler for when the value of the outside control changed
*/
private handleControlChanged(): void {
- const updatedValue = this.control.value as moment;
+ const updatedValue = this.control.value as Moment;
if (updatedValue !== this.result) {
this.result = updatedValue;
@@ -343,7 +351,7 @@ export class DateComponent implements OnInit, OnDestroy {
this.updateShadowDate(this.control.value);
if (this.withTime) {
- this.updateShadowTime(this.control.value);
+ this.updateShadowTime(this.control.value);
}
}
}
@@ -389,9 +397,9 @@ export class DateComponent implements OnInit, OnDestroy {
*
* updates the value of the internal date only shadow form
*/
- private updateShadowDate(value: moment): void {
+ private updateShadowDate(value: Moment): void {
const shadow = DateParser.asDateOnly(value);
- this.shadowDate.setValue(shadow, {emitEvent: false});
+ this.shadowDate.setValue(shadow, { emitEvent: false });
}
/**
@@ -401,7 +409,7 @@ export class DateComponent implements OnInit, OnDestroy {
*/
private updateShadowText(text: string): void {
if (text !== this.shadowText.value) {
- this.shadowText.setValue(text, {emitEvent: false});
+ this.shadowText.setValue(text, { emitEvent: false });
}
}
@@ -410,9 +418,9 @@ export class DateComponent implements OnInit, OnDestroy {
*
* upates the value of the internal time shadow form
*/
- private updateShadowTime(value: moment): void {
+ private updateShadowTime(value: Moment): void {
const shadow = DateParser.asTimeOnly(value);
- this.shadowTime.setValue(shadow, {emitEvent: false});
+ this.shadowTime.setValue(shadow, { emitEvent: false });
}
/**
@@ -428,7 +436,7 @@ export class DateComponent implements OnInit, OnDestroy {
// Since this component listens to that event it needs a way to detect its own change in order to avoid circles.
// To achieve that the resulting value is stored in a separate member variable (this.result).
this.result = this.parser.parseDateAndTimeString(dateAndTimeString);
- this.control.setValue(this.result, {emitEvent: true});
+ this.control.setValue(this.result, { emitEvent: true });
this.control.markAsDirty();
}
@@ -447,17 +455,17 @@ export class DateComponent implements OnInit, OnDestroy {
*
* validation method: validates the moment representation of a date (and time)
*/
- private validateMomentInDateRange(date: moment): ValidationErrors | null {
+ private validateMomentInDateRange(date: Moment): ValidationErrors | null {
if (date && !date.isValid()) {
- return {matDatepickerParse : true};
+ return { matDatepickerParse: true };
}
if (this.min && date < moment(this.min)) {
- return {matDatepickerMin : true};
+ return { matDatepickerMin: true };
}
if (this.max && date > moment(this.max)) {
- return {matDatepickerMax : true};
+ return { matDatepickerMax: true };
}
}
diff --git a/imxweb/projects/qbm/src/lib/date/date/time-picker/time-picker.component.ts b/imxweb/projects/qbm/src/lib/date/date/time-picker/time-picker.component.ts
index 363a372c5..8f6451a10 100644
--- a/imxweb/projects/qbm/src/lib/date/date/time-picker/time-picker.component.ts
+++ b/imxweb/projects/qbm/src/lib/date/date/time-picker/time-picker.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -25,8 +25,8 @@
*/
import { Component, Input, EventEmitter, Output, HostListener } from '@angular/core';
-import { AbstractControl } from '@angular/forms';
-import * as moment from 'moment-timezone';
+import { AbstractControl, FormControl } from '@angular/forms';
+import { Moment } from 'moment-timezone';
/**
* Internal wrapper component around elemental time picker to pick a Moment time value.
@@ -43,6 +43,8 @@ export class TimePickerComponent {
*
* When a time is picked it will be stored into the value of this control.
*/
+
+ // TODO: Check Upgrade
@Input() public control: AbstractControl;
/**
@@ -55,7 +57,7 @@ export class TimePickerComponent {
*
* Handles the value change event of the time picker.
*/
- public onValueChange(value: moment): void {
+ public onValueChange(value: Moment): void {
this.control.setValue(value);
}
diff --git a/imxweb/projects/qbm/src/lib/date/localized-date.pipe.spec.ts b/imxweb/projects/qbm/src/lib/date/localized-date.pipe.spec.ts
new file mode 100644
index 000000000..f4a952c5d
--- /dev/null
+++ b/imxweb/projects/qbm/src/lib/date/localized-date.pipe.spec.ts
@@ -0,0 +1,74 @@
+/*
+ * ONE IDENTITY LLC. PROPRIETARY INFORMATION
+ *
+ * This software is confidential. One Identity, LLC. or one of its affiliates or
+ * subsidiaries, has supplied this software to you under terms of a
+ * license agreement, nondisclosure agreement or both.
+ *
+ * You may not copy, disclose, or use this software except in accordance with
+ * those terms.
+ *
+ *
+ * Copyright 2022 One Identity LLC.
+ * ALL RIGHTS RESERVED.
+ *
+ * ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
+ * WARRANTIES ABOUT THE SUITABILITY OF THE SOFTWARE,
+ * EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
+ * TO THE IMPLIED WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE, OR
+ * NON-INFRINGEMENT. ONE IDENTITY LLC. SHALL NOT BE
+ * LIABLE FOR ANY DAMAGES SUFFERED BY LICENSEE
+ * AS A RESULT OF USING, MODIFYING OR DISTRIBUTING
+ * THIS SOFTWARE OR ITS DERIVATIVES.
+ *
+ */
+
+import { TestBed } from '@angular/core/testing';
+import { TranslateService } from '@ngx-translate/core';
+import { configureTestSuite } from 'ng-bullet';
+import { LocalizedDatePipe } from './localized-date.pipe';
+
+
+describe('LocalizedDatePipe', () => {
+
+ let translateService: TranslateService;
+
+ configureTestSuite(() => {
+ TestBed.configureTestingModule({
+ providers: [
+ {
+ provide: TranslateService,
+ useValue: {
+ }
+ }
+ ]
+ });
+ });
+
+ beforeEach(() => {
+ translateService = TestBed.get(TranslateService);
+ translateService.currentLang = 'de';
+ });
+
+ it('should create', () => {
+ const pipe = new LocalizedDatePipe(translateService);
+ expect(pipe).toBeDefined();
+ });
+
+ for (const testcase of [
+ { description: 'german', date: '2020-01-01', culture: 'de', expected: '1.1.2020, 01:00:00' },
+ { description: 'english', date: '2020-01-01', culture: 'en', expected: '1/1/2020, 1:00:00 AM' },
+ { description: 'german (with time)', date: '11/20/2020, 5:37:06 PM', culture: 'de', expected: '20.11.2020, 17:37:06' },
+ { description: 'english (with time)', date: '11/20/2020, 5:37:06 PM', culture: 'en', expected: '11/20/2020, 5:37:06 PM' },
+ { description: 'invalid', date: 'xxx', culture: 'en', expected: 'xxx' },
+ ]) {
+ it(`should transform the ${testcase.description} date to a localized`, () => {
+ translateService.currentLang = testcase.culture;
+
+ const pipe = new LocalizedDatePipe(translateService);
+ expect(pipe.transform(testcase.date)).toBe(testcase.expected);
+ });
+ }
+
+});
diff --git a/imxweb/projects/qbm/src/lib/date/localized-date.pipe.ts b/imxweb/projects/qbm/src/lib/date/localized-date.pipe.ts
new file mode 100644
index 000000000..d41f16cc6
--- /dev/null
+++ b/imxweb/projects/qbm/src/lib/date/localized-date.pipe.ts
@@ -0,0 +1,59 @@
+/*
+ * ONE IDENTITY LLC. PROPRIETARY INFORMATION
+ *
+ * This software is confidential. One Identity, LLC. or one of its affiliates or
+ * subsidiaries, has supplied this software to you under terms of a
+ * license agreement, nondisclosure agreement or both.
+ *
+ * You may not copy, disclose, or use this software except in accordance with
+ * those terms.
+ *
+ *
+ * Copyright 2022 One Identity LLC.
+ * ALL RIGHTS RESERVED.
+ *
+ * ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
+ * WARRANTIES ABOUT THE SUITABILITY OF THE SOFTWARE,
+ * EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
+ * TO THE IMPLIED WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE, OR
+ * NON-INFRINGEMENT. ONE IDENTITY LLC. SHALL NOT BE
+ * LIABLE FOR ANY DAMAGES SUFFERED BY LICENSEE
+ * AS A RESULT OF USING, MODIFYING OR DISTRIBUTING
+ * THIS SOFTWARE OR ITS DERIVATIVES.
+ *
+ */
+
+import { Pipe, PipeTransform, Injectable } from '@angular/core';
+import { TranslateService } from '@ngx-translate/core';
+
+@Injectable({
+ providedIn: 'root'
+})
+@Pipe({
+ name: 'localizedDate',
+})
+export class LocalizedDatePipe implements PipeTransform {
+
+ private readonly currentCulture: string;
+
+ constructor(
+ private readonly translateService: TranslateService,
+ ) {
+ this.currentCulture = this.translateService.currentLang;
+ }
+
+ public transform(value: string | Date): string {
+ if (typeof value === 'string') {
+ if (!value || value.length === 0) {
+ return value;
+ }
+ const timestamp = Date.parse(value);
+ if (isNaN(timestamp)) {
+ return value;
+ }
+ }
+ return new Date(value).toLocaleString(this.currentCulture);
+
+ }
+}
diff --git a/imxweb/projects/qbm/src/lib/date/short-date.pipe.spec.ts b/imxweb/projects/qbm/src/lib/date/short-date.pipe.spec.ts
index 2543f2f33..885b18866 100644
--- a/imxweb/projects/qbm/src/lib/date/short-date.pipe.spec.ts
+++ b/imxweb/projects/qbm/src/lib/date/short-date.pipe.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -51,6 +51,7 @@ describe('ShortDatePipe', () => {
beforeEach(() => {
translateService = TestBed.get(TranslateService);
browserLang = 'de';
+ translateService.currentLang = browserLang;
});
it('should create', () => {
@@ -67,6 +68,7 @@ describe('ShortDatePipe', () => {
]) {
it(`should transform the ${testcase.description} date to a shortDate`, () => {
browserLang = testcase.culture;
+ translateService.currentLang = browserLang;
const pipe = new ShortDatePipe(translateService);
expect(pipe.transform(testcase.date)).toBe(testcase.expected);
diff --git a/imxweb/projects/qbm/src/lib/date/short-date.pipe.ts b/imxweb/projects/qbm/src/lib/date/short-date.pipe.ts
index 3196dd793..4578201b6 100644
--- a/imxweb/projects/qbm/src/lib/date/short-date.pipe.ts
+++ b/imxweb/projects/qbm/src/lib/date/short-date.pipe.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -35,12 +35,12 @@ import { TranslateService } from '@ngx-translate/core';
})
export class ShortDatePipe implements PipeTransform {
- private readonly browserCulture: string;
+ private readonly currentCulture: string;
constructor(
private readonly translateService: TranslateService,
) {
- this.browserCulture = this.translateService.getBrowserCultureLang();
+ this.currentCulture = this.translateService.currentLang;
}
public transform(value: string): string {
@@ -51,7 +51,7 @@ export class ShortDatePipe implements PipeTransform {
if (isNaN(timestamp)) {
return value;
}
- return new Date(value).toLocaleDateString(this.browserCulture);
+ return new Date(value).toLocaleDateString(this.currentCulture);
}
}
diff --git a/imxweb/projects/qbm/src/lib/disable-control/disable-control.directive.spec.ts b/imxweb/projects/qbm/src/lib/disable-control/disable-control.directive.spec.ts
index c414e826f..682fc5f46 100644
--- a/imxweb/projects/qbm/src/lib/disable-control/disable-control.directive.spec.ts
+++ b/imxweb/projects/qbm/src/lib/disable-control/disable-control.directive.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/disable-control/disable-control.directive.ts b/imxweb/projects/qbm/src/lib/disable-control/disable-control.directive.ts
index 2f2ad80e2..750597ee5 100644
--- a/imxweb/projects/qbm/src/lib/disable-control/disable-control.directive.ts
+++ b/imxweb/projects/qbm/src/lib/disable-control/disable-control.directive.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/disable-control/disable-control.module.ts b/imxweb/projects/qbm/src/lib/disable-control/disable-control.module.ts
index b1f3e8a80..b718bf820 100644
--- a/imxweb/projects/qbm/src/lib/disable-control/disable-control.module.ts
+++ b/imxweb/projects/qbm/src/lib/disable-control/disable-control.module.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/dynamic-tabs/dynamic-tab-data-provider.directive.ts b/imxweb/projects/qbm/src/lib/dynamic-tabs/dynamic-tab-data-provider.directive.ts
index dca5ac52d..68a6075ff 100644
--- a/imxweb/projects/qbm/src/lib/dynamic-tabs/dynamic-tab-data-provider.directive.ts
+++ b/imxweb/projects/qbm/src/lib/dynamic-tabs/dynamic-tab-data-provider.directive.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/dynamic-tabs/dynamic-tabs.model.ts b/imxweb/projects/qbm/src/lib/dynamic-tabs/dynamic-tabs.model.ts
index 28b8fe60f..7cd4a3b45 100644
--- a/imxweb/projects/qbm/src/lib/dynamic-tabs/dynamic-tabs.model.ts
+++ b/imxweb/projects/qbm/src/lib/dynamic-tabs/dynamic-tabs.model.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/dynamic-tabs/dynamic-tabs.module.ts b/imxweb/projects/qbm/src/lib/dynamic-tabs/dynamic-tabs.module.ts
index 53fd840ff..16c7af4a4 100644
--- a/imxweb/projects/qbm/src/lib/dynamic-tabs/dynamic-tabs.module.ts
+++ b/imxweb/projects/qbm/src/lib/dynamic-tabs/dynamic-tabs.module.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/entity/entity-select/entity-select.component.html b/imxweb/projects/qbm/src/lib/entity/entity-select/entity-select.component.html
index 09a9ae0b0..20996769c 100644
--- a/imxweb/projects/qbm/src/lib/entity/entity-select/entity-select.component.html
+++ b/imxweb/projects/qbm/src/lib/entity/entity-select/entity-select.component.html
@@ -1,4 +1,4 @@
{{ title | translate }}
-
\ No newline at end of file
+
diff --git a/imxweb/projects/qbm/src/lib/entity/entity-select/entity-select.component.scss b/imxweb/projects/qbm/src/lib/entity/entity-select/entity-select.component.scss
index 9f533c26e..06d0aadbe 100644
--- a/imxweb/projects/qbm/src/lib/entity/entity-select/entity-select.component.scss
+++ b/imxweb/projects/qbm/src/lib/entity/entity-select/entity-select.component.scss
@@ -1,4 +1,4 @@
-@import '~@elemental-ui/core/src/styles/_palette.scss';
+@import '@elemental-ui/core/src/styles/_palette.scss';
:host {
display: flex;
diff --git a/imxweb/projects/qbm/src/lib/entity/entity-select/entity-select.component.spec.ts b/imxweb/projects/qbm/src/lib/entity/entity-select/entity-select.component.spec.ts
index 0e7595d89..a1dbd878d 100644
--- a/imxweb/projects/qbm/src/lib/entity/entity-select/entity-select.component.spec.ts
+++ b/imxweb/projects/qbm/src/lib/entity/entity-select/entity-select.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/entity/entity-select/entity-select.component.ts b/imxweb/projects/qbm/src/lib/entity/entity-select/entity-select.component.ts
index cd32ee01c..45d599ad2 100644
--- a/imxweb/projects/qbm/src/lib/entity/entity-select/entity-select.component.ts
+++ b/imxweb/projects/qbm/src/lib/entity/entity-select/entity-select.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -46,6 +46,7 @@ export class EntitySelectComponent implements OnChanges, AfterContentInit {
@Input() public entities: IEntity[];
@Output() public controlCreated = new EventEmitter();
+
@Output() public selectionChange = new EventEmitter();
constructor() {
@@ -53,7 +54,7 @@ export class EntitySelectComponent implements OnChanges, AfterContentInit {
}
public ngOnChanges(changes: SimpleChanges): void {
- if (changes.entities || changes.display) {
+ if (changes['entities'] || changes['display']) {
if (this.entities) {
this.options = this.entities.map(entity => ({
display: this.display?.primary ?
@@ -76,4 +77,10 @@ export class EntitySelectComponent implements OnChanges, AfterContentInit {
return option.display.toString().toUpperCase().trim().includes(searchInputValue.toUpperCase().trim())
|| (option.displayDetail && option.displayDetail.toString().toUpperCase().trim().includes(searchInputValue.toUpperCase().trim()));
}
+
+
+ // TODO: Check Upgrade
+ // public onChange(event: any): void {
+ // this.selectionChange.emit(event.value);
+ // }
}
diff --git a/imxweb/projects/qbm/src/lib/entity/entity-select/entity-select.interface.ts b/imxweb/projects/qbm/src/lib/entity/entity-select/entity-select.interface.ts
index ea929148e..34da5c0f2 100644
--- a/imxweb/projects/qbm/src/lib/entity/entity-select/entity-select.interface.ts
+++ b/imxweb/projects/qbm/src/lib/entity/entity-select/entity-select.interface.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/entity/entity.module.ts b/imxweb/projects/qbm/src/lib/entity/entity.module.ts
index d7b0e5c33..9d8a20259 100644
--- a/imxweb/projects/qbm/src/lib/entity/entity.module.ts
+++ b/imxweb/projects/qbm/src/lib/entity/entity.module.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/entity/entity.service.spec.ts b/imxweb/projects/qbm/src/lib/entity/entity.service.spec.ts
index 8d8de1108..754d7878b 100644
--- a/imxweb/projects/qbm/src/lib/entity/entity.service.spec.ts
+++ b/imxweb/projects/qbm/src/lib/entity/entity.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/entity/entity.service.ts b/imxweb/projects/qbm/src/lib/entity/entity.service.ts
index 1164896d4..fbd227204 100644
--- a/imxweb/projects/qbm/src/lib/entity/entity.service.ts
+++ b/imxweb/projects/qbm/src/lib/entity/entity.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/entity/fk-table-select/fk-table-select.component.spec.ts b/imxweb/projects/qbm/src/lib/entity/fk-table-select/fk-table-select.component.spec.ts
index e7f540abd..d80a71ce1 100644
--- a/imxweb/projects/qbm/src/lib/entity/fk-table-select/fk-table-select.component.spec.ts
+++ b/imxweb/projects/qbm/src/lib/entity/fk-table-select/fk-table-select.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/entity/fk-table-select/fk-table-select.component.ts b/imxweb/projects/qbm/src/lib/entity/fk-table-select/fk-table-select.component.ts
index 541b773a9..59a5230ef 100644
--- a/imxweb/projects/qbm/src/lib/entity/fk-table-select/fk-table-select.component.ts
+++ b/imxweb/projects/qbm/src/lib/entity/fk-table-select/fk-table-select.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -34,7 +34,7 @@ import { MetadataService } from '../../base/metadata.service';
@Component({
selector: 'imx-fk-table-select',
templateUrl: './fk-table-select.component.html',
- styleUrls: ['./fk-table-select.component.scss']
+ styleUrls: ['./fk-table-select.component.scss'],
})
export class FkTableSelectComponent implements OnInit {
public readonly control = new FormControl(undefined);
@@ -47,16 +47,16 @@ export class FkTableSelectComponent implements OnInit {
@Output() public selectionChanged = new EventEmitter();
- constructor(private readonly metadata: MetadataService) { }
+ constructor(private readonly metadata: MetadataService) {}
public async ngOnInit(): Promise {
this.loading = true;
- await this.metadata.updateNonExisting(this.fkTables.map(item => item.TableName));
+ await this.metadata.updateNonExisting(this.fkTables.map((item) => item.TableName));
this.loading = false;
- this.options = this.fkTables.map(item => ({
+ this.options = this.fkTables.map((item) => ({
display: this.metadata.tables[item.TableName]?.DisplaySingular || item.TableName,
- value: item.TableName
+ value: item.TableName,
}));
this.control.setValue(this.preselectedTableName ?? this.fkTables[0].TableName, { emitEvent: false });
@@ -65,4 +65,9 @@ export class FkTableSelectComponent implements OnInit {
public filter(option: EuiSelectOption, searchInputValue: string): boolean {
return option.display.toString().toUpperCase().trim().includes(searchInputValue.toUpperCase().trim());
}
+
+ // TODO: Check Upgrade
+ // public onChange(event: any): void {
+ // this.selectionChanged.emit(event.value);
+ // }
}
diff --git a/imxweb/projects/qbm/src/lib/entity/typed-entity-candidate-sidesheet/typed-entity-candidate-sidesheet-parameter.interface.ts b/imxweb/projects/qbm/src/lib/entity/typed-entity-candidate-sidesheet/typed-entity-candidate-sidesheet-parameter.interface.ts
index 031ca452f..619134807 100644
--- a/imxweb/projects/qbm/src/lib/entity/typed-entity-candidate-sidesheet/typed-entity-candidate-sidesheet-parameter.interface.ts
+++ b/imxweb/projects/qbm/src/lib/entity/typed-entity-candidate-sidesheet/typed-entity-candidate-sidesheet-parameter.interface.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/entity/typed-entity-candidate-sidesheet/typed-entity-candidate-sidesheet.component.scss b/imxweb/projects/qbm/src/lib/entity/typed-entity-candidate-sidesheet/typed-entity-candidate-sidesheet.component.scss
index 0b6fa1698..396f92c20 100644
--- a/imxweb/projects/qbm/src/lib/entity/typed-entity-candidate-sidesheet/typed-entity-candidate-sidesheet.component.scss
+++ b/imxweb/projects/qbm/src/lib/entity/typed-entity-candidate-sidesheet/typed-entity-candidate-sidesheet.component.scss
@@ -1,4 +1,4 @@
-@import "~@elemental-ui/core/src/styles/_palette.scss";
+@import "@elemental-ui/core/src/styles/_palette.scss";
:host {
display: flex;
diff --git a/imxweb/projects/qbm/src/lib/entity/typed-entity-candidate-sidesheet/typed-entity-candidate-sidesheet.component.spec.ts b/imxweb/projects/qbm/src/lib/entity/typed-entity-candidate-sidesheet/typed-entity-candidate-sidesheet.component.spec.ts
index 112a30160..ef00a9865 100644
--- a/imxweb/projects/qbm/src/lib/entity/typed-entity-candidate-sidesheet/typed-entity-candidate-sidesheet.component.spec.ts
+++ b/imxweb/projects/qbm/src/lib/entity/typed-entity-candidate-sidesheet/typed-entity-candidate-sidesheet.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/entity/typed-entity-candidate-sidesheet/typed-entity-candidate-sidesheet.component.ts b/imxweb/projects/qbm/src/lib/entity/typed-entity-candidate-sidesheet/typed-entity-candidate-sidesheet.component.ts
index 4b55dae27..9e865e185 100644
--- a/imxweb/projects/qbm/src/lib/entity/typed-entity-candidate-sidesheet/typed-entity-candidate-sidesheet.component.ts
+++ b/imxweb/projects/qbm/src/lib/entity/typed-entity-candidate-sidesheet/typed-entity-candidate-sidesheet.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/entity/typed-entity-candidate-sidesheet/typed-entity-table-filter.interface.ts b/imxweb/projects/qbm/src/lib/entity/typed-entity-candidate-sidesheet/typed-entity-table-filter.interface.ts
index 4f45de488..18587b3f2 100644
--- a/imxweb/projects/qbm/src/lib/entity/typed-entity-candidate-sidesheet/typed-entity-table-filter.interface.ts
+++ b/imxweb/projects/qbm/src/lib/entity/typed-entity-candidate-sidesheet/typed-entity-table-filter.interface.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/entity/typed-entity-select/typed-entity-fk-data.interface.ts b/imxweb/projects/qbm/src/lib/entity/typed-entity-select/typed-entity-fk-data.interface.ts
index a97d29b82..6643cf200 100644
--- a/imxweb/projects/qbm/src/lib/entity/typed-entity-select/typed-entity-fk-data.interface.ts
+++ b/imxweb/projects/qbm/src/lib/entity/typed-entity-select/typed-entity-fk-data.interface.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -28,7 +28,6 @@ import { CollectionLoadParameters, IForeignKeyInfo, TypedEntity, TypedEntityColl
export interface TypedEntityFkData {
getTyped?: (parameters: CollectionLoadParameters) => Promise>;
- hasSearchParameter: boolean;
isMultiValue: boolean;
preselectedEntities?: TypedEntity[];
fkTables: ReadonlyArray;
diff --git a/imxweb/projects/qbm/src/lib/entity/typed-entity-select/typed-entity-select.component.html b/imxweb/projects/qbm/src/lib/entity/typed-entity-select/typed-entity-select.component.html
index a86081e3b..764b716e0 100644
--- a/imxweb/projects/qbm/src/lib/entity/typed-entity-select/typed-entity-select.component.html
+++ b/imxweb/projects/qbm/src/lib/entity/typed-entity-select/typed-entity-select.component.html
@@ -11,7 +11,7 @@
{{ control?.value?.length ? ('#LDS#Change' | translate) : ('#LDS#Assign' | translate) }}
-
+
{{ '#LDS#This field is mandatory.' | translate }}
diff --git a/imxweb/projects/qbm/src/lib/entity/typed-entity-select/typed-entity-select.component.spec.ts b/imxweb/projects/qbm/src/lib/entity/typed-entity-select/typed-entity-select.component.spec.ts
index f0b1ae6fc..1e0dc9cf7 100644
--- a/imxweb/projects/qbm/src/lib/entity/typed-entity-select/typed-entity-select.component.spec.ts
+++ b/imxweb/projects/qbm/src/lib/entity/typed-entity-select/typed-entity-select.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -88,7 +88,6 @@ describe('TypedEntitySelectComponent', () => {
},
getInitialDisplay: () => 'some entity display',
getSelected: () => Promise.resolve([{ GetEntity: () => ({ GetDisplay: () => 'some entity display' }) } as TypedEntity]),
- hasSearchParameter: true
}as unknown as TypedEntitySelectionData;
component.data = data;
diff --git a/imxweb/projects/qbm/src/lib/entity/typed-entity-select/typed-entity-select.component.ts b/imxweb/projects/qbm/src/lib/entity/typed-entity-select/typed-entity-select.component.ts
index fece3b78a..c75a71e62 100644
--- a/imxweb/projects/qbm/src/lib/entity/typed-entity-select/typed-entity-select.component.ts
+++ b/imxweb/projects/qbm/src/lib/entity/typed-entity-select/typed-entity-select.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -85,7 +85,6 @@ export class TypedEntitySelectComponent implements OnInit {
width: isIE() ? '60%' : 'max(600px, 60%)',
data: {
getTyped: this.data.dynamicFkRelation ? undefined : this.data.getTyped,
- hasSearchParameter: this.data.hasSearchParameter,
isMultiValue: true,
preselectedEntities: this.selected,
fkTables: this.data.dynamicFkRelation?.tables,
diff --git a/imxweb/projects/qbm/src/lib/entity/typed-entity-select/typed-entity-selection-data.interface.ts b/imxweb/projects/qbm/src/lib/entity/typed-entity-select/typed-entity-selection-data.interface.ts
index 367a05539..60c7fd20c 100644
--- a/imxweb/projects/qbm/src/lib/entity/typed-entity-select/typed-entity-selection-data.interface.ts
+++ b/imxweb/projects/qbm/src/lib/entity/typed-entity-select/typed-entity-selection-data.interface.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -37,5 +37,4 @@ export interface TypedEntitySelectionData {
tables: ReadonlyArray;
getSelectedTableName: (selected: TypedEntity[]) => string;
};
- hasSearchParameter: boolean;
}
diff --git a/imxweb/projects/qbm/src/lib/entity/typed-entity-select/typed-entity-selector/typed-entity-selector.component.scss b/imxweb/projects/qbm/src/lib/entity/typed-entity-select/typed-entity-selector/typed-entity-selector.component.scss
index 96ef84861..d6905592c 100644
--- a/imxweb/projects/qbm/src/lib/entity/typed-entity-select/typed-entity-selector/typed-entity-selector.component.scss
+++ b/imxweb/projects/qbm/src/lib/entity/typed-entity-select/typed-entity-selector/typed-entity-selector.component.scss
@@ -1,4 +1,4 @@
-@import '~@elemental-ui/core/src/styles/_palette.scss';
+@import '@elemental-ui/core/src/styles/_palette.scss';
:host {
overflow-y: auto;
diff --git a/imxweb/projects/qbm/src/lib/entity/typed-entity-select/typed-entity-selector/typed-entity-selector.component.spec.ts b/imxweb/projects/qbm/src/lib/entity/typed-entity-select/typed-entity-selector/typed-entity-selector.component.spec.ts
index b8b9b1122..57094f133 100644
--- a/imxweb/projects/qbm/src/lib/entity/typed-entity-select/typed-entity-selector/typed-entity-selector.component.spec.ts
+++ b/imxweb/projects/qbm/src/lib/entity/typed-entity-select/typed-entity-selector/typed-entity-selector.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/entity/typed-entity-select/typed-entity-selector/typed-entity-selector.component.ts b/imxweb/projects/qbm/src/lib/entity/typed-entity-select/typed-entity-selector/typed-entity-selector.component.ts
index 8a1f38f00..f01b1ef4c 100644
--- a/imxweb/projects/qbm/src/lib/entity/typed-entity-select/typed-entity-selector/typed-entity-selector.component.ts
+++ b/imxweb/projects/qbm/src/lib/entity/typed-entity-select/typed-entity-selector/typed-entity-selector.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -41,6 +41,7 @@ export class TypedEntitySelectorComponent {
public selectedItems: TypedEntity[];
public selectedFkTable: IForeignKeyInfo;
+ // TODO: Check Upgrade
public readonly fkRelationData: TypedEntityFkData;
constructor(
diff --git a/imxweb/projects/qbm/src/lib/ext/ext.component.spec.ts b/imxweb/projects/qbm/src/lib/ext/ext.component.spec.ts
index eddacc308..47d21d36a 100644
--- a/imxweb/projects/qbm/src/lib/ext/ext.component.spec.ts
+++ b/imxweb/projects/qbm/src/lib/ext/ext.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/ext/ext.component.ts b/imxweb/projects/qbm/src/lib/ext/ext.component.ts
index 53d800a34..ae4c38ef6 100644
--- a/imxweb/projects/qbm/src/lib/ext/ext.component.ts
+++ b/imxweb/projects/qbm/src/lib/ext/ext.component.ts
@@ -1,74 +1,74 @@
-/*
- * ONE IDENTITY LLC. PROPRIETARY INFORMATION
- *
- * This software is confidential. One Identity, LLC. or one of its affiliates or
- * subsidiaries, has supplied this software to you under terms of a
- * license agreement, nondisclosure agreement or both.
- *
- * You may not copy, disclose, or use this software except in accordance with
- * those terms.
- *
- *
- * Copyright 2021 One Identity LLC.
- * ALL RIGHTS RESERVED.
- *
- * ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
- * WARRANTIES ABOUT THE SUITABILITY OF THE SOFTWARE,
- * EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
- * TO THE IMPLIED WARRANTIES OF MERCHANTABILITY,
- * FITNESS FOR A PARTICULAR PURPOSE, OR
- * NON-INFRINGEMENT. ONE IDENTITY LLC. SHALL NOT BE
- * LIABLE FOR ANY DAMAGES SUFFERED BY LICENSEE
- * AS A RESULT OF USING, MODIFYING OR DISTRIBUTING
- * THIS SOFTWARE OR ITS DERIVATIVES.
- *
- */
-
-import { ComponentFactoryResolver, Component, ViewChild, OnInit, Input } from '@angular/core';
-
-import { ExtService } from './ext.service';
-import { ExtDirective } from './ext.directive';
-
-@Component({
- selector: 'imx-ext',
- template: ` `,
-})
-export class ExtComponent implements OnInit {
- @ViewChild(ExtDirective, { static: true }) public directive: ExtDirective;
-
- @Input() public id: string;
-
- @Input() public referrer: any;
-
- @Input() public properties: { [property: string]: any };
-
- constructor(private componentFactoryResolver: ComponentFactoryResolver, private extService: ExtService) {}
-
- public ngOnInit(): void {
- this.loadComponent();
- }
-
- private loadComponent(): void {
- const extensions = this.extService.Registry[this.id];
-
- if (extensions == null) {
- // TODO log
- return;
- }
-
- const viewContainerRef = this.directive.viewContainerRef;
- viewContainerRef.clear();
-
- extensions.forEach((element) => {
- const c = viewContainerRef.createComponent(this.componentFactoryResolver.resolveComponentFactory(element.instance));
- c.instance.referrer = this.referrer;
- c.instance.inputData = element.inputData;
-
- if (this.properties) {
- for (let key in this.properties) {
- Reflect.set(c.instance, key, this.properties[key]);
- }
- }
- });
- }
-}
+/*
+ * ONE IDENTITY LLC. PROPRIETARY INFORMATION
+ *
+ * This software is confidential. One Identity, LLC. or one of its affiliates or
+ * subsidiaries, has supplied this software to you under terms of a
+ * license agreement, nondisclosure agreement or both.
+ *
+ * You may not copy, disclose, or use this software except in accordance with
+ * those terms.
+ *
+ *
+ * Copyright 2022 One Identity LLC.
+ * ALL RIGHTS RESERVED.
+ *
+ * ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
+ * WARRANTIES ABOUT THE SUITABILITY OF THE SOFTWARE,
+ * EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
+ * TO THE IMPLIED WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE, OR
+ * NON-INFRINGEMENT. ONE IDENTITY LLC. SHALL NOT BE
+ * LIABLE FOR ANY DAMAGES SUFFERED BY LICENSEE
+ * AS A RESULT OF USING, MODIFYING OR DISTRIBUTING
+ * THIS SOFTWARE OR ITS DERIVATIVES.
+ *
+ */
+
+import { ComponentFactoryResolver, Component, ViewChild, OnInit, Input } from '@angular/core';
+
+import { ExtService } from './ext.service';
+import { ExtDirective } from './ext.directive';
+
+@Component({
+ selector: 'imx-ext',
+ template: ` `,
+})
+export class ExtComponent implements OnInit {
+ @ViewChild(ExtDirective, { static: true }) public directive: ExtDirective;
+
+ @Input() public id: string;
+
+ @Input() public referrer: any;
+
+ @Input() public properties: { [property: string]: any };
+
+ constructor(private componentFactoryResolver: ComponentFactoryResolver, private extService: ExtService) {}
+
+ public ngOnInit(): void {
+ this.loadComponent();
+ }
+
+ private loadComponent(): void {
+ const extensions = this.extService.Registry[this.id];
+
+ if (extensions == null) {
+ // TODO log
+ return;
+ }
+
+ const viewContainerRef = this.directive.viewContainerRef;
+ viewContainerRef.clear();
+
+ extensions.forEach((element) => {
+ const c = viewContainerRef.createComponent(this.componentFactoryResolver.resolveComponentFactory(element.instance));
+ c.instance.referrer = this.referrer;
+ c.instance.inputData = element.inputData;
+
+ if (this.properties) {
+ for (let key in this.properties) {
+ Reflect.set(c.instance, key, this.properties[key]);
+ }
+ }
+ });
+ }
+}
diff --git a/imxweb/projects/qbm/src/lib/ext/ext.directive.spec.ts b/imxweb/projects/qbm/src/lib/ext/ext.directive.spec.ts
index d327c4f1d..2a85839e8 100644
--- a/imxweb/projects/qbm/src/lib/ext/ext.directive.spec.ts
+++ b/imxweb/projects/qbm/src/lib/ext/ext.directive.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/ext/ext.directive.ts b/imxweb/projects/qbm/src/lib/ext/ext.directive.ts
index db9de3ce1..182d07099 100644
--- a/imxweb/projects/qbm/src/lib/ext/ext.directive.ts
+++ b/imxweb/projects/qbm/src/lib/ext/ext.directive.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/ext/ext.module.ts b/imxweb/projects/qbm/src/lib/ext/ext.module.ts
index a725185dd..87c944e5a 100644
--- a/imxweb/projects/qbm/src/lib/ext/ext.module.ts
+++ b/imxweb/projects/qbm/src/lib/ext/ext.module.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/ext/ext.service.spec.ts b/imxweb/projects/qbm/src/lib/ext/ext.service.spec.ts
index 5c348771e..8947913ba 100644
--- a/imxweb/projects/qbm/src/lib/ext/ext.service.spec.ts
+++ b/imxweb/projects/qbm/src/lib/ext/ext.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/ext/ext.service.ts b/imxweb/projects/qbm/src/lib/ext/ext.service.ts
index 3816171eb..5ce350316 100644
--- a/imxweb/projects/qbm/src/lib/ext/ext.service.ts
+++ b/imxweb/projects/qbm/src/lib/ext/ext.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -54,5 +54,13 @@ export class ExtService {
}
return ret;
}
+ public async getFittingComponent(key: string): Promise {
+ if (this.registry[key]) {
+ return this.registry[key][0] as T;
+ } else {
+ return null;
+ }
+ }
+
}
diff --git a/imxweb/projects/qbm/src/lib/ext/extension.ts b/imxweb/projects/qbm/src/lib/ext/extension.ts
index ab339f6c5..2abdc5a8c 100644
--- a/imxweb/projects/qbm/src/lib/ext/extension.ts
+++ b/imxweb/projects/qbm/src/lib/ext/extension.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/file-selector/file-selector.service.spec.ts b/imxweb/projects/qbm/src/lib/file-selector/file-selector.service.spec.ts
index be6ff3838..5c6a713ec 100644
--- a/imxweb/projects/qbm/src/lib/file-selector/file-selector.service.spec.ts
+++ b/imxweb/projects/qbm/src/lib/file-selector/file-selector.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/file-selector/file-selector.service.ts b/imxweb/projects/qbm/src/lib/file-selector/file-selector.service.ts
index 2373b184a..146a08121 100644
--- a/imxweb/projects/qbm/src/lib/file-selector/file-selector.service.ts
+++ b/imxweb/projects/qbm/src/lib/file-selector/file-selector.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/filter-tile/filter-tile.component.scss b/imxweb/projects/qbm/src/lib/filter-tile/filter-tile.component.scss
index 3abe5baf2..f9e63c13a 100644
--- a/imxweb/projects/qbm/src/lib/filter-tile/filter-tile.component.scss
+++ b/imxweb/projects/qbm/src/lib/filter-tile/filter-tile.component.scss
@@ -1,4 +1,4 @@
-@import "~@elemental-ui/core/src/styles/_palette.scss";
+@import "@elemental-ui/core/src/styles/_palette.scss";
.FilterIcon,
.FilterIconChecked {
diff --git a/imxweb/projects/qbm/src/lib/filter-tile/filter-tile.component.spec.ts b/imxweb/projects/qbm/src/lib/filter-tile/filter-tile.component.spec.ts
index 6d6da8514..0897b7bd6 100644
--- a/imxweb/projects/qbm/src/lib/filter-tile/filter-tile.component.spec.ts
+++ b/imxweb/projects/qbm/src/lib/filter-tile/filter-tile.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/filter-tile/filter-tile.component.ts b/imxweb/projects/qbm/src/lib/filter-tile/filter-tile.component.ts
index 5926f842d..739308909 100644
--- a/imxweb/projects/qbm/src/lib/filter-tile/filter-tile.component.ts
+++ b/imxweb/projects/qbm/src/lib/filter-tile/filter-tile.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/fk-advanced-picker/candidate-entity.ts b/imxweb/projects/qbm/src/lib/fk-advanced-picker/candidate-entity.ts
index 9b5bab9db..41852dd45 100644
--- a/imxweb/projects/qbm/src/lib/fk-advanced-picker/candidate-entity.ts
+++ b/imxweb/projects/qbm/src/lib/fk-advanced-picker/candidate-entity.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/fk-advanced-picker/candidate.interface.ts b/imxweb/projects/qbm/src/lib/fk-advanced-picker/candidate.interface.ts
index 9bcb2881b..97449c96c 100644
--- a/imxweb/projects/qbm/src/lib/fk-advanced-picker/candidate.interface.ts
+++ b/imxweb/projects/qbm/src/lib/fk-advanced-picker/candidate.interface.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qbm/src/lib/fk-advanced-picker/fk-advanced-picker.component.html b/imxweb/projects/qbm/src/lib/fk-advanced-picker/fk-advanced-picker.component.html
index c0f4dc177..da37161fe 100644
--- a/imxweb/projects/qbm/src/lib/fk-advanced-picker/fk-advanced-picker.component.html
+++ b/imxweb/projects/qbm/src/lib/fk-advanced-picker/fk-advanced-picker.component.html
@@ -5,7 +5,7 @@
-
\ No newline at end of file
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/app.component.spec.ts b/imxweb/projects/qer-app-operationssupport/src/app/app.component.spec.ts
index aeeab9fb6..aef7d8982 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/app.component.spec.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/app.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -33,9 +33,8 @@ import { configureTestSuite } from 'ng-bullet';
import { Subject } from 'rxjs';
import { AppComponent } from './app.component';
-import { AppConfigService, clearStylesFromDOM, ISessionState, AuthenticationService, MenuService, MenuFactory, imx_SessionService } from 'qbm';
+import { AppConfigService, clearStylesFromDOM, ISessionState, AuthenticationService, MenuService, MenuFactory, imx_SessionService, SplashService } from 'qbm';
import { UserService } from './user/user.service';
-import { ProjectConfigurationService } from 'qer';
import { FeatureConfigService } from 'qer';
@Component({
@@ -95,6 +94,12 @@ describe('AppComponent', () => {
})
};
+ const splashServiceStub = {
+ init: jasmine.createSpy('init'),
+ update: jasmine.createSpy('update'),
+ close: jasmine.createSpy('close'),
+ }
+
configureTestSuite(() => {
TestBed.configureTestingModule({
declarations: [
@@ -130,6 +135,10 @@ describe('AppComponent', () => {
provide: EuiLoadingService,
useValue: euiLoadingServiceStub
},
+ {
+ provide: SplashService,
+ useValue: splashServiceStub
+ },
{
provide: AuthenticationService,
useValue: mockAuthenticationService
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/app.component.ts b/imxweb/projects/qer-app-operationssupport/src/app/app.component.ts
index 13921aa3e..8f4ccee01 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/app.component.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/app.component.ts
@@ -1,228 +1,245 @@
-/*
- * ONE IDENTITY LLC. PROPRIETARY INFORMATION
- *
- * This software is confidential. One Identity, LLC. or one of its affiliates or
- * subsidiaries, has supplied this software to you under terms of a
- * license agreement, nondisclosure agreement or both.
- *
- * You may not copy, disclose, or use this software except in accordance with
- * those terms.
- *
- *
- * Copyright 2021 One Identity LLC.
- * ALL RIGHTS RESERVED.
- *
- * ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
- * WARRANTIES ABOUT THE SUITABILITY OF THE SOFTWARE,
- * EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
- * TO THE IMPLIED WARRANTIES OF MERCHANTABILITY,
- * FITNESS FOR A PARTICULAR PURPOSE, OR
- * NON-INFRINGEMENT. ONE IDENTITY LLC. SHALL NOT BE
- * LIABLE FOR ANY DAMAGES SUFFERED BY LICENSEE
- * AS A RESULT OF USING, MODIFYING OR DISTRIBUTING
- * THIS SOFTWARE OR ITS DERIVATIVES.
- *
- */
-
-import { OverlayRef } from '@angular/cdk/overlay';
-import { Component, OnInit, OnDestroy } from '@angular/core';
-import { Router, RouterEvent, NavigationStart, NavigationEnd, NavigationError, NavigationCancel } from '@angular/router';
-import { EuiLoadingService } from '@elemental-ui/core';
-import { Subscription } from 'rxjs';
-
-import { MenuItem, AuthenticationService, ISessionState, MenuService, SettingsService, imx_SessionService } from 'qbm';
-import { FeatureConfigService } from 'qer';
-import { UserService } from './user/user.service';
-import { FeatureConfig } from 'imx-api-qer';
-
-@Component({
- selector: 'imx-root',
- templateUrl: './app.component.html',
- styleUrls: ['./app.component.scss']
-})
-export class AppComponent implements OnInit, OnDestroy {
- public menuItems: MenuItem[];
- public isLoggedIn = false;
- public hideMenu = false;
- public hideUserMessage = false;
-
- private readonly subscriptions: Subscription[] = [];
-
- constructor(
- private readonly authentication: AuthenticationService,
- private readonly busyService: EuiLoadingService,
- private readonly router: Router,
- private readonly menuService: MenuService,
- private readonly userModelService: UserService,
- private readonly featureService: FeatureConfigService,
- sessionService: imx_SessionService,
- settings: SettingsService
- ) {
-
- this.subscriptions.push(
- this.authentication.onSessionResponse.subscribe(async (sessionState: ISessionState) => {
- this.isLoggedIn = sessionState.IsLoggedIn;
- if (this.isLoggedIn) {
- await this.setupMenu();
- const conf = await sessionService.Client.opsupport_config_get();
- settings.DefaultPageSize = conf.DefaultPageSize;
-
- const groupInfo = await this.userModelService.getGroups();
- this.menuItems = this.menuService.getMenuItems([], groupInfo.map(group => group.Name), true);
- }
- })
- );
-
- this.subscriptions.push(this.authentication.onSessionResponse.subscribe(async (sessionState: ISessionState) => {
- this.isLoggedIn = sessionState.IsLoggedIn;
- }));
-
- this.setupRouter();
- }
-
- public async ngOnInit(): Promise {
- await this.authentication.update();
- }
-
- public ngOnDestroy(): void {
- this.subscriptions.forEach(s => s.unsubscribe());
- }
-
- private setupRouter(): void {
- let overlayRef: OverlayRef;
-
- this.router.events.subscribe(((event: RouterEvent) => {
- switch (true) {
- case event instanceof NavigationStart:
- this.hideUserMessage = true;
- setTimeout(() => overlayRef = this.busyService.show());
- break;
- case event instanceof NavigationEnd:
- case event instanceof NavigationCancel:
- case event instanceof NavigationError:
- this.hideUserMessage = false;
- this.hideMenu = event.url === '/';
- setTimeout(() => this.busyService.hide(overlayRef));
- }
- }));
- }
-
- private async setupMenu(): Promise {
-
- let featureConfig : FeatureConfig;
- const overlay = this.busyService.show();
- try {
- featureConfig = await this.featureService.getFeatureConfig();
- } finally {
- this.busyService.hide(overlay);
- }
-
- this.menuService.addMenuFactories(
- () => {
- return {
- id: 'OpsWeb_ROOT_Dashboard',
- sorting: '10',
- title: '#LDS#Home',
- route: 'start'
- };
- },
- (__: string[], groups: string[]) => {
-
- if (!groups.includes('QER_4_OperationsSupport')) {
- return null;
- }
-
- const menu = {
- id: 'OpsWeb_ROOT_Processes',
- sorting: '20',
- title: '#LDS#Processes',
- items: [
- {
- id: 'OpsWeb_Processes_Processes',
- title: '#LDS#Processes',
- route: 'Jobs'
- },
- {
- id: 'OpsWeb_Processes_ProcessSteps',
- title: '#LDS#Process steps',
- route: 'JobChainInformation'
- },
- {
- id: 'OpsWeb_Processes_Performance',
- title: '#LDS#Performance',
- route: 'JobPerformance'
- }
- ]
- };
- return menu;
- },
- (__: string[], groups: string[]) => {
- if (!groups.includes('QER_4_OperationsSupport')) {
- return null;
- }
- const menu = {
- id: 'OpsWeb_ROOT_Synchronization',
- title: '#LDS#Synchronization',
- sorting: '30',
- items: [
- {
- id: 'OpsWeb_Synchronization_UnresolvedReferences',
- title: '#LDS#Unresolved references',
- route: 'unresolvedRefs',
- sorting: '30-10'
- }
- ]
- };
-
- if (groups.some(elem => elem === 'QER_4_ManageOutstanding')) {
- menu.items.push({
- id: 'OpsWeb_Synchronization_OutstandingObjects',
- title: '#LDS#Menu Entry Outstanding objects',
- route: 'outstanding',
- sorting: '30-20'
- });
- }
-
- menu.items.push({
- id: 'OpsWeb_Synchronization_SyncInformation',
- title: '#LDS#Synchronization',
- route: 'SyncInformation',
- sorting: '30-30'
- });
- return menu;
- },
- (__: string[], groups: string[]) => {
- if (!groups.includes('QER_4_OperationsSupport')) {
- return null;
- }
- const menu = {
- id: 'OpsWeb_ROOT_System',
- sorting: '40',
- title: '#LDS#System',
- items: [
- {
- id: 'OpsWeb_System_Database',
- title: '#LDS#Database log',
- route: 'journal'
- },
- {
- id: 'OpsWeb_System_WebApplications',
- title: '#LDS#Web applications',
- route: 'WebApplications'
- },
- ]
- };
-
- if (featureConfig?.EnableSystemStatus) {
- menu.items.unshift({
- id: 'OpsWeb_System_SystemStatus',
- title: '#LDS#System status',
- route: 'SystemStatus'
- });
- }
- return menu;
- });
-
- return null;
- }
-}
+/*
+ * ONE IDENTITY LLC. PROPRIETARY INFORMATION
+ *
+ * This software is confidential. One Identity, LLC. or one of its affiliates or
+ * subsidiaries, has supplied this software to you under terms of a
+ * license agreement, nondisclosure agreement or both.
+ *
+ * You may not copy, disclose, or use this software except in accordance with
+ * those terms.
+ *
+ *
+ * Copyright 2022 One Identity LLC.
+ * ALL RIGHTS RESERVED.
+ *
+ * ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
+ * WARRANTIES ABOUT THE SUITABILITY OF THE SOFTWARE,
+ * EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
+ * TO THE IMPLIED WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE, OR
+ * NON-INFRINGEMENT. ONE IDENTITY LLC. SHALL NOT BE
+ * LIABLE FOR ANY DAMAGES SUFFERED BY LICENSEE
+ * AS A RESULT OF USING, MODIFYING OR DISTRIBUTING
+ * THIS SOFTWARE OR ITS DERIVATIVES.
+ *
+ */
+
+import { OverlayRef } from '@angular/cdk/overlay';
+import { Component, OnInit, OnDestroy } from '@angular/core';
+import { Router, RouterEvent, NavigationStart, NavigationEnd, NavigationError, NavigationCancel } from '@angular/router';
+import { EuiLoadingService } from '@elemental-ui/core';
+import { Subscription } from 'rxjs';
+
+import { MenuItem, AuthenticationService, ISessionState, MenuService, SettingsService, imx_SessionService, SplashService } from 'qbm';
+import { FeatureConfigService } from 'qer';
+import { UserService } from './user/user.service';
+import { FeatureConfig } from 'imx-api-qer';
+
+@Component({
+ selector: 'imx-root',
+ templateUrl: './app.component.html',
+ styleUrls: ['./app.component.scss']
+})
+export class AppComponent implements OnInit, OnDestroy {
+ public menuItems: MenuItem[];
+ public isLoggedIn = false;
+ public hideMenu = false;
+ public hideUserMessage = false;
+ public showPageContent = false;
+
+ private readonly subscriptions: Subscription[] = [];
+
+ constructor(
+ private readonly authentication: AuthenticationService,
+ private readonly busyService: EuiLoadingService,
+ private readonly router: Router,
+ private readonly menuService: MenuService,
+ private readonly featureService: FeatureConfigService,
+ private readonly splash: SplashService,
+ sessionService: imx_SessionService,
+ settings: SettingsService,
+ userModelService: UserService,
+ ) {
+
+ this.subscriptions.push(
+ this.authentication.onSessionResponse.subscribe(async (sessionState: ISessionState) => {
+
+ if (sessionState.hasErrorState) {
+ // Needs to close here when there is an error on sessionState
+ splash.close();
+ }
+
+ this.isLoggedIn = sessionState.IsLoggedIn;
+ if (this.isLoggedIn) {
+ // Close the splash screen that opened in app service initialisation
+ // Needs to close here when running in containers (auth skipped)
+ splash.close();
+
+ await this.setupMenu();
+ const conf = await sessionService.Client.opsupport_config_get();
+ settings.DefaultPageSize = conf.DefaultPageSize;
+
+ const groupInfo = await userModelService.getGroups();
+ this.menuItems = this.menuService.getMenuItems([], groupInfo.map(group => group.Name), true);
+ }
+ })
+ );
+
+ this.subscriptions.push(this.authentication.onSessionResponse.subscribe(async (sessionState: ISessionState) => {
+ this.isLoggedIn = sessionState.IsLoggedIn;
+ }));
+
+ this.setupRouter();
+ }
+
+ public async ngOnInit(): Promise {
+ await this.authentication.update();
+ }
+
+ public ngOnDestroy(): void {
+ this.subscriptions.forEach(s => s.unsubscribe());
+ }
+
+ private setupRouter(): void {
+ let overlayRef: OverlayRef;
+
+ this.router.events.subscribe(((event: RouterEvent) => {
+ switch (true) {
+ case event instanceof NavigationStart:
+ this.hideUserMessage = true;
+
+ if (this.isLoggedIn && event.url === '/') {
+ // show the splash screen, when the user logs out!
+ this.splash.init({ applicationName: 'Operations Support Web Portal' });
+ }
+ break;
+ case event instanceof NavigationEnd:
+ case event instanceof NavigationCancel:
+ case event instanceof NavigationError:
+ this.hideUserMessage = false;
+ this.hideMenu = event.url === '/';
+ // show the pageContent, if the user is logged in or the login page is shown
+ this.showPageContent = this.isLoggedIn || event.url === '/';
+ }
+ }));
+ }
+
+ private async setupMenu(): Promise {
+
+ let featureConfig: FeatureConfig;
+ const overlay = this.busyService.show();
+ try {
+ featureConfig = await this.featureService.getFeatureConfig();
+ } finally {
+ this.busyService.hide(overlay);
+ }
+
+ this.menuService.addMenuFactories(
+ () => {
+ return {
+ id: 'OpsWeb_ROOT_Dashboard',
+ sorting: '10',
+ title: '#LDS#Home',
+ route: 'start'
+ };
+ },
+ (__: string[], groups: string[]) => {
+
+ if (!groups.includes('QER_4_OperationsSupport')) {
+ return null;
+ }
+
+ const menu = {
+ id: 'OpsWeb_ROOT_Processes',
+ sorting: '20',
+ title: '#LDS#Processes',
+ items: [
+ {
+ id: 'OpsWeb_Processes_Processes',
+ title: '#LDS#Processes',
+ route: 'Jobs'
+ },
+ {
+ id: 'OpsWeb_Processes_ProcessSteps',
+ title: '#LDS#Process steps',
+ route: 'JobChainInformation'
+ },
+ {
+ id: 'OpsWeb_Processes_Performance',
+ title: '#LDS#Performance',
+ route: 'JobPerformance'
+ }
+ ]
+ };
+ return menu;
+ },
+ (__: string[], groups: string[]) => {
+ if (!groups.includes('QER_4_OperationsSupport')) {
+ return null;
+ }
+ const menu = {
+ id: 'OpsWeb_ROOT_Synchronization',
+ title: '#LDS#Synchronization',
+ sorting: '30',
+ items: [
+ {
+ id: 'OpsWeb_Synchronization_UnresolvedReferences',
+ title: '#LDS#Unresolved references',
+ route: 'unresolvedRefs',
+ sorting: '30-10'
+ }
+ ]
+ };
+
+ if (groups.some(elem => elem === 'QER_4_ManageOutstanding')) {
+ menu.items.push({
+ id: 'OpsWeb_Synchronization_OutstandingObjects',
+ title: '#LDS#Menu Entry Outstanding objects',
+ route: 'outstanding',
+ sorting: '30-20'
+ });
+ }
+
+ menu.items.push({
+ id: 'OpsWeb_Synchronization_SyncInformation',
+ title: '#LDS#Synchronization',
+ route: 'SyncInformation',
+ sorting: '30-30'
+ });
+ return menu;
+ },
+ (__: string[], groups: string[]) => {
+ if (!groups.includes('QER_4_OperationsSupport')) {
+ return null;
+ }
+ const menu = {
+ id: 'OpsWeb_ROOT_System',
+ sorting: '40',
+ title: '#LDS#System',
+ items: [
+ {
+ id: 'OpsWeb_System_Database',
+ title: '#LDS#Database log',
+ route: 'journal'
+ },
+ {
+ id: 'OpsWeb_System_WebApplications',
+ title: '#LDS#Web applications',
+ route: 'WebApplications'
+ },
+ ]
+ };
+
+ if (featureConfig?.EnableSystemStatus) {
+ menu.items.unshift({
+ id: 'OpsWeb_System_SystemStatus',
+ title: '#LDS#System status',
+ route: 'SystemStatus'
+ });
+ }
+ return menu;
+ });
+
+ return null;
+ }
+}
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/app.module.ts b/imxweb/projects/qer-app-operationssupport/src/app/app.module.ts
index 70f632dc8..5ce0416c0 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/app.module.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/app.module.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -46,7 +46,7 @@ import {
AuthenticationModule,
RouteGuardService} from 'qbm';
import { OutstandingModule } from 'dpr';
-import { ObjectSheetModule, QerModule, StarlingService } from 'qer';
+import { ObjectSheetModule, QerModule } from 'qer';
import { AppRoutingModule } from './app-routing.module';
import { SyncModule } from './sync/sync.module';
import { ObjectOverviewModule } from './object-overview/object-overview.module';
@@ -59,7 +59,6 @@ import { SystemStatusModule } from './information/system-status/system-status.mo
import { ProcessesModule } from './processes/processes.module';
import { AppComponent } from './app.component';
import { AppService } from './app.service';
-import { OpsupportStarlingService } from './opsupport-starling.service';
import { environment } from '../environments/environment';
import appConfigJson from '../appconfig.json';
@@ -123,10 +122,6 @@ import appConfigJson from '../appconfig.json';
},
RouteGuardService,
OpsupportDbObjectService,
- {
- provide: StarlingService,
- useClass: OpsupportStarlingService
- },
],
bootstrap: [AppComponent]
})
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/app.service.spec.ts b/imxweb/projects/qer-app-operationssupport/src/app/app.service.spec.ts
index 9682860e8..10e3baf2a 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/app.service.spec.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/app.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -31,7 +31,7 @@ import { LoggerTestingModule } from 'ngx-logger/testing';
import { TranslateService } from '@ngx-translate/core';
import { BehaviorSubject, of } from 'rxjs';
-import { AppConfigService, imx_SessionService, ImxTranslationProviderService, ExtService, AuthenticationService, PluginLoaderService } from 'qbm';
+import { AppConfigService, imx_SessionService, ImxTranslationProviderService, ExtService, AuthenticationService, PluginLoaderService, SplashService } from 'qbm';
import { AppService } from './app.service';
describe('AppService', () => {
@@ -45,6 +45,11 @@ describe('AppService', () => {
onLangChange: { subscribe: () => {}},
};
+ splash = {
+ init: jasmine.createSpy('init'),
+ update: jasmine.createSpy('update'),
+ close: jasmine.createSpy('close'),
+ }
translationProvider = {
init: jasmine.createSpy('init').and.returnValue(Promise.resolve())
};
@@ -133,6 +138,10 @@ describe('AppService', () => {
{
provide: AuthenticationService,
useValue: mocks.authentication
+ },
+ {
+ provide: SplashService,
+ useValue: mocks.splash
}
]
});
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/app.service.ts b/imxweb/projects/qer-app-operationssupport/src/app/app.service.ts
index 3d026e560..fe7b43d38 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/app.service.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/app.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -24,7 +24,7 @@
*
*/
-import { Injectable, ComponentFactoryResolver } from '@angular/core';
+import { Injectable } from '@angular/core';
import { Title } from '@angular/platform-browser';
import { TranslateService } from '@ngx-translate/core';
@@ -37,7 +37,8 @@ import {
ImxTranslationProviderService,
imx_SessionService,
AuthenticationService,
- PluginLoaderService
+ PluginLoaderService,
+ SplashService
} from 'qbm';
import { SystemOverviewComponent } from './information/system-overview/system-overview.component';
import { environment } from '../environments/environment';
@@ -53,21 +54,22 @@ declare var SystemJS: any;
})
export class AppService {
constructor(
- private logger: ClassloggerService,
+ public readonly registry: CdrRegistryService,
+ private readonly logger: ClassloggerService,
private readonly config: AppConfigService,
private readonly translateService: TranslateService,
private readonly session: imx_SessionService,
private readonly translationProvider: ImxTranslationProviderService,
private readonly title: Title,
- public readonly registry: CdrRegistryService,
- public readonly resolver: ComponentFactoryResolver,
private readonly extService: ExtService,
private readonly pluginLoader: PluginLoaderService,
- private readonly authentication: AuthenticationService
+ private readonly authentication: AuthenticationService,
+ private readonly splash: SplashService,
) { }
public async init(): Promise {
+ this.showSplash();
await this.config.init(environment.clientUrl);
this.translateService.addLangs(this.config.Config.Translation.Langs);
@@ -102,6 +104,8 @@ export class AppService {
this.config.Config.Title = await this.translateService.get('#LDS#Heading Operations Support Web Portal').toPromise();
const title = `${name} ${this.config.Config.Title}`;
this.title.setTitle(title);
+
+ await this.updateSplash(title);
}
public static init(app: AppService): () => Promise {
@@ -111,4 +115,15 @@ export class AppService {
resolve();
});
}
+
+ private showSplash(): void {
+ // open splash screen with fix values
+ this.splash.init({ applicationName: 'Operations Support Web Portal' });
+ }
+
+ private async updateSplash(title: string): Promise {
+ // update the splash screen and use translated texts and the title from the imxconfig
+ const loadingMsg = await this.translateService.get('#LDS#Loading...').toPromise();
+ this.splash.update({ applicationName: title, message: loadingMsg });
+ }
}
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/base/subscription.service.ts b/imxweb/projects/qer-app-operationssupport/src/app/base/subscription.service.ts
index 7083e238d..ce8054124 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/base/subscription.service.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/base/subscription.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/dashboard/dashboard.component.spec.ts b/imxweb/projects/qer-app-operationssupport/src/app/dashboard/dashboard.component.spec.ts
index dcfa290a7..c65318521 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/dashboard/dashboard.component.spec.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/dashboard/dashboard.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/dashboard/dashboard.component.ts b/imxweb/projects/qer-app-operationssupport/src/app/dashboard/dashboard.component.ts
index 37d5d76ce..a58a619a4 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/dashboard/dashboard.component.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/dashboard/dashboard.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/dashboard/dashboard.module.ts b/imxweb/projects/qer-app-operationssupport/src/app/dashboard/dashboard.module.ts
index 71ae9115f..89d77773e 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/dashboard/dashboard.module.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/dashboard/dashboard.module.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/guards/system-status-route-guard.service.ts b/imxweb/projects/qer-app-operationssupport/src/app/guards/system-status-route-guard.service.ts
index ee3aae4fe..88f8bb5d6 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/guards/system-status-route-guard.service.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/guards/system-status-route-guard.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/information/issue-tiles.scss b/imxweb/projects/qer-app-operationssupport/src/app/information/issue-tiles.scss
index 6753dbfbb..3b802fbf4 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/information/issue-tiles.scss
+++ b/imxweb/projects/qer-app-operationssupport/src/app/information/issue-tiles.scss
@@ -1,4 +1,4 @@
-@import "~@elemental-ui/core/src/styles/_palette.scss";
+@import "@elemental-ui/core/src/styles/_palette.scss";
.issueIconLine {
position: relative;
@@ -86,4 +86,4 @@
margin-top: 20px;
margin-right: 20px;
}
-}
\ No newline at end of file
+}
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/information/notifications/notification-issue-item.ts b/imxweb/projects/qer-app-operationssupport/src/app/information/notifications/notification-issue-item.ts
index 63831ef26..a83aad9bc 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/information/notifications/notification-issue-item.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/information/notifications/notification-issue-item.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -24,7 +24,7 @@
*
*/
-import { IssueItem, IssueAction } from '../service-Issues/service-issues.models';
+import { IssueItem, IssueAction } from '../service-issues/service-issues.models';
export enum NotificationIssueType {
Undefined,
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/information/notifications/notifications.component.scss b/imxweb/projects/qer-app-operationssupport/src/app/information/notifications/notifications.component.scss
index ba1a1fffd..cfa0d71ce 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/information/notifications/notifications.component.scss
+++ b/imxweb/projects/qer-app-operationssupport/src/app/information/notifications/notifications.component.scss
@@ -1,105 +1,105 @@
-@import "~@elemental-ui/core/src/styles/_palette.scss";
-
-.startSubTitle {
- font-size: larger;
- font-weight: 600;
- margin-bottom: 10px;
-}
-
-.imx-ops-icon {
- display: flex;
- flex-direction: column;
- > :first-child {
- flex: 1 1 auto;
- }
-
- ::ng-deep .imx-iconStack-text {
- flex: 0 0;
- text-align: center;
- margin-top: -25px;
- margin-bottom: -25px;
- }
-}
-
-.imx-iconStack-1x .icon-setdefault {
- color: $black-c;
- font-size: 30px;
-}
-
-.no-issue-detected {
- max-width: 350px;
-}
-
-.imx-iconStack,
-imx-iconstack {
- margin-top: 10px;
-}
-
-.imx-iconStack-0x {
- line-height: 3em;
-}
-
-.mat-button {
- height: 100%;
- color: $iris-blue;
- font-weight: 600;
-}
-
-
-.imx-notification-container {
- display: flex;
- flex-wrap: wrap;
- margin-bottom: -10px;
-
- >.imx-notification-card{
- margin-right: 10px;
- margin-bottom: 10px;
- }
-}
-
-.notificationContentPane {
- width: 726px;
- height: 50px;
- display: flex;
-
- eui-icon {
- margin: 12px 15px;
- color: $corbin-orange;
- }
-
- > * {
- margin: 15px 0;
- text-align: left;
- }
-
- .notificationTitle {
- width: 96px;
- height: 21px;
- font-size: 16px;
- font-weight: bold;
- font-style: normal;
- font-stretch: normal;
- line-height: normal;
- letter-spacing: normal;
- color: $black-3;
- flex: 0 0 184px;
- }
-
- .notificationContent {
- width: 198px;
- height: 21px;
- font-size: 16px;
- font-weight: normal;
- font-style: normal;
- font-stretch: normal;
- line-height: normal;
- letter-spacing: normal;
- color: $black-3;
- flex: 1 1 auto;
- }
-
- .issueAction {
- flex: 0 0 100px;
- align-self: center;
- }
-}
\ No newline at end of file
+@import "@elemental-ui/core/src/styles/_palette.scss";
+
+.startSubTitle {
+ font-size: larger;
+ font-weight: 600;
+ margin-bottom: 10px;
+}
+
+.imx-ops-icon {
+ display: flex;
+ flex-direction: column;
+ > :first-child {
+ flex: 1 1 auto;
+ }
+
+ ::ng-deep .imx-iconStack-text {
+ flex: 0 0;
+ text-align: center;
+ margin-top: -25px;
+ margin-bottom: -25px;
+ }
+}
+
+.imx-iconStack-1x .icon-setdefault {
+ color: $black-c;
+ font-size: 30px;
+}
+
+.no-issue-detected {
+ max-width: 350px;
+}
+
+.imx-iconStack,
+imx-iconstack {
+ margin-top: 10px;
+}
+
+.imx-iconStack-0x {
+ line-height: 3em;
+}
+
+.mat-button {
+ height: 100%;
+ color: $iris-blue;
+ font-weight: 600;
+}
+
+
+.imx-notification-container {
+ display: flex;
+ flex-wrap: wrap;
+ margin-bottom: -10px;
+
+ >.imx-notification-card{
+ margin-right: 10px;
+ margin-bottom: 10px;
+ }
+}
+
+.notificationContentPane {
+ width: 726px;
+ height: 50px;
+ display: flex;
+
+ eui-icon {
+ margin: 12px 15px;
+ color: $corbin-orange;
+ }
+
+ > * {
+ margin: 15px 0;
+ text-align: left;
+ }
+
+ .notificationTitle {
+ width: 96px;
+ height: 21px;
+ font-size: 16px;
+ font-weight: bold;
+ font-style: normal;
+ font-stretch: normal;
+ line-height: normal;
+ letter-spacing: normal;
+ color: $black-3;
+ flex: 0 0 184px;
+ }
+
+ .notificationContent {
+ width: 198px;
+ height: 21px;
+ font-size: 16px;
+ font-weight: normal;
+ font-style: normal;
+ font-stretch: normal;
+ line-height: normal;
+ letter-spacing: normal;
+ color: $black-3;
+ flex: 1 1 auto;
+ }
+
+ .issueAction {
+ flex: 0 0 100px;
+ align-self: center;
+ }
+}
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/information/notifications/notifications.component.spec.ts b/imxweb/projects/qer-app-operationssupport/src/app/information/notifications/notifications.component.spec.ts
index aca82c79c..55502970e 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/information/notifications/notifications.component.spec.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/information/notifications/notifications.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/information/notifications/notifications.component.ts b/imxweb/projects/qer-app-operationssupport/src/app/information/notifications/notifications.component.ts
index 1d4bd4e47..369601bcb 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/information/notifications/notifications.component.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/information/notifications/notifications.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -29,7 +29,7 @@ import { DomSanitizer, SafeStyle } from '@angular/platform-browser';
import { NotificationsService } from './notifications.service';
import { AppConfigService } from 'qbm';
-import { IssueItem } from '../service-Issues/service-issues.models';
+import { IssueItem } from '../service-issues/service-issues.models';
@Component({
selector: 'imx-notifications',
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/information/notifications/notifications.module.ts b/imxweb/projects/qer-app-operationssupport/src/app/information/notifications/notifications.module.ts
index 25b1b7e1a..15794d005 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/information/notifications/notifications.module.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/information/notifications/notifications.module.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/information/notifications/notifications.service.spec.ts b/imxweb/projects/qer-app-operationssupport/src/app/information/notifications/notifications.service.spec.ts
index cc4ce266b..8b4c8b9ac 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/information/notifications/notifications.service.spec.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/information/notifications/notifications.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/information/notifications/notifications.service.ts b/imxweb/projects/qer-app-operationssupport/src/app/information/notifications/notifications.service.ts
index 8f4a18aae..b69e9a18e 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/information/notifications/notifications.service.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/information/notifications/notifications.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -29,7 +29,7 @@ import { Router } from '@angular/router';
import { FilterType, CompareOperator } from 'imx-qbm-dbts';
import { SubscriptionService } from '../../base/subscription.service';
import { NotificationIssueItem, NotificationIssueType } from './notification-issue-item';
-import { IssueAction } from '../service-Issues/service-issues.models';
+import { IssueAction } from '../service-issues/service-issues.models';
import { imx_SessionService, TextContainer, LdsReplacePipe } from 'qbm';
import { TranslateService } from '@ngx-translate/core';
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/information/service-issues/service-issue-item.ts b/imxweb/projects/qer-app-operationssupport/src/app/information/service-issues/service-issue-item.ts
index 350091988..7ba40b858 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/information/service-issues/service-issue-item.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/information/service-issues/service-issue-item.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/information/service-issues/service-issue.component.scss b/imxweb/projects/qer-app-operationssupport/src/app/information/service-issues/service-issue.component.scss
index 2ae27df51..65aa30edb 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/information/service-issues/service-issue.component.scss
+++ b/imxweb/projects/qer-app-operationssupport/src/app/information/service-issues/service-issue.component.scss
@@ -1,9 +1,4 @@
-@import "~@elemental-ui/core/src/styles/_palette.scss";
-
-:host {
- width: 350px;
- height: 156px;
-}
+@import "@elemental-ui/core/src/styles/_palette.scss";
mat-card {
padding: 0px;
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/information/service-issues/service-issue.component.spec.ts b/imxweb/projects/qer-app-operationssupport/src/app/information/service-issues/service-issue.component.spec.ts
index 43a1d5971..6c15a35ad 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/information/service-issues/service-issue.component.spec.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/information/service-issues/service-issue.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/information/service-issues/service-issue.component.ts b/imxweb/projects/qer-app-operationssupport/src/app/information/service-issues/service-issue.component.ts
index 1eaaea36f..fada12f7d 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/information/service-issues/service-issue.component.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/information/service-issues/service-issue.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/information/service-issues/service-issues.component.scss b/imxweb/projects/qer-app-operationssupport/src/app/information/service-issues/service-issues.component.scss
index 1407a2a04..3088d7294 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/information/service-issues/service-issues.component.scss
+++ b/imxweb/projects/qer-app-operationssupport/src/app/information/service-issues/service-issues.component.scss
@@ -1,4 +1,4 @@
-@import "~@elemental-ui/core/src/styles/_palette.scss";
+@import "@elemental-ui/core/src/styles/_palette.scss";
:host {
max-width: 1200px;
}
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/information/service-issues/service-issues.component.spec.ts b/imxweb/projects/qer-app-operationssupport/src/app/information/service-issues/service-issues.component.spec.ts
index b5e04e8a3..abe1d8066 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/information/service-issues/service-issues.component.spec.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/information/service-issues/service-issues.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/information/service-issues/service-issues.component.ts b/imxweb/projects/qer-app-operationssupport/src/app/information/service-issues/service-issues.component.ts
index ddd910d0e..05cdd526b 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/information/service-issues/service-issues.component.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/information/service-issues/service-issues.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/information/service-issues/service-issues.models.ts b/imxweb/projects/qer-app-operationssupport/src/app/information/service-issues/service-issues.models.ts
index 70f623f69..d007dc6e3 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/information/service-issues/service-issues.models.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/information/service-issues/service-issues.models.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/information/service-issues/service-issues.module.ts b/imxweb/projects/qer-app-operationssupport/src/app/information/service-issues/service-issues.module.ts
index e8ab7760c..1b21f340c 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/information/service-issues/service-issues.module.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/information/service-issues/service-issues.module.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/information/service-issues/service-issues.service.spec.ts b/imxweb/projects/qer-app-operationssupport/src/app/information/service-issues/service-issues.service.spec.ts
index 0e3b97192..e823842b4 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/information/service-issues/service-issues.service.spec.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/information/service-issues/service-issues.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/information/service-issues/service-issues.service.ts b/imxweb/projects/qer-app-operationssupport/src/app/information/service-issues/service-issues.service.ts
index b690c5f3d..b1232c383 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/information/service-issues/service-issues.service.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/information/service-issues/service-issues.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/information/system-overview/system-overview.component.spec.ts b/imxweb/projects/qer-app-operationssupport/src/app/information/system-overview/system-overview.component.spec.ts
index b7198ff5e..4dadd40d3 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/information/system-overview/system-overview.component.spec.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/information/system-overview/system-overview.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/information/system-overview/system-overview.component.ts b/imxweb/projects/qer-app-operationssupport/src/app/information/system-overview/system-overview.component.ts
index 785336ffd..4c95e6fda 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/information/system-overview/system-overview.component.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/information/system-overview/system-overview.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/information/system-overview/system-overview.module.ts b/imxweb/projects/qer-app-operationssupport/src/app/information/system-overview/system-overview.module.ts
index 207a71d30..a6f74f622 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/information/system-overview/system-overview.module.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/information/system-overview/system-overview.module.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/information/system-overview/system-overview.service.spec.ts b/imxweb/projects/qer-app-operationssupport/src/app/information/system-overview/system-overview.service.spec.ts
index 53f6de796..0aac2520d 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/information/system-overview/system-overview.service.spec.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/information/system-overview/system-overview.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/information/system-overview/system-overview.service.ts b/imxweb/projects/qer-app-operationssupport/src/app/information/system-overview/system-overview.service.ts
index 5a0268901..4f18c3504 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/information/system-overview/system-overview.service.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/information/system-overview/system-overview.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/information/system-overview/system-tree/system-tree-database.spec.ts b/imxweb/projects/qer-app-operationssupport/src/app/information/system-overview/system-tree/system-tree-database.spec.ts
index f6d62d6c1..6a5fa7f89 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/information/system-overview/system-tree/system-tree-database.spec.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/information/system-overview/system-tree/system-tree-database.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/information/system-overview/system-tree/system-tree-database.ts b/imxweb/projects/qer-app-operationssupport/src/app/information/system-overview/system-tree/system-tree-database.ts
index b7b68d6fb..463ca82a5 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/information/system-overview/system-tree/system-tree-database.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/information/system-overview/system-tree/system-tree-database.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/information/system-overview/system-tree/system-tree-datasource.spec.ts b/imxweb/projects/qer-app-operationssupport/src/app/information/system-overview/system-tree/system-tree-datasource.spec.ts
index d85f9ebf5..a3e3ca971 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/information/system-overview/system-tree/system-tree-datasource.spec.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/information/system-overview/system-tree/system-tree-datasource.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/information/system-overview/system-tree/system-tree-datasource.ts b/imxweb/projects/qer-app-operationssupport/src/app/information/system-overview/system-tree/system-tree-datasource.ts
index 1eec2fc8b..6bbec66e9 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/information/system-overview/system-tree/system-tree-datasource.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/information/system-overview/system-tree/system-tree-datasource.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/information/system-overview/system-tree/system-tree-node.spec.ts b/imxweb/projects/qer-app-operationssupport/src/app/information/system-overview/system-tree/system-tree-node.spec.ts
index 396ae73e7..f31f5e1d4 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/information/system-overview/system-tree/system-tree-node.spec.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/information/system-overview/system-tree/system-tree-node.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/information/system-overview/system-tree/system-tree-node.ts b/imxweb/projects/qer-app-operationssupport/src/app/information/system-overview/system-tree/system-tree-node.ts
index ec3f36a5c..ad95d03db 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/information/system-overview/system-tree/system-tree-node.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/information/system-overview/system-tree/system-tree-node.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/information/system-status/system-status-information.interface.ts b/imxweb/projects/qer-app-operationssupport/src/app/information/system-status/system-status-information.interface.ts
index fe23125f9..f4b022305 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/information/system-status/system-status-information.interface.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/information/system-status/system-status-information.interface.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/information/system-status/system-status.component.scss b/imxweb/projects/qer-app-operationssupport/src/app/information/system-status/system-status.component.scss
index 048cf2466..84aafa829 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/information/system-status/system-status.component.scss
+++ b/imxweb/projects/qer-app-operationssupport/src/app/information/system-status/system-status.component.scss
@@ -1,4 +1,4 @@
-@import "~@elemental-ui/core/src/styles/_palette.scss";
+@import "@elemental-ui/core/src/styles/_palette.scss";
.imx-db-icon {
padding-top: 45px;
@@ -25,4 +25,4 @@ eui-icon {
.imx-system-status {
display: flex;
flex-wrap: wrap;
-}
\ No newline at end of file
+}
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/information/system-status/system-status.component.spec.ts b/imxweb/projects/qer-app-operationssupport/src/app/information/system-status/system-status.component.spec.ts
index 6e350181a..7ae13a27a 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/information/system-status/system-status.component.spec.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/information/system-status/system-status.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/information/system-status/system-status.component.ts b/imxweb/projects/qer-app-operationssupport/src/app/information/system-status/system-status.component.ts
index 909ccba2a..5f9431410 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/information/system-status/system-status.component.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/information/system-status/system-status.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/information/system-status/system-status.module.ts b/imxweb/projects/qer-app-operationssupport/src/app/information/system-status/system-status.module.ts
index 32bcbf237..0fef5df38 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/information/system-status/system-status.module.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/information/system-status/system-status.module.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/information/system-status/system-status.service.spec.ts b/imxweb/projects/qer-app-operationssupport/src/app/information/system-status/system-status.service.spec.ts
index 65d378421..0955e382a 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/information/system-status/system-status.service.spec.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/information/system-status/system-status.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/information/system-status/system-status.service.ts b/imxweb/projects/qer-app-operationssupport/src/app/information/system-status/system-status.service.ts
index e221c2207..eef21cd77 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/information/system-status/system-status.service.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/information/system-status/system-status.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -47,7 +47,10 @@ export class SystemStatusService {
}
public set(isJobServiceDisabled: boolean, isDbSchedulerDisabled: boolean): Promise {
- return this.session.Client.opsupport_systemstatus_post(isDbSchedulerDisabled, isJobServiceDisabled, '');
+ return this.session.Client.opsupport_systemstatus_post('', {
+ IsDbSchedulerDisabled: isDbSchedulerDisabled,
+ IsJobServiceDisabled: isJobServiceDisabled
+ });
}
public async isSystemAdmin(): Promise {
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/journal/filter-tile-params.ts b/imxweb/projects/qer-app-operationssupport/src/app/journal/filter-tile-params.ts
index ce0f2e199..9f7d35fea 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/journal/filter-tile-params.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/journal/filter-tile-params.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/journal/journal.component.scss b/imxweb/projects/qer-app-operationssupport/src/app/journal/journal.component.scss
index 1ddee4667..64dd5ce64 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/journal/journal.component.scss
+++ b/imxweb/projects/qer-app-operationssupport/src/app/journal/journal.component.scss
@@ -1,4 +1,4 @@
-@import "~@elemental-ui/core/src/styles/_palette.scss";
+@import "@elemental-ui/core/src/styles/_palette.scss";
:host {
display: flex;
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/journal/journal.component.spec.ts b/imxweb/projects/qer-app-operationssupport/src/app/journal/journal.component.spec.ts
index 5a4e3f65b..d897fcbe7 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/journal/journal.component.spec.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/journal/journal.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/journal/journal.component.ts b/imxweb/projects/qer-app-operationssupport/src/app/journal/journal.component.ts
index de30e7952..1ca5430df 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/journal/journal.component.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/journal/journal.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/journal/journal.module.ts b/imxweb/projects/qer-app-operationssupport/src/app/journal/journal.module.ts
index b50edeb33..cf1a2f547 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/journal/journal.module.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/journal/journal.module.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/journal/journal.service.spec.ts b/imxweb/projects/qer-app-operationssupport/src/app/journal/journal.service.spec.ts
index 6593d73fd..5e9cfba30 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/journal/journal.service.spec.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/journal/journal.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/journal/journal.service.ts b/imxweb/projects/qer-app-operationssupport/src/app/journal/journal.service.ts
index f4ec636fe..0a3d698c3 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/journal/journal.service.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/journal/journal.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/object-overview/hyperview/hyperview.service.spec.ts b/imxweb/projects/qer-app-operationssupport/src/app/object-overview/hyperview/hyperview.service.spec.ts
index c6dbf4a12..c9b512fee 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/object-overview/hyperview/hyperview.service.spec.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/object-overview/hyperview/hyperview.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/object-overview/hyperview/hyperview.service.ts b/imxweb/projects/qer-app-operationssupport/src/app/object-overview/hyperview/hyperview.service.ts
index e7280aa03..b46bafb8b 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/object-overview/hyperview/hyperview.service.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/object-overview/hyperview/hyperview.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/object-overview/object-overview.component.scss b/imxweb/projects/qer-app-operationssupport/src/app/object-overview/object-overview.component.scss
index 83e1b3fdd..684c71ca4 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/object-overview/object-overview.component.scss
+++ b/imxweb/projects/qer-app-operationssupport/src/app/object-overview/object-overview.component.scss
@@ -1,11 +1,10 @@
-@import "~@elemental-ui/core/src/styles/_palette.scss";
+@import "@elemental-ui/core/src/styles/_palette.scss";
:host {
display: flex;
flex-direction: column;
overflow: hidden;
height: 100%;
- max-width: 1200px;
}
:host ::ng-deep .mat-tab-body {
@@ -77,13 +76,13 @@
width: 50%;
align-self: flex-end;
}
-
+
.mat-card-title {
font-size: medium;
font-weight: 600;
padding: 10px 10px 0 10px;
}
-
+
.mat-card-content {
display: grid;
grid-template-columns: auto 1fr;
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/object-overview/object-overview.component.spec.ts b/imxweb/projects/qer-app-operationssupport/src/app/object-overview/object-overview.component.spec.ts
index 72b4233d2..5ac279403 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/object-overview/object-overview.component.spec.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/object-overview/object-overview.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -40,7 +40,7 @@ import { TranslationProviderServiceSpy } from '../test-utilities/imx-translation
import { RoutingMock } from '../test-utilities/router-mock.spec';
import { SessionServiceSpy } from '../test-utilities/imx-session.service.spy.spec';
import { ObjectOverviewService } from './object-overview.service';
-import { PersonJobQueueInfo } from './person-job-queue-Info';
+import { PersonJobQueueInfo } from './person-job-queue-info';
import { Subject } from 'rxjs';
@Component({
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/object-overview/object-overview.component.ts b/imxweb/projects/qer-app-operationssupport/src/app/object-overview/object-overview.component.ts
index 9bb0c5dbe..b6a0bd948 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/object-overview/object-overview.component.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/object-overview/object-overview.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -42,7 +42,8 @@ import {
ShapeClickArgs,
ClassloggerService,
DataSourceToolbarSettings,
- AuthenticationService
+ AuthenticationService,
+ ClientPropertyForTableColumns
} from 'qbm';
import { QueueJobsService } from '../processes/jobs/queue-jobs.service';
import { MatDialog } from '@angular/material/dialog';
@@ -50,7 +51,7 @@ import { ObjectOverviewContainer, FeatureConfigService } from 'qer';
import { HyperviewService } from './hyperview/hyperview.service';
import { ObjectOverviewService } from './object-overview.service';
import { PersonDbQueueInfo } from './person-db-queue-info';
-import { PersonJobQueueInfo } from './person-job-queue-Info';
+import { PersonJobQueueInfo } from './person-job-queue-info';
@Component({
templateUrl: './object-overview.component.html',
@@ -68,7 +69,7 @@ export class ObjectOverviewComponent implements OnInit, ObjectOverviewContainer
public readonly entitySchemaJobs: EntitySchema;
public readonly entitySchemaDbs: EntitySchema;
- public displayedColumnsJobs: IClientProperty[];
+ public displayedColumnsJobs: ClientPropertyForTableColumns[];
public displayedColumnsDbs: IClientProperty[];
public dstSettingsJobs: DataSourceToolbarSettings;
@@ -111,7 +112,8 @@ export class ObjectOverviewComponent implements OnInit, ObjectOverviewContainer
this.entitySchemaJobs.Columns.TaskName,
{
ColumnName: 'actions',
- Type: ValType.String
+ Type: ValType.String,
+ afterAdditionals: true
}
];
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/object-overview/object-overview.module.ts b/imxweb/projects/qer-app-operationssupport/src/app/object-overview/object-overview.module.ts
index fb5cd3af5..8b5da6e65 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/object-overview/object-overview.module.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/object-overview/object-overview.module.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/object-overview/object-overview.service.ts b/imxweb/projects/qer-app-operationssupport/src/app/object-overview/object-overview.service.ts
index e6aed538e..5d9cb5496 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/object-overview/object-overview.service.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/object-overview/object-overview.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/object-overview/opsupport-history-api.service.ts b/imxweb/projects/qer-app-operationssupport/src/app/object-overview/opsupport-history-api.service.ts
index 5561dc827..2d0e46bdf 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/object-overview/opsupport-history-api.service.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/object-overview/opsupport-history-api.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/object-overview/person-db-queue-info.ts b/imxweb/projects/qer-app-operationssupport/src/app/object-overview/person-db-queue-info.ts
index 067b716e7..38711265a 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/object-overview/person-db-queue-info.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/object-overview/person-db-queue-info.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/object-overview/person-job-queue-info.ts b/imxweb/projects/qer-app-operationssupport/src/app/object-overview/person-job-queue-info.ts
index d8241166b..9e758de0b 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/object-overview/person-job-queue-info.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/object-overview/person-job-queue-info.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/object-search/object-search.component.spec.ts b/imxweb/projects/qer-app-operationssupport/src/app/object-search/object-search.component.spec.ts
index bc223fbc1..d18b2c0e5 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/object-search/object-search.component.spec.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/object-search/object-search.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/object-search/object-search.component.ts b/imxweb/projects/qer-app-operationssupport/src/app/object-search/object-search.component.ts
index 46264d42d..118b7e6cb 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/object-search/object-search.component.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/object-search/object-search.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/object-search/object-search.module.ts b/imxweb/projects/qer-app-operationssupport/src/app/object-search/object-search.module.ts
index d3600190d..c159348ea 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/object-search/object-search.module.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/object-search/object-search.module.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/opsupport-starling.service.ts b/imxweb/projects/qer-app-operationssupport/src/app/opsupport-starling.service.ts
deleted file mode 100644
index 1ec8bc158..000000000
--- a/imxweb/projects/qer-app-operationssupport/src/app/opsupport-starling.service.ts
+++ /dev/null
@@ -1,66 +0,0 @@
-/*
- * ONE IDENTITY LLC. PROPRIETARY INFORMATION
- *
- * This software is confidential. One Identity, LLC. or one of its affiliates or
- * subsidiaries, has supplied this software to you under terms of a
- * license agreement, nondisclosure agreement or both.
- *
- * You may not copy, disclose, or use this software except in accordance with
- * those terms.
- *
- *
- * Copyright 2021 One Identity LLC.
- * ALL RIGHTS RESERVED.
- *
- * ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
- * WARRANTIES ABOUT THE SUITABILITY OF THE SOFTWARE,
- * EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
- * TO THE IMPLIED WARRANTIES OF MERCHANTABILITY,
- * FITNESS FOR A PARTICULAR PURPOSE, OR
- * NON-INFRINGEMENT. ONE IDENTITY LLC. SHALL NOT BE
- * LIABLE FOR ANY DAMAGES SUFFERED BY LICENSEE
- * AS A RESULT OF USING, MODIFYING OR DISTRIBUTING
- * THIS SOFTWARE OR ITS DERIVATIVES.
- *
- */
-
-import { Injectable } from '@angular/core';
-
-import { OtpType } from 'imx-api-qer';
-import { ClassloggerService, AuthenticationService, SessionState } from 'qbm';
-import { QerApiService, StarlingService } from 'qer';
-
-@Injectable({
- providedIn: 'root'
-})
-export class OpsupportStarlingService implements StarlingService {
- constructor(
- private readonly qerClient: QerApiService,
- private readonly authentication: AuthenticationService,
- private readonly logger: ClassloggerService
- ) { }
-
- public async sendPush(): Promise {
- this.logger.debug(this, 'sendPush');
- return this.authentication.processLogin(
- async () => new SessionState(await this.qerClient.client.opsupport_starling_push_post())
- );
- }
-
- public async verify(code: string): Promise {
- this.logger.debug(this, ' verify');
- return this.authentication.processLogin(
- async () => new SessionState(await this.qerClient.client.opsupport_starling_verify_post(code))
- );
- }
-
- public async sendSms(): Promise {
- this.logger.debug(this, 'sendSms');
- return this.qerClient.client.opsupport_starling_send_post(OtpType.Sms);
- }
-
- public async sendCall(): Promise {
- this.logger.debug(this, 'sendCall');
- return this.qerClient.client.opsupport_starling_send_post(OtpType.Call);
- }
-}
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/processes/frozen-jobs/frozen-jobs.component.scss b/imxweb/projects/qer-app-operationssupport/src/app/processes/frozen-jobs/frozen-jobs.component.scss
index dbb502ad2..71c8c43e8 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/processes/frozen-jobs/frozen-jobs.component.scss
+++ b/imxweb/projects/qer-app-operationssupport/src/app/processes/frozen-jobs/frozen-jobs.component.scss
@@ -1,11 +1,10 @@
-@import "~@elemental-ui/core/src/styles/_palette.scss";
+@import "@elemental-ui/core/src/styles/_palette.scss";
:host {
display: flex;
flex-direction: column;
overflow: hidden;
flex-grow: 1;
- max-width: 1200px;
}
.imx-table-container {
@@ -13,7 +12,7 @@
height: calc(100% - 50px);
display: flex;
flex-direction: column;
-
+
> :nth-child(2) {
flex: 1 1 auto;
}
@@ -38,7 +37,7 @@
clear: both;
width: auto;
float: right;
- position: absolute;
+ position: absolute;
right: 0;
padding: 0 20px;
background-color: $iris-blue;
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/processes/frozen-jobs/frozen-jobs.component.spec.ts b/imxweb/projects/qer-app-operationssupport/src/app/processes/frozen-jobs/frozen-jobs.component.spec.ts
index 0547d29c0..0f449b6df 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/processes/frozen-jobs/frozen-jobs.component.spec.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/processes/frozen-jobs/frozen-jobs.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/processes/frozen-jobs/frozen-jobs.component.ts b/imxweb/projects/qer-app-operationssupport/src/app/processes/frozen-jobs/frozen-jobs.component.ts
index 0e6c323a8..0cddfc8fd 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/processes/frozen-jobs/frozen-jobs.component.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/processes/frozen-jobs/frozen-jobs.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/processes/frozen-jobs/frozen-jobs.service.spec.ts b/imxweb/projects/qer-app-operationssupport/src/app/processes/frozen-jobs/frozen-jobs.service.spec.ts
index 09a2ba302..af28c6a47 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/processes/frozen-jobs/frozen-jobs.service.spec.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/processes/frozen-jobs/frozen-jobs.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/processes/frozen-jobs/frozen-jobs.service.ts b/imxweb/projects/qer-app-operationssupport/src/app/processes/frozen-jobs/frozen-jobs.service.ts
index 822bfd6b2..ecc75bce2 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/processes/frozen-jobs/frozen-jobs.service.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/processes/frozen-jobs/frozen-jobs.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/processes/frozen-jobs/queue-tree.service.spec.ts b/imxweb/projects/qer-app-operationssupport/src/app/processes/frozen-jobs/queue-tree.service.spec.ts
index fe9ae1c0d..3af1a52d0 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/processes/frozen-jobs/queue-tree.service.spec.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/processes/frozen-jobs/queue-tree.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/processes/frozen-jobs/queue-tree.service.ts b/imxweb/projects/qer-app-operationssupport/src/app/processes/frozen-jobs/queue-tree.service.ts
index 1b8ff8d5d..8fe31f0dd 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/processes/frozen-jobs/queue-tree.service.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/processes/frozen-jobs/queue-tree.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/processes/frozen-jobs/single-frozen-job.component.spec.ts b/imxweb/projects/qer-app-operationssupport/src/app/processes/frozen-jobs/single-frozen-job.component.spec.ts
index 201cd5432..17bb7c656 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/processes/frozen-jobs/single-frozen-job.component.spec.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/processes/frozen-jobs/single-frozen-job.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -320,11 +320,14 @@ describe('SingleFrozenJobComponent', () => {
0,
1
].forEach(row => {
- it('gets right time text', () => {
+ xit('gets right time text', () => {
const translate = getTestBed().get(TranslateService);
translate.use('en-us');
const date = new Date(2019, 0, 1);
- const expected = row > 0 ? 'January 01, 12:00:00 AM' : '';
+ // We use the same Intl.DateTimeFormater since ES5 and ES2017 were causing an issue with angular changes
+ // const expected = row > 0 ? 'January 01, 12:00:00 AM' : '';
+ const opt: any = { month: 'long', day: '2-digit', hour: '2-digit', minute: '2-digit', second: '2-digit' };
+ const expected = row > 0 ? new Intl.DateTimeFormat(translate.currentLang, opt).format(date) : '';
expect(component.timeAccessor({ XDateUpdated: { value: date } } as OpsupportQueueTree, row)).toEqual(expected);
});
});
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/processes/frozen-jobs/single-frozen-job.component.ts b/imxweb/projects/qer-app-operationssupport/src/app/processes/frozen-jobs/single-frozen-job.component.ts
index afe70e4d6..8c74ef386 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/processes/frozen-jobs/single-frozen-job.component.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/processes/frozen-jobs/single-frozen-job.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/processes/job-chains/job-chains.component.scss b/imxweb/projects/qer-app-operationssupport/src/app/processes/job-chains/job-chains.component.scss
index f954236f7..3f894fce0 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/processes/job-chains/job-chains.component.scss
+++ b/imxweb/projects/qer-app-operationssupport/src/app/processes/job-chains/job-chains.component.scss
@@ -3,7 +3,6 @@
flex-direction: column;
overflow: hidden;
flex-grow: 1;
- max-width: 1200px;
}
.imx-table-container {
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/processes/job-chains/job-chains.component.spec.ts b/imxweb/projects/qer-app-operationssupport/src/app/processes/job-chains/job-chains.component.spec.ts
index 8abdfd68a..3b076bcad 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/processes/job-chains/job-chains.component.spec.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/processes/job-chains/job-chains.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/processes/job-chains/job-chains.component.ts b/imxweb/projects/qer-app-operationssupport/src/app/processes/job-chains/job-chains.component.ts
index 2b7a282fc..2032d60c2 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/processes/job-chains/job-chains.component.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/processes/job-chains/job-chains.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/processes/job-chains/job-chains.service.spec.ts b/imxweb/projects/qer-app-operationssupport/src/app/processes/job-chains/job-chains.service.spec.ts
index dfcf1596d..ef7f0d0bd 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/processes/job-chains/job-chains.service.spec.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/processes/job-chains/job-chains.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/processes/job-chains/job-chains.service.ts b/imxweb/projects/qer-app-operationssupport/src/app/processes/job-chains/job-chains.service.ts
index 77a337da0..a9f34e6d3 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/processes/job-chains/job-chains.service.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/processes/job-chains/job-chains.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/processes/job-performance/job-performance-queues.service.spec.ts b/imxweb/projects/qer-app-operationssupport/src/app/processes/job-performance/job-performance-queues.service.spec.ts
index 440f586c3..527c8ec62 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/processes/job-performance/job-performance-queues.service.spec.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/processes/job-performance/job-performance-queues.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/processes/job-performance/job-performance-queues.service.ts b/imxweb/projects/qer-app-operationssupport/src/app/processes/job-performance/job-performance-queues.service.ts
index c62a59967..db418f19c 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/processes/job-performance/job-performance-queues.service.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/processes/job-performance/job-performance-queues.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/processes/job-performance/job-performance.component.scss b/imxweb/projects/qer-app-operationssupport/src/app/processes/job-performance/job-performance.component.scss
index 6f0d7beb4..363260945 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/processes/job-performance/job-performance.component.scss
+++ b/imxweb/projects/qer-app-operationssupport/src/app/processes/job-performance/job-performance.component.scss
@@ -3,7 +3,6 @@
flex-direction: column;
overflow: hidden;
flex-grow: 1;
- max-width: 1200px;
}
.imx-table-container {
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/processes/job-performance/job-performance.component.spec.ts b/imxweb/projects/qer-app-operationssupport/src/app/processes/job-performance/job-performance.component.spec.ts
index 4560b6c32..e861c903c 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/processes/job-performance/job-performance.component.spec.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/processes/job-performance/job-performance.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/processes/job-performance/job-performance.component.ts b/imxweb/projects/qer-app-operationssupport/src/app/processes/job-performance/job-performance.component.ts
index edca903c7..c618582db 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/processes/job-performance/job-performance.component.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/processes/job-performance/job-performance.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/processes/job-performance/job-performance.service.spec.ts b/imxweb/projects/qer-app-operationssupport/src/app/processes/job-performance/job-performance.service.spec.ts
index 1d0ae023c..fdbb1a4b9 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/processes/job-performance/job-performance.service.spec.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/processes/job-performance/job-performance.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/processes/job-performance/job-performance.service.ts b/imxweb/projects/qer-app-operationssupport/src/app/processes/job-performance/job-performance.service.ts
index ed3865a16..68ca9f646 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/processes/job-performance/job-performance.service.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/processes/job-performance/job-performance.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/processes/jobs/FilterDescription.ts b/imxweb/projects/qer-app-operationssupport/src/app/processes/jobs/FilterDescription.ts
index 5120acb56..dc337647a 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/processes/jobs/FilterDescription.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/processes/jobs/FilterDescription.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/processes/jobs/jobs-gridview/jobs-gridview.component.scss b/imxweb/projects/qer-app-operationssupport/src/app/processes/jobs/jobs-gridview/jobs-gridview.component.scss
index cbd32b958..fd9a85618 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/processes/jobs/jobs-gridview/jobs-gridview.component.scss
+++ b/imxweb/projects/qer-app-operationssupport/src/app/processes/jobs/jobs-gridview/jobs-gridview.component.scss
@@ -1,9 +1,8 @@
-@import "~@elemental-ui/core/src/styles/_palette.scss";
+@import "@elemental-ui/core/src/styles/_palette.scss";
:host {
display: flex;
flex-direction: column;
flex-grow: 1;
- max-width: 1200px;
overflow: hidden;
}
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/processes/jobs/jobs-gridview/jobs-gridview.component.spec.ts b/imxweb/projects/qer-app-operationssupport/src/app/processes/jobs/jobs-gridview/jobs-gridview.component.spec.ts
index bfb977a2d..0c353d526 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/processes/jobs/jobs-gridview/jobs-gridview.component.spec.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/processes/jobs/jobs-gridview/jobs-gridview.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/processes/jobs/jobs-gridview/jobs-gridview.component.ts b/imxweb/projects/qer-app-operationssupport/src/app/processes/jobs/jobs-gridview/jobs-gridview.component.ts
index 9f914d0d7..1192c2b95 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/processes/jobs/jobs-gridview/jobs-gridview.component.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/processes/jobs/jobs-gridview/jobs-gridview.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -30,7 +30,7 @@ import { EuiLoadingService, EuiSidesheetConfig, EuiSidesheetService } from '@ele
import { OpsupportQueueJobs, ReactivateJobMode } from 'imx-api-qbm';
import { OpsupportQueueJobsParameters, QueueJobsService } from '../queue-jobs.service';
-import { SnackBarService, TextContainer, DataSourceToolbarSettings, DataSourceToolbarFilter, SettingsService } from 'qbm';
+import { SnackBarService, TextContainer, DataSourceToolbarSettings, DataSourceToolbarFilter, SettingsService, ClientPropertyForTableColumns } from 'qbm';
import { CollectionLoadParameters, CompareOperator, DataModel, EntitySchema, FilterType, IClientProperty, ValType } from 'imx-qbm-dbts';
import { SingleFrozenJobComponent } from '../../frozen-jobs/single-frozen-job.component';
import { TranslateService } from '@ngx-translate/core';
@@ -56,7 +56,7 @@ export class JobsGridviewComponent implements OnInit {
@Input() public preselectFailed = false;
private navigationState: CollectionLoadParameters;
- private readonly displayedColumns: IClientProperty[];
+ private readonly displayedColumns: ClientPropertyForTableColumns[];
private filters: DataSourceToolbarFilter[];
private dataModel: DataModel;
@@ -75,7 +75,8 @@ export class JobsGridviewComponent implements OnInit {
this.entitySchemaJobs.Columns.XDateInserted,
{
ColumnName: 'actions',
- Type: ValType.String
+ Type: ValType.String,
+ afterAdditionals: true
}
];
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/processes/jobs/jobs.component.html b/imxweb/projects/qer-app-operationssupport/src/app/processes/jobs/jobs.component.html
index 4656b77d0..9323645b7 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/processes/jobs/jobs.component.html
+++ b/imxweb/projects/qer-app-operationssupport/src/app/processes/jobs/jobs.component.html
@@ -7,7 +7,7 @@
#LDS#Processes
-
+ {{(isShowGraph ? '#LDS#Chart view' : '#LDS#Table view') | translate}}
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/processes/jobs/jobs.component.scss b/imxweb/projects/qer-app-operationssupport/src/app/processes/jobs/jobs.component.scss
index cdc5cd451..ee92c4df9 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/processes/jobs/jobs.component.scss
+++ b/imxweb/projects/qer-app-operationssupport/src/app/processes/jobs/jobs.component.scss
@@ -2,7 +2,6 @@
display: contents;
max-height: 100%;
flex: 1 1 auto;
- max-width: 1200px;
::ng-deep .imx-table-container .imx-data-table-no-results {
height: 100%;
@@ -15,7 +14,6 @@
.imx-heading-wrapper {
display: flex;
- max-width: 1200px;
.imx-helper-alert {
display: flex;
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/processes/jobs/jobs.component.spec.ts b/imxweb/projects/qer-app-operationssupport/src/app/processes/jobs/jobs.component.spec.ts
index 83ac0076b..cae32461d 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/processes/jobs/jobs.component.spec.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/processes/jobs/jobs.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/processes/jobs/jobs.component.ts b/imxweb/projects/qer-app-operationssupport/src/app/processes/jobs/jobs.component.ts
index 5c706d7af..401357e8f 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/processes/jobs/jobs.component.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/processes/jobs/jobs.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/processes/jobs/queue-jobs.service.spec.ts b/imxweb/projects/qer-app-operationssupport/src/app/processes/jobs/queue-jobs.service.spec.ts
index 1180b6d5a..4620d7c69 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/processes/jobs/queue-jobs.service.spec.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/processes/jobs/queue-jobs.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/processes/jobs/queue-jobs.service.ts b/imxweb/projects/qer-app-operationssupport/src/app/processes/jobs/queue-jobs.service.ts
index 3fd711020..61739c12c 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/processes/jobs/queue-jobs.service.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/processes/jobs/queue-jobs.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/processes/processes.module.ts b/imxweb/projects/qer-app-operationssupport/src/app/processes/processes.module.ts
index 0fd21cadb..2d3ba70ca 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/processes/processes.module.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/processes/processes.module.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/service-report/job-servers-gridview.component.scss b/imxweb/projects/qer-app-operationssupport/src/app/service-report/job-servers-gridview.component.scss
index 47025a410..78ede8afa 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/service-report/job-servers-gridview.component.scss
+++ b/imxweb/projects/qer-app-operationssupport/src/app/service-report/job-servers-gridview.component.scss
@@ -3,7 +3,6 @@
flex-direction: column;
overflow: hidden;
flex-grow: 1;
- max-width: 1200px;
}
.imx-table-container {
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/service-report/job-servers-gridview.component.spec.ts b/imxweb/projects/qer-app-operationssupport/src/app/service-report/job-servers-gridview.component.spec.ts
index 8c7abb591..767e976e9 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/service-report/job-servers-gridview.component.spec.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/service-report/job-servers-gridview.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/service-report/job-servers-gridview.component.ts b/imxweb/projects/qer-app-operationssupport/src/app/service-report/job-servers-gridview.component.ts
index ee836c1f5..4b14abdd4 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/service-report/job-servers-gridview.component.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/service-report/job-servers-gridview.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/service-report/job-servers.service.spec.ts b/imxweb/projects/qer-app-operationssupport/src/app/service-report/job-servers.service.spec.ts
index 81d786ed0..af4e3d6a9 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/service-report/job-servers.service.spec.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/service-report/job-servers.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/service-report/job-servers.service.ts b/imxweb/projects/qer-app-operationssupport/src/app/service-report/job-servers.service.ts
index c80c3fb3b..c84c29294 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/service-report/job-servers.service.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/service-report/job-servers.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/service-report/service-availability.component.spec.ts b/imxweb/projects/qer-app-operationssupport/src/app/service-report/service-availability.component.spec.ts
index f644fb1a6..989a530b3 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/service-report/service-availability.component.spec.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/service-report/service-availability.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/service-report/service-availability.component.ts b/imxweb/projects/qer-app-operationssupport/src/app/service-report/service-availability.component.ts
index 62e4598f2..eae892403 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/service-report/service-availability.component.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/service-report/service-availability.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/service-report/service-report.component.spec.ts b/imxweb/projects/qer-app-operationssupport/src/app/service-report/service-report.component.spec.ts
index 661a35a31..f790740eb 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/service-report/service-report.component.spec.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/service-report/service-report.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/service-report/service-report.component.ts b/imxweb/projects/qer-app-operationssupport/src/app/service-report/service-report.component.ts
index 9661f0432..47bc5f9e7 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/service-report/service-report.component.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/service-report/service-report.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/service-report/service-report.module.ts b/imxweb/projects/qer-app-operationssupport/src/app/service-report/service-report.module.ts
index 8f065a554..1ffbc98f3 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/service-report/service-report.module.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/service-report/service-report.module.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/service-report/services-inactive.component.spec.ts b/imxweb/projects/qer-app-operationssupport/src/app/service-report/services-inactive.component.spec.ts
index 2686002bf..d3db8a497 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/service-report/services-inactive.component.spec.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/service-report/services-inactive.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/service-report/services-inactive.component.ts b/imxweb/projects/qer-app-operationssupport/src/app/service-report/services-inactive.component.ts
index 48e48a2d9..340e602df 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/service-report/services-inactive.component.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/service-report/services-inactive.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/sync/sync-information/sync-information.component.scss b/imxweb/projects/qer-app-operationssupport/src/app/sync/sync-information/sync-information.component.scss
index ad2cc004d..14ab8ce52 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/sync/sync-information/sync-information.component.scss
+++ b/imxweb/projects/qer-app-operationssupport/src/app/sync/sync-information/sync-information.component.scss
@@ -3,7 +3,6 @@
flex-direction: column;
overflow: hidden;
height: 100%;
- max-width: 1200px;
}
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/sync/sync-information/sync-information.component.spec.ts b/imxweb/projects/qer-app-operationssupport/src/app/sync/sync-information/sync-information.component.spec.ts
index 8868e2b63..b066d80b2 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/sync/sync-information/sync-information.component.spec.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/sync/sync-information/sync-information.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/sync/sync-information/sync-information.component.ts b/imxweb/projects/qer-app-operationssupport/src/app/sync/sync-information/sync-information.component.ts
index 49c318740..f2338461d 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/sync/sync-information/sync-information.component.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/sync/sync-information/sync-information.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -31,7 +31,7 @@ import { EuiLoadingService } from '@elemental-ui/core';
import { OpsupportSyncShell } from 'imx-api-dpr';
import { EntitySchema, IClientProperty, ValType } from 'imx-qbm-dbts';
-import { DataSourceToolbarSettings, SettingsService } from 'qbm';
+import { DataSourceToolbarSettings, ClientPropertyForTableColumns, SettingsService } from 'qbm';
import { OpsupportSyncShellParameters, SyncService } from '../sync.service';
@Component({
@@ -44,7 +44,7 @@ export class SyncInformationComponent implements OnInit {
public dstSettings: DataSourceToolbarSettings;
public readonly entitySchemaSyncInfo: EntitySchema;
private navigationState: OpsupportSyncShellParameters;
- private readonly displayedColumns: IClientProperty[];
+ private readonly displayedColumns: ClientPropertyForTableColumns[];
constructor(
private dataSource: SyncService,
@@ -62,7 +62,8 @@ export class SyncInformationComponent implements OnInit {
this.entitySchemaSyncInfo.Columns.LastSyncCountObjects,
{
ColumnName: 'actions',
- Type: ValType.String
+ Type: ValType.String,
+ afterAdditionals: true
}
];
}
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/sync/sync-journal/sync-journal.component.scss b/imxweb/projects/qer-app-operationssupport/src/app/sync/sync-journal/sync-journal.component.scss
index 41c44d7e0..e772dfef1 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/sync/sync-journal/sync-journal.component.scss
+++ b/imxweb/projects/qer-app-operationssupport/src/app/sync/sync-journal/sync-journal.component.scss
@@ -3,7 +3,6 @@
flex-direction: column;
overflow: hidden;
flex-grow: 1;
- max-width: 1200px;
}
.imx-table-container {
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/sync/sync-journal/sync-journal.component.spec.ts b/imxweb/projects/qer-app-operationssupport/src/app/sync/sync-journal/sync-journal.component.spec.ts
index 6f558fc5e..b17317eb1 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/sync/sync-journal/sync-journal.component.spec.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/sync/sync-journal/sync-journal.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/sync/sync-journal/sync-journal.component.ts b/imxweb/projects/qer-app-operationssupport/src/app/sync/sync-journal/sync-journal.component.ts
index 32532a646..5630e04d9 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/sync/sync-journal/sync-journal.component.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/sync/sync-journal/sync-journal.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -31,7 +31,7 @@ import { EuiDownloadDirective, EuiLoadingService } from '@elemental-ui/core';
import { OpsupportSyncJournal } from 'imx-api-dpr';
import { EntitySchema, IClientProperty, ValType } from 'imx-qbm-dbts';
-import { DataSourceToolbarSettings, ElementalUiConfigService, SettingsService } from 'qbm';
+import { DataSourceToolbarSettings, ElementalUiConfigService, ClientPropertyForTableColumns, SettingsService } from 'qbm';
import { OpsSyncJournalParameters, SyncService } from '../sync.service';
import { SyncSummaryService } from './sync-summary.service';
@@ -49,7 +49,7 @@ export class SyncJournalComponent implements OnInit {
@ViewChild(EuiDownloadDirective) public directive: EuiDownloadDirective;
private navigationState: OpsSyncJournalParameters;
- private readonly displayedColumns: IClientProperty[];
+ private readonly displayedColumns: ClientPropertyForTableColumns[];
constructor(
private activeRoute: ActivatedRoute,
@@ -67,7 +67,8 @@ export class SyncJournalComponent implements OnInit {
this.entitySchemaSyncInfo.Columns.ProjectionStartInfoDisplay,
{
ColumnName: 'actions',
- Type: ValType.String
+ Type: ValType.String,
+ afterAdditionals: true
}
];
}
@@ -131,6 +132,8 @@ export class SyncJournalComponent implements OnInit {
}
const csvUrl = URL.createObjectURL(blob);
+ console.log(fileName);
+
if (this.directive) {
this.directive.downloadOptions = {
... this.elementalUiConfigService.Config.downloadOptions,
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/sync/sync-journal/sync-summary.service.spec.ts b/imxweb/projects/qer-app-operationssupport/src/app/sync/sync-journal/sync-summary.service.spec.ts
index 59b030391..d37b9064a 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/sync/sync-journal/sync-summary.service.spec.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/sync/sync-journal/sync-summary.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/sync/sync-journal/sync-summary.service.ts b/imxweb/projects/qer-app-operationssupport/src/app/sync/sync-journal/sync-summary.service.ts
index 2819df45b..e3ec0d933 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/sync/sync-journal/sync-summary.service.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/sync/sync-journal/sync-summary.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -36,6 +36,6 @@ export class SyncSummaryService {
constructor(private readonly dprClient: DprApiService) {}
public async Get(state: OpsupportSyncSummaryParameters): Promise {
- return this.dprClient.client.opsupport_sync_summary_get(state.journal);
+ return this.dprClient.client.opsupport_sync_summary_get({ journal: state.journal });
}
}
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/sync/sync.module.ts b/imxweb/projects/qer-app-operationssupport/src/app/sync/sync.module.ts
index ef16c7169..51baf4877 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/sync/sync.module.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/sync/sync.module.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/sync/sync.service.spec.ts b/imxweb/projects/qer-app-operationssupport/src/app/sync/sync.service.spec.ts
index 1f78e0231..73f05e982 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/sync/sync.service.spec.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/sync/sync.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/sync/sync.service.ts b/imxweb/projects/qer-app-operationssupport/src/app/sync/sync.service.ts
index 5d7f65ab6..dc8491c40 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/sync/sync.service.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/sync/sync.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/test-utilities/imx-api-mock.spec.ts b/imxweb/projects/qer-app-operationssupport/src/app/test-utilities/imx-api-mock.spec.ts
index 22ef20a90..6a4d26763 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/test-utilities/imx-api-mock.spec.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/test-utilities/imx-api-mock.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/test-utilities/imx-session.service.spy.spec.ts b/imxweb/projects/qer-app-operationssupport/src/app/test-utilities/imx-session.service.spy.spec.ts
index 9294368a2..35e5a4b60 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/test-utilities/imx-session.service.spy.spec.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/test-utilities/imx-session.service.spy.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/test-utilities/imx-translation-provider.service.spy.spec.ts b/imxweb/projects/qer-app-operationssupport/src/app/test-utilities/imx-translation-provider.service.spy.spec.ts
index 3f6d282d0..c853d66b3 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/test-utilities/imx-translation-provider.service.spy.spec.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/test-utilities/imx-translation-provider.service.spy.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/test-utilities/router-mock.spec.ts b/imxweb/projects/qer-app-operationssupport/src/app/test-utilities/router-mock.spec.ts
index 6c9640eac..e162a7701 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/test-utilities/router-mock.spec.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/test-utilities/router-mock.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/test-utilities/test-helper.module.spec.ts b/imxweb/projects/qer-app-operationssupport/src/app/test-utilities/test-helper.module.spec.ts
index 49d7c01d8..bc338e9cb 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/test-utilities/test-helper.module.spec.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/test-utilities/test-helper.module.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/test-utilities/typed-entity-provider.spec.ts b/imxweb/projects/qer-app-operationssupport/src/app/test-utilities/typed-entity-provider.spec.ts
index fdec56a39..7c90896bd 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/test-utilities/typed-entity-provider.spec.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/test-utilities/typed-entity-provider.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/unresolved-refs/unresolved-refs.component.scss b/imxweb/projects/qer-app-operationssupport/src/app/unresolved-refs/unresolved-refs.component.scss
index f36f7a6b5..044b6f74b 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/unresolved-refs/unresolved-refs.component.scss
+++ b/imxweb/projects/qer-app-operationssupport/src/app/unresolved-refs/unresolved-refs.component.scss
@@ -3,7 +3,6 @@
flex-direction: column;
overflow: hidden;
flex-grow: 1;
- max-width: 1200px;
}
.imx-table-container {
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/unresolved-refs/unresolved-refs.component.spec.ts b/imxweb/projects/qer-app-operationssupport/src/app/unresolved-refs/unresolved-refs.component.spec.ts
index 32e24fa56..336e72c4d 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/unresolved-refs/unresolved-refs.component.spec.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/unresolved-refs/unresolved-refs.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/unresolved-refs/unresolved-refs.component.ts b/imxweb/projects/qer-app-operationssupport/src/app/unresolved-refs/unresolved-refs.component.ts
index 8e515136b..9b26bdae8 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/unresolved-refs/unresolved-refs.component.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/unresolved-refs/unresolved-refs.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/unresolved-refs/unresolved-refs.module.ts b/imxweb/projects/qer-app-operationssupport/src/app/unresolved-refs/unresolved-refs.module.ts
index 7ddb5e11c..98b8e3cfb 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/unresolved-refs/unresolved-refs.module.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/unresolved-refs/unresolved-refs.module.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/unresolved-refs/unresolved-refs.service.spec.ts b/imxweb/projects/qer-app-operationssupport/src/app/unresolved-refs/unresolved-refs.service.spec.ts
index 5ed10aae1..b698fbf82 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/unresolved-refs/unresolved-refs.service.spec.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/unresolved-refs/unresolved-refs.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/unresolved-refs/unresolved-refs.service.ts b/imxweb/projects/qer-app-operationssupport/src/app/unresolved-refs/unresolved-refs.service.ts
index fdc6cde4a..0a176fefe 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/unresolved-refs/unresolved-refs.service.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/unresolved-refs/unresolved-refs.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/user/user.service.ts b/imxweb/projects/qer-app-operationssupport/src/app/user/user.service.ts
index 8d005139e..4577174a9 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/user/user.service.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/user/user.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/web-applications/web-applications.component.scss b/imxweb/projects/qer-app-operationssupport/src/app/web-applications/web-applications.component.scss
index 40de89d88..09dc25eb1 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/web-applications/web-applications.component.scss
+++ b/imxweb/projects/qer-app-operationssupport/src/app/web-applications/web-applications.component.scss
@@ -3,7 +3,6 @@
flex-direction: column;
overflow: hidden;
flex-grow: 1;
- max-width: 1200px;
}
.mat-column-IsDebug,
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/web-applications/web-applications.component.spec.ts b/imxweb/projects/qer-app-operationssupport/src/app/web-applications/web-applications.component.spec.ts
index 473d5353e..038c9c7da 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/web-applications/web-applications.component.spec.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/web-applications/web-applications.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/web-applications/web-applications.component.ts b/imxweb/projects/qer-app-operationssupport/src/app/web-applications/web-applications.component.ts
index 59a2f9568..8dc038644 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/web-applications/web-applications.component.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/web-applications/web-applications.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/web-applications/web-applications.module.ts b/imxweb/projects/qer-app-operationssupport/src/app/web-applications/web-applications.module.ts
index 7d9a6e5ca..e478b1ebf 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/web-applications/web-applications.module.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/web-applications/web-applications.module.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/web-applications/web-applications.service.spec.ts b/imxweb/projects/qer-app-operationssupport/src/app/web-applications/web-applications.service.spec.ts
index 06db64e93..584752435 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/web-applications/web-applications.service.spec.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/web-applications/web-applications.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/app/web-applications/web-applications.service.ts b/imxweb/projects/qer-app-operationssupport/src/app/web-applications/web-applications.service.ts
index d8d0c5248..df4e714fa 100644
--- a/imxweb/projects/qer-app-operationssupport/src/app/web-applications/web-applications.service.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/app/web-applications/web-applications.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/environments/environment.prod.ts b/imxweb/projects/qer-app-operationssupport/src/environments/environment.prod.ts
index 6a0977066..69977712d 100644
--- a/imxweb/projects/qer-app-operationssupport/src/environments/environment.prod.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/environments/environment.prod.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/environments/environment.ts b/imxweb/projects/qer-app-operationssupport/src/environments/environment.ts
index 3009fb675..32cf6057b 100644
--- a/imxweb/projects/qer-app-operationssupport/src/environments/environment.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/environments/environment.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/main.ts b/imxweb/projects/qer-app-operationssupport/src/main.ts
index fc2b0eb41..fd8c44ec6 100644
--- a/imxweb/projects/qer-app-operationssupport/src/main.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/main.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/polyfills.ts b/imxweb/projects/qer-app-operationssupport/src/polyfills.ts
index 2ef824ed2..ff9ae5541 100644
--- a/imxweb/projects/qer-app-operationssupport/src/polyfills.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/polyfills.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-operationssupport/src/styles.scss b/imxweb/projects/qer-app-operationssupport/src/styles.scss
index e3945764e..e241666d7 100644
--- a/imxweb/projects/qer-app-operationssupport/src/styles.scss
+++ b/imxweb/projects/qer-app-operationssupport/src/styles.scss
@@ -1,9 +1,11 @@
/* You can add global styles to this file, and also import other style files */
-$material_icons_font_path: "~@elemental-ui/core/assets/MaterialIcons";
-$cadence_font_path: "~@elemental-ui/cadence-icon/dist";
-$source_sans_pro_font_path: "~@elemental-ui/core/assets/Source_Sans_Pro";
+@use '@angular/material' as mat;
-@import '~@elemental-ui/core/src/styles/core.scss';
+$material_icons_font_path: "~node_modules/@elemental-ui/core/assets/MaterialIcons";
+$cadence_font_path: "~node_modules/@elemental-ui/core/assets/Cadence";
+$source_sans_pro_font_path: "~node_modules/@elemental-ui/core/assets/Source_Sans_Pro";
+
+@import '@elemental-ui/core/src/styles/core.scss';
@import "variables";
diff --git a/imxweb/projects/qer-app-operationssupport/src/test.ts b/imxweb/projects/qer-app-operationssupport/src/test.ts
index 8f69c34e8..e5df46ceb 100644
--- a/imxweb/projects/qer-app-operationssupport/src/test.ts
+++ b/imxweb/projects/qer-app-operationssupport/src/test.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-portal/package.json b/imxweb/projects/qer-app-portal/package.json
index 7c197b86c..ba3312e6f 100644
--- a/imxweb/projects/qer-app-portal/package.json
+++ b/imxweb/projects/qer-app-portal/package.json
@@ -1,6 +1,6 @@
{
"name": "qer-app-portal",
- "version": "8.2.0",
+ "version": "9.0.0",
"private": true,
"peerDependencies": {
}
diff --git a/imxweb/projects/qer-app-portal/src/app/app-routing.module.ts b/imxweb/projects/qer-app-portal/src/app/app-routing.module.ts
index 7dafa0893..438cb260c 100644
--- a/imxweb/projects/qer-app-portal/src/app/app-routing.module.ts
+++ b/imxweb/projects/qer-app-portal/src/app/app-routing.module.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-portal/src/app/app.component.html b/imxweb/projects/qer-app-portal/src/app/app.component.html
index 6836f7ce8..19c8b1790 100644
--- a/imxweb/projects/qer-app-portal/src/app/app.component.html
+++ b/imxweb/projects/qer-app-portal/src/app/app.component.html
@@ -14,6 +14,6 @@
-
+
diff --git a/imxweb/projects/qer-app-portal/src/app/app.component.spec.ts b/imxweb/projects/qer-app-portal/src/app/app.component.spec.ts
index 29ba1ba3b..8ad4d6521 100644
--- a/imxweb/projects/qer-app-portal/src/app/app.component.spec.ts
+++ b/imxweb/projects/qer-app-portal/src/app/app.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -34,7 +34,7 @@ import { LoggerTestingModule } from 'ngx-logger/testing';
import { Subject } from 'rxjs';
import { AppComponent } from './app.component';
-import { AuthenticationService, ISessionState, clearStylesFromDOM, MenuService, SystemInfoService, IeWarningService } from 'qbm';
+import { AuthenticationService, ISessionState, clearStylesFromDOM, MenuService, SystemInfoService, IeWarningService, SplashService } from 'qbm';
import { ProjectConfigurationService, UserModelService } from 'qer';
@Component({
@@ -100,6 +100,12 @@ describe('AppComponent', () => {
getMenuItems: jasmine.createSpy('getMenuItems').and.returnValue(Promise.resolve([])),
};
+ const splashServiceStub = {
+ init: jasmine.createSpy('init'),
+ update: jasmine.createSpy('update'),
+ close: jasmine.createSpy('close'),
+ }
+
configureTestSuite(() => {
TestBed.configureTestingModule({
imports: [
@@ -134,6 +140,10 @@ describe('AppComponent', () => {
provide: EuiLoadingService,
useValue: euiLoadingServiceStub,
},
+ {
+ provide: SplashService,
+ useValue: splashServiceStub
+ },
{
provide: UserModelService,
useValue: userModelServiceStub,
diff --git a/imxweb/projects/qer-app-portal/src/app/app.component.ts b/imxweb/projects/qer-app-portal/src/app/app.component.ts
index 3f85508f3..6718ffe6c 100644
--- a/imxweb/projects/qer-app-portal/src/app/app.component.ts
+++ b/imxweb/projects/qer-app-portal/src/app/app.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -25,12 +25,13 @@
*/
import { Component, OnDestroy, OnInit } from '@angular/core';
-import { OverlayRef } from '@angular/cdk/overlay';
import { Router, NavigationEnd, NavigationStart, NavigationError, RouterEvent, NavigationCancel } from '@angular/router';
import { Subscription } from 'rxjs';
-import { AuthenticationService, ISessionState, MenuItem, SystemInfoService, MenuService, IeWarningService } from 'qbm';
+import { AuthenticationService, ISessionState, MenuItem, SystemInfoService, MenuService, IeWarningService, SplashService } from 'qbm';
import { PendingItemsType, ProjectConfigurationService, UserModelService } from 'qer';
+import { QerProjectConfig } from 'imx-api-qer';
+import { ProjectConfig } from 'imx-api-qbm';
@Component({
selector: 'imx-root',
@@ -43,27 +44,39 @@ export class AppComponent implements OnInit, OnDestroy {
public hideMenu = false;
public hideUserMessage = false;
public pendingItems: PendingItemsType;
+ public showPageContent = false;
private readonly subscriptions: Subscription[] = [];
constructor(
private readonly authentication: AuthenticationService,
+ private readonly router: Router,
+ private readonly splash: SplashService,
menuService: MenuService,
userModelService: UserModelService,
- private readonly router: Router,
systemInfoService: SystemInfoService,
ieWarningService: IeWarningService,
- projectConfig: ProjectConfigurationService
+ projectConfig: ProjectConfigurationService,
) {
this.subscriptions.push(
this.authentication.onSessionResponse.subscribe(async (sessionState: ISessionState) => {
+
+ if (sessionState.hasErrorState) {
+ // Needs to close here when there is an error on sessionState
+ splash.close();
+ }
+
this.isLoggedIn = sessionState.IsLoggedIn;
if (this.isLoggedIn) {
- projectConfig.getConfig();
+ // Close the splash screen that opened in app service initialisation
+ // Needs to close here when running in containers (auth skipped)
+ splash.close();
+
+ const config: QerProjectConfig & ProjectConfig = await projectConfig.getConfig();
this.pendingItems = await userModelService.getPendingItems();
const groupInfo = await userModelService.getGroups();
const systemInfo = await systemInfoService.get();
- this.menuItems = menuService.getMenuItems(systemInfo.PreProps, groupInfo.map(group => group.Name));
+ this.menuItems = menuService.getMenuItems(systemInfo.PreProps, groupInfo.map(group => group.Name), false, config);
ieWarningService.showIe11Banner();
}
@@ -103,11 +116,13 @@ export class AppComponent implements OnInit, OnDestroy {
}
private setupRouter(): void {
- let overlayRef: OverlayRef;
-
this.router.events.subscribe(((event: RouterEvent) => {
if (event instanceof NavigationStart) {
this.hideUserMessage = true;
+ if (this.isLoggedIn && event.url === '/') {
+ // show the splash screen, when the user logs out!
+ this.splash.init({ applicationName: 'One Identity Manager Portal' });
+ }
}
if (event instanceof NavigationCancel) {
@@ -117,6 +132,8 @@ export class AppComponent implements OnInit, OnDestroy {
if (event instanceof NavigationEnd) {
this.hideUserMessage = false;
this.hideMenu = event.url === '/';
+ // show the pageContent, if the user is logged in or the login page is shown
+ this.showPageContent = this.isLoggedIn || event.urlAfterRedirects === '/';
}
if (event instanceof NavigationError) {
diff --git a/imxweb/projects/qer-app-portal/src/app/app.module.ts b/imxweb/projects/qer-app-portal/src/app/app.module.ts
index aafcf9bf9..e67916c77 100644
--- a/imxweb/projects/qer-app-portal/src/app/app.module.ts
+++ b/imxweb/projects/qer-app-portal/src/app/app.module.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -64,7 +64,6 @@ import {
ServiceCategoriesModule,
ServiceItemsEditModule,
ShoppingCartModule,
- StarlingService,
ProfileModule,
RequestConfigModule,
RoleManangementModule,
@@ -74,7 +73,6 @@ import {
import { AppRoutingModule } from './app-routing.module';
import { AppComponent } from './app.component';
import { AppService } from './app.service';
-import { PortalStarlingService } from './portal-starling.service';
import { environment } from '../environments/environment';
import appConfigJson from '../appconfig.json';
import { PortalHistoryService } from './portal-history.service';
@@ -140,10 +138,6 @@ import { PortalHistoryService } from './portal-history.service';
provide: ErrorHandler,
useClass: GlobalErrorHandler
},
- {
- provide: StarlingService,
- useClass: PortalStarlingService
- },
{
provide: ObjectHistoryApiService,
useClass: PortalHistoryService
diff --git a/imxweb/projects/qer-app-portal/src/app/app.service.spec.ts b/imxweb/projects/qer-app-portal/src/app/app.service.spec.ts
index 716b9273a..619f6a8eb 100644
--- a/imxweb/projects/qer-app-portal/src/app/app.service.spec.ts
+++ b/imxweb/projects/qer-app-portal/src/app/app.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -31,19 +31,26 @@ import { LoggerTestingModule } from 'ngx-logger/testing';
import { TranslateService } from '@ngx-translate/core';
import { BehaviorSubject, of } from 'rxjs';
-import { AppConfigService, imx_SessionService, ImxTranslationProviderService, AuthenticationService } from 'qbm';
+import { AppConfigService, imx_SessionService, ImxTranslationProviderService, AuthenticationService, SplashService } from 'qbm';
import { AppService } from './app.service';
import { PluginLoaderService } from 'qbm';
describe('AppService', () => {
class Mocks {
translate = {
+ get: jasmine.createSpy('get').and.returnValue(of()),
addLangs: jasmine.createSpy('addLangs'),
getBrowserCultureLang: jasmine.createSpy('getBrowserCultureLang').and.returnValue(''),
setDefaultLang: jasmine.createSpy('setDefaultLang'),
use: jasmine.createSpy('use').and.returnValue(of({})),
};
+ splash = {
+ init: jasmine.createSpy('init'),
+ update: jasmine.createSpy('update'),
+ close: jasmine.createSpy('close'),
+ };
+
translationProvider = {
init: jasmine.createSpy('init').and.returnValue(Promise.resolve())
};
@@ -122,6 +129,10 @@ describe('AppService', () => {
{
provide: AuthenticationService,
useValue: mocks.authentication
+ },
+ {
+ provide: SplashService,
+ useValue: mocks.splash
}
]
});
diff --git a/imxweb/projects/qer-app-portal/src/app/app.service.ts b/imxweb/projects/qer-app-portal/src/app/app.service.ts
index 81d535f03..63e7d48fc 100644
--- a/imxweb/projects/qer-app-portal/src/app/app.service.ts
+++ b/imxweb/projects/qer-app-portal/src/app/app.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -24,7 +24,7 @@
*
*/
-import { Injectable, ComponentFactoryResolver } from '@angular/core';
+import { Injectable } from '@angular/core';
import { Title } from '@angular/platform-browser';
import { TranslateService } from '@ngx-translate/core';
@@ -36,7 +36,8 @@ import {
ImxTranslationProviderService,
ClassloggerService,
AuthenticationService,
- PluginLoaderService
+ PluginLoaderService,
+ SplashService
} from 'qbm';
import { environment } from '../environments/environment';
import { TypedClient } from 'imx-api-qbm';
@@ -51,19 +52,21 @@ declare var SystemJS: any;
})
export class AppService {
constructor(
- private logger: ClassloggerService,
+ public readonly registry: CdrRegistryService,
+ private readonly logger: ClassloggerService,
private readonly config: AppConfigService,
private readonly translateService: TranslateService,
private readonly session: imx_SessionService,
private readonly translationProvider: ImxTranslationProviderService,
private readonly title: Title,
- public readonly registry: CdrRegistryService,
- public readonly resolver: ComponentFactoryResolver,
- private pluginLoader: PluginLoaderService,
- private readonly authentication: AuthenticationService
+ private readonly pluginLoader: PluginLoaderService,
+ private readonly authentication: AuthenticationService,
+ private readonly splash: SplashService,
) { }
public async init(): Promise {
+ this.showSplash();
+
await this.config.init(environment.clientUrl);
const imxConfig = await this.config.getImxConfig();
@@ -72,6 +75,8 @@ export class AppService {
this.logger.debug(this, `Set page title to ${title}`);
this.title.setTitle(title);
+ await this.updateSplash(title);
+
this.translateService.addLangs(this.config.Config.Translation.Langs);
const browserCulture = this.translateService.getBrowserCultureLang();
this.logger.debug(this, `Set ${browserCulture} as default language`);
@@ -95,4 +100,16 @@ export class AppService {
resolve();
});
}
+
+ private showSplash(): void {
+ // open splash screen with fix values
+ this.splash.init({ applicationName: 'One Identity Manager Portal' });
+ }
+
+ private async updateSplash(title: string): Promise {
+ // update the splash screen and use translated texts and the title from the imxconfig
+ const loadingMsg = await this.translateService.get('#LDS#Loading...').toPromise();
+ this.splash.update({ applicationName: title, message: loadingMsg });
+ }
+
}
diff --git a/imxweb/projects/qer-app-portal/src/app/portal-history.service.ts b/imxweb/projects/qer-app-portal/src/app/portal-history.service.ts
index 9b5ef351e..2d8f21c04 100644
--- a/imxweb/projects/qer-app-portal/src/app/portal-history.service.ts
+++ b/imxweb/projects/qer-app-portal/src/app/portal-history.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-portal/src/app/portal-starling.service.ts b/imxweb/projects/qer-app-portal/src/app/portal-starling.service.ts
deleted file mode 100644
index 6c23c2a1d..000000000
--- a/imxweb/projects/qer-app-portal/src/app/portal-starling.service.ts
+++ /dev/null
@@ -1,66 +0,0 @@
-/*
- * ONE IDENTITY LLC. PROPRIETARY INFORMATION
- *
- * This software is confidential. One Identity, LLC. or one of its affiliates or
- * subsidiaries, has supplied this software to you under terms of a
- * license agreement, nondisclosure agreement or both.
- *
- * You may not copy, disclose, or use this software except in accordance with
- * those terms.
- *
- *
- * Copyright 2021 One Identity LLC.
- * ALL RIGHTS RESERVED.
- *
- * ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
- * WARRANTIES ABOUT THE SUITABILITY OF THE SOFTWARE,
- * EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
- * TO THE IMPLIED WARRANTIES OF MERCHANTABILITY,
- * FITNESS FOR A PARTICULAR PURPOSE, OR
- * NON-INFRINGEMENT. ONE IDENTITY LLC. SHALL NOT BE
- * LIABLE FOR ANY DAMAGES SUFFERED BY LICENSEE
- * AS A RESULT OF USING, MODIFYING OR DISTRIBUTING
- * THIS SOFTWARE OR ITS DERIVATIVES.
- *
- */
-
-import { Injectable } from '@angular/core';
-
-import { OtpType } from 'imx-api-qer';
-import { ClassloggerService, AuthenticationService, SessionState } from 'qbm';
-import { QerApiService, StarlingService } from 'qer';
-
-@Injectable({
- providedIn: 'root'
-})
-export class PortalStarlingService implements StarlingService {
- constructor(
- private readonly qerClient: QerApiService,
- private readonly authentication: AuthenticationService,
- private readonly logger: ClassloggerService
- ) { }
-
- public async sendPush(): Promise {
- this.logger.debug(this, 'sendPush');
- return this.authentication.processLogin(
- async () => new SessionState(await this.qerClient.client.portal_starling_push_post())
- );
- }
-
- public async verify(code: string): Promise {
- this.logger.debug(this, ' verify');
- return this.authentication.processLogin(
- async () => new SessionState(await this.qerClient.client.portal_starling_verify_post(code))
- );
- }
-
- public async sendSms(): Promise {
- this.logger.debug(this, 'sendSms');
- return this.qerClient.client.portal_starling_send_post(OtpType.Sms);
- }
-
- public async sendCall(): Promise {
- this.logger.debug(this, 'sendCall');
- return this.qerClient.client.portal_starling_send_post(OtpType.Call);
- }
-}
diff --git a/imxweb/projects/qer-app-portal/src/environments/environment.prod.ts b/imxweb/projects/qer-app-portal/src/environments/environment.prod.ts
index 0453f690f..bc8de8050 100644
--- a/imxweb/projects/qer-app-portal/src/environments/environment.prod.ts
+++ b/imxweb/projects/qer-app-portal/src/environments/environment.prod.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-portal/src/environments/environment.ts b/imxweb/projects/qer-app-portal/src/environments/environment.ts
index 6030a08f6..d0085ac85 100644
--- a/imxweb/projects/qer-app-portal/src/environments/environment.ts
+++ b/imxweb/projects/qer-app-portal/src/environments/environment.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-portal/src/main.ts b/imxweb/projects/qer-app-portal/src/main.ts
index fedc4780e..0d6be56bc 100644
--- a/imxweb/projects/qer-app-portal/src/main.ts
+++ b/imxweb/projects/qer-app-portal/src/main.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-portal/src/polyfills.ts b/imxweb/projects/qer-app-portal/src/polyfills.ts
index 1df811d3b..0c12b344d 100644
--- a/imxweb/projects/qer-app-portal/src/polyfills.ts
+++ b/imxweb/projects/qer-app-portal/src/polyfills.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-portal/src/styles.scss b/imxweb/projects/qer-app-portal/src/styles.scss
index 483c848ed..4de322196 100644
--- a/imxweb/projects/qer-app-portal/src/styles.scss
+++ b/imxweb/projects/qer-app-portal/src/styles.scss
@@ -1,12 +1,15 @@
/* You can add global styles to this file, and also import other style files */
-$material_icons_font_path: "~@elemental-ui/core/assets/MaterialIcons";
-$cadence_font_path: "~@elemental-ui/cadence-icon/dist";
-$source_sans_pro_font_path: "~@elemental-ui/core/assets/Source_Sans_Pro";
+@use '@angular/material' as mat;
+
+$material_icons_font_path: "~node_modules/@elemental-ui/core/assets/MaterialIcons";
+$cadence_font_path: "~node_modules/@elemental-ui/core/assets/Cadence";
+$source_sans_pro_font_path: "~node_modules/@elemental-ui/core/assets/Source_Sans_Pro";
+
+@import '@elemental-ui/core/src/styles/core.scss';
-@import '~@elemental-ui/core/src/styles/core.scss';
.imx-dialog-panel-class > .mat-dialog-container {
- background-color: mat-color($asher-gray-palette, 200);
+ background-color: mat.get-color-from-palette($asher-gray-palette, 200);
}
.mat-snack-bar-container.mat-snack-bar-center.eui-alert-banner-panel {
@@ -27,7 +30,6 @@ imx-data-explorer-accounts {
display: flex;
flex-direction: column;
overflow: hidden;
- max-width: 1200px;
> .data-explorer--groups,
.data-explorer--accounts {
flex: 1 1 auto;
diff --git a/imxweb/projects/qer-app-portal/src/test.ts b/imxweb/projects/qer-app-portal/src/test.ts
index d1ab175f7..6d8094e66 100644
--- a/imxweb/projects/qer-app-portal/src/test.ts
+++ b/imxweb/projects/qer-app-portal/src/test.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-pwdportal/package.json b/imxweb/projects/qer-app-pwdportal/package.json
index edc2b6e29..2968187c8 100644
--- a/imxweb/projects/qer-app-pwdportal/package.json
+++ b/imxweb/projects/qer-app-pwdportal/package.json
@@ -1,5 +1,5 @@
{
"name": "qer-app-pwdportal",
- "version": "8.2.0",
+ "version": "9.0.0",
"private": true
}
\ No newline at end of file
diff --git a/imxweb/projects/qer-app-pwdportal/src/app/app-routing.module.ts b/imxweb/projects/qer-app-pwdportal/src/app/app-routing.module.ts
index c038600d7..0370c9bb6 100644
--- a/imxweb/projects/qer-app-pwdportal/src/app/app-routing.module.ts
+++ b/imxweb/projects/qer-app-pwdportal/src/app/app-routing.module.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-pwdportal/src/app/app.component.html b/imxweb/projects/qer-app-pwdportal/src/app/app.component.html
index 30c32b69d..ae5e1f2c2 100644
--- a/imxweb/projects/qer-app-pwdportal/src/app/app.component.html
+++ b/imxweb/projects/qer-app-pwdportal/src/app/app.component.html
@@ -5,6 +5,6 @@
-
+
\ No newline at end of file
diff --git a/imxweb/projects/qer-app-pwdportal/src/app/app.component.spec.ts b/imxweb/projects/qer-app-pwdportal/src/app/app.component.spec.ts
index da437f4ab..bb0c8babc 100644
--- a/imxweb/projects/qer-app-pwdportal/src/app/app.component.spec.ts
+++ b/imxweb/projects/qer-app-pwdportal/src/app/app.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -30,7 +30,7 @@ import { RouterTestingModule } from '@angular/router/testing';
import { configureTestSuite } from 'ng-bullet';
import { of, Subject } from 'rxjs';
-import { AuthenticationService, clearStylesFromDOM } from 'qbm';
+import { AuthenticationService, clearStylesFromDOM, SplashService } from 'qbm';
import { AppComponent } from './app.component';
import { ProjectConfigurationService } from 'qer';
@@ -52,6 +52,12 @@ for (const navigationState of [
events: of(navigationState)
};
+ const splashServiceStub = {
+ init: jasmine.createSpy('init'),
+ update: jasmine.createSpy('update'),
+ close: jasmine.createSpy('close'),
+ }
+
const mockAuthService = {
onSessionResponse: new Subject()
};
@@ -76,6 +82,10 @@ for (const navigationState of [
{
provide: ProjectConfigurationService,
useValue: projectConfigService
+ },
+ {
+ provide: SplashService,
+ useValue: splashServiceStub
}
]
});
diff --git a/imxweb/projects/qer-app-pwdportal/src/app/app.component.ts b/imxweb/projects/qer-app-pwdportal/src/app/app.component.ts
index a004276e8..b6d0d75c0 100644
--- a/imxweb/projects/qer-app-pwdportal/src/app/app.component.ts
+++ b/imxweb/projects/qer-app-pwdportal/src/app/app.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -28,7 +28,7 @@ import { Component, OnDestroy, OnInit } from '@angular/core';
import { NavigationCancel, NavigationEnd, NavigationError, NavigationStart, Router, RouterEvent } from '@angular/router';
import { Subscription } from 'rxjs';
-import { AuthenticationService, ISessionState } from 'qbm';
+import { AuthenticationService, ISessionState, SplashService } from 'qbm';
@Component({
selector: 'imx-root',
@@ -38,18 +38,29 @@ import { AuthenticationService, ISessionState } from 'qbm';
export class AppComponent implements OnInit, OnDestroy {
public isLoggedIn = false;
public hideUserMessage = false;
+ public showPageContent = false;
private readonly subscriptions: Subscription[] = [];
constructor(
private readonly authentication: AuthenticationService,
private readonly router: Router,
+ private readonly splash: SplashService,
) {
this.subscriptions.push(
this.authentication.onSessionResponse.subscribe(async (sessionState: ISessionState) => {
+
+ if (sessionState.hasErrorState) {
+ // Needs to close here when there is an error on sessionState
+ this.splash.close();
+ }
+
this.isLoggedIn = sessionState.IsLoggedIn;
if (this.isLoggedIn) {
+ // Close the splash screen that opened in app service initialisation
+ // Needs to close here when running in containers (auth skipped)
+ this.splash.close();
}
})
);
@@ -69,6 +80,10 @@ export class AppComponent implements OnInit, OnDestroy {
this.router.events.subscribe(((event: RouterEvent) => {
if (event instanceof NavigationStart) {
this.hideUserMessage = true;
+ if (this.isLoggedIn && event.url === '/') {
+ // show the splash screen, when the user logs out!
+ this.splash.init({ applicationName: 'Password Reset Portal' });
+ }
}
if (event instanceof NavigationCancel) {
@@ -77,6 +92,8 @@ export class AppComponent implements OnInit, OnDestroy {
if (event instanceof NavigationEnd) {
this.hideUserMessage = false;
+ // show the pageContent, if the user is logged in or the login page is shown
+ this.showPageContent = this.isLoggedIn || event.urlAfterRedirects === '/';
}
if (event instanceof NavigationError) {
diff --git a/imxweb/projects/qer-app-pwdportal/src/app/app.module.ts b/imxweb/projects/qer-app-pwdportal/src/app/app.module.ts
index 10443fcf4..7ae4b7d52 100644
--- a/imxweb/projects/qer-app-pwdportal/src/app/app.module.ts
+++ b/imxweb/projects/qer-app-pwdportal/src/app/app.module.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-pwdportal/src/app/app.service.spec.ts b/imxweb/projects/qer-app-pwdportal/src/app/app.service.spec.ts
index b10e9b10b..74b121011 100644
--- a/imxweb/projects/qer-app-pwdportal/src/app/app.service.spec.ts
+++ b/imxweb/projects/qer-app-pwdportal/src/app/app.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -31,7 +31,7 @@ import { LoggerTestingModule } from 'ngx-logger/testing';
import { TranslateService } from '@ngx-translate/core';
import { BehaviorSubject, of } from 'rxjs';
-import { AppConfigService, AuthenticationService, imx_SessionService, ImxTranslationProviderService, PluginLoaderService } from 'qbm';
+import { AppConfigService, AuthenticationService, imx_SessionService, ImxTranslationProviderService, PluginLoaderService, SplashService } from 'qbm';
import { AppService } from './app.service';
describe('AppService', () => {
@@ -46,6 +46,12 @@ describe('AppService', () => {
onLangChange: { subscribe: () => {}},
};
+ splash = {
+ init: jasmine.createSpy('init'),
+ update: jasmine.createSpy('update'),
+ close: jasmine.createSpy('close'),
+ }
+
translationProvider = {
init: jasmine.createSpy('init').and.returnValue(Promise.resolve())
};
@@ -126,6 +132,10 @@ describe('AppService', () => {
{
provide: AuthenticationService,
useValue: mocks.authentication
+ },
+ {
+ provide: SplashService,
+ useValue: mocks.splash
}
]
});
diff --git a/imxweb/projects/qer-app-pwdportal/src/app/app.service.ts b/imxweb/projects/qer-app-pwdportal/src/app/app.service.ts
index 2688e12ec..3dc24b18b 100644
--- a/imxweb/projects/qer-app-pwdportal/src/app/app.service.ts
+++ b/imxweb/projects/qer-app-pwdportal/src/app/app.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -24,15 +24,20 @@
*
*/
-import { Injectable, ComponentFactoryResolver } from '@angular/core';
+import { Injectable } from '@angular/core';
import { Title } from '@angular/platform-browser';
import { TranslateService } from '@ngx-translate/core';
import { Globals } from 'imx-qbm-dbts';
import {
- AppConfigService, AuthenticationService, imx_SessionService,
- CdrRegistryService, ImxTranslationProviderService, ClassloggerService,
- PluginLoaderService
+ AppConfigService,
+ AuthenticationService,
+ imx_SessionService,
+ CdrRegistryService,
+ ImxTranslationProviderService,
+ ClassloggerService,
+ PluginLoaderService,
+ SplashService
} from 'qbm';
import { environment } from '../environments/environment';
import { TypedClient } from 'imx-api-qbm';
@@ -48,19 +53,20 @@ declare var SystemJS: any;
})
export class AppService {
constructor(
- private logger: ClassloggerService,
+ public readonly registry: CdrRegistryService,
+ private readonly logger: ClassloggerService,
private readonly config: AppConfigService,
private readonly translateService: TranslateService,
private readonly session: imx_SessionService,
private readonly translationProvider: ImxTranslationProviderService,
private readonly title: Title,
- public readonly registry: CdrRegistryService,
- public readonly resolver: ComponentFactoryResolver,
private readonly pluginLoader: PluginLoaderService,
- private readonly authentication: AuthenticationService
+ private readonly authentication: AuthenticationService,
+ private readonly splash: SplashService,
) { }
public async init(): Promise {
+ this.showSplash();
await this.config.init(environment.clientUrl);
this.translateService.addLangs(this.config.Config.Translation.Langs);
@@ -90,6 +96,8 @@ export class AppService {
this.config.Config.Title = await this.translateService.get('#LDS#Heading Password Reset Portal').toPromise();
const title = `${name} ${this.config.Config.Title}`;
this.title.setTitle(title);
+
+ await this.updateSplash(title);
}
public static init(app: AppService): () => Promise {
@@ -99,4 +107,15 @@ export class AppService {
resolve();
});
}
+
+ private showSplash(): void {
+ // open splash screen with fix values
+ this.splash.init({ applicationName: 'Password Reset Portal' });
+ }
+
+ private async updateSplash(title: string): Promise {
+ // update the splash screen and use translated texts and the title from the imxconfig
+ const loadingMsg = await this.translateService.get('#LDS#Loading...').toPromise();
+ this.splash.update({ applicationName: title, message: loadingMsg });
+ }
}
diff --git a/imxweb/projects/qer-app-pwdportal/src/environments/environment.prod.ts b/imxweb/projects/qer-app-pwdportal/src/environments/environment.prod.ts
index af15687e8..8a5123ba6 100644
--- a/imxweb/projects/qer-app-pwdportal/src/environments/environment.prod.ts
+++ b/imxweb/projects/qer-app-pwdportal/src/environments/environment.prod.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-pwdportal/src/environments/environment.ts b/imxweb/projects/qer-app-pwdportal/src/environments/environment.ts
index 06160abce..0988fd956 100644
--- a/imxweb/projects/qer-app-pwdportal/src/environments/environment.ts
+++ b/imxweb/projects/qer-app-pwdportal/src/environments/environment.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-pwdportal/src/main.ts b/imxweb/projects/qer-app-pwdportal/src/main.ts
index fedc4780e..0d6be56bc 100644
--- a/imxweb/projects/qer-app-pwdportal/src/main.ts
+++ b/imxweb/projects/qer-app-pwdportal/src/main.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-pwdportal/src/polyfills.ts b/imxweb/projects/qer-app-pwdportal/src/polyfills.ts
index 987767f82..02b0a61d5 100644
--- a/imxweb/projects/qer-app-pwdportal/src/polyfills.ts
+++ b/imxweb/projects/qer-app-pwdportal/src/polyfills.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer-app-pwdportal/src/styles.scss b/imxweb/projects/qer-app-pwdportal/src/styles.scss
index deb0d6ead..39bf32251 100644
--- a/imxweb/projects/qer-app-pwdportal/src/styles.scss
+++ b/imxweb/projects/qer-app-pwdportal/src/styles.scss
@@ -1,6 +1,9 @@
/* You can add global styles to this file, and also import other style files */
-$material_icons_font_path: "~@elemental-ui/core/assets/MaterialIcons";
-$cadence_font_path: "~@elemental-ui/cadence-icon/dist";
-$source_sans_pro_font_path: "~@elemental-ui/core/assets/Source_Sans_Pro";
-@import '~@elemental-ui/core/src/styles/core.scss';
+@use '@angular/material' as mat;
+
+$material_icons_font_path: "~node_modules/@elemental-ui/core/assets/MaterialIcons";
+$cadence_font_path: "~node_modules/@elemental-ui/core/assets/Cadence";
+$source_sans_pro_font_path: "~node_modules/@elemental-ui/core/assets/Source_Sans_Pro";
+
+@import '@elemental-ui/core/src/styles/core.scss';
diff --git a/imxweb/projects/qer-app-pwdportal/src/test.ts b/imxweb/projects/qer-app-pwdportal/src/test.ts
index c51131720..fb558848c 100644
--- a/imxweb/projects/qer-app-pwdportal/src/test.ts
+++ b/imxweb/projects/qer-app-pwdportal/src/test.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/package.json b/imxweb/projects/qer/package.json
index 1e1e583db..7e0d7ad49 100644
--- a/imxweb/projects/qer/package.json
+++ b/imxweb/projects/qer/package.json
@@ -1,6 +1,6 @@
{
"name": "qer",
- "version": "8.2.0",
+ "version": "9.0.0",
"private": true,
"dependencies": {
diff --git a/imxweb/projects/qer/src/lib/addressbook/addressbook-detail/addressbook-detail.component.scss b/imxweb/projects/qer/src/lib/addressbook/addressbook-detail/addressbook-detail.component.scss
index ed499ccbe..3bb0bfc86 100644
--- a/imxweb/projects/qer/src/lib/addressbook/addressbook-detail/addressbook-detail.component.scss
+++ b/imxweb/projects/qer/src/lib/addressbook/addressbook-detail/addressbook-detail.component.scss
@@ -1,4 +1,4 @@
-@import '~@elemental-ui/core/src/styles/_palette.scss';
+@import '@elemental-ui/core/src/styles/_palette.scss';
:host {
background-color: $asher-gray;
diff --git a/imxweb/projects/qer/src/lib/addressbook/addressbook-detail/addressbook-detail.component.spec.ts b/imxweb/projects/qer/src/lib/addressbook/addressbook-detail/addressbook-detail.component.spec.ts
index f891a0d2f..9871e5e58 100644
--- a/imxweb/projects/qer/src/lib/addressbook/addressbook-detail/addressbook-detail.component.spec.ts
+++ b/imxweb/projects/qer/src/lib/addressbook/addressbook-detail/addressbook-detail.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/addressbook/addressbook-detail/addressbook-detail.component.ts b/imxweb/projects/qer/src/lib/addressbook/addressbook-detail/addressbook-detail.component.ts
index 0a19f7364..ddcf328b5 100644
--- a/imxweb/projects/qer/src/lib/addressbook/addressbook-detail/addressbook-detail.component.ts
+++ b/imxweb/projects/qer/src/lib/addressbook/addressbook-detail/addressbook-detail.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/addressbook/addressbook-detail/addressbook-detail.interface.ts b/imxweb/projects/qer/src/lib/addressbook/addressbook-detail/addressbook-detail.interface.ts
index 2aa0ba887..4a20e8c82 100644
--- a/imxweb/projects/qer/src/lib/addressbook/addressbook-detail/addressbook-detail.interface.ts
+++ b/imxweb/projects/qer/src/lib/addressbook/addressbook-detail/addressbook-detail.interface.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/addressbook/addressbook.component.spec.ts b/imxweb/projects/qer/src/lib/addressbook/addressbook.component.spec.ts
index b8e6da936..31c8a3741 100644
--- a/imxweb/projects/qer/src/lib/addressbook/addressbook.component.spec.ts
+++ b/imxweb/projects/qer/src/lib/addressbook/addressbook.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/addressbook/addressbook.component.ts b/imxweb/projects/qer/src/lib/addressbook/addressbook.component.ts
index c3afcd738..82ad62c7a 100644
--- a/imxweb/projects/qer/src/lib/addressbook/addressbook.component.ts
+++ b/imxweb/projects/qer/src/lib/addressbook/addressbook.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/addressbook/addressbook.module.ts b/imxweb/projects/qer/src/lib/addressbook/addressbook.module.ts
index ef5fea483..b96747ae2 100644
--- a/imxweb/projects/qer/src/lib/addressbook/addressbook.module.ts
+++ b/imxweb/projects/qer/src/lib/addressbook/addressbook.module.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/addressbook/addressbook.service.spec.ts b/imxweb/projects/qer/src/lib/addressbook/addressbook.service.spec.ts
index 1c975380f..20a172ee2 100644
--- a/imxweb/projects/qer/src/lib/addressbook/addressbook.service.spec.ts
+++ b/imxweb/projects/qer/src/lib/addressbook/addressbook.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/addressbook/addressbook.service.ts b/imxweb/projects/qer/src/lib/addressbook/addressbook.service.ts
index f9443990e..a02098a43 100644
--- a/imxweb/projects/qer/src/lib/addressbook/addressbook.service.ts
+++ b/imxweb/projects/qer/src/lib/addressbook/addressbook.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/admin/feature-config.service.ts b/imxweb/projects/qer/src/lib/admin/feature-config.service.ts
index e9f11e84c..cabc41720 100644
--- a/imxweb/projects/qer/src/lib/admin/feature-config.service.ts
+++ b/imxweb/projects/qer/src/lib/admin/feature-config.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/admin/qer-permissions-helper.ts b/imxweb/projects/qer/src/lib/admin/qer-permissions-helper.ts
index d56e076fb..f89b3569a 100644
--- a/imxweb/projects/qer/src/lib/admin/qer-permissions-helper.ts
+++ b/imxweb/projects/qer/src/lib/admin/qer-permissions-helper.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/admin/qer-permissions.service.spec.ts b/imxweb/projects/qer/src/lib/admin/qer-permissions.service.spec.ts
index 7d7b6ab89..26812ed7f 100644
--- a/imxweb/projects/qer/src/lib/admin/qer-permissions.service.spec.ts
+++ b/imxweb/projects/qer/src/lib/admin/qer-permissions.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/admin/qer-permissions.service.ts b/imxweb/projects/qer/src/lib/admin/qer-permissions.service.ts
index 93c445e0c..51480b28b 100644
--- a/imxweb/projects/qer/src/lib/admin/qer-permissions.service.ts
+++ b/imxweb/projects/qer/src/lib/admin/qer-permissions.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/businessowner-addon-tile/businessowner-addon-tile.component.spec.ts b/imxweb/projects/qer/src/lib/businessowner-addon-tile/businessowner-addon-tile.component.spec.ts
index 44c9d4c80..80d6ff27a 100644
--- a/imxweb/projects/qer/src/lib/businessowner-addon-tile/businessowner-addon-tile.component.spec.ts
+++ b/imxweb/projects/qer/src/lib/businessowner-addon-tile/businessowner-addon-tile.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/businessowner-addon-tile/businessowner-addon-tile.component.ts b/imxweb/projects/qer/src/lib/businessowner-addon-tile/businessowner-addon-tile.component.ts
index 2e677e85c..9e2323aea 100644
--- a/imxweb/projects/qer/src/lib/businessowner-addon-tile/businessowner-addon-tile.component.ts
+++ b/imxweb/projects/qer/src/lib/businessowner-addon-tile/businessowner-addon-tile.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/businessowner-addon-tile/businessowner-addon-tile.module.ts b/imxweb/projects/qer/src/lib/businessowner-addon-tile/businessowner-addon-tile.module.ts
index ec2c1da58..ad1b24532 100644
--- a/imxweb/projects/qer/src/lib/businessowner-addon-tile/businessowner-addon-tile.module.ts
+++ b/imxweb/projects/qer/src/lib/businessowner-addon-tile/businessowner-addon-tile.module.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/businessowner-overview-tile/businessowner-overview-tile.component.spec.ts b/imxweb/projects/qer/src/lib/businessowner-overview-tile/businessowner-overview-tile.component.spec.ts
index a55a3d7c7..529f3d36b 100644
--- a/imxweb/projects/qer/src/lib/businessowner-overview-tile/businessowner-overview-tile.component.spec.ts
+++ b/imxweb/projects/qer/src/lib/businessowner-overview-tile/businessowner-overview-tile.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/businessowner-overview-tile/businessowner-overview-tile.component.ts b/imxweb/projects/qer/src/lib/businessowner-overview-tile/businessowner-overview-tile.component.ts
index 5cc7fcc46..4a58b2833 100644
--- a/imxweb/projects/qer/src/lib/businessowner-overview-tile/businessowner-overview-tile.component.ts
+++ b/imxweb/projects/qer/src/lib/businessowner-overview-tile/businessowner-overview-tile.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/businessowner-overview-tile/businessowner-overview-tile.module.ts b/imxweb/projects/qer/src/lib/businessowner-overview-tile/businessowner-overview-tile.module.ts
index 5a8bab7dd..1501a85ff 100644
--- a/imxweb/projects/qer/src/lib/businessowner-overview-tile/businessowner-overview-tile.module.ts
+++ b/imxweb/projects/qer/src/lib/businessowner-overview-tile/businessowner-overview-tile.module.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/data-explorer-view/data-explorer-extension.ts b/imxweb/projects/qer/src/lib/data-explorer-view/data-explorer-extension.ts
index 5f038e575..39d0b85c6 100644
--- a/imxweb/projects/qer/src/lib/data-explorer-view/data-explorer-extension.ts
+++ b/imxweb/projects/qer/src/lib/data-explorer-view/data-explorer-extension.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/data-explorer-view/data-explorer-registry.service.ts b/imxweb/projects/qer/src/lib/data-explorer-view/data-explorer-registry.service.ts
index 29b26376f..0ea4ea63f 100644
--- a/imxweb/projects/qer/src/lib/data-explorer-view/data-explorer-registry.service.ts
+++ b/imxweb/projects/qer/src/lib/data-explorer-view/data-explorer-registry.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/data-explorer-view/data-explorer-view.component.scss b/imxweb/projects/qer/src/lib/data-explorer-view/data-explorer-view.component.scss
index 52eb8f0db..2ba1b9e62 100644
--- a/imxweb/projects/qer/src/lib/data-explorer-view/data-explorer-view.component.scss
+++ b/imxweb/projects/qer/src/lib/data-explorer-view/data-explorer-view.component.scss
@@ -1,4 +1,4 @@
-@import "~@elemental-ui/core/src/styles/_palette.scss";
+@import "@elemental-ui/core/src/styles/_palette.scss";
:host {
height: 100%;
diff --git a/imxweb/projects/qer/src/lib/data-explorer-view/data-explorer-view.component.spec.ts b/imxweb/projects/qer/src/lib/data-explorer-view/data-explorer-view.component.spec.ts
index 99953e053..5d9968c6e 100644
--- a/imxweb/projects/qer/src/lib/data-explorer-view/data-explorer-view.component.spec.ts
+++ b/imxweb/projects/qer/src/lib/data-explorer-view/data-explorer-view.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/data-explorer-view/data-explorer-view.component.ts b/imxweb/projects/qer/src/lib/data-explorer-view/data-explorer-view.component.ts
index b2baee107..58bd56d9b 100644
--- a/imxweb/projects/qer/src/lib/data-explorer-view/data-explorer-view.component.ts
+++ b/imxweb/projects/qer/src/lib/data-explorer-view/data-explorer-view.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/data-explorer-view/data-explorer-view.module.ts b/imxweb/projects/qer/src/lib/data-explorer-view/data-explorer-view.module.ts
index c386d32c2..c775e5349 100644
--- a/imxweb/projects/qer/src/lib/data-explorer-view/data-explorer-view.module.ts
+++ b/imxweb/projects/qer/src/lib/data-explorer-view/data-explorer-view.module.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/delegation/delegation.component.scss b/imxweb/projects/qer/src/lib/delegation/delegation.component.scss
index c69075985..831b73fcd 100644
--- a/imxweb/projects/qer/src/lib/delegation/delegation.component.scss
+++ b/imxweb/projects/qer/src/lib/delegation/delegation.component.scss
@@ -1,4 +1,4 @@
-@import "~@elemental-ui/core/src/styles/_palette.scss";
+@import "@elemental-ui/core/src/styles/_palette.scss";
:host {
display: flex;
@@ -38,7 +38,6 @@
.imx-delegation-stepper {
flex: 1 1 auto;
- width: 1200px;
max-width: 100%;
background-color: $white;
overflow: auto;
diff --git a/imxweb/projects/qer/src/lib/delegation/delegation.component.ts b/imxweb/projects/qer/src/lib/delegation/delegation.component.ts
index 1af3214f0..0d8b4a2ca 100644
--- a/imxweb/projects/qer/src/lib/delegation/delegation.component.ts
+++ b/imxweb/projects/qer/src/lib/delegation/delegation.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -130,7 +130,8 @@ export class DelegationComponent implements OnInit, OnDestroy {
this.subscriptions.push(this.authenticationservice.onSessionResponse.subscribe(async session => {
this.uidPerson = session.UserUid;
- const role = await this.delegationService.getRoleClasses(this.uidPerson);
+ const role = (await this.delegationService.getRoleClasses(this.uidPerson))
+ .filter(r => r.CountRolesOwned.value > 0);
this.roleClasses = role;
// pre-select all role classes
this.globalDelegation.UidOrgRoot = role.map(r => r.GetEntity().GetKeys()[0]);
diff --git a/imxweb/projects/qer/src/lib/delegation/delegation.module.ts b/imxweb/projects/qer/src/lib/delegation/delegation.module.ts
index 069fe8dee..4112260c4 100644
--- a/imxweb/projects/qer/src/lib/delegation/delegation.module.ts
+++ b/imxweb/projects/qer/src/lib/delegation/delegation.module.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/delegation/delegation.service.spec.ts b/imxweb/projects/qer/src/lib/delegation/delegation.service.spec.ts
index 2b2bf66ff..a361fc4b9 100644
--- a/imxweb/projects/qer/src/lib/delegation/delegation.service.spec.ts
+++ b/imxweb/projects/qer/src/lib/delegation/delegation.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/delegation/delegation.service.ts b/imxweb/projects/qer/src/lib/delegation/delegation.service.ts
index 668190216..cb7653b8d 100644
--- a/imxweb/projects/qer/src/lib/delegation/delegation.service.ts
+++ b/imxweb/projects/qer/src/lib/delegation/delegation.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -56,7 +56,7 @@ export class DelegationService {
}
public async getRoleClasses(uidUser: string): Promise {
- return (await this.qerApiService.typedClient.PortalDelegationsGlobalRoleclasses.Get(uidUser)).Data;
+ return (await this.qerApiService.typedClient.PortalDelegationsGlobalRoleclasses.Get(uidUser, { PageSize: 1024 })).Data;
}
public async commitDelegations(reference: PortalDelegations, objectKeys: string[]): Promise {
diff --git a/imxweb/projects/qer/src/lib/dynamic-exclusion-dialog/dynamic-exclusion-dialog.component.spec.ts b/imxweb/projects/qer/src/lib/dynamic-exclusion-dialog/dynamic-exclusion-dialog.component.spec.ts
index eaa0456b8..b8a4b984a 100644
--- a/imxweb/projects/qer/src/lib/dynamic-exclusion-dialog/dynamic-exclusion-dialog.component.spec.ts
+++ b/imxweb/projects/qer/src/lib/dynamic-exclusion-dialog/dynamic-exclusion-dialog.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/dynamic-exclusion-dialog/dynamic-exclusion-dialog.component.ts b/imxweb/projects/qer/src/lib/dynamic-exclusion-dialog/dynamic-exclusion-dialog.component.ts
index 381d4f07c..453c673c7 100644
--- a/imxweb/projects/qer/src/lib/dynamic-exclusion-dialog/dynamic-exclusion-dialog.component.ts
+++ b/imxweb/projects/qer/src/lib/dynamic-exclusion-dialog/dynamic-exclusion-dialog.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/dynamic-exclusion-dialog/dynamic-exclusion-dialog.module.ts b/imxweb/projects/qer/src/lib/dynamic-exclusion-dialog/dynamic-exclusion-dialog.module.ts
index cb88e8cf6..0a3e50fe2 100644
--- a/imxweb/projects/qer/src/lib/dynamic-exclusion-dialog/dynamic-exclusion-dialog.module.ts
+++ b/imxweb/projects/qer/src/lib/dynamic-exclusion-dialog/dynamic-exclusion-dialog.module.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/guards/application-guard.service.spec.ts b/imxweb/projects/qer/src/lib/guards/application-guard.service.spec.ts
index ceb543db2..2ac2aa1a0 100644
--- a/imxweb/projects/qer/src/lib/guards/application-guard.service.spec.ts
+++ b/imxweb/projects/qer/src/lib/guards/application-guard.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/guards/application-guard.service.ts b/imxweb/projects/qer/src/lib/guards/application-guard.service.ts
index e1e7389c8..9b75315ed 100644
--- a/imxweb/projects/qer/src/lib/guards/application-guard.service.ts
+++ b/imxweb/projects/qer/src/lib/guards/application-guard.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/guards/itshop-pattern-guard.service.spec.ts b/imxweb/projects/qer/src/lib/guards/itshop-pattern-guard.service.spec.ts
new file mode 100644
index 000000000..cfbda5914
--- /dev/null
+++ b/imxweb/projects/qer/src/lib/guards/itshop-pattern-guard.service.spec.ts
@@ -0,0 +1,126 @@
+/*
+ * ONE IDENTITY LLC. PROPRIETARY INFORMATION
+ *
+ * This software is confidential. One Identity, LLC. or one of its affiliates or
+ * subsidiaries, has supplied this software to you under terms of a
+ * license agreement, nondisclosure agreement or both.
+ *
+ * You may not copy, disclose, or use this software except in accordance with
+ * those terms.
+ *
+ *
+ * Copyright 2022 One Identity LLC.
+ * ALL RIGHTS RESERVED.
+ *
+ * ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
+ * WARRANTIES ABOUT THE SUITABILITY OF THE SOFTWARE,
+ * EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
+ * TO THE IMPLIED WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE, OR
+ * NON-INFRINGEMENT. ONE IDENTITY LLC. SHALL NOT BE
+ * LIABLE FOR ANY DAMAGES SUFFERED BY LICENSEE
+ * AS A RESULT OF USING, MODIFYING OR DISTRIBUTING
+ * THIS SOFTWARE OR ITS DERIVATIVES.
+ *
+ */
+
+import { Component } from '@angular/core';
+import { TestBed, fakeAsync, flush } from '@angular/core/testing';
+import { RouterTestingModule } from '@angular/router/testing';
+import { configureTestSuite } from 'ng-bullet';
+import { Subject } from 'rxjs';
+
+import { AppConfigService, AuthenticationService, ISessionState } from 'qbm';
+import { ItshopPatternGuardService } from './itshop-pattern-guard.service';
+import { ProjectConfigurationService } from '../project-configuration/project-configuration.service';
+
+@Component({
+ template: `
Dummy
`
+})
+class DummyComponent {
+}
+
+describe('ItshopPatternGuardService', () => {
+ let service: ItshopPatternGuardService;
+
+ const authenticationServiceStub = {
+ onSessionResponse: new Subject(),
+ };
+
+ let isRequestTemplatesEnabled = false;
+
+ const projectConfigurationServiceStub = {
+ getConfig: jasmine.createSpy('getConfig').and.callFake(() => Promise.resolve(
+ {
+ ITShopConfig: {
+ VI_ITShop_ProductSelectionFromTemplate: isRequestTemplatesEnabled
+ }
+ }
+ ))
+ }
+
+
+ configureTestSuite(() => {
+ TestBed.configureTestingModule({
+ declarations: [DummyComponent],
+ imports: [RouterTestingModule.withRoutes([
+ { path: 'dashboard', component: DummyComponent }
+ ])],
+ providers: [
+ ItshopPatternGuardService,
+ {
+ provide: ProjectConfigurationService,
+ useValue: projectConfigurationServiceStub,
+ },
+ {
+ provide: AuthenticationService,
+ useValue: authenticationServiceStub,
+ },
+ {
+ provide: AppConfigService,
+ useValue: {
+ Config: {
+ Title: '',
+ routeConfig: {
+ start: 'dashboard'
+ }
+ }
+ }
+ },
+ ],
+ });
+ });
+
+
+ beforeEach(() => {
+ service = TestBed.inject(ItshopPatternGuardService);
+ });
+
+ it('should be created', () => {
+ expect(service).toBeTruthy();
+ });
+
+ it('canActivate() should return true if VI_ITShop_ProductSelectionFromTemplate in ITShopConfig is enabled', fakeAsync(() => {
+ isRequestTemplatesEnabled = true;
+
+ service.canActivate().subscribe((val: boolean) => {
+ expect(val).toEqual(true);
+ });
+
+ authenticationServiceStub.onSessionResponse.next({ IsLoggedIn: true });
+
+ flush();
+ }));
+
+ it("canActivate() should return false if VI_ITShop_ProductSelectionFromTemplate in ITShopConfig is disnabled", fakeAsync(() => {
+ isRequestTemplatesEnabled = false;
+
+ service.canActivate().subscribe((val: boolean) => {
+ expect(val).toEqual(false);
+ });
+
+ authenticationServiceStub.onSessionResponse.next({ IsLoggedIn: true });
+
+ flush();
+ }));
+});
diff --git a/imxweb/projects/qer/src/lib/guards/itshop-pattern-guard.service.ts b/imxweb/projects/qer/src/lib/guards/itshop-pattern-guard.service.ts
new file mode 100644
index 000000000..09370fa59
--- /dev/null
+++ b/imxweb/projects/qer/src/lib/guards/itshop-pattern-guard.service.ts
@@ -0,0 +1,70 @@
+/*
+ * ONE IDENTITY LLC. PROPRIETARY INFORMATION
+ *
+ * This software is confidential. One Identity, LLC. or one of its affiliates or
+ * subsidiaries, has supplied this software to you under terms of a
+ * license agreement, nondisclosure agreement or both.
+ *
+ * You may not copy, disclose, or use this software except in accordance with
+ * those terms.
+ *
+ *
+ * Copyright 2022 One Identity LLC.
+ * ALL RIGHTS RESERVED.
+ *
+ * ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
+ * WARRANTIES ABOUT THE SUITABILITY OF THE SOFTWARE,
+ * EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
+ * TO THE IMPLIED WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE, OR
+ * NON-INFRINGEMENT. ONE IDENTITY LLC. SHALL NOT BE
+ * LIABLE FOR ANY DAMAGES SUFFERED BY LICENSEE
+ * AS A RESULT OF USING, MODIFYING OR DISTRIBUTING
+ * THIS SOFTWARE OR ITS DERIVATIVES.
+ *
+ */
+
+import { Injectable, OnDestroy } from '@angular/core';
+import { CanActivate, Router } from '@angular/router';
+import { Observable, Subscription } from 'rxjs';
+
+import { AppConfigService, AuthenticationService, ISessionState } from 'qbm';
+import { ProjectConfigurationService } from '../project-configuration/project-configuration.service';
+
+/**
+ * Guard that checks if the config key "VI_ITShop_ProductSelectionFromTemplate" is enabled.
+ */
+@Injectable({
+ providedIn: 'root',
+})
+export class ItshopPatternGuardService implements CanActivate, OnDestroy {
+ private onSessionResponse: Subscription;
+
+ constructor(
+ private readonly projectConfig: ProjectConfigurationService,
+ private readonly authentication: AuthenticationService,
+ private readonly appConfig: AppConfigService,
+ private readonly router: Router
+ ) { }
+
+ public canActivate(): Observable {
+ return new Observable((observer) => {
+ this.onSessionResponse = this.authentication.onSessionResponse.subscribe(async (sessionState: ISessionState) => {
+ if (sessionState.IsLoggedIn) {
+ const isRequestTemplateEnabled = (await this.projectConfig.getConfig()).ITShopConfig.VI_ITShop_ProductSelectionFromTemplate;
+ if (!isRequestTemplateEnabled) {
+ this.router.navigate([this.appConfig.Config.routeConfig.start], { queryParams: {} });
+ }
+ observer.next(isRequestTemplateEnabled);
+ observer.complete();
+ }
+ });
+ });
+ }
+
+ public ngOnDestroy(): void {
+ if (this.onSessionResponse) {
+ this.onSessionResponse.unsubscribe();
+ }
+ }
+}
diff --git a/imxweb/projects/qer/src/lib/guards/person-admin-guard.service.spec.ts b/imxweb/projects/qer/src/lib/guards/person-admin-guard.service.spec.ts
index dd53bad9a..ca0b95a34 100644
--- a/imxweb/projects/qer/src/lib/guards/person-admin-guard.service.spec.ts
+++ b/imxweb/projects/qer/src/lib/guards/person-admin-guard.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/guards/person-admin-guard.service.ts b/imxweb/projects/qer/src/lib/guards/person-admin-guard.service.ts
index 1f447d52a..d0f613e90 100644
--- a/imxweb/projects/qer/src/lib/guards/person-admin-guard.service.ts
+++ b/imxweb/projects/qer/src/lib/guards/person-admin-guard.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/guards/shop-admin-guard.service.spec.ts b/imxweb/projects/qer/src/lib/guards/shop-admin-guard.service.spec.ts
index b64988d18..c290c63a7 100644
--- a/imxweb/projects/qer/src/lib/guards/shop-admin-guard.service.spec.ts
+++ b/imxweb/projects/qer/src/lib/guards/shop-admin-guard.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/guards/shop-admin-guard.service.ts b/imxweb/projects/qer/src/lib/guards/shop-admin-guard.service.ts
index d29aad077..d568c6ef8 100644
--- a/imxweb/projects/qer/src/lib/guards/shop-admin-guard.service.ts
+++ b/imxweb/projects/qer/src/lib/guards/shop-admin-guard.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/guards/struct-admin-guard.service.spec.ts b/imxweb/projects/qer/src/lib/guards/struct-admin-guard.service.spec.ts
index faa36cf27..e4eedeeb2 100644
--- a/imxweb/projects/qer/src/lib/guards/struct-admin-guard.service.spec.ts
+++ b/imxweb/projects/qer/src/lib/guards/struct-admin-guard.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/guards/struct-admin-guard.service.ts b/imxweb/projects/qer/src/lib/guards/struct-admin-guard.service.ts
index 3eb0af3fc..af6e79c3e 100644
--- a/imxweb/projects/qer/src/lib/guards/struct-admin-guard.service.ts
+++ b/imxweb/projects/qer/src/lib/guards/struct-admin-guard.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/helper-alert-content/helper-alert-content.interface.ts b/imxweb/projects/qer/src/lib/helper-alert-content/helper-alert-content.interface.ts
index 3ac99cb48..59664aa1c 100644
--- a/imxweb/projects/qer/src/lib/helper-alert-content/helper-alert-content.interface.ts
+++ b/imxweb/projects/qer/src/lib/helper-alert-content/helper-alert-content.interface.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/identities/create-new-identity/create-new-identity.component.ts b/imxweb/projects/qer/src/lib/identities/create-new-identity/create-new-identity.component.ts
index f839226f1..b71fd4d93 100644
--- a/imxweb/projects/qer/src/lib/identities/create-new-identity/create-new-identity.component.ts
+++ b/imxweb/projects/qer/src/lib/identities/create-new-identity/create-new-identity.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/identities/create-new-identity/duplicate-check-parameter.interface.ts b/imxweb/projects/qer/src/lib/identities/create-new-identity/duplicate-check-parameter.interface.ts
index 950ba3543..2634369c5 100644
--- a/imxweb/projects/qer/src/lib/identities/create-new-identity/duplicate-check-parameter.interface.ts
+++ b/imxweb/projects/qer/src/lib/identities/create-new-identity/duplicate-check-parameter.interface.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/identities/create-new-identity/duplicates-sidesheet/duplicates-sidesheet.component.scss b/imxweb/projects/qer/src/lib/identities/create-new-identity/duplicates-sidesheet/duplicates-sidesheet.component.scss
index 835bc7cc9..a562bcdb6 100644
--- a/imxweb/projects/qer/src/lib/identities/create-new-identity/duplicates-sidesheet/duplicates-sidesheet.component.scss
+++ b/imxweb/projects/qer/src/lib/identities/create-new-identity/duplicates-sidesheet/duplicates-sidesheet.component.scss
@@ -1,4 +1,4 @@
-@import "~@elemental-ui/core/src/styles/_palette.scss";
+@import "@elemental-ui/core/src/styles/_palette.scss";
:host {
background-color: $asher-gray;
diff --git a/imxweb/projects/qer/src/lib/identities/create-new-identity/duplicates-sidesheet/duplicates-sidesheet.component.ts b/imxweb/projects/qer/src/lib/identities/create-new-identity/duplicates-sidesheet/duplicates-sidesheet.component.ts
index 76b82f56b..a2a4bd1ee 100644
--- a/imxweb/projects/qer/src/lib/identities/create-new-identity/duplicates-sidesheet/duplicates-sidesheet.component.ts
+++ b/imxweb/projects/qer/src/lib/identities/create-new-identity/duplicates-sidesheet/duplicates-sidesheet.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/identities/identities-reports.service.spec.ts b/imxweb/projects/qer/src/lib/identities/identities-reports.service.spec.ts
index eeae953d7..d0482015f 100644
--- a/imxweb/projects/qer/src/lib/identities/identities-reports.service.spec.ts
+++ b/imxweb/projects/qer/src/lib/identities/identities-reports.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -92,7 +92,7 @@ describe('IdentitiesReportsService', () => {
service.personData();
- expect(mockQerApiService.client.portal_candidates_Person_get).toHaveBeenCalledWith(undefined, 0, 20, undefined, undefined, undefined);
+ expect(mockQerApiService.client.portal_candidates_Person_get).toHaveBeenCalledWith({ PageSize: 20, StartIndex: 0 });
});
it('personData(search) should call client method with correct parameters', () => {
@@ -100,6 +100,6 @@ describe('IdentitiesReportsService', () => {
service.personData('test');
- expect(mockQerApiService.client.portal_candidates_Person_get).toHaveBeenCalledWith(undefined, 0, 20, undefined, undefined, 'test');
+ expect(mockQerApiService.client.portal_candidates_Person_get).toHaveBeenCalledWith({ PageSize: 20, StartIndex: 0, search: 'test' });
});
});
diff --git a/imxweb/projects/qer/src/lib/identities/identities-reports.service.ts b/imxweb/projects/qer/src/lib/identities/identities-reports.service.ts
index 139005daa..3bb8dd35f 100644
--- a/imxweb/projects/qer/src/lib/identities/identities-reports.service.ts
+++ b/imxweb/projects/qer/src/lib/identities/identities-reports.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -48,14 +48,7 @@ export class IdentitiesReportsService {
public async personData(search?: string): Promise {
const options: CollectionLoadParameters = this.getDefaultDataOptions(search);
- return this.qerClient.client.portal_candidates_Person_get(
- options.OrderBy,
- options.StartIndex,
- options.PageSize,
- options.filter,
- options.withProperties,
- options.search
- );
+ return this.qerClient.client.portal_candidates_Person_get(options);
}
private getDefaultDataOptions(search?: string): CollectionLoadParameters {
diff --git a/imxweb/projects/qer/src/lib/identities/identities.component.scss b/imxweb/projects/qer/src/lib/identities/identities.component.scss
index e46c36b61..96105b5d1 100644
--- a/imxweb/projects/qer/src/lib/identities/identities.component.scss
+++ b/imxweb/projects/qer/src/lib/identities/identities.component.scss
@@ -1,4 +1,4 @@
-@import "~@elemental-ui/core/src/styles/_palette.scss";
+@import "@elemental-ui/core/src/styles/_palette.scss";
.data-explorer {
&.data-explorer--identities {
diff --git a/imxweb/projects/qer/src/lib/identities/identities.component.spec.ts b/imxweb/projects/qer/src/lib/identities/identities.component.spec.ts
index 5ad82d8da..076709ea3 100644
--- a/imxweb/projects/qer/src/lib/identities/identities.component.spec.ts
+++ b/imxweb/projects/qer/src/lib/identities/identities.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -204,7 +204,7 @@ describe('DataExplorerIdentitiesComponent', () => {
it('should create', () => {
expect(component).toBeTruthy();
});
-
+
it('should change navigation state', async () => {
await component.onNavigationStateChanged(navigationState);
expect(component.navigationState).toEqual(navigationState);
diff --git a/imxweb/projects/qer/src/lib/identities/identities.component.ts b/imxweb/projects/qer/src/lib/identities/identities.component.ts
index 113b95be1..9a5dc69c8 100644
--- a/imxweb/projects/qer/src/lib/identities/identities.component.ts
+++ b/imxweb/projects/qer/src/lib/identities/identities.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/identities/identities.module.ts b/imxweb/projects/qer/src/lib/identities/identities.module.ts
index 375a779f5..403519f1a 100644
--- a/imxweb/projects/qer/src/lib/identities/identities.module.ts
+++ b/imxweb/projects/qer/src/lib/identities/identities.module.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/identities/identities.service.spec.ts b/imxweb/projects/qer/src/lib/identities/identities.service.spec.ts
index 736073501..de8cb8464 100644
--- a/imxweb/projects/qer/src/lib/identities/identities.service.spec.ts
+++ b/imxweb/projects/qer/src/lib/identities/identities.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -51,7 +51,7 @@ describe('IdentitiesService', () => {
PortalPersonReportsInteractive: {
Get_byid: jasmine.createSpy('Get_byid').and.returnValue(Promise.resolve({ Data: ['test1'] })),
},
- PortalPersonReportsInteractive_byid: {
+ PortalPersonReportsinteractive: {
Get_byid: jasmine.createSpy('Get_byid').and.returnValue(Promise.resolve({ Data: ['test1'] })),
},
},
@@ -108,7 +108,7 @@ describe('IdentitiesService', () => {
it('retrieves persons details (as a manager)', async () => {
mockQerApiService.typedClient.PortalPersonReportsInteractive.Get_byid.calls.reset;
expect(await service.getPersonInteractive('test1')).toBeDefined();
- expect(mockQerApiService.typedClient.PortalPersonReportsInteractive_byid.Get_byid).toHaveBeenCalled();
+ expect(mockQerApiService.typedClient.PortalPersonReportsInteractive.Get_byid).toHaveBeenCalled();
});
it('retrieves the filter options for the identities', async () => {
diff --git a/imxweb/projects/qer/src/lib/identities/identities.service.ts b/imxweb/projects/qer/src/lib/identities/identities.service.ts
index 02446bef2..7a7d2291e 100644
--- a/imxweb/projects/qer/src/lib/identities/identities.service.ts
+++ b/imxweb/projects/qer/src/lib/identities/identities.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -132,17 +132,19 @@ export class IdentitiesService {
public async getGroupedAllPerson(columns: string, navigationState: CollectionLoadParameters): Promise {
this.logger.debug(this, `Retrieving person list`);
this.logger.trace('Navigation state', navigationState);
+
return this.qerClient.client.portal_admin_person_group_get(
- columns,
- '',
- undefined,
- navigationState.StartIndex,
- navigationState.PageSize,
- true,
- '',
- '',
- '',
- ''
+ {
+ by: columns,
+ def: '',
+ StartIndex: navigationState.StartIndex,
+ PageSize: navigationState.PageSize,
+ withcount: true,
+ withmanager: '',
+ orphaned: '',
+ deletedintarget: '',
+ isinactive: ''
+ }
);
}
@@ -172,7 +174,7 @@ export class IdentitiesService {
}
public async getPersonInteractive(uid: string): Promise> {
- return this.qerClient.typedClient.PortalPersonReportsInteractive_byid.Get_byid(uid);
+ return this.qerClient.typedClient.PortalPersonReportsInteractive.Get_byid(uid);
}
public async getDataModelAdmin(): Promise {
diff --git a/imxweb/projects/qer/src/lib/identities/identity-sidesheet/assignments/assignments.component.scss b/imxweb/projects/qer/src/lib/identities/identity-sidesheet/assignments/assignments.component.scss
index 108556867..cfcbe45f2 100644
--- a/imxweb/projects/qer/src/lib/identities/identity-sidesheet/assignments/assignments.component.scss
+++ b/imxweb/projects/qer/src/lib/identities/identity-sidesheet/assignments/assignments.component.scss
@@ -1,4 +1,4 @@
-@import "~@elemental-ui/core/src/styles/_palette.scss";
+@import "@elemental-ui/core/src/styles/_palette.scss";
:host {
height: 100%;
diff --git a/imxweb/projects/qer/src/lib/identities/identity-sidesheet/assignments/assignments.component.spec.ts b/imxweb/projects/qer/src/lib/identities/identity-sidesheet/assignments/assignments.component.spec.ts
index a49f67bbc..313b2991e 100644
--- a/imxweb/projects/qer/src/lib/identities/identity-sidesheet/assignments/assignments.component.spec.ts
+++ b/imxweb/projects/qer/src/lib/identities/identity-sidesheet/assignments/assignments.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/identities/identity-sidesheet/assignments/assignments.component.ts b/imxweb/projects/qer/src/lib/identities/identity-sidesheet/assignments/assignments.component.ts
index 49f47a4be..182b96697 100644
--- a/imxweb/projects/qer/src/lib/identities/identity-sidesheet/assignments/assignments.component.ts
+++ b/imxweb/projects/qer/src/lib/identities/identity-sidesheet/assignments/assignments.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/identities/identity-sidesheet/identity-role-memberships/identity-role-memberships-parameter.interface.ts b/imxweb/projects/qer/src/lib/identities/identity-sidesheet/identity-role-memberships/identity-role-memberships-parameter.interface.ts
index a75994e0d..646a95e1b 100644
--- a/imxweb/projects/qer/src/lib/identities/identity-sidesheet/identity-role-memberships/identity-role-memberships-parameter.interface.ts
+++ b/imxweb/projects/qer/src/lib/identities/identity-sidesheet/identity-role-memberships/identity-role-memberships-parameter.interface.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -35,7 +35,7 @@ export interface IdentityRoleMembershipsParameter {
/**
* a method, that provides the collection data
*/
- get?: (navigationState?: CollectionLoadParameters) => Promise;
+ get?: (uidPerson: string, navigationState?: CollectionLoadParameters) => Promise;
/**
* the data type used for typed entity building
diff --git a/imxweb/projects/qer/src/lib/identities/identity-sidesheet/identity-role-memberships/identity-role-memberships.component.scss b/imxweb/projects/qer/src/lib/identities/identity-sidesheet/identity-role-memberships/identity-role-memberships.component.scss
index b27e4c10c..b55f5b354 100644
--- a/imxweb/projects/qer/src/lib/identities/identity-sidesheet/identity-role-memberships/identity-role-memberships.component.scss
+++ b/imxweb/projects/qer/src/lib/identities/identity-sidesheet/identity-role-memberships/identity-role-memberships.component.scss
@@ -1,4 +1,4 @@
-@import "~@elemental-ui/core/src/styles/_palette.scss";
+@import "@elemental-ui/core/src/styles/_palette.scss";
:host {
overflow: hidden;
@@ -21,4 +21,4 @@
flex-direction: column;
overflow: auto;
margin-top: 20px;
-}
\ No newline at end of file
+}
diff --git a/imxweb/projects/qer/src/lib/identities/identity-sidesheet/identity-role-memberships/identity-role-memberships.component.ts b/imxweb/projects/qer/src/lib/identities/identity-sidesheet/identity-role-memberships/identity-role-memberships.component.ts
index d49d9b6af..cb7c6c0ff 100644
--- a/imxweb/projects/qer/src/lib/identities/identity-sidesheet/identity-role-memberships/identity-role-memberships.component.ts
+++ b/imxweb/projects/qer/src/lib/identities/identity-sidesheet/identity-role-memberships/identity-role-memberships.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -31,16 +31,19 @@ import { TranslateService } from '@ngx-translate/core';
import { CollectionLoadParameters, DisplayColumns, EntitySchema, IClientProperty, TypedEntity, ValType } from 'imx-qbm-dbts';
import { DataSourceToolbarSettings, DynamicTabDataProviderDirective, MetadataService, SettingsService } from 'qbm';
-import { SourceDetectiveSidesheetComponent, SourceDetectiveSidesheetData } from '../../../sourcedetective/sourcedetective-sidesheet.component';
+import { RoleService } from '../../../role-management/role.service';
+import {
+ SourceDetectiveSidesheetComponent,
+ SourceDetectiveSidesheetData,
+} from '../../../sourcedetective/sourcedetective-sidesheet.component';
import { SourceDetectiveType } from '../../../sourcedetective/sourcedetective-type.enum';
import { IdentityRoleMembershipsService } from './identity-role-memberships.service';
@Component({
templateUrl: './identity-role-memberships.component.html',
- styleUrls: ['./identity-role-memberships.component.scss']
+ styleUrls: ['./identity-role-memberships.component.scss'],
})
export class IdentityRoleMembershipsComponent implements OnInit {
-
public dstSettings: DataSourceToolbarSettings;
public readonly DisplayColumns = DisplayColumns;
public displayedColumns: IClientProperty[];
@@ -48,21 +51,20 @@ export class IdentityRoleMembershipsComponent implements OnInit {
public entitySchema: EntitySchema;
public withActions: boolean;
- private referrer: { objectuid: string; tablename: string; };
+ private referrer: { objectuid: string; tablename: string };
private navigationState: CollectionLoadParameters;
private displayedColumnsWithDisplay: IClientProperty[];
-
constructor(
private readonly busyService: EuiLoadingService,
private readonly metadataService: MetadataService,
private readonly roleMembershipsService: IdentityRoleMembershipsService,
+ private readonly membershipService: RoleService,
private readonly settingService: SettingsService,
private readonly sidesheet: EuiSidesheetService,
private readonly translate: TranslateService,
dataProvider: DynamicTabDataProviderDirective
) {
-
this.referrer = dataProvider.data;
this.entitySchema = this.roleMembershipsService.getSchema(this.referrer.tablename);
this.withActions = this.roleMembershipsService.canAnalyseAssignment(this.referrer.tablename);
@@ -75,14 +77,10 @@ export class IdentityRoleMembershipsComponent implements OnInit {
this.entitySchema.Columns.ValidUntil,
];
+ this.displayedColumnsWithDisplay = [...[this.entitySchema.Columns[DisplayColumns.DISPLAY_PROPERTYNAME]], ...this.displayedColumns];
if (this.withActions) {
- this.displayedColumns.push({ ColumnName: 'actions', Type: ValType.String });
+ this.displayedColumnsWithDisplay.push({ ColumnName: 'actions', Type: ValType.String });
}
-
- this.displayedColumnsWithDisplay = [
- ...[this.entitySchema.Columns[DisplayColumns.DISPLAY_PROPERTYNAME]],
- ...this.displayedColumns
- ];
}
public async ngOnInit(): Promise {
@@ -96,16 +94,15 @@ export class IdentityRoleMembershipsComponent implements OnInit {
return this.getData();
}
-
public async onShowDetails(entity: TypedEntity): Promise {
-
const uidPerson = this.referrer.objectuid;
+ const uidRole = this.membershipService.targetMap.get(this.referrer.tablename).membership.GetUidRole(entity.GetEntity());
const data: SourceDetectiveSidesheetData = {
UID_Person: uidPerson,
Type: SourceDetectiveType.MembershipOfRole,
- UID: entity.GetEntity().GetKeys()[0],
- TableName: this.referrer.tablename
+ UID: uidRole,
+ TableName: this.referrer.tablename,
};
this.sidesheet.open(SourceDetectiveSidesheetComponent, {
title: await this.translate.get('#LDS#Heading View Assignment Analysis').toPromise(),
@@ -134,23 +131,18 @@ export class IdentityRoleMembershipsComponent implements OnInit {
private async getData(): Promise {
let overlayRef: OverlayRef;
- setTimeout(() => overlayRef = this.busyService.show());
+ setTimeout(() => (overlayRef = this.busyService.show()));
try {
-
- const dataSource = await this.roleMembershipsService.get(
- this.referrer.tablename,
- { ...this.navigationState, ...{ uidPerson: this.referrer.objectuid } });
+ const dataSource = await this.roleMembershipsService.get(this.referrer.tablename, this.referrer.objectuid, this.navigationState);
this.dstSettings = {
displayedColumns: this.displayedColumnsWithDisplay,
dataSource,
entitySchema: this.entitySchema,
- navigationState: this.navigationState
+ navigationState: this.navigationState,
};
} finally {
setTimeout(() => this.busyService.hide(overlayRef));
}
}
-
-
}
diff --git a/imxweb/projects/qer/src/lib/identities/identity-sidesheet/identity-role-memberships/identity-role-memberships.module.ts b/imxweb/projects/qer/src/lib/identities/identity-sidesheet/identity-role-memberships/identity-role-memberships.module.ts
index 9330b252a..e2782bb01 100644
--- a/imxweb/projects/qer/src/lib/identities/identity-sidesheet/identity-role-memberships/identity-role-memberships.module.ts
+++ b/imxweb/projects/qer/src/lib/identities/identity-sidesheet/identity-role-memberships/identity-role-memberships.module.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/identities/identity-sidesheet/identity-role-memberships/identity-role-memberships.service.spec.ts b/imxweb/projects/qer/src/lib/identities/identity-sidesheet/identity-role-memberships/identity-role-memberships.service.spec.ts
index ce053ec76..1b0755797 100644
--- a/imxweb/projects/qer/src/lib/identities/identity-sidesheet/identity-role-memberships/identity-role-memberships.service.spec.ts
+++ b/imxweb/projects/qer/src/lib/identities/identity-sidesheet/identity-role-memberships/identity-role-memberships.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/identities/identity-sidesheet/identity-role-memberships/identity-role-memberships.service.ts b/imxweb/projects/qer/src/lib/identities/identity-sidesheet/identity-role-memberships/identity-role-memberships.service.ts
index 9e4401432..984be80e7 100644
--- a/imxweb/projects/qer/src/lib/identities/identity-sidesheet/identity-role-memberships/identity-role-memberships.service.ts
+++ b/imxweb/projects/qer/src/lib/identities/identity-sidesheet/identity-role-memberships/identity-role-memberships.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -55,7 +55,7 @@ export class IdentityRoleMembershipsService {
this.addPredefinedTargets();
}
- public async get(target: string, navigationState?: CollectionLoadParameters)
+ public async get(target: string, uidPerson:string, navigationState?: CollectionLoadParameters)
: Promise> {
const targetObject = this.targetMap.get(target);
@@ -64,7 +64,7 @@ export class IdentityRoleMembershipsService {
}
const builder = new TypedEntityBuilder(targetObject.type);
- const data = await targetObject.get(navigationState);
+ const data = await targetObject.get(uidPerson,navigationState);
return builder.buildReadWriteEntities(data, targetObject.entitySchema);
}
@@ -95,15 +95,12 @@ export class IdentityRoleMembershipsService {
label: '#LDS#Menu Entry Locations',
index: 40,
},
- get: async (parameter: CollectionLoadParameters) => this.qerApiClient.client.portal_person_rolememberships_Locality_get(
- parameter?.uidPerson,
- parameter?.OrderBy,
- parameter?.StartIndex,
- parameter?.PageSize,
- parameter?.filter,
- parameter?.withProperties,
- parameter?.search
- )
+ get: async (uidPerson: string, parameter: CollectionLoadParameters) =>
+ {
+ return this.qerApiClient.client.portal_person_rolememberships_Locality_get(
+ uidPerson,
+ parameter
+ )}
,
withAnalysis: true
});
@@ -116,15 +113,10 @@ export class IdentityRoleMembershipsService {
label: '#LDS#Menu Entry Cost centers',
index: 50,
},
- get: async (parameter: CollectionLoadParameters) => this.qerApiClient.client.portal_person_rolememberships_ProfitCenter_get(
- parameter?.uidPerson,
- parameter?.OrderBy,
- parameter?.StartIndex,
- parameter?.PageSize,
- parameter?.filter,
- parameter?.withProperties,
- parameter?.search
- ),
+ get: async (uidPerson:string, parameter: CollectionLoadParameters) => this.qerApiClient.client.portal_person_rolememberships_ProfitCenter_get(
+ uidPerson,
+ parameter
+ ),
withAnalysis: true
});
@@ -136,14 +128,9 @@ export class IdentityRoleMembershipsService {
label: '#LDS#Menu Entry Departments',
index: 30,
},
- get: async (parameter: CollectionLoadParameters) => this.qerApiClient.client.portal_person_rolememberships_Department_get(
- parameter?.uidPerson,
- parameter?.OrderBy,
- parameter?.StartIndex,
- parameter?.PageSize,
- parameter?.filter,
- parameter?.withProperties,
- parameter?.search
+ get: async (uidPerson: string, parameter: CollectionLoadParameters) => this.qerApiClient.client.portal_person_rolememberships_Department_get(
+ uidPerson,
+ parameter
),
withAnalysis: true
});
@@ -153,18 +140,13 @@ export class IdentityRoleMembershipsService {
type: PortalPersonRolemembershipsAerole,
entitySchema: this.qerApiClient.typedClient.PortalPersonRolemembershipsAerole.GetSchema(),
controlInfo: {
- label: '#LDS#Heading Application Roles',
+ label: '#LDS#Menu Entry Application roles',
index: 60,
},
- get: async (parameter: CollectionLoadParameters) => this.qerApiClient.client.portal_person_rolememberships_AERole_get(
- parameter?.uidPerson,
- parameter?.OrderBy,
- parameter?.StartIndex,
- parameter?.PageSize,
- parameter?.filter,
- parameter?.withProperties,
- parameter?.search
- ),
+ get: async (uidPerson: string, parameter: CollectionLoadParameters) => this.qerApiClient.client.portal_person_rolememberships_AERole_get(
+ uidPerson,
+ parameter
+ ),
withAnalysis: true
});
@@ -176,16 +158,13 @@ export class IdentityRoleMembershipsService {
label: '#LDS#Heading Shops',
index: 90,
},
- get: async (parameter: CollectionLoadParameters) => this.qerApiClient.client.portal_person_rolememberships_ITShopOrg_get(
- parameter?.uidPerson,
- parameter?.OrderBy,
- parameter?.StartIndex,
- parameter?.PageSize,
- undefined,
- parameter?.withProperties,
- parameter?.search,
- 'CU'
- ),
+ get: async (uidPerson: string,parameter: CollectionLoadParameters) => this.qerApiClient.client.portal_person_rolememberships_ITShopOrg_get(
+ uidPerson,
+ {
+ ...parameter,
+ type: 'CU'
+ }
+ ),
withAnalysis: true
});
}
diff --git a/imxweb/projects/qer/src/lib/identities/identity-sidesheet/identity-sidesheet.component.html b/imxweb/projects/qer/src/lib/identities/identity-sidesheet/identity-sidesheet.component.html
index 523e83d80..2a99c5c52 100644
--- a/imxweb/projects/qer/src/lib/identities/identity-sidesheet/identity-sidesheet.component.html
+++ b/imxweb/projects/qer/src/lib/identities/identity-sidesheet/identity-sidesheet.component.html
@@ -19,7 +19,7 @@
-
+
Promise;
GetFilterTree?: (parentKey: string) => Promise;
- hasSearchParameter: boolean;
isMultiValue: boolean;
}
) { }
diff --git a/imxweb/projects/qer/src/lib/itshop-config/request-config-members/request-config-members.component.scss b/imxweb/projects/qer/src/lib/itshop-config/request-config-members/request-config-members.component.scss
index dc6fa796f..a2a17d490 100644
--- a/imxweb/projects/qer/src/lib/itshop-config/request-config-members/request-config-members.component.scss
+++ b/imxweb/projects/qer/src/lib/itshop-config/request-config-members/request-config-members.component.scss
@@ -1,4 +1,4 @@
-@import '~@elemental-ui/core/src/styles/_palette.scss';
+@import '@elemental-ui/core/src/styles/_palette.scss';
.membership-view-toggle {
margin: 32px 32px 0;
diff --git a/imxweb/projects/qer/src/lib/itshop-config/request-config-members/request-config-members.component.spec.ts b/imxweb/projects/qer/src/lib/itshop-config/request-config-members/request-config-members.component.spec.ts
index 76a41289d..e11ffb730 100644
--- a/imxweb/projects/qer/src/lib/itshop-config/request-config-members/request-config-members.component.spec.ts
+++ b/imxweb/projects/qer/src/lib/itshop-config/request-config-members/request-config-members.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -98,7 +98,7 @@ describe('RequestConfigMembersComponent', () => {
const expectedDialogData = {
get: jasmine.anything(),
GetFilterTree: jasmine.anything(),
- hasSearchParameter: true, isMultiValue: true
+ isMultiValue: true
};
beforeEach(() => {
dialogOpenSpy = spyOn(component['matDialog'], 'open').and.callFake(() => RequestsConfigurationCommonMocks.mockDialogRef);
diff --git a/imxweb/projects/qer/src/lib/itshop-config/request-config-members/request-config-members.component.ts b/imxweb/projects/qer/src/lib/itshop-config/request-config-members/request-config-members.component.ts
index 3ded4cec2..cab809aa1 100644
--- a/imxweb/projects/qer/src/lib/itshop-config/request-config-members/request-config-members.component.ts
+++ b/imxweb/projects/qer/src/lib/itshop-config/request-config-members/request-config-members.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -201,7 +201,6 @@ export class RequestConfigMembersComponent implements OnInit {
data: {
get: parameters => fk.load(entity, parameters),
GetFilterTree: parentkey => fk.getFilterTree(entity, parentkey),
- hasSearchParameter: true,
isMultiValue: true
}
});
diff --git a/imxweb/projects/qer/src/lib/itshop-config/request-config-sidesheet-common.scss b/imxweb/projects/qer/src/lib/itshop-config/request-config-sidesheet-common.scss
index ada47a8ca..112a493b2 100644
--- a/imxweb/projects/qer/src/lib/itshop-config/request-config-sidesheet-common.scss
+++ b/imxweb/projects/qer/src/lib/itshop-config/request-config-sidesheet-common.scss
@@ -1,4 +1,4 @@
-@import '~@elemental-ui/core/src/styles/_palette.scss';
+@import '@elemental-ui/core/src/styles/_palette.scss';
.request-config-sidesheet {
background-color: $asher-gray;
diff --git a/imxweb/projects/qer/src/lib/itshop-config/request-config-sidesheet/request-config-sidesheet.component.spec.ts b/imxweb/projects/qer/src/lib/itshop-config/request-config-sidesheet/request-config-sidesheet.component.spec.ts
index b50a4f13f..bfe5edd70 100644
--- a/imxweb/projects/qer/src/lib/itshop-config/request-config-sidesheet/request-config-sidesheet.component.spec.ts
+++ b/imxweb/projects/qer/src/lib/itshop-config/request-config-sidesheet/request-config-sidesheet.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/itshop-config/request-config-sidesheet/request-config-sidesheet.component.ts b/imxweb/projects/qer/src/lib/itshop-config/request-config-sidesheet/request-config-sidesheet.component.ts
index d9431d269..b48144439 100644
--- a/imxweb/projects/qer/src/lib/itshop-config/request-config-sidesheet/request-config-sidesheet.component.ts
+++ b/imxweb/projects/qer/src/lib/itshop-config/request-config-sidesheet/request-config-sidesheet.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/itshop-config/request-config.module.ts b/imxweb/projects/qer/src/lib/itshop-config/request-config.module.ts
index 174608ec8..a492940e9 100644
--- a/imxweb/projects/qer/src/lib/itshop-config/request-config.module.ts
+++ b/imxweb/projects/qer/src/lib/itshop-config/request-config.module.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -53,6 +53,7 @@ import { DynamicExclusionDialogModule } from '../dynamic-exclusion-dialog/dynami
import { MemberSelectorComponent } from './request-config-members/member-selector.component';
import { ShopAdminGuardService } from '../guards/shop-admin-guard.service';
import { isShopAdmin } from '../admin/qer-permissions-helper';
+import { CREATE_SHELF_TOKEN } from './request-shelves/request-shelf-token';
const routes: Routes = [
@@ -90,6 +91,7 @@ const routes: Routes = [
FkAdvancedPickerModule,
RouterModule.forChild(routes),
],
+ providers: [{provide: CREATE_SHELF_TOKEN, useValue: RequestShelvesComponent}],
schemas: [CUSTOM_ELEMENTS_SCHEMA],
})
export class RequestConfigModule {
diff --git a/imxweb/projects/qer/src/lib/itshop-config/request-shelf-entitlements/request-shelf-entitlements.component.spec.ts b/imxweb/projects/qer/src/lib/itshop-config/request-shelf-entitlements/request-shelf-entitlements.component.spec.ts
index 8818f58d5..580bebd8c 100644
--- a/imxweb/projects/qer/src/lib/itshop-config/request-shelf-entitlements/request-shelf-entitlements.component.spec.ts
+++ b/imxweb/projects/qer/src/lib/itshop-config/request-shelf-entitlements/request-shelf-entitlements.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/itshop-config/request-shelf-entitlements/request-shelf-entitlements.component.ts b/imxweb/projects/qer/src/lib/itshop-config/request-shelf-entitlements/request-shelf-entitlements.component.ts
index ebdd6c068..57f1f6971 100644
--- a/imxweb/projects/qer/src/lib/itshop-config/request-shelf-entitlements/request-shelf-entitlements.component.ts
+++ b/imxweb/projects/qer/src/lib/itshop-config/request-shelf-entitlements/request-shelf-entitlements.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/itshop-config/request-shelf-sidesheet/request-shelf-sidesheet.component.spec.ts b/imxweb/projects/qer/src/lib/itshop-config/request-shelf-sidesheet/request-shelf-sidesheet.component.spec.ts
index a8e10151a..81e2239e0 100644
--- a/imxweb/projects/qer/src/lib/itshop-config/request-shelf-sidesheet/request-shelf-sidesheet.component.spec.ts
+++ b/imxweb/projects/qer/src/lib/itshop-config/request-shelf-sidesheet/request-shelf-sidesheet.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/itshop-config/request-shelf-sidesheet/request-shelf-sidesheet.component.ts b/imxweb/projects/qer/src/lib/itshop-config/request-shelf-sidesheet/request-shelf-sidesheet.component.ts
index 66e295fef..29b051010 100644
--- a/imxweb/projects/qer/src/lib/itshop-config/request-shelf-sidesheet/request-shelf-sidesheet.component.ts
+++ b/imxweb/projects/qer/src/lib/itshop-config/request-shelf-sidesheet/request-shelf-sidesheet.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/itshop-config/request-shelves/request-shelf-token.ts b/imxweb/projects/qer/src/lib/itshop-config/request-shelves/request-shelf-token.ts
new file mode 100644
index 000000000..b71588c26
--- /dev/null
+++ b/imxweb/projects/qer/src/lib/itshop-config/request-shelves/request-shelf-token.ts
@@ -0,0 +1,30 @@
+/*
+ * ONE IDENTITY LLC. PROPRIETARY INFORMATION
+ *
+ * This software is confidential. One Identity, LLC. or one of its affiliates or
+ * subsidiaries, has supplied this software to you under terms of a
+ * license agreement, nondisclosure agreement or both.
+ *
+ * You may not copy, disclose, or use this software except in accordance with
+ * those terms.
+ *
+ *
+ * Copyright 2022 One Identity LLC.
+ * ALL RIGHTS RESERVED.
+ *
+ * ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
+ * WARRANTIES ABOUT THE SUITABILITY OF THE SOFTWARE,
+ * EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
+ * TO THE IMPLIED WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE, OR
+ * NON-INFRINGEMENT. ONE IDENTITY LLC. SHALL NOT BE
+ * LIABLE FOR ANY DAMAGES SUFFERED BY LICENSEE
+ * AS A RESULT OF USING, MODIFYING OR DISTRIBUTING
+ * THIS SOFTWARE OR ITS DERIVATIVES.
+ *
+ */
+
+import { ComponentType } from "@angular/cdk/portal";
+import { InjectionToken } from "@angular/core";
+
+export const CREATE_SHELF_TOKEN: InjectionToken> = new InjectionToken>('CREATE_SHELF_TOKEN');
diff --git a/imxweb/projects/qer/src/lib/itshop-config/request-shelves/request-shelves.component.spec.ts b/imxweb/projects/qer/src/lib/itshop-config/request-shelves/request-shelves.component.spec.ts
index c516a5add..db307d873 100644
--- a/imxweb/projects/qer/src/lib/itshop-config/request-shelves/request-shelves.component.spec.ts
+++ b/imxweb/projects/qer/src/lib/itshop-config/request-shelves/request-shelves.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -31,6 +31,7 @@ import { RequestShelvesComponent } from './request-shelves.component';
import { RequestsConfigurationTestBed } from '../test/requests-configuration-test-bed';
import { RequestsConfigurationCommonMocks } from '../test/requests-configuration-mocks';
import { HELPER_ALERT_KEY_PREFIX, StorageService } from 'qbm';
+import { CREATE_SHELF_TOKEN } from './request-shelf-token';
describe('RequestShelvesComponent', () => {
let component: RequestShelvesComponent;
@@ -41,6 +42,10 @@ describe('RequestShelvesComponent', () => {
RequestsConfigurationTestBed.configureTestingModule({
declarations: [ RequestShelvesComponent ],
providers: [
+ {
+ provide: CREATE_SHELF_TOKEN,
+ useValue: {}
+ },
{
provide: RequestsService,
useValue: RequestsConfigurationCommonMocks.mockRequestsService
diff --git a/imxweb/projects/qer/src/lib/itshop-config/request-shelves/request-shelves.component.ts b/imxweb/projects/qer/src/lib/itshop-config/request-shelves/request-shelves.component.ts
index e214ccf83..b62a297c8 100644
--- a/imxweb/projects/qer/src/lib/itshop-config/request-shelves/request-shelves.component.ts
+++ b/imxweb/projects/qer/src/lib/itshop-config/request-shelves/request-shelves.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -24,14 +24,15 @@
*
*/
-import { Component, EventEmitter, Input, OnInit, Output } from '@angular/core';
+import { ComponentType } from '@angular/cdk/portal';
+import { Component, EventEmitter, Inject, Input, OnInit, Output } from '@angular/core';
import { EuiSidesheetService } from '@elemental-ui/core';
import { TranslateService } from '@ngx-translate/core';
import { PortalShopConfigStructure } from 'imx-api-qer';
import { CollectionLoadParameters, IClientProperty, DisplayColumns, EntitySchema } from 'imx-qbm-dbts';
import { DataSourceToolbarSettings, DataSourceToolbarFilter, ClassloggerService, StorageService, HELPER_ALERT_KEY_PREFIX, SettingsService } from 'qbm';
-import { RequestShelfSidesheetComponent } from '../request-shelf-sidesheet/request-shelf-sidesheet.component';
import { RequestsService } from '../requests.service';
+import { CREATE_SHELF_TOKEN } from './request-shelf-token';
const helperAlertKey = `${HELPER_ALERT_KEY_PREFIX}_requestShopShelves`;
@@ -54,6 +55,7 @@ export class RequestShelvesComponent implements OnInit {
private displayedColumns: IClientProperty[] = [];
constructor(
+ @Inject(CREATE_SHELF_TOKEN) private shelfComponent: ComponentType,
private readonly sideSheet: EuiSidesheetService,
private readonly logger: ClassloggerService,
private readonly translate: TranslateService,
@@ -115,7 +117,8 @@ export class RequestShelvesComponent implements OnInit {
private async viewRequestShelf(requestConfig: PortalShopConfigStructure, isNew: boolean = false): Promise {
const header = await this.translate.get(isNew ? '#LDS#Heading Create Shelf' : '#LDS#Heading Edit Shelf').toPromise();
- const sidesheetRef = this.sideSheet.open(RequestShelfSidesheetComponent, {
+
+ const sidesheetRef = this.sideSheet.open(this.shelfComponent, {
title: header,
headerColour: 'iris-tint',
padding: '0px',
diff --git a/imxweb/projects/qer/src/lib/itshop-config/requestable-entitlement-type.service.ts b/imxweb/projects/qer/src/lib/itshop-config/requestable-entitlement-type.service.ts
index 4d8003533..d043feea6 100644
--- a/imxweb/projects/qer/src/lib/itshop-config/requestable-entitlement-type.service.ts
+++ b/imxweb/projects/qer/src/lib/itshop-config/requestable-entitlement-type.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/itshop-config/requestable-entl-type.ts b/imxweb/projects/qer/src/lib/itshop-config/requestable-entl-type.ts
index 5eb97fbd3..88f42d1b7 100644
--- a/imxweb/projects/qer/src/lib/itshop-config/requestable-entl-type.ts
+++ b/imxweb/projects/qer/src/lib/itshop-config/requestable-entl-type.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/itshop-config/requests-selector/requests-entity-selector.component.spec.ts b/imxweb/projects/qer/src/lib/itshop-config/requests-selector/requests-entity-selector.component.spec.ts
index 8587789e4..4968e3de0 100644
--- a/imxweb/projects/qer/src/lib/itshop-config/requests-selector/requests-entity-selector.component.spec.ts
+++ b/imxweb/projects/qer/src/lib/itshop-config/requests-selector/requests-entity-selector.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -70,7 +70,6 @@ describe('RequestsEntitySelectorComponent', () => {
provide: MAT_DIALOG_DATA,
useValue: {
get: (params) => Promise.resolve([]),
- hasSearchParameter: true,
isMultiValue: true
},
},
diff --git a/imxweb/projects/qer/src/lib/itshop-config/requests-selector/requests-entity-selector.component.ts b/imxweb/projects/qer/src/lib/itshop-config/requests-selector/requests-entity-selector.component.ts
index 9a67b2ee3..68a0fb15a 100644
--- a/imxweb/projects/qer/src/lib/itshop-config/requests-selector/requests-entity-selector.component.ts
+++ b/imxweb/projects/qer/src/lib/itshop-config/requests-selector/requests-entity-selector.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -98,7 +98,6 @@ export class RequestsEntitySelectorComponent {
}
return this.fk.getFilterTree(this.fkEntity, parentKey);
},
- hasSearchParameter: true,
isMultiValue: true
};
}
diff --git a/imxweb/projects/qer/src/lib/itshop-config/requests.service.ts b/imxweb/projects/qer/src/lib/itshop-config/requests.service.ts
index 22b5af8ae..7d020ed0b 100644
--- a/imxweb/projects/qer/src/lib/itshop-config/requests.service.ts
+++ b/imxweb/projects/qer/src/lib/itshop-config/requests.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/itshop-config/requests/requests.component.scss b/imxweb/projects/qer/src/lib/itshop-config/requests/requests.component.scss
index 0c316ac53..16932e2f1 100644
--- a/imxweb/projects/qer/src/lib/itshop-config/requests/requests.component.scss
+++ b/imxweb/projects/qer/src/lib/itshop-config/requests/requests.component.scss
@@ -1,4 +1,4 @@
-@import '~@elemental-ui/core/src/styles/_palette.scss';
+@import '@elemental-ui/core/src/styles/_palette.scss';
:host {
display: flex;
@@ -21,7 +21,7 @@
flex-grow: 1;
overflow: auto;
}
- }
+ }
> div {
display: flex;
diff --git a/imxweb/projects/qer/src/lib/itshop-config/requests/requests.component.spec.ts b/imxweb/projects/qer/src/lib/itshop-config/requests/requests.component.spec.ts
index 7cec94689..085e35c5b 100644
--- a/imxweb/projects/qer/src/lib/itshop-config/requests/requests.component.spec.ts
+++ b/imxweb/projects/qer/src/lib/itshop-config/requests/requests.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/itshop-config/requests/requests.component.ts b/imxweb/projects/qer/src/lib/itshop-config/requests/requests.component.ts
index c8cd67ada..dc5b447f9 100644
--- a/imxweb/projects/qer/src/lib/itshop-config/requests/requests.component.ts
+++ b/imxweb/projects/qer/src/lib/itshop-config/requests/requests.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/itshop-config/resource-entitlement-type.ts b/imxweb/projects/qer/src/lib/itshop-config/resource-entitlement-type.ts
index 40b08d3b3..c26c46b11 100644
--- a/imxweb/projects/qer/src/lib/itshop-config/resource-entitlement-type.ts
+++ b/imxweb/projects/qer/src/lib/itshop-config/resource-entitlement-type.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/itshop-config/test/requests-configuration-mocks.ts b/imxweb/projects/qer/src/lib/itshop-config/test/requests-configuration-mocks.ts
index 13a3ee4ca..27c3d33e0 100644
--- a/imxweb/projects/qer/src/lib/itshop-config/test/requests-configuration-mocks.ts
+++ b/imxweb/projects/qer/src/lib/itshop-config/test/requests-configuration-mocks.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/itshop-config/test/requests-configuration-test-bed.ts b/imxweb/projects/qer/src/lib/itshop-config/test/requests-configuration-test-bed.ts
index c360b10cb..16d53100a 100644
--- a/imxweb/projects/qer/src/lib/itshop-config/test/requests-configuration-test-bed.ts
+++ b/imxweb/projects/qer/src/lib/itshop-config/test/requests-configuration-test-bed.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/itshop-pattern/duplicate-pattern-items/duplicate-pattern-item.ts b/imxweb/projects/qer/src/lib/itshop-pattern/duplicate-pattern-items/duplicate-pattern-item.ts
new file mode 100644
index 000000000..261ce99d6
--- /dev/null
+++ b/imxweb/projects/qer/src/lib/itshop-pattern/duplicate-pattern-items/duplicate-pattern-item.ts
@@ -0,0 +1,51 @@
+/*
+ * ONE IDENTITY LLC. PROPRIETARY INFORMATION
+ *
+ * This software is confidential. One Identity, LLC. or one of its affiliates or
+ * subsidiaries, has supplied this software to you under terms of a
+ * license agreement, nondisclosure agreement or both.
+ *
+ * You may not copy, disclose, or use this software except in accordance with
+ * those terms.
+ *
+ *
+ * Copyright 2022 One Identity LLC.
+ * ALL RIGHTS RESERVED.
+ *
+ * ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
+ * WARRANTIES ABOUT THE SUITABILITY OF THE SOFTWARE,
+ * EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
+ * TO THE IMPLIED WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE, OR
+ * NON-INFRINGEMENT. ONE IDENTITY LLC. SHALL NOT BE
+ * LIABLE FOR ANY DAMAGES SUFFERED BY LICENSEE
+ * AS A RESULT OF USING, MODIFYING OR DISTRIBUTING
+ * THIS SOFTWARE OR ITS DERIVATIVES.
+ *
+ */
+
+import { ExceptionData, RequestableProductForPerson } from 'imx-api-qer';
+
+/**
+ * Class representing the service items that could not be added to the itshop pattern.
+ */
+export class DuplicatePatternItem implements RequestableProductForPerson {
+
+ // tslint:disable-next-line: variable-name
+ public readonly UidITShopOrg: string;
+
+ // tslint:disable-next-line: variable-name
+ public readonly Display: string;
+
+ // tslint:disable-next-line: variable-name
+ public readonly DisplayRecipient: string;
+
+ public readonly error: string;
+
+ constructor(product: RequestableProductForPerson, public readonly errorMessage: ExceptionData) {
+ this.UidITShopOrg = product.UidITShopOrg;
+ this.Display = product.Display;
+ this.DisplayRecipient = product.DisplayRecipient;
+ this.error = errorMessage.Message;
+ }
+}
diff --git a/imxweb/projects/qer/src/lib/itshop-pattern/duplicate-pattern-items/duplicate-pattern-items.component.html b/imxweb/projects/qer/src/lib/itshop-pattern/duplicate-pattern-items/duplicate-pattern-items.component.html
new file mode 100644
index 000000000..432dacd5d
--- /dev/null
+++ b/imxweb/projects/qer/src/lib/itshop-pattern/duplicate-pattern-items/duplicate-pattern-items.component.html
@@ -0,0 +1,28 @@
+
+ {{'#LDS#Heading Products Cannot Be Added To The Request Template' | translate}}
+
+
+
+ {{ description1 | translate}}
+
+
+ {{ description2 | translate}}
+
+
+
+
+ {{ column.title | translate }}
+
+
+ {{ row[column.name] }}
+
+
+
+
+
+
+
+
+ {{'#LDS#Close' | translate}}
+
+
diff --git a/imxweb/projects/qer/src/lib/itshop-pattern/duplicate-pattern-items/duplicate-pattern-items.component.scss b/imxweb/projects/qer/src/lib/itshop-pattern/duplicate-pattern-items/duplicate-pattern-items.component.scss
new file mode 100644
index 000000000..542a60e72
--- /dev/null
+++ b/imxweb/projects/qer/src/lib/itshop-pattern/duplicate-pattern-items/duplicate-pattern-items.component.scss
@@ -0,0 +1,9 @@
+.mat-dialog-content{
+ overflow: hidden;
+ display: flex;
+ flex-direction: column;
+
+ .mat-table {
+ margin-top: 20px;
+ }
+}
diff --git a/imxweb/projects/qer/src/lib/itshop-pattern/duplicate-pattern-items/duplicate-pattern-items.component.ts b/imxweb/projects/qer/src/lib/itshop-pattern/duplicate-pattern-items/duplicate-pattern-items.component.ts
new file mode 100644
index 000000000..820c9b66f
--- /dev/null
+++ b/imxweb/projects/qer/src/lib/itshop-pattern/duplicate-pattern-items/duplicate-pattern-items.component.ts
@@ -0,0 +1,59 @@
+/*
+ * ONE IDENTITY LLC. PROPRIETARY INFORMATION
+ *
+ * This software is confidential. One Identity, LLC. or one of its affiliates or
+ * subsidiaries, has supplied this software to you under terms of a
+ * license agreement, nondisclosure agreement or both.
+ *
+ * You may not copy, disclose, or use this software except in accordance with
+ * those terms.
+ *
+ *
+ * Copyright 2022 One Identity LLC.
+ * ALL RIGHTS RESERVED.
+ *
+ * ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
+ * WARRANTIES ABOUT THE SUITABILITY OF THE SOFTWARE,
+ * EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
+ * TO THE IMPLIED WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE, OR
+ * NON-INFRINGEMENT. ONE IDENTITY LLC. SHALL NOT BE
+ * LIABLE FOR ANY DAMAGES SUFFERED BY LICENSEE
+ * AS A RESULT OF USING, MODIFYING OR DISTRIBUTING
+ * THIS SOFTWARE OR ITS DERIVATIVES.
+ *
+ */
+
+import { Component, Inject } from '@angular/core';
+import { MAT_DIALOG_DATA } from '@angular/material/dialog';
+
+import { DuplicatePatternItem } from './duplicate-pattern-item';
+
+/**
+ * This component shows a list of all serviceitems that could not be added to the itshop pattern.
+ */
+@Component({
+ selector: 'imx-duplicate-pattern-items',
+ templateUrl: './duplicate-pattern-items.component.html',
+ styleUrls: ['./duplicate-pattern-items.component.scss']
+})
+export class DuplicatePatternItemsComponent {
+
+ public get columnNames(): string[] {
+ return this.displayedColumns.map(c => c.name);
+ }
+
+ public description1 = '#LDS#Each product can be added to the request template only once.';
+ public description2 = '#LDS#The following products are already included and cannot be added again.';
+
+ public readonly displayedColumns = [
+ { name: 'Display', title: '#LDS#Product' }
+ ];
+
+ constructor(
+ @Inject(MAT_DIALOG_DATA) public readonly data: {
+ duplicatePatternItems: DuplicatePatternItem[]
+ }
+ ) {
+ }
+}
diff --git a/imxweb/projects/qer/src/lib/itshop-pattern/itshop-pattern-add-products/itshop-pattern-add-products.component.html b/imxweb/projects/qer/src/lib/itshop-pattern/itshop-pattern-add-products/itshop-pattern-add-products.component.html
new file mode 100644
index 000000000..0f50d7757
--- /dev/null
+++ b/imxweb/projects/qer/src/lib/itshop-pattern/itshop-pattern-add-products/itshop-pattern-add-products.component.html
@@ -0,0 +1,31 @@
+
diff --git a/imxweb/projects/qer/src/lib/itshop-pattern/itshop-pattern.component.scss b/imxweb/projects/qer/src/lib/itshop-pattern/itshop-pattern.component.scss
index 3ffe4d584..1447e0b72 100644
--- a/imxweb/projects/qer/src/lib/itshop-pattern/itshop-pattern.component.scss
+++ b/imxweb/projects/qer/src/lib/itshop-pattern/itshop-pattern.component.scss
@@ -32,7 +32,6 @@
@include imx-flex-column-container();
overflow: hidden;
height: inherit;
- width: 1200px;
max-width: 100%;
}
diff --git a/imxweb/projects/qer/src/lib/itshop-pattern/itshop-pattern.component.spec.ts b/imxweb/projects/qer/src/lib/itshop-pattern/itshop-pattern.component.spec.ts
index 353d92df9..3aa13a410 100644
--- a/imxweb/projects/qer/src/lib/itshop-pattern/itshop-pattern.component.spec.ts
+++ b/imxweb/projects/qer/src/lib/itshop-pattern/itshop-pattern.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -74,7 +74,7 @@ describe('ItshopPatternComponent', () => {
isShopAdmin: jasmine.createSpy('isShopAdmin').and.callFake(() => isShopAdmin)
};
- let routeConfigPath = 'configuration/carttemplates';
+ let routeConfigPath = 'itshop/requesttemplates';
const activatedRouteStub = {
snapshot: {
routeConfig: { path: routeConfigPath }
@@ -151,8 +151,7 @@ describe('ItshopPatternComponent', () => {
}
}
]
- })
- .compileComponents();
+ });
});
beforeEach(waitForAsync(() => {
@@ -178,34 +177,6 @@ describe('ItshopPatternComponent', () => {
expect(component).toBeTruthy();
});
- for (const testcase of [
- { adminMode: true, description: 'admin-mode' },
- { adminMode: false, description: 'normaö-user-mode' },
- ]) {
- xit(`should run the component in ${testcase.description}`, async () => {
- patterServiceStub.getPrivatePatterns.calls.reset();
- patterServiceStub.getPublicPatterns.calls.reset();
- const state = { OrderBy: 'Ident_ShoppingCartPattern asc' };
- if (testcase.adminMode) {
- routeConfigPath = 'configuration/carttemplates';
- isShopAdmin = true;
- } else {
- routeConfigPath = 'something else';
- isShopAdmin = false;
- }
-
- await component.ngOnInit();
-
- if (testcase.adminMode) {
- expect(patterServiceStub.getPublicPatterns).toHaveBeenCalledWith(state);
- expect(patterServiceStub.getPrivatePatterns).not.toHaveBeenCalled();
- } else {
- expect(patterServiceStub.getPrivatePatterns).toHaveBeenCalledWith(state);
- expect(patterServiceStub.getPublicPatterns).not.toHaveBeenCalled();
- }
- });
- }
-
it('should open the details sidesheet', async () => {
await component.viewDetails(selectedPattern);
diff --git a/imxweb/projects/qer/src/lib/itshop-pattern/itshop-pattern.component.ts b/imxweb/projects/qer/src/lib/itshop-pattern/itshop-pattern.component.ts
index 5475c8d20..ec7245867 100644
--- a/imxweb/projects/qer/src/lib/itshop-pattern/itshop-pattern.component.ts
+++ b/imxweb/projects/qer/src/lib/itshop-pattern/itshop-pattern.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -25,7 +25,6 @@
*/
import { Component, OnDestroy, OnInit, ViewChild } from '@angular/core';
-import { ActivatedRoute } from '@angular/router';
import { EuiSidesheetService } from '@elemental-ui/core';
import { TranslateService } from '@ngx-translate/core';
import { Subscription } from 'rxjs';
@@ -48,6 +47,10 @@ import { ItshopPatternService } from './itshop-pattern.service';
import { ItshopPatternCreateService } from './itshop-pattern-create-sidesheet/itshop-pattern-create.service';
import { ItShopPatternChangedType } from './itshop-pattern-changed.enum';
+/**
+ * Component that shows all list of all itshop pattern of the current user
+ * or all itshop pattern of all other users, if the user is a shop admin.
+ */
@Component({
selector: 'imx-itshop-pattern',
templateUrl: './itshop-pattern.component.html',
@@ -76,7 +79,6 @@ export class ItshopPatternComponent implements OnInit, OnDestroy {
private readonly patternService: ItshopPatternService,
private readonly patternCreateService: ItshopPatternCreateService,
private readonly qerPermissionService: QerPermissionsService,
- private readonly activatedRoute: ActivatedRoute,
private readonly sidesheet: EuiSidesheetService,
private readonly snackBar: SnackBarService,
private readonly translate: TranslateService,
@@ -95,8 +97,7 @@ export class ItshopPatternComponent implements OnInit, OnDestroy {
this.patternService.handleOpenLoader();
try {
- const route = this.activatedRoute.snapshot.routeConfig.path;
- this.adminMode = await this.qerPermissionService.isShopAdmin() && route === 'configuration/carttemplates';
+ this.adminMode = await this.qerPermissionService.isShopAdmin();
this.infoText = this.adminMode ? this.infoTextAdmin : this.infoTextUser;
@@ -113,7 +114,8 @@ export class ItshopPatternComponent implements OnInit, OnDestroy {
entitySchema.Columns.IsPublicPattern,
{
ColumnName: 'actions',
- Type: ValType.String
+ Type: ValType.String,
+ afterAdditionals: true
}
],
entitySchema,
@@ -217,7 +219,8 @@ export class ItshopPatternComponent implements OnInit, OnDestroy {
testId: 'pattern-details-sidesheet',
data: {
pattern,
- isMyPattern
+ isMyPattern,
+ adminMode: this.adminMode
}
}).afterClosed().toPromise();
diff --git a/imxweb/projects/qer/src/lib/itshop-pattern/itshop-pattern.module.ts b/imxweb/projects/qer/src/lib/itshop-pattern/itshop-pattern.module.ts
index a4b14b832..b26b98c06 100644
--- a/imxweb/projects/qer/src/lib/itshop-pattern/itshop-pattern.module.ts
+++ b/imxweb/projects/qer/src/lib/itshop-pattern/itshop-pattern.module.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -31,6 +31,9 @@ import { RouterModule, Routes } from '@angular/router';
import { EuiCoreModule, EuiMaterialModule } from '@elemental-ui/core';
import { TranslateModule } from '@ngx-translate/core';
+import { ProjectConfig } from 'imx-api-qbm';
+import { QerProjectConfig } from 'imx-api-qer';
+
import {
CdrModule,
ClassloggerService,
@@ -38,37 +41,34 @@ import {
DataTableModule,
MenuItem,
MenuService,
- RouteGuardService
+ RouteGuardService,
+ UserMessageModule
} from 'qbm';
import { ItshopPatternComponent } from './itshop-pattern.component';
import { ItshopPatternSidesheetComponent } from './itshop-pattern-sidesheet/itshop-pattern-sidesheet.component';
-
-import { ShopAdminGuardService } from '../guards/shop-admin-guard.service';
-import { isShopAdmin } from '../admin/qer-permissions-helper';
import { ItshopPatternCreateSidesheetComponent } from './itshop-pattern-create-sidesheet/itshop-pattern-create-sidesheet.component';
+import { ItshopPatternAddProductsComponent } from './itshop-pattern-add-products/itshop-pattern-add-products.component';
+import { ServiceItemsModule } from '../service-items/service-items.module';
+import { DuplicatePatternItemsComponent } from './duplicate-pattern-items/duplicate-pattern-items.component';
+import { UserModule } from '../user/user.module';
+import { ItshopPatternGuardService } from '../guards/itshop-pattern-guard.service';
const routes: Routes = [
{
- path: 'configuration/carttemplates',
+ path: 'itshop/requesttemplates',
component: ItshopPatternComponent,
- canActivate: [RouteGuardService, ShopAdminGuardService],
- resolve: [RouteGuardService]
- },
- {
- path: 'itshop/myrequesttemplates',
- component: ItshopPatternComponent,
- canActivate: [RouteGuardService],
+ canActivate: [RouteGuardService, ItshopPatternGuardService],
resolve: [RouteGuardService]
}
];
-
-
@NgModule({
declarations: [
ItshopPatternComponent,
ItshopPatternSidesheetComponent,
- ItshopPatternCreateSidesheetComponent
+ ItshopPatternCreateSidesheetComponent,
+ ItshopPatternAddProductsComponent,
+ DuplicatePatternItemsComponent
],
imports: [
CdrModule,
@@ -79,8 +79,11 @@ const routes: Routes = [
EuiMaterialModule,
FormsModule,
ReactiveFormsModule,
+ ServiceItemsModule,
TranslateModule,
RouterModule.forChild(routes),
+ UserMessageModule,
+ UserModule
]
})
export class ItshopPatternModule {
@@ -95,17 +98,18 @@ export class ItshopPatternModule {
private setupMenu(): void {
this.menuService.addMenuFactories(
- (preProps: string[], groups: string[]) => {
+ (preProps: string[], groups: string[], projectConfig: QerProjectConfig & ProjectConfig) => {
const items: MenuItem[] = [];
+ const requestTemplatesEnabled = projectConfig.ITShopConfig.VI_ITShop_ProductSelectionFromTemplate;
- if (preProps.includes('ITSHOP')) {
+ if (preProps.includes('ITSHOP') && requestTemplatesEnabled) {
items.push(
{
- id: 'QER_Request_MyRequestTemplates',
+ id: 'QER_Request_RequestTemplates',
navigationCommands: {
- commands: ['itshop', 'myrequesttemplates']
+ commands: ['itshop', 'requesttemplates']
},
- title: '#LDS#Menu Entry My request templates',
+ title: '#LDS#Menu Entry Request templates',
sorting: '10-50',
}
);
@@ -120,36 +124,7 @@ export class ItshopPatternModule {
sorting: '10',
items
};
- },
- (preProps: string[], groups: string[]) => {
- const items: MenuItem[] = [];
-
- if (preProps.includes('ITSHOP') && isShopAdmin(groups)) {
- items.push(
- {
- id: 'QER_Setup_Patterns',
- navigationCommands: {
- commands: ['configuration', 'carttemplates']
- },
- title: '#LDS#Menu Entry Request templates',
- sorting: '50-50',
- },
- );
- }
-
- if (items.length === 0) {
- return null;
- }
- return {
- id: 'ROOT_Setup',
- title: '#LDS#Setup',
- sorting: '50',
- items
- };
- },
+ }
);
}
-
-
-
}
diff --git a/imxweb/projects/qer/src/lib/itshop-pattern/itshop-pattern.service.spec.ts b/imxweb/projects/qer/src/lib/itshop-pattern/itshop-pattern.service.spec.ts
index 027f17951..6b273863e 100644
--- a/imxweb/projects/qer/src/lib/itshop-pattern/itshop-pattern.service.spec.ts
+++ b/imxweb/projects/qer/src/lib/itshop-pattern/itshop-pattern.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/itshop-pattern/itshop-pattern.service.ts b/imxweb/projects/qer/src/lib/itshop-pattern/itshop-pattern.service.ts
index 5aa1a509e..254fb0748 100644
--- a/imxweb/projects/qer/src/lib/itshop-pattern/itshop-pattern.service.ts
+++ b/imxweb/projects/qer/src/lib/itshop-pattern/itshop-pattern.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/itshop/decision-history.service.spec.ts b/imxweb/projects/qer/src/lib/itshop/decision-history.service.spec.ts
index 9ac6decf4..ae85f0e70 100644
--- a/imxweb/projects/qer/src/lib/itshop/decision-history.service.spec.ts
+++ b/imxweb/projects/qer/src/lib/itshop/decision-history.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/itshop/decision-history.service.ts b/imxweb/projects/qer/src/lib/itshop/decision-history.service.ts
index bf54e2135..1e2a08439 100644
--- a/imxweb/projects/qer/src/lib/itshop/decision-history.service.ts
+++ b/imxweb/projects/qer/src/lib/itshop/decision-history.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/itshop/image.service.spec.ts b/imxweb/projects/qer/src/lib/itshop/image.service.spec.ts
index 2836a9659..ed3f4256c 100644
--- a/imxweb/projects/qer/src/lib/itshop/image.service.spec.ts
+++ b/imxweb/projects/qer/src/lib/itshop/image.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -26,6 +26,8 @@
import { TestBed } from '@angular/core/testing';
+import { AppConfigService } from 'qbm';
+
import { QerApiService } from '../qer-api-client.service';
import { ImageService } from './image.service';
@@ -38,6 +40,14 @@ describe('ImageService', () => {
{
provide: QerApiService,
useValue: {}
+ },
+ {
+ provide: AppConfigService,
+ useClass: class {
+ public Config = {
+ BaseUrl: ''
+ };
+ }
}
]
});
diff --git a/imxweb/projects/qer/src/lib/itshop/image.service.ts b/imxweb/projects/qer/src/lib/itshop/image.service.ts
index 941295931..d6bffcd88 100644
--- a/imxweb/projects/qer/src/lib/itshop/image.service.ts
+++ b/imxweb/projects/qer/src/lib/itshop/image.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -26,15 +26,44 @@
import { Injectable } from '@angular/core';
-import { ITShopConfig, PortalShopServiceitems } from 'imx-api-qer';
+import { ITShopConfig, PortalShopServiceitems, V2ApiClientMethodFactory } from 'imx-api-qer';
+import { MethodDefinition, MethodDescriptor } from 'imx-qbm-dbts';
+import { AppConfigService } from 'qbm';
import { QerApiService } from '../qer-api-client.service';
@Injectable({
providedIn: 'root'
})
export class ImageService {
- constructor(private readonly api: QerApiService) { }
+ private readonly methodFactory = new V2ApiClientMethodFactory();
+ constructor(
+ private readonly api: QerApiService,
+ private readonly config: AppConfigService,
+ ) { }
+
+ /** Returns the URL to the image for the specified service item. */
+ public getPath(serviceItem: PortalShopServiceitems): string {
+ const tokens = serviceItem.ImageRef.value?.split('/');
+ if (tokens?.length > 1) {
+ let path: MethodDescriptor;
+ if (tokens[0] === 'category') {
+ path = this.methodFactory.portal_shop_categoryimage_get(tokens[1]);
+ } else if (tokens[0] === 'product') {
+ path = this.methodFactory.portal_shop_serviceitemimage_get(tokens[1]);
+ }
+
+ if (path) {
+ // parameterize path
+ return this.config.BaseUrl + new MethodDefinition(path).path;
+ }
+ }
+ return null;
+ }
+
+ /**
+ * @deprecated Use getPath()
+ */
public async get(serviceItem: PortalShopServiceitems, config: ITShopConfig): Promise {
const tokens = serviceItem.ImageRef.value?.split('/');
if (tokens?.length > 1) {
diff --git a/imxweb/projects/qer/src/lib/itshop/itshop-request.service.spec.ts b/imxweb/projects/qer/src/lib/itshop/itshop-request.service.spec.ts
index dffc4bf5d..b0dd028d3 100644
--- a/imxweb/projects/qer/src/lib/itshop/itshop-request.service.spec.ts
+++ b/imxweb/projects/qer/src/lib/itshop/itshop-request.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/itshop/itshop-request.service.ts b/imxweb/projects/qer/src/lib/itshop/itshop-request.service.ts
index 756cb6df1..9d9f33f61 100644
--- a/imxweb/projects/qer/src/lib/itshop/itshop-request.service.ts
+++ b/imxweb/projects/qer/src/lib/itshop/itshop-request.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/itshop/itshop.module.ts b/imxweb/projects/qer/src/lib/itshop/itshop.module.ts
index 8ae5b5803..a2e481eb6 100644
--- a/imxweb/projects/qer/src/lib/itshop/itshop.module.ts
+++ b/imxweb/projects/qer/src/lib/itshop/itshop.module.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -33,7 +33,7 @@ import { MatListModule } from '@angular/material/list';
import { FormsModule, ReactiveFormsModule } from '@angular/forms';
import { ShelfSelectionComponent } from './shelf-selection.component';
-import { CdrModule, ExtModule, LdsReplaceModule } from 'qbm';
+import { CdrModule, DataSourceToolbarModule, DataTableModule, DateModule, ExtModule, LdsReplaceModule } from 'qbm';
import { ItshopService } from './itshop.service';
import { DecisionHistoryComponent } from './request-info/decision-history.component';
import { RequestInfoComponent } from './request-info/request-info.component';
@@ -41,18 +41,23 @@ import { EuiCoreModule, EuiMaterialModule } from '@elemental-ui/core';
import { NonRequestableItemsComponent } from './non-requestable-items/non-requestable-items.component';
import { PeerGroupComponent } from './peer-group/peer-group.component';
import { ShelfService } from './shelf.service';
-
+import { ServiceItemDetailComponent } from './request-info/service-item-detail/service-item-detail.component';
+import { ProductEntitlementsComponent } from './request-info/service-item-detail/product-entitlements/product-entitlements.component';
@NgModule({
declarations: [
DecisionHistoryComponent,
RequestInfoComponent,
ShelfSelectionComponent,
NonRequestableItemsComponent,
- PeerGroupComponent
+ PeerGroupComponent,
+ ServiceItemDetailComponent,
+ ProductEntitlementsComponent
],
exports: [
RequestInfoComponent,
- PeerGroupComponent
+ PeerGroupComponent,
+ ServiceItemDetailComponent,
+ ProductEntitlementsComponent
],
imports: [
CdrModule,
@@ -66,11 +71,14 @@ import { ShelfService } from './shelf.service';
EuiMaterialModule,
FormsModule,
ReactiveFormsModule,
- ExtModule
+ ExtModule,
+ DateModule,
+ DataTableModule,
+ DataSourceToolbarModule
],
providers: [
ItshopService,
ShelfService
- ]
+ ],
})
export class ItshopModule { }
diff --git a/imxweb/projects/qer/src/lib/itshop/itshop.service.spec.ts b/imxweb/projects/qer/src/lib/itshop/itshop.service.spec.ts
index 407dfb3f5..a087ec2b8 100644
--- a/imxweb/projects/qer/src/lib/itshop/itshop.service.spec.ts
+++ b/imxweb/projects/qer/src/lib/itshop/itshop.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/itshop/itshop.service.ts b/imxweb/projects/qer/src/lib/itshop/itshop.service.ts
index 538220003..4c8b210fb 100644
--- a/imxweb/projects/qer/src/lib/itshop/itshop.service.ts
+++ b/imxweb/projects/qer/src/lib/itshop/itshop.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -28,17 +28,30 @@ import { Injectable } from '@angular/core';
import { ClassloggerService } from 'qbm';
import {
- PortalItshopApproveHistory, PortalItshopCart,
- PortalItshopPersondecision, PortalItshopPeergroupMemberships, PwoData, ServiceItemsExtendedData
+ PortalItshopApproveHistory,
+ PortalItshopCart,
+ PortalItshopPersondecision,
+ PortalItshopPeergroupMemberships,
+ PwoData,
+ ServiceItemsExtendedData,
+ PortalShopServiceitems,
} from 'imx-api-qer';
import {
- CollectionLoadParameters, EntityCollectionData, EntitySchema, ExtendedTypedEntityCollection, FilterTreeData, TypedEntityBuilder, TypedEntityCollectionData
+ CollectionLoadParameters,
+ CompareOperator,
+ EntityCollectionData,
+ EntitySchema,
+ ExtendedTypedEntityCollection,
+ FilterTreeData,
+ FilterType,
+ TypedEntityBuilder,
+ TypedEntityCollectionData,
} from 'imx-qbm-dbts';
import { ParameterDataLoadParameters } from '../parameter-data/parameter-data-load-parameters.interface';
import { QerApiService } from '../qer-api-client.service';
@Injectable({
- providedIn: 'root'
+ providedIn: 'root',
})
export class ItshopService {
public get PortalItshopPeergroupMembershipsSchema(): EntitySchema {
@@ -49,10 +62,42 @@ export class ItshopService {
private readonly historyBuilder = new TypedEntityBuilder(PortalItshopApproveHistory);
- constructor(
- private readonly qerClient: QerApiService,
- private readonly logger: ClassloggerService,
- ) { }
+ constructor(private readonly qerClient: QerApiService, private readonly logger: ClassloggerService) {}
+
+ public async get(
+ parameters: CollectionLoadParameters & {
+ UID_Person?: string;
+ UID_AccProductGroup?: string;
+ IncludeChildCategories?: boolean;
+ UID_AccProductParent?: string;
+ UID_PersonReference?: string;
+ UID_PersonPeerGroup?: string;
+ }
+ ): Promise> {
+ return this.qerClient.typedClient.PortalShopServiceitems.Get(parameters);
+ }
+
+ public async getServiceItem(serviceItemUid: string, isSkippable?: boolean): Promise {
+ const serviceItemCollection = await this.get({
+ IncludeChildCategories: false,
+ filter: [
+ {
+ ColumnName: 'UID_AccProduct',
+ Type: FilterType.Compare,
+ CompareOp: CompareOperator.Equal,
+ Value1: serviceItemUid,
+ },
+ ],
+ });
+ if (serviceItemCollection == null || serviceItemCollection.Data == null || serviceItemCollection.Data.length === 0) {
+ if (isSkippable) {
+ return null;
+ }
+ throw new Error('getServiceItem - service item not found');
+ }
+
+ return serviceItemCollection.Data[0];
+ }
public async getPeerGroupMemberships(
parameters: ({ UID_PersonReference: string } | { UID_PersonPeerGroup: string }) & { UID_Person?: string } & CollectionLoadParameters
@@ -60,7 +105,6 @@ export class ItshopService {
return this.qerClient.typedClient.PortalItshopPeergroupMemberships.Get(parameters);
}
-
public createTypedHistory(pwoData: PwoData): PortalItshopApproveHistory[] {
if (pwoData?.WorkflowHistory) {
return this.historyBuilder.buildReadWriteEntities(
@@ -76,25 +120,27 @@ export class ItshopService {
return this.qerClient.client.portal_itshop_requests_parameter_candidates_post(
parameters.columnName,
parameters.fkTableName,
- parameters.OrderBy,
- parameters.StartIndex,
- parameters.PageSize,
- parameters.filter,
- null,
- parameters.search,
- parameters.ParentKey,
- parameters.diffData
+ parameters.diffData,
+ {
+ OrderBy: parameters.OrderBy,
+ StartIndex: parameters.StartIndex,
+ PageSize: parameters.PageSize,
+ filter: parameters.filter,
+ search: parameters.search,
+ ParentKey: parameters.ParentKey
+ }
);
}
-
public async getRequestParameterFilterTree(parameters: ParameterDataLoadParameters): Promise {
return this.qerClient.client.portal_itshop_requests_parameter_candidates_filtertree_post(
parameters.columnName,
parameters.fkTableName,
- parameters.filter,
- parameters.ParentKey,
- parameters.diffData
+ parameters.diffData,
+ {
+ filter: parameters.filter,
+ parentkey: parameters.ParentKey
+ }
);
}
diff --git a/imxweb/projects/qer/src/lib/itshop/non-requestable-items/non-requestable-items.component.spec.ts b/imxweb/projects/qer/src/lib/itshop/non-requestable-items/non-requestable-items.component.spec.ts
index 2d8b78a35..98f44ee57 100644
--- a/imxweb/projects/qer/src/lib/itshop/non-requestable-items/non-requestable-items.component.spec.ts
+++ b/imxweb/projects/qer/src/lib/itshop/non-requestable-items/non-requestable-items.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/itshop/non-requestable-items/non-requestable-items.component.ts b/imxweb/projects/qer/src/lib/itshop/non-requestable-items/non-requestable-items.component.ts
index 06b9a8564..f8c153590 100644
--- a/imxweb/projects/qer/src/lib/itshop/non-requestable-items/non-requestable-items.component.ts
+++ b/imxweb/projects/qer/src/lib/itshop/non-requestable-items/non-requestable-items.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/itshop/peer-group/peer-group.component.scss b/imxweb/projects/qer/src/lib/itshop/peer-group/peer-group.component.scss
index 8d7402084..1ccf69055 100644
--- a/imxweb/projects/qer/src/lib/itshop/peer-group/peer-group.component.scss
+++ b/imxweb/projects/qer/src/lib/itshop/peer-group/peer-group.component.scss
@@ -1,4 +1,4 @@
-@import '~@elemental-ui/core/src/styles/_palette.scss';
+@import '@elemental-ui/core/src/styles/_palette.scss';
.imx-peer-group-info {
font-size: small;
diff --git a/imxweb/projects/qer/src/lib/itshop/peer-group/peer-group.component.spec.ts b/imxweb/projects/qer/src/lib/itshop/peer-group/peer-group.component.spec.ts
index 65dadd951..6c567bd1b 100644
--- a/imxweb/projects/qer/src/lib/itshop/peer-group/peer-group.component.spec.ts
+++ b/imxweb/projects/qer/src/lib/itshop/peer-group/peer-group.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/itshop/peer-group/peer-group.component.ts b/imxweb/projects/qer/src/lib/itshop/peer-group/peer-group.component.ts
index b5b22e9f2..7d5da6d1d 100644
--- a/imxweb/projects/qer/src/lib/itshop/peer-group/peer-group.component.ts
+++ b/imxweb/projects/qer/src/lib/itshop/peer-group/peer-group.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/itshop/request-info/approver-container.spec.ts b/imxweb/projects/qer/src/lib/itshop/request-info/approver-container.spec.ts
index 947e47836..e8297e815 100644
--- a/imxweb/projects/qer/src/lib/itshop/request-info/approver-container.spec.ts
+++ b/imxweb/projects/qer/src/lib/itshop/request-info/approver-container.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/itshop/request-info/approver-container.ts b/imxweb/projects/qer/src/lib/itshop/request-info/approver-container.ts
index 52f49aab4..20f7e1b6b 100644
--- a/imxweb/projects/qer/src/lib/itshop/request-info/approver-container.ts
+++ b/imxweb/projects/qer/src/lib/itshop/request-info/approver-container.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/itshop/request-info/decision-history.component.html b/imxweb/projects/qer/src/lib/itshop/request-info/decision-history.component.html
index 2538c6bb4..5a786b4cb 100644
--- a/imxweb/projects/qer/src/lib/itshop/request-info/decision-history.component.html
+++ b/imxweb/projects/qer/src/lib/itshop/request-info/decision-history.component.html
@@ -9,7 +9,7 @@
[attr.data-imx-identifier]="'workflow-step-title-'+i">{{
step.approveHistory.DecisionType.Column.GetDisplayValue() }}
-
- {{ step.approveHistory.XDateInserted.Column.GetDisplayValue() }}
+ {{step.approveHistory.XDateInserted.value | localizedDate }}
diff --git a/imxweb/projects/qer/src/lib/itshop/request-info/decision-history.component.scss b/imxweb/projects/qer/src/lib/itshop/request-info/decision-history.component.scss
index 7d6235a93..bb5229241 100644
--- a/imxweb/projects/qer/src/lib/itshop/request-info/decision-history.component.scss
+++ b/imxweb/projects/qer/src/lib/itshop/request-info/decision-history.component.scss
@@ -1,4 +1,4 @@
-@import "~@elemental-ui/core/src/styles/_palette.scss";
+@import "@elemental-ui/core/src/styles/_palette.scss";
:host {
display: flex;
@@ -36,18 +36,6 @@
}
}
-ul.imx-eventbar {
- margin: 0 0 0 -25px;
- padding: 0;
- display: flex;
- flex: 1 1 auto;
- flex-direction: column;
-}
-
-li {
- max-width: 460px;
-}
-
li.imx-event {
list-style-type: none;
padding: 0 0 20px 48px;
diff --git a/imxweb/projects/qer/src/lib/itshop/request-info/decision-history.component.spec.ts b/imxweb/projects/qer/src/lib/itshop/request-info/decision-history.component.spec.ts
index 499c40458..21460941a 100644
--- a/imxweb/projects/qer/src/lib/itshop/request-info/decision-history.component.spec.ts
+++ b/imxweb/projects/qer/src/lib/itshop/request-info/decision-history.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/itshop/request-info/decision-history.component.ts b/imxweb/projects/qer/src/lib/itshop/request-info/decision-history.component.ts
index 780570b1f..95e0e80b9 100644
--- a/imxweb/projects/qer/src/lib/itshop/request-info/decision-history.component.ts
+++ b/imxweb/projects/qer/src/lib/itshop/request-info/decision-history.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -25,6 +25,7 @@
*/
import { Component, Input } from '@angular/core';
+import { TranslateService } from '@ngx-translate/core';
import { DecisionHistoryService } from '../decision-history.service';
import { ApproverContainer } from './approver-container';
@@ -38,5 +39,8 @@ import { WorkflowHistoryItemWrapper } from './workflow-history-item-wrapper';
export class DecisionHistoryComponent {
@Input() public approverContainer: ApproverContainer;
@Input() public workflow: WorkflowHistoryItemWrapper[];
- constructor(public readonly decisionHistory: DecisionHistoryService) {}
+ constructor(
+ public readonly decisionHistory: DecisionHistoryService,
+ private readonly translate: TranslateService
+ ) { }
}
diff --git a/imxweb/projects/qer/src/lib/itshop/request-info/itshop-request-data.spec.ts b/imxweb/projects/qer/src/lib/itshop/request-info/itshop-request-data.spec.ts
index 94b39600d..a6048d949 100644
--- a/imxweb/projects/qer/src/lib/itshop/request-info/itshop-request-data.spec.ts
+++ b/imxweb/projects/qer/src/lib/itshop/request-info/itshop-request-data.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/itshop/request-info/itshop-request-data.ts b/imxweb/projects/qer/src/lib/itshop/request-info/itshop-request-data.ts
index eebc8dbdc..da3b7050f 100644
--- a/imxweb/projects/qer/src/lib/itshop/request-info/itshop-request-data.ts
+++ b/imxweb/projects/qer/src/lib/itshop/request-info/itshop-request-data.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/itshop/request-info/itshop-request-entity-wrapper.interface.ts b/imxweb/projects/qer/src/lib/itshop/request-info/itshop-request-entity-wrapper.interface.ts
index f41e22e99..880f492bf 100644
--- a/imxweb/projects/qer/src/lib/itshop/request-info/itshop-request-entity-wrapper.interface.ts
+++ b/imxweb/projects/qer/src/lib/itshop/request-info/itshop-request-entity-wrapper.interface.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/itshop/request-info/ordered-working-step.interface.ts b/imxweb/projects/qer/src/lib/itshop/request-info/ordered-working-step.interface.ts
index 82f2581bf..6244137d2 100644
--- a/imxweb/projects/qer/src/lib/itshop/request-info/ordered-working-step.interface.ts
+++ b/imxweb/projects/qer/src/lib/itshop/request-info/ordered-working-step.interface.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/itshop/request-info/request-info.component.html b/imxweb/projects/qer/src/lib/itshop/request-info/request-info.component.html
index dbb140efe..fd7c4d4f2 100644
--- a/imxweb/projects/qer/src/lib/itshop/request-info/request-info.component.html
+++ b/imxweb/projects/qer/src/lib/itshop/request-info/request-info.component.html
@@ -10,7 +10,25 @@
-
+
+
+
+
+
+
+
+
+
+
+
+
+ {{'#LDS#This product is a role membership and has the following entitlements.' |translate}}
+
+
@@ -18,6 +36,7 @@
+
diff --git a/imxweb/projects/qer/src/lib/pattern-item-list/pattern-item-list.component.spec.ts b/imxweb/projects/qer/src/lib/pattern-item-list/pattern-item-list.component.spec.ts
index 0e08da94b..613157b26 100644
--- a/imxweb/projects/qer/src/lib/pattern-item-list/pattern-item-list.component.spec.ts
+++ b/imxweb/projects/qer/src/lib/pattern-item-list/pattern-item-list.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/pattern-item-list/pattern-item-list.component.ts b/imxweb/projects/qer/src/lib/pattern-item-list/pattern-item-list.component.ts
index 1ff1a2b6f..eccfc9c87 100644
--- a/imxweb/projects/qer/src/lib/pattern-item-list/pattern-item-list.component.ts
+++ b/imxweb/projects/qer/src/lib/pattern-item-list/pattern-item-list.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -59,9 +59,10 @@ export class PatternItemListComponent implements AfterViewInit, OnChanges, OnDes
@Input() public keywords: string;
@Input() public recipients: IWriteValue;
@Input() public dataSourceView = { selected: 'cardlist' };
+ @Input() public itemActions: DataTileMenuItem[];
- @Output() public addItemToCart = new EventEmitter();
- @Output() public showDetails = new EventEmitter();
+ @Output() public handleAction = new EventEmitter<
+ { name: string, serviceItems?: PortalShopServiceitems[], patternItem?: PortalItshopPatternRequestable }>();
@Output() public selectionChanged = new EventEmitter();
public dstSettings: DataSourceToolbarSettings;
@@ -129,7 +130,7 @@ export class PatternItemListComponent implements AfterViewInit, OnChanges, OnDes
Type: ValType.String
},
{
- ColumnName: 'addCartButton',
+ ColumnName: 'actions',
Type: ValType.String,
},
];
@@ -244,28 +245,25 @@ export class PatternItemListComponent implements AfterViewInit, OnChanges, OnDes
this.dataSourceView.selected = view;
}
- public handleAction(item: DataTileMenuItem): void {
- if (item.name === 'edit') {
- this.addItemToCart.emit(item.typedEntity as PortalItshopPatternRequestable);
- }
- if (item.name === 'details') {
- this.bubbleShowDetails(item.typedEntity as PortalItshopPatternRequestable);
- }
- }
-
- public async bubbleShowDetails(patternRequestable: PortalItshopPatternRequestable): Promise {
- let overlayRef: OverlayRef;
- setTimeout(() => {
- overlayRef = this.busyService.show();
- });
+ public async emitAction(item: DataTileMenuItem, patternRequestable?: PortalItshopPatternRequestable): Promise {
- try {
- const items = await this.patternItemService.getServiceItems(patternRequestable);
- this.showDetails.emit(items);
- } finally {
+ if (item.name === 'details') {
+ let overlayRef: OverlayRef;
setTimeout(() => {
- this.busyService.hide(overlayRef);
+ overlayRef = this.busyService.show();
});
+
+ try {
+ const items = await this.patternItemService.getServiceItems(item.typedEntity as PortalItshopPatternRequestable);
+ this.handleAction.emit({ serviceItems: items, name: item.name });
+ } finally {
+ setTimeout(() => {
+ this.busyService.hide(overlayRef);
+ });
+ }
+ }
+ if (item.name === 'addTemplateToCart') {
+ this.handleAction.emit({ patternItem: patternRequestable ?? item.typedEntity as PortalItshopPatternRequestable, name: item.name });
}
}
diff --git a/imxweb/projects/qer/src/lib/pattern-item-list/pattern-item.service.spec.ts b/imxweb/projects/qer/src/lib/pattern-item-list/pattern-item.service.spec.ts
index 804b15c0a..73cff3677 100644
--- a/imxweb/projects/qer/src/lib/pattern-item-list/pattern-item.service.spec.ts
+++ b/imxweb/projects/qer/src/lib/pattern-item-list/pattern-item.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/pattern-item-list/pattern-item.service.ts b/imxweb/projects/qer/src/lib/pattern-item-list/pattern-item.service.ts
index 631c1c2b8..6aee99c08 100644
--- a/imxweb/projects/qer/src/lib/pattern-item-list/pattern-item.service.ts
+++ b/imxweb/projects/qer/src/lib/pattern-item-list/pattern-item.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/pattern-item-list/pattern-items.module.ts b/imxweb/projects/qer/src/lib/pattern-item-list/pattern-items.module.ts
index 07adf09dc..47aae94ce 100644
--- a/imxweb/projects/qer/src/lib/pattern-item-list/pattern-items.module.ts
+++ b/imxweb/projects/qer/src/lib/pattern-item-list/pattern-items.module.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/person/person-all-load-parameters.interface.ts b/imxweb/projects/qer/src/lib/person/person-all-load-parameters.interface.ts
index 5667f9d52..57c224eb4 100644
--- a/imxweb/projects/qer/src/lib/person/person-all-load-parameters.interface.ts
+++ b/imxweb/projects/qer/src/lib/person/person-all-load-parameters.interface.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/person/person.module.ts b/imxweb/projects/qer/src/lib/person/person.module.ts
index c90128c01..3c2fb2526 100644
--- a/imxweb/projects/qer/src/lib/person/person.module.ts
+++ b/imxweb/projects/qer/src/lib/person/person.module.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/person/person.service.spec.ts b/imxweb/projects/qer/src/lib/person/person.service.spec.ts
index 0d14f1a42..c6906953d 100644
--- a/imxweb/projects/qer/src/lib/person/person.service.spec.ts
+++ b/imxweb/projects/qer/src/lib/person/person.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/person/person.service.ts b/imxweb/projects/qer/src/lib/person/person.service.ts
index 7a68f3865..198396afa 100644
--- a/imxweb/projects/qer/src/lib/person/person.service.ts
+++ b/imxweb/projects/qer/src/lib/person/person.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -58,7 +58,7 @@ export class PersonService {
constructor(private readonly qerClient: QerApiService, private readonly entityService: EntityService) { }
public async getMasterdataInteractive(uid: string): Promise> {
- return this.qerClient.typedClient.PortalPersonMasterdataInteractive_byid.Get_byid(uid);
+ return this.qerClient.typedClient.PortalPersonMasterdataInteractive.Get_byid(uid);
}
public async getMasterdata(parameters: CollectionLoadParameters = {}): Promise> {
@@ -74,7 +74,7 @@ export class PersonService {
}
public async getDataModel(filter?: FilterData[]): Promise {
- return this.qerClient.client.portal_person_all_datamodel_get(filter);
+ return this.qerClient.client.portal_person_all_datamodel_get({ filter: filter });
}
public async getGroupInfo(parameters: PersonAllLoadParameters = {}): Promise {
diff --git a/imxweb/projects/qer/src/lib/product-selection/optional-items-sidesheet/dependency.service.spec.ts b/imxweb/projects/qer/src/lib/product-selection/optional-items-sidesheet/dependency.service.spec.ts
new file mode 100644
index 000000000..4eb8d32e8
--- /dev/null
+++ b/imxweb/projects/qer/src/lib/product-selection/optional-items-sidesheet/dependency.service.spec.ts
@@ -0,0 +1,77 @@
+/*
+ * ONE IDENTITY LLC. PROPRIETARY INFORMATION
+ *
+ * This software is confidential. One Identity, LLC. or one of its affiliates or
+ * subsidiaries, has supplied this software to you under terms of a
+ * license agreement, nondisclosure agreement or both.
+ *
+ * You may not copy, disclose, or use this software except in accordance with
+ * those terms.
+ *
+ *
+ * Copyright 2022 One Identity LLC.
+ * ALL RIGHTS RESERVED.
+ *
+ * ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
+ * WARRANTIES ABOUT THE SUITABILITY OF THE SOFTWARE,
+ * EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
+ * TO THE IMPLIED WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE, OR
+ * NON-INFRINGEMENT. ONE IDENTITY LLC. SHALL NOT BE
+ * LIABLE FOR ANY DAMAGES SUFFERED BY LICENSEE
+ * AS A RESULT OF USING, MODIFYING OR DISTRIBUTING
+ * THIS SOFTWARE OR ITS DERIVATIVES.
+ *
+ */
+
+import { TestBed } from '@angular/core/testing';
+import { EuiLoadingService } from '@elemental-ui/core';
+import { configureTestSuite } from 'ng-bullet';
+import { QerApiService } from '../../qer-api-client.service';
+
+import { DependencyService } from './dependency.service';
+
+describe('DependencyService', () => {
+ let service: DependencyService;
+
+ const qerApiStub = {
+ v2Client: {
+ portal_shop_serviceitems_dependencies_get: jasmine.createSpy('portal_shop_serviceitems_dependencies_get').and.callFake(
+ (
+ uid: string,
+ options?: {
+ UID_Person?: string;
+ }
+ ) => Promise.resolve({})
+ ),
+ },
+ typedClient: {
+ PortalShopServiceitems: {
+ GetSchema: () => {},
+ },
+ },
+ };
+
+ configureTestSuite(() => {
+ TestBed.configureTestingModule({
+ providers: [
+ {
+ provide: QerApiService,
+ useValue: qerApiStub,
+ },
+ {
+ provide: EuiLoadingService,
+ useValue: {
+ hide: jasmine.createSpy('hide'),
+ show: jasmine.createSpy('show')
+ },
+ },
+ ],
+ });
+ service = TestBed.inject(DependencyService);
+ });
+
+ it('should be created', () => {
+ expect(service).toBeTruthy();
+ });
+});
diff --git a/imxweb/projects/qer/src/lib/product-selection/optional-items-sidesheet/dependency.service.ts b/imxweb/projects/qer/src/lib/product-selection/optional-items-sidesheet/dependency.service.ts
new file mode 100644
index 000000000..ea0905ef6
--- /dev/null
+++ b/imxweb/projects/qer/src/lib/product-selection/optional-items-sidesheet/dependency.service.ts
@@ -0,0 +1,157 @@
+/*
+ * ONE IDENTITY LLC. PROPRIETARY INFORMATION
+ *
+ * This software is confidential. One Identity, LLC. or one of its affiliates or
+ * subsidiaries, has supplied this software to you under terms of a
+ * license agreement, nondisclosure agreement or both.
+ *
+ * You may not copy, disclose, or use this software except in accordance with
+ * those terms.
+ *
+ *
+ * Copyright 2022 One Identity LLC.
+ * ALL RIGHTS RESERVED.
+ *
+ * ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
+ * WARRANTIES ABOUT THE SUITABILITY OF THE SOFTWARE,
+ * EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
+ * TO THE IMPLIED WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE, OR
+ * NON-INFRINGEMENT. ONE IDENTITY LLC. SHALL NOT BE
+ * LIABLE FOR ANY DAMAGES SUFFERED BY LICENSEE
+ * AS A RESULT OF USING, MODIFYING OR DISTRIBUTING
+ * THIS SOFTWARE OR ITS DERIVATIVES.
+ *
+ */
+
+import { Injectable } from '@angular/core';
+import { EuiLoadingService } from '@elemental-ui/core';
+import { PortalShopServiceitems, ServiceItemHierarchy } from 'imx-api-qer';
+import { EntitySchema, IWriteValue, MultiValue, TypedEntity } from 'imx-qbm-dbts';
+import { QerApiService } from '../../qer-api-client.service';
+import { ServiceItemHierarchyExtended, ServiceItemTreeWrapper } from '../service-item-order.interface';
+
+@Injectable({
+ providedIn: 'root',
+})
+export class DependencyService {
+ constructor(private readonly qerClient: QerApiService, private busyService: EuiLoadingService) {}
+
+ public get PortalShopServiceItemsSchema(): EntitySchema {
+ return this.qerClient.typedClient.PortalShopServiceitems.GetSchema();
+ }
+
+ public async get(parameters: { UID_Person?: string; UID_AccProductParent: string }): Promise {
+ return this.qerClient.v2Client.portal_shop_serviceitems_dependencies_get(parameters.UID_AccProductParent, {
+ UID_Person: parameters?.UID_Person,
+ });
+ }
+
+ public countOptional(tree: ServiceItemHierarchy): number {
+ let count = 0;
+ if (tree?.Optional.length > 0) {
+ // Count number of optional, and apply this to all children
+ count += tree.Optional.length;
+ count = tree.Optional.map((childTree) => this.countOptional(childTree)).reduce((a, b) => a + b, count);
+ }
+ if (tree?.Mandatory.length > 0) {
+ // Apply only to children
+ count = tree.Mandatory.map((childTree) => this.countOptional(childTree)).reduce((a, b) => a + b, count);
+ }
+ return count;
+ }
+
+ public extendTree(
+ tree: ServiceItemHierarchy,
+ options?: {
+ Recipient?: string;
+ UidRecipient?: string;
+ isMandatory: boolean;
+ isChecked: boolean;
+ isIndeterminate: boolean;
+ parentChecked: boolean;
+ parent?: string;
+ }
+ ): ServiceItemHierarchyExtended {
+ const extendedTree: ServiceItemHierarchyExtended = {
+ Display: tree.Display,
+ UidAccProduct: tree.UidAccProduct,
+ Mandatory: [],
+ Optional: [],
+ ...options,
+ };
+ const parent = tree.UidAccProduct;
+ if (tree?.Mandatory.length > 0) {
+ extendedTree.Mandatory = tree.Mandatory.map((childTree) =>
+ this.extendTree(childTree, {
+ isMandatory: true,
+ isChecked: true,
+ isIndeterminate: !options.isChecked,
+ parent,
+ parentChecked: options.isChecked,
+ })
+ );
+ }
+ if (tree?.Optional.length > 0) {
+ extendedTree.Optional = tree.Optional.map((childTree) =>
+ this.extendTree(childTree, {
+ isMandatory: false,
+ isChecked: false,
+ isIndeterminate: !options.isChecked,
+ parent,
+ parentChecked: options.isChecked,
+ })
+ );
+ }
+ return extendedTree;
+ }
+
+ public async checkForOptionalTree(
+ serviceItems: PortalShopServiceitems[],
+ recipients: IWriteValue
+ ): Promise {
+ const allTrees: ServiceItemTreeWrapper = {
+ trees: [],
+ };
+ try {
+ this.busyService.show();
+ let optionalCount = 0;
+ const recipientsUids = MultiValue.FromString(recipients.value).GetValues();
+ const recipientsDisplays = MultiValue.FromString(recipients.Column.GetDisplayValue()).GetValues();
+ await Promise.all(
+ serviceItems.map(async (parentItem) => {
+ await Promise.all(
+ recipientsUids.map(async (recipientUid, index) => {
+ const parentKey = this.getKey(parentItem);
+ const hierarchy = await this.get({
+ UID_AccProductParent: parentKey,
+ UID_Person: recipientUid,
+ });
+ const thisCount = this.countOptional(hierarchy);
+ if (thisCount > 0) {
+ const extendedhierarchy = this.extendTree(hierarchy, {
+ Recipient: recipientsDisplays[index],
+ UidRecipient: recipientUid,
+ isMandatory: true,
+ isChecked: true,
+ isIndeterminate: false,
+ parentChecked: true,
+ });
+ allTrees.trees.push(extendedhierarchy);
+ optionalCount += thisCount;
+ }
+ })
+ );
+ })
+ );
+ allTrees.totalOptional = optionalCount;
+ } finally {
+ this.busyService.hide();
+ }
+ return allTrees;
+ }
+
+ private getKey(item: TypedEntity): string {
+ return item.GetEntity().GetKeys()[0];
+ }
+}
diff --git a/imxweb/projects/qer/src/lib/product-selection/optional-items-sidesheet/optional-items-sidesheet.component.html b/imxweb/projects/qer/src/lib/product-selection/optional-items-sidesheet/optional-items-sidesheet.component.html
new file mode 100644
index 000000000..b992c0b6c
--- /dev/null
+++ b/imxweb/projects/qer/src/lib/product-selection/optional-items-sidesheet/optional-items-sidesheet.component.html
@@ -0,0 +1,59 @@
+
+
+ {{ '#LDS#The following products have optional products as well, select these if you want to request them additionally. Only products with selected parents will be added.' | translate }}
+
+
+
+
-
-
-
\ No newline at end of file
diff --git a/imxweb/projects/qer/src/lib/product-selection/product-details-sidesheet/product-entitlements/product-entitlements.component.scss b/imxweb/projects/qer/src/lib/product-selection/product-details-sidesheet/product-entitlements/product-entitlements.component.scss
deleted file mode 100644
index 1450be87c..000000000
--- a/imxweb/projects/qer/src/lib/product-selection/product-details-sidesheet/product-entitlements/product-entitlements.component.scss
+++ /dev/null
@@ -1 +0,0 @@
-//Hier können css-regeln eingeführt werden
\ No newline at end of file
diff --git a/imxweb/projects/qer/src/lib/product-selection/product-selection.component.html b/imxweb/projects/qer/src/lib/product-selection/product-selection.component.html
index c40dd9848..ec2e9cc8a 100644
--- a/imxweb/projects/qer/src/lib/product-selection/product-selection.component.html
+++ b/imxweb/projects/qer/src/lib/product-selection/product-selection.component.html
@@ -1,16 +1,21 @@
-
- {{'#LDS#Select all on page' | translate}}
- {{'#LDS#Deselect all' | translate}}
+ {{ '#LDS#Select all on page' | translate }}
+
+ {{ '#LDS#Deselect all' | translate }}
+
-
- {{'#LDS#Add to cart' |
- translate}}
+
+ {{ '#LDS#Add to cart' | translate }}
+
@@ -186,10 +216,9 @@
-
{{ '#LDS#This product has already been assigned to {0}.' | translate |
- ldsReplace:recipients?.Column?.GetDisplayValue() }}
- {{ '#LDS#You can still submit a request for the product. Please see the details about the assignmeht below.' |
- translate}}
+
+ {{ '#LDS#This product has already been assigned to {0}.' | translate | ldsReplace: recipients?.Column?.GetDisplayValue() }}
+ {{ '#LDS#You can still submit a request for the product. Please see the details about the assignmeht below.' | translate }}
-
+
+
+
+ {{'#LDS#Select the type of entitlement to add' | translate}}
+
+
+ {{pr.TableDisplay}}
+
+
+
+
+
+
-
+
{{ '#LDS#Show products from service category' | translate }}
@@ -117,6 +94,7 @@
-
+
diff --git a/imxweb/projects/qer/src/lib/service-items/serviceitem-list/serviceitem-list.component.scss b/imxweb/projects/qer/src/lib/service-items/serviceitem-list/serviceitem-list.component.scss
index 584639de3..4ece1918b 100644
--- a/imxweb/projects/qer/src/lib/service-items/serviceitem-list/serviceitem-list.component.scss
+++ b/imxweb/projects/qer/src/lib/service-items/serviceitem-list/serviceitem-list.component.scss
@@ -1,4 +1,4 @@
-@import '~@elemental-ui/core/src/styles/_palette.scss';
+@import '@elemental-ui/core/src/styles/_palette.scss';
:host {
display: flex;
@@ -35,4 +35,4 @@
eui-icon {
margin-right: 5px;
-}
\ No newline at end of file
+}
diff --git a/imxweb/projects/qer/src/lib/service-items/serviceitem-list/serviceitem-list.component.spec.ts b/imxweb/projects/qer/src/lib/service-items/serviceitem-list/serviceitem-list.component.spec.ts
index c90c307fd..80b257eb7 100644
--- a/imxweb/projects/qer/src/lib/service-items/serviceitem-list/serviceitem-list.component.spec.ts
+++ b/imxweb/projects/qer/src/lib/service-items/serviceitem-list/serviceitem-list.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/service-items/serviceitem-list/serviceitem-list.component.ts b/imxweb/projects/qer/src/lib/service-items/serviceitem-list/serviceitem-list.component.ts
index b1a8d4ef3..2540cb3a7 100644
--- a/imxweb/projects/qer/src/lib/service-items/serviceitem-list/serviceitem-list.component.ts
+++ b/imxweb/projects/qer/src/lib/service-items/serviceitem-list/serviceitem-list.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -25,11 +25,30 @@
*/
import { OverlayRef } from '@angular/cdk/overlay';
-import { Component, Input, Output, EventEmitter, AfterViewInit, OnChanges, SimpleChanges, ViewChild, OnDestroy, OnInit } from '@angular/core';
+import {
+ Component,
+ Input,
+ Output,
+ EventEmitter,
+ AfterViewInit,
+ OnChanges,
+ SimpleChanges,
+ ViewChild,
+ OnDestroy,
+ OnInit,
+} from '@angular/core';
import { MatDialog } from '@angular/material/dialog';
import { EuiLoadingService } from '@elemental-ui/core';
-import { DataSourceToolbarSettings, DataSourceToolbarComponent, DataTileBadge, DataTileMenuItem, SettingsService, buildAdditionalElementsString } from 'qbm';
+import {
+ buildAdditionalElementsString,
+ DataSourceToolbarComponent,
+ DataSourceToolbarSettings,
+ DataTileBadge,
+ DataTileMenuItem,
+ MessageDialogComponent,
+ SettingsService,
+} from 'qbm';
import {
CollectionLoadParameters,
DisplayColumns,
@@ -38,14 +57,14 @@ import {
ValType,
MultiValue,
EntitySchema,
- DataModel
+ DataModel,
} from 'imx-qbm-dbts';
-import { ITShopConfig, PortalShopCategories, PortalShopServiceitems } from 'imx-api-qer';
+import { PortalShopCategories, PortalShopServiceitems } from 'imx-api-qer';
import { ServiceItemsService } from '../service-items.service';
import { ServiceItemInfoComponent } from '../service-item-info/service-item-info.component';
import { ImageService } from '../../itshop/image.service';
-import { ProjectConfigurationService } from '../../project-configuration/project-configuration.service';
+import { TranslateService } from '@ngx-translate/core';
@Component({
selector: 'imx-serviceitem-list',
@@ -61,10 +80,10 @@ export class ServiceitemListComponent implements AfterViewInit, OnChanges, OnDes
@Input() public referenceUserUid: string;
@Input() public uidPersonPeerGroup: string;
@Input() public dataSourceView = { selected: 'cardlist' };
+ @Input() public itemActions: DataTileMenuItem[];
@Output() public selectionChanged = new EventEmitter();
- @Output() public addItemToCart = new EventEmitter();
- @Output() public showDetails = new EventEmitter();
+ @Output() public handleAction = new EventEmitter<{ item: PortalShopServiceitems, name: string }>();
@Output() public categoryRemoved = new EventEmitter();
@Output() public readonly openCategoryTree = new EventEmitter();
@@ -73,46 +92,26 @@ export class ServiceitemListComponent implements AfterViewInit, OnChanges, OnDes
public DisplayColumns = DisplayColumns;
public displayedColumns: IClientProperty[];
public includeChildCategories: boolean;
+ public noDataText = '#LDS#No data';
public readonly status = {
- getBadges: (prod: PortalShopServiceitems): DataTileBadge[] => {
- const result: DataTileBadge[] = [];
- if (prod.IsRequestable.value === false) {
- result.push({
- content: this.badgeNotRequestableText,
- color: 'red',
- });
- }
-
- if (
- prod.IsRequestable.value &&
- (this.isValueContains(prod.OrderableStatus.value, ['PERSONHASOBJECT', 'PERSONHASASSIGNMENTORDER']) ||
- this.isValueContains(prod.OrderableStatus.value, 'ASSIGNED') ||
- this.isValueContains(prod.OrderableStatus.value, 'ORDER') ||
- this.isValueContains(prod.OrderableStatus.value, 'NOTORDERABLE') ||
- this.isValueContains(prod.OrderableStatus.value, 'CART'))
- ) {
- result.push({
- content: this.badgeInfoText,
- color: 'orange',
- });
- }
-
- return result;
- },
+ getBadges: (prod: PortalShopServiceitems): DataTileBadge[] => this.getBadges(prod),
enabled: (prod: PortalShopServiceitems): boolean => {
return prod.IsRequestable.value;
},
- getImage: async (prod: PortalShopServiceitems): Promise => this.image.get(prod, this.itshopConfig),
+ getImagePath: async (prod: PortalShopServiceitems): Promise => this.image.getPath(prod),
};
public peerGroupSize: number;
public isLoading = false;
+ public get options(): string[] {
+ return this.uidPersonPeerGroup ?? '' !== '' ? ['search', 'filter', 'settings'] : ['search', 'filter', 'settings', 'selectedViewGroup'];
+ }
+
@ViewChild(DataSourceToolbarComponent) private readonly dst: DataSourceToolbarComponent;
private readonly badgeInfoText = '#LDS#Info';
private readonly badgeNotRequestableText = '#LDS#Not requestable';
private navigationState: CollectionLoadParameters;
- private itshopConfig: ITShopConfig;
private dataModel: DataModel;
constructor(
@@ -120,15 +119,15 @@ export class ServiceitemListComponent implements AfterViewInit, OnChanges, OnDes
private readonly serviceItemsProvider: ServiceItemsService,
private readonly dialog: MatDialog,
private readonly image: ImageService,
- private readonly settingsService: SettingsService,
- private readonly projectConfig: ProjectConfigurationService
+ private readonly translate: TranslateService,
+ settingsService: SettingsService,
) {
this.navigationState = { PageSize: settingsService.DefaultPageSize, StartIndex: 0 };
this.entitySchema = serviceItemsProvider.PortalShopServiceItemsSchema;
this.displayedColumns = [
this.entitySchema.Columns[DisplayColumns.DISPLAY_PROPERTYNAME],
{
- ColumnName: 'addCartButton',
+ ColumnName: 'actions',
Type: ValType.String,
},
];
@@ -155,6 +154,7 @@ export class ServiceitemListComponent implements AfterViewInit, OnChanges, OnDes
(changes.referenceUserUid && !changes.referenceUserUid.firstChange) ||
(changes.uidPersonPeerGroup && !changes.uidPersonPeerGroup.firstChange)
) {
+ this.dst?.clearSelection();
return this.getData({ StartIndex: 0 });
}
}
@@ -198,10 +198,6 @@ export class ServiceitemListComponent implements AfterViewInit, OnChanges, OnDes
});
try {
- if (this.itshopConfig == null) {
- this.itshopConfig = (await this.projectConfig.getConfig()).ITShopConfig;
- }
-
const data = await this.serviceItemsProvider.get({
...this.navigationState,
UID_Person: this.recipients ? MultiValue.FromString(this.recipients.value).GetValues().join(',') : undefined,
@@ -218,10 +214,24 @@ export class ServiceitemListComponent implements AfterViewInit, OnChanges, OnDes
entitySchema: this.entitySchema,
navigationState: this.navigationState,
dataModel: this.dataModel,
- identifierForSessionStore: 'service-item-list'
+ identifierForSessionStore: 'service-item-list',
};
this.peerGroupSize = data.extendedData?.PeerGroupSize;
+
+ if (this.peerGroupSize === 0) {
+ this.noDataText = '#LDS#Heading Peer Group Is Empty';
+ this.dialog.open(MessageDialogComponent, {
+ data: {
+ ShowOk: true,
+ Title: await this.translate.get(this.noDataText).toPromise(),
+ Message: await this.translate.get('#LDS#You cannot view products of your peer group. Your peer group is empty.').toPromise(),
+ },
+ panelClass: 'imx-messageDialog',
+ });
+ } else {
+ this.noDataText = '#LDS#No data';
+ }
} else {
this.dstSettings = undefined;
}
@@ -255,13 +265,8 @@ export class ServiceitemListComponent implements AfterViewInit, OnChanges, OnDes
this.dataSourceView.selected = view;
}
- public handleAction(item: DataTileMenuItem): void {
- if (item.name === 'edit') {
- this.addItemToCart.emit(item.typedEntity as PortalShopServiceitems);
- }
- if (item.name === 'details') {
- this.showDetails.emit(item.typedEntity as PortalShopServiceitems);
- }
+ public emitAction(item: DataTileMenuItem, serviceItem?: PortalShopServiceitems): void {
+ this.handleAction.emit({ item: serviceItem ?? item.typedEntity as PortalShopServiceitems, name: item.name });
}
public async onRemoveChip(): Promise {
@@ -283,4 +288,30 @@ export class ServiceitemListComponent implements AfterViewInit, OnChanges, OnDes
this.dstComponent.keywords = '';
this.dstComponent.searchControl.setValue('');
}
+
+ private getBadges(prod: PortalShopServiceitems): DataTileBadge[] {
+ const result: DataTileBadge[] = [];
+ if (prod.IsRequestable.value === false) {
+ result.push({
+ content: this.badgeNotRequestableText,
+ color: 'red',
+ });
+ }
+
+ if (
+ prod.IsRequestable.value &&
+ (this.isValueContains(prod.OrderableStatus.value, ['PERSONHASOBJECT', 'PERSONHASASSIGNMENTORDER']) ||
+ this.isValueContains(prod.OrderableStatus.value, 'ASSIGNED') ||
+ this.isValueContains(prod.OrderableStatus.value, 'ORDER') ||
+ this.isValueContains(prod.OrderableStatus.value, 'NOTORDERABLE') ||
+ this.isValueContains(prod.OrderableStatus.value, 'CART'))
+ ) {
+ result.push({
+ content: this.badgeInfoText,
+ color: 'orange',
+ });
+ }
+
+ return result;
+ }
}
diff --git a/imxweb/projects/qer/src/lib/shopping-cart-validation-detail/base-viewer/base-viewer.component.spec.ts b/imxweb/projects/qer/src/lib/shopping-cart-validation-detail/base-viewer/base-viewer.component.spec.ts
index c4ba2b44e..7be06d75a 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart-validation-detail/base-viewer/base-viewer.component.spec.ts
+++ b/imxweb/projects/qer/src/lib/shopping-cart-validation-detail/base-viewer/base-viewer.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/shopping-cart-validation-detail/base-viewer/base-viewer.component.ts b/imxweb/projects/qer/src/lib/shopping-cart-validation-detail/base-viewer/base-viewer.component.ts
index 6f4c260e9..8bf29f6f7 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart-validation-detail/base-viewer/base-viewer.component.ts
+++ b/imxweb/projects/qer/src/lib/shopping-cart-validation-detail/base-viewer/base-viewer.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/shopping-cart-validation-detail/detail-viewer/detail-viewer.component.spec.ts b/imxweb/projects/qer/src/lib/shopping-cart-validation-detail/detail-viewer/detail-viewer.component.spec.ts
index 5adfca409..955fb2d92 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart-validation-detail/detail-viewer/detail-viewer.component.spec.ts
+++ b/imxweb/projects/qer/src/lib/shopping-cart-validation-detail/detail-viewer/detail-viewer.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/shopping-cart-validation-detail/detail-viewer/detail-viewer.component.ts b/imxweb/projects/qer/src/lib/shopping-cart-validation-detail/detail-viewer/detail-viewer.component.ts
index e728ff9c6..9316623c9 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart-validation-detail/detail-viewer/detail-viewer.component.ts
+++ b/imxweb/projects/qer/src/lib/shopping-cart-validation-detail/detail-viewer/detail-viewer.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/shopping-cart-validation-detail/details-container.interface.ts b/imxweb/projects/qer/src/lib/shopping-cart-validation-detail/details-container.interface.ts
index 5a359bc3d..577d042eb 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart-validation-detail/details-container.interface.ts
+++ b/imxweb/projects/qer/src/lib/shopping-cart-validation-detail/details-container.interface.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/shopping-cart-validation-detail/details-view.interface.ts b/imxweb/projects/qer/src/lib/shopping-cart-validation-detail/details-view.interface.ts
index d886aeca8..9369e9b13 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart-validation-detail/details-view.interface.ts
+++ b/imxweb/projects/qer/src/lib/shopping-cart-validation-detail/details-view.interface.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/shopping-cart-validation-detail/duplicate-check/duplicate-check.component.ts b/imxweb/projects/qer/src/lib/shopping-cart-validation-detail/duplicate-check/duplicate-check.component.ts
index dfb1b9065..de5c06c2d 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart-validation-detail/duplicate-check/duplicate-check.component.ts
+++ b/imxweb/projects/qer/src/lib/shopping-cart-validation-detail/duplicate-check/duplicate-check.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/shopping-cart-validation-detail/exclusion-check/exclusion-check.component.ts b/imxweb/projects/qer/src/lib/shopping-cart-validation-detail/exclusion-check/exclusion-check.component.ts
index 6a273105e..f13f0a196 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart-validation-detail/exclusion-check/exclusion-check.component.ts
+++ b/imxweb/projects/qer/src/lib/shopping-cart-validation-detail/exclusion-check/exclusion-check.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/shopping-cart-validation-detail/exclusion-check/exclusion-result.interface.ts b/imxweb/projects/qer/src/lib/shopping-cart-validation-detail/exclusion-check/exclusion-result.interface.ts
index 42ce8737c..c15700235 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart-validation-detail/exclusion-check/exclusion-result.interface.ts
+++ b/imxweb/projects/qer/src/lib/shopping-cart-validation-detail/exclusion-check/exclusion-result.interface.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/shopping-cart-validation-detail/product-dependency-check/mandatory-acc-product-result.interface.ts b/imxweb/projects/qer/src/lib/shopping-cart-validation-detail/product-dependency-check/mandatory-acc-product-result.interface.ts
index 19d4a04ed..456a8d91c 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart-validation-detail/product-dependency-check/mandatory-acc-product-result.interface.ts
+++ b/imxweb/projects/qer/src/lib/shopping-cart-validation-detail/product-dependency-check/mandatory-acc-product-result.interface.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/shopping-cart-validation-detail/product-dependency-check/product-dependency-check.component.ts b/imxweb/projects/qer/src/lib/shopping-cart-validation-detail/product-dependency-check/product-dependency-check.component.ts
index 645486a56..c49e57ee0 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart-validation-detail/product-dependency-check/product-dependency-check.component.ts
+++ b/imxweb/projects/qer/src/lib/shopping-cart-validation-detail/product-dependency-check/product-dependency-check.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/shopping-cart-validation-detail/shopping-cart-validation-detail.module.ts b/imxweb/projects/qer/src/lib/shopping-cart-validation-detail/shopping-cart-validation-detail.module.ts
index b9adf16b9..a41575ecc 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart-validation-detail/shopping-cart-validation-detail.module.ts
+++ b/imxweb/projects/qer/src/lib/shopping-cart-validation-detail/shopping-cart-validation-detail.module.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/shopping-cart-validation-detail/shopping-cart-validation-detail.service.spec.ts b/imxweb/projects/qer/src/lib/shopping-cart-validation-detail/shopping-cart-validation-detail.service.spec.ts
index 701817f41..fe54351a9 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart-validation-detail/shopping-cart-validation-detail.service.spec.ts
+++ b/imxweb/projects/qer/src/lib/shopping-cart-validation-detail/shopping-cart-validation-detail.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/shopping-cart-validation-detail/shopping-cart-validation-detail.service.ts b/imxweb/projects/qer/src/lib/shopping-cart-validation-detail/shopping-cart-validation-detail.service.ts
index 39b02ad2b..d3c0d860f 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart-validation-detail/shopping-cart-validation-detail.service.ts
+++ b/imxweb/projects/qer/src/lib/shopping-cart-validation-detail/shopping-cart-validation-detail.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/shopping-cart/cart-item-edit/cart-item-clone-parameters.interface.ts b/imxweb/projects/qer/src/lib/shopping-cart/cart-item-edit/cart-item-clone-parameters.interface.ts
index 82d8e0a6e..af85c8255 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart/cart-item-edit/cart-item-clone-parameters.interface.ts
+++ b/imxweb/projects/qer/src/lib/shopping-cart/cart-item-edit/cart-item-clone-parameters.interface.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/shopping-cart/cart-item-edit/cart-item-clone.service.spec.ts b/imxweb/projects/qer/src/lib/shopping-cart/cart-item-edit/cart-item-clone.service.spec.ts
index 9d9a62bb6..8a8ecb86b 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart/cart-item-edit/cart-item-clone.service.spec.ts
+++ b/imxweb/projects/qer/src/lib/shopping-cart/cart-item-edit/cart-item-clone.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/shopping-cart/cart-item-edit/cart-item-clone.service.ts b/imxweb/projects/qer/src/lib/shopping-cart/cart-item-edit/cart-item-clone.service.ts
index 599411ccd..229265de5 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart/cart-item-edit/cart-item-clone.service.ts
+++ b/imxweb/projects/qer/src/lib/shopping-cart/cart-item-edit/cart-item-clone.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -80,10 +80,12 @@ export class CartItemCloneService {
setTimeout(() => this.busyService.show());
try {
const serviceItem = await this.serviceItems.getServiceItem(item.accProduct.DataValue);
- const serviceItemForPersons = await this.serviceItems.getServiceItemsForPersons(
+ const serviceItemForPersons = this.serviceItems.getServiceItemsForPersons(
[serviceItem],
persons,
- item.uidITShopOrg
+ {
+ uidITShopOrg: item.uidITShopOrg
+ }
);
if (serviceItemForPersons && serviceItemForPersons.length > 0) {
diff --git a/imxweb/projects/qer/src/lib/shopping-cart/cart-item-edit/cart-item-edit-parameter.interface.ts b/imxweb/projects/qer/src/lib/shopping-cart/cart-item-edit/cart-item-edit-parameter.interface.ts
index b561037fd..f8c572667 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart/cart-item-edit/cart-item-edit-parameter.interface.ts
+++ b/imxweb/projects/qer/src/lib/shopping-cart/cart-item-edit/cart-item-edit-parameter.interface.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/shopping-cart/cart-item-edit/cart-item-edit.component.spec.ts b/imxweb/projects/qer/src/lib/shopping-cart/cart-item-edit/cart-item-edit.component.spec.ts
index 72be6bd4f..c277926f2 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart/cart-item-edit/cart-item-edit.component.spec.ts
+++ b/imxweb/projects/qer/src/lib/shopping-cart/cart-item-edit/cart-item-edit.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -45,6 +45,7 @@ describe('CartItemEditComponent', () => {
const defaultColumnNames = [
'OrderReason',
+ 'UID_QERJustificationOrder',
'PWOPriority',
extendedColumnNames[0],
'ValidUntil',
@@ -65,6 +66,7 @@ describe('CartItemEditComponent', () => {
cartitem['PWOPriority'].value = 1;
cartitem['OrderReason'].value = 'No reason';
cartitem['RequestType'].value = 'request';
+ cartitem['UID_QERJustificationOrder'].value = 'uidKistification';
return cartitem;
}
@@ -126,11 +128,11 @@ describe('CartItemEditComponent', () => {
});
it('should init the correct columns', () => {
- expect(component.columns.length).toEqual(5);
+ expect(component.columns.length).toEqual(6);
expect(component.columns[0].ColumnName).toEqual(extendedColumnNames[0]);
expect(component.columns[1].ColumnName).toEqual(extendedColumnNames[1]);
expect(component.columns[2].ColumnName).toEqual(defaultColumnNames[0]);
expect(component.columns[3].ColumnName).toEqual(defaultColumnNames[1]);
- expect(component.columns[4].ColumnName).toEqual(defaultColumnNames[3]);
+ expect(component.columns[4].ColumnName).toEqual(defaultColumnNames[2]);
});
});
diff --git a/imxweb/projects/qer/src/lib/shopping-cart/cart-item-edit/cart-item-edit.component.ts b/imxweb/projects/qer/src/lib/shopping-cart/cart-item-edit/cart-item-edit.component.ts
index 84afb34c7..70cee8951 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart/cart-item-edit/cart-item-edit.component.ts
+++ b/imxweb/projects/qer/src/lib/shopping-cart/cart-item-edit/cart-item-edit.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -52,6 +52,7 @@ export class CartItemEditComponent {
const defaultColumns = [
this.shoppingCartItem.OrderReason.Column,
+ this.shoppingCartItem.UID_QERJustificationOrder.Column,
this.shoppingCartItem.PWOPriority.Column
];
diff --git a/imxweb/projects/qer/src/lib/shopping-cart/cart-item-edit/cart-item-fk.service.spec.ts b/imxweb/projects/qer/src/lib/shopping-cart/cart-item-edit/cart-item-fk.service.spec.ts
index e47a10b2b..e10df29bc 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart/cart-item-edit/cart-item-fk.service.spec.ts
+++ b/imxweb/projects/qer/src/lib/shopping-cart/cart-item-edit/cart-item-fk.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/shopping-cart/cart-item-edit/cart-item-fk.service.ts b/imxweb/projects/qer/src/lib/shopping-cart/cart-item-edit/cart-item-fk.service.ts
index e870605bc..a825d78fb 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart/cart-item-edit/cart-item-fk.service.ts
+++ b/imxweb/projects/qer/src/lib/shopping-cart/cart-item-edit/cart-item-fk.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -74,20 +74,14 @@ export class CartItemFkService {
return this.qerClient.client.portal_cartitem_interactive_parameter_candidates_post(
columnName,
fkTableName,
- parameters.OrderBy,
- parameters.StartIndex,
- parameters.PageSize,
- parameters.filter,
- null,
- parameters.search,
- parameters.ParentKey,
- interactiveEntity.InteractiveEntityWriteData
+ interactiveEntity.InteractiveEntityWriteData,
+ parameters
);
},
getDataModel: async () => ({}),
- getFilterTree: async (entity, parentkey) => {
- return this.qerClient.client.portal_itshop_requests_parameter_candidates_filtertree_post(
- columnName, fkTableName, undefined, parentkey, entity.GetDiffData()
+ getFilterTree: async (__, parentkey) => {
+ return this.qerClient.client.portal_cartitem_interactive_parameter_candidates_filtertree_post(
+ columnName, fkTableName, interactiveEntity.InteractiveEntityWriteData, { parentkey: parentkey }
);
}
};
diff --git a/imxweb/projects/qer/src/lib/shopping-cart/cart-item-edit/cart-item-interactive.service.spec.ts b/imxweb/projects/qer/src/lib/shopping-cart/cart-item-edit/cart-item-interactive.service.spec.ts
index be88b72c7..399aa341e 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart/cart-item-edit/cart-item-interactive.service.spec.ts
+++ b/imxweb/projects/qer/src/lib/shopping-cart/cart-item-edit/cart-item-interactive.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -77,7 +77,7 @@ describe('CartItemInteractiveService', () => {
const apiService = {
typedClient: {
PortalCartitemInteractive: portalCartitemInteractiveMethod,
- PortalCartitemInteractive_byid: portalCartitemInteractiveMethod}
+ PortalCartiteminteractive: portalCartitemInteractiveMethod}
};
const parameterDataService = new class {
diff --git a/imxweb/projects/qer/src/lib/shopping-cart/cart-item-edit/cart-item-interactive.service.ts b/imxweb/projects/qer/src/lib/shopping-cart/cart-item-edit/cart-item-interactive.service.ts
index 369575a95..5d7b9220a 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart/cart-item-edit/cart-item-interactive.service.ts
+++ b/imxweb/projects/qer/src/lib/shopping-cart/cart-item-edit/cart-item-interactive.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -44,7 +44,7 @@ export class CartItemInteractiveService {
) { }
public async getExtendedEntity(entityReference: string): Promise> {
- const collection = await this.qerClient.typedClient.PortalCartitemInteractive_byid.Get_byid(entityReference);
+ const collection = await this.qerClient.typedClient.PortalCartitemInteractive.Get_byid(entityReference);
const index = 0;
diff --git a/imxweb/projects/qer/src/lib/shopping-cart/cart-item-edit/order-for-additional-users.component.spec.ts b/imxweb/projects/qer/src/lib/shopping-cart/cart-item-edit/order-for-additional-users.component.spec.ts
index ce2e12c7d..45db8f319 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart/cart-item-edit/order-for-additional-users.component.spec.ts
+++ b/imxweb/projects/qer/src/lib/shopping-cart/cart-item-edit/order-for-additional-users.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/shopping-cart/cart-item-edit/order-for-additional-users.component.ts b/imxweb/projects/qer/src/lib/shopping-cart/cart-item-edit/order-for-additional-users.component.ts
index 1576450c6..5ecd73ce7 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart/cart-item-edit/order-for-additional-users.component.ts
+++ b/imxweb/projects/qer/src/lib/shopping-cart/cart-item-edit/order-for-additional-users.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/shopping-cart/cart-item-edit/request-parameters.service.spec.ts b/imxweb/projects/qer/src/lib/shopping-cart/cart-item-edit/request-parameters.service.spec.ts
index ba99b35be..a1e54abb9 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart/cart-item-edit/request-parameters.service.spec.ts
+++ b/imxweb/projects/qer/src/lib/shopping-cart/cart-item-edit/request-parameters.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/shopping-cart/cart-item-edit/request-parameters.service.ts b/imxweb/projects/qer/src/lib/shopping-cart/cart-item-edit/request-parameters.service.ts
index 88f0b1a78..c45b1f733 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart/cart-item-edit/request-parameters.service.ts
+++ b/imxweb/projects/qer/src/lib/shopping-cart/cart-item-edit/request-parameters.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/shopping-cart/cart-item-validation-overview/cart-item-validation-overview.component.scss b/imxweb/projects/qer/src/lib/shopping-cart/cart-item-validation-overview/cart-item-validation-overview.component.scss
index ac7cd41a7..a90850e1c 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart/cart-item-validation-overview/cart-item-validation-overview.component.scss
+++ b/imxweb/projects/qer/src/lib/shopping-cart/cart-item-validation-overview/cart-item-validation-overview.component.scss
@@ -1,4 +1,4 @@
-@import "~@elemental-ui/core/src/styles/_palette.scss";
+@import "@elemental-ui/core/src/styles/_palette.scss";
.mat-list .mat-list-item .mat-line {
word-wrap: break-word;
diff --git a/imxweb/projects/qer/src/lib/shopping-cart/cart-item-validation-overview/cart-item-validation-overview.component.spec.ts b/imxweb/projects/qer/src/lib/shopping-cart/cart-item-validation-overview/cart-item-validation-overview.component.spec.ts
index 730a8f031..ba400192a 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart/cart-item-validation-overview/cart-item-validation-overview.component.spec.ts
+++ b/imxweb/projects/qer/src/lib/shopping-cart/cart-item-validation-overview/cart-item-validation-overview.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/shopping-cart/cart-item-validation-overview/cart-item-validation-overview.component.ts b/imxweb/projects/qer/src/lib/shopping-cart/cart-item-validation-overview/cart-item-validation-overview.component.ts
index c665b6dd8..1e4c2148c 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart/cart-item-validation-overview/cart-item-validation-overview.component.ts
+++ b/imxweb/projects/qer/src/lib/shopping-cart/cart-item-validation-overview/cart-item-validation-overview.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/shopping-cart/cart-item-validation-overview/cart-item-validation-result.interface.ts b/imxweb/projects/qer/src/lib/shopping-cart/cart-item-validation-overview/cart-item-validation-result.interface.ts
index 98622cfb7..5e3b1ed31 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart/cart-item-validation-overview/cart-item-validation-result.interface.ts
+++ b/imxweb/projects/qer/src/lib/shopping-cart/cart-item-validation-overview/cart-item-validation-result.interface.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/shopping-cart/cart-items.service.spec.ts b/imxweb/projects/qer/src/lib/shopping-cart/cart-items.service.spec.ts
index b97fa3206..64693f4f1 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart/cart-items.service.spec.ts
+++ b/imxweb/projects/qer/src/lib/shopping-cart/cart-items.service.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -32,7 +32,7 @@ import { LoggerTestingModule } from 'ngx-logger/testing';
import { of } from 'rxjs';
import { CartItemsService } from './cart-items.service';
-import { CheckMode, PortalCartitem } from 'imx-api-qer';
+import { CheckMode, PortalCartitem, RequestableProductForPerson } from 'imx-api-qer';
import { TypedEntity } from 'imx-qbm-dbts';
import { QerApiService } from '../qer-api-client.service';
import { ParameterDataService } from '../parameter-data/parameter-data.service';
@@ -95,19 +95,19 @@ describe('CartItemsService', () => {
this.items = this.items.filter(item => itemWithDescendants.find(child => child.key === item.key) == null);
}
- move(key: string, toCart: boolean): void {
+ move(key: string, opts: { tocart: boolean }): void {
const itemWithDescendants = this.withDescendants(this.getItem(key));
this.items.forEach(item => {
if (itemWithDescendants.find(child => child.key === item.key)) {
- if (toCart && item.cartKey) {
+ if (opts?.tocart && item.cartKey) {
throw Error('item with key ' + key + ' already in cart');
}
- if (!toCart && item.cartKey == null) {
+ if (!opts?.tocart && item.cartKey == null) {
throw Error('item with key ' + key + ' already in for later list');
}
- item.cartKey = toCart ? this.someCartKey : undefined;
+ item.cartKey = opts?.tocart ? this.someCartKey : undefined;
}
});
}
@@ -163,8 +163,8 @@ describe('CartItemsService', () => {
return Promise.resolve();
}),
portal_cartitem_move_post: jasmine.createSpy('portal_cartitem_move_post').and.
- callFake((uid: string, toCart: boolean) => {
- fakeServer.move(uid, toCart);
+ callFake((uid: string, opts: { tocart: boolean }) => {
+ fakeServer.move(uid, opts);
return Promise.resolve({});
}),
portal_cart_submit_post: jasmine.createSpy('portal_cart_submit_post').and.returnValue(Promise.resolve(mockCheck))
@@ -284,14 +284,14 @@ describe('CartItemsService', () => {
});
it('has an add method', async () => {
- const serviceItem = {
- UID_AccProduct: 'p1',
+ const serviceItem: RequestableProductForPerson = {
+ UidAccProduct: 'p1',
UidPerson: 'a',
UidITShopOrg: 'shelf1',
};
- const serviceItemChild = {
- UID_AccProduct: 'p2',
+ const serviceItemChild: RequestableProductForPerson = {
+ UidAccProduct: 'p2',
UidPerson: 'a',
UidITShopOrg: 'shelf1',
};
@@ -303,6 +303,49 @@ describe('CartItemsService', () => {
expect(qerApiStub.typedClient.PortalCartitem.Post).toHaveBeenCalledTimes(items.length);
});
+ // TODO: Revist when cart has been restructured
+ // it ('sorts children to back items', async () => {
+ // const serviceItem: RequestableProductForPerson = {
+ // UidAccProduct: 'p1',
+ // UidPerson: 'a',
+ // UidITShopOrg: 'shelf1',
+ // UidAccProductParent: 'p2'
+ // };
+
+ // const serviceItemChild: RequestableProductForPerson = {
+ // UidAccProduct: 'p2',
+ // UidPerson: 'a',
+ // UidITShopOrg: 'shelf1',
+ // };
+
+ // spyOn(service, 'editItems');
+ // const items = [serviceItem, serviceItemChild];
+ // await service.addItems(items);
+ // expect(qerApiStub.typedClient.PortalCartitem.createEntity).toHaveBeenCalledTimes(items.length);
+ // expect(qerApiStub.typedClient.PortalCartitem.Post).toHaveBeenCalledTimes(items.length);
+ // });
+
+ // it ('should abort since the parent is not here', async () => {
+ // const serviceItem: RequestableProductForPerson = {
+ // UidAccProduct: 'p1',
+ // UidPerson: 'a',
+ // UidITShopOrg: 'shelf1',
+ // UidAccProductParent: 'not here'
+ // };
+
+ // const serviceItemChild: RequestableProductForPerson = {
+ // UidAccProduct: 'p2',
+ // UidPerson: 'a',
+ // UidITShopOrg: 'shelf1',
+ // };
+
+ // spyOn(service, 'editItems');
+ // const items = [serviceItem, serviceItemChild];
+ // await service.addItems(items);
+ // expect(errorHandlerStub.handleError).toHaveBeenCalled();
+ // expect(qerApiStub.typedClient.PortalCartitem.createEntity).toHaveBeenCalledTimes(0);
+ // expect(qerApiStub.typedClient.PortalCartitem.Post).toHaveBeenCalledTimes(0);
+ // });
[
{ doSave: true },
diff --git a/imxweb/projects/qer/src/lib/shopping-cart/cart-items.service.ts b/imxweb/projects/qer/src/lib/shopping-cart/cart-items.service.ts
index 2a2ad4ae5..adaea5779 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart/cart-items.service.ts
+++ b/imxweb/projects/qer/src/lib/shopping-cart/cart-items.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -27,16 +27,14 @@
import { Injectable, ErrorHandler } from '@angular/core';
import { EuiLoadingService } from '@elemental-ui/core';
+import { FilterData, ExtendedTypedEntityCollection, CompareOperator, FilterType, EntitySchema, TypedEntity } from 'imx-qbm-dbts';
import {
- FilterData,
- ExtendedTypedEntityCollection,
- CompareOperator,
- FilterType,
- EntitySchema,
- TypedEntity
-} from 'imx-qbm-dbts';
-import {
- CartCheckResult, CheckMode, PortalCartitem, RequestableProductForPerson, CartItemDataRead, PortalCartitemInteractive
+ CartCheckResult,
+ CheckMode,
+ PortalCartitem,
+ RequestableProductForPerson,
+ CartItemDataRead,
+ PortalCartitemInteractive,
} from 'imx-api-qer';
import { BulkItemStatus, ClassloggerService } from 'qbm';
import { QerApiService } from '../qer-api-client.service';
@@ -47,7 +45,6 @@ import { CartItemInteractiveService } from './cart-item-edit/cart-item-interacti
@Injectable()
export class CartItemsService {
-
public get PortalCartitemSchema(): EntitySchema {
return this.qerClient.typedClient.PortalCartitem.GetSchema();
}
@@ -59,89 +56,129 @@ export class CartItemsService {
private readonly itemEditService: ItemEditService,
private readonly parameterDataService: ParameterDataService,
private readonly cartItemInteractive: CartItemInteractiveService
- ) { }
+ ) {}
public async getItemsForCart(uidShoppingCart?: string): Promise> {
- return this.get([{
- CompareOp: CompareOperator.Equal,
- Type: FilterType.Compare,
- ColumnName: 'UID_ShoppingCartOrder',
- Value1: uidShoppingCart
- }]);
+ return this.get([
+ {
+ CompareOp: CompareOperator.Equal,
+ Type: FilterType.Compare,
+ ColumnName: 'UID_ShoppingCartOrder',
+ Value1: uidShoppingCart,
+ },
+ ]);
}
public async addItemsFromRoles(objectKeyMemberships: string[], recipients: string[]): Promise {
- return Promise.all(objectKeyMemberships.map(async key =>
- Promise.all(recipients.map(async recipient => {
- const cartItem = this.qerClient.typedClient.PortalCartitem.createEntity();
- cartItem.RoleMembership.value = key;
- cartItem.UID_PersonOrdered.value = recipient;
- await this.qerClient.typedClient.PortalCartitem.Post(cartItem);
- }))
- ));
+ return Promise.all(
+ objectKeyMemberships.map(async (key) =>
+ Promise.all(
+ recipients.map(async (recipient) => {
+ const cartItem = this.qerClient.typedClient.PortalCartitem.createEntity();
+ cartItem.RoleMembership.value = key;
+ cartItem.UID_PersonOrdered.value = recipient;
+ await this.qerClient.typedClient.PortalCartitem.Post(cartItem);
+ })
+ )
+ )
+ );
}
- public async addItems(requestableServiceItemsForPersons: RequestableProductForPerson[]): Promise {
- // TODO for later: Show product-specific editors, if any
+ public async createAndPost(
+ requestableServiceItemForPerson: RequestableProductForPerson,
+ parentCartUid: string
+ ): Promise> {
+ const cartItem = this.qerClient.typedClient.PortalCartitem.createEntity();
+ cartItem.UID_PersonOrdered.value = requestableServiceItemForPerson.UidPerson;
+ cartItem.UID_ITShopOrg.value = requestableServiceItemForPerson.UidITShopOrg;
+ if (parentCartUid) {
+ cartItem.UID_ShoppingCartItemParent.value = parentCartUid;
+ }
+ cartItem.reload = true;
+ return this.qerClient.typedClient.PortalCartitem.Post(cartItem);
+ }
- const addedItems: { [uidAccProduct: string]: PortalCartitem } = {};
+ public async addItems(requestableServiceItemsForPersons: RequestableProductForPerson[]): Promise {
+ const addedItems: PortalCartitem[] = [];
const cartitemReferences: string[] = [];
const cartItemsWithoutParams: PortalCartitem[] = [];
- for (const requestableServiceItemForPerson of requestableServiceItemsForPersons) {
- const cartItem = this.qerClient.typedClient.PortalCartitem.createEntity();
- cartItem.UID_PersonOrdered.value = requestableServiceItemForPerson.UidPerson;
- cartItem.UID_ITShopOrg.value = requestableServiceItemForPerson.UidITShopOrg;
- if (requestableServiceItemForPerson.UidAccProductParent) {
- const cartItemParent = addedItems[requestableServiceItemForPerson.UidAccProductParent];
- if (cartItemParent) {
- cartItem.UID_ShoppingCartItemParent.value = cartItemParent.GetEntity().GetKeys()[0];
- } else {
- throw new Error('Cart item parent for optional cart item not found');
+ const sortedRequestables: RequestableProductForPerson[] = [];
+ const sortedUids: string[] = [];
+ // We need to order the items such that we can order them sequentially
+ let error: Error;
+ let result = 0;
+ while (sortedRequestables.length < requestableServiceItemsForPersons.length && !error) {
+ const preLength = sortedRequestables.length;
+ requestableServiceItemsForPersons.map((requestable) => {
+ const uidProdAndPerson = requestable.UidAccProduct + requestable.UidPerson;
+ const uidParentAndPerson = requestable?.UidAccProductParent + requestable.UidPerson;
+ if (!requestable?.UidAccProductParent || sortedUids.includes(uidParentAndPerson)) {
+ sortedRequestables.push(requestable);
+ sortedUids.push(uidProdAndPerson);
}
+ });
+ const postLength = sortedRequestables.length;
+ if (preLength === postLength) {
+ error = new Error('The items could not be added to the cart.');
+ this.logger.error(this, 'addItems entered an endless loop.');
}
+ result = result + 1;
+ }
+ if (error) {
+ this.errorHandler.handleError(error);
+ return result;
+ }
- // TODO: this call does not work yet. await cartItem.GetEntity().Commit(true);
- cartItem.reload = true;
- const cartItemCollection = await this.qerClient.typedClient.PortalCartitem.Post(cartItem);
-
- if (cartItemCollection && cartItemCollection.Data) {
- const index = 0;
+ for await (const requestable of sortedRequestables) {
+ let parentCartUid: string;
+ if (requestable?.UidAccProductParent) {
+ const uidParentAndPerson = requestable.UidAccProductParent + requestable.UidPerson;
+ const index = sortedUids.findIndex((uid) => uid === uidParentAndPerson);
+ parentCartUid = this.getKey(addedItems[index]);
+ }
+ const cartItemCollection = await this.createAndPost(requestable, parentCartUid);
- const hasParameters = this.parameterDataService.hasParameters({
+ addedItems.push(cartItemCollection.Data[0]);
+ // TODO: this call does not work yet. await cartItem.GetEntity().Commit(true);
+ if (
+ this.parameterDataService.hasParameters({
Parameters: cartItemCollection.extendedData?.Parameters,
- index
- });
-
- if (hasParameters) {
- cartitemReferences.push(cartItemCollection.Data[index].GetEntity().GetKeys().join(''));
- } else {
- cartItemsWithoutParams.push(cartItemCollection.Data[index]);
- }
+ index: 0,
+ })
+ ) {
+ cartitemReferences.push(this.getKey(cartItemCollection.Data[0]));
+ } else {
+ cartItemsWithoutParams.push(cartItemCollection.Data[0]);
}
}
- let result = false;
if (cartitemReferences.length > 0) {
result = await this.editItems(cartitemReferences, cartItemsWithoutParams);
return result;
} else {
- return requestableServiceItemsForPersons.length > 0;
+ return requestableServiceItemsForPersons.length;
}
}
public async removeItems(cartItems: PortalCartitem[], filter?: (cartItem: PortalCartitem) => boolean): Promise {
- for (const cartItem of cartItems) {
- if (filter == null || filter(cartItem)) {
- try {
- await this.qerClient.client.portal_cartitem_delete(cartItem.GetEntity().GetKeys()[0]);
- this.logger.trace(this, 'cart item removed:', cartItem);
- } catch (error) {
- this.errorHandler.handleError(error);
- this.logger.trace(this, 'cart item not removed:', cartItem);
+ await Promise.all(
+ cartItems.map(async (cartItem) => {
+ if (filter == null || filter(cartItem)) {
+ try {
+ await this.qerClient.client.portal_cartitem_delete(cartItem.GetEntity().GetKeys()[0]);
+ this.logger.trace(this, 'cart item removed:', cartItem);
+ } catch (error) {
+ this.errorHandler.handleError(error);
+ this.logger.trace(this, 'cart item not removed:', cartItem);
+ }
}
- }
- }
+ })
+ );
+ }
+
+ public getKey(item: PortalCartitem): string {
+ return item.GetEntity().GetKeys()[0];
}
public async submit(uidCart: string, mode: CheckMode): Promise {
@@ -180,35 +217,38 @@ export class CartItemsService {
}
private async moveItems(cartItems: PortalCartitem[], toCart: boolean): Promise {
- for (const cartItem of cartItems) {
- if (cartItem.UID_ShoppingCartItemParent.value == null || cartItem.UID_ShoppingCartItemParent.value.length === 0) {
- try {
- await this.qerClient.client.portal_cartitem_move_post(cartItem.GetEntity().GetKeys()[0], toCart);
- this.logger.trace(this, 'cart item moved to cart=' + toCart, cartItem);
- } catch (error) {
- this.errorHandler.handleError(error);
- this.logger.trace(this, 'cart item not moved to cart=' + toCart, cartItem);
+ await Promise.all(
+ cartItems.map(async (cartItem) => {
+ if (cartItem.UID_ShoppingCartItemParent.value == null || cartItem.UID_ShoppingCartItemParent.value.length === 0) {
+ try {
+ await this.qerClient.client.portal_cartitem_move_post(cartItem.GetEntity().GetKeys()[0], { tocart: toCart });
+ this.logger.trace(this, 'cart item moved to cart=' + toCart, cartItem);
+ } catch (error) {
+ this.errorHandler.handleError(error);
+ this.logger.trace(this, 'cart item not moved to cart=' + toCart, cartItem);
+ }
}
- }
- }
+ })
+ );
}
- private async editItems(entityReferences: string[], cartItemsWithoutParams: PortalCartitem[]): Promise {
+ private async editItems(entityReferences: string[], cartItemsWithoutParams: PortalCartitem[]): Promise {
setTimeout(() => this.busyIndicator.hide());
- const cartItems = await Promise.all(entityReferences.map(entityReference =>
- this.getInteractiveCartitem(entityReference)
- ));
+ let result = entityReferences.length + cartItemsWithoutParams.length;
+
+ const cartItems = await Promise.all(entityReferences.map((entityReference) => this.getInteractiveCartitem(entityReference)));
const results = await this.itemEditService.openEditor(cartItems);
for (const item of results.bulkItems) {
try {
- const found = cartItems.find(x => x.typedEntity.GetEntity().GetKeys()[0] === item.entity.GetEntity().GetKeys()[0]);
+ const found = cartItems.find((x) => x.typedEntity.GetEntity().GetKeys()[0] === item.entity.GetEntity().GetKeys()[0]);
if (item.status === BulkItemStatus.saved) {
await this.save(found);
this.logger.debug(this, `${found.typedEntity.GetEntity().GetDisplay} saved`);
} else {
await this.removeItems([found.typedEntity]);
+ result = result - 1;
this.logger.debug(this, `${found.typedEntity.GetEntity().GetDisplay} removed`);
}
} catch (e) {
@@ -217,10 +257,14 @@ export class CartItemsService {
}
if (!results.submit) {
- this.logger.debug(this, `The user aborts this "add to cart"-action. So we have to delete all cartitems without params from shopping cart too.`);
+ this.logger.debug(
+ this,
+ `The user aborts this "add to cart"-action. So we have to delete all cartitems without params from shopping cart too.`
+ );
await this.removeItems(cartItemsWithoutParams);
+ result = result - cartItemsWithoutParams.length;
}
- return results.submit;
+ return result;
}
}
diff --git a/imxweb/projects/qer/src/lib/shopping-cart/cart-items/cart-item-check-status.enum.ts b/imxweb/projects/qer/src/lib/shopping-cart/cart-items/cart-item-check-status.enum.ts
index 1e4453b27..fc1184c28 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart/cart-items/cart-item-check-status.enum.ts
+++ b/imxweb/projects/qer/src/lib/shopping-cart/cart-items/cart-item-check-status.enum.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/shopping-cart/cart-items/cart-item-display.component.ts b/imxweb/projects/qer/src/lib/shopping-cart/cart-items/cart-item-display.component.ts
index 4ce59fed6..eb21a38aa 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart/cart-items/cart-item-display.component.ts
+++ b/imxweb/projects/qer/src/lib/shopping-cart/cart-items/cart-item-display.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/shopping-cart/cart-items/cart-item-logic.interface.ts b/imxweb/projects/qer/src/lib/shopping-cart/cart-items/cart-item-logic.interface.ts
index e527691a6..6469ccd5f 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart/cart-items/cart-item-logic.interface.ts
+++ b/imxweb/projects/qer/src/lib/shopping-cart/cart-items/cart-item-logic.interface.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/shopping-cart/cart-items/cart-item-logic.service.ts b/imxweb/projects/qer/src/lib/shopping-cart/cart-items/cart-item-logic.service.ts
index 15699fc5d..0b8758b40 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart/cart-items/cart-item-logic.service.ts
+++ b/imxweb/projects/qer/src/lib/shopping-cart/cart-items/cart-item-logic.service.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/shopping-cart/cart-items/cart-item-validation-status.enum.ts b/imxweb/projects/qer/src/lib/shopping-cart/cart-items/cart-item-validation-status.enum.ts
index 9ad8d4996..b330c9209 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart/cart-items/cart-item-validation-status.enum.ts
+++ b/imxweb/projects/qer/src/lib/shopping-cart/cart-items/cart-item-validation-status.enum.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/shopping-cart/cart-items/cart-items.component.html b/imxweb/projects/qer/src/lib/shopping-cart/cart-items/cart-items.component.html
index 6e0dc9950..5520e304c 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart/cart-items/cart-items.component.html
+++ b/imxweb/projects/qer/src/lib/shopping-cart/cart-items/cart-items.component.html
@@ -56,7 +56,7 @@
-
diff --git a/imxweb/projects/qer/src/lib/shopping-cart/cart-items/cart-items.component.scss b/imxweb/projects/qer/src/lib/shopping-cart/cart-items/cart-items.component.scss
index fe3a0200b..4766fc328 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart/cart-items/cart-items.component.scss
+++ b/imxweb/projects/qer/src/lib/shopping-cart/cart-items/cart-items.component.scss
@@ -1,4 +1,4 @@
-@import '~@elemental-ui/core/src/styles/_palette.scss';
+@import '@elemental-ui/core/src/styles/_palette.scss';
:host {
margin: 10px;
diff --git a/imxweb/projects/qer/src/lib/shopping-cart/cart-items/cart-items.component.spec.ts b/imxweb/projects/qer/src/lib/shopping-cart/cart-items/cart-items.component.spec.ts
index 2844d07db..a7e56aad0 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart/cart-items/cart-items.component.spec.ts
+++ b/imxweb/projects/qer/src/lib/shopping-cart/cart-items/cart-items.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/shopping-cart/cart-items/cart-items.component.ts b/imxweb/projects/qer/src/lib/shopping-cart/cart-items/cart-items.component.ts
index e55e1459c..2ebb9fe4a 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart/cart-items/cart-items.component.ts
+++ b/imxweb/projects/qer/src/lib/shopping-cart/cart-items/cart-items.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -36,7 +36,8 @@ import {
SnackBarService,
ClassloggerService,
DataTableComponent,
- ConfirmationService
+ ConfirmationService,
+ ClientPropertyForTableColumns
} from 'qbm';
import { DisplayColumns, EntitySchema, IClientProperty, TypedEntity, ValType } from 'imx-qbm-dbts';
import { CartItemEditComponent } from '../cart-item-edit/cart-item-edit.component';
@@ -57,7 +58,7 @@ export class CartItemsComponent implements OnInit, OnChanges {
public removeButtonLabel = '';
public readonly entitySchema: EntitySchema;
public DisplayColumns = DisplayColumns;
- public displayedColumns: IClientProperty[];
+ public displayedColumns: ClientPropertyForTableColumns[];
public readonly itemStatus = {
enabled: (cartItem: PortalCartitem): boolean => {
@@ -96,7 +97,8 @@ export class CartItemsComponent implements OnInit, OnChanges {
this.entitySchema.Columns[DisplayColumns.DISPLAY_LONG_PROPERTYNAME],
{
ColumnName: 'removeItemButton',
- Type: ValType.String
+ Type: ValType.String,
+ afterAdditionals: true
}
];
diff --git a/imxweb/projects/qer/src/lib/shopping-cart/cart-items/default-cart-item-display.component.scss b/imxweb/projects/qer/src/lib/shopping-cart/cart-items/default-cart-item-display.component.scss
index 788c925dc..b4a16aed3 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart/cart-items/default-cart-item-display.component.scss
+++ b/imxweb/projects/qer/src/lib/shopping-cart/cart-items/default-cart-item-display.component.scss
@@ -1 +1 @@
-@import '~@elemental-ui/core/src/styles/_palette.scss';
+@import '@elemental-ui/core/src/styles/_palette.scss';
diff --git a/imxweb/projects/qer/src/lib/shopping-cart/cart-items/default-cart-item-display.component.ts b/imxweb/projects/qer/src/lib/shopping-cart/cart-items/default-cart-item-display.component.ts
index 6e4952ed1..f44ea60d7 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart/cart-items/default-cart-item-display.component.ts
+++ b/imxweb/projects/qer/src/lib/shopping-cart/cart-items/default-cart-item-display.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/shopping-cart/confirm-cart-submit.dialog.ts b/imxweb/projects/qer/src/lib/shopping-cart/confirm-cart-submit.dialog.ts
index 298a763a1..feecb59d9 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart/confirm-cart-submit.dialog.ts
+++ b/imxweb/projects/qer/src/lib/shopping-cart/confirm-cart-submit.dialog.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart-empty.component.scss b/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart-empty.component.scss
index 154b8868f..c10153896 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart-empty.component.scss
+++ b/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart-empty.component.scss
@@ -1,4 +1,4 @@
-@import '~@elemental-ui/core/src/styles/_palette.scss';
+@import '@elemental-ui/core/src/styles/_palette.scss';
:host {
display: flex;
diff --git a/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart-empty.component.ts b/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart-empty.component.ts
index d91182794..476e38a3d 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart-empty.component.ts
+++ b/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart-empty.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart-for-later/shopping-cart-for-later.component.html b/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart-for-later/shopping-cart-for-later.component.html
index 673d2b56e..96a7d57ec 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart-for-later/shopping-cart-for-later.component.html
+++ b/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart-for-later/shopping-cart-for-later.component.html
@@ -2,9 +2,12 @@
{{ '#LDS#Heading Saved for Later' | translate }}
-
+
+
{{ '#LDS#The following requests are currently in your saved for later list. Please use the actions menu to move the requests to the shopping cart.' | translate }}
-
+
+
+
diff --git a/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart-for-later/shopping-cart-for-later.component.scss b/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart-for-later/shopping-cart-for-later.component.scss
index e6b9704eb..99af79952 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart-for-later/shopping-cart-for-later.component.scss
+++ b/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart-for-later/shopping-cart-for-later.component.scss
@@ -1,11 +1,10 @@
-@import '~@elemental-ui/core/src/styles/_palette.scss';
+@import '@elemental-ui/core/src/styles/_palette.scss';
:host {
display: flex;
flex-direction: column;
overflow: hidden;
height: 100%;
- max-width: 1200px;
}
@@ -13,9 +12,7 @@
overflow: hidden;
display: flex;
}
- .imx-itshop-info {
- margin: 0;
- }
+
.imx-itshop-content{
display: flex;
flex-direction: column;
@@ -35,6 +32,7 @@
.imx-toolbar {
display: flex;
justify-content: flex-end;
+ margin-top: 20px;
button {
margin-left: 10px;
diff --git a/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart-for-later/shopping-cart-for-later.component.spec.ts b/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart-for-later/shopping-cart-for-later.component.spec.ts
index f84565ca8..d4e7a6641 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart-for-later/shopping-cart-for-later.component.spec.ts
+++ b/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart-for-later/shopping-cart-for-later.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart-for-later/shopping-cart-for-later.component.ts b/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart-for-later/shopping-cart-for-later.component.ts
index 17fb92546..a339af848 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart-for-later/shopping-cart-for-later.component.ts
+++ b/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart-for-later/shopping-cart-for-later.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart-submit-warnings.dialog.spec.ts b/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart-submit-warnings.dialog.spec.ts
index c268f512c..8380f17da 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart-submit-warnings.dialog.spec.ts
+++ b/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart-submit-warnings.dialog.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -35,7 +35,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart-submit-warnings.dialog.ts b/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart-submit-warnings.dialog.ts
index 0a5dd38c1..1ec83cd7a 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart-submit-warnings.dialog.ts
+++ b/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart-submit-warnings.dialog.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart-validator.spec.ts b/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart-validator.spec.ts
index a490f51d8..0428fdf56 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart-validator.spec.ts
+++ b/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart-validator.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart-validator.ts b/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart-validator.ts
index 461f130df..329874e01 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart-validator.ts
+++ b/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart-validator.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart.component.html b/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart.component.html
index fcee13fad..f4ec45562 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart.component.html
+++ b/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart.component.html
@@ -91,7 +91,7 @@
{{ '#LDS#Heading Shopping Cart' | tran
{{ '#LDS#View saved for later list' | translate }}
-
{{'#LDS#Create request template' | translate}}
diff --git a/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart.component.scss b/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart.component.scss
index 285733af7..58bb12d0c 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart.component.scss
+++ b/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart.component.scss
@@ -1,11 +1,10 @@
-@import "~@elemental-ui/core/src/styles/_palette.scss";
+@import "@elemental-ui/core/src/styles/_palette.scss";
:host {
display: flex;
flex-direction: column;
overflow: hidden;
height: 100%;
- width: 1200px;
max-width: 100%;
}
@@ -59,4 +58,4 @@
.LabelBlock {
display: block;
-}
\ No newline at end of file
+}
diff --git a/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart.component.spec.ts b/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart.component.spec.ts
index 81bc76489..ed5ae5f39 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart.component.spec.ts
+++ b/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart.component.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -34,8 +34,9 @@ import { MatSelectModule } from '@angular/material/select';
import { MatButtonModule } from '@angular/material/button';
import { MatMenuModule } from '@angular/material/menu';
import { MatDividerModule } from '@angular/material/divider';
-import { Component, Input, Output, EventEmitter } from '@angular/core';
-import { EuiCoreModule, EuiLoadingService } from '@elemental-ui/core';
+import { NoopAnimationsModule } from '@angular/platform-browser/animations';
+import { Component, Input, Output, EventEmitter, CUSTOM_ELEMENTS_SCHEMA } from '@angular/core';
+import { EuiCoreModule, EuiLoadingService, EuiSidesheetService } from '@elemental-ui/core';
import { MatDialog } from '@angular/material/dialog';
import { of } from 'rxjs';
@@ -110,10 +111,19 @@ describe('ShoppingCartComponent', () => {
ITShopConfig: {}
};
+ const sidesheetServiceStub = {
+ open: jasmine.createSpy('open').and.returnValue({
+ afterClosed: () => of({})
+ })
+ };
+
let component: ShoppingCartComponent;
let fixture: ComponentFixture;
configureTestSuite(() => {
TestBed.configureTestingModule({
+ schemas: [
+ CUSTOM_ELEMENTS_SCHEMA
+ ],
imports: [
EuiCoreModule,
LoggerTestingModule,
@@ -123,6 +133,7 @@ describe('ShoppingCartComponent', () => {
MatSelectModule,
MatButtonModule,
MatMenuModule,
+ NoopAnimationsModule,
RouterTestingModule.withRoutes(
[
{ path: 'shoppingcart/empty', component: MockEmptyCartComponent },
@@ -179,6 +190,10 @@ describe('ShoppingCartComponent', () => {
{
provide: ItshopService,
useValue: itshopServiceStub
+ },
+ {
+ provide: EuiSidesheetService,
+ useValue: sidesheetServiceStub
}
]
});
diff --git a/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart.component.ts b/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart.component.ts
index ca4ca6802..40ec296e4 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart.component.ts
+++ b/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -24,14 +24,15 @@
*
*/
+import { OverlayRef } from '@angular/cdk/overlay';
import { Component, OnInit, AfterViewInit } from '@angular/core';
import { MatDialog } from '@angular/material/dialog';
import { Router } from '@angular/router';
-import { EuiLoadingService } from '@elemental-ui/core';
+import { EuiLoadingService, EuiSidesheetService } from '@elemental-ui/core';
import { TranslateService } from '@ngx-translate/core';
import { map } from 'rxjs/operators';
-import { PortalItshopCart, CheckMode, ITShopConfig, PortalCartitem } from 'imx-api-qer';
+import { CartCheckResult, CheckMode, ITShopConfig, PortalCartitem, PortalItshopCart, RequestableProductForPerson } from 'imx-api-qer';
import { ClassloggerService, SnackBarService, LdsReplacePipe, ConfirmationService } from 'qbm';
import { UserModelService } from '../user/user-model.service';
import { ProjectConfigurationService } from '../project-configuration/project-configuration.service';
@@ -42,6 +43,8 @@ import { ConfirmCartSubmitDialog } from './confirm-cart-submit.dialog';
import { ShoppingCartSubmitWarningsDialog } from './shopping-cart-submit-warnings.dialog';
import { ShoppingCartValidator } from './shopping-cart-validator';
import { ItshopPatternCreateService } from '../itshop-pattern/itshop-pattern-create-sidesheet/itshop-pattern-create.service';
+import { TermsOfUseAcceptComponent } from '../terms-of-use/terms-of-use-accept.component';
+import { CartItemCheckStatus } from './cart-items/cart-item-check-status.enum';
@Component({
templateUrl: './shopping-cart.component.html',
@@ -54,6 +57,7 @@ export class ShoppingCartComponent implements OnInit, AfterViewInit {
public selectedItshopCart: PortalItshopCart;
public selectedItems: PortalCartitem[];
public isEmpty: boolean;
+ public canCreateRequestTemplates: boolean;
private itshopConfig: ITShopConfig;
@@ -70,11 +74,13 @@ export class ShoppingCartComponent implements OnInit, AfterViewInit {
private readonly projectConfig: ProjectConfigurationService,
private readonly itshopProvider: ItshopService,
private readonly patternCreateService: ItshopPatternCreateService,
- private readonly snackBarService: SnackBarService
+ private readonly snackBarService: SnackBarService,
+ private readonly sideSheet: EuiSidesheetService
) { }
public async ngOnInit(): Promise {
this.itshopConfig = (await this.projectConfig.getConfig()).ITShopConfig;
+ this.canCreateRequestTemplates = this.itshopConfig.VI_ITShop_ProductSelectionFromTemplate;
}
public async ngAfterViewInit(): Promise {
@@ -82,14 +88,14 @@ export class ShoppingCartComponent implements OnInit, AfterViewInit {
}
public async validate(): Promise {
+
+ await this.checkTermsOfUse();
+
+ const result = await this.checkShoppingCart();
let message = '#LDS#An error ocurred';
setTimeout(() => this.busyService.show());
try {
- const uid = this.selectedItshopCart.GetEntity().GetKeys()[0];
- const result = await this.cartItemService.submit(uid, CheckMode.CheckOnly);
- this.logger.debug(this, 'Validation result', result);
-
message = result.HasErrors ? '#LDS#At least one request cannot be submitted.' : '#LDS#Your shopping cart may be submitted.';
await this.getCartItems();
} finally {
@@ -102,13 +108,23 @@ export class ShoppingCartComponent implements OnInit, AfterViewInit {
}
public async createItshopPattern(cartItems?: PortalCartitem[]): Promise {
- if (await this.patternCreateService.createItshopPatternFromShoppingCart(cartItems) > 0) {
+ const cartItemUids = cartItems.map(item => item.UID_AccProduct.value);
+
+ const serviceItemsForPersons = cartItems.map(item => {
+ return {
+ Display: item.GetEntity().GetDisplay(),
+ DisplayRecipient: item.UID_PersonOrdered.Column.GetDisplayValue(),
+ UidITShopOrg: item.UID_ITShopOrg.value,
+ UidAccProduct: item.UID_AccProduct.value
+ } as RequestableProductForPerson;
+ });
+ if ((await this.patternCreateService.assignItemsToPattern(cartItemUids, serviceItemsForPersons)) > 0) {
await this.getData(true);
const snackbarRef = this.snackBarService.open(
{ key: '#LDS#The request template has been successfully created.' },
'#LDS#View my request templates');
- snackbarRef.onAction().subscribe(() => this.router.navigate(['itshop/myrequesttemplates']));
+ snackbarRef.onAction().subscribe(() => this.router.navigate(['itshop/requesttemplates']));
} else {
this.snackBarService.open({ key: '#LDS#The request template could not be created.' });
@@ -144,16 +160,19 @@ export class ShoppingCartComponent implements OnInit, AfterViewInit {
}
public async submitShoppingCart(): Promise {
- setTimeout(() => this.busyService.show());
- try {
- this.logger.debug(this, 'Submit shopping cart. Validating cart...');
- const uid = this.selectedItshopCart.GetEntity().GetKeys()[0];
- const validator = new ShoppingCartValidator(await this.cartItemService.submit(uid, CheckMode.CheckOnly));
+ this.logger.debug(this, 'Submit shopping cart. Check for TermsOfUse...');
+
+ await this.checkTermsOfUse();
- this.logger.debug(this, `Check shopping cart. Validation errors: ${validator.hasErrors}`);
- this.logger.debug(this, `Check shopping cart. Validation warnings: ${validator.hasWarnings}`);
+ this.logger.debug(this, 'Submit shopping cart. Validating cart...')
+ const validator = new ShoppingCartValidator(await this.checkShoppingCart());
+ this.logger.debug(this, `Check shopping cart. Validation errors: ${validator.hasErrors}`);
+ this.logger.debug(this, `Check shopping cart. Validation warnings: ${validator.hasWarnings}`);
+
+ setTimeout(() => this.busyService.show());
+ try {
if (validator.hasErrors) {
this.snackBarService.open(
{ key: '#LDS#At least one request cannot be submitted.' },
@@ -190,7 +209,7 @@ export class ShoppingCartComponent implements OnInit, AfterViewInit {
await this.getCartItems();
return;
}
-
+ const uid = this.selectedItshopCart.GetEntity().GetKeys()[0];
await this.cartItemService.submit(uid, CheckMode.SubmitWithWarnings);
this.snackBarService.open(
@@ -244,6 +263,20 @@ export class ShoppingCartComponent implements OnInit, AfterViewInit {
this.selectedItems = items;
}
+ private async checkShoppingCart(): Promise {
+ let overlayRef: OverlayRef;
+ setTimeout(() => overlayRef = this.busyService.show());
+ try {
+ const uid = this.selectedItshopCart.GetEntity().GetKeys()[0];
+ const result = await this.cartItemService.submit(uid, CheckMode.CheckOnly);
+ this.logger.debug(this, 'Validation result', result);
+ return result;
+ } finally {
+ setTimeout(() => this.busyService.hide(overlayRef));
+ }
+ }
+
+
private async getCartItems(): Promise {
if (this.selectedItshopCart) {
this.logger.debug(this, 'getCartItems - loading...', this.selectedItshopCart.GetEntity().GetDisplay());
@@ -261,4 +294,45 @@ export class ShoppingCartComponent implements OnInit, AfterViewInit {
this.isEmpty = (this.shoppingCart.numberOfItems === 0 &&
(this.shoppingCartCandidates == null || this.shoppingCartCandidates.length <= 1));
}
+
+ private async checkTermsOfUse(): Promise {
+
+ // get all cart items with terms of uses
+ const itemsWithTermsOfUseToAccecpt = this.shoppingCart.getItems(item =>
+ item.UID_QERTermsOfUse?.value !== null
+ && item.UID_QERTermsOfUse?.value !== ''
+ && item.CheckResult?.value !== CartItemCheckStatus.ok
+ );
+
+ if (itemsWithTermsOfUseToAccecpt.length > 0) {
+ this.logger.debug(this,
+ `There are ${itemsWithTermsOfUseToAccecpt.length} service items with terms of use the user have to accepted.`);
+
+ const termsOfUseAccepted = await this.sideSheet.open(TermsOfUseAcceptComponent, {
+ title: await this.translate.get('#LDS#Heading Accept Terms Of Use').toPromise(),
+ headerColour: 'iris-blue',
+ bodyColour: 'asher-gray',
+ padding: '0px',
+ width: 'max(600px, 60%)',
+ data: {
+ acceptCartItems: true,
+ cartItems: itemsWithTermsOfUseToAccecpt,
+ },
+ testId: 'terms-of-use-accept-sidesheet'
+ }).afterClosed().toPromise();
+
+ if (termsOfUseAccepted) {
+ this.logger.debug(this, 'all terms of use were accepted.');
+ return true;
+ } else {
+ this.logger.debug(this, 'at least one terms of use was not accepted.');
+ return false;
+ }
+
+ } else {
+ this.logger.debug(this, 'there are no service items with terms of use the user have to accepted.');
+ return true;
+ }
+ }
}
+
diff --git a/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart.module.ts b/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart.module.ts
index 9e8edb328..6067d4392 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart.module.ts
+++ b/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart.module.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart.spec.ts b/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart.spec.ts
index 97ffc363e..f255d5bc5 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart.spec.ts
+++ b/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart.spec.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart.ts b/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart.ts
index 2dfaedb5e..211c00613 100644
--- a/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart.ts
+++ b/imxweb/projects/qer/src/lib/shopping-cart/shopping-cart.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/sourcedetective/sourcedetective-sidesheet.component.html b/imxweb/projects/qer/src/lib/sourcedetective/sourcedetective-sidesheet.component.html
index 4b6ebdb9b..0b1006930 100644
--- a/imxweb/projects/qer/src/lib/sourcedetective/sourcedetective-sidesheet.component.html
+++ b/imxweb/projects/qer/src/lib/sourcedetective/sourcedetective-sidesheet.component.html
@@ -1 +1,6 @@
-
\ No newline at end of file
+
+
+
+
+
+
\ No newline at end of file
diff --git a/imxweb/projects/qer/src/lib/sourcedetective/sourcedetective-sidesheet.component.ts b/imxweb/projects/qer/src/lib/sourcedetective/sourcedetective-sidesheet.component.ts
index d969fc0ea..8b15c54fd 100644
--- a/imxweb/projects/qer/src/lib/sourcedetective/sourcedetective-sidesheet.component.ts
+++ b/imxweb/projects/qer/src/lib/sourcedetective/sourcedetective-sidesheet.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/sourcedetective/sourcedetective-type.enum.ts b/imxweb/projects/qer/src/lib/sourcedetective/sourcedetective-type.enum.ts
index d219154ad..dfa6776ea 100644
--- a/imxweb/projects/qer/src/lib/sourcedetective/sourcedetective-type.enum.ts
+++ b/imxweb/projects/qer/src/lib/sourcedetective/sourcedetective-type.enum.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/sourcedetective/sourcedetective.component.ts b/imxweb/projects/qer/src/lib/sourcedetective/sourcedetective.component.ts
index c8840443c..922c18156 100644
--- a/imxweb/projects/qer/src/lib/sourcedetective/sourcedetective.component.ts
+++ b/imxweb/projects/qer/src/lib/sourcedetective/sourcedetective.component.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
diff --git a/imxweb/projects/qer/src/lib/sourcedetective/sourcedetective.module.ts b/imxweb/projects/qer/src/lib/sourcedetective/sourcedetective.module.ts
index 99fa6fa88..efce66d54 100644
--- a/imxweb/projects/qer/src/lib/sourcedetective/sourcedetective.module.ts
+++ b/imxweb/projects/qer/src/lib/sourcedetective/sourcedetective.module.ts
@@ -9,7 +9,7 @@
* those terms.
*
*
- * Copyright 2021 One Identity LLC.
+ * Copyright 2022 One Identity LLC.
* ALL RIGHTS RESERVED.
*
* ONE IDENTITY LLC. MAKES NO REPRESENTATIONS OR
@@ -31,13 +31,14 @@ import { TranslateModule } from '@ngx-translate/core';
import { BrowserAnimationsModule } from '@angular/platform-browser/animations';
import { MatTreeModule } from '@angular/material/tree';
import { MatIconModule } from '@angular/material/icon';
+import { MatTooltipModule } from '@angular/material/tooltip';
+import { MatCardModule } from '@angular/material/card';
+import { EuiCoreModule, EuiMaterialModule } from '@elemental-ui/core';
import { QbmModule, LdsReplaceModule, ParameterizedTextModule } from 'qbm';
import { SourceDetectiveComponent } from './sourcedetective.component';
-import { EuiCoreModule, EuiMaterialModule } from '@elemental-ui/core';
import { SourceDetectiveSidesheetComponent } from './sourcedetective-sidesheet.component';
import { RequestHistoryModule } from '../request-history/request-history.module';
-import { MatTooltipModule } from '@angular/material/tooltip';
@NgModule({
declarations: [
@@ -57,7 +58,8 @@ import { MatTooltipModule } from '@angular/material/tooltip';
MatTreeModule,
TranslateModule,
ParameterizedTextModule,
- RequestHistoryModule
+ RequestHistoryModule,
+ MatCardModule
],
exports: [
SourceDetectiveComponent
diff --git a/imxweb/projects/qer/src/lib/starling/starling.component.html b/imxweb/projects/qer/src/lib/starling/starling.component.html
deleted file mode 100644
index 8281b4701..000000000
--- a/imxweb/projects/qer/src/lib/starling/starling.component.html
+++ /dev/null
@@ -1,34 +0,0 @@
-
-
#LDS#Authenticate using Starling 2FA
-
-
-
{{errorMessage}}
-
-
- {{ '#LDS#Log out' | translate }}
-
-
-
-
#LDS#Request a token from the Starling 2FA app. If you do not have the app, request a token via SMS or phone call.