feat: stabilize category rule operations

approve dcy-001 and add REQ/BAT evidence

pass selected DB path through Streamlit rule actions

expose delete_category_rule MCP tool

add category rule deletion regression
This commit is contained in:
Jarca
2026-06-27 00:02:06 +09:00
parent 97115f6acf
commit 0f881b245f
12 changed files with 459 additions and 5 deletions
+5
View File
@@ -154,6 +154,11 @@ def update_category_rule(rule_id: str, match_field: str, pattern: str, category:
"""Update an existing ledger transaction categorization rule."""
return service.update_category_rule(rule_id, match_field, pattern, category, subcategory, transaction_type, match_type, priority, person, is_fixed, confidence, memo, amount_min, amount_max, day_of_month, active)
@mcp.tool()
def delete_category_rule(rule_id: str) -> dict:
"""Delete a transaction categorization rule."""
return service.delete_category_rule(rule_id)
@mcp.tool()
def preview_categorization(limit: int = 1000, only_uncategorized: bool = True) -> dict:
"""Preview category-rule matches before writing categories to transactions."""