create apiEnum components
This commit is contained in:
@@ -13,7 +13,7 @@ export interface ISelectItem {
|
||||
template: '',
|
||||
})
|
||||
export abstract class AbstractSelectComponent<T = ISelectItem, serviceResponse = T[]> {
|
||||
@Input() control = new FormControl<Maybe<number | T>>(null);
|
||||
@Input() control = new FormControl<Maybe<number | string | T>>(null);
|
||||
@Input() canInsert: boolean = false;
|
||||
@Input() showLabel: boolean = true;
|
||||
@Input() showErrors: boolean = true;
|
||||
@@ -39,6 +39,7 @@ export abstract class AbstractSelectComponent<T = ISelectItem, serviceResponse =
|
||||
}
|
||||
|
||||
abstract getDataService(): Observable<serviceResponse>;
|
||||
|
||||
getData() {
|
||||
this.loading.set(true);
|
||||
this.getDataService().subscribe({
|
||||
|
||||
Reference in New Issue
Block a user