X-Git-Url: https://plomlompom.com/repos/foo.html?a=blobdiff_plain;f=plomtask%2Fconditions.py;h=45aa62b9b27a026c75549aea3350640c419d8a5e;hb=8c0cbef8f467d125ba7c987b3eb1f5bef7d38120;hp=337970924ab25305d64abef13afe24148b0209b1;hpb=23012cd370777b60a25839788d131173d2abee91;p=plomtask diff --git a/plomtask/conditions.py b/plomtask/conditions.py index 3379709..45aa62b 100644 --- a/plomtask/conditions.py +++ b/plomtask/conditions.py @@ -44,6 +44,8 @@ class Condition(BaseModel[int]): table_name = f'{item}_{attr}' for _ in db_conn.row_where(table_name, 'condition', self.id_): raise HandledException('cannot remove Condition in use') + db_conn.delete_where('condition_titles', 'parent', self.id_) + db_conn.delete_where('condition_descriptions', 'parent', self.id_) super().remove(db_conn)