+ def save_today(self):
+ if self.today_date in self.old_days.keys():
+ raise PlomException('cannot use same date twice')
+ for task_uuid, todo in [(task_uuid, todo) for task_uuid, todo in self.today.todos.items()
+ if not todo.weight]:
+ todo.weight = self.tasks[task_uuid].default_weight
+ self.old_days[self.today_date] = self.today
+