backlog 0.12.1 → 0.12.2

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.
@@ -1,3 +1,18 @@
1
+ == 0.12.2 2007-11-08
2
+
3
+ ===Features
4
+
5
+ * Made "update start time for work" functions use ajax to speed up response.
6
+
7
+ === Fixes
8
+
9
+ * Removed obsolete and wrong validation of customer name size in Task.
10
+ This would give application error when trying to link a task to a customer.
11
+
12
+ === Known bugs
13
+
14
+ * Finishing or reopening tasks makes remaining tasks show wrong priority number.
15
+
1
16
  == 0.12.1 2007-11-07
2
17
 
3
18
  ===Features
@@ -92,9 +92,14 @@ class WorksController < ApplicationController
92
92
  @field = params[:field] || 'started_at_time'
93
93
  end
94
94
 
95
+ def update_time
96
+ update_work
97
+ flash.discard
98
+ @field = params[:field] || 'started_at_time'
99
+ end
100
+
95
101
  def update_work
96
102
  @work = Work.find(params[:id])
97
- work = @work
98
103
  convert_start_time_param
99
104
  convert_hours_param
100
105
  if @work.update_attributes(params[:work])
@@ -28,7 +28,6 @@ class Task < ActiveRecord::Base
28
28
  validates_presence_of :description, :if => :backlog_id
29
29
 
30
30
  validates_size_of :description, :maximum => 80, :if => :description
31
- validates_size_of :customer, :maximum => 64, :if => :customer
32
31
 
33
32
  #validates_uniqueness_of :description, :scope => :backlog_id, :if => Proc.new {|task| task.backlog_id && task.previous_task_id.nil?}
34
33
  validates_uniqueness_of :description, :scope => :period_id, :if => :period_id
@@ -24,13 +24,13 @@
24
24
  </td>
25
25
  <td align="right" nowrap="true" width="1">
26
26
  <% if active && @task.loggable? -%>
27
- <% form_tag({:controller => 'works', :action => 'update', :id => @task.started_work}) do %>
28
- <%= submit_tag('checkmark', :value => l(:save), :style => 'display: none')%>
27
+ <% remote_form_for(:work, :url => {:controller => 'works', :action => 'update_time', :id => @task.started_work}) do |f| %>
28
+ <%=submit_tag('checkmark', :value => l(:save), :style => 'display: none')%>
29
29
  <% if @task.work_started? -%>
30
- <%= text_field 'work', 'started_at_time', :tabindex => i+1, :value => @task.started_work.started_at.strftime('%H:%M'),
30
+ <%=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
31
  :class => :task_time, :maxlength => 5, :onkeypress => "handleEvent(this, event, #{@task.id})" %>
32
32
  <% elsif @task.track_times? && @task.period && @task.period.active? %>
33
- <%= image_link_to_remote 'hammer.png', l(:start_work), {:controller => 'tasks', :action => :start_work, :id => @task.id}, nil, true %>
33
+ <%=image_link_to_remote 'hammer.png', l(:start_work), {:controller => 'tasks', :action => :start_work, :id => @task.id}, nil, true %>
34
34
  <% end -%>
35
35
  <% end %>
36
36
  <% end -%>
@@ -0,0 +1,2 @@
1
+ page["work_#{@work.id}_started_at_time"].value = @work.started_at.strftime('%H:%M')
2
+ page.replace "notice", :partial => '/layouts/notice'
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.12.1
7
- date: 2007-11-08 00:00:00 +01:00
6
+ version: 0.12.2
7
+ date: 2007-11-09 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
@@ -490,6 +490,7 @@ files:
490
490
  - app/views/works/new.rhtml
491
491
  - app/views/works/_row_field.rhtml
492
492
  - app/views/works/edit.rhtml
493
+ - app/views/works/update_time.rjs
493
494
  - app/views/works/daily_work_sheet.rhtml
494
495
  - app/views/works/weekly_work_sheet.rhtml
495
496
  - app/views/works/timeliste.rhtml