Feature #7224 » view_project_members_permission-1.3.1.patch
app/models/project.rb (kopia robocza) | ||
---|---|---|
528 | 528 |
'custom_field_values', |
529 | 529 |
'custom_fields', |
530 | 530 |
'tracker_ids', |
531 |
'issue_custom_field_ids' |
|
531 |
'issue_custom_field_ids', |
|
532 |
'show_members' |
|
532 | 533 | |
533 | 534 |
safe_attributes 'enabled_module_names', |
534 | 535 |
:if => lambda {|project, user| project.new_record? || user.allowed_to?(:select_project_modules, project) } |
app/views/projects/_form.rhtml (kopia robocza) | ||
---|---|---|
15 | 15 |
<% end %></p> |
16 | 16 |
<p><%= f.text_field :homepage, :size => 60 %></p> |
17 | 17 |
<p><%= f.check_box :is_public %></p> |
18 |
<p><%= f.check_box :show_members %></p> |
|
18 | 19 |
<%= wikitoolbar_for 'project_description' %> |
19 | 20 | |
20 | 21 |
<% @project.custom_field_values.each do |value| %> |
app/views/projects/_members_box.html.erb (kopia robocza) | ||
---|---|---|
1 |
<% if @users_by_role.any? %>
|
|
1 |
<% if @users_by_role.any? && @project.show_members? && User.current.allowed_to?(:view_project_members, @project) %>
|
|
2 | 2 |
<div class="members box"> |
3 | 3 |
<h3><%=l(:label_member_plural)%></h3> |
4 | 4 |
<p><% @users_by_role.keys.sort.each do |role| %> |
db/migrate/20110517174842_add_show_members_to_projects.rb (wersja 0) | ||
---|---|---|
1 |
class AddShowMembersToProjects < ActiveRecord::Migration |
|
2 |
def self.up |
|
3 |
add_column :projects, :show_members, :boolean, :default => true, :null => false |
|
4 |
Project.update_all("show_members = #{connection.quoted_true}") |
|
5 |
end |
|
6 |
|
|
7 |
def self.down |
|
8 |
remove_column :projects, :show_members |
|
9 |
end |
|
10 |
end |
config/locales/en.yml (kopia robocza) | ||
---|---|---|
245 | 245 |
field_role: Role |
246 | 246 |
field_homepage: Homepage |
247 | 247 |
field_is_public: Public |
248 |
field_show_members: Show members |
|
248 | 249 |
field_parent: Subproject of |
249 | 250 |
field_is_in_roadmap: Issues displayed in roadmap |
250 | 251 |
field_login: Login |
... | ... | |
418 | 419 |
permission_delete_own_messages: Delete own messages |
419 | 420 |
permission_export_wiki_pages: Export wiki pages |
420 | 421 |
permission_manage_subtasks: Manage subtasks |
422 |
permission_view_project_members: View project members |
|
421 | 423 |
|
422 | 424 |
project_module_issue_tracking: Issue tracking |
423 | 425 |
project_module_time_tracking: Time tracking |
config/locales/pl.yml (kopia robocza) | ||
---|---|---|
249 | 249 |
field_is_for_all: Dla wszystkich projektów |
250 | 250 |
field_is_in_roadmap: Zagadnienie pokazywane na mapie |
251 | 251 |
field_is_public: Publiczny |
252 |
field_show_members: Wyświetlanie uczestników |
|
252 | 253 |
field_is_required: Wymagane |
253 | 254 |
field_issue: Zagadnienie |
254 | 255 |
field_issue_to: Powiązania zagadnienia |
... | ... | |
892 | 893 |
permission_add_subprojects: Tworzenie podprojektów |
893 | 894 |
permission_delete_issue_watchers: Usuń obserwatorów |
894 | 895 |
permission_view_issues: Przeglądanie zagadnień |
896 |
permission_view_project_members: Wgląd w uczestników projektu |
|
895 | 897 |
setting_default_projects_modules: Domyślnie włączone moduły dla nowo tworzonych projektów |
896 | 898 |
setting_gravatar_default: Domyślny obraz Gravatar |
897 | 899 |
setting_issue_done_ratio: Obliczaj postęp realizacji zagadnień za pomocą |
lib/redmine.rb (kopia robocza) | ||
---|---|---|
53 | 53 |
map.permission :manage_members, {:projects => :settings, :members => [:new, :edit, :destroy, :autocomplete_for_member]}, :require => :member |
54 | 54 |
map.permission :manage_versions, {:projects => :settings, :versions => [:new, :create, :edit, :update, :close_completed, :destroy]}, :require => :member |
55 | 55 |
map.permission :add_subprojects, {:projects => [:new, :create]}, :require => :member |
56 |
map.permission :view_project_members, {} |
|
56 | 57 |
|
57 | 58 |
map.project_module :issue_tracking do |map| |
58 | 59 |
# Issue categories |