From 641b6f0fe4b0784d2af2e90bcc01b553eec70f83 Mon Sep 17 00:00:00 2001
From: caishi <1149225589@qq.com>
Date: Thu, 16 Mar 2023 17:08:42 +0800
Subject: [PATCH 1/6] =?UTF-8?q?code=E4=BB=A3=E7=A0=81=E8=A1=8C=E4=B8=8D?=
=?UTF-8?q?=E6=98=BE=E7=A4=BA=E8=A1=8C=E5=8F=B7?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/index.css | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/src/index.css b/src/index.css
index d94c4c6ff..1fff67d5c 100644
--- a/src/index.css
+++ b/src/index.css
@@ -99,9 +99,11 @@ li {
pre.prettyprint {
border: 0px solid transparent;
- padding: 10px 38px;
+ padding: 10px;
+}
+.markdown-body pre ol>li, .markdown-body pre ol>li{
+ list-style: none!important;
}
-
.-flex-basic0 {
flex-basis: 0% !important;
-webkit-flex-basis: 0% !important;
From bbfb4ea8bdafdc7d24e16fd57f0ea64c94c994e2 Mon Sep 17 00:00:00 2001
From: caishi <1149225589@qq.com>
Date: Thu, 16 Mar 2023 17:50:47 +0800
Subject: [PATCH 2/6] =?UTF-8?q?=E8=B4=A1=E7=8C=AE=E8=80=85=E6=B2=A1?=
=?UTF-8?q?=E6=9C=89id=E7=94=A8email?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/forge/Component/Contributors.jsx | 4 ++--
src/forge/Main/sub/Contribute.jsx | 2 +-
src/forge/claims/claim.scss | 8 +++-----
src/forge/claims/claims.js | 2 +-
4 files changed, 7 insertions(+), 9 deletions(-)
diff --git a/src/forge/Component/Contributors.jsx b/src/forge/Component/Contributors.jsx
index 294fdf03e..04ee3648b 100644
--- a/src/forge/Component/Contributors.jsx
+++ b/src/forge/Component/Contributors.jsx
@@ -175,9 +175,9 @@ function Contributors({owner,projectsId,currentLogin}){
list && list.length>0 && list.map((item,key)=>{
return(
-
+
setVisibleFunc(true,item.login,key)}/>
-
+
)
})
diff --git a/src/forge/Main/sub/Contribute.jsx b/src/forge/Main/sub/Contribute.jsx
index 1db9f7e5d..cc3f97438 100644
--- a/src/forge/Main/sub/Contribute.jsx
+++ b/src/forge/Main/sub/Contribute.jsx
@@ -63,7 +63,7 @@ function Contribute(props){
-
{item.name}
+
{item.name}
提交{item.contributions}次{item.contribution_perc ? ` I 贡献占比${item.contribution_perc}` : ''}
diff --git a/src/forge/claims/claim.scss b/src/forge/claims/claim.scss
index 2a0e5248e..d01d7a22d 100644
--- a/src/forge/claims/claim.scss
+++ b/src/forge/claims/claim.scss
@@ -57,15 +57,13 @@
padding-bottom: 10px;
word-break: break-all;
}
- .attrPerson{
- padding-top: 12px;
+ .claimattrPerson{
display: flex;
flex-wrap: wrap;
padding-bottom: 2px;
a{
- margin: 0px 2px 0px 0px;
- height: 22px;
- line-height: 20px;
+ margin: 12px 2px 0px 0px;
+ height: 30px;
img{
border-radius: 50%;
width: 30px;
diff --git a/src/forge/claims/claims.js b/src/forge/claims/claims.js
index 57a0c5e88..d480b1785 100644
--- a/src/forge/claims/claims.js
+++ b/src/forge/claims/claims.js
@@ -294,7 +294,7 @@ class claims extends React.Component {
{claimerData.length}
this.setVisibleFunc(false)}
>
{claimerData.map((item, key) => {
From f0e74326ace43c45a209646cc5caae979ad8ef49 Mon Sep 17 00:00:00 2001
From: caishi <1149225589@qq.com>
Date: Fri, 17 Mar 2023 10:46:14 +0800
Subject: [PATCH 3/6] file type is submodule , but submodule_git_url is null
---
src/forge/Main/CoderDepotCatalogue.jsx | 22 ++++++++++++++++------
1 file changed, 16 insertions(+), 6 deletions(-)
diff --git a/src/forge/Main/CoderDepotCatalogue.jsx b/src/forge/Main/CoderDepotCatalogue.jsx
index 375266ce0..c292ee733 100644
--- a/src/forge/Main/CoderDepotCatalogue.jsx
+++ b/src/forge/Main/CoderDepotCatalogue.jsx
@@ -29,12 +29,22 @@ function CoderDepotCatalogue({item , goToSubRoot , owner , projectsId , platform
{item.name}
:
(item.type === "submodule" ?
-
-
- {item.name}
-
- @{truncateCommitId(item.sha)}
-
+ (
+ item.submodule_git_url ?
+
+
+ {item.name}
+
+ @
+ {truncateCommitId(item.sha)}
+
+ :
+
+ {item.name}
+ @
+ {truncateCommitId(item.sha)}
+
+ )
:
goToSubRoot(item.path,item.type,item.name)}>
{item.name}
From 4aa09a5d862eff9281bfd74f34a452aeb6c06b64 Mon Sep 17 00:00:00 2001
From: caishi <1149225589@qq.com>
Date: Fri, 17 Mar 2023 13:49:52 +0800
Subject: [PATCH 4/6] =?UTF-8?q?issue=202616=20issue=E4=BF=9D=E5=AD=98?=
=?UTF-8?q?=E6=8F=90=E7=A4=BA=E9=99=84=E4=BB=B6id=E4=B8=8D=E5=AD=98?=
=?UTF-8?q?=E5=9C=A8?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/forge/Component/Contributors.jsx | 7 ++++++-
src/forge/Issues/Component/newPanel.jsx | 14 ++++++++------
2 files changed, 14 insertions(+), 7 deletions(-)
diff --git a/src/forge/Component/Contributors.jsx b/src/forge/Component/Contributors.jsx
index 04ee3648b..304d8a16e 100644
--- a/src/forge/Component/Contributors.jsx
+++ b/src/forge/Component/Contributors.jsx
@@ -174,11 +174,16 @@ function Contributors({owner,projectsId,currentLogin}){
{
list && list.length>0 && list.map((item,key)=>{
return(
+ item.id ?
-
+
setVisibleFunc(true,item.login,key)}/>
+ :
+
+
setVisibleFunc(true,item.login,key)}/>
+
)
})
}
diff --git a/src/forge/Issues/Component/newPanel.jsx b/src/forge/Issues/Component/newPanel.jsx
index 0094be5a0..56964aed4 100644
--- a/src/forge/Issues/Component/newPanel.jsx
+++ b/src/forge/Issues/Component/newPanel.jsx
@@ -1,4 +1,4 @@
-import React , { forwardRef , useState } from 'react';
+import React , { forwardRef , useState , useRef } from 'react';
import { Form , Input , Button } from 'antd';
import MDEditor from "../../../modules/tpm/challengesnew/tpm-md-editor";
import Upload from "../../Upload/Index";
@@ -7,7 +7,6 @@ import UploadImg from '../Img/UploadImg.png';
function NewPanel(props,ref){
const [ description , setDescription ] = useState("");
- const [ fileList , setFileList] = useState(undefined);
const [ attachments , setAttachments ] = useState([]);
const [ receivers_login , setReceiversLogin ] = useState(undefined);
@@ -15,6 +14,8 @@ function NewPanel(props,ref){
const { form: { getFieldDecorator, validateFields , setFieldsValue } } = props;
+ const fileList = useRef(undefined);
+
useState(()=>{
title && setTimeout(()=>{
setFieldsValue({subject:title});
@@ -33,16 +34,17 @@ function NewPanel(props,ref){
arr = files.map(i=>{return i.id});
}
list = arr && arr.length>0 ? f.concat(arr) : f ;
- setFileList(list);
+ fileList.current = list;
};
function deleteLoad(id){
let arr = [];
- let list = files
+ let list = files;
if(list && list.length>0 ){
arr = list.filter(i=>i.id !== id);
}
- setFileList(arr.map(i=>{return i.id}));
+ let idArr = arr.map(i=>{return i.id});
+ fileList.current = idArr;
}
function changeAtWhoLoginList(loginList){
@@ -54,7 +56,7 @@ function NewPanel(props,ref){
function sureFunc(){
validateFields((error,values)=>{
if (!error) {
- createFunc(values,fileList,receivers_login,description);
+ createFunc(values,fileList.current,receivers_login,description);
}
})
}
From 201ece7558f0a88024bb37ac62a4dee2a1e36d0b Mon Sep 17 00:00:00 2001
From: caishi <1149225589@qq.com>
Date: Fri, 17 Mar 2023 16:02:25 +0800
Subject: [PATCH 5/6] fault
---
src/forge/Issues/Component/newPanel.jsx | 14 +++++++-------
1 file changed, 7 insertions(+), 7 deletions(-)
diff --git a/src/forge/Issues/Component/newPanel.jsx b/src/forge/Issues/Component/newPanel.jsx
index 56964aed4..2b65b4687 100644
--- a/src/forge/Issues/Component/newPanel.jsx
+++ b/src/forge/Issues/Component/newPanel.jsx
@@ -1,4 +1,4 @@
-import React , { forwardRef , useState , useRef } from 'react';
+import React , { forwardRef , useState } from 'react';
import { Form , Input , Button } from 'antd';
import MDEditor from "../../../modules/tpm/challengesnew/tpm-md-editor";
import Upload from "../../Upload/Index";
@@ -7,6 +7,7 @@ import UploadImg from '../Img/UploadImg.png';
function NewPanel(props,ref){
const [ description , setDescription ] = useState("");
+ const [ fileList , setFileList] = useState(undefined);
const [ attachments , setAttachments ] = useState([]);
const [ receivers_login , setReceiversLogin ] = useState(undefined);
@@ -14,8 +15,6 @@ function NewPanel(props,ref){
const { form: { getFieldDecorator, validateFields , setFieldsValue } } = props;
- const fileList = useRef(undefined);
-
useState(()=>{
title && setTimeout(()=>{
setFieldsValue({subject:title});
@@ -34,7 +33,7 @@ function NewPanel(props,ref){
arr = files.map(i=>{return i.id});
}
list = arr && arr.length>0 ? f.concat(arr) : f ;
- fileList.current = list;
+ setFileList(list);
};
function deleteLoad(id){
@@ -43,8 +42,8 @@ function NewPanel(props,ref){
if(list && list.length>0 ){
arr = list.filter(i=>i.id !== id);
}
- let idArr = arr.map(i=>{return i.id});
- fileList.current = idArr;
+ console.log('删除后:',arr);
+ setFileList(arr.map(i=>{return i.id}));
}
function changeAtWhoLoginList(loginList){
@@ -56,7 +55,8 @@ function NewPanel(props,ref){
function sureFunc(){
validateFields((error,values)=>{
if (!error) {
- createFunc(values,fileList.current,receivers_login,description);
+ console.log('保存时:',fileList);
+ createFunc(values,fileList,receivers_login,description);
}
})
}
From caf1195d057152283f1e63b933f045dd1a8413c2 Mon Sep 17 00:00:00 2001
From: caishi <1149225589@qq.com>
Date: Fri, 17 Mar 2023 16:30:19 +0800
Subject: [PATCH 6/6] =?UTF-8?q?=E9=99=84=E4=BB=B6=E7=BB=84=E4=BB=B6-?=
=?UTF-8?q?=E5=88=A0=E9=99=A4=E5=88=9A=E4=B8=8A=E4=BC=A0=E7=9A=84=E6=96=87?=
=?UTF-8?q?=E4=BB=B6=EF=BC=8C=E6=B2=A1=E6=9C=89=E5=8F=8A=E6=97=B6=E6=9B=B4?=
=?UTF-8?q?=E6=96=B0?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/forge/Issues/Component/newPanel.jsx | 2 --
src/forge/Upload/Index.js | 3 ++-
2 files changed, 2 insertions(+), 3 deletions(-)
diff --git a/src/forge/Issues/Component/newPanel.jsx b/src/forge/Issues/Component/newPanel.jsx
index 2b65b4687..78298cd7c 100644
--- a/src/forge/Issues/Component/newPanel.jsx
+++ b/src/forge/Issues/Component/newPanel.jsx
@@ -42,7 +42,6 @@ function NewPanel(props,ref){
if(list && list.length>0 ){
arr = list.filter(i=>i.id !== id);
}
- console.log('删除后:',arr);
setFileList(arr.map(i=>{return i.id}));
}
@@ -55,7 +54,6 @@ function NewPanel(props,ref){
function sureFunc(){
validateFields((error,values)=>{
if (!error) {
- console.log('保存时:',fileList);
createFunc(values,fileList,receivers_login,description);
}
})
diff --git a/src/forge/Upload/Index.js b/src/forge/Upload/Index.js
index 616c90141..4c254405b 100644
--- a/src/forge/Upload/Index.js
+++ b/src/forge/Upload/Index.js
@@ -59,8 +59,9 @@ class Index extends Component {
return {
fileList: newFileList,
};
+ },()=>{
+ this.fileIdList(this.state.fileList);
});
- this.fileIdList(this.state.fileList);
} else {
this.props.showNotification(response.data.message)
}