🔨 优化执行日志查看.

This commit is contained in:
lijiahang
2025-02-08 10:03:07 +08:00
parent a14b28de6a
commit a9ac9d0f79
8 changed files with 130 additions and 39 deletions

View File

@@ -6,7 +6,6 @@ import type {
ExecLogQueryRequest,
ExecLogQueryResponse,
ExecLogStatusResponse,
ExecLogTailRequest
} from './exec-log';
import axios from 'axios';
import qs from 'query-string';
@@ -25,6 +24,13 @@ export function getExecJobLog(id: number) {
return axios.get<ExecLogQueryResponse>('/asset/exec-job-log/get', { params: { id } });
}
/**
* 查询主机计划任务日志
*/
export function getExecJobHostLog(id: number) {
return axios.get<ExecHostLogQueryResponse>('/asset/exec-job-log/get-host', { params: { id } });
}
/**
* 查询主机计划任务日志
*/
@@ -91,8 +97,8 @@ export function clearExecJobLog(request: ExecLogClearRequest) {
/**
* 查看计划任务日志
*/
export function getExecJobLogTailToken(request: ExecLogTailRequest) {
return axios.post<string>('/asset/exec-job-log/tail', request);
export function getExecJobLogTailToken(id: number) {
return axios.get<string>('/asset/exec-job-log/tail', { params: { id } });
}
/**