|
|
|
@ -36,10 +36,10 @@ import { AliasEntityType, EntityType } from '@shared/models/entity-type.models'; |
|
|
|
import { BaseData } from '@shared/models/base-data'; |
|
|
|
import { EntityId } from '@shared/models/id/entity-id'; |
|
|
|
import { EntityService } from '@core/http/entity.service'; |
|
|
|
import { coerceBooleanProperty } from '@angular/cdk/coercion'; |
|
|
|
import { getCurrentAuthUser } from '@core/auth/auth.selectors'; |
|
|
|
import { Authority } from '@shared/models/authority.enum'; |
|
|
|
import { isEqual } from '@core/utils'; |
|
|
|
import {coerceBoolean} from '@shared/decorators/coerce-boolean'; |
|
|
|
|
|
|
|
@Component({ |
|
|
|
selector: 'tb-entity-autocomplete', |
|
|
|
@ -71,8 +71,6 @@ export class EntityAutocompleteComponent implements ControlValueAccessor, OnInit |
|
|
|
|
|
|
|
searchText = ''; |
|
|
|
|
|
|
|
private requiredValue: boolean; |
|
|
|
|
|
|
|
private dirty = false; |
|
|
|
|
|
|
|
private refresh$ = new Subject<Array<BaseData<EntityId>>>(); |
|
|
|
@ -119,14 +117,11 @@ export class EntityAutocompleteComponent implements ControlValueAccessor, OnInit |
|
|
|
appearance: MatFormFieldAppearance = 'fill'; |
|
|
|
|
|
|
|
@Input() |
|
|
|
set required(value: boolean) { |
|
|
|
this.requiredValue = coerceBooleanProperty(value); |
|
|
|
} |
|
|
|
get required(): boolean { |
|
|
|
return this.requiredValue; |
|
|
|
} |
|
|
|
@coerceBoolean() |
|
|
|
required: boolean; |
|
|
|
|
|
|
|
@Input() |
|
|
|
@coerceBoolean() |
|
|
|
disabled: boolean; |
|
|
|
|
|
|
|
@Output() |
|
|
|
|