I have @table_name(object array) contain many objects. I want to replace its column values one by one with my values..
i have use
<% for group_permission in @table_name %>
<%end%>
How i change Please help me
I have @table_name(object array) contain many objects. I want to replace its column values one by one with my values..
i have use
<% for group_permission in @table_name %>
<%end%>
How i change Please help me
Hi If @table_name is a collection of objects, you can get each as
<%@table_name.each do |t|%>
<%= t.group_permissions %>
<%end%>
You also can get attributes as
<% t.attributes.each do |a| %>
<%.......%>
<%end%>
Values and names of attributes as
a[0]
a[1]