1
0

Meals index, WIP

This commit is contained in:
cryptogopher
2020-04-18 18:29:53 +02:00
parent 3ff36df168
commit 50b89de904
10 changed files with 90 additions and 55 deletions

View File

@@ -18,6 +18,8 @@ en:
field_formula: 'Formula'
field_code: 'Formula'
field_shortname: 'Short name'
button_eat: 'Eat'
button_note: 'Note'
button_retake: 'Retake'
button_child: 'Child'
activerecord:

View File

@@ -10,7 +10,12 @@ resources :projects, shallow: true do
resources :ingredients, only: [] do
post 'adjust/:adjustment', to: 'ingredients#adjust', as: :adjust, on: :member
end
resources :meals, only: [:index, :new, :create, :edit, :update, :destroy]
resources :meals, only: [:index, :new, :create, :edit, :update, :destroy] do
member do
post 'note'
post 'toggle_eaten'
end
end
resources :measurement_routines, only: [:show, :edit] do
member do
get 'readouts', to: 'measurements#readouts'