mirror of
https://github.com/whyour/qinglong.git
synced 2026-08-13 20:30:48 +08:00
ck管理增加排序,禁用,实时状态变成手动获取
This commit is contained in:
@@ -3,6 +3,12 @@ import { Modal, notification, Input, Form } from 'antd';
|
||||
import { request } from '@/utils/http';
|
||||
import config from '@/utils/config';
|
||||
|
||||
enum CrontabStatus {
|
||||
'running',
|
||||
'idle',
|
||||
'disabled',
|
||||
}
|
||||
|
||||
const CronLogModal = ({
|
||||
cron,
|
||||
handleCancel,
|
||||
@@ -12,14 +18,14 @@ const CronLogModal = ({
|
||||
visible: boolean;
|
||||
handleCancel: () => void;
|
||||
}) => {
|
||||
const [value, setValue] = useState<string>('运行中...');
|
||||
const [value, setValue] = useState<string>('启动中...');
|
||||
const [logTimer, setLogTimer] = useState<any>();
|
||||
|
||||
const getCronLog = () => {
|
||||
request
|
||||
.get(`${config.apiPrefix}crons/${cron._id}/log`)
|
||||
.then((data: any) => {
|
||||
setValue(data.data);
|
||||
setValue(data.data || '暂无日志');
|
||||
});
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user