Initial web app consumption/integration #5

Merged
joe merged 6 commits from web-app-integration into master 2026-02-23 21:15:19 +00:00
3 changed files with 7 additions and 5 deletions
Showing only changes of commit 2185aa5415 - Show all commits

View file

@ -13,9 +13,9 @@ post {
body:json { body:json {
{ {
"date": "2026-01-03", "date": "2026-01-03",
"cents": 1010, "cents": 101111,
"note": "Gas", "note": "Gas",
"categoryId": "db21acbb-0e3e-4ea1-89e1-3d52e5d72cb4", "categoryId": "db21acbb-0e3e-4ea1-89e1-3d52e5d72cb4",
"marchantId": "b9028a32-1305-4699-8611-d8fd812ebc04" "merchantId": "b9028a32-1305-4699-8611-d8fd812ebc04"
} }
} }

View file

@ -12,6 +12,6 @@ post {
body:json { body:json {
{ {
"name": "Tag Three" "name": "Joe"
} }
} }

View file

@ -19,11 +19,13 @@ export class ExpenseDataService {
} }
public async create(expense: CreateExpense): Promise<Expense> { public async create(expense: CreateExpense): Promise<Expense> {
return await this.expenses.save(expense); const created = await this.expenses.save(expense);
return await this.expenses.findOneBy({ id: created.id }) as Expense;
} }
public async update(expense: UpdateExpense): Promise<Expense> { public async update(expense: UpdateExpense): Promise<Expense> {
return await this.expenses.save(expense); await this.expenses.save(expense);
return await this.expenses.findOneBy({ id: expense.id }) as Expense;
} }
public async delete(id: string): Promise<void> { public async delete(id: string): Promise<void> {