protected async void UpdateExpenses() { await ServerFacade.UpdateExpenses(Expenses); FilterExpenses(); CloseEditForm(); base.StateHasChanged(); }
protected async void DeleteExpense(Expense expense) { Expenses.Remove(expense); await ServerFacade.UpdateExpenses(Expenses); FilterExpenses(); base.StateHasChanged(); }
protected async void AddNewExpense() { if (string.IsNullOrEmpty(NewExpense.Name)) { return; } Expenses.Add(NewExpense); await ServerFacade.UpdateExpenses(Expenses); FilterExpenses(); NewExpense = new Expense(); IsFormOpen = false; base.StateHasChanged(); }