Add process restart feature via WebUI

Introduces backend and frontend support for restarting the worker process from the WebUI. Adds API endpoint, controller, and UI button for process management. Refactors napcat-shell to support master/worker process lifecycle and restart logic.
This commit is contained in:
手瓜一十雪
2026-01-17 14:42:07 +08:00
parent e52617c474
commit 15232f7365
10 changed files with 338 additions and 5 deletions

View File

@@ -0,0 +1,14 @@
import { serverRequest } from '@/utils/request';
export default class ProcessManager {
/**
* 重启进程
*/
public static async restartProcess () {
const data = await serverRequest.post<ServerResponse<{ message: string; }>>(
'/Process/Restart'
);
return data.data.data;
}
}