1
0
mirror of https://github.com/simon987/task_tracker_drone.git synced 2025-04-16 08:56:45 +00:00

json recipe helper method

This commit is contained in:
simon987 2019-03-24 16:20:45 -04:00
parent 626e3a203e
commit ef07c059ad

@ -53,6 +53,9 @@ class Task:
self.assign_time: int = json_obj["assign_time"]
self.verification_count: int = json_obj["verification_count"]
def json_recipe(self) -> dict:
return json.loads(self.recipe)
def toJSON(self):
return json.dumps({
"id": self.id, "priority": self.priority,