]> git.madduck.net Git - etc/taskwarrior.git/commitdiff

madduck's git repository

Every one of the projects in this repository is available at the canonical URL git://git.madduck.net/madduck/pub/<projectpath> — see each project's metadata for the exact URL.

All patches and comments are welcome. Please squash your changes to logical commits before using git-format-patch and git-send-email to patches@git.madduck.net. If you'd read over the Git project's submission guidelines and adhered to them, I'd be especially grateful.

SSH access, as well as push access can be individually arranged.

If you use my repositories frequently, consider adding the following snippet to ~/.gitconfig and using the third clone URL listed for each project:

[url "git://git.madduck.net/madduck/"]
  insteadOf = madduck:

Task: Refresh all relevant attributes in done,start and delete methods
authorTomas Babej <tomasbabej@gmail.com>
Fri, 20 Feb 2015 16:52:30 +0000 (17:52 +0100)
committerTomas Babej <tomasbabej@gmail.com>
Fri, 20 Feb 2015 17:19:10 +0000 (18:19 +0100)
tasklib/task.py

index dc83e9706eaa875c1d13ac3350fe5c18e9677982..5c05baea3d3fd199bd7c359c4dc10ab1e774f271 100644 (file)
@@ -532,7 +532,7 @@ class Task(TaskResource):
         self.warrior.execute_command([self['uuid'], 'delete'])
 
         # Refresh the status again, so that we have updated info stored
         self.warrior.execute_command([self['uuid'], 'delete'])
 
         # Refresh the status again, so that we have updated info stored
-        self.refresh(only_fields=['status'])
+        self.refresh(only_fields=['status', 'start', 'end'])
 
     def start(self):
         if not self.saved:
 
     def start(self):
         if not self.saved:
@@ -549,7 +549,7 @@ class Task(TaskResource):
         self.warrior.execute_command([self['uuid'], 'start'])
 
         # Refresh the status again, so that we have updated info stored
         self.warrior.execute_command([self['uuid'], 'start'])
 
         # Refresh the status again, so that we have updated info stored
-        self.refresh(only_fields=['status'])
+        self.refresh(only_fields=['status', 'start'])
 
     def done(self):
         if not self.saved:
 
     def done(self):
         if not self.saved:
@@ -566,7 +566,7 @@ class Task(TaskResource):
         self.warrior.execute_command([self['uuid'], 'done'])
 
         # Refresh the status again, so that we have updated info stored
         self.warrior.execute_command([self['uuid'], 'done'])
 
         # Refresh the status again, so that we have updated info stored
-        self.refresh(only_fields=['status'])
+        self.refresh(only_fields=['status', 'start', 'end'])
 
     def save(self):
         if self.saved and not self.modified:
 
     def save(self):
         if self.saved and not self.modified: