diff --git a/src/frontend/app/administration/registered-mail/indexing/recipient-input.component.html b/src/frontend/app/administration/registered-mail/indexing/recipient-input.component.html index 94eaf5054791f9e82b4aa36307623d7466bb5553..983c522c08e927901a6944e6abce55ed970f615f 100644 --- a/src/frontend/app/administration/registered-mail/indexing/recipient-input.component.html +++ b/src/frontend/app/administration/registered-mail/indexing/recipient-input.component.html @@ -27,7 +27,8 @@ </mat-option> </mat-autocomplete> </mat-form-field> -<mat-card color="primary" *ngIf="manualAddress && !emptyAddress()"> +<a *ngIf="!manualAddress && emptyAddress()" (click)="manualAddress=!manualAddress" style="cursor: pointer;">{{'lang.switchManualAddress' | translate}}</a> +<mat-card color="primary" *ngIf="manualAddress"> <button mat-icon-button class="address-icon" (click)="manualAddress=!manualAddress" [title]="'lang.showAddress' | translate"> <mat-icon class="fa fa-eye"></mat-icon> @@ -96,7 +97,7 @@ </mat-autocomplete> </mat-form-field> </mat-card> -<mat-card color="primary" *ngIf="!manualAddress && !emptyAddress()"> +<mat-card color="primary" *ngIf="!manualAddress && !emptyAddress()" style="min-height: 60px"> <button *ngIf="this.control.status !== 'DISABLED'" mat-icon-button class="address-icon" (click)="manualAddress=!manualAddress" [title]="'lang.update' | translate"> <mat-icon class="fa fa-edit"></mat-icon> diff --git a/src/frontend/app/administration/registered-mail/indexing/recipient-input.component.ts b/src/frontend/app/administration/registered-mail/indexing/recipient-input.component.ts index 66bbdbafbd8a93cbec6bc6d9f11b5a835d25ad5b..5ee0c35ed49609032a8bb8f7aa9b17b9bcae3746 100644 --- a/src/frontend/app/administration/registered-mail/indexing/recipient-input.component.ts +++ b/src/frontend/app/administration/registered-mail/indexing/recipient-input.component.ts @@ -167,7 +167,7 @@ export class RegisteredMailRecipientInputComponent implements OnInit { emptyAddress() { let state: boolean = true; Object.keys(this.control.value).forEach(key => { - if (this.control.value[key] !== '') { + if (!this.functions.empty(this.control.value[key])) { state = false; } });