RED-4590: Fixed some sonar cube issues
This commit is contained in:
parent
dff0b26fe6
commit
fa4e3e79d5
@ -1,7 +1,7 @@
|
||||
import { ChangeDetectionStrategy, Component, Input, OnInit } from '@angular/core';
|
||||
import { UntypedFormBuilder, Validators } from '@angular/forms';
|
||||
import { BaseSignatureConfigurationComponent } from '../base-signature-configuration-component';
|
||||
import { IKmsDigitalSignature, IKmsDigitalSignatureRequest, DigitalSignatureOptions } from '@red/domain';
|
||||
import { DigitalSignatureOptions, IKmsDigitalSignature, IKmsDigitalSignatureRequest } from '@red/domain';
|
||||
import { firstValueFrom } from 'rxjs';
|
||||
import { DigitalSignatureService } from '../../../../services/digital-signature.service';
|
||||
|
||||
@ -51,7 +51,7 @@ export class KmsSignatureConfigurationComponent extends BaseSignatureConfigurati
|
||||
const digitalSignature: IKmsDigitalSignature = { ...formValue };
|
||||
|
||||
if (!this.digitalSignature) {
|
||||
digitalSignature.certificate = window.btoa(<string>digitalSignature.certificate);
|
||||
digitalSignature.certificate = window.btoa(digitalSignature.certificate);
|
||||
}
|
||||
|
||||
return firstValueFrom(this._digitalSignatureService.saveKmsSignature(digitalSignature));
|
||||
|
||||
@ -8,7 +8,6 @@ import { BaseDialogComponent } from '@iqser/common-ui';
|
||||
@Component({
|
||||
selector: 'redaction-smtp-auth-dialog',
|
||||
templateUrl: './smtp-auth-dialog.component.html',
|
||||
styleUrls: ['./smtp-auth-dialog.component.scss'],
|
||||
})
|
||||
export class SmtpAuthDialogComponent extends BaseDialogComponent {
|
||||
readonly #currentUser = getCurrentUser();
|
||||
|
||||
@ -9,7 +9,6 @@ import { firstValueFrom } from 'rxjs';
|
||||
@Component({
|
||||
selector: 'redaction-general-config-form',
|
||||
templateUrl: './general-config-form.component.html',
|
||||
styleUrls: ['./general-config-form.component.scss'],
|
||||
})
|
||||
export class GeneralConfigFormComponent extends BaseFormComponent implements OnInit, OnDestroy {
|
||||
private _initialConfiguration: IGeneralConfiguration;
|
||||
|
||||
@ -10,7 +10,6 @@ import { firstValueFrom } from 'rxjs';
|
||||
@Component({
|
||||
selector: 'redaction-smtp-form',
|
||||
templateUrl: './smtp-form.component.html',
|
||||
styleUrls: ['./smtp-form.component.scss'],
|
||||
})
|
||||
export class SmtpFormComponent extends BaseFormComponent implements OnInit, OnDestroy {
|
||||
readonly iconButtonTypes = IconButtonTypes;
|
||||
|
||||
@ -11,7 +11,6 @@ export type ValueType = 'number' | 'string' | 'boolean';
|
||||
@Component({
|
||||
selector: 'redaction-system-preferences-form',
|
||||
templateUrl: './system-preferences-form.component.html',
|
||||
styleUrls: ['./system-preferences-form.component.scss'],
|
||||
})
|
||||
export class SystemPreferencesFormComponent extends BaseFormComponent {
|
||||
readonly translations = systemPreferencesTranslations;
|
||||
|
||||
@ -8,7 +8,6 @@ import { firstValueFrom } from 'rxjs';
|
||||
|
||||
@Component({
|
||||
templateUrl: './add-edit-justification-dialog.component.html',
|
||||
styleUrls: ['./add-edit-justification-dialog.component.scss'],
|
||||
changeDetection: ChangeDetectionStrategy.OnPush,
|
||||
})
|
||||
export class AddEditJustificationDialogComponent extends BaseDialogComponent {
|
||||
|
||||
@ -8,7 +8,6 @@ import { UserPreferenceService } from '@services/user-preference.service';
|
||||
@Component({
|
||||
selector: 'redaction-table-item',
|
||||
templateUrl: './table-item.component.html',
|
||||
styleUrls: ['./table-item.component.scss'],
|
||||
changeDetection: ChangeDetectionStrategy.OnPush,
|
||||
})
|
||||
export class TableItemComponent {
|
||||
|
||||
@ -96,7 +96,7 @@ export class ComboChartComponent extends BaseChartComponent {
|
||||
|
||||
@Input() xAxisTickFormatting: any;
|
||||
|
||||
trackBy(index, item): string {
|
||||
trackBy(_index, item): string {
|
||||
return item.name;
|
||||
}
|
||||
|
||||
|
||||
@ -229,8 +229,8 @@ export class DictionaryManagerComponent implements OnChanges {
|
||||
return dictionary$.pipe(map(data => this._toString([...data.entries])));
|
||||
}
|
||||
|
||||
private _toString(entries: string[]) {
|
||||
const compareFn = (a, b) => a.localeCompare(b, undefined, { sensitivity: 'accent' });
|
||||
return entries.sort(compareFn).join('\n');
|
||||
private _toString(entries: string[]): string {
|
||||
entries.sort((a, b) => a.localeCompare(b, undefined, { sensitivity: 'accent' }));
|
||||
return entries.join('\n');
|
||||
}
|
||||
}
|
||||
|
||||
@ -1 +1 @@
|
||||
Subproject commit f9ef1003fd3295f5bc4c81ed9be3b77224e7370e
|
||||
Subproject commit dd9e20411be4d2f29cb05e77fe026b081056ce58
|
||||
Loading…
x
Reference in New Issue
Block a user