backlog 0.24.0 → 0.25.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 +16 -0
- data/History.txt~ +961 -0
- data/app/controllers/works_controller.rb +71 -30
- data/app/helpers/application_helper.rb +2 -1
- data/app/models/work.rb +1 -1
- data/app/views/tasks/_form.rhtml +1 -1
- data/app/views/user/edit.rhtml +6 -6
- data/app/views/works/_row.rhtml +17 -10
- data/app/views/works/_row_field.rhtml +2 -2
- data/app/views/works/_task_id_list.rhtml +5 -0
- data/app/views/works/daily_work_sheet.rhtml +39 -50
- data/app/views/works/update_new_row.rjs +27 -0
- data/app/views/works/update_row.rjs +10 -6
- data/lang/en.yaml +1 -0
- data/lang/no.yaml +1 -0
- data/test/functional/estimates_controller_test.rb +1 -1
- data/vendor/plugins/rails_time/lib/time_of_day.rb +8 -3
- metadata +6 -3
@@ -0,0 +1,27 @@
|
|
1
|
+
display_notice(page)
|
2
|
+
if @work && @work.errors.empty?
|
3
|
+
@updated_fields.each do |field_name|
|
4
|
+
if field_name.to_s =~ /(.*)_time$/
|
5
|
+
attribute_name = $1
|
6
|
+
value = @work[attribute_name]
|
7
|
+
if value.is_a? BigDecimal
|
8
|
+
value = '%d:%02d' % [value.to_i, (value.frac * 60).to_i]
|
9
|
+
else
|
10
|
+
value = value.strftime('%H:%M')
|
11
|
+
end
|
12
|
+
page["work_" + field_name.to_s].value = value
|
13
|
+
else
|
14
|
+
page["work_" + field_name.to_s].value = @work.send(field_name).to_s
|
15
|
+
end
|
16
|
+
end
|
17
|
+
#page.replace "work_#{@work.id}", :partial => 'row', :object => @work
|
18
|
+
#page["work_#{@work.id}_#{@next_field}"].select
|
19
|
+
#page["work_#{@work.id}_#{@next_field}"].focus
|
20
|
+
else
|
21
|
+
@work.errors.each do |error|
|
22
|
+
page["work_#{@work.id}_#{error[0]}"].addClassName('fieldWithErrors')
|
23
|
+
end
|
24
|
+
end
|
25
|
+
#if @day_total
|
26
|
+
# page.replace_html "hours_total", "#{'%d:%02d' % [@day_total.to_i, 60 * (@day_total % 1)]}"
|
27
|
+
#end
|
@@ -1,9 +1,13 @@
|
|
1
|
-
page
|
2
|
-
|
3
|
-
page.
|
1
|
+
display_notice(page)
|
2
|
+
if @work && @work.errors.empty?
|
3
|
+
page.replace "work_#{@work.id}", :partial => 'row', :object => @work
|
4
|
+
page["work_#{@work.id}_#{@next_field}"].select
|
5
|
+
page["work_#{@work.id}_#{@next_field}"].focus
|
6
|
+
else
|
7
|
+
@work.errors.each do |error|
|
8
|
+
page["work_#{@work.id}_#{error[0]}"].addClassName('fieldWithErrors')
|
9
|
+
end
|
10
|
+
end
|
4
11
|
if @day_total
|
5
12
|
page.replace_html "hours_total", "#{'%d:%02d' % [@day_total.to_i, 60 * (@day_total % 1)]}"
|
6
13
|
end
|
7
|
-
page["work_#{@work.id}_#{@next_field}"].select
|
8
|
-
page["work_#{@work.id}_#{@next_field}"].focus
|
9
|
-
|
data/lang/en.yaml
CHANGED
data/lang/no.yaml
CHANGED
@@ -21,7 +21,7 @@ class EstimatesControllerTest < Test::Unit::TestCase
|
|
21
21
|
assert_response :redirect
|
22
22
|
assert_redirected_to :controller => 'periods', :action => :show, :id => tasks(:first).period_id, :task_id => 1
|
23
23
|
|
24
|
-
assert_equal count_before +1 , Estimate.count
|
24
|
+
assert_equal count_before + 1 , Estimate.count
|
25
25
|
end
|
26
26
|
|
27
27
|
def test_create_get_is_redirected_to_root
|
@@ -35,7 +35,8 @@ class TimeOfDay
|
|
35
35
|
end
|
36
36
|
|
37
37
|
def ==(other)
|
38
|
-
|
38
|
+
return false unless other.is_a? TimeOfDay
|
39
|
+
(self <=> other) == 0
|
39
40
|
end
|
40
41
|
|
41
42
|
def <=>(other)
|
@@ -46,8 +47,12 @@ class TimeOfDay
|
|
46
47
|
on(Date.today).strftime(format)
|
47
48
|
end
|
48
49
|
|
49
|
-
def to_s
|
50
|
-
|
50
|
+
def to_s(with_seconds = true)
|
51
|
+
if with_seconds
|
52
|
+
"%02d:%02d:%02d" % [@hour, @minute, @second]
|
53
|
+
else
|
54
|
+
"%02d:%02d" % [@hour, @minute]
|
55
|
+
end
|
51
56
|
end
|
52
57
|
|
53
58
|
def self.yaml_new( klass, tag, val )
|
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: 0.
|
4
|
+
version: 0.25.0
|
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-
|
12
|
+
date: 2008-03-28 00:00:00 +01:00
|
13
13
|
default_executable:
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
@@ -64,7 +64,7 @@ dependencies:
|
|
64
64
|
requirements:
|
65
65
|
- - ">="
|
66
66
|
- !ruby/object:Gem::Version
|
67
|
-
version: 1.5.
|
67
|
+
version: 1.5.1
|
68
68
|
version:
|
69
69
|
description: Backlog is a tool to help you collect and organize all your tasks, whether you are a single person or a small or large group. A time keeping module is also included to track time spent on the different tasks.
|
70
70
|
email: uwe@kubosch.no
|
@@ -150,6 +150,7 @@ files:
|
|
150
150
|
- app/views/backlogs/_name_list.rhtml
|
151
151
|
- app/views/backlogs/show.rhtml
|
152
152
|
- app/views/works
|
153
|
+
- app/views/works/update_new_row.rjs
|
153
154
|
- app/views/works/new.rhtml
|
154
155
|
- app/views/works/update_time.rjs
|
155
156
|
- app/views/works/update_row.rjs
|
@@ -157,6 +158,7 @@ files:
|
|
157
158
|
- app/views/works/_row.rhtml
|
158
159
|
- app/views/works/list_excel.rhtml
|
159
160
|
- app/views/works/_buttons.rhtml
|
161
|
+
- app/views/works/_task_id_list.rhtml
|
160
162
|
- app/views/works/timeliste.rhtml
|
161
163
|
- app/views/works/_description_list.rhtml
|
162
164
|
- app/views/works/daily_work_sheet.rhtml
|
@@ -353,6 +355,7 @@ files:
|
|
353
355
|
- test/performance/server_test.rb
|
354
356
|
- test/performance/common.rb
|
355
357
|
- test/performance/jetty_test.rb
|
358
|
+
- History.txt~
|
356
359
|
- LICENSE_LOCALIZATION
|
357
360
|
- README_LOCALIZATION
|
358
361
|
- History.txt
|