Posts by Rodrigo • 146 points
2 posts
-
2
votes2
answers199
viewsA: Construct an unordered list with content_tag
With this code you can create the list: def li_with_link(link_text, link_url) content_tag :li, link_to(link_text, link_url) end def ul_with_lis content_tag :ul, class: 'menu' do content_tag :li do…
-
1
votes1
answer816
viewsA: How to update with AJAX a list after the action of a remote form?
First of all, study at Gem Cancan to implement permissions. With Cancan, the code of your method would look like this: def create @groupsuser = Groupsuser.new(groupsuser_params) @groupsuser.group =…