1
0

Added Targets index

This commit is contained in:
cryptogopher
2020-08-06 21:52:33 +02:00
parent ffcc9553d5
commit cf3bbb205d
15 changed files with 245 additions and 45 deletions

View File

@@ -22,6 +22,7 @@ en:
field_formula: 'Formula'
field_code: 'Formula'
field_shortname: 'Short name'
button_reapply: 'Reapply'
button_eat: 'Eat'
button_notes: 'Notes'
button_retake: 'Retake'

View File

@@ -7,8 +7,16 @@ resources :projects, shallow: true do
post 'defaults'
end
end
resources :goals, only: [:show, :edit]
resources :targets, except: [:show]
resources :goals, only: [:show, :edit] do
member do
post 'toggle_exposure', to: 'goals#toggle_exposure'
end
end
resources :targets, except: [:show] do
collection do
post 'reapply/:date', to: 'targets#reapply', as: :reapply
end
end
resources :ingredients, only: [] do
post 'adjust/:adjustment', to: 'meals#adjust', as: :adjust, on: :member
end