##// END OF EJS Templates
html_safe for Rails3...
html_safe for Rails3 git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@8267 e93f8b46-1217-0410-a6f0-8f06a7374b81

File last commit:

r8025:532a76f78c91
r8147:8677f069ec4b
Show More
permissions.html.erb
52 lines | 2.1 KiB | text/plain | TextLexer
/ app / views / roles / permissions.html.erb
Jean-Philippe Lang
Resourcified roles....
r8025 <h2><%= link_to l(:label_role_plural), roles_path %> &#187; <%=l(:label_permissions_report)%></h2>
Jean-Philippe Lang
Added permissions report (link available on roles list view)....
r430
Jean-Philippe Lang
Resourcified roles....
r8025 <% form_tag(permissions_roles_path, :id => 'permissions_form') do %>
Jean-Philippe Lang
Adds checkboxes toggle links on permissions report....
r1769 <%= hidden_field_tag 'permissions[0]', '', :id => nil %>
Jean-Philippe Lang
Adds an autoscroll div around permissions report table....
r4986 <div class="autoscroll">
Jean-Philippe Lang
Added permissions report (link available on roles list view)....
r430 <table class="list">
Jean-Philippe Lang
Merged 0.6 branch into trunk....
r663 <thead>
Jean-Philippe Lang
Added permissions report (link available on roles list view)....
r430 <tr>
Jean-Philippe Lang
Merged 0.6 branch into trunk....
r663 <th><%=l(:label_permissions)%></th>
Jean-Philippe Lang
Added permissions report (link available on roles list view)....
r430 <% @roles.each do |role| %>
Jean-Philippe Lang
Adds checkboxes toggle links on permissions report....
r1769 <th>
<%= content_tag(role.builtin? ? 'em' : 'span', h(role.name)) %>
<%= link_to_function(image_tag('toggle_check.png'), "toggleCheckboxesBySelector('input.role-#{role.id}')",
:title => "#{l(:button_check_all)}/#{l(:button_uncheck_all)}") %>
</th>
Jean-Philippe Lang
Added permissions report (link available on roles list view)....
r430 <% end %>
</tr>
Jean-Philippe Lang
Merged 0.6 branch into trunk....
r663 </thead>
<tbody>
Jean-Philippe Lang
Added project module concept....
r714 <% perms_by_module = @permissions.group_by {|p| p.project_module.to_s} %>
<% perms_by_module.keys.sort.each do |mod| %>
<% unless mod.blank? %>
Jean-Philippe Lang
Slight change to the permissions report view, with folding support....
r2626 <tr class="group open">
Toshi MARUYAMA
replace tabs to spaces at app/views/roles/report.html.erb...
r7235 <td colspan="<%= @roles.size + 1 %>">
<span class="expander" onclick="toggleRowGroup(this);">&nbsp;</span>
<%= l_or_humanize(mod, :prefix => 'project_module_') %>
</td>
Jean-Philippe Lang
Slight change to the permissions report view, with folding support....
r2626 </tr>
Jean-Philippe Lang
Added permissions report (link available on roles list view)....
r430 <% end %>
Jean-Philippe Lang
Added project module concept....
r714 <% perms_by_module[mod].each do |permission| %>
Jean-Philippe Lang
Adds checkboxes toggle links on permissions report....
r1769 <tr class="<%= cycle('odd', 'even') %> permission-<%= permission.name %>">
<td>
<%= link_to_function(image_tag('toggle_check.png'), "toggleCheckboxesBySelector('.permission-#{permission.name} input')",
:title => "#{l(:button_check_all)}/#{l(:button_uncheck_all)}") %>
Jean-Philippe Lang
Makes permission screens localized (#2070)....
r1941 <%= l_or_humanize(permission.name, :prefix => 'permission_') %>
Jean-Philippe Lang
Adds checkboxes toggle links on permissions report....
r1769 </td>
Jean-Philippe Lang
Added project module concept....
r714 <% @roles.each do |role| %>
<td align="center">
<% if role.setable_permissions.include? permission %>
Jean-Philippe Lang
Adds checkboxes toggle links on permissions report....
r1769 <%= check_box_tag "permissions[#{role.id}][]", permission.name, (role.permissions.include? permission.name), :id => nil, :class => "role-#{role.id}" %>
Jean-Philippe Lang
Added project module concept....
r714 <% end %>
</td>
<% end %>
</tr>
Jean-Philippe Lang
Merged 0.6 branch into trunk....
r663 <% end %>
<% end %>
Jean-Philippe Lang
Added permissions report (link available on roles list view)....
r430 </tbody>
</table>
Jean-Philippe Lang
Adds an autoscroll div around permissions report table....
r4986 </div>
Jean-Philippe Lang
Added permissions report (link available on roles list view)....
r430 <p><%= check_all_links 'permissions_form' %></p>
<p><%= submit_tag l(:button_save) %></p>
Jean-Philippe Lang
Some deprecation fixes (end_form_tag and count API)....
r665 <% end %>