Fixxes + Skriptketten

This commit is contained in:
2026-03-05 20:46:39 +00:00
parent 6836892907
commit afca677b1c
14 changed files with 1785 additions and 68 deletions

View File

@@ -607,6 +607,22 @@ class HistoryService {
}));
}
async getRunningEncodeJobs() {
const db = await getDb();
const rows = await db.all(
`
SELECT *
FROM jobs
WHERE status = 'ENCODING'
ORDER BY updated_at ASC, id ASC
`
);
return rows.map((job) => ({
...enrichJobRow(job),
log_count: hasProcessLogFile(job.id) ? 1 : 0
}));
}
async getJobWithLogs(jobId, options = {}) {
const db = await getDb();
const job = await db.get('SELECT * FROM jobs WHERE id = ?', [jobId]);