Compare commits
3 Commits
9b82720b7f
...
bd5c4f5482
Author | SHA1 | Date | |
---|---|---|---|
bd5c4f5482 | |||
d2974edcc1 | |||
810d0740f3 |
@ -4,4 +4,8 @@ class ExpensesController < ApplicationController
|
||||
def summary
|
||||
render json: Expenses::TotalQuery.new.call
|
||||
end
|
||||
|
||||
def index
|
||||
render json: Expense.all.order(pricing_type: :asc, amount: :desc).as_json(only: %i[id name amount pricing_type])
|
||||
end
|
||||
end
|
||||
|
@ -1,5 +1,3 @@
|
||||
# Copyright (C) 2024 Manuel Bustillo
|
||||
|
||||
class MergeGuestNames < ActiveRecord::Migration[8.0]
|
||||
def change
|
||||
add_column :guests, :name, :string
|
||||
|
2
db/schema.rb
generated
2
db/schema.rb
generated
@ -1,5 +1,3 @@
|
||||
# Copyright (C) 2024 Manuel Bustillo
|
||||
|
||||
# This file is auto-generated from the current state of the database. Instead
|
||||
# of editing this file, please use the migrations feature of Active Record to
|
||||
# incrementally modify your database, and then regenerate this schema definition.
|
||||
|
Loading…
x
Reference in New Issue
Block a user