From 80cae93045027adf73e1385b1273fa8e1837d39e Mon Sep 17 00:00:00 2001 From: caishi <1149225589@qq.com> Date: Thu, 8 Apr 2021 17:44:31 +0800 Subject: [PATCH] =?UTF-8?q?ssh-=E5=88=9D=E6=AD=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/AppConfig.js | 2 +- src/forge/DevOps/OpsDetailRightpanel.jsx | 80 +++++++++++++----------- src/forge/DevOps/ops.scss | 12 ++++ src/forge/Main/CoderDepot.jsx | 1 + 4 files changed, 59 insertions(+), 36 deletions(-) diff --git a/src/AppConfig.js b/src/AppConfig.js index bd24bb7d..5f530ce9 100644 --- a/src/AppConfig.js +++ b/src/AppConfig.js @@ -32,7 +32,7 @@ export function initAxiosInterceptors(props) { // 判断网络是否连接 initOnlineOfflineListener(); - var proxy = "https://testforgeplus.trustie.net"; + var proxy = "https://forgeplus.trustie.net"; //响应前的设置 axios.interceptors.request.use( config => { diff --git a/src/forge/DevOps/OpsDetailRightpanel.jsx b/src/forge/DevOps/OpsDetailRightpanel.jsx index 1e0ed86a..6998964e 100644 --- a/src/forge/DevOps/OpsDetailRightpanel.jsx +++ b/src/forge/DevOps/OpsDetailRightpanel.jsx @@ -1,5 +1,5 @@ import React, { useState, useEffect } from "react"; -import { Spin } from "antd"; +import { Spin , Menu } from "antd"; import { FlexAJ, AlignCenter } from "../Component/layout"; import axios from "axios"; @@ -17,6 +17,8 @@ export default ({ const [spining, setSpining] = useState(true); const [stage, setStage] = useState(undefined); const [step, setStep] = useState(undefined); + const [nav, setNav] = useState("0"); + useEffect(() => { setSpining(rightSpin); }, [rightSpin]); @@ -66,42 +68,50 @@ export default ({ } return ( -
- {data && data.status !== "error" ? ( -
- - {step && step.name} - - {step && step.duration_time} - - - + {/* {setNav(e.key)}} selectedKeys={[nav]} mode="horizontal"> + 文件 + 命令行 + */} + { + nav === "0" && +
+ {data && data.status !== "error" ? (
- {coders && coders.length > 0 ? ( - coders.map((item, key) => { - return ( -
- {key + 1} -

{item.out}

-
- ); - }) - ) : empty ? ( -
- 1 -

- {stage && stage.name} – {step && step.name}: Skipped -

-
- ) : ( - "" - )} + + {step && step.name} + + {step && step.duration_time} + + + +
+ {coders && coders.length > 0 ? ( + coders.map((item, key) => { + return ( +
+ {key + 1} +

{item.out}

+
+ ); + }) + ) : empty ? ( +
+ 1 +

+ {stage && stage.name} – {step && step.name}: Skipped +

+
+ ) : ( + "" + )} +
-
- ) : ( -
error:{data && data.error}
- )} -
+ ) : ( +
error:{data && data.error}
+ )} +
+ } +
); }; diff --git a/src/forge/DevOps/ops.scss b/src/forge/DevOps/ops.scss index 538247f3..024d0aa6 100644 --- a/src/forge/DevOps/ops.scss +++ b/src/forge/DevOps/ops.scss @@ -194,6 +194,18 @@ &.rightSection{ width:100%; background-color: #081930; + .devopsNav{ + background-color: #111c24; + border-bottom: none; + .ant-menu-item{ + color: #ccc; + padding:0px; + margin:0px 20px!important; + } + .ant-menu-item.ant-menu-item-selected{ + color: #1890ff; + } + } .rightMainContent{ padding:24px 30px; height:100vh; diff --git a/src/forge/Main/CoderDepot.jsx b/src/forge/Main/CoderDepot.jsx index 634f9c8c..7d10e3e5 100644 --- a/src/forge/Main/CoderDepot.jsx +++ b/src/forge/Main/CoderDepot.jsx @@ -217,6 +217,7 @@ function CoderDepot(props){ ) + // 确认修改简介、website、实践课程链接 function okUpdate(d,w,l){ const url = `/${owner}/${projectsId}.json`; axios.put(url,{