@@ -0,0 +1,9 | |||||
|
1 | class AddActiveFieldToEnumerations < ActiveRecord::Migration | |||
|
2 | def self.up | |||
|
3 | add_column :enumerations, :active, :boolean, :default => true, :null => false | |||
|
4 | end | |||
|
5 | ||||
|
6 | def self.down | |||
|
7 | remove_column :enumerations, :active | |||
|
8 | end | |||
|
9 | end |
@@ -1,164 +1,171 | |||||
1 | # redMine - project management software |
|
1 | # redMine - project management software | |
2 | # Copyright (C) 2006 Jean-Philippe Lang |
|
2 | # Copyright (C) 2006 Jean-Philippe Lang | |
3 | # |
|
3 | # | |
4 | # This program is free software; you can redistribute it and/or |
|
4 | # This program is free software; you can redistribute it and/or | |
5 | # modify it under the terms of the GNU General Public License |
|
5 | # modify it under the terms of the GNU General Public License | |
6 | # as published by the Free Software Foundation; either version 2 |
|
6 | # as published by the Free Software Foundation; either version 2 | |
7 | # of the License, or (at your option) any later version. |
|
7 | # of the License, or (at your option) any later version. | |
8 | # |
|
8 | # | |
9 | # This program is distributed in the hope that it will be useful, |
|
9 | # This program is distributed in the hope that it will be useful, | |
10 | # but WITHOUT ANY WARRANTY; without even the implied warranty of |
|
10 | # but WITHOUT ANY WARRANTY; without even the implied warranty of | |
11 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|
11 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
12 | # GNU General Public License for more details. |
|
12 | # GNU General Public License for more details. | |
13 | # |
|
13 | # | |
14 | # You should have received a copy of the GNU General Public License |
|
14 | # You should have received a copy of the GNU General Public License | |
15 | # along with this program; if not, write to the Free Software |
|
15 | # along with this program; if not, write to the Free Software | |
16 | # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. |
|
16 | # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. | |
17 |
|
17 | |||
18 | module TimelogHelper |
|
18 | module TimelogHelper | |
19 | include ApplicationHelper |
|
19 | include ApplicationHelper | |
20 |
|
20 | |||
21 | def render_timelog_breadcrumb |
|
21 | def render_timelog_breadcrumb | |
22 | links = [] |
|
22 | links = [] | |
23 | links << link_to(l(:label_project_all), {:project_id => nil, :issue_id => nil}) |
|
23 | links << link_to(l(:label_project_all), {:project_id => nil, :issue_id => nil}) | |
24 | links << link_to(h(@project), {:project_id => @project, :issue_id => nil}) if @project |
|
24 | links << link_to(h(@project), {:project_id => @project, :issue_id => nil}) if @project | |
25 | links << link_to_issue(@issue) if @issue |
|
25 | links << link_to_issue(@issue) if @issue | |
26 | breadcrumb links |
|
26 | breadcrumb links | |
27 | end |
|
27 | end | |
28 |
|
28 | |||
29 | def activity_collection_for_select_options |
|
29 | # Returns a collection of activities for a select field. time_entry | |
30 | activities = TimeEntryActivity.all |
|
30 | # is optional and will be used to check if the selected TimeEntryActivity | |
|
31 | # is active. | |||
|
32 | def activity_collection_for_select_options(time_entry=nil) | |||
|
33 | activities = TimeEntryActivity.active | |||
31 | collection = [] |
|
34 | collection = [] | |
|
35 | if time_entry && !time_entry.activity.active? | |||
|
36 | collection << [ "--- #{l(:actionview_instancetag_blank_option)} ---", '' ] | |||
|
37 | else | |||
32 | collection << [ "--- #{l(:actionview_instancetag_blank_option)} ---", '' ] unless activities.detect(&:is_default) |
|
38 | collection << [ "--- #{l(:actionview_instancetag_blank_option)} ---", '' ] unless activities.detect(&:is_default) | |
|
39 | end | |||
33 | activities.each { |a| collection << [a.name, a.id] } |
|
40 | activities.each { |a| collection << [a.name, a.id] } | |
34 | collection |
|
41 | collection | |
35 | end |
|
42 | end | |
36 |
|
43 | |||
37 | def select_hours(data, criteria, value) |
|
44 | def select_hours(data, criteria, value) | |
38 | if value.to_s.empty? |
|
45 | if value.to_s.empty? | |
39 | data.select {|row| row[criteria].blank? } |
|
46 | data.select {|row| row[criteria].blank? } | |
40 | else |
|
47 | else | |
41 | data.select {|row| row[criteria] == value} |
|
48 | data.select {|row| row[criteria] == value} | |
42 | end |
|
49 | end | |
43 | end |
|
50 | end | |
44 |
|
51 | |||
45 | def sum_hours(data) |
|
52 | def sum_hours(data) | |
46 | sum = 0 |
|
53 | sum = 0 | |
47 | data.each do |row| |
|
54 | data.each do |row| | |
48 | sum += row['hours'].to_f |
|
55 | sum += row['hours'].to_f | |
49 | end |
|
56 | end | |
50 | sum |
|
57 | sum | |
51 | end |
|
58 | end | |
52 |
|
59 | |||
53 | def options_for_period_select(value) |
|
60 | def options_for_period_select(value) | |
54 | options_for_select([[l(:label_all_time), 'all'], |
|
61 | options_for_select([[l(:label_all_time), 'all'], | |
55 | [l(:label_today), 'today'], |
|
62 | [l(:label_today), 'today'], | |
56 | [l(:label_yesterday), 'yesterday'], |
|
63 | [l(:label_yesterday), 'yesterday'], | |
57 | [l(:label_this_week), 'current_week'], |
|
64 | [l(:label_this_week), 'current_week'], | |
58 | [l(:label_last_week), 'last_week'], |
|
65 | [l(:label_last_week), 'last_week'], | |
59 | [l(:label_last_n_days, 7), '7_days'], |
|
66 | [l(:label_last_n_days, 7), '7_days'], | |
60 | [l(:label_this_month), 'current_month'], |
|
67 | [l(:label_this_month), 'current_month'], | |
61 | [l(:label_last_month), 'last_month'], |
|
68 | [l(:label_last_month), 'last_month'], | |
62 | [l(:label_last_n_days, 30), '30_days'], |
|
69 | [l(:label_last_n_days, 30), '30_days'], | |
63 | [l(:label_this_year), 'current_year']], |
|
70 | [l(:label_this_year), 'current_year']], | |
64 | value) |
|
71 | value) | |
65 | end |
|
72 | end | |
66 |
|
73 | |||
67 | def entries_to_csv(entries) |
|
74 | def entries_to_csv(entries) | |
68 | ic = Iconv.new(l(:general_csv_encoding), 'UTF-8') |
|
75 | ic = Iconv.new(l(:general_csv_encoding), 'UTF-8') | |
69 | decimal_separator = l(:general_csv_decimal_separator) |
|
76 | decimal_separator = l(:general_csv_decimal_separator) | |
70 | custom_fields = TimeEntryCustomField.find(:all) |
|
77 | custom_fields = TimeEntryCustomField.find(:all) | |
71 | export = StringIO.new |
|
78 | export = StringIO.new | |
72 | CSV::Writer.generate(export, l(:general_csv_separator)) do |csv| |
|
79 | CSV::Writer.generate(export, l(:general_csv_separator)) do |csv| | |
73 | # csv header fields |
|
80 | # csv header fields | |
74 | headers = [l(:field_spent_on), |
|
81 | headers = [l(:field_spent_on), | |
75 | l(:field_user), |
|
82 | l(:field_user), | |
76 | l(:field_activity), |
|
83 | l(:field_activity), | |
77 | l(:field_project), |
|
84 | l(:field_project), | |
78 | l(:field_issue), |
|
85 | l(:field_issue), | |
79 | l(:field_tracker), |
|
86 | l(:field_tracker), | |
80 | l(:field_subject), |
|
87 | l(:field_subject), | |
81 | l(:field_hours), |
|
88 | l(:field_hours), | |
82 | l(:field_comments) |
|
89 | l(:field_comments) | |
83 | ] |
|
90 | ] | |
84 | # Export custom fields |
|
91 | # Export custom fields | |
85 | headers += custom_fields.collect(&:name) |
|
92 | headers += custom_fields.collect(&:name) | |
86 |
|
93 | |||
87 | csv << headers.collect {|c| begin; ic.iconv(c.to_s); rescue; c.to_s; end } |
|
94 | csv << headers.collect {|c| begin; ic.iconv(c.to_s); rescue; c.to_s; end } | |
88 | # csv lines |
|
95 | # csv lines | |
89 | entries.each do |entry| |
|
96 | entries.each do |entry| | |
90 | fields = [format_date(entry.spent_on), |
|
97 | fields = [format_date(entry.spent_on), | |
91 | entry.user, |
|
98 | entry.user, | |
92 | entry.activity, |
|
99 | entry.activity, | |
93 | entry.project, |
|
100 | entry.project, | |
94 | (entry.issue ? entry.issue.id : nil), |
|
101 | (entry.issue ? entry.issue.id : nil), | |
95 | (entry.issue ? entry.issue.tracker : nil), |
|
102 | (entry.issue ? entry.issue.tracker : nil), | |
96 | (entry.issue ? entry.issue.subject : nil), |
|
103 | (entry.issue ? entry.issue.subject : nil), | |
97 | entry.hours.to_s.gsub('.', decimal_separator), |
|
104 | entry.hours.to_s.gsub('.', decimal_separator), | |
98 | entry.comments |
|
105 | entry.comments | |
99 | ] |
|
106 | ] | |
100 | fields += custom_fields.collect {|f| show_value(entry.custom_value_for(f)) } |
|
107 | fields += custom_fields.collect {|f| show_value(entry.custom_value_for(f)) } | |
101 |
|
108 | |||
102 | csv << fields.collect {|c| begin; ic.iconv(c.to_s); rescue; c.to_s; end } |
|
109 | csv << fields.collect {|c| begin; ic.iconv(c.to_s); rescue; c.to_s; end } | |
103 | end |
|
110 | end | |
104 | end |
|
111 | end | |
105 | export.rewind |
|
112 | export.rewind | |
106 | export |
|
113 | export | |
107 | end |
|
114 | end | |
108 |
|
115 | |||
109 | def format_criteria_value(criteria, value) |
|
116 | def format_criteria_value(criteria, value) | |
110 | value.blank? ? l(:label_none) : ((k = @available_criterias[criteria][:klass]) ? k.find_by_id(value.to_i) : format_value(value, @available_criterias[criteria][:format])) |
|
117 | value.blank? ? l(:label_none) : ((k = @available_criterias[criteria][:klass]) ? k.find_by_id(value.to_i) : format_value(value, @available_criterias[criteria][:format])) | |
111 | end |
|
118 | end | |
112 |
|
119 | |||
113 | def report_to_csv(criterias, periods, hours) |
|
120 | def report_to_csv(criterias, periods, hours) | |
114 | export = StringIO.new |
|
121 | export = StringIO.new | |
115 | CSV::Writer.generate(export, l(:general_csv_separator)) do |csv| |
|
122 | CSV::Writer.generate(export, l(:general_csv_separator)) do |csv| | |
116 | # Column headers |
|
123 | # Column headers | |
117 | headers = criterias.collect {|criteria| l(@available_criterias[criteria][:label]) } |
|
124 | headers = criterias.collect {|criteria| l(@available_criterias[criteria][:label]) } | |
118 | headers += periods |
|
125 | headers += periods | |
119 | headers << l(:label_total) |
|
126 | headers << l(:label_total) | |
120 | csv << headers.collect {|c| to_utf8(c) } |
|
127 | csv << headers.collect {|c| to_utf8(c) } | |
121 | # Content |
|
128 | # Content | |
122 | report_criteria_to_csv(csv, criterias, periods, hours) |
|
129 | report_criteria_to_csv(csv, criterias, periods, hours) | |
123 | # Total row |
|
130 | # Total row | |
124 | row = [ l(:label_total) ] + [''] * (criterias.size - 1) |
|
131 | row = [ l(:label_total) ] + [''] * (criterias.size - 1) | |
125 | total = 0 |
|
132 | total = 0 | |
126 | periods.each do |period| |
|
133 | periods.each do |period| | |
127 | sum = sum_hours(select_hours(hours, @columns, period.to_s)) |
|
134 | sum = sum_hours(select_hours(hours, @columns, period.to_s)) | |
128 | total += sum |
|
135 | total += sum | |
129 | row << (sum > 0 ? "%.2f" % sum : '') |
|
136 | row << (sum > 0 ? "%.2f" % sum : '') | |
130 | end |
|
137 | end | |
131 | row << "%.2f" %total |
|
138 | row << "%.2f" %total | |
132 | csv << row |
|
139 | csv << row | |
133 | end |
|
140 | end | |
134 | export.rewind |
|
141 | export.rewind | |
135 | export |
|
142 | export | |
136 | end |
|
143 | end | |
137 |
|
144 | |||
138 | def report_criteria_to_csv(csv, criterias, periods, hours, level=0) |
|
145 | def report_criteria_to_csv(csv, criterias, periods, hours, level=0) | |
139 | hours.collect {|h| h[criterias[level]].to_s}.uniq.each do |value| |
|
146 | hours.collect {|h| h[criterias[level]].to_s}.uniq.each do |value| | |
140 | hours_for_value = select_hours(hours, criterias[level], value) |
|
147 | hours_for_value = select_hours(hours, criterias[level], value) | |
141 | next if hours_for_value.empty? |
|
148 | next if hours_for_value.empty? | |
142 | row = [''] * level |
|
149 | row = [''] * level | |
143 | row << to_utf8(format_criteria_value(criterias[level], value)) |
|
150 | row << to_utf8(format_criteria_value(criterias[level], value)) | |
144 | row += [''] * (criterias.length - level - 1) |
|
151 | row += [''] * (criterias.length - level - 1) | |
145 | total = 0 |
|
152 | total = 0 | |
146 | periods.each do |period| |
|
153 | periods.each do |period| | |
147 | sum = sum_hours(select_hours(hours_for_value, @columns, period.to_s)) |
|
154 | sum = sum_hours(select_hours(hours_for_value, @columns, period.to_s)) | |
148 | total += sum |
|
155 | total += sum | |
149 | row << (sum > 0 ? "%.2f" % sum : '') |
|
156 | row << (sum > 0 ? "%.2f" % sum : '') | |
150 | end |
|
157 | end | |
151 | row << "%.2f" %total |
|
158 | row << "%.2f" %total | |
152 | csv << row |
|
159 | csv << row | |
153 |
|
160 | |||
154 | if criterias.length > level + 1 |
|
161 | if criterias.length > level + 1 | |
155 | report_criteria_to_csv(csv, criterias, periods, hours_for_value, level + 1) |
|
162 | report_criteria_to_csv(csv, criterias, periods, hours_for_value, level + 1) | |
156 | end |
|
163 | end | |
157 | end |
|
164 | end | |
158 | end |
|
165 | end | |
159 |
|
166 | |||
160 | def to_utf8(s) |
|
167 | def to_utf8(s) | |
161 | @ic ||= Iconv.new(l(:general_csv_encoding), 'UTF-8') |
|
168 | @ic ||= Iconv.new(l(:general_csv_encoding), 'UTF-8') | |
162 | begin; @ic.iconv(s.to_s); rescue; s.to_s; end |
|
169 | begin; @ic.iconv(s.to_s); rescue; s.to_s; end | |
163 | end |
|
170 | end | |
164 | end |
|
171 | end |
@@ -1,132 +1,140 | |||||
1 | # redMine - project management software |
|
1 | # redMine - project management software | |
2 | # Copyright (C) 2006 Jean-Philippe Lang |
|
2 | # Copyright (C) 2006 Jean-Philippe Lang | |
3 | # |
|
3 | # | |
4 | # This program is free software; you can redistribute it and/or |
|
4 | # This program is free software; you can redistribute it and/or | |
5 | # modify it under the terms of the GNU General Public License |
|
5 | # modify it under the terms of the GNU General Public License | |
6 | # as published by the Free Software Foundation; either version 2 |
|
6 | # as published by the Free Software Foundation; either version 2 | |
7 | # of the License, or (at your option) any later version. |
|
7 | # of the License, or (at your option) any later version. | |
8 | # |
|
8 | # | |
9 | # This program is distributed in the hope that it will be useful, |
|
9 | # This program is distributed in the hope that it will be useful, | |
10 | # but WITHOUT ANY WARRANTY; without even the implied warranty of |
|
10 | # but WITHOUT ANY WARRANTY; without even the implied warranty of | |
11 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|
11 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
12 | # GNU General Public License for more details. |
|
12 | # GNU General Public License for more details. | |
13 | # |
|
13 | # | |
14 | # You should have received a copy of the GNU General Public License |
|
14 | # You should have received a copy of the GNU General Public License | |
15 | # along with this program; if not, write to the Free Software |
|
15 | # along with this program; if not, write to the Free Software | |
16 | # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. |
|
16 | # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. | |
17 |
|
17 | |||
18 | class Enumeration < ActiveRecord::Base |
|
18 | class Enumeration < ActiveRecord::Base | |
19 | acts_as_list :scope => 'type = \'#{type}\'' |
|
19 | acts_as_list :scope => 'type = \'#{type}\'' | |
20 | acts_as_customizable |
|
20 | acts_as_customizable | |
21 |
|
21 | |||
22 | before_destroy :check_integrity |
|
22 | before_destroy :check_integrity | |
23 |
|
23 | |||
24 | validates_presence_of :name |
|
24 | validates_presence_of :name | |
25 | validates_uniqueness_of :name, :scope => [:type] |
|
25 | validates_uniqueness_of :name, :scope => [:type] | |
26 | validates_length_of :name, :maximum => 30 |
|
26 | validates_length_of :name, :maximum => 30 | |
27 |
|
27 | |||
28 | # Backwards compatiblity named_scopes. |
|
28 | # Backwards compatiblity named_scopes. | |
29 | # Can be removed post-0.9 |
|
29 | # Can be removed post-0.9 | |
30 | named_scope :priorities, :conditions => { :type => "IssuePriority" }, :order => 'position' do |
|
30 | named_scope :priorities, :conditions => { :type => "IssuePriority" }, :order => 'position' do | |
31 | ActiveSupport::Deprecation.warn("Enumeration#priorities is deprecated, use the IssuePriority class. (#{Redmine::Info.issue(3007)})") |
|
31 | ActiveSupport::Deprecation.warn("Enumeration#priorities is deprecated, use the IssuePriority class. (#{Redmine::Info.issue(3007)})") | |
32 | def default |
|
32 | def default | |
33 | find(:first, :conditions => { :is_default => true }) |
|
33 | find(:first, :conditions => { :is_default => true }) | |
34 | end |
|
34 | end | |
35 | end |
|
35 | end | |
36 |
|
36 | |||
37 | named_scope :document_categories, :conditions => { :type => "DocumentCategory" }, :order => 'position' do |
|
37 | named_scope :document_categories, :conditions => { :type => "DocumentCategory" }, :order => 'position' do | |
38 | ActiveSupport::Deprecation.warn("Enumeration#document_categories is deprecated, use the DocumentCategories class. (#{Redmine::Info.issue(3007)})") |
|
38 | ActiveSupport::Deprecation.warn("Enumeration#document_categories is deprecated, use the DocumentCategories class. (#{Redmine::Info.issue(3007)})") | |
39 | def default |
|
39 | def default | |
40 | find(:first, :conditions => { :is_default => true }) |
|
40 | find(:first, :conditions => { :is_default => true }) | |
41 | end |
|
41 | end | |
42 | end |
|
42 | end | |
43 |
|
43 | |||
44 | named_scope :activities, :conditions => { :type => "TimeEntryActivity" }, :order => 'position' do |
|
44 | named_scope :activities, :conditions => { :type => "TimeEntryActivity" }, :order => 'position' do | |
45 | ActiveSupport::Deprecation.warn("Enumeration#activities is deprecated, use the TimeEntryActivity class. (#{Redmine::Info.issue(3007)})") |
|
45 | ActiveSupport::Deprecation.warn("Enumeration#activities is deprecated, use the TimeEntryActivity class. (#{Redmine::Info.issue(3007)})") | |
46 | def default |
|
46 | def default | |
47 | find(:first, :conditions => { :is_default => true }) |
|
47 | find(:first, :conditions => { :is_default => true }) | |
48 | end |
|
48 | end | |
49 | end |
|
49 | end | |
50 |
|
50 | |||
51 | named_scope :values, lambda {|type| { :conditions => { :type => type }, :order => 'position' } } do |
|
51 | named_scope :values, lambda {|type| { :conditions => { :type => type }, :order => 'position' } } do | |
52 | def default |
|
52 | def default | |
53 | find(:first, :conditions => { :is_default => true }) |
|
53 | find(:first, :conditions => { :is_default => true }) | |
54 | end |
|
54 | end | |
55 | end |
|
55 | end | |
|
56 | # End backwards compatiblity named_scopes | |||
56 |
|
57 | |||
57 | named_scope :all, :order => 'position' |
|
58 | named_scope :all, :order => 'position' | |
58 |
|
59 | |||
|
60 | named_scope :active, lambda { | |||
|
61 | { | |||
|
62 | :conditions => {:active => true}, | |||
|
63 | :order => 'position' | |||
|
64 | } | |||
|
65 | } | |||
|
66 | ||||
59 | def self.default |
|
67 | def self.default | |
60 | # Creates a fake default scope so Enumeration.default will check |
|
68 | # Creates a fake default scope so Enumeration.default will check | |
61 | # it's type. STI subclasses will automatically add their own |
|
69 | # it's type. STI subclasses will automatically add their own | |
62 | # types to the finder. |
|
70 | # types to the finder. | |
63 | if self.descends_from_active_record? |
|
71 | if self.descends_from_active_record? | |
64 | find(:first, :conditions => { :is_default => true, :type => 'Enumeration' }) |
|
72 | find(:first, :conditions => { :is_default => true, :type => 'Enumeration' }) | |
65 | else |
|
73 | else | |
66 | # STI classes are |
|
74 | # STI classes are | |
67 | find(:first, :conditions => { :is_default => true }) |
|
75 | find(:first, :conditions => { :is_default => true }) | |
68 | end |
|
76 | end | |
69 | end |
|
77 | end | |
70 |
|
78 | |||
71 | # Overloaded on concrete classes |
|
79 | # Overloaded on concrete classes | |
72 | def option_name |
|
80 | def option_name | |
73 | nil |
|
81 | nil | |
74 | end |
|
82 | end | |
75 |
|
83 | |||
76 | # Backwards compatiblity. Can be removed post-0.9 |
|
84 | # Backwards compatiblity. Can be removed post-0.9 | |
77 | def opt |
|
85 | def opt | |
78 | ActiveSupport::Deprecation.warn("Enumeration#opt is deprecated, use the STI classes now. (#{Redmine::Info.issue(3007)})") |
|
86 | ActiveSupport::Deprecation.warn("Enumeration#opt is deprecated, use the STI classes now. (#{Redmine::Info.issue(3007)})") | |
79 | return OptName |
|
87 | return OptName | |
80 | end |
|
88 | end | |
81 |
|
89 | |||
82 | def before_save |
|
90 | def before_save | |
83 | if is_default? && is_default_changed? |
|
91 | if is_default? && is_default_changed? | |
84 | Enumeration.update_all("is_default = #{connection.quoted_false}", {:type => type}) |
|
92 | Enumeration.update_all("is_default = #{connection.quoted_false}", {:type => type}) | |
85 | end |
|
93 | end | |
86 | end |
|
94 | end | |
87 |
|
95 | |||
88 | # Overloaded on concrete classes |
|
96 | # Overloaded on concrete classes | |
89 | def objects_count |
|
97 | def objects_count | |
90 | 0 |
|
98 | 0 | |
91 | end |
|
99 | end | |
92 |
|
100 | |||
93 | def in_use? |
|
101 | def in_use? | |
94 | self.objects_count != 0 |
|
102 | self.objects_count != 0 | |
95 | end |
|
103 | end | |
96 |
|
104 | |||
97 | alias :destroy_without_reassign :destroy |
|
105 | alias :destroy_without_reassign :destroy | |
98 |
|
106 | |||
99 | # Destroy the enumeration |
|
107 | # Destroy the enumeration | |
100 | # If a enumeration is specified, objects are reassigned |
|
108 | # If a enumeration is specified, objects are reassigned | |
101 | def destroy(reassign_to = nil) |
|
109 | def destroy(reassign_to = nil) | |
102 | if reassign_to && reassign_to.is_a?(Enumeration) |
|
110 | if reassign_to && reassign_to.is_a?(Enumeration) | |
103 | self.transfer_relations(reassign_to) |
|
111 | self.transfer_relations(reassign_to) | |
104 | end |
|
112 | end | |
105 | destroy_without_reassign |
|
113 | destroy_without_reassign | |
106 | end |
|
114 | end | |
107 |
|
115 | |||
108 | def <=>(enumeration) |
|
116 | def <=>(enumeration) | |
109 | position <=> enumeration.position |
|
117 | position <=> enumeration.position | |
110 | end |
|
118 | end | |
111 |
|
119 | |||
112 | def to_s; name end |
|
120 | def to_s; name end | |
113 |
|
121 | |||
114 | # Returns the Subclasses of Enumeration. Each Subclass needs to be |
|
122 | # Returns the Subclasses of Enumeration. Each Subclass needs to be | |
115 | # required in development mode. |
|
123 | # required in development mode. | |
116 | # |
|
124 | # | |
117 | # Note: subclasses is protected in ActiveRecord |
|
125 | # Note: subclasses is protected in ActiveRecord | |
118 | def self.get_subclasses |
|
126 | def self.get_subclasses | |
119 | @@subclasses[Enumeration] |
|
127 | @@subclasses[Enumeration] | |
120 | end |
|
128 | end | |
121 |
|
129 | |||
122 | private |
|
130 | private | |
123 | def check_integrity |
|
131 | def check_integrity | |
124 | raise "Can't delete enumeration" if self.in_use? |
|
132 | raise "Can't delete enumeration" if self.in_use? | |
125 | end |
|
133 | end | |
126 |
|
134 | |||
127 | end |
|
135 | end | |
128 |
|
136 | |||
129 | # Force load the subclasses in development mode |
|
137 | # Force load the subclasses in development mode | |
130 | require_dependency 'time_entry_activity' |
|
138 | require_dependency 'time_entry_activity' | |
131 | require_dependency 'document_category' |
|
139 | require_dependency 'document_category' | |
132 | require_dependency 'issue_priority' |
|
140 | require_dependency 'issue_priority' |
@@ -1,16 +1,19 | |||||
1 | <%= error_messages_for 'enumeration' %> |
|
1 | <%= error_messages_for 'enumeration' %> | |
2 | <div class="box"> |
|
2 | <div class="box"> | |
3 | <!--[form:optvalue]--> |
|
3 | <!--[form:optvalue]--> | |
4 | <%= hidden_field 'enumeration', 'type' %> |
|
4 | <%= hidden_field 'enumeration', 'type' %> | |
5 |
|
5 | |||
6 | <p><label for="enumeration_name"><%=l(:field_name)%></label> |
|
6 | <p><label for="enumeration_name"><%=l(:field_name)%></label> | |
7 | <%= text_field 'enumeration', 'name' %></p> |
|
7 | <%= text_field 'enumeration', 'name' %></p> | |
8 |
|
8 | |||
|
9 | <p><label for="enumeration_active"><%=l(:field_active)%></label> | |||
|
10 | <%= check_box 'enumeration', 'active' %></p> | |||
|
11 | ||||
9 | <p><label for="enumeration_is_default"><%=l(:field_is_default)%></label> |
|
12 | <p><label for="enumeration_is_default"><%=l(:field_is_default)%></label> | |
10 | <%= check_box 'enumeration', 'is_default' %></p> |
|
13 | <%= check_box 'enumeration', 'is_default' %></p> | |
11 | <!--[eoform:optvalue]--> |
|
14 | <!--[eoform:optvalue]--> | |
12 |
|
15 | |||
13 | <% @enumeration.custom_field_values.each do |value| %> |
|
16 | <% @enumeration.custom_field_values.each do |value| %> | |
14 | <p><%= custom_field_tag_with_label :enumeration, value %></p> |
|
17 | <p><%= custom_field_tag_with_label :enumeration, value %></p> | |
15 | <% end %> |
|
18 | <% end %> | |
16 | </div> |
|
19 | </div> |
@@ -1,29 +1,37 | |||||
1 | <h2><%=l(:label_enumerations)%></h2> |
|
1 | <h2><%=l(:label_enumerations)%></h2> | |
2 |
|
2 | |||
3 | <% Enumeration.get_subclasses.each do |klass| %> |
|
3 | <% Enumeration.get_subclasses.each do |klass| %> | |
4 | <h3><%= l(klass::OptionName) %></h3> |
|
4 | <h3><%= l(klass::OptionName) %></h3> | |
5 |
|
5 | |||
6 | <% enumerations = klass.all %> |
|
6 | <% enumerations = klass.all %> | |
7 | <% if enumerations.any? %> |
|
7 | <% if enumerations.any? %> | |
8 | <table class="list"> |
|
8 | <table class="list"> | |
|
9 | <tr> | |||
|
10 | <th><%= l(:field_name) %></th> | |||
|
11 | <th style="width:15%;"><%= l(:field_is_default) %></th> | |||
|
12 | <th style="width:15%;"><%= l(:field_active) %></th> | |||
|
13 | <th style="width:15%;"></th> | |||
|
14 | <th align="center" style="width:10%;"> </th> | |||
|
15 | </tr> | |||
9 | <% enumerations.each do |enumeration| %> |
|
16 | <% enumerations.each do |enumeration| %> | |
10 | <tr class="<%= cycle('odd', 'even') %>"> |
|
17 | <tr class="<%= cycle('odd', 'even') %>"> | |
11 | <td><%= link_to h(enumeration), :action => 'edit', :id => enumeration %></td> |
|
18 | <td><%= link_to h(enumeration), :action => 'edit', :id => enumeration %></td> | |
12 | <td style="width:15%;"><%= image_tag('true.png') if enumeration.is_default? %></td> |
|
19 | <td style="width:15%;"><%= image_tag('true.png') if enumeration.is_default? %></td> | |
|
20 | <td style="width:15%;"><%= image_tag('true.png') if enumeration.active? %></td> | |||
13 | <td style="width:15%;"><%= reorder_links('enumeration', {:action => 'update', :id => enumeration}) %></td> |
|
21 | <td style="width:15%;"><%= reorder_links('enumeration', {:action => 'update', :id => enumeration}) %></td> | |
14 | <td class="buttons"> |
|
22 | <td class="buttons"> | |
15 | <%= link_to l(:button_delete), { :action => 'destroy', :id => enumeration }, |
|
23 | <%= link_to l(:button_delete), { :action => 'destroy', :id => enumeration }, | |
16 | :method => :post, |
|
24 | :method => :post, | |
17 | :confirm => l(:text_are_you_sure), |
|
25 | :confirm => l(:text_are_you_sure), | |
18 | :class => 'icon icon-del' %> |
|
26 | :class => 'icon icon-del' %> | |
19 | </td> |
|
27 | </td> | |
20 | </tr> |
|
28 | </tr> | |
21 | <% end %> |
|
29 | <% end %> | |
22 | </table> |
|
30 | </table> | |
23 | <% reset_cycle %> |
|
31 | <% reset_cycle %> | |
24 | <% end %> |
|
32 | <% end %> | |
25 |
|
33 | |||
26 | <p><%= link_to l(:label_enumeration_new), { :action => 'new', :type => klass.name } %></p> |
|
34 | <p><%= link_to l(:label_enumeration_new), { :action => 'new', :type => klass.name } %></p> | |
27 | <% end %> |
|
35 | <% end %> | |
28 |
|
36 | |||
29 | <% html_title(l(:label_enumerations)) -%> |
|
37 | <% html_title(l(:label_enumerations)) -%> |
@@ -1,21 +1,21 | |||||
1 | <h2><%= l(:label_spent_time) %></h2> |
|
1 | <h2><%= l(:label_spent_time) %></h2> | |
2 |
|
2 | |||
3 | <% labelled_tabular_form_for :time_entry, @time_entry, :url => {:action => 'edit', :id => @time_entry, :project_id => @time_entry.project} do |f| %> |
|
3 | <% labelled_tabular_form_for :time_entry, @time_entry, :url => {:action => 'edit', :id => @time_entry, :project_id => @time_entry.project} do |f| %> | |
4 | <%= error_messages_for 'time_entry' %> |
|
4 | <%= error_messages_for 'time_entry' %> | |
5 | <%= back_url_hidden_field_tag %> |
|
5 | <%= back_url_hidden_field_tag %> | |
6 |
|
6 | |||
7 | <div class="box"> |
|
7 | <div class="box"> | |
8 | <p><%= f.text_field :issue_id, :size => 6 %> <em><%= h("#{@time_entry.issue.tracker.name} ##{@time_entry.issue.id}: #{@time_entry.issue.subject}") if @time_entry.issue %></em></p> |
|
8 | <p><%= f.text_field :issue_id, :size => 6 %> <em><%= h("#{@time_entry.issue.tracker.name} ##{@time_entry.issue.id}: #{@time_entry.issue.subject}") if @time_entry.issue %></em></p> | |
9 | <p><%= f.text_field :spent_on, :size => 10, :required => true %><%= calendar_for('time_entry_spent_on') %></p> |
|
9 | <p><%= f.text_field :spent_on, :size => 10, :required => true %><%= calendar_for('time_entry_spent_on') %></p> | |
10 | <p><%= f.text_field :hours, :size => 6, :required => true %></p> |
|
10 | <p><%= f.text_field :hours, :size => 6, :required => true %></p> | |
11 | <p><%= f.text_field :comments, :size => 100 %></p> |
|
11 | <p><%= f.text_field :comments, :size => 100 %></p> | |
12 | <p><%= f.select :activity_id, activity_collection_for_select_options, :required => true %></p> |
|
12 | <p><%= f.select :activity_id, activity_collection_for_select_options(@time_entry), :required => true %></p> | |
13 | <% @time_entry.custom_field_values.each do |value| %> |
|
13 | <% @time_entry.custom_field_values.each do |value| %> | |
14 | <p><%= custom_field_tag_with_label :time_entry, value %></p> |
|
14 | <p><%= custom_field_tag_with_label :time_entry, value %></p> | |
15 | <% end %> |
|
15 | <% end %> | |
16 | <%= call_hook(:view_timelog_edit_form_bottom, { :time_entry => @time_entry, :form => f }) %> |
|
16 | <%= call_hook(:view_timelog_edit_form_bottom, { :time_entry => @time_entry, :form => f }) %> | |
17 | </div> |
|
17 | </div> | |
18 |
|
18 | |||
19 | <%= submit_tag l(:button_save) %> |
|
19 | <%= submit_tag l(:button_save) %> | |
20 |
|
20 | |||
21 | <% end %> |
|
21 | <% end %> |
@@ -1,830 +1,832 | |||||
1 | en: |
|
1 | en: | |
2 | date: |
|
2 | date: | |
3 | formats: |
|
3 | formats: | |
4 | # Use the strftime parameters for formats. |
|
4 | # Use the strftime parameters for formats. | |
5 | # When no format has been given, it uses default. |
|
5 | # When no format has been given, it uses default. | |
6 | # You can provide other formats here if you like! |
|
6 | # You can provide other formats here if you like! | |
7 | default: "%m/%d/%Y" |
|
7 | default: "%m/%d/%Y" | |
8 | short: "%b %d" |
|
8 | short: "%b %d" | |
9 | long: "%B %d, %Y" |
|
9 | long: "%B %d, %Y" | |
10 |
|
10 | |||
11 | day_names: [Sunday, Monday, Tuesday, Wednesday, Thursday, Friday, Saturday] |
|
11 | day_names: [Sunday, Monday, Tuesday, Wednesday, Thursday, Friday, Saturday] | |
12 | abbr_day_names: [Sun, Mon, Tue, Wed, Thu, Fri, Sat] |
|
12 | abbr_day_names: [Sun, Mon, Tue, Wed, Thu, Fri, Sat] | |
13 |
|
13 | |||
14 | # Don't forget the nil at the beginning; there's no such thing as a 0th month |
|
14 | # Don't forget the nil at the beginning; there's no such thing as a 0th month | |
15 | month_names: [~, January, February, March, April, May, June, July, August, September, October, November, December] |
|
15 | month_names: [~, January, February, March, April, May, June, July, August, September, October, November, December] | |
16 | abbr_month_names: [~, Jan, Feb, Mar, Apr, May, Jun, Jul, Aug, Sep, Oct, Nov, Dec] |
|
16 | abbr_month_names: [~, Jan, Feb, Mar, Apr, May, Jun, Jul, Aug, Sep, Oct, Nov, Dec] | |
17 | # Used in date_select and datime_select. |
|
17 | # Used in date_select and datime_select. | |
18 | order: [ :year, :month, :day ] |
|
18 | order: [ :year, :month, :day ] | |
19 |
|
19 | |||
20 | time: |
|
20 | time: | |
21 | formats: |
|
21 | formats: | |
22 | default: "%m/%d/%Y %I:%M %p" |
|
22 | default: "%m/%d/%Y %I:%M %p" | |
23 | time: "%I:%M %p" |
|
23 | time: "%I:%M %p" | |
24 | short: "%d %b %H:%M" |
|
24 | short: "%d %b %H:%M" | |
25 | long: "%B %d, %Y %H:%M" |
|
25 | long: "%B %d, %Y %H:%M" | |
26 | am: "am" |
|
26 | am: "am" | |
27 | pm: "pm" |
|
27 | pm: "pm" | |
28 |
|
28 | |||
29 | datetime: |
|
29 | datetime: | |
30 | distance_in_words: |
|
30 | distance_in_words: | |
31 | half_a_minute: "half a minute" |
|
31 | half_a_minute: "half a minute" | |
32 | less_than_x_seconds: |
|
32 | less_than_x_seconds: | |
33 | one: "less than 1 second" |
|
33 | one: "less than 1 second" | |
34 | other: "less than {{count}} seconds" |
|
34 | other: "less than {{count}} seconds" | |
35 | x_seconds: |
|
35 | x_seconds: | |
36 | one: "1 second" |
|
36 | one: "1 second" | |
37 | other: "{{count}} seconds" |
|
37 | other: "{{count}} seconds" | |
38 | less_than_x_minutes: |
|
38 | less_than_x_minutes: | |
39 | one: "less than a minute" |
|
39 | one: "less than a minute" | |
40 | other: "less than {{count}} minutes" |
|
40 | other: "less than {{count}} minutes" | |
41 | x_minutes: |
|
41 | x_minutes: | |
42 | one: "1 minute" |
|
42 | one: "1 minute" | |
43 | other: "{{count}} minutes" |
|
43 | other: "{{count}} minutes" | |
44 | about_x_hours: |
|
44 | about_x_hours: | |
45 | one: "about 1 hour" |
|
45 | one: "about 1 hour" | |
46 | other: "about {{count}} hours" |
|
46 | other: "about {{count}} hours" | |
47 | x_days: |
|
47 | x_days: | |
48 | one: "1 day" |
|
48 | one: "1 day" | |
49 | other: "{{count}} days" |
|
49 | other: "{{count}} days" | |
50 | about_x_months: |
|
50 | about_x_months: | |
51 | one: "about 1 month" |
|
51 | one: "about 1 month" | |
52 | other: "about {{count}} months" |
|
52 | other: "about {{count}} months" | |
53 | x_months: |
|
53 | x_months: | |
54 | one: "1 month" |
|
54 | one: "1 month" | |
55 | other: "{{count}} months" |
|
55 | other: "{{count}} months" | |
56 | about_x_years: |
|
56 | about_x_years: | |
57 | one: "about 1 year" |
|
57 | one: "about 1 year" | |
58 | other: "about {{count}} years" |
|
58 | other: "about {{count}} years" | |
59 | over_x_years: |
|
59 | over_x_years: | |
60 | one: "over 1 year" |
|
60 | one: "over 1 year" | |
61 | other: "over {{count}} years" |
|
61 | other: "over {{count}} years" | |
62 |
|
62 | |||
63 | number: |
|
63 | number: | |
64 | human: |
|
64 | human: | |
65 | format: |
|
65 | format: | |
66 | delimiter: "" |
|
66 | delimiter: "" | |
67 | precision: 1 |
|
67 | precision: 1 | |
68 | storage_units: |
|
68 | storage_units: | |
69 | format: "%n %u" |
|
69 | format: "%n %u" | |
70 | units: |
|
70 | units: | |
71 | byte: |
|
71 | byte: | |
72 | one: "Byte" |
|
72 | one: "Byte" | |
73 | other: "Bytes" |
|
73 | other: "Bytes" | |
74 | kb: "KB" |
|
74 | kb: "KB" | |
75 | mb: "MB" |
|
75 | mb: "MB" | |
76 | gb: "GB" |
|
76 | gb: "GB" | |
77 | tb: "TB" |
|
77 | tb: "TB" | |
78 |
|
78 | |||
79 |
|
79 | |||
80 | # Used in array.to_sentence. |
|
80 | # Used in array.to_sentence. | |
81 | support: |
|
81 | support: | |
82 | array: |
|
82 | array: | |
83 | sentence_connector: "and" |
|
83 | sentence_connector: "and" | |
84 | skip_last_comma: false |
|
84 | skip_last_comma: false | |
85 |
|
85 | |||
86 | activerecord: |
|
86 | activerecord: | |
87 | errors: |
|
87 | errors: | |
88 | messages: |
|
88 | messages: | |
89 | inclusion: "is not included in the list" |
|
89 | inclusion: "is not included in the list" | |
90 | exclusion: "is reserved" |
|
90 | exclusion: "is reserved" | |
91 | invalid: "is invalid" |
|
91 | invalid: "is invalid" | |
92 | confirmation: "doesn't match confirmation" |
|
92 | confirmation: "doesn't match confirmation" | |
93 | accepted: "must be accepted" |
|
93 | accepted: "must be accepted" | |
94 | empty: "can't be empty" |
|
94 | empty: "can't be empty" | |
95 | blank: "can't be blank" |
|
95 | blank: "can't be blank" | |
96 | too_long: "is too long (maximum is {{count}} characters)" |
|
96 | too_long: "is too long (maximum is {{count}} characters)" | |
97 | too_short: "is too short (minimum is {{count}} characters)" |
|
97 | too_short: "is too short (minimum is {{count}} characters)" | |
98 | wrong_length: "is the wrong length (should be {{count}} characters)" |
|
98 | wrong_length: "is the wrong length (should be {{count}} characters)" | |
99 | taken: "has already been taken" |
|
99 | taken: "has already been taken" | |
100 | not_a_number: "is not a number" |
|
100 | not_a_number: "is not a number" | |
101 | not_a_date: "is not a valid date" |
|
101 | not_a_date: "is not a valid date" | |
102 | greater_than: "must be greater than {{count}}" |
|
102 | greater_than: "must be greater than {{count}}" | |
103 | greater_than_or_equal_to: "must be greater than or equal to {{count}}" |
|
103 | greater_than_or_equal_to: "must be greater than or equal to {{count}}" | |
104 | equal_to: "must be equal to {{count}}" |
|
104 | equal_to: "must be equal to {{count}}" | |
105 | less_than: "must be less than {{count}}" |
|
105 | less_than: "must be less than {{count}}" | |
106 | less_than_or_equal_to: "must be less than or equal to {{count}}" |
|
106 | less_than_or_equal_to: "must be less than or equal to {{count}}" | |
107 | odd: "must be odd" |
|
107 | odd: "must be odd" | |
108 | even: "must be even" |
|
108 | even: "must be even" | |
109 | greater_than_start_date: "must be greater than start date" |
|
109 | greater_than_start_date: "must be greater than start date" | |
110 | not_same_project: "doesn't belong to the same project" |
|
110 | not_same_project: "doesn't belong to the same project" | |
111 | circular_dependency: "This relation would create a circular dependency" |
|
111 | circular_dependency: "This relation would create a circular dependency" | |
112 |
|
112 | |||
113 | actionview_instancetag_blank_option: Please select |
|
113 | actionview_instancetag_blank_option: Please select | |
114 |
|
114 | |||
115 | general_text_No: 'No' |
|
115 | general_text_No: 'No' | |
116 | general_text_Yes: 'Yes' |
|
116 | general_text_Yes: 'Yes' | |
117 | general_text_no: 'no' |
|
117 | general_text_no: 'no' | |
118 | general_text_yes: 'yes' |
|
118 | general_text_yes: 'yes' | |
119 | general_lang_name: 'English' |
|
119 | general_lang_name: 'English' | |
120 | general_csv_separator: ',' |
|
120 | general_csv_separator: ',' | |
121 | general_csv_decimal_separator: '.' |
|
121 | general_csv_decimal_separator: '.' | |
122 | general_csv_encoding: ISO-8859-1 |
|
122 | general_csv_encoding: ISO-8859-1 | |
123 | general_pdf_encoding: ISO-8859-1 |
|
123 | general_pdf_encoding: ISO-8859-1 | |
124 | general_first_day_of_week: '7' |
|
124 | general_first_day_of_week: '7' | |
125 |
|
125 | |||
126 | notice_account_updated: Account was successfully updated. |
|
126 | notice_account_updated: Account was successfully updated. | |
127 | notice_account_invalid_creditentials: Invalid user or password |
|
127 | notice_account_invalid_creditentials: Invalid user or password | |
128 | notice_account_password_updated: Password was successfully updated. |
|
128 | notice_account_password_updated: Password was successfully updated. | |
129 | notice_account_wrong_password: Wrong password |
|
129 | notice_account_wrong_password: Wrong password | |
130 | notice_account_register_done: Account was successfully created. To activate your account, click on the link that was emailed to you. |
|
130 | notice_account_register_done: Account was successfully created. To activate your account, click on the link that was emailed to you. | |
131 | notice_account_unknown_email: Unknown user. |
|
131 | notice_account_unknown_email: Unknown user. | |
132 | notice_can_t_change_password: This account uses an external authentication source. Impossible to change the password. |
|
132 | notice_can_t_change_password: This account uses an external authentication source. Impossible to change the password. | |
133 | notice_account_lost_email_sent: An email with instructions to choose a new password has been sent to you. |
|
133 | notice_account_lost_email_sent: An email with instructions to choose a new password has been sent to you. | |
134 | notice_account_activated: Your account has been activated. You can now log in. |
|
134 | notice_account_activated: Your account has been activated. You can now log in. | |
135 | notice_successful_create: Successful creation. |
|
135 | notice_successful_create: Successful creation. | |
136 | notice_successful_update: Successful update. |
|
136 | notice_successful_update: Successful update. | |
137 | notice_successful_delete: Successful deletion. |
|
137 | notice_successful_delete: Successful deletion. | |
138 | notice_successful_connection: Successful connection. |
|
138 | notice_successful_connection: Successful connection. | |
139 | notice_file_not_found: The page you were trying to access doesn't exist or has been removed. |
|
139 | notice_file_not_found: The page you were trying to access doesn't exist or has been removed. | |
140 | notice_locking_conflict: Data has been updated by another user. |
|
140 | notice_locking_conflict: Data has been updated by another user. | |
141 | notice_not_authorized: You are not authorized to access this page. |
|
141 | notice_not_authorized: You are not authorized to access this page. | |
142 | notice_email_sent: "An email was sent to {{value}}" |
|
142 | notice_email_sent: "An email was sent to {{value}}" | |
143 | notice_email_error: "An error occurred while sending mail ({{value}})" |
|
143 | notice_email_error: "An error occurred while sending mail ({{value}})" | |
144 | notice_feeds_access_key_reseted: Your RSS access key was reset. |
|
144 | notice_feeds_access_key_reseted: Your RSS access key was reset. | |
145 | notice_failed_to_save_issues: "Failed to save {{count}} issue(s) on {{total}} selected: {{ids}}." |
|
145 | notice_failed_to_save_issues: "Failed to save {{count}} issue(s) on {{total}} selected: {{ids}}." | |
146 | notice_no_issue_selected: "No issue is selected! Please, check the issues you want to edit." |
|
146 | notice_no_issue_selected: "No issue is selected! Please, check the issues you want to edit." | |
147 | notice_account_pending: "Your account was created and is now pending administrator approval." |
|
147 | notice_account_pending: "Your account was created and is now pending administrator approval." | |
148 | notice_default_data_loaded: Default configuration successfully loaded. |
|
148 | notice_default_data_loaded: Default configuration successfully loaded. | |
149 | notice_unable_delete_version: Unable to delete version. |
|
149 | notice_unable_delete_version: Unable to delete version. | |
150 |
|
150 | |||
151 | error_can_t_load_default_data: "Default configuration could not be loaded: {{value}}" |
|
151 | error_can_t_load_default_data: "Default configuration could not be loaded: {{value}}" | |
152 | error_scm_not_found: "The entry or revision was not found in the repository." |
|
152 | error_scm_not_found: "The entry or revision was not found in the repository." | |
153 | error_scm_command_failed: "An error occurred when trying to access the repository: {{value}}" |
|
153 | error_scm_command_failed: "An error occurred when trying to access the repository: {{value}}" | |
154 | error_scm_annotate: "The entry does not exist or can not be annotated." |
|
154 | error_scm_annotate: "The entry does not exist or can not be annotated." | |
155 | error_issue_not_found_in_project: 'The issue was not found or does not belong to this project' |
|
155 | error_issue_not_found_in_project: 'The issue was not found or does not belong to this project' | |
156 | error_no_tracker_in_project: 'No tracker is associated to this project. Please check the Project settings.' |
|
156 | error_no_tracker_in_project: 'No tracker is associated to this project. Please check the Project settings.' | |
157 | error_no_default_issue_status: 'No default issue status is defined. Please check your configuration (Go to "Administration -> Issue statuses").' |
|
157 | error_no_default_issue_status: 'No default issue status is defined. Please check your configuration (Go to "Administration -> Issue statuses").' | |
158 |
|
158 | |||
159 | warning_attachments_not_saved: "{{count}} file(s) could not be saved." |
|
159 | warning_attachments_not_saved: "{{count}} file(s) could not be saved." | |
160 |
|
160 | |||
161 | mail_subject_lost_password: "Your {{value}} password" |
|
161 | mail_subject_lost_password: "Your {{value}} password" | |
162 | mail_body_lost_password: 'To change your password, click on the following link:' |
|
162 | mail_body_lost_password: 'To change your password, click on the following link:' | |
163 | mail_subject_register: "Your {{value}} account activation" |
|
163 | mail_subject_register: "Your {{value}} account activation" | |
164 | mail_body_register: 'To activate your account, click on the following link:' |
|
164 | mail_body_register: 'To activate your account, click on the following link:' | |
165 | mail_body_account_information_external: "You can use your {{value}} account to log in." |
|
165 | mail_body_account_information_external: "You can use your {{value}} account to log in." | |
166 | mail_body_account_information: Your account information |
|
166 | mail_body_account_information: Your account information | |
167 | mail_subject_account_activation_request: "{{value}} account activation request" |
|
167 | mail_subject_account_activation_request: "{{value}} account activation request" | |
168 | mail_body_account_activation_request: "A new user ({{value}}) has registered. The account is pending your approval:" |
|
168 | mail_body_account_activation_request: "A new user ({{value}}) has registered. The account is pending your approval:" | |
169 | mail_subject_reminder: "{{count}} issue(s) due in the next days" |
|
169 | mail_subject_reminder: "{{count}} issue(s) due in the next days" | |
170 | mail_body_reminder: "{{count}} issue(s) that are assigned to you are due in the next {{days}} days:" |
|
170 | mail_body_reminder: "{{count}} issue(s) that are assigned to you are due in the next {{days}} days:" | |
171 | mail_subject_wiki_content_added: "'{{page}}' wiki page has been added" |
|
171 | mail_subject_wiki_content_added: "'{{page}}' wiki page has been added" | |
172 | mail_body_wiki_content_added: "The '{{page}}' wiki page has been added by {{author}}." |
|
172 | mail_body_wiki_content_added: "The '{{page}}' wiki page has been added by {{author}}." | |
173 | mail_subject_wiki_content_updated: "'{{page}}' wiki page has been updated" |
|
173 | mail_subject_wiki_content_updated: "'{{page}}' wiki page has been updated" | |
174 | mail_body_wiki_content_updated: "The '{{page}}' wiki page has been updated by {{author}}." |
|
174 | mail_body_wiki_content_updated: "The '{{page}}' wiki page has been updated by {{author}}." | |
175 |
|
175 | |||
176 | gui_validation_error: 1 error |
|
176 | gui_validation_error: 1 error | |
177 | gui_validation_error_plural: "{{count}} errors" |
|
177 | gui_validation_error_plural: "{{count}} errors" | |
178 |
|
178 | |||
179 | field_name: Name |
|
179 | field_name: Name | |
180 | field_description: Description |
|
180 | field_description: Description | |
181 | field_summary: Summary |
|
181 | field_summary: Summary | |
182 | field_is_required: Required |
|
182 | field_is_required: Required | |
183 | field_firstname: Firstname |
|
183 | field_firstname: Firstname | |
184 | field_lastname: Lastname |
|
184 | field_lastname: Lastname | |
185 | field_mail: Email |
|
185 | field_mail: Email | |
186 | field_filename: File |
|
186 | field_filename: File | |
187 | field_filesize: Size |
|
187 | field_filesize: Size | |
188 | field_downloads: Downloads |
|
188 | field_downloads: Downloads | |
189 | field_author: Author |
|
189 | field_author: Author | |
190 | field_created_on: Created |
|
190 | field_created_on: Created | |
191 | field_updated_on: Updated |
|
191 | field_updated_on: Updated | |
192 | field_field_format: Format |
|
192 | field_field_format: Format | |
193 | field_is_for_all: For all projects |
|
193 | field_is_for_all: For all projects | |
194 | field_possible_values: Possible values |
|
194 | field_possible_values: Possible values | |
195 | field_regexp: Regular expression |
|
195 | field_regexp: Regular expression | |
196 | field_min_length: Minimum length |
|
196 | field_min_length: Minimum length | |
197 | field_max_length: Maximum length |
|
197 | field_max_length: Maximum length | |
198 | field_value: Value |
|
198 | field_value: Value | |
199 | field_category: Category |
|
199 | field_category: Category | |
200 | field_title: Title |
|
200 | field_title: Title | |
201 | field_project: Project |
|
201 | field_project: Project | |
202 | field_issue: Issue |
|
202 | field_issue: Issue | |
203 | field_status: Status |
|
203 | field_status: Status | |
204 | field_notes: Notes |
|
204 | field_notes: Notes | |
205 | field_is_closed: Issue closed |
|
205 | field_is_closed: Issue closed | |
206 | field_is_default: Default value |
|
206 | field_is_default: Default value | |
207 | field_tracker: Tracker |
|
207 | field_tracker: Tracker | |
208 | field_subject: Subject |
|
208 | field_subject: Subject | |
209 | field_due_date: Due date |
|
209 | field_due_date: Due date | |
210 | field_assigned_to: Assigned to |
|
210 | field_assigned_to: Assigned to | |
211 | field_priority: Priority |
|
211 | field_priority: Priority | |
212 | field_fixed_version: Target version |
|
212 | field_fixed_version: Target version | |
213 | field_user: User |
|
213 | field_user: User | |
214 | field_role: Role |
|
214 | field_role: Role | |
215 | field_homepage: Homepage |
|
215 | field_homepage: Homepage | |
216 | field_is_public: Public |
|
216 | field_is_public: Public | |
217 | field_parent: Subproject of |
|
217 | field_parent: Subproject of | |
218 | field_is_in_chlog: Issues displayed in changelog |
|
218 | field_is_in_chlog: Issues displayed in changelog | |
219 | field_is_in_roadmap: Issues displayed in roadmap |
|
219 | field_is_in_roadmap: Issues displayed in roadmap | |
220 | field_login: Login |
|
220 | field_login: Login | |
221 | field_mail_notification: Email notifications |
|
221 | field_mail_notification: Email notifications | |
222 | field_admin: Administrator |
|
222 | field_admin: Administrator | |
223 | field_last_login_on: Last connection |
|
223 | field_last_login_on: Last connection | |
224 | field_language: Language |
|
224 | field_language: Language | |
225 | field_effective_date: Date |
|
225 | field_effective_date: Date | |
226 | field_password: Password |
|
226 | field_password: Password | |
227 | field_new_password: New password |
|
227 | field_new_password: New password | |
228 | field_password_confirmation: Confirmation |
|
228 | field_password_confirmation: Confirmation | |
229 | field_version: Version |
|
229 | field_version: Version | |
230 | field_type: Type |
|
230 | field_type: Type | |
231 | field_host: Host |
|
231 | field_host: Host | |
232 | field_port: Port |
|
232 | field_port: Port | |
233 | field_account: Account |
|
233 | field_account: Account | |
234 | field_base_dn: Base DN |
|
234 | field_base_dn: Base DN | |
235 | field_attr_login: Login attribute |
|
235 | field_attr_login: Login attribute | |
236 | field_attr_firstname: Firstname attribute |
|
236 | field_attr_firstname: Firstname attribute | |
237 | field_attr_lastname: Lastname attribute |
|
237 | field_attr_lastname: Lastname attribute | |
238 | field_attr_mail: Email attribute |
|
238 | field_attr_mail: Email attribute | |
239 | field_onthefly: On-the-fly user creation |
|
239 | field_onthefly: On-the-fly user creation | |
240 | field_start_date: Start |
|
240 | field_start_date: Start | |
241 | field_done_ratio: % Done |
|
241 | field_done_ratio: % Done | |
242 | field_auth_source: Authentication mode |
|
242 | field_auth_source: Authentication mode | |
243 | field_hide_mail: Hide my email address |
|
243 | field_hide_mail: Hide my email address | |
244 | field_comments: Comment |
|
244 | field_comments: Comment | |
245 | field_url: URL |
|
245 | field_url: URL | |
246 | field_start_page: Start page |
|
246 | field_start_page: Start page | |
247 | field_subproject: Subproject |
|
247 | field_subproject: Subproject | |
248 | field_hours: Hours |
|
248 | field_hours: Hours | |
249 | field_activity: Activity |
|
249 | field_activity: Activity | |
250 | field_spent_on: Date |
|
250 | field_spent_on: Date | |
251 | field_identifier: Identifier |
|
251 | field_identifier: Identifier | |
252 | field_is_filter: Used as a filter |
|
252 | field_is_filter: Used as a filter | |
253 | field_issue_to: Related issue |
|
253 | field_issue_to: Related issue | |
254 | field_delay: Delay |
|
254 | field_delay: Delay | |
255 | field_assignable: Issues can be assigned to this role |
|
255 | field_assignable: Issues can be assigned to this role | |
256 | field_redirect_existing_links: Redirect existing links |
|
256 | field_redirect_existing_links: Redirect existing links | |
257 | field_estimated_hours: Estimated time |
|
257 | field_estimated_hours: Estimated time | |
258 | field_column_names: Columns |
|
258 | field_column_names: Columns | |
259 | field_time_zone: Time zone |
|
259 | field_time_zone: Time zone | |
260 | field_searchable: Searchable |
|
260 | field_searchable: Searchable | |
261 | field_default_value: Default value |
|
261 | field_default_value: Default value | |
262 | field_comments_sorting: Display comments |
|
262 | field_comments_sorting: Display comments | |
263 | field_parent_title: Parent page |
|
263 | field_parent_title: Parent page | |
264 | field_editable: Editable |
|
264 | field_editable: Editable | |
265 | field_watcher: Watcher |
|
265 | field_watcher: Watcher | |
266 | field_identity_url: OpenID URL |
|
266 | field_identity_url: OpenID URL | |
267 | field_content: Content |
|
267 | field_content: Content | |
268 | field_group_by: Group results by |
|
268 | field_group_by: Group results by | |
269 |
|
269 | |||
270 | setting_app_title: Application title |
|
270 | setting_app_title: Application title | |
271 | setting_app_subtitle: Application subtitle |
|
271 | setting_app_subtitle: Application subtitle | |
272 | setting_welcome_text: Welcome text |
|
272 | setting_welcome_text: Welcome text | |
273 | setting_default_language: Default language |
|
273 | setting_default_language: Default language | |
274 | setting_login_required: Authentication required |
|
274 | setting_login_required: Authentication required | |
275 | setting_self_registration: Self-registration |
|
275 | setting_self_registration: Self-registration | |
276 | setting_attachment_max_size: Attachment max. size |
|
276 | setting_attachment_max_size: Attachment max. size | |
277 | setting_issues_export_limit: Issues export limit |
|
277 | setting_issues_export_limit: Issues export limit | |
278 | setting_mail_from: Emission email address |
|
278 | setting_mail_from: Emission email address | |
279 | setting_bcc_recipients: Blind carbon copy recipients (bcc) |
|
279 | setting_bcc_recipients: Blind carbon copy recipients (bcc) | |
280 | setting_plain_text_mail: Plain text mail (no HTML) |
|
280 | setting_plain_text_mail: Plain text mail (no HTML) | |
281 | setting_host_name: Host name and path |
|
281 | setting_host_name: Host name and path | |
282 | setting_text_formatting: Text formatting |
|
282 | setting_text_formatting: Text formatting | |
283 | setting_wiki_compression: Wiki history compression |
|
283 | setting_wiki_compression: Wiki history compression | |
284 | setting_feeds_limit: Feed content limit |
|
284 | setting_feeds_limit: Feed content limit | |
285 | setting_default_projects_public: New projects are public by default |
|
285 | setting_default_projects_public: New projects are public by default | |
286 | setting_autofetch_changesets: Autofetch commits |
|
286 | setting_autofetch_changesets: Autofetch commits | |
287 | setting_sys_api_enabled: Enable WS for repository management |
|
287 | setting_sys_api_enabled: Enable WS for repository management | |
288 | setting_commit_ref_keywords: Referencing keywords |
|
288 | setting_commit_ref_keywords: Referencing keywords | |
289 | setting_commit_fix_keywords: Fixing keywords |
|
289 | setting_commit_fix_keywords: Fixing keywords | |
290 | setting_autologin: Autologin |
|
290 | setting_autologin: Autologin | |
291 | setting_date_format: Date format |
|
291 | setting_date_format: Date format | |
292 | setting_time_format: Time format |
|
292 | setting_time_format: Time format | |
293 | setting_cross_project_issue_relations: Allow cross-project issue relations |
|
293 | setting_cross_project_issue_relations: Allow cross-project issue relations | |
294 | setting_issue_list_default_columns: Default columns displayed on the issue list |
|
294 | setting_issue_list_default_columns: Default columns displayed on the issue list | |
295 | setting_repositories_encodings: Repositories encodings |
|
295 | setting_repositories_encodings: Repositories encodings | |
296 | setting_commit_logs_encoding: Commit messages encoding |
|
296 | setting_commit_logs_encoding: Commit messages encoding | |
297 | setting_emails_footer: Emails footer |
|
297 | setting_emails_footer: Emails footer | |
298 | setting_protocol: Protocol |
|
298 | setting_protocol: Protocol | |
299 | setting_per_page_options: Objects per page options |
|
299 | setting_per_page_options: Objects per page options | |
300 | setting_user_format: Users display format |
|
300 | setting_user_format: Users display format | |
301 | setting_activity_days_default: Days displayed on project activity |
|
301 | setting_activity_days_default: Days displayed on project activity | |
302 | setting_display_subprojects_issues: Display subprojects issues on main projects by default |
|
302 | setting_display_subprojects_issues: Display subprojects issues on main projects by default | |
303 | setting_enabled_scm: Enabled SCM |
|
303 | setting_enabled_scm: Enabled SCM | |
304 | setting_mail_handler_api_enabled: Enable WS for incoming emails |
|
304 | setting_mail_handler_api_enabled: Enable WS for incoming emails | |
305 | setting_mail_handler_api_key: API key |
|
305 | setting_mail_handler_api_key: API key | |
306 | setting_sequential_project_identifiers: Generate sequential project identifiers |
|
306 | setting_sequential_project_identifiers: Generate sequential project identifiers | |
307 | setting_gravatar_enabled: Use Gravatar user icons |
|
307 | setting_gravatar_enabled: Use Gravatar user icons | |
308 | setting_diff_max_lines_displayed: Max number of diff lines displayed |
|
308 | setting_diff_max_lines_displayed: Max number of diff lines displayed | |
309 | setting_file_max_size_displayed: Max size of text files displayed inline |
|
309 | setting_file_max_size_displayed: Max size of text files displayed inline | |
310 | setting_repository_log_display_limit: Maximum number of revisions displayed on file log |
|
310 | setting_repository_log_display_limit: Maximum number of revisions displayed on file log | |
311 | setting_openid: Allow OpenID login and registration |
|
311 | setting_openid: Allow OpenID login and registration | |
312 | setting_password_min_length: Minimum password length |
|
312 | setting_password_min_length: Minimum password length | |
313 | setting_new_project_user_role_id: Role given to a non-admin user who creates a project |
|
313 | setting_new_project_user_role_id: Role given to a non-admin user who creates a project | |
314 |
|
314 | |||
315 | permission_add_project: Create project |
|
315 | permission_add_project: Create project | |
316 | permission_edit_project: Edit project |
|
316 | permission_edit_project: Edit project | |
317 | permission_select_project_modules: Select project modules |
|
317 | permission_select_project_modules: Select project modules | |
318 | permission_manage_members: Manage members |
|
318 | permission_manage_members: Manage members | |
319 | permission_manage_versions: Manage versions |
|
319 | permission_manage_versions: Manage versions | |
320 | permission_manage_categories: Manage issue categories |
|
320 | permission_manage_categories: Manage issue categories | |
321 | permission_add_issues: Add issues |
|
321 | permission_add_issues: Add issues | |
322 | permission_edit_issues: Edit issues |
|
322 | permission_edit_issues: Edit issues | |
323 | permission_manage_issue_relations: Manage issue relations |
|
323 | permission_manage_issue_relations: Manage issue relations | |
324 | permission_add_issue_notes: Add notes |
|
324 | permission_add_issue_notes: Add notes | |
325 | permission_edit_issue_notes: Edit notes |
|
325 | permission_edit_issue_notes: Edit notes | |
326 | permission_edit_own_issue_notes: Edit own notes |
|
326 | permission_edit_own_issue_notes: Edit own notes | |
327 | permission_move_issues: Move issues |
|
327 | permission_move_issues: Move issues | |
328 | permission_delete_issues: Delete issues |
|
328 | permission_delete_issues: Delete issues | |
329 | permission_manage_public_queries: Manage public queries |
|
329 | permission_manage_public_queries: Manage public queries | |
330 | permission_save_queries: Save queries |
|
330 | permission_save_queries: Save queries | |
331 | permission_view_gantt: View gantt chart |
|
331 | permission_view_gantt: View gantt chart | |
332 | permission_view_calendar: View calender |
|
332 | permission_view_calendar: View calender | |
333 | permission_view_issue_watchers: View watchers list |
|
333 | permission_view_issue_watchers: View watchers list | |
334 | permission_add_issue_watchers: Add watchers |
|
334 | permission_add_issue_watchers: Add watchers | |
335 | permission_log_time: Log spent time |
|
335 | permission_log_time: Log spent time | |
336 | permission_view_time_entries: View spent time |
|
336 | permission_view_time_entries: View spent time | |
337 | permission_edit_time_entries: Edit time logs |
|
337 | permission_edit_time_entries: Edit time logs | |
338 | permission_edit_own_time_entries: Edit own time logs |
|
338 | permission_edit_own_time_entries: Edit own time logs | |
339 | permission_manage_news: Manage news |
|
339 | permission_manage_news: Manage news | |
340 | permission_comment_news: Comment news |
|
340 | permission_comment_news: Comment news | |
341 | permission_manage_documents: Manage documents |
|
341 | permission_manage_documents: Manage documents | |
342 | permission_view_documents: View documents |
|
342 | permission_view_documents: View documents | |
343 | permission_manage_files: Manage files |
|
343 | permission_manage_files: Manage files | |
344 | permission_view_files: View files |
|
344 | permission_view_files: View files | |
345 | permission_manage_wiki: Manage wiki |
|
345 | permission_manage_wiki: Manage wiki | |
346 | permission_rename_wiki_pages: Rename wiki pages |
|
346 | permission_rename_wiki_pages: Rename wiki pages | |
347 | permission_delete_wiki_pages: Delete wiki pages |
|
347 | permission_delete_wiki_pages: Delete wiki pages | |
348 | permission_view_wiki_pages: View wiki |
|
348 | permission_view_wiki_pages: View wiki | |
349 | permission_view_wiki_edits: View wiki history |
|
349 | permission_view_wiki_edits: View wiki history | |
350 | permission_edit_wiki_pages: Edit wiki pages |
|
350 | permission_edit_wiki_pages: Edit wiki pages | |
351 | permission_delete_wiki_pages_attachments: Delete attachments |
|
351 | permission_delete_wiki_pages_attachments: Delete attachments | |
352 | permission_protect_wiki_pages: Protect wiki pages |
|
352 | permission_protect_wiki_pages: Protect wiki pages | |
353 | permission_manage_repository: Manage repository |
|
353 | permission_manage_repository: Manage repository | |
354 | permission_browse_repository: Browse repository |
|
354 | permission_browse_repository: Browse repository | |
355 | permission_view_changesets: View changesets |
|
355 | permission_view_changesets: View changesets | |
356 | permission_commit_access: Commit access |
|
356 | permission_commit_access: Commit access | |
357 | permission_manage_boards: Manage boards |
|
357 | permission_manage_boards: Manage boards | |
358 | permission_view_messages: View messages |
|
358 | permission_view_messages: View messages | |
359 | permission_add_messages: Post messages |
|
359 | permission_add_messages: Post messages | |
360 | permission_edit_messages: Edit messages |
|
360 | permission_edit_messages: Edit messages | |
361 | permission_edit_own_messages: Edit own messages |
|
361 | permission_edit_own_messages: Edit own messages | |
362 | permission_delete_messages: Delete messages |
|
362 | permission_delete_messages: Delete messages | |
363 | permission_delete_own_messages: Delete own messages |
|
363 | permission_delete_own_messages: Delete own messages | |
364 |
|
364 | |||
365 | project_module_issue_tracking: Issue tracking |
|
365 | project_module_issue_tracking: Issue tracking | |
366 | project_module_time_tracking: Time tracking |
|
366 | project_module_time_tracking: Time tracking | |
367 | project_module_news: News |
|
367 | project_module_news: News | |
368 | project_module_documents: Documents |
|
368 | project_module_documents: Documents | |
369 | project_module_files: Files |
|
369 | project_module_files: Files | |
370 | project_module_wiki: Wiki |
|
370 | project_module_wiki: Wiki | |
371 | project_module_repository: Repository |
|
371 | project_module_repository: Repository | |
372 | project_module_boards: Boards |
|
372 | project_module_boards: Boards | |
373 |
|
373 | |||
374 | label_user: User |
|
374 | label_user: User | |
375 | label_user_plural: Users |
|
375 | label_user_plural: Users | |
376 | label_user_new: New user |
|
376 | label_user_new: New user | |
377 | label_project: Project |
|
377 | label_project: Project | |
378 | label_project_new: New project |
|
378 | label_project_new: New project | |
379 | label_project_plural: Projects |
|
379 | label_project_plural: Projects | |
380 | label_x_projects: |
|
380 | label_x_projects: | |
381 | zero: no projects |
|
381 | zero: no projects | |
382 | one: 1 project |
|
382 | one: 1 project | |
383 | other: "{{count}} projects" |
|
383 | other: "{{count}} projects" | |
384 | label_project_all: All Projects |
|
384 | label_project_all: All Projects | |
385 | label_project_latest: Latest projects |
|
385 | label_project_latest: Latest projects | |
386 | label_issue: Issue |
|
386 | label_issue: Issue | |
387 | label_issue_new: New issue |
|
387 | label_issue_new: New issue | |
388 | label_issue_plural: Issues |
|
388 | label_issue_plural: Issues | |
389 | label_issue_view_all: View all issues |
|
389 | label_issue_view_all: View all issues | |
390 | label_issues_by: "Issues by {{value}}" |
|
390 | label_issues_by: "Issues by {{value}}" | |
391 | label_issue_added: Issue added |
|
391 | label_issue_added: Issue added | |
392 | label_issue_updated: Issue updated |
|
392 | label_issue_updated: Issue updated | |
393 | label_document: Document |
|
393 | label_document: Document | |
394 | label_document_new: New document |
|
394 | label_document_new: New document | |
395 | label_document_plural: Documents |
|
395 | label_document_plural: Documents | |
396 | label_document_added: Document added |
|
396 | label_document_added: Document added | |
397 | label_role: Role |
|
397 | label_role: Role | |
398 | label_role_plural: Roles |
|
398 | label_role_plural: Roles | |
399 | label_role_new: New role |
|
399 | label_role_new: New role | |
400 | label_role_and_permissions: Roles and permissions |
|
400 | label_role_and_permissions: Roles and permissions | |
401 | label_member: Member |
|
401 | label_member: Member | |
402 | label_member_new: New member |
|
402 | label_member_new: New member | |
403 | label_member_plural: Members |
|
403 | label_member_plural: Members | |
404 | label_tracker: Tracker |
|
404 | label_tracker: Tracker | |
405 | label_tracker_plural: Trackers |
|
405 | label_tracker_plural: Trackers | |
406 | label_tracker_new: New tracker |
|
406 | label_tracker_new: New tracker | |
407 | label_workflow: Workflow |
|
407 | label_workflow: Workflow | |
408 | label_issue_status: Issue status |
|
408 | label_issue_status: Issue status | |
409 | label_issue_status_plural: Issue statuses |
|
409 | label_issue_status_plural: Issue statuses | |
410 | label_issue_status_new: New status |
|
410 | label_issue_status_new: New status | |
411 | label_issue_category: Issue category |
|
411 | label_issue_category: Issue category | |
412 | label_issue_category_plural: Issue categories |
|
412 | label_issue_category_plural: Issue categories | |
413 | label_issue_category_new: New category |
|
413 | label_issue_category_new: New category | |
414 | label_custom_field: Custom field |
|
414 | label_custom_field: Custom field | |
415 | label_custom_field_plural: Custom fields |
|
415 | label_custom_field_plural: Custom fields | |
416 | label_custom_field_new: New custom field |
|
416 | label_custom_field_new: New custom field | |
417 | label_enumerations: Enumerations |
|
417 | label_enumerations: Enumerations | |
418 | label_enumeration_new: New value |
|
418 | label_enumeration_new: New value | |
419 | label_information: Information |
|
419 | label_information: Information | |
420 | label_information_plural: Information |
|
420 | label_information_plural: Information | |
421 | label_please_login: Please log in |
|
421 | label_please_login: Please log in | |
422 | label_register: Register |
|
422 | label_register: Register | |
423 | label_login_with_open_id_option: or login with OpenID |
|
423 | label_login_with_open_id_option: or login with OpenID | |
424 | label_password_lost: Lost password |
|
424 | label_password_lost: Lost password | |
425 | label_home: Home |
|
425 | label_home: Home | |
426 | label_my_page: My page |
|
426 | label_my_page: My page | |
427 | label_my_account: My account |
|
427 | label_my_account: My account | |
428 | label_my_projects: My projects |
|
428 | label_my_projects: My projects | |
429 | label_administration: Administration |
|
429 | label_administration: Administration | |
430 | label_login: Sign in |
|
430 | label_login: Sign in | |
431 | label_logout: Sign out |
|
431 | label_logout: Sign out | |
432 | label_help: Help |
|
432 | label_help: Help | |
433 | label_reported_issues: Reported issues |
|
433 | label_reported_issues: Reported issues | |
434 | label_assigned_to_me_issues: Issues assigned to me |
|
434 | label_assigned_to_me_issues: Issues assigned to me | |
435 | label_last_login: Last connection |
|
435 | label_last_login: Last connection | |
436 | label_registered_on: Registered on |
|
436 | label_registered_on: Registered on | |
437 | label_activity: Activity |
|
437 | label_activity: Activity | |
438 | label_overall_activity: Overall activity |
|
438 | label_overall_activity: Overall activity | |
439 | label_user_activity: "{{value}}'s activity" |
|
439 | label_user_activity: "{{value}}'s activity" | |
440 | label_new: New |
|
440 | label_new: New | |
441 | label_logged_as: Logged in as |
|
441 | label_logged_as: Logged in as | |
442 | label_environment: Environment |
|
442 | label_environment: Environment | |
443 | label_authentication: Authentication |
|
443 | label_authentication: Authentication | |
444 | label_auth_source: Authentication mode |
|
444 | label_auth_source: Authentication mode | |
445 | label_auth_source_new: New authentication mode |
|
445 | label_auth_source_new: New authentication mode | |
446 | label_auth_source_plural: Authentication modes |
|
446 | label_auth_source_plural: Authentication modes | |
447 | label_subproject_plural: Subprojects |
|
447 | label_subproject_plural: Subprojects | |
448 | label_and_its_subprojects: "{{value}} and its subprojects" |
|
448 | label_and_its_subprojects: "{{value}} and its subprojects" | |
449 | label_min_max_length: Min - Max length |
|
449 | label_min_max_length: Min - Max length | |
450 | label_list: List |
|
450 | label_list: List | |
451 | label_date: Date |
|
451 | label_date: Date | |
452 | label_integer: Integer |
|
452 | label_integer: Integer | |
453 | label_float: Float |
|
453 | label_float: Float | |
454 | label_boolean: Boolean |
|
454 | label_boolean: Boolean | |
455 | label_string: Text |
|
455 | label_string: Text | |
456 | label_text: Long text |
|
456 | label_text: Long text | |
457 | label_attribute: Attribute |
|
457 | label_attribute: Attribute | |
458 | label_attribute_plural: Attributes |
|
458 | label_attribute_plural: Attributes | |
459 | label_download: "{{count}} Download" |
|
459 | label_download: "{{count}} Download" | |
460 | label_download_plural: "{{count}} Downloads" |
|
460 | label_download_plural: "{{count}} Downloads" | |
461 | label_no_data: No data to display |
|
461 | label_no_data: No data to display | |
462 | label_change_status: Change status |
|
462 | label_change_status: Change status | |
463 | label_history: History |
|
463 | label_history: History | |
464 | label_attachment: File |
|
464 | label_attachment: File | |
465 | label_attachment_new: New file |
|
465 | label_attachment_new: New file | |
466 | label_attachment_delete: Delete file |
|
466 | label_attachment_delete: Delete file | |
467 | label_attachment_plural: Files |
|
467 | label_attachment_plural: Files | |
468 | label_file_added: File added |
|
468 | label_file_added: File added | |
469 | label_report: Report |
|
469 | label_report: Report | |
470 | label_report_plural: Reports |
|
470 | label_report_plural: Reports | |
471 | label_news: News |
|
471 | label_news: News | |
472 | label_news_new: Add news |
|
472 | label_news_new: Add news | |
473 | label_news_plural: News |
|
473 | label_news_plural: News | |
474 | label_news_latest: Latest news |
|
474 | label_news_latest: Latest news | |
475 | label_news_view_all: View all news |
|
475 | label_news_view_all: View all news | |
476 | label_news_added: News added |
|
476 | label_news_added: News added | |
477 | label_change_log: Change log |
|
477 | label_change_log: Change log | |
478 | label_settings: Settings |
|
478 | label_settings: Settings | |
479 | label_overview: Overview |
|
479 | label_overview: Overview | |
480 | label_version: Version |
|
480 | label_version: Version | |
481 | label_version_new: New version |
|
481 | label_version_new: New version | |
482 | label_version_plural: Versions |
|
482 | label_version_plural: Versions | |
483 | label_confirmation: Confirmation |
|
483 | label_confirmation: Confirmation | |
484 | label_export_to: 'Also available in:' |
|
484 | label_export_to: 'Also available in:' | |
485 | label_read: Read... |
|
485 | label_read: Read... | |
486 | label_public_projects: Public projects |
|
486 | label_public_projects: Public projects | |
487 | label_open_issues: open |
|
487 | label_open_issues: open | |
488 | label_open_issues_plural: open |
|
488 | label_open_issues_plural: open | |
489 | label_closed_issues: closed |
|
489 | label_closed_issues: closed | |
490 | label_closed_issues_plural: closed |
|
490 | label_closed_issues_plural: closed | |
491 | label_x_open_issues_abbr_on_total: |
|
491 | label_x_open_issues_abbr_on_total: | |
492 | zero: 0 open / {{total}} |
|
492 | zero: 0 open / {{total}} | |
493 | one: 1 open / {{total}} |
|
493 | one: 1 open / {{total}} | |
494 | other: "{{count}} open / {{total}}" |
|
494 | other: "{{count}} open / {{total}}" | |
495 | label_x_open_issues_abbr: |
|
495 | label_x_open_issues_abbr: | |
496 | zero: 0 open |
|
496 | zero: 0 open | |
497 | one: 1 open |
|
497 | one: 1 open | |
498 | other: "{{count}} open" |
|
498 | other: "{{count}} open" | |
499 | label_x_closed_issues_abbr: |
|
499 | label_x_closed_issues_abbr: | |
500 | zero: 0 closed |
|
500 | zero: 0 closed | |
501 | one: 1 closed |
|
501 | one: 1 closed | |
502 | other: "{{count}} closed" |
|
502 | other: "{{count}} closed" | |
503 | label_total: Total |
|
503 | label_total: Total | |
504 | label_permissions: Permissions |
|
504 | label_permissions: Permissions | |
505 | label_current_status: Current status |
|
505 | label_current_status: Current status | |
506 | label_new_statuses_allowed: New statuses allowed |
|
506 | label_new_statuses_allowed: New statuses allowed | |
507 | label_all: all |
|
507 | label_all: all | |
508 | label_none: none |
|
508 | label_none: none | |
509 | label_nobody: nobody |
|
509 | label_nobody: nobody | |
510 | label_next: Next |
|
510 | label_next: Next | |
511 | label_previous: Previous |
|
511 | label_previous: Previous | |
512 | label_used_by: Used by |
|
512 | label_used_by: Used by | |
513 | label_details: Details |
|
513 | label_details: Details | |
514 | label_add_note: Add a note |
|
514 | label_add_note: Add a note | |
515 | label_per_page: Per page |
|
515 | label_per_page: Per page | |
516 | label_calendar: Calendar |
|
516 | label_calendar: Calendar | |
517 | label_months_from: months from |
|
517 | label_months_from: months from | |
518 | label_gantt: Gantt |
|
518 | label_gantt: Gantt | |
519 | label_internal: Internal |
|
519 | label_internal: Internal | |
520 | label_last_changes: "last {{count}} changes" |
|
520 | label_last_changes: "last {{count}} changes" | |
521 | label_change_view_all: View all changes |
|
521 | label_change_view_all: View all changes | |
522 | label_personalize_page: Personalize this page |
|
522 | label_personalize_page: Personalize this page | |
523 | label_comment: Comment |
|
523 | label_comment: Comment | |
524 | label_comment_plural: Comments |
|
524 | label_comment_plural: Comments | |
525 | label_x_comments: |
|
525 | label_x_comments: | |
526 | zero: no comments |
|
526 | zero: no comments | |
527 | one: 1 comment |
|
527 | one: 1 comment | |
528 | other: "{{count}} comments" |
|
528 | other: "{{count}} comments" | |
529 | label_comment_add: Add a comment |
|
529 | label_comment_add: Add a comment | |
530 | label_comment_added: Comment added |
|
530 | label_comment_added: Comment added | |
531 | label_comment_delete: Delete comments |
|
531 | label_comment_delete: Delete comments | |
532 | label_query: Custom query |
|
532 | label_query: Custom query | |
533 | label_query_plural: Custom queries |
|
533 | label_query_plural: Custom queries | |
534 | label_query_new: New query |
|
534 | label_query_new: New query | |
535 | label_filter_add: Add filter |
|
535 | label_filter_add: Add filter | |
536 | label_filter_plural: Filters |
|
536 | label_filter_plural: Filters | |
537 | label_equals: is |
|
537 | label_equals: is | |
538 | label_not_equals: is not |
|
538 | label_not_equals: is not | |
539 | label_in_less_than: in less than |
|
539 | label_in_less_than: in less than | |
540 | label_in_more_than: in more than |
|
540 | label_in_more_than: in more than | |
541 | label_greater_or_equal: '>=' |
|
541 | label_greater_or_equal: '>=' | |
542 | label_less_or_equal: '<=' |
|
542 | label_less_or_equal: '<=' | |
543 | label_in: in |
|
543 | label_in: in | |
544 | label_today: today |
|
544 | label_today: today | |
545 | label_all_time: all time |
|
545 | label_all_time: all time | |
546 | label_yesterday: yesterday |
|
546 | label_yesterday: yesterday | |
547 | label_this_week: this week |
|
547 | label_this_week: this week | |
548 | label_last_week: last week |
|
548 | label_last_week: last week | |
549 | label_last_n_days: "last {{count}} days" |
|
549 | label_last_n_days: "last {{count}} days" | |
550 | label_this_month: this month |
|
550 | label_this_month: this month | |
551 | label_last_month: last month |
|
551 | label_last_month: last month | |
552 | label_this_year: this year |
|
552 | label_this_year: this year | |
553 | label_date_range: Date range |
|
553 | label_date_range: Date range | |
554 | label_less_than_ago: less than days ago |
|
554 | label_less_than_ago: less than days ago | |
555 | label_more_than_ago: more than days ago |
|
555 | label_more_than_ago: more than days ago | |
556 | label_ago: days ago |
|
556 | label_ago: days ago | |
557 | label_contains: contains |
|
557 | label_contains: contains | |
558 | label_not_contains: doesn't contain |
|
558 | label_not_contains: doesn't contain | |
559 | label_day_plural: days |
|
559 | label_day_plural: days | |
560 | label_repository: Repository |
|
560 | label_repository: Repository | |
561 | label_repository_plural: Repositories |
|
561 | label_repository_plural: Repositories | |
562 | label_browse: Browse |
|
562 | label_browse: Browse | |
563 | label_modification: "{{count}} change" |
|
563 | label_modification: "{{count}} change" | |
564 | label_modification_plural: "{{count}} changes" |
|
564 | label_modification_plural: "{{count}} changes" | |
565 | label_branch: Branch |
|
565 | label_branch: Branch | |
566 | label_tag: Tag |
|
566 | label_tag: Tag | |
567 | label_revision: Revision |
|
567 | label_revision: Revision | |
568 | label_revision_plural: Revisions |
|
568 | label_revision_plural: Revisions | |
569 | label_associated_revisions: Associated revisions |
|
569 | label_associated_revisions: Associated revisions | |
570 | label_added: added |
|
570 | label_added: added | |
571 | label_modified: modified |
|
571 | label_modified: modified | |
572 | label_copied: copied |
|
572 | label_copied: copied | |
573 | label_renamed: renamed |
|
573 | label_renamed: renamed | |
574 | label_deleted: deleted |
|
574 | label_deleted: deleted | |
575 | label_latest_revision: Latest revision |
|
575 | label_latest_revision: Latest revision | |
576 | label_latest_revision_plural: Latest revisions |
|
576 | label_latest_revision_plural: Latest revisions | |
577 | label_view_revisions: View revisions |
|
577 | label_view_revisions: View revisions | |
578 | label_view_all_revisions: View all revisions |
|
578 | label_view_all_revisions: View all revisions | |
579 | label_max_size: Maximum size |
|
579 | label_max_size: Maximum size | |
580 | label_sort_highest: Move to top |
|
580 | label_sort_highest: Move to top | |
581 | label_sort_higher: Move up |
|
581 | label_sort_higher: Move up | |
582 | label_sort_lower: Move down |
|
582 | label_sort_lower: Move down | |
583 | label_sort_lowest: Move to bottom |
|
583 | label_sort_lowest: Move to bottom | |
584 | label_roadmap: Roadmap |
|
584 | label_roadmap: Roadmap | |
585 | label_roadmap_due_in: "Due in {{value}}" |
|
585 | label_roadmap_due_in: "Due in {{value}}" | |
586 | label_roadmap_overdue: "{{value}} late" |
|
586 | label_roadmap_overdue: "{{value}} late" | |
587 | label_roadmap_no_issues: No issues for this version |
|
587 | label_roadmap_no_issues: No issues for this version | |
588 | label_search: Search |
|
588 | label_search: Search | |
589 | label_result_plural: Results |
|
589 | label_result_plural: Results | |
590 | label_all_words: All words |
|
590 | label_all_words: All words | |
591 | label_wiki: Wiki |
|
591 | label_wiki: Wiki | |
592 | label_wiki_edit: Wiki edit |
|
592 | label_wiki_edit: Wiki edit | |
593 | label_wiki_edit_plural: Wiki edits |
|
593 | label_wiki_edit_plural: Wiki edits | |
594 | label_wiki_page: Wiki page |
|
594 | label_wiki_page: Wiki page | |
595 | label_wiki_page_plural: Wiki pages |
|
595 | label_wiki_page_plural: Wiki pages | |
596 | label_index_by_title: Index by title |
|
596 | label_index_by_title: Index by title | |
597 | label_index_by_date: Index by date |
|
597 | label_index_by_date: Index by date | |
598 | label_current_version: Current version |
|
598 | label_current_version: Current version | |
599 | label_preview: Preview |
|
599 | label_preview: Preview | |
600 | label_feed_plural: Feeds |
|
600 | label_feed_plural: Feeds | |
601 | label_changes_details: Details of all changes |
|
601 | label_changes_details: Details of all changes | |
602 | label_issue_tracking: Issue tracking |
|
602 | label_issue_tracking: Issue tracking | |
603 | label_spent_time: Spent time |
|
603 | label_spent_time: Spent time | |
604 | label_f_hour: "{{value}} hour" |
|
604 | label_f_hour: "{{value}} hour" | |
605 | label_f_hour_plural: "{{value}} hours" |
|
605 | label_f_hour_plural: "{{value}} hours" | |
606 | label_time_tracking: Time tracking |
|
606 | label_time_tracking: Time tracking | |
607 | label_change_plural: Changes |
|
607 | label_change_plural: Changes | |
608 | label_statistics: Statistics |
|
608 | label_statistics: Statistics | |
609 | label_commits_per_month: Commits per month |
|
609 | label_commits_per_month: Commits per month | |
610 | label_commits_per_author: Commits per author |
|
610 | label_commits_per_author: Commits per author | |
611 | label_view_diff: View differences |
|
611 | label_view_diff: View differences | |
612 | label_diff_inline: inline |
|
612 | label_diff_inline: inline | |
613 | label_diff_side_by_side: side by side |
|
613 | label_diff_side_by_side: side by side | |
614 | label_options: Options |
|
614 | label_options: Options | |
615 | label_copy_workflow_from: Copy workflow from |
|
615 | label_copy_workflow_from: Copy workflow from | |
616 | label_permissions_report: Permissions report |
|
616 | label_permissions_report: Permissions report | |
617 | label_watched_issues: Watched issues |
|
617 | label_watched_issues: Watched issues | |
618 | label_related_issues: Related issues |
|
618 | label_related_issues: Related issues | |
619 | label_applied_status: Applied status |
|
619 | label_applied_status: Applied status | |
620 | label_loading: Loading... |
|
620 | label_loading: Loading... | |
621 | label_relation_new: New relation |
|
621 | label_relation_new: New relation | |
622 | label_relation_delete: Delete relation |
|
622 | label_relation_delete: Delete relation | |
623 | label_relates_to: related to |
|
623 | label_relates_to: related to | |
624 | label_duplicates: duplicates |
|
624 | label_duplicates: duplicates | |
625 | label_duplicated_by: duplicated by |
|
625 | label_duplicated_by: duplicated by | |
626 | label_blocks: blocks |
|
626 | label_blocks: blocks | |
627 | label_blocked_by: blocked by |
|
627 | label_blocked_by: blocked by | |
628 | label_precedes: precedes |
|
628 | label_precedes: precedes | |
629 | label_follows: follows |
|
629 | label_follows: follows | |
630 | label_end_to_start: end to start |
|
630 | label_end_to_start: end to start | |
631 | label_end_to_end: end to end |
|
631 | label_end_to_end: end to end | |
632 | label_start_to_start: start to start |
|
632 | label_start_to_start: start to start | |
633 | label_start_to_end: start to end |
|
633 | label_start_to_end: start to end | |
634 | label_stay_logged_in: Stay logged in |
|
634 | label_stay_logged_in: Stay logged in | |
635 | label_disabled: disabled |
|
635 | label_disabled: disabled | |
636 | label_show_completed_versions: Show completed versions |
|
636 | label_show_completed_versions: Show completed versions | |
637 | label_me: me |
|
637 | label_me: me | |
638 | label_board: Forum |
|
638 | label_board: Forum | |
639 | label_board_new: New forum |
|
639 | label_board_new: New forum | |
640 | label_board_plural: Forums |
|
640 | label_board_plural: Forums | |
641 | label_topic_plural: Topics |
|
641 | label_topic_plural: Topics | |
642 | label_message_plural: Messages |
|
642 | label_message_plural: Messages | |
643 | label_message_last: Last message |
|
643 | label_message_last: Last message | |
644 | label_message_new: New message |
|
644 | label_message_new: New message | |
645 | label_message_posted: Message added |
|
645 | label_message_posted: Message added | |
646 | label_reply_plural: Replies |
|
646 | label_reply_plural: Replies | |
647 | label_send_information: Send account information to the user |
|
647 | label_send_information: Send account information to the user | |
648 | label_year: Year |
|
648 | label_year: Year | |
649 | label_month: Month |
|
649 | label_month: Month | |
650 | label_week: Week |
|
650 | label_week: Week | |
651 | label_date_from: From |
|
651 | label_date_from: From | |
652 | label_date_to: To |
|
652 | label_date_to: To | |
653 | label_language_based: Based on user's language |
|
653 | label_language_based: Based on user's language | |
654 | label_sort_by: "Sort by {{value}}" |
|
654 | label_sort_by: "Sort by {{value}}" | |
655 | label_send_test_email: Send a test email |
|
655 | label_send_test_email: Send a test email | |
656 | label_feeds_access_key_created_on: "RSS access key created {{value}} ago" |
|
656 | label_feeds_access_key_created_on: "RSS access key created {{value}} ago" | |
657 | label_module_plural: Modules |
|
657 | label_module_plural: Modules | |
658 | label_added_time_by: "Added by {{author}} {{age}} ago" |
|
658 | label_added_time_by: "Added by {{author}} {{age}} ago" | |
659 | label_updated_time_by: "Updated by {{author}} {{age}} ago" |
|
659 | label_updated_time_by: "Updated by {{author}} {{age}} ago" | |
660 | label_updated_time: "Updated {{value}} ago" |
|
660 | label_updated_time: "Updated {{value}} ago" | |
661 | label_jump_to_a_project: Jump to a project... |
|
661 | label_jump_to_a_project: Jump to a project... | |
662 | label_file_plural: Files |
|
662 | label_file_plural: Files | |
663 | label_changeset_plural: Changesets |
|
663 | label_changeset_plural: Changesets | |
664 | label_default_columns: Default columns |
|
664 | label_default_columns: Default columns | |
665 | label_no_change_option: (No change) |
|
665 | label_no_change_option: (No change) | |
666 | label_bulk_edit_selected_issues: Bulk edit selected issues |
|
666 | label_bulk_edit_selected_issues: Bulk edit selected issues | |
667 | label_theme: Theme |
|
667 | label_theme: Theme | |
668 | label_default: Default |
|
668 | label_default: Default | |
669 | label_search_titles_only: Search titles only |
|
669 | label_search_titles_only: Search titles only | |
670 | label_user_mail_option_all: "For any event on all my projects" |
|
670 | label_user_mail_option_all: "For any event on all my projects" | |
671 | label_user_mail_option_selected: "For any event on the selected projects only..." |
|
671 | label_user_mail_option_selected: "For any event on the selected projects only..." | |
672 | label_user_mail_option_none: "Only for things I watch or I'm involved in" |
|
672 | label_user_mail_option_none: "Only for things I watch or I'm involved in" | |
673 | label_user_mail_no_self_notified: "I don't want to be notified of changes that I make myself" |
|
673 | label_user_mail_no_self_notified: "I don't want to be notified of changes that I make myself" | |
674 | label_registration_activation_by_email: account activation by email |
|
674 | label_registration_activation_by_email: account activation by email | |
675 | label_registration_manual_activation: manual account activation |
|
675 | label_registration_manual_activation: manual account activation | |
676 | label_registration_automatic_activation: automatic account activation |
|
676 | label_registration_automatic_activation: automatic account activation | |
677 | label_display_per_page: "Per page: {{value}}" |
|
677 | label_display_per_page: "Per page: {{value}}" | |
678 | label_age: Age |
|
678 | label_age: Age | |
679 | label_change_properties: Change properties |
|
679 | label_change_properties: Change properties | |
680 | label_general: General |
|
680 | label_general: General | |
681 | label_more: More |
|
681 | label_more: More | |
682 | label_scm: SCM |
|
682 | label_scm: SCM | |
683 | label_plugins: Plugins |
|
683 | label_plugins: Plugins | |
684 | label_ldap_authentication: LDAP authentication |
|
684 | label_ldap_authentication: LDAP authentication | |
685 | label_downloads_abbr: D/L |
|
685 | label_downloads_abbr: D/L | |
686 | label_optional_description: Optional description |
|
686 | label_optional_description: Optional description | |
687 | label_add_another_file: Add another file |
|
687 | label_add_another_file: Add another file | |
688 | label_preferences: Preferences |
|
688 | label_preferences: Preferences | |
689 | label_chronological_order: In chronological order |
|
689 | label_chronological_order: In chronological order | |
690 | label_reverse_chronological_order: In reverse chronological order |
|
690 | label_reverse_chronological_order: In reverse chronological order | |
691 | label_planning: Planning |
|
691 | label_planning: Planning | |
692 | label_incoming_emails: Incoming emails |
|
692 | label_incoming_emails: Incoming emails | |
693 | label_generate_key: Generate a key |
|
693 | label_generate_key: Generate a key | |
694 | label_issue_watchers: Watchers |
|
694 | label_issue_watchers: Watchers | |
695 | label_example: Example |
|
695 | label_example: Example | |
696 | label_display: Display |
|
696 | label_display: Display | |
697 | label_sort: Sort |
|
697 | label_sort: Sort | |
698 | label_ascending: Ascending |
|
698 | label_ascending: Ascending | |
699 | label_descending: Descending |
|
699 | label_descending: Descending | |
700 | label_date_from_to: From {{start}} to {{end}} |
|
700 | label_date_from_to: From {{start}} to {{end}} | |
701 | label_wiki_content_added: Wiki page added |
|
701 | label_wiki_content_added: Wiki page added | |
702 | label_wiki_content_updated: Wiki page updated |
|
702 | label_wiki_content_updated: Wiki page updated | |
703 | label_group: Group |
|
703 | label_group: Group | |
704 | label_group_plural: Groups |
|
704 | label_group_plural: Groups | |
705 | label_group_new: New group |
|
705 | label_group_new: New group | |
706 | label_time_entry_plural: Spent time |
|
706 | label_time_entry_plural: Spent time | |
707 |
|
707 | |||
708 | button_login: Login |
|
708 | button_login: Login | |
709 | button_submit: Submit |
|
709 | button_submit: Submit | |
710 | button_save: Save |
|
710 | button_save: Save | |
711 | button_check_all: Check all |
|
711 | button_check_all: Check all | |
712 | button_uncheck_all: Uncheck all |
|
712 | button_uncheck_all: Uncheck all | |
713 | button_delete: Delete |
|
713 | button_delete: Delete | |
714 | button_create: Create |
|
714 | button_create: Create | |
715 | button_create_and_continue: Create and continue |
|
715 | button_create_and_continue: Create and continue | |
716 | button_test: Test |
|
716 | button_test: Test | |
717 | button_edit: Edit |
|
717 | button_edit: Edit | |
718 | button_add: Add |
|
718 | button_add: Add | |
719 | button_change: Change |
|
719 | button_change: Change | |
720 | button_apply: Apply |
|
720 | button_apply: Apply | |
721 | button_clear: Clear |
|
721 | button_clear: Clear | |
722 | button_lock: Lock |
|
722 | button_lock: Lock | |
723 | button_unlock: Unlock |
|
723 | button_unlock: Unlock | |
724 | button_download: Download |
|
724 | button_download: Download | |
725 | button_list: List |
|
725 | button_list: List | |
726 | button_view: View |
|
726 | button_view: View | |
727 | button_move: Move |
|
727 | button_move: Move | |
728 | button_back: Back |
|
728 | button_back: Back | |
729 | button_cancel: Cancel |
|
729 | button_cancel: Cancel | |
730 | button_activate: Activate |
|
730 | button_activate: Activate | |
731 | button_sort: Sort |
|
731 | button_sort: Sort | |
732 | button_log_time: Log time |
|
732 | button_log_time: Log time | |
733 | button_rollback: Rollback to this version |
|
733 | button_rollback: Rollback to this version | |
734 | button_watch: Watch |
|
734 | button_watch: Watch | |
735 | button_unwatch: Unwatch |
|
735 | button_unwatch: Unwatch | |
736 | button_reply: Reply |
|
736 | button_reply: Reply | |
737 | button_archive: Archive |
|
737 | button_archive: Archive | |
738 | button_unarchive: Unarchive |
|
738 | button_unarchive: Unarchive | |
739 | button_reset: Reset |
|
739 | button_reset: Reset | |
740 | button_rename: Rename |
|
740 | button_rename: Rename | |
741 | button_change_password: Change password |
|
741 | button_change_password: Change password | |
742 | button_copy: Copy |
|
742 | button_copy: Copy | |
743 | button_annotate: Annotate |
|
743 | button_annotate: Annotate | |
744 | button_update: Update |
|
744 | button_update: Update | |
745 | button_configure: Configure |
|
745 | button_configure: Configure | |
746 | button_quote: Quote |
|
746 | button_quote: Quote | |
747 |
|
747 | |||
748 | status_active: active |
|
748 | status_active: active | |
749 | status_registered: registered |
|
749 | status_registered: registered | |
750 | status_locked: locked |
|
750 | status_locked: locked | |
751 |
|
751 | |||
|
752 | field_active: Active | |||
|
753 | ||||
752 | text_select_mail_notifications: Select actions for which email notifications should be sent. |
|
754 | text_select_mail_notifications: Select actions for which email notifications should be sent. | |
753 | text_regexp_info: eg. ^[A-Z0-9]+$ |
|
755 | text_regexp_info: eg. ^[A-Z0-9]+$ | |
754 | text_min_max_length_info: 0 means no restriction |
|
756 | text_min_max_length_info: 0 means no restriction | |
755 | text_project_destroy_confirmation: Are you sure you want to delete this project and related data ? |
|
757 | text_project_destroy_confirmation: Are you sure you want to delete this project and related data ? | |
756 | text_subprojects_destroy_warning: "Its subproject(s): {{value}} will be also deleted." |
|
758 | text_subprojects_destroy_warning: "Its subproject(s): {{value}} will be also deleted." | |
757 | text_workflow_edit: Select a role and a tracker to edit the workflow |
|
759 | text_workflow_edit: Select a role and a tracker to edit the workflow | |
758 | text_are_you_sure: Are you sure ? |
|
760 | text_are_you_sure: Are you sure ? | |
759 | text_journal_changed: "{{label}} changed from {{old}} to {{new}}" |
|
761 | text_journal_changed: "{{label}} changed from {{old}} to {{new}}" | |
760 | text_journal_set_to: "{{label}} set to {{value}}" |
|
762 | text_journal_set_to: "{{label}} set to {{value}}" | |
761 | text_journal_deleted: "{{label}} deleted ({{old}})" |
|
763 | text_journal_deleted: "{{label}} deleted ({{old}})" | |
762 | text_journal_added: "{{label}} {{value}} added" |
|
764 | text_journal_added: "{{label}} {{value}} added" | |
763 | text_tip_task_begin_day: task beginning this day |
|
765 | text_tip_task_begin_day: task beginning this day | |
764 | text_tip_task_end_day: task ending this day |
|
766 | text_tip_task_end_day: task ending this day | |
765 | text_tip_task_begin_end_day: task beginning and ending this day |
|
767 | text_tip_task_begin_end_day: task beginning and ending this day | |
766 | text_project_identifier_info: 'Only lower case letters (a-z), numbers and dashes are allowed.<br />Once saved, the identifier can not be changed.' |
|
768 | text_project_identifier_info: 'Only lower case letters (a-z), numbers and dashes are allowed.<br />Once saved, the identifier can not be changed.' | |
767 | text_caracters_maximum: "{{count}} characters maximum." |
|
769 | text_caracters_maximum: "{{count}} characters maximum." | |
768 | text_caracters_minimum: "Must be at least {{count}} characters long." |
|
770 | text_caracters_minimum: "Must be at least {{count}} characters long." | |
769 | text_length_between: "Length between {{min}} and {{max}} characters." |
|
771 | text_length_between: "Length between {{min}} and {{max}} characters." | |
770 | text_tracker_no_workflow: No workflow defined for this tracker |
|
772 | text_tracker_no_workflow: No workflow defined for this tracker | |
771 | text_unallowed_characters: Unallowed characters |
|
773 | text_unallowed_characters: Unallowed characters | |
772 | text_comma_separated: Multiple values allowed (comma separated). |
|
774 | text_comma_separated: Multiple values allowed (comma separated). | |
773 | text_issues_ref_in_commit_messages: Referencing and fixing issues in commit messages |
|
775 | text_issues_ref_in_commit_messages: Referencing and fixing issues in commit messages | |
774 | text_issue_added: "Issue {{id}} has been reported by {{author}}." |
|
776 | text_issue_added: "Issue {{id}} has been reported by {{author}}." | |
775 | text_issue_updated: "Issue {{id}} has been updated by {{author}}." |
|
777 | text_issue_updated: "Issue {{id}} has been updated by {{author}}." | |
776 | text_wiki_destroy_confirmation: Are you sure you want to delete this wiki and all its content ? |
|
778 | text_wiki_destroy_confirmation: Are you sure you want to delete this wiki and all its content ? | |
777 | text_issue_category_destroy_question: "Some issues ({{count}}) are assigned to this category. What do you want to do ?" |
|
779 | text_issue_category_destroy_question: "Some issues ({{count}}) are assigned to this category. What do you want to do ?" | |
778 | text_issue_category_destroy_assignments: Remove category assignments |
|
780 | text_issue_category_destroy_assignments: Remove category assignments | |
779 | text_issue_category_reassign_to: Reassign issues to this category |
|
781 | text_issue_category_reassign_to: Reassign issues to this category | |
780 | text_user_mail_option: "For unselected projects, you will only receive notifications about things you watch or you're involved in (eg. issues you're the author or assignee)." |
|
782 | text_user_mail_option: "For unselected projects, you will only receive notifications about things you watch or you're involved in (eg. issues you're the author or assignee)." | |
781 | text_no_configuration_data: "Roles, trackers, issue statuses and workflow have not been configured yet.\nIt is highly recommended to load the default configuration. You will be able to modify it once loaded." |
|
783 | text_no_configuration_data: "Roles, trackers, issue statuses and workflow have not been configured yet.\nIt is highly recommended to load the default configuration. You will be able to modify it once loaded." | |
782 | text_load_default_configuration: Load the default configuration |
|
784 | text_load_default_configuration: Load the default configuration | |
783 | text_status_changed_by_changeset: "Applied in changeset {{value}}." |
|
785 | text_status_changed_by_changeset: "Applied in changeset {{value}}." | |
784 | text_issues_destroy_confirmation: 'Are you sure you want to delete the selected issue(s) ?' |
|
786 | text_issues_destroy_confirmation: 'Are you sure you want to delete the selected issue(s) ?' | |
785 | text_select_project_modules: 'Select modules to enable for this project:' |
|
787 | text_select_project_modules: 'Select modules to enable for this project:' | |
786 | text_default_administrator_account_changed: Default administrator account changed |
|
788 | text_default_administrator_account_changed: Default administrator account changed | |
787 | text_file_repository_writable: Attachments directory writable |
|
789 | text_file_repository_writable: Attachments directory writable | |
788 | text_plugin_assets_writable: Plugin assets directory writable |
|
790 | text_plugin_assets_writable: Plugin assets directory writable | |
789 | text_rmagick_available: RMagick available (optional) |
|
791 | text_rmagick_available: RMagick available (optional) | |
790 | text_destroy_time_entries_question: "{{hours}} hours were reported on the issues you are about to delete. What do you want to do ?" |
|
792 | text_destroy_time_entries_question: "{{hours}} hours were reported on the issues you are about to delete. What do you want to do ?" | |
791 | text_destroy_time_entries: Delete reported hours |
|
793 | text_destroy_time_entries: Delete reported hours | |
792 | text_assign_time_entries_to_project: Assign reported hours to the project |
|
794 | text_assign_time_entries_to_project: Assign reported hours to the project | |
793 | text_reassign_time_entries: 'Reassign reported hours to this issue:' |
|
795 | text_reassign_time_entries: 'Reassign reported hours to this issue:' | |
794 | text_user_wrote: "{{value}} wrote:" |
|
796 | text_user_wrote: "{{value}} wrote:" | |
795 | text_enumeration_destroy_question: "{{count}} objects are assigned to this value." |
|
797 | text_enumeration_destroy_question: "{{count}} objects are assigned to this value." | |
796 | text_enumeration_category_reassign_to: 'Reassign them to this value:' |
|
798 | text_enumeration_category_reassign_to: 'Reassign them to this value:' | |
797 | text_email_delivery_not_configured: "Email delivery is not configured, and notifications are disabled.\nConfigure your SMTP server in config/email.yml and restart the application to enable them." |
|
799 | text_email_delivery_not_configured: "Email delivery is not configured, and notifications are disabled.\nConfigure your SMTP server in config/email.yml and restart the application to enable them." | |
798 | text_repository_usernames_mapping: "Select or update the Redmine user mapped to each username found in the repository log.\nUsers with the same Redmine and repository username or email are automatically mapped." |
|
800 | text_repository_usernames_mapping: "Select or update the Redmine user mapped to each username found in the repository log.\nUsers with the same Redmine and repository username or email are automatically mapped." | |
799 | text_diff_truncated: '... This diff was truncated because it exceeds the maximum size that can be displayed.' |
|
801 | text_diff_truncated: '... This diff was truncated because it exceeds the maximum size that can be displayed.' | |
800 | text_custom_field_possible_values_info: 'One line for each value' |
|
802 | text_custom_field_possible_values_info: 'One line for each value' | |
801 | text_wiki_page_destroy_question: "This page has {{descendants}} child page(s) and descendant(s). What do you want to do?" |
|
803 | text_wiki_page_destroy_question: "This page has {{descendants}} child page(s) and descendant(s). What do you want to do?" | |
802 | text_wiki_page_nullify_children: "Keep child pages as root pages" |
|
804 | text_wiki_page_nullify_children: "Keep child pages as root pages" | |
803 | text_wiki_page_destroy_children: "Delete child pages and all their descendants" |
|
805 | text_wiki_page_destroy_children: "Delete child pages and all their descendants" | |
804 | text_wiki_page_reassign_children: "Reassign child pages to this parent page" |
|
806 | text_wiki_page_reassign_children: "Reassign child pages to this parent page" | |
805 |
|
807 | |||
806 | default_role_manager: Manager |
|
808 | default_role_manager: Manager | |
807 | default_role_developper: Developer |
|
809 | default_role_developper: Developer | |
808 | default_role_reporter: Reporter |
|
810 | default_role_reporter: Reporter | |
809 | default_tracker_bug: Bug |
|
811 | default_tracker_bug: Bug | |
810 | default_tracker_feature: Feature |
|
812 | default_tracker_feature: Feature | |
811 | default_tracker_support: Support |
|
813 | default_tracker_support: Support | |
812 | default_issue_status_new: New |
|
814 | default_issue_status_new: New | |
813 | default_issue_status_in_progress: In Progress |
|
815 | default_issue_status_in_progress: In Progress | |
814 | default_issue_status_resolved: Resolved |
|
816 | default_issue_status_resolved: Resolved | |
815 | default_issue_status_feedback: Feedback |
|
817 | default_issue_status_feedback: Feedback | |
816 | default_issue_status_closed: Closed |
|
818 | default_issue_status_closed: Closed | |
817 | default_issue_status_rejected: Rejected |
|
819 | default_issue_status_rejected: Rejected | |
818 | default_doc_category_user: User documentation |
|
820 | default_doc_category_user: User documentation | |
819 | default_doc_category_tech: Technical documentation |
|
821 | default_doc_category_tech: Technical documentation | |
820 | default_priority_low: Low |
|
822 | default_priority_low: Low | |
821 | default_priority_normal: Normal |
|
823 | default_priority_normal: Normal | |
822 | default_priority_high: High |
|
824 | default_priority_high: High | |
823 | default_priority_urgent: Urgent |
|
825 | default_priority_urgent: Urgent | |
824 | default_priority_immediate: Immediate |
|
826 | default_priority_immediate: Immediate | |
825 | default_activity_design: Design |
|
827 | default_activity_design: Design | |
826 | default_activity_development: Development |
|
828 | default_activity_development: Development | |
827 |
|
829 | |||
828 | enumeration_issue_priorities: Issue priorities |
|
830 | enumeration_issue_priorities: Issue priorities | |
829 | enumeration_doc_categories: Document categories |
|
831 | enumeration_doc_categories: Document categories | |
830 | enumeration_activities: Activities (time tracking) |
|
832 | enumeration_activities: Activities (time tracking) |
@@ -1,69 +1,88 | |||||
1 | --- |
|
1 | --- | |
2 | enumerations_001: |
|
2 | enumerations_001: | |
3 | name: Uncategorized |
|
3 | name: Uncategorized | |
4 | id: 1 |
|
4 | id: 1 | |
5 | opt: DCAT |
|
5 | opt: DCAT | |
6 | type: DocumentCategory |
|
6 | type: DocumentCategory | |
|
7 | active: true | |||
7 | enumerations_002: |
|
8 | enumerations_002: | |
8 | name: User documentation |
|
9 | name: User documentation | |
9 | id: 2 |
|
10 | id: 2 | |
10 | opt: DCAT |
|
11 | opt: DCAT | |
11 | type: DocumentCategory |
|
12 | type: DocumentCategory | |
|
13 | active: true | |||
12 | enumerations_003: |
|
14 | enumerations_003: | |
13 | name: Technical documentation |
|
15 | name: Technical documentation | |
14 | id: 3 |
|
16 | id: 3 | |
15 | opt: DCAT |
|
17 | opt: DCAT | |
16 | type: DocumentCategory |
|
18 | type: DocumentCategory | |
|
19 | active: true | |||
17 | enumerations_004: |
|
20 | enumerations_004: | |
18 | name: Low |
|
21 | name: Low | |
19 | id: 4 |
|
22 | id: 4 | |
20 | opt: IPRI |
|
23 | opt: IPRI | |
21 | type: IssuePriority |
|
24 | type: IssuePriority | |
|
25 | active: true | |||
22 | enumerations_005: |
|
26 | enumerations_005: | |
23 | name: Normal |
|
27 | name: Normal | |
24 | id: 5 |
|
28 | id: 5 | |
25 | opt: IPRI |
|
29 | opt: IPRI | |
26 | type: IssuePriority |
|
30 | type: IssuePriority | |
27 | is_default: true |
|
31 | is_default: true | |
|
32 | active: true | |||
28 | enumerations_006: |
|
33 | enumerations_006: | |
29 | name: High |
|
34 | name: High | |
30 | id: 6 |
|
35 | id: 6 | |
31 | opt: IPRI |
|
36 | opt: IPRI | |
32 | type: IssuePriority |
|
37 | type: IssuePriority | |
|
38 | active: true | |||
33 | enumerations_007: |
|
39 | enumerations_007: | |
34 | name: Urgent |
|
40 | name: Urgent | |
35 | id: 7 |
|
41 | id: 7 | |
36 | opt: IPRI |
|
42 | opt: IPRI | |
37 | type: IssuePriority |
|
43 | type: IssuePriority | |
|
44 | active: true | |||
38 | enumerations_008: |
|
45 | enumerations_008: | |
39 | name: Immediate |
|
46 | name: Immediate | |
40 | id: 8 |
|
47 | id: 8 | |
41 | opt: IPRI |
|
48 | opt: IPRI | |
42 | type: IssuePriority |
|
49 | type: IssuePriority | |
|
50 | active: true | |||
43 | enumerations_009: |
|
51 | enumerations_009: | |
44 | name: Design |
|
52 | name: Design | |
45 | id: 9 |
|
53 | id: 9 | |
46 | opt: ACTI |
|
54 | opt: ACTI | |
47 | type: TimeEntryActivity |
|
55 | type: TimeEntryActivity | |
|
56 | active: true | |||
48 | enumerations_010: |
|
57 | enumerations_010: | |
49 | name: Development |
|
58 | name: Development | |
50 | id: 10 |
|
59 | id: 10 | |
51 | opt: ACTI |
|
60 | opt: ACTI | |
52 | type: TimeEntryActivity |
|
61 | type: TimeEntryActivity | |
53 | is_default: true |
|
62 | is_default: true | |
|
63 | active: true | |||
54 | enumerations_011: |
|
64 | enumerations_011: | |
55 | name: QA |
|
65 | name: QA | |
56 | id: 11 |
|
66 | id: 11 | |
57 | opt: ACTI |
|
67 | opt: ACTI | |
58 | type: TimeEntryActivity |
|
68 | type: TimeEntryActivity | |
|
69 | active: true | |||
59 | enumerations_012: |
|
70 | enumerations_012: | |
60 | name: Default Enumeration |
|
71 | name: Default Enumeration | |
61 | id: 12 |
|
72 | id: 12 | |
62 | opt: '' |
|
73 | opt: '' | |
63 | type: Enumeration |
|
74 | type: Enumeration | |
64 | is_default: true |
|
75 | is_default: true | |
|
76 | active: true | |||
65 | enumerations_013: |
|
77 | enumerations_013: | |
66 | name: Another Enumeration |
|
78 | name: Another Enumeration | |
67 | id: 13 |
|
79 | id: 13 | |
68 | opt: '' |
|
80 | opt: '' | |
69 | type: Enumeration |
|
81 | type: Enumeration | |
|
82 | active: true | |||
|
83 | enumerations_014: | |||
|
84 | name: Inactive Activity | |||
|
85 | id: 14 | |||
|
86 | opt: ACTI | |||
|
87 | type: TimeEntryActivity | |||
|
88 | active: false |
@@ -1,404 +1,427 | |||||
|
1 | # -*- coding: utf-8 -*- | |||
1 | # redMine - project management software |
|
2 | # redMine - project management software | |
2 | # Copyright (C) 2006-2007 Jean-Philippe Lang |
|
3 | # Copyright (C) 2006-2007 Jean-Philippe Lang | |
3 | # |
|
4 | # | |
4 | # This program is free software; you can redistribute it and/or |
|
5 | # This program is free software; you can redistribute it and/or | |
5 | # modify it under the terms of the GNU General Public License |
|
6 | # modify it under the terms of the GNU General Public License | |
6 | # as published by the Free Software Foundation; either version 2 |
|
7 | # as published by the Free Software Foundation; either version 2 | |
7 | # of the License, or (at your option) any later version. |
|
8 | # of the License, or (at your option) any later version. | |
8 | # |
|
9 | # | |
9 | # This program is distributed in the hope that it will be useful, |
|
10 | # This program is distributed in the hope that it will be useful, | |
10 | # but WITHOUT ANY WARRANTY; without even the implied warranty of |
|
11 | # but WITHOUT ANY WARRANTY; without even the implied warranty of | |
11 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|
12 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
12 | # GNU General Public License for more details. |
|
13 | # GNU General Public License for more details. | |
13 | # |
|
14 | # | |
14 | # You should have received a copy of the GNU General Public License |
|
15 | # You should have received a copy of the GNU General Public License | |
15 | # along with this program; if not, write to the Free Software |
|
16 | # along with this program; if not, write to the Free Software | |
16 | # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. |
|
17 | # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. | |
17 |
|
18 | |||
18 | require File.dirname(__FILE__) + '/../test_helper' |
|
19 | require File.dirname(__FILE__) + '/../test_helper' | |
19 | require 'timelog_controller' |
|
20 | require 'timelog_controller' | |
20 |
|
21 | |||
21 | # Re-raise errors caught by the controller. |
|
22 | # Re-raise errors caught by the controller. | |
22 | class TimelogController; def rescue_action(e) raise e end; end |
|
23 | class TimelogController; def rescue_action(e) raise e end; end | |
23 |
|
24 | |||
24 | class TimelogControllerTest < ActionController::TestCase |
|
25 | class TimelogControllerTest < ActionController::TestCase | |
25 | fixtures :projects, :enabled_modules, :roles, :members, :member_roles, :issues, :time_entries, :users, :trackers, :enumerations, :issue_statuses, :custom_fields, :custom_values |
|
26 | fixtures :projects, :enabled_modules, :roles, :members, :member_roles, :issues, :time_entries, :users, :trackers, :enumerations, :issue_statuses, :custom_fields, :custom_values | |
26 |
|
27 | |||
27 | def setup |
|
28 | def setup | |
28 | @controller = TimelogController.new |
|
29 | @controller = TimelogController.new | |
29 | @request = ActionController::TestRequest.new |
|
30 | @request = ActionController::TestRequest.new | |
30 | @response = ActionController::TestResponse.new |
|
31 | @response = ActionController::TestResponse.new | |
31 | end |
|
32 | end | |
32 |
|
33 | |||
33 | def test_edit_routing |
|
34 | def test_edit_routing | |
34 | assert_routing( |
|
35 | assert_routing( | |
35 | {:method => :get, :path => '/issues/567/time_entries/new'}, |
|
36 | {:method => :get, :path => '/issues/567/time_entries/new'}, | |
36 | :controller => 'timelog', :action => 'edit', :issue_id => '567' |
|
37 | :controller => 'timelog', :action => 'edit', :issue_id => '567' | |
37 | ) |
|
38 | ) | |
38 | assert_routing( |
|
39 | assert_routing( | |
39 | {:method => :get, :path => '/projects/ecookbook/time_entries/new'}, |
|
40 | {:method => :get, :path => '/projects/ecookbook/time_entries/new'}, | |
40 | :controller => 'timelog', :action => 'edit', :project_id => 'ecookbook' |
|
41 | :controller => 'timelog', :action => 'edit', :project_id => 'ecookbook' | |
41 | ) |
|
42 | ) | |
42 | assert_routing( |
|
43 | assert_routing( | |
43 | {:method => :get, :path => '/projects/ecookbook/issues/567/time_entries/new'}, |
|
44 | {:method => :get, :path => '/projects/ecookbook/issues/567/time_entries/new'}, | |
44 | :controller => 'timelog', :action => 'edit', :project_id => 'ecookbook', :issue_id => '567' |
|
45 | :controller => 'timelog', :action => 'edit', :project_id => 'ecookbook', :issue_id => '567' | |
45 | ) |
|
46 | ) | |
46 |
|
47 | |||
47 | #TODO: change new form to POST to issue_time_entries_path instead of to edit action |
|
48 | #TODO: change new form to POST to issue_time_entries_path instead of to edit action | |
48 | #TODO: change edit form to PUT to time_entry_path |
|
49 | #TODO: change edit form to PUT to time_entry_path | |
49 | assert_routing( |
|
50 | assert_routing( | |
50 | {:method => :get, :path => '/time_entries/22/edit'}, |
|
51 | {:method => :get, :path => '/time_entries/22/edit'}, | |
51 | :controller => 'timelog', :action => 'edit', :id => '22' |
|
52 | :controller => 'timelog', :action => 'edit', :id => '22' | |
52 | ) |
|
53 | ) | |
53 | end |
|
54 | end | |
54 |
|
55 | |||
55 | def test_get_edit |
|
56 | def test_get_edit | |
56 | @request.session[:user_id] = 3 |
|
57 | @request.session[:user_id] = 3 | |
57 | get :edit, :project_id => 1 |
|
58 | get :edit, :project_id => 1 | |
58 | assert_response :success |
|
59 | assert_response :success | |
59 | assert_template 'edit' |
|
60 | assert_template 'edit' | |
60 | # Default activity selected |
|
61 | # Default activity selected | |
61 | assert_tag :tag => 'option', :attributes => { :selected => 'selected' }, |
|
62 | assert_tag :tag => 'option', :attributes => { :selected => 'selected' }, | |
62 | :content => 'Development' |
|
63 | :content => 'Development' | |
63 | end |
|
64 | end | |
64 |
|
65 | |||
65 | def test_get_edit_existing_time |
|
66 | def test_get_edit_existing_time | |
66 | @request.session[:user_id] = 2 |
|
67 | @request.session[:user_id] = 2 | |
67 | get :edit, :id => 2, :project_id => nil |
|
68 | get :edit, :id => 2, :project_id => nil | |
68 | assert_response :success |
|
69 | assert_response :success | |
69 | assert_template 'edit' |
|
70 | assert_template 'edit' | |
70 | # Default activity selected |
|
71 | # Default activity selected | |
71 | assert_tag :tag => 'form', :attributes => { :action => '/projects/ecookbook/timelog/edit/2' } |
|
72 | assert_tag :tag => 'form', :attributes => { :action => '/projects/ecookbook/timelog/edit/2' } | |
72 | end |
|
73 | end | |
73 |
|
74 | |||
|
75 | def test_get_edit_should_only_show_active_time_entry_activities | |||
|
76 | @request.session[:user_id] = 3 | |||
|
77 | get :edit, :project_id => 1 | |||
|
78 | assert_response :success | |||
|
79 | assert_template 'edit' | |||
|
80 | assert_no_tag :tag => 'option', :content => 'Inactive Activity' | |||
|
81 | ||||
|
82 | end | |||
|
83 | ||||
|
84 | def test_get_edit_with_an_existing_time_entry_with_inactive_activity | |||
|
85 | te = TimeEntry.find(1) | |||
|
86 | te.activity = TimeEntryActivity.find_by_name("Inactive Activity") | |||
|
87 | te.save! | |||
|
88 | ||||
|
89 | @request.session[:user_id] = 1 | |||
|
90 | get :edit, :project_id => 1, :id => 1 | |||
|
91 | assert_response :success | |||
|
92 | assert_template 'edit' | |||
|
93 | # Blank option since nothing is pre-selected | |||
|
94 | assert_tag :tag => 'option', :content => '--- Please select ---' | |||
|
95 | end | |||
|
96 | ||||
74 | def test_post_edit |
|
97 | def test_post_edit | |
75 | # TODO: should POST to issuesβ time log instead of project. change form |
|
98 | # TODO: should POST to issuesβ time log instead of project. change form | |
76 | # and routing |
|
99 | # and routing | |
77 | @request.session[:user_id] = 3 |
|
100 | @request.session[:user_id] = 3 | |
78 | post :edit, :project_id => 1, |
|
101 | post :edit, :project_id => 1, | |
79 | :time_entry => {:comments => 'Some work on TimelogControllerTest', |
|
102 | :time_entry => {:comments => 'Some work on TimelogControllerTest', | |
80 | # Not the default activity |
|
103 | # Not the default activity | |
81 | :activity_id => '11', |
|
104 | :activity_id => '11', | |
82 | :spent_on => '2008-03-14', |
|
105 | :spent_on => '2008-03-14', | |
83 | :issue_id => '1', |
|
106 | :issue_id => '1', | |
84 | :hours => '7.3'} |
|
107 | :hours => '7.3'} | |
85 | assert_redirected_to :action => 'details', :project_id => 'ecookbook' |
|
108 | assert_redirected_to :action => 'details', :project_id => 'ecookbook' | |
86 |
|
109 | |||
87 | i = Issue.find(1) |
|
110 | i = Issue.find(1) | |
88 | t = TimeEntry.find_by_comments('Some work on TimelogControllerTest') |
|
111 | t = TimeEntry.find_by_comments('Some work on TimelogControllerTest') | |
89 | assert_not_nil t |
|
112 | assert_not_nil t | |
90 | assert_equal 11, t.activity_id |
|
113 | assert_equal 11, t.activity_id | |
91 | assert_equal 7.3, t.hours |
|
114 | assert_equal 7.3, t.hours | |
92 | assert_equal 3, t.user_id |
|
115 | assert_equal 3, t.user_id | |
93 | assert_equal i, t.issue |
|
116 | assert_equal i, t.issue | |
94 | assert_equal i.project, t.project |
|
117 | assert_equal i.project, t.project | |
95 | end |
|
118 | end | |
96 |
|
119 | |||
97 | def test_update |
|
120 | def test_update | |
98 | entry = TimeEntry.find(1) |
|
121 | entry = TimeEntry.find(1) | |
99 | assert_equal 1, entry.issue_id |
|
122 | assert_equal 1, entry.issue_id | |
100 | assert_equal 2, entry.user_id |
|
123 | assert_equal 2, entry.user_id | |
101 |
|
124 | |||
102 | @request.session[:user_id] = 1 |
|
125 | @request.session[:user_id] = 1 | |
103 | post :edit, :id => 1, |
|
126 | post :edit, :id => 1, | |
104 | :time_entry => {:issue_id => '2', |
|
127 | :time_entry => {:issue_id => '2', | |
105 | :hours => '8'} |
|
128 | :hours => '8'} | |
106 | assert_redirected_to :action => 'details', :project_id => 'ecookbook' |
|
129 | assert_redirected_to :action => 'details', :project_id => 'ecookbook' | |
107 | entry.reload |
|
130 | entry.reload | |
108 |
|
131 | |||
109 | assert_equal 8, entry.hours |
|
132 | assert_equal 8, entry.hours | |
110 | assert_equal 2, entry.issue_id |
|
133 | assert_equal 2, entry.issue_id | |
111 | assert_equal 2, entry.user_id |
|
134 | assert_equal 2, entry.user_id | |
112 | end |
|
135 | end | |
113 |
|
136 | |||
114 | def test_destroy_routing |
|
137 | def test_destroy_routing | |
115 | #TODO: use DELETE to time_entry_path |
|
138 | #TODO: use DELETE to time_entry_path | |
116 | assert_routing( |
|
139 | assert_routing( | |
117 | {:method => :post, :path => '/time_entries/55/destroy'}, |
|
140 | {:method => :post, :path => '/time_entries/55/destroy'}, | |
118 | :controller => 'timelog', :action => 'destroy', :id => '55' |
|
141 | :controller => 'timelog', :action => 'destroy', :id => '55' | |
119 | ) |
|
142 | ) | |
120 | end |
|
143 | end | |
121 |
|
144 | |||
122 | def test_destroy |
|
145 | def test_destroy | |
123 | @request.session[:user_id] = 2 |
|
146 | @request.session[:user_id] = 2 | |
124 | post :destroy, :id => 1 |
|
147 | post :destroy, :id => 1 | |
125 | assert_redirected_to :action => 'details', :project_id => 'ecookbook' |
|
148 | assert_redirected_to :action => 'details', :project_id => 'ecookbook' | |
126 | assert_nil TimeEntry.find_by_id(1) |
|
149 | assert_nil TimeEntry.find_by_id(1) | |
127 | end |
|
150 | end | |
128 |
|
151 | |||
129 | def test_report_routing |
|
152 | def test_report_routing | |
130 | assert_routing( |
|
153 | assert_routing( | |
131 | {:method => :get, :path => '/projects/567/time_entries/report'}, |
|
154 | {:method => :get, :path => '/projects/567/time_entries/report'}, | |
132 | :controller => 'timelog', :action => 'report', :project_id => '567' |
|
155 | :controller => 'timelog', :action => 'report', :project_id => '567' | |
133 | ) |
|
156 | ) | |
134 | assert_routing( |
|
157 | assert_routing( | |
135 | {:method => :get, :path => '/projects/567/time_entries/report.csv'}, |
|
158 | {:method => :get, :path => '/projects/567/time_entries/report.csv'}, | |
136 | :controller => 'timelog', :action => 'report', :project_id => '567', :format => 'csv' |
|
159 | :controller => 'timelog', :action => 'report', :project_id => '567', :format => 'csv' | |
137 | ) |
|
160 | ) | |
138 | end |
|
161 | end | |
139 |
|
162 | |||
140 | def test_report_no_criteria |
|
163 | def test_report_no_criteria | |
141 | get :report, :project_id => 1 |
|
164 | get :report, :project_id => 1 | |
142 | assert_response :success |
|
165 | assert_response :success | |
143 | assert_template 'report' |
|
166 | assert_template 'report' | |
144 | end |
|
167 | end | |
145 |
|
168 | |||
146 | def test_report_routing_for_all_projects |
|
169 | def test_report_routing_for_all_projects | |
147 | assert_routing( |
|
170 | assert_routing( | |
148 | {:method => :get, :path => '/time_entries/report'}, |
|
171 | {:method => :get, :path => '/time_entries/report'}, | |
149 | :controller => 'timelog', :action => 'report' |
|
172 | :controller => 'timelog', :action => 'report' | |
150 | ) |
|
173 | ) | |
151 | end |
|
174 | end | |
152 |
|
175 | |||
153 | def test_report_all_projects |
|
176 | def test_report_all_projects | |
154 | get :report |
|
177 | get :report | |
155 | assert_response :success |
|
178 | assert_response :success | |
156 | assert_template 'report' |
|
179 | assert_template 'report' | |
157 | end |
|
180 | end | |
158 |
|
181 | |||
159 | def test_report_all_projects_denied |
|
182 | def test_report_all_projects_denied | |
160 | r = Role.anonymous |
|
183 | r = Role.anonymous | |
161 | r.permissions.delete(:view_time_entries) |
|
184 | r.permissions.delete(:view_time_entries) | |
162 | r.permissions_will_change! |
|
185 | r.permissions_will_change! | |
163 | r.save |
|
186 | r.save | |
164 | get :report |
|
187 | get :report | |
165 | assert_redirected_to '/login?back_url=http%3A%2F%2Ftest.host%2Ftime_entries%2Freport' |
|
188 | assert_redirected_to '/login?back_url=http%3A%2F%2Ftest.host%2Ftime_entries%2Freport' | |
166 | end |
|
189 | end | |
167 |
|
190 | |||
168 | def test_report_all_projects_one_criteria |
|
191 | def test_report_all_projects_one_criteria | |
169 | get :report, :columns => 'week', :from => "2007-04-01", :to => "2007-04-30", :criterias => ['project'] |
|
192 | get :report, :columns => 'week', :from => "2007-04-01", :to => "2007-04-30", :criterias => ['project'] | |
170 | assert_response :success |
|
193 | assert_response :success | |
171 | assert_template 'report' |
|
194 | assert_template 'report' | |
172 | assert_not_nil assigns(:total_hours) |
|
195 | assert_not_nil assigns(:total_hours) | |
173 | assert_equal "8.65", "%.2f" % assigns(:total_hours) |
|
196 | assert_equal "8.65", "%.2f" % assigns(:total_hours) | |
174 | end |
|
197 | end | |
175 |
|
198 | |||
176 | def test_report_all_time |
|
199 | def test_report_all_time | |
177 | get :report, :project_id => 1, :criterias => ['project', 'issue'] |
|
200 | get :report, :project_id => 1, :criterias => ['project', 'issue'] | |
178 | assert_response :success |
|
201 | assert_response :success | |
179 | assert_template 'report' |
|
202 | assert_template 'report' | |
180 | assert_not_nil assigns(:total_hours) |
|
203 | assert_not_nil assigns(:total_hours) | |
181 | assert_equal "162.90", "%.2f" % assigns(:total_hours) |
|
204 | assert_equal "162.90", "%.2f" % assigns(:total_hours) | |
182 | end |
|
205 | end | |
183 |
|
206 | |||
184 | def test_report_all_time_by_day |
|
207 | def test_report_all_time_by_day | |
185 | get :report, :project_id => 1, :criterias => ['project', 'issue'], :columns => 'day' |
|
208 | get :report, :project_id => 1, :criterias => ['project', 'issue'], :columns => 'day' | |
186 | assert_response :success |
|
209 | assert_response :success | |
187 | assert_template 'report' |
|
210 | assert_template 'report' | |
188 | assert_not_nil assigns(:total_hours) |
|
211 | assert_not_nil assigns(:total_hours) | |
189 | assert_equal "162.90", "%.2f" % assigns(:total_hours) |
|
212 | assert_equal "162.90", "%.2f" % assigns(:total_hours) | |
190 | assert_tag :tag => 'th', :content => '2007-03-12' |
|
213 | assert_tag :tag => 'th', :content => '2007-03-12' | |
191 | end |
|
214 | end | |
192 |
|
215 | |||
193 | def test_report_one_criteria |
|
216 | def test_report_one_criteria | |
194 | get :report, :project_id => 1, :columns => 'week', :from => "2007-04-01", :to => "2007-04-30", :criterias => ['project'] |
|
217 | get :report, :project_id => 1, :columns => 'week', :from => "2007-04-01", :to => "2007-04-30", :criterias => ['project'] | |
195 | assert_response :success |
|
218 | assert_response :success | |
196 | assert_template 'report' |
|
219 | assert_template 'report' | |
197 | assert_not_nil assigns(:total_hours) |
|
220 | assert_not_nil assigns(:total_hours) | |
198 | assert_equal "8.65", "%.2f" % assigns(:total_hours) |
|
221 | assert_equal "8.65", "%.2f" % assigns(:total_hours) | |
199 | end |
|
222 | end | |
200 |
|
223 | |||
201 | def test_report_two_criterias |
|
224 | def test_report_two_criterias | |
202 | get :report, :project_id => 1, :columns => 'month', :from => "2007-01-01", :to => "2007-12-31", :criterias => ["member", "activity"] |
|
225 | get :report, :project_id => 1, :columns => 'month', :from => "2007-01-01", :to => "2007-12-31", :criterias => ["member", "activity"] | |
203 | assert_response :success |
|
226 | assert_response :success | |
204 | assert_template 'report' |
|
227 | assert_template 'report' | |
205 | assert_not_nil assigns(:total_hours) |
|
228 | assert_not_nil assigns(:total_hours) | |
206 | assert_equal "162.90", "%.2f" % assigns(:total_hours) |
|
229 | assert_equal "162.90", "%.2f" % assigns(:total_hours) | |
207 | end |
|
230 | end | |
208 |
|
231 | |||
209 | def test_report_at_issue_level |
|
232 | def test_report_at_issue_level | |
210 | get :report, :project_id => 1, :issue_id => 1, :columns => 'month', :from => "2007-01-01", :to => "2007-12-31", :criterias => ["member", "activity"] |
|
233 | get :report, :project_id => 1, :issue_id => 1, :columns => 'month', :from => "2007-01-01", :to => "2007-12-31", :criterias => ["member", "activity"] | |
211 | assert_response :success |
|
234 | assert_response :success | |
212 | assert_template 'report' |
|
235 | assert_template 'report' | |
213 | assert_not_nil assigns(:total_hours) |
|
236 | assert_not_nil assigns(:total_hours) | |
214 | assert_equal "154.25", "%.2f" % assigns(:total_hours) |
|
237 | assert_equal "154.25", "%.2f" % assigns(:total_hours) | |
215 | end |
|
238 | end | |
216 |
|
239 | |||
217 | def test_report_custom_field_criteria |
|
240 | def test_report_custom_field_criteria | |
218 | get :report, :project_id => 1, :criterias => ['project', 'cf_1'] |
|
241 | get :report, :project_id => 1, :criterias => ['project', 'cf_1'] | |
219 | assert_response :success |
|
242 | assert_response :success | |
220 | assert_template 'report' |
|
243 | assert_template 'report' | |
221 | assert_not_nil assigns(:total_hours) |
|
244 | assert_not_nil assigns(:total_hours) | |
222 | assert_not_nil assigns(:criterias) |
|
245 | assert_not_nil assigns(:criterias) | |
223 | assert_equal 2, assigns(:criterias).size |
|
246 | assert_equal 2, assigns(:criterias).size | |
224 | assert_equal "162.90", "%.2f" % assigns(:total_hours) |
|
247 | assert_equal "162.90", "%.2f" % assigns(:total_hours) | |
225 | # Custom field column |
|
248 | # Custom field column | |
226 | assert_tag :tag => 'th', :content => 'Database' |
|
249 | assert_tag :tag => 'th', :content => 'Database' | |
227 | # Custom field row |
|
250 | # Custom field row | |
228 | assert_tag :tag => 'td', :content => 'MySQL', |
|
251 | assert_tag :tag => 'td', :content => 'MySQL', | |
229 | :sibling => { :tag => 'td', :attributes => { :class => 'hours' }, |
|
252 | :sibling => { :tag => 'td', :attributes => { :class => 'hours' }, | |
230 | :child => { :tag => 'span', :attributes => { :class => 'hours hours-int' }, |
|
253 | :child => { :tag => 'span', :attributes => { :class => 'hours hours-int' }, | |
231 | :content => '1' }} |
|
254 | :content => '1' }} | |
232 | end |
|
255 | end | |
233 |
|
256 | |||
234 | def test_report_one_criteria_no_result |
|
257 | def test_report_one_criteria_no_result | |
235 | get :report, :project_id => 1, :columns => 'week', :from => "1998-04-01", :to => "1998-04-30", :criterias => ['project'] |
|
258 | get :report, :project_id => 1, :columns => 'week', :from => "1998-04-01", :to => "1998-04-30", :criterias => ['project'] | |
236 | assert_response :success |
|
259 | assert_response :success | |
237 | assert_template 'report' |
|
260 | assert_template 'report' | |
238 | assert_not_nil assigns(:total_hours) |
|
261 | assert_not_nil assigns(:total_hours) | |
239 | assert_equal "0.00", "%.2f" % assigns(:total_hours) |
|
262 | assert_equal "0.00", "%.2f" % assigns(:total_hours) | |
240 | end |
|
263 | end | |
241 |
|
264 | |||
242 | def test_report_all_projects_csv_export |
|
265 | def test_report_all_projects_csv_export | |
243 | get :report, :columns => 'month', :from => "2007-01-01", :to => "2007-06-30", :criterias => ["project", "member", "activity"], :format => "csv" |
|
266 | get :report, :columns => 'month', :from => "2007-01-01", :to => "2007-06-30", :criterias => ["project", "member", "activity"], :format => "csv" | |
244 | assert_response :success |
|
267 | assert_response :success | |
245 | assert_equal 'text/csv', @response.content_type |
|
268 | assert_equal 'text/csv', @response.content_type | |
246 | lines = @response.body.chomp.split("\n") |
|
269 | lines = @response.body.chomp.split("\n") | |
247 | # Headers |
|
270 | # Headers | |
248 | assert_equal 'Project,Member,Activity,2007-1,2007-2,2007-3,2007-4,2007-5,2007-6,Total', lines.first |
|
271 | assert_equal 'Project,Member,Activity,2007-1,2007-2,2007-3,2007-4,2007-5,2007-6,Total', lines.first | |
249 | # Total row |
|
272 | # Total row | |
250 | assert_equal 'Total,"","","","",154.25,8.65,"","",162.90', lines.last |
|
273 | assert_equal 'Total,"","","","",154.25,8.65,"","",162.90', lines.last | |
251 | end |
|
274 | end | |
252 |
|
275 | |||
253 | def test_report_csv_export |
|
276 | def test_report_csv_export | |
254 | get :report, :project_id => 1, :columns => 'month', :from => "2007-01-01", :to => "2007-06-30", :criterias => ["project", "member", "activity"], :format => "csv" |
|
277 | get :report, :project_id => 1, :columns => 'month', :from => "2007-01-01", :to => "2007-06-30", :criterias => ["project", "member", "activity"], :format => "csv" | |
255 | assert_response :success |
|
278 | assert_response :success | |
256 | assert_equal 'text/csv', @response.content_type |
|
279 | assert_equal 'text/csv', @response.content_type | |
257 | lines = @response.body.chomp.split("\n") |
|
280 | lines = @response.body.chomp.split("\n") | |
258 | # Headers |
|
281 | # Headers | |
259 | assert_equal 'Project,Member,Activity,2007-1,2007-2,2007-3,2007-4,2007-5,2007-6,Total', lines.first |
|
282 | assert_equal 'Project,Member,Activity,2007-1,2007-2,2007-3,2007-4,2007-5,2007-6,Total', lines.first | |
260 | # Total row |
|
283 | # Total row | |
261 | assert_equal 'Total,"","","","",154.25,8.65,"","",162.90', lines.last |
|
284 | assert_equal 'Total,"","","","",154.25,8.65,"","",162.90', lines.last | |
262 | end |
|
285 | end | |
263 |
|
286 | |||
264 | def test_details_all_projects |
|
287 | def test_details_all_projects | |
265 | get :details |
|
288 | get :details | |
266 | assert_response :success |
|
289 | assert_response :success | |
267 | assert_template 'details' |
|
290 | assert_template 'details' | |
268 | assert_not_nil assigns(:total_hours) |
|
291 | assert_not_nil assigns(:total_hours) | |
269 | assert_equal "162.90", "%.2f" % assigns(:total_hours) |
|
292 | assert_equal "162.90", "%.2f" % assigns(:total_hours) | |
270 | end |
|
293 | end | |
271 |
|
294 | |||
272 | def test_project_details_routing |
|
295 | def test_project_details_routing | |
273 | assert_routing( |
|
296 | assert_routing( | |
274 | {:method => :get, :path => '/projects/567/time_entries'}, |
|
297 | {:method => :get, :path => '/projects/567/time_entries'}, | |
275 | :controller => 'timelog', :action => 'details', :project_id => '567' |
|
298 | :controller => 'timelog', :action => 'details', :project_id => '567' | |
276 | ) |
|
299 | ) | |
277 | end |
|
300 | end | |
278 |
|
301 | |||
279 | def test_details_at_project_level |
|
302 | def test_details_at_project_level | |
280 | get :details, :project_id => 1 |
|
303 | get :details, :project_id => 1 | |
281 | assert_response :success |
|
304 | assert_response :success | |
282 | assert_template 'details' |
|
305 | assert_template 'details' | |
283 | assert_not_nil assigns(:entries) |
|
306 | assert_not_nil assigns(:entries) | |
284 | assert_equal 4, assigns(:entries).size |
|
307 | assert_equal 4, assigns(:entries).size | |
285 | # project and subproject |
|
308 | # project and subproject | |
286 | assert_equal [1, 3], assigns(:entries).collect(&:project_id).uniq.sort |
|
309 | assert_equal [1, 3], assigns(:entries).collect(&:project_id).uniq.sort | |
287 | assert_not_nil assigns(:total_hours) |
|
310 | assert_not_nil assigns(:total_hours) | |
288 | assert_equal "162.90", "%.2f" % assigns(:total_hours) |
|
311 | assert_equal "162.90", "%.2f" % assigns(:total_hours) | |
289 | # display all time by default |
|
312 | # display all time by default | |
290 | assert_equal '2007-03-11'.to_date, assigns(:from) |
|
313 | assert_equal '2007-03-11'.to_date, assigns(:from) | |
291 | assert_equal '2007-04-22'.to_date, assigns(:to) |
|
314 | assert_equal '2007-04-22'.to_date, assigns(:to) | |
292 | end |
|
315 | end | |
293 |
|
316 | |||
294 | def test_details_at_project_level_with_date_range |
|
317 | def test_details_at_project_level_with_date_range | |
295 | get :details, :project_id => 1, :from => '2007-03-20', :to => '2007-04-30' |
|
318 | get :details, :project_id => 1, :from => '2007-03-20', :to => '2007-04-30' | |
296 | assert_response :success |
|
319 | assert_response :success | |
297 | assert_template 'details' |
|
320 | assert_template 'details' | |
298 | assert_not_nil assigns(:entries) |
|
321 | assert_not_nil assigns(:entries) | |
299 | assert_equal 3, assigns(:entries).size |
|
322 | assert_equal 3, assigns(:entries).size | |
300 | assert_not_nil assigns(:total_hours) |
|
323 | assert_not_nil assigns(:total_hours) | |
301 | assert_equal "12.90", "%.2f" % assigns(:total_hours) |
|
324 | assert_equal "12.90", "%.2f" % assigns(:total_hours) | |
302 | assert_equal '2007-03-20'.to_date, assigns(:from) |
|
325 | assert_equal '2007-03-20'.to_date, assigns(:from) | |
303 | assert_equal '2007-04-30'.to_date, assigns(:to) |
|
326 | assert_equal '2007-04-30'.to_date, assigns(:to) | |
304 | end |
|
327 | end | |
305 |
|
328 | |||
306 | def test_details_at_project_level_with_period |
|
329 | def test_details_at_project_level_with_period | |
307 | get :details, :project_id => 1, :period => '7_days' |
|
330 | get :details, :project_id => 1, :period => '7_days' | |
308 | assert_response :success |
|
331 | assert_response :success | |
309 | assert_template 'details' |
|
332 | assert_template 'details' | |
310 | assert_not_nil assigns(:entries) |
|
333 | assert_not_nil assigns(:entries) | |
311 | assert_not_nil assigns(:total_hours) |
|
334 | assert_not_nil assigns(:total_hours) | |
312 | assert_equal Date.today - 7, assigns(:from) |
|
335 | assert_equal Date.today - 7, assigns(:from) | |
313 | assert_equal Date.today, assigns(:to) |
|
336 | assert_equal Date.today, assigns(:to) | |
314 | end |
|
337 | end | |
315 |
|
338 | |||
316 | def test_issue_details_routing |
|
339 | def test_issue_details_routing | |
317 | assert_routing( |
|
340 | assert_routing( | |
318 | {:method => :get, :path => 'time_entries'}, |
|
341 | {:method => :get, :path => 'time_entries'}, | |
319 | :controller => 'timelog', :action => 'details' |
|
342 | :controller => 'timelog', :action => 'details' | |
320 | ) |
|
343 | ) | |
321 | assert_routing( |
|
344 | assert_routing( | |
322 | {:method => :get, :path => '/issues/234/time_entries'}, |
|
345 | {:method => :get, :path => '/issues/234/time_entries'}, | |
323 | :controller => 'timelog', :action => 'details', :issue_id => '234' |
|
346 | :controller => 'timelog', :action => 'details', :issue_id => '234' | |
324 | ) |
|
347 | ) | |
325 | # TODO: issue detail page shouldnt link to project_issue_time_entries_path but to normal issues one |
|
348 | # TODO: issue detail page shouldnt link to project_issue_time_entries_path but to normal issues one | |
326 | # doesnt seem to have effect on resulting page so controller can be left untouched |
|
349 | # doesnt seem to have effect on resulting page so controller can be left untouched | |
327 | assert_routing( |
|
350 | assert_routing( | |
328 | {:method => :get, :path => '/projects/ecookbook/issues/123/time_entries'}, |
|
351 | {:method => :get, :path => '/projects/ecookbook/issues/123/time_entries'}, | |
329 | :controller => 'timelog', :action => 'details', :project_id => 'ecookbook', :issue_id => '123' |
|
352 | :controller => 'timelog', :action => 'details', :project_id => 'ecookbook', :issue_id => '123' | |
330 | ) |
|
353 | ) | |
331 | end |
|
354 | end | |
332 |
|
355 | |||
333 | def test_details_at_issue_level |
|
356 | def test_details_at_issue_level | |
334 | get :details, :issue_id => 1 |
|
357 | get :details, :issue_id => 1 | |
335 | assert_response :success |
|
358 | assert_response :success | |
336 | assert_template 'details' |
|
359 | assert_template 'details' | |
337 | assert_not_nil assigns(:entries) |
|
360 | assert_not_nil assigns(:entries) | |
338 | assert_equal 2, assigns(:entries).size |
|
361 | assert_equal 2, assigns(:entries).size | |
339 | assert_not_nil assigns(:total_hours) |
|
362 | assert_not_nil assigns(:total_hours) | |
340 | assert_equal 154.25, assigns(:total_hours) |
|
363 | assert_equal 154.25, assigns(:total_hours) | |
341 | # display all time by default |
|
364 | # display all time by default | |
342 | assert_equal '2007-03-11'.to_date, assigns(:from) |
|
365 | assert_equal '2007-03-11'.to_date, assigns(:from) | |
343 | assert_equal '2007-04-22'.to_date, assigns(:to) |
|
366 | assert_equal '2007-04-22'.to_date, assigns(:to) | |
344 | end |
|
367 | end | |
345 |
|
368 | |||
346 | def test_details_formatted_routing |
|
369 | def test_details_formatted_routing | |
347 | assert_routing( |
|
370 | assert_routing( | |
348 | {:method => :get, :path => 'time_entries.atom'}, |
|
371 | {:method => :get, :path => 'time_entries.atom'}, | |
349 | :controller => 'timelog', :action => 'details', :format => 'atom' |
|
372 | :controller => 'timelog', :action => 'details', :format => 'atom' | |
350 | ) |
|
373 | ) | |
351 | assert_routing( |
|
374 | assert_routing( | |
352 | {:method => :get, :path => 'time_entries.csv'}, |
|
375 | {:method => :get, :path => 'time_entries.csv'}, | |
353 | :controller => 'timelog', :action => 'details', :format => 'csv' |
|
376 | :controller => 'timelog', :action => 'details', :format => 'csv' | |
354 | ) |
|
377 | ) | |
355 | end |
|
378 | end | |
356 |
|
379 | |||
357 | def test_details_for_project_formatted_routing |
|
380 | def test_details_for_project_formatted_routing | |
358 | assert_routing( |
|
381 | assert_routing( | |
359 | {:method => :get, :path => '/projects/567/time_entries.atom'}, |
|
382 | {:method => :get, :path => '/projects/567/time_entries.atom'}, | |
360 | :controller => 'timelog', :action => 'details', :format => 'atom', :project_id => '567' |
|
383 | :controller => 'timelog', :action => 'details', :format => 'atom', :project_id => '567' | |
361 | ) |
|
384 | ) | |
362 | assert_routing( |
|
385 | assert_routing( | |
363 | {:method => :get, :path => '/projects/567/time_entries.csv'}, |
|
386 | {:method => :get, :path => '/projects/567/time_entries.csv'}, | |
364 | :controller => 'timelog', :action => 'details', :format => 'csv', :project_id => '567' |
|
387 | :controller => 'timelog', :action => 'details', :format => 'csv', :project_id => '567' | |
365 | ) |
|
388 | ) | |
366 | end |
|
389 | end | |
367 |
|
390 | |||
368 | def test_details_for_issue_formatted_routing |
|
391 | def test_details_for_issue_formatted_routing | |
369 | assert_routing( |
|
392 | assert_routing( | |
370 | {:method => :get, :path => '/projects/ecookbook/issues/123/time_entries.atom'}, |
|
393 | {:method => :get, :path => '/projects/ecookbook/issues/123/time_entries.atom'}, | |
371 | :controller => 'timelog', :action => 'details', :project_id => 'ecookbook', :issue_id => '123', :format => 'atom' |
|
394 | :controller => 'timelog', :action => 'details', :project_id => 'ecookbook', :issue_id => '123', :format => 'atom' | |
372 | ) |
|
395 | ) | |
373 | assert_routing( |
|
396 | assert_routing( | |
374 | {:method => :get, :path => '/projects/ecookbook/issues/123/time_entries.csv'}, |
|
397 | {:method => :get, :path => '/projects/ecookbook/issues/123/time_entries.csv'}, | |
375 | :controller => 'timelog', :action => 'details', :project_id => 'ecookbook', :issue_id => '123', :format => 'csv' |
|
398 | :controller => 'timelog', :action => 'details', :project_id => 'ecookbook', :issue_id => '123', :format => 'csv' | |
376 | ) |
|
399 | ) | |
377 | end |
|
400 | end | |
378 |
|
401 | |||
379 | def test_details_atom_feed |
|
402 | def test_details_atom_feed | |
380 | get :details, :project_id => 1, :format => 'atom' |
|
403 | get :details, :project_id => 1, :format => 'atom' | |
381 | assert_response :success |
|
404 | assert_response :success | |
382 | assert_equal 'application/atom+xml', @response.content_type |
|
405 | assert_equal 'application/atom+xml', @response.content_type | |
383 | assert_not_nil assigns(:items) |
|
406 | assert_not_nil assigns(:items) | |
384 | assert assigns(:items).first.is_a?(TimeEntry) |
|
407 | assert assigns(:items).first.is_a?(TimeEntry) | |
385 | end |
|
408 | end | |
386 |
|
409 | |||
387 | def test_details_all_projects_csv_export |
|
410 | def test_details_all_projects_csv_export | |
388 | Setting.date_format = '%m/%d/%Y' |
|
411 | Setting.date_format = '%m/%d/%Y' | |
389 | get :details, :format => 'csv' |
|
412 | get :details, :format => 'csv' | |
390 | assert_response :success |
|
413 | assert_response :success | |
391 | assert_equal 'text/csv', @response.content_type |
|
414 | assert_equal 'text/csv', @response.content_type | |
392 | assert @response.body.include?("Date,User,Activity,Project,Issue,Tracker,Subject,Hours,Comment\n") |
|
415 | assert @response.body.include?("Date,User,Activity,Project,Issue,Tracker,Subject,Hours,Comment\n") | |
393 | assert @response.body.include?("\n04/21/2007,redMine Admin,Design,eCookbook,3,Bug,Error 281 when updating a recipe,1.0,\"\"\n") |
|
416 | assert @response.body.include?("\n04/21/2007,redMine Admin,Design,eCookbook,3,Bug,Error 281 when updating a recipe,1.0,\"\"\n") | |
394 | end |
|
417 | end | |
395 |
|
418 | |||
396 | def test_details_csv_export |
|
419 | def test_details_csv_export | |
397 | Setting.date_format = '%m/%d/%Y' |
|
420 | Setting.date_format = '%m/%d/%Y' | |
398 | get :details, :project_id => 1, :format => 'csv' |
|
421 | get :details, :project_id => 1, :format => 'csv' | |
399 | assert_response :success |
|
422 | assert_response :success | |
400 | assert_equal 'text/csv', @response.content_type |
|
423 | assert_equal 'text/csv', @response.content_type | |
401 | assert @response.body.include?("Date,User,Activity,Project,Issue,Tracker,Subject,Hours,Comment\n") |
|
424 | assert @response.body.include?("Date,User,Activity,Project,Issue,Tracker,Subject,Hours,Comment\n") | |
402 | assert @response.body.include?("\n04/21/2007,redMine Admin,Design,eCookbook,3,Bug,Error 281 when updating a recipe,1.0,\"\"\n") |
|
425 | assert @response.body.include?("\n04/21/2007,redMine Admin,Design,eCookbook,3,Bug,Error 281 when updating a recipe,1.0,\"\"\n") | |
403 | end |
|
426 | end | |
404 | end |
|
427 | end |
General Comments 0
You need to be logged in to leave comments.
Login now