##// END OF EJS Templates
Merged r4618 and r4619 from trunk....
Jean-Philippe Lang -
r4500:151a49b319fa
parent child
Show More
@@ -1,79 +1,79
1 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
1 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
2 <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
2 <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
3 <head>
3 <head>
4 <meta http-equiv="content-type" content="text/html; charset=utf-8" />
4 <meta http-equiv="content-type" content="text/html; charset=utf-8" />
5 <title><%=h html_title %></title>
5 <title><%=h html_title %></title>
6 <meta name="description" content="<%= Redmine::Info.app_name %>" />
6 <meta name="description" content="<%= Redmine::Info.app_name %>" />
7 <meta name="keywords" content="issue,bug,tracker" />
7 <meta name="keywords" content="issue,bug,tracker" />
8 <%= favicon %>
8 <%= favicon %>
9 <%= stylesheet_link_tag 'application', :media => 'all' %>
9 <%= stylesheet_link_tag 'application', :media => 'all' %>
10 <%= stylesheet_link_tag 'rtl', :media => 'all' if l(:direction) == 'rtl' %>
10 <%= stylesheet_link_tag 'rtl', :media => 'all' if l(:direction) == 'rtl' %>
11 <%= javascript_include_tag :defaults %>
11 <%= javascript_include_tag :defaults %>
12 <%= heads_for_theme %>
12 <%= heads_for_theme %>
13 <%= heads_for_wiki_formatter %>
13 <%= heads_for_wiki_formatter %>
14 <!--[if IE]>
14 <!--[if IE]>
15 <style type="text/css">
15 <style type="text/css">
16 * html body{ width: expression( document.documentElement.clientWidth < 900 ? '900px' : '100%' ); }
16 * html body{ width: expression( document.documentElement.clientWidth < 900 ? '900px' : '100%' ); }
17 body {behavior: url(<%= stylesheet_path "csshover.htc" %>);}
17 body {behavior: url(<%= stylesheet_path "csshover.htc" %>);}
18 </style>
18 </style>
19 <![endif]-->
19 <![endif]-->
20 <%= call_hook :view_layouts_base_html_head %>
20 <%= call_hook :view_layouts_base_html_head %>
21 <!-- page specific tags -->
21 <!-- page specific tags -->
22 <%= yield :header_tags -%>
22 <%= yield :header_tags -%>
23 </head>
23 </head>
24 <body class="<%= body_css_classes %>">
24 <body class="<%= body_css_classes %>">
25 <div id="wrapper">
25 <div id="wrapper">
26 <div id="wrapper2">
26 <div id="wrapper2">
27 <div id="top-menu">
27 <div id="top-menu">
28 <div id="account">
28 <div id="account">
29 <%= render_menu :account_menu -%>
29 <%= render_menu :account_menu -%>
30 </div>
30 </div>
31 <%= content_tag('div', "#{l(:label_logged_as)} #{link_to_user(User.current, :format => :username)}", :id => 'loggedas') if User.current.logged? %>
31 <%= content_tag('div', "#{l(:label_logged_as)} #{link_to_user(User.current, :format => :username)}", :id => 'loggedas') if User.current.logged? %>
32 <%= render_menu :top_menu -%>
32 <%= render_menu :top_menu -%>
33 </div>
33 </div>
34
34
35 <div id="header">
35 <div id="header">
36 <div id="quick-search">
36 <div id="quick-search">
37 <% form_tag({:controller => 'search', :action => 'index', :id => @project}, :method => :get ) do %>
37 <% form_tag({:controller => 'search', :action => 'index', :id => @project}, :method => :get ) do %>
38 <%= hidden_field_tag(controller.default_search_scope, 1, :id => nil) if controller.default_search_scope %>
38 <%= hidden_field_tag(controller.default_search_scope, 1, :id => nil) if controller.default_search_scope %>
39 <%= link_to l(:label_search), {:controller => 'search', :action => 'index', :id => @project}, :accesskey => accesskey(:search) %>:
39 <%= link_to l(:label_search), {:controller => 'search', :action => 'index', :id => @project}, :accesskey => accesskey(:search) %>:
40 <%= text_field_tag 'q', @question, :size => 20, :class => 'small', :accesskey => accesskey(:quick_search) %>
40 <%= text_field_tag 'q', @question, :size => 20, :class => 'small', :accesskey => accesskey(:quick_search) %>
41 <% end %>
41 <% end %>
42 <%= render_project_jump_box %>
42 <%= render_project_jump_box %>
43 </div>
43 </div>
44
44
45 <h1><%= page_header_title %></h1>
45 <h1><%= page_header_title %></h1>
46
46
47 <% if display_main_menu?(@project) %>
47 <% if display_main_menu?(@project) %>
48 <div id="main-menu">
48 <div id="main-menu">
49 <%= render_main_menu(@project) %>
49 <%= render_main_menu(@project) %>
50 </div>
50 </div>
51 <% end %>
51 <% end %>
52 </div>
52 </div>
53
53
54 <%= tag('div', {:id => 'main', :class => (has_content?(:sidebar) ? '' : 'nosidebar')}, true) %>
54 <%= tag('div', {:id => 'main', :class => (has_content?(:sidebar) ? '' : 'nosidebar')}, true) %>
55 <div id="sidebar">
55 <div id="sidebar">
56 <%= yield :sidebar %>
56 <%= yield :sidebar %>
57 <%= call_hook :view_layouts_base_sidebar %>
57 <%= call_hook :view_layouts_base_sidebar %>
58 </div>
58 </div>
59
59
60 <div id="content">
60 <div id="content">
61 <%= render_flash_messages %>
61 <%= render_flash_messages %>
62 <%= yield %>
62 <%= yield %>
63 <%= call_hook :view_layouts_base_content %>
63 <%= call_hook :view_layouts_base_content %>
64 <div style="clear:both;"></div>
64 <div style="clear:both;"></div>
65 </div>
65 </div>
66 </div>
66 </div>
67
67
68 <div id="ajax-indicator" style="display:none;"><span><%= l(:label_loading) %></span></div>
68 <div id="ajax-indicator" style="display:none;"><span><%= l(:label_loading) %></span></div>
69
69
70 <div id="footer">
70 <div id="footer">
71 <div class="bgl"><div class="bgr">
71 <div class="bgl"><div class="bgr">
72 Powered by <%= link_to Redmine::Info.app_name, Redmine::Info.url %> &copy; 2006-2010 Jean-Philippe Lang
72 Powered by <%= link_to Redmine::Info.app_name, Redmine::Info.url %> &copy; 2006-2011 Jean-Philippe Lang
73 </div></div>
73 </div></div>
74 </div>
74 </div>
75 </div>
75 </div>
76 </div>
76 </div>
77 <%= call_hook :view_layouts_base_body_bottom %>
77 <%= call_hook :view_layouts_base_body_bottom %>
78 </body>
78 </body>
79 </html>
79 </html>
@@ -1,43 +1,43
1 require 'rexml/document'
1 require 'rexml/document'
2
2
3 module Redmine
3 module Redmine
4 module VERSION #:nodoc:
4 module VERSION #:nodoc:
5 MAJOR = 1
5 MAJOR = 1
6 MINOR = 0
6 MINOR = 1
7 TINY = 5
7 TINY = 0
8
8
9 # Branch values:
9 # Branch values:
10 # * official release: nil
10 # * official release: nil
11 # * stable branch: stable
11 # * stable branch: stable
12 # * trunk: devel
12 # * trunk: devel
13 BRANCH = 'devel'
13 BRANCH = 'devel'
14
14
15 def self.revision
15 def self.revision
16 revision = nil
16 revision = nil
17 entries_path = "#{RAILS_ROOT}/.svn/entries"
17 entries_path = "#{RAILS_ROOT}/.svn/entries"
18 if File.readable?(entries_path)
18 if File.readable?(entries_path)
19 begin
19 begin
20 f = File.open(entries_path, 'r')
20 f = File.open(entries_path, 'r')
21 entries = f.read
21 entries = f.read
22 f.close
22 f.close
23 if entries.match(%r{^\d+})
23 if entries.match(%r{^\d+})
24 revision = $1.to_i if entries.match(%r{^\d+\s+dir\s+(\d+)\s})
24 revision = $1.to_i if entries.match(%r{^\d+\s+dir\s+(\d+)\s})
25 else
25 else
26 xml = REXML::Document.new(entries)
26 xml = REXML::Document.new(entries)
27 revision = xml.elements['wc-entries'].elements[1].attributes['revision'].to_i
27 revision = xml.elements['wc-entries'].elements[1].attributes['revision'].to_i
28 end
28 end
29 rescue
29 rescue
30 # Could not find the current revision
30 # Could not find the current revision
31 end
31 end
32 end
32 end
33 revision
33 revision
34 end
34 end
35
35
36 REVISION = self.revision
36 REVISION = self.revision
37 ARRAY = [MAJOR, MINOR, TINY, BRANCH, REVISION].compact
37 ARRAY = [MAJOR, MINOR, TINY, BRANCH, REVISION].compact
38 STRING = ARRAY.join('.')
38 STRING = ARRAY.join('.')
39
39
40 def self.to_a; ARRAY end
40 def self.to_a; ARRAY end
41 def self.to_s; STRING end
41 def self.to_s; STRING end
42 end
42 end
43 end
43 end
General Comments 0
You need to be logged in to leave comments. Login now