backlog 0.34 → 0.34.1
Sign up to get free protection for your applications and to get access to all the features.
- data/History.txt +13 -1
- data/app/controllers/backlogs_controller.rb +3 -1
- data/app/models/task.rb +1 -1
- data/app/models/work.rb +5 -0
- data/test/functional/absences_controller_test.rb +1 -1
- data/uwe@celina +0 -0
- metadata +3 -2
data/History.txt
CHANGED
@@ -1,4 +1,16 @@
|
|
1
|
-
== 0.34 2008-
|
1
|
+
== 0.34.1 2008-09-22
|
2
|
+
|
3
|
+
=== Fixes
|
4
|
+
|
5
|
+
* Fixed bug in Backlog => Works view. Now search and filtering work fine.
|
6
|
+
* Fixed bug in "Started Tasks": Tasks with work records without start time would be wrongly identified as started.
|
7
|
+
* Set "invoice" for a work record to true as default.
|
8
|
+
|
9
|
+
=== Internal
|
10
|
+
|
11
|
+
* Fixed failing test for Absence records.
|
12
|
+
|
13
|
+
== 0.34 2008-09-09
|
2
14
|
|
3
15
|
== Features
|
4
16
|
|
@@ -176,9 +176,11 @@ class BacklogsController < ApplicationController
|
|
176
176
|
|
177
177
|
def works
|
178
178
|
backlog = Backlog.find(params[:id])
|
179
|
-
@report_filter =
|
179
|
+
@report_filter = WorksReportFilter.new(params[:report_filter])
|
180
180
|
@report_filter.title = "#{l :hours} for #{backlog.name} #{@report_filter.start_on && @report_filter.start_on.strftime('%Y-%m-%d - ')}#{@report_filter.end_on && @report_filter.end_on.strftime('%Y-%m-%d')}"
|
181
181
|
@works = Work.paginate :conditions => ["completed_at BETWEEN ? AND ? AND task_id IN (SELECT id FROM tasks t where t.backlog_id = ?)", @report_filter.start_on, @report_filter.end_on, backlog.id], :page => params[:page], :per_page => @report_filter.page_size
|
182
|
+
@work_accounts = WorkAccount.find(:all)
|
183
|
+
@users = User.find(:all)
|
182
184
|
if params[:export] == 'excel'
|
183
185
|
render :template => '/works/list_excel', :layout => false
|
184
186
|
else
|
data/app/models/task.rb
CHANGED
@@ -60,7 +60,7 @@ class Task < ActiveRecord::Base
|
|
60
60
|
if current_user
|
61
61
|
user_clause = " OR user_id = #{current_user.id}"
|
62
62
|
end
|
63
|
-
conditions = "completed_at IS NULL AND (user_id IS NULL#{user_clause})"
|
63
|
+
conditions = "start_time IS NOT NULL AND completed_at IS NULL AND (user_id IS NULL#{user_clause})"
|
64
64
|
Work.find(:all, :conditions => conditions).map {|work| work.task}.compact.sort_by do |t|
|
65
65
|
[t.root_task.backlog.name, t.root_task.period ? t.root_task.period.end_on : 0, t.position || 0]
|
66
66
|
end
|
data/app/models/work.rb
CHANGED
@@ -12,6 +12,11 @@ class Work < ActiveRecord::Base
|
|
12
12
|
validates_presence_of :started_on
|
13
13
|
validates_presence_of :start_time, :if => :track_times?
|
14
14
|
|
15
|
+
def initialize(*args)
|
16
|
+
super
|
17
|
+
self.invoice = true
|
18
|
+
end
|
19
|
+
|
15
20
|
def validate
|
16
21
|
errors.add(:work, "Work account is missing") unless work_account
|
17
22
|
if completed_at
|
data/uwe@celina
ADDED
Binary file
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: backlog
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version:
|
4
|
+
version: 0.34.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Uwe Kubosch
|
@@ -9,7 +9,7 @@ autorequire:
|
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
11
|
|
12
|
-
date: 2008-09-
|
12
|
+
date: 2008-09-22 00:00:00 +02:00
|
13
13
|
default_executable:
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
@@ -747,6 +747,7 @@ files:
|
|
747
747
|
- db/migrate/017_insert_datek_projects.rb
|
748
748
|
- db/migrate/006_works_data_fix.rb
|
749
749
|
- db/schema.rb
|
750
|
+
- uwe@celina
|
750
751
|
- README.txt
|
751
752
|
has_rdoc: true
|
752
753
|
homepage: http://rubyforge.org/projects/backlog/
|