1
0
This repository has been archived on 2023-12-07. You can view files and clone it, but cannot push or open issues or pull requests.
body_tracking/app/helpers/meals_helper.rb
2020-04-18 01:22:21 +02:00

10 lines
290 B
Ruby

module MealsHelper
def meal_links(m)
delete_link(meal_path(m), {remote: true, data: {}}) if m.persisted?
end
def adjust_ingredient_link(i, adjustment)
link_to "%+d" % adjustment, adjust_ingredient_path(i, adjustment: adjustment),
{remote: true, method: :post}
end
end