feat(server): add RSS feed fetching functionality and enhance workflow management

- Introduced a new script for fetching RSS feeds, allowing workflows to process and transform feed data using JSONata.
- Updated workflow configuration to include a new RSS feed script, enhancing the capabilities of existing workflows.
- Enhanced the workflow management API to support enabling and disabling workflows dynamically.
- Improved UI components to reflect the new workflow features, including enabling/disabling workflows and displaying their statuses.
- Added support for wildcard filtering in workflow queries, improving the flexibility of workflow management.
This commit is contained in:
2026-08-14 22:52:33 +07:00
parent b8bbd56035
commit c5015bb391
15 changed files with 429 additions and 25 deletions
+13 -1
View File
@@ -190,7 +190,19 @@ export async function listRuns(filters = {}) {
const limit = Math.min(Math.max(filters.limit ?? 50, 1), 200);
let q = db("workflow_runs").select("*").orderBy("started_at", "desc");
if (filters.owner) q = q.where("owner", filters.owner);
if (filters.workflow) q = q.where("workflow", filters.workflow);
if (filters.workflow) {
const key = String(filters.workflow);
if (key.includes("*")) {
const pattern = key
.replaceAll("\\", "\\\\")
.replaceAll("%", "\\%")
.replaceAll("_", "\\_")
.replaceAll("*", "%");
q = q.whereRaw("workflow LIKE ? ESCAPE '\\'", [pattern]);
} else {
q = q.where("workflow", key);
}
}
if (filters.status) q = q.where("status", filters.status);
if (filters.before) q = q.where("started_at", "<", filters.before);
const rows = await q.limit(limit);