auto-sync: 2026-05-19 22:58:07

This commit is contained in:
cfdaily
2026-05-19 22:58:07 +08:00
parent 6106e953eb
commit 1aea7a2d0e
+10
View File
@@ -208,6 +208,16 @@ export const api = {
}
},
taskStatusUpdate: async (taskId: string, newStatus: string): Promise<ActionResult> => {
try {
const pid = _currentProjectId || Object.keys((await api.projects()).projects)[0];
if (!pid) return { ok: false, error: 'No project' };
return postJ(`${API_BASE}/api/projects/${pid}/tasks/${taskId}/status`, { status: newStatus });
} catch (e: any) {
return { ok: false, error: e.message };
}
},
reviewAction: async (taskId: string, action: string, comment: string): Promise<ActionResult> => {
try {
const pid = _currentProjectId || Object.keys((await api.projects()).projects)[0];