luis@465
|
1 <div class="contextual">
|
luis@465
|
2 <% if User.current.allowed_to?(:add_subprojects, @project) %>
|
luis@465
|
3 <%= link_to l(:label_subproject_new), {:controller => 'projects', :action => 'new', :parent_id => @project}, :class => 'icon icon-add' %>
|
luis@465
|
4 <% end %>
|
luis@546
|
5
|
Chris@1232
|
6 <% if User.current.allowed_to?(:close_project, @project) %>
|
Chris@1232
|
7 <% if @project.active? %>
|
Chris@1232
|
8 <%= link_to l(:button_close), close_project_path(@project), :data => {:confirm => l(:text_are_you_sure)}, :method => :post, :class => 'icon icon-lock' %>
|
Chris@1232
|
9 <% else %>
|
Chris@1232
|
10 <%= link_to l(:button_reopen), reopen_project_path(@project), :data => {:confirm => l(:text_are_you_sure)}, :method => :post, :class => 'icon icon-unlock' %>
|
Chris@1232
|
11 <% end %>
|
Chris@1232
|
12
|
luis@550
|
13 <% if @project.module_enabled? :redmine_bibliography %>
|
luis@626
|
14 <% if User.current.allowed_to?(:add_publication, @project) %>
|
luis@626
|
15 <%= link_to l(:label_add_publication_to_project), {:controller => 'publications', :action => 'new', :project_id => @project}, :class => 'icon icon-add' %>
|
luis@626
|
16 <% end %>
|
luis@550
|
17 <% end %>
|
luis@465
|
18 </div>
|
luis@465
|
19
|
chris@680
|
20 <% if @project.has_welcome_page %>
|
chris@680
|
21 <% page = @project.wiki.find_page("Overview") %>
|
chris@680
|
22 <% end %>
|
chris@680
|
23
|
chris@680
|
24 <% if page %>
|
chris@680
|
25
|
chris@680
|
26 <% if @project.module_enabled? :wiki %>
|
chris@680
|
27 <% if User.current.allowed_to?(:edit_wiki_pages, @project) %>
|
chris@680
|
28 <div class="contextual">
|
chris@680
|
29 <%= link_to(l(:button_welcome_page_edit_this), {:controller => 'wiki', :action => 'edit', :project_id => @project, :id => Wiki.titleize("Overview")}, :class => 'icon icon-edit') %>
|
chris@680
|
30 </div>
|
chris@680
|
31 <% end %>
|
chris@680
|
32 <% end %>
|
chris@680
|
33
|
chris@680
|
34 <div class="contextual" style="clear: right">
|
chris@680
|
35 <ul>
|
Chris@1232
|
36 <% unless @project.homepage.blank? %><li><%=l(:field_homepage)%>: <%= link_to h(@project.homepage), @project.homepage %></li><% end %>
|
chris@680
|
37 <% if @subprojects.any? %>
|
chris@680
|
38 <li><%=l(:label_subproject_plural)%>:
|
Chris@1232
|
39 <%= @subprojects.collect{|p| link_to(h(p), :action => 'show', :id => p)}.join(", ").html_safe %></li>
|
chris@680
|
40 <% end %>
|
chris@680
|
41 </ul>
|
chris@680
|
42 </div>
|
chris@680
|
43
|
chris@680
|
44 <%= render(:partial => "wiki/content", :locals => {:content => page.content_for_version()}) %>
|
chris@680
|
45
|
chris@680
|
46 <% else %>
|
chris@680
|
47
|
luis@465
|
48 <h2><%=l(:label_overview)%></h2>
|
luis@465
|
49
|
Chris@1232
|
50 <% unless @project.active? %>
|
Chris@1232
|
51 <p class="warning"><span class="icon icon-lock"><%= l(:text_project_closed) %></span></p>
|
Chris@1232
|
52 <% end %>
|
Chris@1232
|
53
|
luis@465
|
54 <div class="splitcontentleft">
|
Chris@1232
|
55 <% if @project.description.present? %>
|
luis@465
|
56 <div class="wiki">
|
luis@465
|
57 <%= textilizable @project.description %>
|
luis@465
|
58 </div>
|
Chris@1232
|
59 <% end %>
|
luis@465
|
60 <ul>
|
Chris@1232
|
61 <% unless @project.homepage.blank? %><li><%=l(:field_homepage)%>: <%= link_to h(@project.homepage), @project.homepage %></li><% end %>
|
luis@465
|
62 <% if @subprojects.any? %>
|
luis@465
|
63 <li><%=l(:label_subproject_plural)%>:
|
Chris@1232
|
64 <%= @subprojects.collect{|p| link_to(h(p), :action => 'show', :id => p)}.join(", ").html_safe %></li>
|
luis@465
|
65 <% end %>
|
luis@465
|
66 <% @project.visible_custom_field_values.each do |custom_value| %>
|
luis@465
|
67 <% if !custom_value.value.blank? %>
|
luis@465
|
68 <li><%= custom_value.custom_field.name%>: <%=h show_value(custom_value) %></li>
|
luis@465
|
69 <% end %>
|
luis@465
|
70 <% end %>
|
luis@465
|
71 </ul>
|
luis@465
|
72
|
Chris@1232
|
73 <% if User.current.allowed_to?(:view_issues, @project) and @open_issues_by_tracker.values.any? %>
|
luis@465
|
74 <div class="issues box">
|
luis@465
|
75 <h3><%=l(:label_issue_tracking)%></h3>
|
luis@465
|
76 <ul>
|
luis@465
|
77 <% for tracker in @trackers %>
|
Chris@1232
|
78 <li><%= link_to h(tracker.name), :controller => 'issues', :action => 'index', :project_id => @project,
|
luis@465
|
79 :set_filter => 1,
|
luis@465
|
80 "tracker_id" => tracker.id %>:
|
Chris@1232
|
81 <%= l(:label_x_open_issues_abbr_on_total, :count => @open_issues_by_tracker[tracker].to_i,
|
Chris@1232
|
82 :total => @total_issues_by_tracker[tracker].to_i) %>
|
Chris@1232
|
83 </li>
|
luis@465
|
84 <% end %>
|
luis@465
|
85 </ul>
|
luis@465
|
86 <p>
|
luis@465
|
87 <%= link_to l(:label_issue_view_all), :controller => 'issues', :action => 'index', :project_id => @project, :set_filter => 1 %>
|
luis@465
|
88 <% if User.current.allowed_to?(:view_calendar, @project, :global => true) %>
|
luis@465
|
89 | <%= link_to(l(:label_calendar), :controller => 'calendars', :action => 'show', :project_id => @project) %>
|
luis@465
|
90 <% end %>
|
luis@465
|
91 <% if User.current.allowed_to?(:view_gantt, @project, :global => true) %>
|
luis@465
|
92 | <%= link_to(l(:label_gantt), :controller => 'gantts', :action => 'show', :project_id => @project) %>
|
luis@465
|
93 <% end %>
|
luis@465
|
94 </p>
|
luis@465
|
95 </div>
|
luis@465
|
96 <% end %>
|
luis@465
|
97 <%= call_hook(:view_projects_show_left, :project => @project) %>
|
luis@465
|
98 </div>
|
luis@465
|
99
|
luis@465
|
100 <div class="splitcontentright">
|
luis@465
|
101
|
luis@465
|
102 <%= render :partial => 'bibliography_box' %>
|
luis@465
|
103
|
luis@465
|
104 <%= render :partial => 'members_box' %>
|
luis@465
|
105
|
luis@465
|
106 <% if @news.any? && authorize_for('news', 'index') %>
|
luis@465
|
107 <div class="news box">
|
luis@465
|
108 <h3><%=l(:label_news_latest)%></h3>
|
luis@465
|
109 <%= render :partial => 'news/news', :collection => @news %>
|
luis@465
|
110 <p><%= link_to l(:label_news_view_all), :controller => 'news', :action => 'index', :project_id => @project %></p>
|
luis@465
|
111 </div>
|
luis@465
|
112 <% end %>
|
Chris@1232
|
113
|
Chris@1232
|
114 <%= render :partial => 'activities/recent' %>
|
Chris@1232
|
115
|
luis@465
|
116 <%= call_hook(:view_projects_show_right, :project => @project) %>
|
luis@465
|
117 </div>
|
luis@465
|
118
|
luis@465
|
119 <% content_for :sidebar do %>
|
chris@810
|
120 <%= call_hook(:view_projects_show_sidebar_top, :project => @project) %>
|
Chris@1232
|
121 <% if @total_hours.present? && User.current.allowed_to?(:view_time_entries, @project) %>
|
luis@465
|
122 <h3><%= l(:label_spent_time) %></h3>
|
luis@465
|
123 <p><span class="icon icon-time"><%= l_hours(@total_hours) %></span></p>
|
Chris@1232
|
124 <p>
|
Chris@1232
|
125 <% if User.current.allowed_to?(:log_time, @project) %>
|
Chris@1232
|
126 <%= link_to l(:button_log_time), new_project_time_entry_path(@project) %> |
|
Chris@1232
|
127 <% end %>
|
Chris@1232
|
128 <%= link_to(l(:label_details), project_time_entries_path(@project)) %> |
|
Chris@1232
|
129 <%= link_to(l(:label_report), report_project_time_entries_path(@project)) %></p>
|
luis@465
|
130 <% end %>
|
luis@465
|
131 <%= call_hook(:view_projects_show_sidebar_bottom, :project => @project) %>
|
luis@465
|
132 <% end %>
|
luis@465
|
133
|
chris@680
|
134 <% end %>
|
chris@680
|
135
|
luis@465
|
136 <% content_for :header_tags do %>
|
luis@465
|
137 <%= auto_discovery_link_tag(:atom, {:controller => 'activities', :action => 'index', :id => @project, :format => 'atom', :key => User.current.rss_key}) %>
|
luis@465
|
138 <% end %>
|
luis@465
|
139
|
luis@465
|
140 <% html_title(l(:label_overview)) -%>
|