perbaikan master

This commit is contained in:
fuzi_fauzia committed 2024-07-02 22:45:07 +07:00
1 parent b2d8a8e2f6
commit b095f870dd
17 files changed
+166 -57

No files matched your search

@@ -12,17 +12,20 @@ interface Icon {
export class SelectIconComponent {
// @Output() iconSelected: EventEmitter<string> = new EventEmitter<string>();
@Output() iconSelected = new EventEmitter<string>();
@Input() selectedIcon: string;
@Input() selectedIcon = undefined;
icons: any[] = [];
constructor(private masterService: MasterService) {}
ngOnInit(): void {
this.masterService.getIconData().subscribe((res) => {
this.icons = res.rows;
});
if (!this.selectedIcon) {
this.selectedIcon = undefined;
}
}
onSelect(icon: Icon): void {
console.log(icon);
if (icon) {
this.iconSelected.emit(icon.icon);
} else {