aboutsummaryrefslogtreecommitdiff
path: root/ufund-ui/src/app/components/need-edit/need-edit.component.ts
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--ufund-ui/src/app/components/need-edit/need-edit.component.ts6
1 files changed, 3 insertions, 3 deletions
diff --git a/ufund-ui/src/app/components/need-edit/need-edit.component.ts b/ufund-ui/src/app/components/need-edit/need-edit.component.ts
index 02ffb71..2462534 100644
--- a/ufund-ui/src/app/components/need-edit/need-edit.component.ts
+++ b/ufund-ui/src/app/components/need-edit/need-edit.component.ts
@@ -1,4 +1,4 @@
-import { Component, Input, Output } from '@angular/core';
+import { Component, Input, Output, EventEmitter } from '@angular/core';
import { Need, GoalType } from '../../models/Need';
import { CupboardService } from '../../services/cupboard.service';
import { catchError, of } from 'rxjs';
@@ -18,7 +18,7 @@ export class NeedEditComponent {
) {}
@Input() selectedNeed!: Need;
- @Output() selectedNeedID: number | null = null;
+ @Output() refreshNeedList = new EventEmitter<void>();
update(form: any) {
console.log(form);
@@ -50,7 +50,7 @@ export class NeedEditComponent {
(result) => {
if (result) {
console.log("need updated successfully");
- // this.needList?.refresh()
+ this.refreshNeedList.emit();
} else {
console.log("need update failed");
}