backlog 0.14.4 → 0.15.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/History.txt +21 -0
- data/app/controllers/backlogs_controller.rb +1 -1
- data/app/controllers/periods_controller.rb +4 -8
- data/app/controllers/search_controller.rb +2 -1
- data/app/controllers/tasks_controller.rb +8 -2
- data/app/controllers/works_controller.rb +1 -1
- data/app/helpers/backlogs_helper.rb +9 -6
- data/app/helpers/periods_helper.rb +4 -1
- data/app/models/work.rb +2 -2
- data/app/views/backlogs/_buttons.rhtml +1 -2
- data/app/views/backlogs/_form.rhtml +7 -0
- data/app/views/backlogs/show.rhtml +31 -3
- data/app/views/periods/_show_active.rhtml +2 -2
- data/app/views/tasks/_completed.rhtml +3 -1
- data/app/views/tasks/_fields_header.rhtml +2 -2
- data/app/views/tasks/_form.rhtml +10 -3
- data/app/views/tasks/_task.rhtml +10 -14
- data/app/views/tasks/notes.rhtml +8 -0
- data/db/migrate/024_add_sprint_option.rb +10 -0
- data/db/schema.rb +2 -1
- data/lang/en.yaml +4 -1
- data/lang/no.yaml +3 -0
- data/public/images/view_fullscreen.png +0 -0
- data/test/fixtures/tasks.yml +1 -0
- data/test/functional/search_controller_test.rb +9 -3
- metadata +5 -3
- data/app/views/backlogs/_tasks.rhtml +0 -33
data/History.txt
CHANGED
@@ -1,3 +1,24 @@
|
|
1
|
+
== 0.15.0 2007-11-28
|
2
|
+
|
3
|
+
=== Features
|
4
|
+
|
5
|
+
* Expanded search to include the "notes" field of tasks.
|
6
|
+
* Added unformatted viewing of notes for a task.
|
7
|
+
* Made using sprints an option for backlogs. Default is not to use sprints to enable simple usage of the Backlog application.
|
8
|
+
Existing backlogs have the option set even if no sprints have been started, for backwards compatibility.
|
9
|
+
* Added link from task line to task editing view.
|
10
|
+
|
11
|
+
=== Fixes
|
12
|
+
|
13
|
+
* Ordered work records by end date in list view.
|
14
|
+
* Fixed wrong redirect when moving an unplanned task to a sprint.
|
15
|
+
* Fixed bug when editing a finished task leads to reopening it.
|
16
|
+
* Fixed cosmetic errors in finishing and reopening tasks.
|
17
|
+
* Fixed error when tracking time done, but not start and stop times.
|
18
|
+
* Removed unnecessary icon for showing a backlog when already showing the backlog.
|
19
|
+
* Fixed missing border around icons in backlog view.
|
20
|
+
* Fixed cosmetics on task lines.
|
21
|
+
|
1
22
|
== 0.14.4 2007-11-27
|
2
23
|
|
3
24
|
=== Features
|
@@ -148,7 +148,7 @@ class BacklogsController < ApplicationController
|
|
148
148
|
params[:period_id] = next_period && next_period.id
|
149
149
|
move_task_to_period
|
150
150
|
else
|
151
|
-
rjs_redirect_to :action => :edit, :id => @task
|
151
|
+
rjs_redirect_to :controller => 'tasks', :action => :edit, :id => @task
|
152
152
|
end
|
153
153
|
end
|
154
154
|
|
@@ -140,14 +140,10 @@ class PeriodsController < ApplicationController
|
|
140
140
|
|
141
141
|
def move_task_to_next_period
|
142
142
|
@task = Task.find(params[:id])
|
143
|
-
|
144
|
-
|
145
|
-
|
146
|
-
|
147
|
-
move_task_to_period
|
148
|
-
else
|
149
|
-
rjs_redirect_to :action => :edit, :id => @task
|
150
|
-
end
|
143
|
+
next_period = @task.period.lower_item
|
144
|
+
next_period = next_period.lower_item while next_period && next_period.passed?
|
145
|
+
params[:period_id] = next_period && next_period.id
|
146
|
+
move_task_to_period
|
151
147
|
end
|
152
148
|
|
153
149
|
def finish_task
|
@@ -1,9 +1,10 @@
|
|
1
1
|
class SearchController < ApplicationController
|
2
|
+
|
2
3
|
def results
|
3
4
|
if params[:q]
|
4
5
|
@search = params[:q]
|
5
6
|
@backlogs = Backlog.find(:all, :conditions => ["lower(name) LIKE ?", "%#{@search.downcase}%"])
|
6
|
-
@tasks = Task.find(:all, :conditions => ["lower(description) LIKE ?", "%#{@search.downcase}%"])
|
7
|
+
@tasks = Task.find(:all, :conditions => ["lower(description) LIKE ? OR lower(notes) LIKE ?", "%#{@search.downcase}%", "%#{@search.downcase}%"])
|
7
8
|
else
|
8
9
|
@backlogs = []
|
9
10
|
@tasks = []
|
@@ -1,7 +1,7 @@
|
|
1
1
|
class TasksController < ApplicationController
|
2
2
|
skip_before_filter :populate_layout, :except => [:edit, :list_started, :move_down, :move_to_bottom, :move_to_top, :move_up, :new, :specify]
|
3
3
|
|
4
|
-
verify :method => :post, :except => [ :new, :show, :edit, :list_started, :move_to_next_period],
|
4
|
+
verify :method => :post, :except => [ :new, :show, :edit, :list_started, :move_to_next_period, :notes],
|
5
5
|
:redirect_to => { :controller => 'backlogs' }
|
6
6
|
|
7
7
|
def list_started
|
@@ -109,6 +109,9 @@ class TasksController < ApplicationController
|
|
109
109
|
else
|
110
110
|
if @task.finished_at
|
111
111
|
@task.reopen
|
112
|
+
flash[:notice] += 'Task was reopened.'
|
113
|
+
populate_layout
|
114
|
+
render :action => 'edit'
|
112
115
|
else
|
113
116
|
if @task.period
|
114
117
|
back_or_redirect_to :controller => 'periods', :action => :show, :id => @task.period, :task => @task.id
|
@@ -260,6 +263,9 @@ class TasksController < ApplicationController
|
|
260
263
|
render :text => task.description
|
261
264
|
end
|
262
265
|
|
263
|
-
|
266
|
+
def notes
|
267
|
+
@task = Task.find(params[:id])
|
268
|
+
render :layout => 'wide'
|
269
|
+
end
|
264
270
|
|
265
271
|
end
|
@@ -17,7 +17,7 @@ class WorksController < ApplicationController
|
|
17
17
|
|
18
18
|
def list
|
19
19
|
@period = params[:id] && Period.find(params[:id])
|
20
|
-
@work_pages, @works = paginate :works, :per_page => 20
|
20
|
+
@work_pages, @works = paginate :works, :order => 'completed_at', :per_page => 20
|
21
21
|
end
|
22
22
|
|
23
23
|
def show
|
@@ -14,7 +14,9 @@ module BacklogsHelper
|
|
14
14
|
end
|
15
15
|
|
16
16
|
def add_finished_task(page)
|
17
|
-
|
17
|
+
tasks_in_period = @completed_tasks.select {|t| t.period_id == @task.period_id}
|
18
|
+
work_done = ! tasks_in_period.find {|t| t.total_done != 0}.nil?
|
19
|
+
not_first = tasks_in_period.size > 1
|
18
20
|
if not_first
|
19
21
|
page.select("#completed_tasks_#{@task.period_id} tr").first.remove
|
20
22
|
page.select("#completed_tasks_#{@task.period_id} tr").first.remove
|
@@ -25,7 +27,7 @@ module BacklogsHelper
|
|
25
27
|
page.insert_html :top, "completed_tasks_#{@task.period_id}", :partial => '/tasks/task', :locals => {:active => false, :hidden => true, :highlight_task => false}
|
26
28
|
page.visual_effect :appear, "task_#{@task.id}"
|
27
29
|
|
28
|
-
page.insert_html :top, "completed_tasks_#{@task.period_id}", :partial => '/tasks/fields_header', :locals => {:backlog => @task.backlog, :active => false}
|
30
|
+
page.insert_html :top, "completed_tasks_#{@task.period_id}", :partial => '/tasks/fields_header', :locals => {:backlog => @task.backlog, :active => false, :work_done => work_done}
|
29
31
|
page.insert_html :top, "completed_tasks_#{@task.period_id}", :partial => '/tasks/period_header', :locals => {:period => @task.period}
|
30
32
|
end
|
31
33
|
|
@@ -39,17 +41,18 @@ module BacklogsHelper
|
|
39
41
|
end
|
40
42
|
|
41
43
|
def add_active_task(page)
|
42
|
-
|
44
|
+
tasks_in_period = @tasks.select{|t| t.period_id == @task.period_id}
|
45
|
+
first_in_period = tasks_in_period.size == 1
|
43
46
|
if first_in_period
|
44
47
|
page.insert_html :top, :active_tasks, %Q{<table id="active_tasks_#{@task.period_id}" class="input" style="width: 100%;"/>}
|
45
48
|
else
|
46
|
-
page.select(
|
47
|
-
page.select(
|
49
|
+
page.select("#active_tasks_#{@task.period_id} tr").first.remove
|
50
|
+
page.select("#active_tasks_#{@task.period_id} tr").first.remove
|
48
51
|
end
|
49
52
|
|
50
53
|
page.insert_html(:top, "active_tasks_#{@task.period_id}", render(:partial => "/tasks/task", :locals => { :task => @task, :i => 1, :active => true, :highlight_task => false, :update => :spotlight, :hidden => true }))
|
51
54
|
|
52
|
-
fields_header = render(:partial => '/tasks/fields_header', :locals => { :backlog => @task.backlog, :active => true } )
|
55
|
+
fields_header = render(:partial => '/tasks/fields_header', :locals => { :backlog => @task.backlog, :active => true, :track_times => tasks_in_period.find {|t|t.period && t.period.active?} } )
|
53
56
|
page.insert_html :top, "active_tasks_#{@task.period_id}", fields_header
|
54
57
|
page.insert_html :top, "active_tasks_#{@task.period_id}", render(:partial => "/tasks/period_header", :locals => {:period => @task.period})
|
55
58
|
|
@@ -45,15 +45,18 @@ module PeriodsHelper
|
|
45
45
|
end
|
46
46
|
|
47
47
|
def add_finished_task(page)
|
48
|
+
work_done = ! @completed_tasks.find {|t| t.total_done != 0}.nil?
|
48
49
|
first_finished = @completed_tasks.find {|t| t.id != @task.id}.nil?
|
49
50
|
unless first_finished
|
50
51
|
page.select("#completed_tasks_#{@task.period_id} tr").first.remove
|
52
|
+
else
|
53
|
+
page.insert_html :top, "completed_tasks", "<table id=\"completed_tasks_#{@task.period_id}\" class=\"input\" />"
|
51
54
|
end
|
52
55
|
|
53
56
|
page.insert_html :top, "completed_tasks_#{@task.period_id}", :partial => '/tasks/task', :locals => {:active => false, :hidden => true, :highlight_task => false}
|
54
57
|
page.visual_effect :appear, "task_#{@task.id}"
|
55
58
|
|
56
|
-
page.insert_html :top, "completed_tasks_#{@task.period_id}", :partial => '/tasks/fields_header', :locals => {:backlog => @task.backlog, :active => false}
|
59
|
+
page.insert_html :top, "completed_tasks_#{@task.period_id}", :partial => '/tasks/fields_header', :locals => {:backlog => @task.backlog, :active => false, :work_done => work_done}
|
57
60
|
end
|
58
61
|
|
59
62
|
def update_burn_down_chart(page)
|
data/app/models/work.rb
CHANGED
@@ -7,7 +7,7 @@ class Work < ActiveRecord::Base
|
|
7
7
|
belongs_to :work_account
|
8
8
|
|
9
9
|
validates_associated :task
|
10
|
-
validates_presence_of :started_at
|
10
|
+
validates_presence_of :started_at, :if => :track_times?
|
11
11
|
validates_presence_of :work_account
|
12
12
|
|
13
13
|
def validate
|
@@ -20,7 +20,7 @@ class Work < ActiveRecord::Base
|
|
20
20
|
end
|
21
21
|
|
22
22
|
def track_times?
|
23
|
-
|
23
|
+
work_account.track_times?
|
24
24
|
end
|
25
25
|
|
26
26
|
# Return an array with an array of works per day:
|
@@ -1,4 +1,3 @@
|
|
1
1
|
<%=image_link_to 'arrow_up.png', l(:backlogs), :action => :list %>
|
2
|
-
<%=image_detour_to('clipboard.png', l(:edit), :controller => 'backlogs', :action => :edit, :id => @backlog)%>
|
3
|
-
<%=image_detour_to('clipboard.png', l(:show), :controller => 'backlogs', :action => :show, :id => @backlog)%>
|
2
|
+
<%=image_detour_to('clipboard.png', l(:edit), :controller => 'backlogs', :action => :edit, :id => @backlog) unless controller.action_name == 'edit' %>
|
4
3
|
<%=detour_to(image_tag(url_for("add.png"), :alt => l(:add_task), :title => l(:add_task), :class => 'image-submit'), :controller => 'tasks', :action => 'new', :task => {:backlog_id => @backlog.id} ) %>
|
@@ -4,6 +4,8 @@
|
|
4
4
|
<%= text_field 'backlog', 'name', :maxlength => 64 %>
|
5
5
|
</p>
|
6
6
|
|
7
|
+
<h3>Options</h3>
|
8
|
+
|
7
9
|
<p>
|
8
10
|
<%= check_box 'backlog', 'track_todo' %>
|
9
11
|
<label for="backlog_track_todo"><%=l :track_todo%></label>
|
@@ -14,6 +16,11 @@
|
|
14
16
|
<label for="backlog_enable_subtasks"><%=l :enable_subtasks%></label>
|
15
17
|
</p>
|
16
18
|
|
19
|
+
<p>
|
20
|
+
<%= check_box 'backlog', 'enable_periods' %>
|
21
|
+
<label for="backlog_enable_periods"><%=l :enable_periods%></label>
|
22
|
+
</p>
|
23
|
+
|
17
24
|
<p>
|
18
25
|
<%= check_box 'backlog', 'enable_customer' %>
|
19
26
|
<label for="backlog_enable_customer"><%=l :enable_customer%></label>
|
@@ -1,5 +1,33 @@
|
|
1
|
-
|
2
|
-
|
1
|
+
<%@page_title = @backlog.name %>
|
2
|
+
<div id="spotlight">
|
3
|
+
<div class="btitle">
|
4
|
+
<%=render :partial => 'buttons' %><h4><%=l :tasks %></h4>
|
5
|
+
</div>
|
6
|
+
<div id="active_tasks"<%=' style="display: none;"' unless @tasks and not @tasks.empty? %>>
|
7
|
+
<%#=render :partial => '/tasks/backlog_header', :locals => {:backlog => @backlog, :track_times => @tasks.find {|t|t.period && t.period.active?}} %>
|
8
|
+
<%i = 0 %>
|
9
|
+
<%for period in @tasks.map {|t| t.period}.uniq %>
|
10
|
+
<% tasks_in_period = @tasks.select {|t| t.period_id == (period && period.id)} %>
|
11
|
+
<% work_done = !tasks_in_period.find{|t| t.total_done > 0}.nil? %>
|
12
|
+
<table id="active_tasks_<%=period ? period.id : '' %>">
|
13
|
+
<%=render :partial => '/tasks/period_header', :locals => {:period => period} %>
|
14
|
+
<%=render :partial => '/tasks/fields_header', :locals => {:backlog => @backlog, :active => true, :track_times => tasks_in_period.find {|t|t.period && t.period.active?}, :work_done => work_done} %>
|
15
|
+
<%for @task in tasks_in_period %>
|
16
|
+
<%=render :partial => '/tasks/task/', :locals => {:task => @task, :i => i += 1, :active => true, :highlight_task => false, :update => :maincontent, :hidden => false} %>
|
17
|
+
<%end %>
|
18
|
+
</table>
|
19
|
+
<%end %>
|
20
|
+
</div>
|
21
|
+
<p id="no_tasks_message"<%=' style="display: none;"' if @tasks and not @tasks.empty? %>>
|
22
|
+
<%=l :no_pending_tasks_in_backlog %>
|
23
|
+
</p>
|
24
|
+
<%=back_or_link_to(l(:back)) %>
|
25
|
+
</div>
|
3
26
|
<div id="maincontent">
|
4
|
-
|
27
|
+
<div class="mainblock">
|
28
|
+
<div class="btitle">
|
29
|
+
<h4><%=l(:completed_tasks) %></h4>
|
30
|
+
</div>
|
31
|
+
<%=render :partial => '/tasks/completed', :locals => {:i => 1} %>
|
32
|
+
</div>
|
5
33
|
</div>
|
@@ -40,8 +40,8 @@ function handleEvent(field, event, id) {
|
|
40
40
|
<% current_backlog = task.backlog %>
|
41
41
|
<table class="input" style="width: 100%;">
|
42
42
|
<%= '<tr><td> </td></tr>' if false && current_backlog %>
|
43
|
-
<%=render :partial => '/tasks/backlog_header', :locals => { :backlog => task.backlog, :track_times => @tasks.find {|t|t.period && t.period.active?} } %>
|
44
|
-
<%=render :partial => '/tasks/fields_header', :locals => { :backlog => task.backlog, :active => true, :track_times => @tasks.find {|t|t.period && t.period.active?} } %>
|
43
|
+
<%=render :partial => '/tasks/backlog_header', :locals => { :backlog => task.backlog, :track_times => current_backlog.track_done? && @tasks.find {|t|t.period && t.period.active?} } %>
|
44
|
+
<%=render :partial => '/tasks/fields_header', :locals => { :backlog => task.backlog, :active => true, :track_times => @tasks.find {|t|t.period && t.period.active?}, :work_done => @tasks.find {|t|t.backlog_id == current_backlog.id && t.total_done > 0} } %>
|
45
45
|
<% end -%>
|
46
46
|
<%=render :partial => '/tasks/task', :locals => { :task => task, :i => i, :active => true, :highlight_task => task == @selected_task, :update => :spotlight, :hidden => false } %>
|
47
47
|
<% i += 1 %>
|
@@ -1,8 +1,10 @@
|
|
1
1
|
<div id="completed_tasks">
|
2
2
|
<% @completed_tasks.map {|t| t.period}.uniq.each do |period| %>
|
3
3
|
<table id="completed_tasks_<%=period ? period.id : ''%>" class="input">
|
4
|
+
<% tasks_in_period = @completed_tasks.select {|t| t.period == period} %>
|
5
|
+
<% work_done = !tasks_in_period.find{|t| t.total_done != 0}.nil? %>
|
4
6
|
<%=render :partial => '/tasks/period_header', :locals => {:period => period} unless @completed_tasks.map(&:period).uniq.size == 1 %>
|
5
|
-
<%=render :partial => '/tasks/fields_header', :locals => {:backlog => @backlog, :active => false, :track_times => false} %>
|
7
|
+
<%=render :partial => '/tasks/fields_header', :locals => {:backlog => @backlog, :active => false, :track_times => false, :work_done => work_done} %>
|
6
8
|
<% @completed_tasks.select {|t| t.period == period}.each do |task| %>
|
7
9
|
<%=render :partial => '/tasks/task', :locals => { :task => task, :i => i, :active => false, :highlight_task => task == @selected_task, :hidden => false } %>
|
8
10
|
<% i += 1 %>
|
@@ -2,8 +2,8 @@
|
|
2
2
|
<th/>
|
3
3
|
<th align="center"><%=active ? '#' : l(:resolution_abr)%></th>
|
4
4
|
<th><%=l :task %></th>
|
5
|
-
<th><%=l :start if active && backlog.
|
5
|
+
<th><%=l :start if active && backlog.track_times? %></th>
|
6
6
|
<th/>
|
7
|
-
<th><%=l :done if
|
7
|
+
<th><%=l :done if (active && backlog.track_done?) || work_done %></th>
|
8
8
|
<th width="*"><%=l :todo if active && backlog.track_todo? %></th>
|
9
9
|
</tr>
|
data/app/views/tasks/_form.rhtml
CHANGED
@@ -14,6 +14,7 @@
|
|
14
14
|
</p>
|
15
15
|
|
16
16
|
|
17
|
+
<% if @task.backlog && @task.backlog.enable_periods? %>
|
17
18
|
<p><label for="task_period_id"><%=l :period%></label><br/>
|
18
19
|
<%= select 'task', 'period_id', [['', '']] + @periods.map{|p| [p.name, p.id]}, {},
|
19
20
|
:onchange => remote_function(:update => 'period_link',
|
@@ -23,13 +24,17 @@
|
|
23
24
|
</span>
|
24
25
|
<%=detour_to l(:new_period), :controller => 'periods', :action => :new %>
|
25
26
|
</p>
|
26
|
-
|
27
|
+
<% end %>
|
27
28
|
|
28
29
|
|
29
30
|
<% if @task.backlog %>
|
30
31
|
|
31
32
|
<p><label for="task_description"><%=l :task%></label><br/>
|
32
|
-
|
33
|
+
<% if @task.active? -%>
|
34
|
+
<%=text_field 'task', 'description', :size => 64, :maxlength => 80 %></p>
|
35
|
+
<% else -%>
|
36
|
+
<%=@task.description -%>
|
37
|
+
<% end -%>
|
33
38
|
|
34
39
|
<% if @task.enable_customer? %>
|
35
40
|
<p><label for="task_customer"><%=l :customer%></label><br/>
|
@@ -52,7 +57,9 @@
|
|
52
57
|
<% end %>
|
53
58
|
|
54
59
|
<p><label for="task_notes"><%=l :notes%></label><br/>
|
55
|
-
<%=
|
60
|
+
<%=text_area 'task', 'notes', :cols => '72', :rows => 16 %>
|
61
|
+
<%=if @task.notes and not @task.notes.empty? then image_link_to 'view_fullscreen.png', l(:view_fullscreen), :controller => 'tasks', :action => :notes, :id => @task end%>
|
62
|
+
</p>
|
56
63
|
|
57
64
|
<p><label for="task_file"><%=l :files%></label><br/>
|
58
65
|
<%=@task.task_files.map do |task_file|
|
data/app/views/tasks/_task.rhtml
CHANGED
@@ -9,17 +9,13 @@
|
|
9
9
|
</td>
|
10
10
|
<td align="left" valign="top" width="1" nowrap="true">
|
11
11
|
<%= (" " * @task.depth * 4) if @task.depth > 0 %>
|
12
|
-
|
12
|
+
<%=@task.position if @task.position || @task.depth == 0 %>
|
13
13
|
<%= resolution_image(@task.resolution) if @task.finished_at %>
|
14
14
|
<%= "-" if @task.children.size > 0 %>
|
15
15
|
</td>
|
16
16
|
<td>
|
17
17
|
<div id="task_<%=@task.id%>_description"<%=' class="tasks" onmouseover="this.style.border=\'1px solid black\'" onmouseout="this.style.border=\'1px solid transparent\'"' if active && (@task.period.nil? || @task.period.active_or_future?) && (not @task.work_started?) %>>
|
18
|
-
|
19
|
-
<%=in_place_editor_field(:task, :description, {:id => "#{@task.id}_description", :tabindex => i}, :url => url_for(:controller => 'tasks', :action => "set_task_description", :id => @task)) %>
|
20
|
-
<% else -%>
|
21
|
-
<%=@task.description -%>
|
22
|
-
<% end -%>
|
18
|
+
<%=detour_to h(@task.description), :controller => 'tasks', :action => :edit, :id => @task.id if @task.position || @task.depth == 0 %>
|
23
19
|
</div>
|
24
20
|
</td>
|
25
21
|
<td align="right" nowrap="true" width="1">
|
@@ -29,7 +25,7 @@
|
|
29
25
|
<% if @task.work_started? -%>
|
30
26
|
<%=f.text_field 'started_at_time', :id => "work_#{@task.started_work.id}_started_at_time", :tabindex => i+1, :value => @task.started_work.started_at.strftime('%H:%M'),
|
31
27
|
:class => :task_time, :maxlength => 5 %>
|
32
|
-
<% elsif @task.track_times? && @task.
|
28
|
+
<% elsif @task.track_times? && (@task.period_id.nil? || @task.period.active?) %>
|
33
29
|
<%=image_link_to_remote 'hammer.png', l(:start_work), {:controller => 'tasks', :action => :start_work, :id => @task.id}, nil, true %>
|
34
30
|
<% end -%>
|
35
31
|
<% end %>
|
@@ -42,13 +38,13 @@
|
|
42
38
|
<% end -%>
|
43
39
|
<% end -%>
|
44
40
|
</td>
|
45
|
-
<td align="
|
46
|
-
<% if @task.track_done? %>
|
41
|
+
<td align="<%=active && @task.loggable? && @task.track_done? ? 'left' : 'right'%>" nowrap="true" width="1">
|
42
|
+
<% if @task.track_done? || @task.total_done != 0 %>
|
47
43
|
<% if @task.loggable? || @task.finished_at -%>
|
48
44
|
<% form_tag({:controller => 'works', :action => (@task.work_started? ? :edit : :create), :id => @task.started_work}) do %>
|
49
|
-
<%=
|
50
|
-
<%=
|
51
|
-
<% unless @task.track_times? || @task.work_started? || @task.finished_at -%>
|
45
|
+
<%=hidden_field('work', 'task_id', :value => @task.id)%>
|
46
|
+
<%=submit_tag('checkmark', :value => l(:save), :style => 'display: none')%>
|
47
|
+
<% unless !@task.track_done? || @task.track_times? || @task.work_started? || @task.finished_at -%>
|
52
48
|
<%=text_field 'work', 'hours', :tabindex => i+1, :id => "#{@task.id}_done",
|
53
49
|
:class => :task_hours, :maxlength => 4,
|
54
50
|
:ondblclick => "form.elements[1].style.display = 'inline';this.style.display = 'none'" -%>
|
@@ -74,12 +70,12 @@
|
|
74
70
|
<% end -%>
|
75
71
|
<% end -%>
|
76
72
|
</td>
|
77
|
-
<td align="right" nowrap="true"
|
73
|
+
<td align="right" nowrap="true">
|
78
74
|
<% form_tag({:controller => 'tasks', :action => 'update', :id => @task}) do %>
|
79
75
|
<% if @task.active? %>
|
80
76
|
<% if @task.loggable? %>
|
81
77
|
<% unless @task.work_started? %>
|
82
|
-
<%=image_link_to_remote('arrow_right.png', l(:move_to_next_period), {:action => :move_task_to_next_period, :id => @task}, nil, true)%>
|
78
|
+
<%=image_link_to_remote('arrow_right.png', l(:move_to_next_period), {:action => :move_task_to_next_period, :id => @task}, nil, true) if @task.backlog.enable_periods? || @task.period_id%>
|
83
79
|
<%=image_link_to_remote('ernes_stop.png', l(:abort), {:action => :abort_task, :id => @task}, nil, true)%>
|
84
80
|
<% end %>
|
85
81
|
<% end %>
|
data/db/schema.rb
CHANGED
@@ -2,7 +2,7 @@
|
|
2
2
|
# migrations feature of ActiveRecord to incrementally modify your database, and
|
3
3
|
# then regenerate this schema definition.
|
4
4
|
|
5
|
-
ActiveRecord::Schema.define(:version =>
|
5
|
+
ActiveRecord::Schema.define(:version => 24) do
|
6
6
|
|
7
7
|
create_table "backlogs", :force => true do |t|
|
8
8
|
t.column "name", :string, :limit => 64, :null => false
|
@@ -12,6 +12,7 @@ ActiveRecord::Schema.define(:version => 23) do
|
|
12
12
|
t.column "enable_users", :boolean
|
13
13
|
t.column "work_account_id", :integer
|
14
14
|
t.column "customer_id", :integer
|
15
|
+
t.column "enable_periods", :boolean
|
15
16
|
end
|
16
17
|
|
17
18
|
create_table "configurations", :force => true do |t|
|
data/lang/en.yaml
CHANGED
@@ -27,6 +27,7 @@ edit: Edit
|
|
27
27
|
editing: Editing
|
28
28
|
enable_customer: Enable customer
|
29
29
|
enable_invoicing: Enable invoicing
|
30
|
+
enable_periods: Enable Sprints
|
30
31
|
enable_subtasks: Enable Subtasks
|
31
32
|
enable_users: Enable users
|
32
33
|
end_on: End on
|
@@ -55,7 +56,8 @@ move_to_top: Move task to top of list
|
|
55
56
|
moved: Moved
|
56
57
|
name: Name
|
57
58
|
new_backlog: Start new backlog
|
58
|
-
|
59
|
+
new_customer: Add new customer
|
60
|
+
new_group: Form new group
|
59
61
|
new_period: Add new sprint
|
60
62
|
new_task: Add new task
|
61
63
|
new_work: Add new work record
|
@@ -104,6 +106,7 @@ tuesday: Tuesday
|
|
104
106
|
unplanned_tasks: Unplanned tasks
|
105
107
|
up: Up
|
106
108
|
user: User
|
109
|
+
view_fullscreen: View fullscreen
|
107
110
|
wednesday: Wednesday
|
108
111
|
week: Week
|
109
112
|
weekly_work_sheet: Weekly work sheet
|
data/lang/no.yaml
CHANGED
@@ -27,6 +27,7 @@ edit: Rediger
|
|
27
27
|
editing: Redigerer
|
28
28
|
enable_customer: Tillat kunder
|
29
29
|
enable_invoicing: Tillat fakturering
|
30
|
+
enable_periods: Tillat sprinter
|
30
31
|
enable_subtasks: Tillat underoppgaver
|
31
32
|
enable_users: Tillat brukere
|
32
33
|
end_on: Avslutt på
|
@@ -55,6 +56,7 @@ move_to_top: Flytt oppgaven til toppen av listen
|
|
55
56
|
moved: Flyttet
|
56
57
|
name: Navn
|
57
58
|
new_backlog: Start ny oppgaveliste
|
59
|
+
new_customer: Legg til ny kunde
|
58
60
|
new_group: Start ny gruppe
|
59
61
|
new_period: Start ny periode
|
60
62
|
new_task: Legg til ny oppgave
|
@@ -103,6 +105,7 @@ tuesday: Tirsdag
|
|
103
105
|
unplanned_tasks: Ikke planlagte oppgaver
|
104
106
|
up: Opp
|
105
107
|
user: Bruker
|
108
|
+
view_fullscreen: Vis fullskjerm
|
106
109
|
wednesday: Onsdag
|
107
110
|
week: Uke
|
108
111
|
weekly_work_sheet: Timeoversikt for uke
|
Binary file
|
data/test/fixtures/tasks.yml
CHANGED
@@ -5,14 +5,20 @@ require 'search_controller'
|
|
5
5
|
class SearchController; def rescue_action(e) raise e end; end
|
6
6
|
|
7
7
|
class SearchControllerTest < Test::Unit::TestCase
|
8
|
+
main_scenario
|
9
|
+
|
8
10
|
def setup
|
9
11
|
@controller = SearchController.new
|
10
12
|
@request = ActionController::TestRequest.new
|
11
13
|
@response = ActionController::TestResponse.new
|
14
|
+
@request.session[:user_id] = 1000001
|
12
15
|
end
|
13
16
|
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
+
def test_notes
|
18
|
+
post :results, :q => 'hullo'
|
19
|
+
assert_not_nil assigns(:backlogs)
|
20
|
+
assert_not_nil assigns(:tasks)
|
21
|
+
assert_equal 1, assigns(:tasks).size
|
22
|
+
assert_equal tasks(:first).id, assigns(:tasks).first.id
|
17
23
|
end
|
18
24
|
end
|
metadata
CHANGED
@@ -3,8 +3,8 @@ rubygems_version: 0.9.4
|
|
3
3
|
specification_version: 1
|
4
4
|
name: backlog
|
5
5
|
version: !ruby/object:Gem::Version
|
6
|
-
version: 0.
|
7
|
-
date: 2007-11-
|
6
|
+
version: 0.15.0
|
7
|
+
date: 2007-11-28 00:00:00 +01:00
|
8
8
|
summary: Application to aid collecting, processing, organizing, reviewing and doing tasks.
|
9
9
|
require_paths:
|
10
10
|
- lib
|
@@ -44,6 +44,7 @@ files:
|
|
44
44
|
- public/images/hammer.png
|
45
45
|
- public/images/arrow_right.svg
|
46
46
|
- public/images/arrow_down.png
|
47
|
+
- public/images/view_fullscreen.png
|
47
48
|
- public/images/eraser_org.png
|
48
49
|
- public/images/period.png
|
49
50
|
- public/images/rmagick.gif
|
@@ -146,6 +147,7 @@ files:
|
|
146
147
|
- db/migrate/022_remove_track_done_flag.rb
|
147
148
|
- db/migrate/005_add_field_work_started_at.rb
|
148
149
|
- db/migrate/006_works_data_fix.rb
|
150
|
+
- db/migrate/024_add_sprint_option.rb
|
149
151
|
- db/test.db
|
150
152
|
- db/schema.rb
|
151
153
|
- test
|
@@ -434,7 +436,6 @@ files:
|
|
434
436
|
- app/views/backlogs/_form.rhtml
|
435
437
|
- app/views/backlogs/new.rhtml
|
436
438
|
- app/views/backlogs/edit.rhtml
|
437
|
-
- app/views/backlogs/_tasks.rhtml
|
438
439
|
- app/views/backlogs/reopen_task.rjs
|
439
440
|
- app/views/estimates
|
440
441
|
- app/views/groups
|
@@ -466,6 +467,7 @@ files:
|
|
466
467
|
- app/views/tasks/edit.rhtml
|
467
468
|
- app/views/tasks/list_started.rhtml
|
468
469
|
- app/views/tasks/_task.rhtml
|
470
|
+
- app/views/tasks/notes.rhtml
|
469
471
|
- app/views/customers
|
470
472
|
- app/views/customers/list.rhtml
|
471
473
|
- app/views/customers/show.rhtml
|
@@ -1,33 +0,0 @@
|
|
1
|
-
<div class="mainblock">
|
2
|
-
<div class="btitle">
|
3
|
-
<%=render :partial => 'buttons'%>
|
4
|
-
<h4><%=l :tasks%></h4>
|
5
|
-
</div>
|
6
|
-
|
7
|
-
<div id="active_tasks"<%=' style="display: none;"' unless @tasks and not @tasks.empty?%>>
|
8
|
-
<%#=render :partial => '/tasks/backlog_header', :locals => {:backlog => @backlog, :track_times => tasks.find {|t|t.period && t.period.active?}} %>
|
9
|
-
<% i = 0 %>
|
10
|
-
<% for period in @tasks.map {|t| t.period}.uniq %>
|
11
|
-
<table id="active_tasks_<%=period ? period.id : 'unplanned' %>">
|
12
|
-
<%=render :partial => '/tasks/period_header', :locals => {:period => period} %>
|
13
|
-
<%=render :partial => '/tasks/fields_header', :locals => {:backlog => @backlog, :active => true, :track_times => tasks.find {|t|t.period && t.period.active?}} %>
|
14
|
-
<% for @task in @tasks.select {|t| t.period_id == (period && period.id)} %>
|
15
|
-
<%=render :partial => '/tasks/task/', :locals => {:task => @task, :i => i += 1, :active => true, :highlight_task => false, :update => :maincontent, :hidden => false} %>
|
16
|
-
<% end %>
|
17
|
-
</table>
|
18
|
-
<% end %>
|
19
|
-
</div>
|
20
|
-
|
21
|
-
<p id="no_tasks_message"<%=' style="display: none;"' if @tasks and not @tasks.empty?%>><%=l :no_pending_tasks_in_backlog%></p>
|
22
|
-
|
23
|
-
<%=back_or_link_to(l(:back)) %>
|
24
|
-
</div>
|
25
|
-
|
26
|
-
<div class="mainblock">
|
27
|
-
<div class="btitle">
|
28
|
-
<h4><%=l(:completed_tasks) %></h4>
|
29
|
-
</div>
|
30
|
-
|
31
|
-
<%=render :partial => '/tasks/completed', :locals => {:i => 1} %>
|
32
|
-
</div>
|
33
|
-
|