openall_time_applet 0.0.19 → 0.0.20

Sign up to get free protection for your applications and to get access to all the features.
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.0.19
1
+ 0.0.20
@@ -138,7 +138,7 @@ class Openall_time_applet::Gui::Win_sync_overview
138
138
  return nil if @dont_reload or @gui["tvTimelogs"].destroyed?
139
139
  @gui["tvTimelogs"].model.clear
140
140
  @timelogs_count = 0
141
- @args[:oata].ob.list(:Timelog, {"sync_need" => 1, "task_id_not" => 0, "orderby" => "timestamp"}) do |timelog|
141
+ @args[:oata].ob.list(:Timelog, {"sync_need" => 1, "task_id_not" => 0, "task_id_not" => "", "orderby" => "timestamp"}) do |timelog|
142
142
  #Read time and transport from timelog.
143
143
  time = timelog[:time].to_i
144
144
  transport = timelog[:time_transport].to_i
@@ -322,7 +322,11 @@ class Openall_time_applet
322
322
  begin
323
323
  sw.label = _("Pushing time-updates.")
324
324
  self.push_time_updates
325
- sw.percent = 0.5
325
+ sw.percent = 0.3
326
+
327
+ sw.label = _("Update task-cache.")
328
+ self.update_task_cache
329
+ sw.percent = 0.66
326
330
 
327
331
  sw.label = _("Updating worktime-cache.")
328
332
  self.update_worktime_cache
data/models/timelog.rb CHANGED
@@ -30,7 +30,7 @@ class Openall_time_applet::Models::Timelog < Knj::Datarow
30
30
  #Go through timelogs that needs syncing and has a task set.
31
31
  self.ob.list(:Timelog, {"sync_need" => 1, "task_id_not" => 0}) do |timelog|
32
32
  secs_sum = timelog[:time_sync].to_i + timelog[:time_transport].to_i
33
- next if secs_sum <= 0
33
+ next if secs_sum <= 0 or !timelog.task
34
34
 
35
35
  #The timelog has not yet been created in OpenAll - create it!
36
36
  res = conn.request(
@@ -5,7 +5,7 @@
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = %q{openall_time_applet}
8
- s.version = "0.0.19"
8
+ s.version = "0.0.20"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["Kasper Johansen"]
metadata CHANGED
@@ -2,7 +2,7 @@
2
2
  name: openall_time_applet
3
3
  version: !ruby/object:Gem::Version
4
4
  prerelease:
5
- version: 0.0.19
5
+ version: 0.0.20
6
6
  platform: ruby
7
7
  authors:
8
8
  - Kasper Johansen
@@ -198,7 +198,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
198
198
  requirements:
199
199
  - - ">="
200
200
  - !ruby/object:Gem::Version
201
- hash: 4278837870597211102
201
+ hash: 3414771373569062324
202
202
  segments:
203
203
  - 0
204
204
  version: "0"