From: Christian Heller Date: Mon, 29 Apr 2024 03:09:41 +0000 (+0200) Subject: Enable Condition.is_active toggling in Condition view. X-Git-Url: https://plomlompom.com/repos/test.html?a=commitdiff_plain;h=fb317a554ed912736498a5b3917b40bb9bfd7489;p=plomtask Enable Condition.is_active toggling in Condition view. --- diff --git a/plomtask/http.py b/plomtask/http.py index 316fd08..196540a 100644 --- a/plomtask/http.py +++ b/plomtask/http.py @@ -287,6 +287,7 @@ class TaskHandler(BaseHTTPRequestHandler): condition.remove(self.conn) return '/conditions' condition = Condition.by_id(self.conn, id_, create=True) + condition.is_active = self.form_data.get_all_str('is_active') != [] condition.title.set(self.form_data.get_str('title')) condition.description.set(self.form_data.get_str('description')) condition.save(self.conn) diff --git a/templates/condition.html b/templates/condition.html index a0a9f45..92f04eb 100644 --- a/templates/condition.html +++ b/templates/condition.html @@ -5,6 +5,7 @@
title: description: +is active: