obsolete.ChilliProject/redmine/app/views/projects/settings.rhtml

106 lines
3.2 KiB
Plaintext
Raw Normal View History

<h2><%=_('Settings')%></h2>
<div class="box">
<%= start_form_tag :action => 'edit', :id => @project %>
<%= render :partial => 'form' %>
<center><%= submit_tag _('Save') %></center>
<%= end_form_tag %>
</div>
<div class="box">
<h3><%=_('Members')%></h3>
<%= error_messages_for 'member' %>
<table>
<% for member in @project.members.find(:all, :include => :user) %>
<% unless member.new_record? %>
<tr>
<td><%= member.user.display_name %></td>
<td>
<%= start_form_tag :controller => 'members', :action => 'edit', :id => member %>
<select name="member[role_id]">
<%= options_from_collection_for_select @roles, "id", "name", member.role_id %>
</select>
</td>
<td>
<%= submit_tag _('Save'), :class => "button-small" %>
<%= end_form_tag %>
</td>
<td>
<%= start_form_tag :controller => 'members', :action => 'destroy', :id => member %>
<%= submit_tag _('Delete'), :class => "button-small" %>
<%= end_form_tag %>
</td>
</tr>
<% end %>
<% end %>
</table>
<hr />
<label><%=_('New member')%></label><br/>
<%= start_form_tag :controller => 'projects', :action => 'add_member', :id => @project %>
<select name="member[user_id]">
<%= options_from_collection_for_select @users, "id", "display_name", @member.user_id %>
</select>
<select name="member[role_id]">
<%= options_from_collection_for_select @roles, "id", "name", @member.role_id %>
</select>
<%= submit_tag _('Add') %>
<%= end_form_tag %>
</div>
<div class="box">
<h3><%=_('Versions')%></h3>
<table>
<% for version in @project.versions %>
<tr>
<td><%= link_to version.name, :controller => 'versions', :action => 'edit', :id => version %></td>
<td><%=h version.descr %></td>
<td>
<%= start_form_tag :controller => 'versions', :action => 'destroy', :id => version %>
<%= submit_tag _('Delete'), :class => "button-small" %>
<%= end_form_tag %>
</td>
</tr>
<% end %>
</table>
<hr />
<%= start_form_tag ({ :controller => 'projects', :action => 'add_version', :id => @project }, :method => 'get' ) %>
<%= submit_tag _('New version...') %>
<%= end_form_tag %>
</div>
<div class="box">
<h3><%=_('Issue categories')%></h3>
<table>
<% for @category in @project.issue_categories %>
<% unless @category.new_record? %>
<tr>
<td>
<%= start_form_tag :controller => 'issue_categories', :action => 'edit', :id => @category %>
<%= text_field 'category', 'name', :size => 25 %>
</td>
<td>
<%= submit_tag _('Save'), :class => "button-small" %>
<%= end_form_tag %>
</td>
<td>
<%= start_form_tag :controller => 'issue_categories', :action => 'destroy', :id => @category %>
<%= submit_tag _('Delete'), :class => "button-small" %>
<%= end_form_tag %>
</td>
</tr>
<% end %>
<% end %>
</table>
<hr />
<%= start_form_tag :action => 'add_issue_category', :id => @project %>
<%= error_messages_for 'issue_category' %>
<label for="issue_category_name"><%=_('New category')%></label><br/>
<%= text_field 'issue_category', 'name', :size => 25 %>
<%= submit_tag _('Create') %>
<%= end_form_tag %>
</div>