+
启动时间:{momnet(message.create_time).format('YYYY-MM-DD HH:mm:ss')}
-
+
执行时长:
{message.finish_time
? elapsedTime(new Date(message.create_time), new Date(message.finish_time))
: elapsedTime(new Date(message.create_time), new Date())}
-
+
状态:
+
-
+
+
);
}
diff --git a/react-ui/src/pages/Experiment/experimentText/editPipeline.less b/react-ui/src/pages/Experiment/experimentText/index.less
similarity index 93%
rename from react-ui/src/pages/Experiment/experimentText/editPipeline.less
rename to react-ui/src/pages/Experiment/experimentText/index.less
index f9e0e21b..d426b5b9 100644
--- a/react-ui/src/pages/Experiment/experimentText/editPipeline.less
+++ b/react-ui/src/pages/Experiment/experimentText/index.less
@@ -24,7 +24,7 @@
display: flex;
align-items: center;
width: 100%;
- height: 45px;
+ height: 56px;
padding: 0 30px;
background: #ffffff;
box-shadow: 0px 3px 6px rgba(146, 146, 146, 0.09);
@@ -43,6 +43,10 @@
color: rgba(29, 29, 32, 0.8);
font-size: 15px;
}
+.param_button {
+ margin-right: 0;
+ margin-left: auto;
+}
.resultTop {
display: flex;
align-items: center;
diff --git a/react-ui/src/pages/Experiment/experimentText/paramsModal.less b/react-ui/src/pages/Experiment/experimentText/paramsModal.less
new file mode 100644
index 00000000..e8b1e16e
--- /dev/null
+++ b/react-ui/src/pages/Experiment/experimentText/paramsModal.less
@@ -0,0 +1,30 @@
+.params_container {
+ max-height: 230px;
+ padding: 15px;
+ border: 1px solid #e6e6e6;
+ border-radius: 8px;
+
+ &_line {
+ display: flex;
+ align-items: center;
+ margin-bottom: 15px;
+
+ &_label {
+ width: 120px;
+ color: #1d1d20;
+ font-size: 15px;
+ }
+ &_value {
+ flex: 1;
+ width: 100px;
+ margin-left: 15px;
+ padding: 10px 20px;
+ color: #1d1d20;
+ font-size: 15px;
+ line-height: 20px;
+ background: #f6f6f6;
+ border: 1px solid #e0e0e1;
+ border-radius: 4px;
+ }
+ }
+}
diff --git a/react-ui/src/pages/Experiment/experimentText/paramsModal.tsx b/react-ui/src/pages/Experiment/experimentText/paramsModal.tsx
new file mode 100644
index 00000000..1a1cf41f
--- /dev/null
+++ b/react-ui/src/pages/Experiment/experimentText/paramsModal.tsx
@@ -0,0 +1,34 @@
+import parameterImg from '@/assets/img/modal-parameter.png';
+import KFModal from '@/components/KFModal';
+import { type PipelineGlobalParam } from '@/types';
+import styles from './paramsModal.less';
+
+type ParamsModalProps = {
+ open: boolean;
+ onCancel: () => void;
+ globalParam?: PipelineGlobalParam[];
+};
+
+function ParamsModal({ open, onCancel, globalParam = [] }: ParamsModalProps) {
+ return (
+
+
+ {globalParam.map((item) => (
+
+ {item.param_name}
+ {item.param_value}
+
+ ))}
+
+
+ );
+}
+
+export default ParamsModal;
diff --git a/react-ui/src/pages/Experiment/experimentText/props.jsx b/react-ui/src/pages/Experiment/experimentText/props.jsx
index 1a6c738b..a8fc72de 100644
--- a/react-ui/src/pages/Experiment/experimentText/props.jsx
+++ b/react-ui/src/pages/Experiment/experimentText/props.jsx
@@ -6,7 +6,7 @@ import { Drawer, Form, Input, Tabs, message } from 'antd';
import moment from 'moment';
import { forwardRef, useImperativeHandle, useState } from 'react';
import LogList from './LogList';
-import Styles from './editPipeline.less';
+import Styles from './index.less';
const { TextArea } = Input;
const Props = forwardRef(({ onParentChange }, ref) => {
const [form] = Form.useForm();
diff --git a/react-ui/src/pages/Pipeline/editPipeline/index.jsx b/react-ui/src/pages/Pipeline/editPipeline/index.jsx
index 1fae2fd5..094735cf 100644
--- a/react-ui/src/pages/Pipeline/editPipeline/index.jsx
+++ b/react-ui/src/pages/Pipeline/editPipeline/index.jsx
@@ -1,4 +1,5 @@
-import { useModal } from '@/hooks';
+import { ReactComponent as ParameterIcon } from '@/assets/svg/parameter.svg';
+import { useAntdModal } from '@/hooks';
import { getWorkflowById, saveWorkflow } from '@/services/pipeline/index.js';
import { to } from '@/utils/promise';
import { SaveOutlined } from '@ant-design/icons';
@@ -7,7 +8,6 @@ import G6 from '@antv/g6';
import { Button, message } from 'antd';
import { useEffect, useRef, useState } from 'react';
import { useNavigate, useParams } from 'react-router-dom';
-import { Icon } from 'umi';
import { s8 } from '../../../utils';
import Styles from './editPipeline.less';
import GlobalParamsDrawer from './globalParamsDrawer';
@@ -60,7 +60,7 @@ const EditPipeline = () => {
});
const graphRef = useRef();
const paramsDrawerRef = useRef();
- const [paramsDrawerVisible, openParamsDrawer, closeParamsDrawer] = useModal(false);
+ const [paramsDrawerOpen, openParamsDrawer, closeParamsDrawer] = useAntdModal(false);
const [globalParam, setGlobalParam] = useState([]);
const onDragEnd = (val) => {
@@ -704,7 +704,7 @@ const EditPipeline = () => {
}
+ icon={
}
style={{ marginRight: '20px' }}
onClick={openParamsDrawer}
>
@@ -735,7 +735,7 @@ const EditPipeline = () => {
diff --git a/react-ui/src/services/developmentEnvironment/index.js b/react-ui/src/services/developmentEnvironment/index.js
index e5e1d819..36203974 100644
--- a/react-ui/src/services/developmentEnvironment/index.js
+++ b/react-ui/src/services/developmentEnvironment/index.js
@@ -1,8 +1,16 @@
import { request } from '@umijs/max';
-// 查询流水线列表
+// 查询开发环境url
export function getJupyterUrl(params) {
return request(`/api/mmp/jupyter/getURL`, {
method: 'GET',
params,
});
}
+
+// 查询 labelStudio url
+export function getLabelStudioUrl(params) {
+ return request(`/api/mmp/labelStudio/getURL`, {
+ method: 'GET',
+ params,
+ });
+}
diff --git a/react-ui/src/styles/theme.less b/react-ui/src/styles/theme.less
index a4400afb..f9385817 100644
--- a/react-ui/src/styles/theme.less
+++ b/react-ui/src/styles/theme.less
@@ -1,8 +1,8 @@
// 全局颜色变量
-
-@primary-color: #1664ff; // 主色调
+// FIXME: 不能设置 @primary-color 不起作用,感觉是哪里被重置了
+@kf-primary-color: #1664ff; // 主色调
// 导出变量
:export {
- primaryColor: #1664ff; // FIXME: 设置为 @primary-color 不起作用,感觉是哪里被重置了
+ primaryColor: @kf-primary-color;
}
diff --git a/ruoyi-modules/management-platform/src/main/java/com/ruoyi/platform/utils/K8sClientUtil.java b/ruoyi-modules/management-platform/src/main/java/com/ruoyi/platform/utils/K8sClientUtil.java
index 9493b6ff..0f58f501 100644
--- a/ruoyi-modules/management-platform/src/main/java/com/ruoyi/platform/utils/K8sClientUtil.java
+++ b/ruoyi-modules/management-platform/src/main/java/com/ruoyi/platform/utils/K8sClientUtil.java
@@ -264,7 +264,7 @@ public class K8sClientUtil {
.withName(podName)
.withLabels(selector)
.endMetadata()
- .withNewSpec().withSchedulerName("0 */4 * * *")//默认不被操作4小时后删除
+ .withNewSpec() //默认不被操作4小时后删除
.addNewContainer()
.withName(podName)
.withImage(image)
@@ -274,7 +274,7 @@ public class K8sClientUtil {
.addNewVolume()
.withName("workspace").withPersistentVolumeClaim(new V1PersistentVolumeClaimVolumeSource().claimName(pvc.getMetadata().getName()))
.endVolume()
-// .withTerminationGracePeriodSeconds(14400L) //默认不被操作4小时后删除
+ .withTerminationGracePeriodSeconds(14400L) //默认不被操作4小时后删除
.endSpec()
.build();
@@ -334,7 +334,7 @@ public class K8sClientUtil {
.withName(podName)
.withLabels(selector)
.endMetadata()
- .withNewSpec().withSchedulerName("0 */1 * * *")//默认不被操作4小时后删除
+ .withNewSpec()
.addNewContainer()
.withName(podName)
.withImage(image)
@@ -344,7 +344,7 @@ public class K8sClientUtil {
.addNewVolume()
.withName("workspace").withPersistentVolumeClaim(new V1PersistentVolumeClaimVolumeSource().claimName(pvcName))
.endVolume()
-// .withTerminationGracePeriodSeconds(14400L)
+ .withTerminationGracePeriodSeconds(14400L)
.endSpec()
.build();