From 3ca1ce6c1bed98613b46c5e633dc47c561f56e72 Mon Sep 17 00:00:00 2001
From: caishi <1149225589@qq.com>
Date: Thu, 6 May 2021 10:14:06 +0800
Subject: [PATCH] merge
---
src/forge/Main/CoderDepot.jsx | 28 ++++++++++++++++++----------
1 file changed, 18 insertions(+), 10 deletions(-)
diff --git a/src/forge/Main/CoderDepot.jsx b/src/forge/Main/CoderDepot.jsx
index 5a2f6438..9fa5603d 100644
--- a/src/forge/Main/CoderDepot.jsx
+++ b/src/forge/Main/CoderDepot.jsx
@@ -20,7 +20,9 @@ import DrawerPanel from '../Component/DrawerPanel';
import UpdateDescModal from './sub/UpdateDescModal';
import Nodata from '../Nodata';
-
+/**
+ * projectDetail.type:0是托管项目,1是镜像项目,2是同步镜像项目(为2时不支持在线创建、在线上传、在线修改、在线删除、创建合并请求等功能)
+ */
function CoderDepot(props){
const [ projectDetail , setProjectDetail ]= useState(undefined);
const [ treeValue , setTreeValue ] = useState(undefined);
@@ -93,7 +95,7 @@ function CoderDepot(props){
setZip_url(result.data.zip_url);
let c = result.data.last_commit
setLastCommit(c && c.commit);
- setLastCommitAuthor(c && (c.author || (c.commit && c.commit.author)));
+ setLastCommitAuthor(c && c.committer);
setMainFlag(true);
setReadOnly(true);
}
@@ -135,7 +137,7 @@ function CoderDepot(props){
}
let c = result.data.last_commit
setLastCommit(c && c.commit);
- setLastCommitAuthor(c && (c.author || (c.commit && c.commit.author)));
+ setLastCommitAuthor(c && c.committer);
setMainFlag(false);
setReadOnly(true);
}
@@ -217,6 +219,7 @@ function CoderDepot(props){
)
+ // 确认修改简介、website、实践课程链接
function okUpdate(d,w,l){
const url = `/${owner}/${projectsId}.json`;
axios.put(url,{
@@ -295,15 +298,19 @@ function CoderDepot(props){
{lastCommit && lastCommit.message}
{lastCommit && lastCommit.message}