Fix some styling and compilation errors

This commit is contained in:
George Kalampokis 2023-10-10 12:10:52 +03:00
parent 5c903c0f48
commit 74a6019a72
2 changed files with 3 additions and 3 deletions

View File

@ -1,4 +1,4 @@
import { UntypedFormGroup, Validators } from "@angular/forms";
import { FormGroup, Validators } from "@angular/forms";
import { FieldDataEditorModel } from "./field-data-editor-model";
import { AuthAutoCompleteData, AutoCompleteSingleData } from "@app/core/model/dataset-profile-definition/field-data/field-data";
@ -9,7 +9,7 @@ export class AuthFieldEditorModel extends FieldDataEditorModel<AuthFieldEditorMo
path: string;
type: string;
buildForm(disabled: boolean = false, skipDisable: Array<String> = []): UntypedFormGroup {
buildForm(disabled: boolean = false, skipDisable: Array<String> = []): FormGroup {
const formGroup = this.formBuilder.group({
method: [{ value: this.method, disabled: (disabled && !skipDisable.includes('AuthFieldEditorModel.method')) }],
url: [{ value: this.url, disabled: (disabled && !skipDisable.includes('AuthFieldEditorModel.url')) },[Validators.required]],

View File

@ -77,7 +77,7 @@
<mat-error *ngIf="singleForm.get('autoCompleteOptions').hasError('required')">{{'GENERAL.VALIDATION.REQUIRED' | translate}}</mat-error>
</mat-form-field>
<mat-checkbox class="col-12" [formControl]="singleForm.get('hasAuth')">{{'DATASET-PROFILE-EDITOR.STEPS.FORM.FIELD.FIELDS.FIELD-AUTOCOMPLETE-HAS-AUTH' | translate}}</mat-checkbox>
<div *ngIf="singleForm.get('hasAuth').value === true" class="col-12">
<div *ngIf="singleForm.get('hasAuth').value === true" class="row">
<mat-form-field class="col-md-6">
<mat-label>{{'DATASET-PROFILE-EDITOR.STEPS.FORM.FIELD.FIELDS.FIELD-AUTOCOMPLETE-AUTH-METHOD' | translate}}</mat-label>
<mat-select [formControl]="singleForm.get('auth').get('method')">