合并蔡世代码并解决冲突
This commit is contained in:
commit
03d568f5f7
|
@ -1,8 +1,8 @@
|
||||||
@font-face {
|
@font-face {
|
||||||
font-family: "iconfont"; /* Project id 2340181 */
|
font-family: "iconfont"; /* Project id 2340181 */
|
||||||
src: url('iconfont.woff2?t=1628841816999') format('woff2'),
|
src: url('iconfont.woff2?t=1630465334247') format('woff2'),
|
||||||
url('iconfont.woff?t=1628841816999') format('woff'),
|
url('iconfont.woff?t=1630465334247') format('woff'),
|
||||||
url('iconfont.ttf?t=1628841816999') format('truetype');
|
url('iconfont.ttf?t=1630465334247') format('truetype');
|
||||||
}
|
}
|
||||||
|
|
||||||
.iconfont {
|
.iconfont {
|
||||||
|
@ -13,6 +13,90 @@
|
||||||
-moz-osx-font-smoothing: grayscale;
|
-moz-osx-font-smoothing: grayscale;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.icon-gerenziliao:before {
|
||||||
|
content: "\e8c4";
|
||||||
|
}
|
||||||
|
|
||||||
|
.icon-xinshouzhiyin:before {
|
||||||
|
content: "\e8e4";
|
||||||
|
}
|
||||||
|
|
||||||
|
.icon-xinjianxiangmu:before {
|
||||||
|
content: "\e8e6";
|
||||||
|
}
|
||||||
|
|
||||||
|
.icon-jiaruketang1:before {
|
||||||
|
content: "\e8e9";
|
||||||
|
}
|
||||||
|
|
||||||
|
.icon-xiangmugonggao:before {
|
||||||
|
content: "\e8c2";
|
||||||
|
}
|
||||||
|
|
||||||
|
.icon-chengguo:before {
|
||||||
|
content: "\e8c3";
|
||||||
|
}
|
||||||
|
|
||||||
|
.icon-chengjiaogonggao:before {
|
||||||
|
content: "\e8c0";
|
||||||
|
}
|
||||||
|
|
||||||
|
.icon-jishuzichan:before {
|
||||||
|
content: "\e8c1";
|
||||||
|
}
|
||||||
|
|
||||||
|
.icon-feibiaogonggao:before {
|
||||||
|
content: "\e8bc";
|
||||||
|
}
|
||||||
|
|
||||||
|
.icon-zhongbiaogonggao:before {
|
||||||
|
content: "\e8bd";
|
||||||
|
}
|
||||||
|
|
||||||
|
.icon-gengzhenggonggao:before {
|
||||||
|
content: "\e8be";
|
||||||
|
}
|
||||||
|
|
||||||
|
.icon-zhaobiaogonggao:before {
|
||||||
|
content: "\e8bf";
|
||||||
|
}
|
||||||
|
|
||||||
|
.icon-wenjian6:before {
|
||||||
|
content: "\e8ba";
|
||||||
|
}
|
||||||
|
|
||||||
|
.icon-wenjianjia4:before {
|
||||||
|
content: "\e8bb";
|
||||||
|
}
|
||||||
|
|
||||||
|
.icon-quxiaoguanzhu:before {
|
||||||
|
content: "\e89a";
|
||||||
|
}
|
||||||
|
|
||||||
|
.icon-dianzan_icon:before {
|
||||||
|
content: "\e8a2";
|
||||||
|
}
|
||||||
|
|
||||||
|
.icon-wenjian5:before {
|
||||||
|
content: "\e896";
|
||||||
|
}
|
||||||
|
|
||||||
|
.icon-wenjianjia3:before {
|
||||||
|
content: "\e8a9";
|
||||||
|
}
|
||||||
|
|
||||||
|
.icon-fuzhiicon:before {
|
||||||
|
content: "\e886";
|
||||||
|
}
|
||||||
|
|
||||||
|
.icon-zhuye-fill:before {
|
||||||
|
content: "\e876";
|
||||||
|
}
|
||||||
|
|
||||||
|
.icon-daimakuicon:before {
|
||||||
|
content: "\e884";
|
||||||
|
}
|
||||||
|
|
||||||
.icon-xinjian2:before {
|
.icon-xinjian2:before {
|
||||||
content: "\e8b0";
|
content: "\e8b0";
|
||||||
}
|
}
|
||||||
|
@ -29,22 +113,6 @@
|
||||||
content: "\e8a6";
|
content: "\e8a6";
|
||||||
}
|
}
|
||||||
|
|
||||||
.icon-dianzan_icon:before {
|
|
||||||
content: "\e8ba";
|
|
||||||
}
|
|
||||||
|
|
||||||
.icon-quxiaoguanzhu:before {
|
|
||||||
content: "\e8bb";
|
|
||||||
}
|
|
||||||
|
|
||||||
.icon-daimakuicon:before {
|
|
||||||
content: "\e8a9";
|
|
||||||
}
|
|
||||||
|
|
||||||
.icon-zhuyeicon:before {
|
|
||||||
content: "\e884";
|
|
||||||
}
|
|
||||||
|
|
||||||
.icon-biaoqianicon:before {
|
.icon-biaoqianicon:before {
|
||||||
content: "\e882";
|
content: "\e882";
|
||||||
}
|
}
|
||||||
|
@ -57,10 +125,6 @@
|
||||||
content: "\e885";
|
content: "\e885";
|
||||||
}
|
}
|
||||||
|
|
||||||
.icon-fuzhiicon:before {
|
|
||||||
content: "\e886";
|
|
||||||
}
|
|
||||||
|
|
||||||
.icon-lianjieicon:before {
|
.icon-lianjieicon:before {
|
||||||
content: "\e887";
|
content: "\e887";
|
||||||
}
|
}
|
||||||
|
@ -93,10 +157,6 @@
|
||||||
content: "\e899";
|
content: "\e899";
|
||||||
}
|
}
|
||||||
|
|
||||||
.icon-wenjian5:before {
|
|
||||||
content: "\e89a";
|
|
||||||
}
|
|
||||||
|
|
||||||
.icon-tijiaoicon:before {
|
.icon-tijiaoicon:before {
|
||||||
content: "\e89e";
|
content: "\e89e";
|
||||||
}
|
}
|
||||||
|
@ -105,10 +165,6 @@
|
||||||
content: "\e89f";
|
content: "\e89f";
|
||||||
}
|
}
|
||||||
|
|
||||||
.icon-wenjianjia3:before {
|
|
||||||
content: "\e8a2";
|
|
||||||
}
|
|
||||||
|
|
||||||
.icon-xialaanniu1:before {
|
.icon-xialaanniu1:before {
|
||||||
content: "\e8a4";
|
content: "\e8a4";
|
||||||
}
|
}
|
||||||
|
@ -241,10 +297,6 @@
|
||||||
content: "\e875";
|
content: "\e875";
|
||||||
}
|
}
|
||||||
|
|
||||||
.icon-fuzhi_icon:before {
|
|
||||||
content: "\e876";
|
|
||||||
}
|
|
||||||
|
|
||||||
.icon-shanchuicon:before {
|
.icon-shanchuicon:before {
|
||||||
content: "\e877";
|
content: "\e877";
|
||||||
}
|
}
|
||||||
|
|
File diff suppressed because one or more lines are too long
|
@ -5,6 +5,153 @@
|
||||||
"css_prefix_text": "icon-",
|
"css_prefix_text": "icon-",
|
||||||
"description": "",
|
"description": "",
|
||||||
"glyphs": [
|
"glyphs": [
|
||||||
|
{
|
||||||
|
"icon_id": "24014152",
|
||||||
|
"name": "个人资料",
|
||||||
|
"font_class": "gerenziliao",
|
||||||
|
"unicode": "e8c4",
|
||||||
|
"unicode_decimal": 59588
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"icon_id": "23655968",
|
||||||
|
"name": "新手指引",
|
||||||
|
"font_class": "xinshouzhiyin",
|
||||||
|
"unicode": "e8e4",
|
||||||
|
"unicode_decimal": 59620
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"icon_id": "23655969",
|
||||||
|
"name": "新建项目",
|
||||||
|
"font_class": "xinjianxiangmu",
|
||||||
|
"unicode": "e8e6",
|
||||||
|
"unicode_decimal": 59622
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"icon_id": "23658111",
|
||||||
|
"name": "加入课堂",
|
||||||
|
"font_class": "jiaruketang1",
|
||||||
|
"unicode": "e8e9",
|
||||||
|
"unicode_decimal": 59625
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"icon_id": "23791639",
|
||||||
|
"name": "项目公告",
|
||||||
|
"font_class": "xiangmugonggao",
|
||||||
|
"unicode": "e8c2",
|
||||||
|
"unicode_decimal": 59586
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"icon_id": "23791640",
|
||||||
|
"name": "成果",
|
||||||
|
"font_class": "chengguo",
|
||||||
|
"unicode": "e8c3",
|
||||||
|
"unicode_decimal": 59587
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"icon_id": "23791410",
|
||||||
|
"name": "成交公告",
|
||||||
|
"font_class": "chengjiaogonggao",
|
||||||
|
"unicode": "e8c0",
|
||||||
|
"unicode_decimal": 59584
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"icon_id": "23791411",
|
||||||
|
"name": "技术资产",
|
||||||
|
"font_class": "jishuzichan",
|
||||||
|
"unicode": "e8c1",
|
||||||
|
"unicode_decimal": 59585
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"icon_id": "23790928",
|
||||||
|
"name": "废标公告",
|
||||||
|
"font_class": "feibiaogonggao",
|
||||||
|
"unicode": "e8bc",
|
||||||
|
"unicode_decimal": 59580
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"icon_id": "23790929",
|
||||||
|
"name": "中标公告",
|
||||||
|
"font_class": "zhongbiaogonggao",
|
||||||
|
"unicode": "e8bd",
|
||||||
|
"unicode_decimal": 59581
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"icon_id": "23790930",
|
||||||
|
"name": "更正公告",
|
||||||
|
"font_class": "gengzhenggonggao",
|
||||||
|
"unicode": "e8be",
|
||||||
|
"unicode_decimal": 59582
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"icon_id": "23790931",
|
||||||
|
"name": "招标公告",
|
||||||
|
"font_class": "zhaobiaogonggao",
|
||||||
|
"unicode": "e8bf",
|
||||||
|
"unicode_decimal": 59583
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"icon_id": "23732532",
|
||||||
|
"name": "文件",
|
||||||
|
"font_class": "wenjian6",
|
||||||
|
"unicode": "e8ba",
|
||||||
|
"unicode_decimal": 59578
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"icon_id": "23732533",
|
||||||
|
"name": "文件夹",
|
||||||
|
"font_class": "wenjianjia4",
|
||||||
|
"unicode": "e8bb",
|
||||||
|
"unicode_decimal": 59579
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"icon_id": "23642443",
|
||||||
|
"name": "取消关注",
|
||||||
|
"font_class": "quxiaoguanzhu",
|
||||||
|
"unicode": "e89a",
|
||||||
|
"unicode_decimal": 59546
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"icon_id": "23642444",
|
||||||
|
"name": "点赞_icon",
|
||||||
|
"font_class": "dianzan_icon",
|
||||||
|
"unicode": "e8a2",
|
||||||
|
"unicode_decimal": 59554
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"icon_id": "23639530",
|
||||||
|
"name": "文件",
|
||||||
|
"font_class": "wenjian5",
|
||||||
|
"unicode": "e896",
|
||||||
|
"unicode_decimal": 59542
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"icon_id": "23639533",
|
||||||
|
"name": "文件夹",
|
||||||
|
"font_class": "wenjianjia3",
|
||||||
|
"unicode": "e8a9",
|
||||||
|
"unicode_decimal": 59561
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"icon_id": "23639440",
|
||||||
|
"name": "复制icon",
|
||||||
|
"font_class": "fuzhiicon",
|
||||||
|
"unicode": "e886",
|
||||||
|
"unicode_decimal": 59526
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"icon_id": "23639422",
|
||||||
|
"name": "主页-fill",
|
||||||
|
"font_class": "zhuye-fill",
|
||||||
|
"unicode": "e876",
|
||||||
|
"unicode_decimal": 59510
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"icon_id": "23639423",
|
||||||
|
"name": "代码库icon",
|
||||||
|
"font_class": "daimakuicon",
|
||||||
|
"unicode": "e884",
|
||||||
|
"unicode_decimal": 59524
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"icon_id": "23572260",
|
"icon_id": "23572260",
|
||||||
"name": "新建",
|
"name": "新建",
|
||||||
|
@ -33,34 +180,6 @@
|
||||||
"unicode": "e8a6",
|
"unicode": "e8a6",
|
||||||
"unicode_decimal": 59558
|
"unicode_decimal": 59558
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"icon_id": "23492900",
|
|
||||||
"name": "点赞_icon",
|
|
||||||
"font_class": "dianzan_icon",
|
|
||||||
"unicode": "e8ba",
|
|
||||||
"unicode_decimal": 59578
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"icon_id": "23492901",
|
|
||||||
"name": "取消关注",
|
|
||||||
"font_class": "quxiaoguanzhu",
|
|
||||||
"unicode": "e8bb",
|
|
||||||
"unicode_decimal": 59579
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"icon_id": "23473151",
|
|
||||||
"name": "代码库icon",
|
|
||||||
"font_class": "daimakuicon",
|
|
||||||
"unicode": "e8a9",
|
|
||||||
"unicode_decimal": 59561
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"icon_id": "23473104",
|
|
||||||
"name": "主页icon",
|
|
||||||
"font_class": "zhuyeicon",
|
|
||||||
"unicode": "e884",
|
|
||||||
"unicode_decimal": 59524
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"icon_id": "23472253",
|
"icon_id": "23472253",
|
||||||
"name": "标签icon",
|
"name": "标签icon",
|
||||||
|
@ -82,13 +201,6 @@
|
||||||
"unicode": "e885",
|
"unicode": "e885",
|
||||||
"unicode_decimal": 59525
|
"unicode_decimal": 59525
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"icon_id": "23472257",
|
|
||||||
"name": "复制icon",
|
|
||||||
"font_class": "fuzhiicon",
|
|
||||||
"unicode": "e886",
|
|
||||||
"unicode_decimal": 59526
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"icon_id": "23472258",
|
"icon_id": "23472258",
|
||||||
"name": "链接icon",
|
"name": "链接icon",
|
||||||
|
@ -145,13 +257,6 @@
|
||||||
"unicode": "e899",
|
"unicode": "e899",
|
||||||
"unicode_decimal": 59545
|
"unicode_decimal": 59545
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"icon_id": "23472268",
|
|
||||||
"name": "文件",
|
|
||||||
"font_class": "wenjian5",
|
|
||||||
"unicode": "e89a",
|
|
||||||
"unicode_decimal": 59546
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"icon_id": "23472269",
|
"icon_id": "23472269",
|
||||||
"name": "提交icon",
|
"name": "提交icon",
|
||||||
|
@ -166,13 +271,6 @@
|
||||||
"unicode": "e89f",
|
"unicode": "e89f",
|
||||||
"unicode_decimal": 59551
|
"unicode_decimal": 59551
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"icon_id": "23472271",
|
|
||||||
"name": "文件夹",
|
|
||||||
"font_class": "wenjianjia3",
|
|
||||||
"unicode": "e8a2",
|
|
||||||
"unicode_decimal": 59554
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"icon_id": "23472272",
|
"icon_id": "23472272",
|
||||||
"name": "下拉按钮",
|
"name": "下拉按钮",
|
||||||
|
@ -404,13 +502,6 @@
|
||||||
"unicode": "e875",
|
"unicode": "e875",
|
||||||
"unicode_decimal": 59509
|
"unicode_decimal": 59509
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"icon_id": "23046262",
|
|
||||||
"name": "复制_icon",
|
|
||||||
"font_class": "fuzhi_icon",
|
|
||||||
"unicode": "e876",
|
|
||||||
"unicode_decimal": 59510
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"icon_id": "23046268",
|
"icon_id": "23046268",
|
||||||
"name": "删除icon",
|
"name": "删除icon",
|
||||||
|
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
|
@ -1,16 +1,10 @@
|
||||||
import React, { useState } from 'react';
|
import React, { useState } from 'react';
|
||||||
import { Dropdown, Menu, Tooltip } from 'antd';
|
import { Menu } from 'antd';
|
||||||
import "./branch.scss";
|
import "./branch.scss";
|
||||||
|
import CopyTool from '../Component/CopyTool';
|
||||||
|
|
||||||
function CloneAddress({http_url , ssh_url , zip_url , tar_url}) {
|
function CloneAddress({http_url , ssh_url , zip_url , tar_url}) {
|
||||||
const [ key , setKey ] = useState("HTTP");
|
const [ key , setKey ] = useState("HTTP");
|
||||||
// 点击按钮复制功能
|
|
||||||
function jsCopy(){
|
|
||||||
var e = document.getElementById("copy_rep_content");
|
|
||||||
e.select();
|
|
||||||
document.execCommand("Copy");
|
|
||||||
}
|
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div className="downMenu">
|
<div className="downMenu">
|
||||||
<div style={{padding:"10px 20px 20px 20px",borderBottom:"1px solid #eee"}}>
|
<div style={{padding:"10px 20px 20px 20px",borderBottom:"1px solid #eee"}}>
|
||||||
|
@ -20,9 +14,7 @@ function CloneAddress({http_url , ssh_url , zip_url , tar_url}) {
|
||||||
</Menu>
|
</Menu>
|
||||||
<div className="gitAddressClone">
|
<div className="gitAddressClone">
|
||||||
<input type="text" id="copy_rep_content" value={key==="HTTP" ? http_url:ssh_url} />
|
<input type="text" id="copy_rep_content" value={key==="HTTP" ? http_url:ssh_url} />
|
||||||
<Tooltip title="复制链接">
|
<CopyTool inputId="copy_rep_content" className="copytool"/>
|
||||||
<span className="color-blue" onClick={jsCopy}><i className="iconfont icon-fuzhi"></i></span>
|
|
||||||
</Tooltip>
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<Menu className="edu-txt-center">
|
<Menu className="edu-txt-center">
|
||||||
|
|
|
@ -102,4 +102,7 @@
|
||||||
border-color:transparent ;
|
border-color:transparent ;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
.copytool{
|
||||||
|
margin:0px 10px;
|
||||||
}
|
}
|
|
@ -9,24 +9,32 @@ CopyTool.defaultProps = {
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
function CopyTool({ beforeText, afterText, className,inputId }) {
|
function CopyTool({ beforeText, afterText, className , inputId , timeOut }) {
|
||||||
const [title, setTitle] = useState(() => {
|
const [title, setTitle] = useState(() => {
|
||||||
return beforeText;
|
return beforeText;
|
||||||
});
|
});
|
||||||
|
|
||||||
// 复制链接
|
// 复制链接
|
||||||
const copyUrl = useCallback(() => {
|
const copyUrl = useCallback(() => {
|
||||||
let inputDom = document.getElementById(inputId);
|
const copyEle = document.querySelector(`#${inputId}`); // 获取要复制的节点
|
||||||
if (!inputDom) {
|
if (!copyEle) {
|
||||||
console.error("您的CopyTool未设置正确的inputId");
|
console.error("您的CopyTool未设置正确的inputId");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
inputDom.select();
|
const range = document.createRange(); // 创造range
|
||||||
|
window.getSelection().removeAllRanges(); //清除页面中已有的selection
|
||||||
|
range.selectNode(copyEle); // 选中需要复制的节点
|
||||||
|
window.getSelection().addRange(range); // 执行选中元素
|
||||||
|
|
||||||
if (document.execCommand('copy')) {
|
if (document.execCommand('copy')) {
|
||||||
document.execCommand('copy');
|
document.execCommand('copy');
|
||||||
}
|
}
|
||||||
setTitle(afterText);
|
setTitle(afterText);
|
||||||
inputDom.blur();
|
if(timeOut){
|
||||||
|
setTimeout(function(){
|
||||||
|
setTitle(beforeText);
|
||||||
|
},1500)
|
||||||
|
}
|
||||||
}, []);
|
}, []);
|
||||||
|
|
||||||
return (
|
return (
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
import React from 'react';
|
import React from 'react';
|
||||||
import { AlignCenter } from '../layout';
|
import { AlignCenter } from '../layout';
|
||||||
import { Modal , Button } from 'antd';
|
import { Button } from 'antd';
|
||||||
import './Index.scss';
|
import Modals from '../PublicModal/Index';
|
||||||
|
|
||||||
function DeleteBox({
|
function DeleteBox({
|
||||||
visible ,
|
visible ,
|
||||||
|
@ -12,24 +12,22 @@ function DeleteBox({
|
||||||
content
|
content
|
||||||
}) {
|
}) {
|
||||||
return(
|
return(
|
||||||
<Modal
|
<Modals
|
||||||
visible={visible}
|
title={title}
|
||||||
onCancel={onCancel}
|
btn={
|
||||||
title={title}
|
|
||||||
width="600px"
|
|
||||||
className="deleteBox"
|
|
||||||
footer={
|
|
||||||
<div>
|
<div>
|
||||||
<Button size={'large'} onClick={onCancel}>取消</Button>
|
<Button size={'large'} onClick={onCancel}>取消</Button>
|
||||||
<Button type={"danger"} size={"large"} onClick={onSuccess}>确认删除</Button>
|
<Button type={"danger"} size={"large"} onClick={onSuccess}>确认删除</Button>
|
||||||
</div>
|
</div>
|
||||||
}
|
}
|
||||||
|
onCancel={onCancel}
|
||||||
|
visible={visible}
|
||||||
>
|
>
|
||||||
<div className="desc">
|
<div className="desc">
|
||||||
<AlignCenter className="descMain"><i className="iconfont icon-shanchu_tc_icon mr10"></i>{content}</AlignCenter>
|
<AlignCenter className="descMain"><i className="iconfont icon-shanchu_tc_icon mr10"></i>{content}</AlignCenter>
|
||||||
<p>{subTitle}</p>
|
<p>{subTitle}</p>
|
||||||
</div>
|
</div>
|
||||||
</Modal>
|
</Modals>
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
export default DeleteBox;
|
export default DeleteBox;
|
|
@ -1,6 +1,6 @@
|
||||||
.ant-modal-mask{
|
.ant-modal-mask{
|
||||||
z-index: 1001;
|
z-index: 1031;
|
||||||
}
|
}
|
||||||
.ant-modal-wrap{
|
.ant-modal-wrap{
|
||||||
z-index: 1002;
|
z-index: 1032;
|
||||||
}
|
}
|
|
@ -0,0 +1,68 @@
|
||||||
|
import React , { useEffect , useState } from 'react';
|
||||||
|
import Modals from '../PublicModal/Index';
|
||||||
|
import { Button } from 'antd';
|
||||||
|
import axios from 'axios';
|
||||||
|
|
||||||
|
import './Index.scss';
|
||||||
|
|
||||||
|
function ProfileModal({visible,onCancel,history}) {
|
||||||
|
const [ modalVis , setModalVis ] = useState(visible);
|
||||||
|
const [ addMemberCheck , setAddMemberCheck ] = useState(false);
|
||||||
|
|
||||||
|
useEffect(()=>{
|
||||||
|
axios.interceptors.response.use((response) => {
|
||||||
|
if (response && (response.data.status === 411 || response.data.status === 412)) {
|
||||||
|
setModalVis(true);
|
||||||
|
if(response.data.status === 412){
|
||||||
|
setAddMemberCheck(true);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return response;
|
||||||
|
}, (error) => {
|
||||||
|
});
|
||||||
|
},[])
|
||||||
|
|
||||||
|
useEffect(()=>{
|
||||||
|
setModalVis(visible);
|
||||||
|
},[visible])
|
||||||
|
|
||||||
|
function onOk(){
|
||||||
|
onCancel();
|
||||||
|
setModalVis(false);
|
||||||
|
setTimeout(function(){
|
||||||
|
window.open(`/settings/profile`,"_blank");
|
||||||
|
},200)
|
||||||
|
}
|
||||||
|
|
||||||
|
function onNo() {
|
||||||
|
onCancel();
|
||||||
|
setModalVis(false);
|
||||||
|
}
|
||||||
|
|
||||||
|
return(
|
||||||
|
<Modals
|
||||||
|
title="完善资料"
|
||||||
|
onCancel={onNo}
|
||||||
|
visible={modalVis}
|
||||||
|
btn={
|
||||||
|
addMemberCheck?
|
||||||
|
<div>
|
||||||
|
<Button type={'primary'} size={"large"} onClick={onNo}>好的</Button>
|
||||||
|
</div>
|
||||||
|
:
|
||||||
|
<div>
|
||||||
|
<Button size={"large"} onClick={onNo}>暂不补充</Button>
|
||||||
|
<Button type={'primary'} size={"large"} onClick={onOk}>好的</Button>
|
||||||
|
</div>
|
||||||
|
}
|
||||||
|
>
|
||||||
|
{
|
||||||
|
addMemberCheck ?
|
||||||
|
<p>目标用户个人资料不完整,需提醒目标用户补充资料后以进行后续操作</p>
|
||||||
|
:
|
||||||
|
<p>您目前的个人资料不完整,需要补充资料以进行后续操作。是否前往补充个人信息?</p>
|
||||||
|
}
|
||||||
|
</Modals>
|
||||||
|
)
|
||||||
|
}
|
||||||
|
export default ProfileModal;
|
|
@ -0,0 +1,17 @@
|
||||||
|
import React from 'react';
|
||||||
|
|
||||||
|
function Profile({children,sureFunc,showCompeleteDialog , completeProfile, className}) {
|
||||||
|
|
||||||
|
function checkProfile() {
|
||||||
|
if(!completeProfile){
|
||||||
|
showCompeleteDialog && showCompeleteDialog();
|
||||||
|
}else{
|
||||||
|
sureFunc();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return(
|
||||||
|
<a className={className} onClick={checkProfile}>{children}</a>
|
||||||
|
)
|
||||||
|
}
|
||||||
|
export default Profile;
|
|
@ -0,0 +1,19 @@
|
||||||
|
import React from 'react';
|
||||||
|
import { Modal } from 'antd';
|
||||||
|
import './Index.scss';
|
||||||
|
|
||||||
|
function Modals({title,children,btn,onCancel,visible}) {
|
||||||
|
return(
|
||||||
|
<Modal
|
||||||
|
visible={visible}
|
||||||
|
onCancel={onCancel}
|
||||||
|
title={title}
|
||||||
|
width="600px"
|
||||||
|
className="deleteBox"
|
||||||
|
footer={btn}
|
||||||
|
>
|
||||||
|
{children}
|
||||||
|
</Modal>
|
||||||
|
)
|
||||||
|
}
|
||||||
|
export default Modals;
|
|
@ -32,14 +32,23 @@
|
||||||
border-top: none;
|
border-top: none;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
padding-bottom: 40px;
|
padding-bottom: 40px;
|
||||||
button{
|
button,a{
|
||||||
width: 120px;
|
width: 120px;
|
||||||
margin:0px 20px;
|
margin:0px 20px;
|
||||||
|
&.ant-btn{
|
||||||
|
border-color: #D0D0D0;
|
||||||
|
color: #666;
|
||||||
|
}
|
||||||
&.ant-btn-danger{
|
&.ant-btn-danger{
|
||||||
background-color: #fff;
|
background-color: #fff;
|
||||||
color: #DF0002;
|
color: #DF0002;
|
||||||
border-color: #D0D0D0;
|
border-color: #D0D0D0;
|
||||||
}
|
}
|
||||||
|
&.ant-btn.ant-btn-primary{
|
||||||
|
background-color: #fff;
|
||||||
|
color: #466AFF;
|
||||||
|
border-color: #D0D0D0;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
|
@ -41,15 +41,19 @@ function DivertModal({form , visible , onSuccess , onCancel,owner,repo}){
|
||||||
// 确认转移
|
// 确认转移
|
||||||
function onOk(){
|
function onOk(){
|
||||||
validateFields((error,values)=>{
|
validateFields((error,values)=>{
|
||||||
console.log(...values);
|
|
||||||
if(!error){
|
if(!error){
|
||||||
const url = `/${owner}/${repo}/applied_transfer_projects.json`;
|
const url = `/${owner}/${repo}/applied_transfer_projects.json`;
|
||||||
Axios.post(url,{
|
Axios.post(url,{
|
||||||
...values
|
...values
|
||||||
}).then(result=>{
|
}).then(result=>{
|
||||||
if(result){
|
if(result){
|
||||||
onSuccess(result.data && result.data.owner);
|
if(result.data.status === 0){
|
||||||
|
onSuccess(result.data && result.data.owner);
|
||||||
|
}else{
|
||||||
|
onSuccess();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
}).catch(error=>{})
|
}).catch(error=>{})
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
|
@ -1,6 +1,7 @@
|
||||||
import React, { useState , forwardRef, useEffect } from 'react';
|
import React, { useState , forwardRef, useEffect } from 'react';
|
||||||
import { Form , Modal , Input , Radio } from 'antd';
|
import { Form , Modal , Input , Radio } from 'antd';
|
||||||
import Axios from 'axios';
|
import Axios from 'axios';
|
||||||
|
import CheckProfile from '../Component/ProfileModal/Profile';
|
||||||
|
|
||||||
export default Form.create()(
|
export default Form.create()(
|
||||||
forwardRef((props)=>{
|
forwardRef((props)=>{
|
||||||
|
@ -77,7 +78,7 @@ export default Form.create()(
|
||||||
</Form.Item>
|
</Form.Item>
|
||||||
</Form>
|
</Form>
|
||||||
</Modal>
|
</Modal>
|
||||||
<a onClick={()=>setVisible(true)}>加入项目</a>
|
<CheckProfile {...props} sureFunc={()=>setVisible(true)}>加入项目</CheckProfile>
|
||||||
</React.Fragment>
|
</React.Fragment>
|
||||||
)
|
)
|
||||||
})
|
})
|
||||||
|
|
|
@ -10,6 +10,7 @@ import HeadSearch from '../Component/HeadSearch';
|
||||||
|
|
||||||
import AddProjectModal from './AddProjectModal';
|
import AddProjectModal from './AddProjectModal';
|
||||||
import '../../modules/tpm/TPMIndex.css';
|
import '../../modules/tpm/TPMIndex.css';
|
||||||
|
import CheckProfile from '../Component/ProfileModal/Profile';
|
||||||
|
|
||||||
import './header.scss';
|
import './header.scss';
|
||||||
const $ = window.$
|
const $ = window.$
|
||||||
|
@ -222,6 +223,15 @@ class NewHeader extends Component {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
checkProfile=(url)=>{
|
||||||
|
const { showCompeleteDialog , completeProfile } = this.props;
|
||||||
|
if(!completeProfile){
|
||||||
|
showCompeleteDialog && showCompeleteDialog();
|
||||||
|
}else{
|
||||||
|
window.location.href(url);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
addMenu=(list)=>{
|
addMenu=(list)=>{
|
||||||
return(
|
return(
|
||||||
|
@ -231,11 +241,16 @@ class NewHeader extends Component {
|
||||||
{
|
{
|
||||||
list.map((item,key)=>{
|
list.map((item,key)=>{
|
||||||
return(
|
return(
|
||||||
(item.name !=="加入课堂" && item.name !=="加入开发项目") && <Menu.Item key={item.name+key}><a href={item.url}>{item.name}</a></Menu.Item>
|
(item.name !=="加入课堂" && item.name !=="加入开发项目") &&
|
||||||
|
<Menu.Item key={item.name+key}>
|
||||||
|
<CheckProfile {...this.props} sureFunc={()=>{window.location.href=item.url}}>{item.name}</CheckProfile>
|
||||||
|
</Menu.Item>
|
||||||
)
|
)
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
<Menu.Item><AddProjectModal showNotification={this.props.showNotification}/></Menu.Item>
|
<Menu.Item>
|
||||||
|
<AddProjectModal {...this.props} showNotification={this.props.showNotification}/>
|
||||||
|
</Menu.Item>
|
||||||
</Menu>
|
</Menu>
|
||||||
</div>
|
</div>
|
||||||
)
|
)
|
||||||
|
|
|
@ -20,6 +20,7 @@ import DrawerPanel from '../Component/DrawerPanel';
|
||||||
import UpdateDescModal from './sub/UpdateDescModal';
|
import UpdateDescModal from './sub/UpdateDescModal';
|
||||||
import Nodata from '../Nodata';
|
import Nodata from '../Nodata';
|
||||||
import Invite from './sub/Invite';
|
import Invite from './sub/Invite';
|
||||||
|
import CheckProfile from '../Component/ProfileModal/Profile';
|
||||||
/**
|
/**
|
||||||
* projectDetail.type:0是托管项目,1是镜像项目,2是同步镜像项目(为2时不支持在线创建、在线上传、在线修改、在线删除、创建合并请求等功能)
|
* projectDetail.type:0是托管项目,1是镜像项目,2是同步镜像项目(为2时不支持在线创建、在线上传、在线修改、在线删除、创建合并请求等功能)
|
||||||
*/
|
*/
|
||||||
|
@ -364,11 +365,11 @@ function CoderDepot(props){
|
||||||
<div className="mr20 addOptionBtn">
|
<div className="mr20 addOptionBtn">
|
||||||
{
|
{
|
||||||
projectDetail.type !== 2 && pullsFlag &&
|
projectDetail.type !== 2 && pullsFlag &&
|
||||||
<a onClick={()=>urlLink(`/${owner}/${projectsId}/pulls/new`)} >+ 合并请求</a>
|
<CheckProfile {...props} sureFunc={()=>urlLink(`/${owner}/${projectsId}/pulls/new`)} >+ 合并请求</CheckProfile>
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
issuesFlag &&
|
issuesFlag &&
|
||||||
<a onClick={()=>urlLink(`/${owner}/${projectsId}/issues/new`)} >+ 任务</a>
|
<CheckProfile {...props} sureFunc={()=>urlLink(`/${owner}/${projectsId}/issues/new`)} >+ 任务</CheckProfile>
|
||||||
}
|
}
|
||||||
</div>
|
</div>
|
||||||
}
|
}
|
||||||
|
@ -454,7 +455,10 @@ function CoderDepot(props){
|
||||||
<Gap style={{paddingLeft:"30px"}}>
|
<Gap style={{paddingLeft:"30px"}}>
|
||||||
<div className="panelmenu">
|
<div className="panelmenu">
|
||||||
<FlexAJ className="font-18 color-grey-6 mb20" style={{lineHeight:"28px"}}>简介
|
<FlexAJ className="font-18 color-grey-6 mb20" style={{lineHeight:"28px"}}>简介
|
||||||
{projectDetail.permission && (projectDetail.permission==="Admin" || projectDetail.permission==="Owner") && <i onClick={()=>setOpenModal(true)} className="iconfont icon-anquanshezhi color-grey-9 font-15"></i>}
|
{
|
||||||
|
projectDetail.permission && (projectDetail.permission==="Admin" || projectDetail.permission==="Owner" || projectDetail.permission==="Manager") &&
|
||||||
|
<i onClick={()=>setOpenModal(true)} className="iconfont icon-anquanshezhi color-grey-9 font-15"></i>
|
||||||
|
}
|
||||||
</FlexAJ>
|
</FlexAJ>
|
||||||
{desc && <p className="font-14 color-grey-9 mb15 task-hide-2" style={{lineHeight:"22px",WebkitLineClamp:"4",textAlign:"justify",wordBreak:"break-all"}}>{desc}</p>}
|
{desc && <p className="font-14 color-grey-9 mb15 task-hide-2" style={{lineHeight:"22px",WebkitLineClamp:"4",textAlign:"justify",wordBreak:"break-all"}}>{desc}</p>}
|
||||||
{
|
{
|
||||||
|
|
|
@ -1,26 +1,15 @@
|
||||||
import React from 'react';
|
import React from 'react';
|
||||||
import { Tooltip , message } from 'antd';
|
|
||||||
import './sub.scss';
|
import './sub.scss';
|
||||||
|
import CopyTool from '../../Component/CopyTool';
|
||||||
|
|
||||||
function Invite({code,className}) {
|
function Invite({code,className}) {
|
||||||
|
|
||||||
function jsCopy(id) {
|
|
||||||
const copyEle = document.querySelector(id); // 获取要复制的节点
|
|
||||||
const range = document.createRange(); // 创造range
|
|
||||||
window.getSelection().removeAllRanges(); //清除页面中已有的selection
|
|
||||||
range.selectNode(copyEle); // 选中需要复制的节点
|
|
||||||
window.getSelection().addRange(range); // 执行选中元素
|
|
||||||
document.execCommand("Copy"); // 执行copy操作
|
|
||||||
message.success('复制成功');
|
|
||||||
}
|
|
||||||
return(
|
return(
|
||||||
<div className={className}>
|
<div className={className}>
|
||||||
<span className="font-16 color-grey-6">邀请码</span>
|
<span className="font-16 color-grey-6">邀请码</span>
|
||||||
<div>
|
<div>
|
||||||
<span id="devitecode">{code}</span>
|
<span id="devitecode">{code}</span>
|
||||||
<Tooltip title={<p className="edu-txt-center">可以通过邀请码邀请成员加入项目<br/>点击复制邀请码。</p>} placement={"bottom"}>
|
<CopyTool timeOut={true} beforeText={<p className="edu-txt-center">可以通过邀请码邀请成员加入项目<br/>点击复制邀请码。</p>} className="ml8 font-16" inputId="devitecode"/>
|
||||||
<i className="iconfont icon-fuzhi2 font-16 color-blue ml8" onClick={()=>jsCopy("#devitecode")}></i>
|
|
||||||
</Tooltip>
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
)
|
)
|
||||||
|
|
|
@ -8,6 +8,7 @@ import MergeItem from "./MergeItem";
|
||||||
import './Index.scss';
|
import './Index.scss';
|
||||||
|
|
||||||
import axios from "axios";
|
import axios from "axios";
|
||||||
|
import CheckProfile from '../Component/ProfileModal/Profile';
|
||||||
|
|
||||||
const Search = Input.Search;
|
const Search = Input.Search;
|
||||||
/**
|
/**
|
||||||
|
@ -256,9 +257,9 @@ class merge extends Component {
|
||||||
</div>
|
</div>
|
||||||
{
|
{
|
||||||
data && data.user_admin_or_developer &&
|
data && data.user_admin_or_developer &&
|
||||||
<a className="topWrapper_btn ml10" onClick={() => this.checkOperation()}>
|
<CheckProfile {...this.props} className="topWrapper_btn ml10" sureFunc={() => this.checkOperation()}>
|
||||||
+ 新建合并请求
|
+ 新建合并请求
|
||||||
</a>
|
</CheckProfile>
|
||||||
}
|
}
|
||||||
</div>
|
</div>
|
||||||
<div className="f-wrap-between screenWrap">
|
<div className="f-wrap-between screenWrap">
|
||||||
|
|
|
@ -4,6 +4,7 @@ import { Dropdown, Icon, Menu, Pagination, Typography, Popconfirm, Spin } from '
|
||||||
import NoneData from '../Nodata';
|
import NoneData from '../Nodata';
|
||||||
import axios from 'axios';
|
import axios from 'axios';
|
||||||
import './order.css';
|
import './order.css';
|
||||||
|
import CheckProfile from '../Component/ProfileModal/Profile';
|
||||||
|
|
||||||
const { Text } = Typography;
|
const { Text } = Typography;
|
||||||
|
|
||||||
|
@ -187,7 +188,7 @@ class Milepost extends Component {
|
||||||
</ul>
|
</ul>
|
||||||
{
|
{
|
||||||
data && data.user_admin_or_member ?
|
data && data.user_admin_or_member ?
|
||||||
<Link to={`/${owner}/${projectsId}/milestones/new`} className="topWrapper_btn">新的里程碑</Link>
|
<CheckProfile {...this.props} className="topWrapper_btn" sureFunc={() => {this.props.history.push(`/${owner}/${projectsId}/milestones/new`)}}>新的里程碑</CheckProfile>
|
||||||
: ''
|
: ''
|
||||||
}
|
}
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -2,7 +2,8 @@ import React, { Component } from "react";
|
||||||
import { Link } from 'react-router-dom';
|
import { Link } from 'react-router-dom';
|
||||||
import { Dropdown, Menu, Icon, Pagination, Spin } from 'antd';
|
import { Dropdown, Menu, Icon, Pagination, Spin } from 'antd';
|
||||||
import './order.css';
|
import './order.css';
|
||||||
import { FlexAJ } from '../Component/layout'
|
import { FlexAJ } from '../Component/layout';
|
||||||
|
import CheckProfile from '../Component/ProfileModal/Profile';
|
||||||
|
|
||||||
import NoneData from '../Nodata';
|
import NoneData from '../Nodata';
|
||||||
import OrderItem from './OrderItem';
|
import OrderItem from './OrderItem';
|
||||||
|
@ -239,7 +240,7 @@ class MilepostDetail extends Component {
|
||||||
</span>
|
</span>
|
||||||
<div className="milepostdiv">
|
<div className="milepostdiv">
|
||||||
<Link to={`/${owner}/${projectsId}/milestones/${meilid}/edit`} className="topWrapper_btn" style={{ marginRight: 15 }} >编辑里程碑</Link>
|
<Link to={`/${owner}/${projectsId}/milestones/${meilid}/edit`} className="topWrapper_btn" style={{ marginRight: 15 }} >编辑里程碑</Link>
|
||||||
<Link to={`/${owner}/${projectsId}/issues/${meilid}/new`} className="topWrapper_btn">创建易修</Link>
|
<CheckProfile {...this.props} sureFunc={()=>{this.props.history.push(`/${owner}/${projectsId}/issues/${meilid}/new`)}} className="topWrapper_btn">创建易修</CheckProfile>
|
||||||
</div>
|
</div>
|
||||||
</FlexAJ>
|
</FlexAJ>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -44,6 +44,7 @@ class OrderItem extends Component {
|
||||||
render() {
|
render() {
|
||||||
const { item , checkbox , mile , user_admin_or_member } = this.props;
|
const { item , checkbox , mile , user_admin_or_member } = this.props;
|
||||||
const { projectsId , owner } = this.props.match.params;
|
const { projectsId , owner } = this.props.match.params;
|
||||||
|
const { orderid , isdisplay } = this.state;
|
||||||
const { current_user } = this.props;
|
const { current_user } = this.props;
|
||||||
return (
|
return (
|
||||||
item &&
|
item &&
|
||||||
|
@ -91,12 +92,21 @@ class OrderItem extends Component {
|
||||||
<Link to={`/${owner}/${projectsId}/issues/${item.id}/detail`}><i className="iconfont icon-pinglun1 mr3 font-16"></i>{item.journals_count}</Link>
|
<Link to={`/${owner}/${projectsId}/issues/${item.id}/detail`}><i className="iconfont icon-pinglun1 mr3 font-16"></i>{item.journals_count}</Link>
|
||||||
{
|
{
|
||||||
user_admin_or_member ?
|
user_admin_or_member ?
|
||||||
<div id="hoverBox" style={{ display: this.state.orderid === item.id && this.state.isdisplay ? 'flex' : 'none' }}>
|
<div style={{ display: orderid === item.id && isdisplay ? 'flex' : 'none' }}>
|
||||||
<div className="mr8 ml8 color-grey-9">
|
<div className="mr8 ml8 color-grey-9">
|
||||||
<Link to={`/${owner}/${projectsId}/issues/${item.id}/updatedetail`} className="color-grey-9"><i className="iconfont icon-bianji3 font-14 mr5"></i></Link>
|
<Link to={`/${owner}/${projectsId}/issues/${item.id}/updatedetail`} className="color-grey-9">
|
||||||
|
<i className="iconfont icon-bianji3 font-14 mr5"></i>
|
||||||
|
</Link>
|
||||||
</div>
|
</div>
|
||||||
<div className="color-grey-9">
|
<div className="color-grey-9">
|
||||||
<Popconfirm placement="bottom" overlayClassName="overlayBox" getPopupContainer={()=>document.getElementById("hoverBox")} title={'您确定要删除当前易修吗?'} okText="是" cancelText="否" onConfirm={() => this.deletedetail(item.id)}>
|
<Popconfirm
|
||||||
|
placement="bottom"
|
||||||
|
overlayClassName={orderid === item.id && isdisplay ? "overlayBox" : "overlayBox hideOverlay" }
|
||||||
|
title={'您确定要删除当前易修吗?'}
|
||||||
|
okText="是"
|
||||||
|
cancelText="否"
|
||||||
|
onConfirm={() => this.deletedetail(item.id)}
|
||||||
|
>
|
||||||
<i className="iconfont icon-yiguanbi1 font-14"></i>
|
<i className="iconfont icon-yiguanbi1 font-14"></i>
|
||||||
</Popconfirm>
|
</Popconfirm>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -20,6 +20,9 @@
|
||||||
.overlayBox{
|
.overlayBox{
|
||||||
width: 230px;
|
width: 230px;
|
||||||
}
|
}
|
||||||
|
.hideOverlay{
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
.topmilepost {
|
.topmilepost {
|
||||||
box-sizing: border-box;
|
box-sizing: border-box;
|
||||||
display: flex;
|
display: flex;
|
||||||
|
|
|
@ -1,12 +1,12 @@
|
||||||
import React, { Component } from "react";
|
import React, { Component } from "react";
|
||||||
import { Input, Dropdown, Menu, Icon, Pagination, Spin, DatePicker, Checkbox } from "antd";
|
import { Input, Dropdown, Menu, Icon, Pagination, Spin, DatePicker, Checkbox } from "antd";
|
||||||
import { Link } from 'react-router-dom';
|
|
||||||
import "./order.css";
|
import "./order.css";
|
||||||
import './index.scss';
|
import './index.scss';
|
||||||
import moment from 'moment';
|
import moment from 'moment';
|
||||||
|
|
||||||
import NoneData from "../Nodata";
|
import NoneData from "../Nodata";
|
||||||
import OrderItem from "./OrderItem";
|
import OrderItem from "./OrderItem";
|
||||||
|
import CheckProfile from '../Component/ProfileModal/Profile';
|
||||||
|
|
||||||
import axios from "axios";
|
import axios from "axios";
|
||||||
|
|
||||||
|
@ -351,9 +351,9 @@ class order extends Component {
|
||||||
if(data && data.user_admin_or_member){
|
if(data && data.user_admin_or_member){
|
||||||
const { projectsId , owner } = this.props.match.params;
|
const { projectsId , owner } = this.props.match.params;
|
||||||
return(
|
return(
|
||||||
<Link className="topWrapper_btn ml10" target="_blank" to={`/${owner}/${projectsId}/issues/new`}>
|
<CheckProfile {...this.props} className="topWrapper_btn ml10" sureFunc={()=>{window.open(`/${owner}/${projectsId}/issues/new`,'_blank')}}>
|
||||||
+ 创建易修
|
+ 创建易修
|
||||||
</Link>
|
</CheckProfile>
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -18,6 +18,10 @@ const SSHNew = Loadable({
|
||||||
loader: () => import("./sub/New"),
|
loader: () => import("./sub/New"),
|
||||||
loading: Loading,
|
loading: Loading,
|
||||||
});
|
});
|
||||||
|
const Profile = Loadable({
|
||||||
|
loader: () => import("../users/Material/Index"),
|
||||||
|
loading: Loading,
|
||||||
|
});
|
||||||
const SSHIndex = Loadable({
|
const SSHIndex = Loadable({
|
||||||
loader: () => import("./sub/SSH"),
|
loader: () => import("./sub/SSH"),
|
||||||
loading: Loading,
|
loading: Loading,
|
||||||
|
@ -39,6 +43,10 @@ function Index(props){
|
||||||
<li>安全设置</li>
|
<li>安全设置</li>
|
||||||
<li className={pathname.indexOf("/settings/SSH")>-1 ?"active":""}><Link to={`/settings/SSH`}><i className="iconfont icon-xuanzhongssh_icon mr5 font-14"></i>SSH密钥</Link></li>
|
<li className={pathname.indexOf("/settings/SSH")>-1 ?"active":""}><Link to={`/settings/SSH`}><i className="iconfont icon-xuanzhongssh_icon mr5 font-14"></i>SSH密钥</Link></li>
|
||||||
</ul>
|
</ul>
|
||||||
|
<ul className="securityUl">
|
||||||
|
<li>个人信息</li>
|
||||||
|
<li className={pathname.indexOf("/settings/profile")>-1 ?"active":""}><Link to={`/settings/profile`}><i className="iconfont icon-gerenziliao mr5 font-14"></i>基本资料</Link></li>
|
||||||
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
<LongWidth>
|
<LongWidth>
|
||||||
<Gap>
|
<Gap>
|
||||||
|
@ -49,6 +57,12 @@ function Index(props){
|
||||||
<SSHNew {...props} {...p}/>
|
<SSHNew {...props} {...p}/>
|
||||||
)}
|
)}
|
||||||
></Route>
|
></Route>
|
||||||
|
<Route
|
||||||
|
path="/settings/profile"
|
||||||
|
render={(p) => (
|
||||||
|
<Profile {...props} {...p}/>
|
||||||
|
)}
|
||||||
|
></Route>
|
||||||
<Route
|
<Route
|
||||||
path="/settings/SSH"
|
path="/settings/SSH"
|
||||||
render={(p) => (
|
render={(p) => (
|
||||||
|
|
|
@ -36,6 +36,8 @@
|
||||||
.securityUl{
|
.securityUl{
|
||||||
padding:20px 16px;
|
padding:20px 16px;
|
||||||
color: #333;
|
color: #333;
|
||||||
|
margin-bottom: 0px;
|
||||||
|
padding-bottom: 0px;
|
||||||
li{
|
li{
|
||||||
margin-bottom: 10px;
|
margin-bottom: 10px;
|
||||||
height: 27px;
|
height: 27px;
|
||||||
|
@ -124,7 +126,6 @@
|
||||||
}
|
}
|
||||||
.deleteBox{
|
.deleteBox{
|
||||||
.ant-modal-header{
|
.ant-modal-header{
|
||||||
background-color: rgba(223, 0, 2, 0.06);
|
|
||||||
border-bottom: none;
|
border-bottom: none;
|
||||||
.ant-modal-title{
|
.ant-modal-title{
|
||||||
text-align: left;
|
text-align: left;
|
||||||
|
|
|
@ -221,10 +221,14 @@ class Setting extends Component {
|
||||||
}
|
}
|
||||||
// 确定转移仓库
|
// 确定转移仓库
|
||||||
onSuccess=(owner)=>{
|
onSuccess=(owner)=>{
|
||||||
|
if(owner){
|
||||||
|
this.setState({
|
||||||
|
is_transfering:true,
|
||||||
|
transfer:owner
|
||||||
|
})
|
||||||
|
}
|
||||||
this.setState({
|
this.setState({
|
||||||
is_transfering:true,
|
divertVisible:false
|
||||||
divertVisible:false,
|
|
||||||
transfer:owner
|
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -6,6 +6,7 @@ import './Index.scss';
|
||||||
import Item from './ListItem';
|
import Item from './ListItem';
|
||||||
import Right from './RightBox';
|
import Right from './RightBox';
|
||||||
import NoData from '../Nodata';
|
import NoData from '../Nodata';
|
||||||
|
import CheckProfile from '../Component/ProfileModal/Profile';
|
||||||
|
|
||||||
import { Menu , Pagination , Dropdown , Spin } from 'antd';
|
import { Menu , Pagination , Dropdown , Spin } from 'antd';
|
||||||
import axios from 'axios';
|
import axios from 'axios';
|
||||||
|
@ -61,8 +62,12 @@ function List(props){
|
||||||
)
|
)
|
||||||
const menu_new=(
|
const menu_new=(
|
||||||
<Menu>
|
<Menu>
|
||||||
<Menu.Item key="updated_on"><Link to={`/projects/deposit/new/${OIdentifier}`}>新建托管项目</Link></Menu.Item>
|
<Menu.Item key="updated_on">
|
||||||
<Menu.Item key="created_on"><Link to={`/projects/mirror/new/${OIdentifier}`}>新建镜像项目</Link></Menu.Item>
|
<CheckProfile {...props} sureFunc={()=>{props.history.push(`/projects/deposit/new/${OIdentifier}`)}}>新建托管项目</CheckProfile>
|
||||||
|
</Menu.Item>
|
||||||
|
<Menu.Item key="created_on">
|
||||||
|
<CheckProfile {...props} sureFunc={()=>{props.history.push(`/projects/mirror/new/${OIdentifier}`)}}>新建镜像项目</CheckProfile>
|
||||||
|
</Menu.Item>
|
||||||
</Menu>
|
</Menu>
|
||||||
)
|
)
|
||||||
|
|
||||||
|
@ -106,7 +111,13 @@ function List(props){
|
||||||
</div>
|
</div>
|
||||||
}
|
}
|
||||||
</div>
|
</div>
|
||||||
<Right admin={organizeDetail && organizeDetail.is_admin} OIdentifier={OIdentifier} history={props.history}/>
|
<Right
|
||||||
|
admin={organizeDetail && organizeDetail.is_admin}
|
||||||
|
OIdentifier={OIdentifier}
|
||||||
|
showCompeleteDialog={props.showCompeleteDialog}
|
||||||
|
completeProfile={props.completeProfile}
|
||||||
|
history={props.history}
|
||||||
|
/>
|
||||||
</div>
|
</div>
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,5 +1,4 @@
|
||||||
import React , { useEffect , useState } from 'react';
|
import React , { useEffect , useState } from 'react';
|
||||||
import { Button } from 'antd';
|
|
||||||
import styled from 'styled-components';
|
import styled from 'styled-components';
|
||||||
import Box from './Box';
|
import Box from './Box';
|
||||||
import axios from 'axios';
|
import axios from 'axios';
|
||||||
|
@ -7,6 +6,8 @@ import { getImageUrl } from 'educoder';
|
||||||
import { Link } from 'react-router-dom';
|
import { Link } from 'react-router-dom';
|
||||||
import Nodata from '../Nodata';
|
import Nodata from '../Nodata';
|
||||||
|
|
||||||
|
import CheckProfile from '../Component/ProfileModal/Profile';
|
||||||
|
|
||||||
const Span = styled.span`{
|
const Span = styled.span`{
|
||||||
color:#888;
|
color:#888;
|
||||||
font-size:12px;
|
font-size:12px;
|
||||||
|
@ -36,7 +37,7 @@ const Img = styled.img`{
|
||||||
height:45px;
|
height:45px;
|
||||||
margin-right:12px;
|
margin-right:12px;
|
||||||
}`
|
}`
|
||||||
function RightBox({ OIdentifier , history , admin }) {
|
function RightBox({ OIdentifier , history , admin , showCompeleteDialog ,completeProfile }) {
|
||||||
const [ memberData, setMemberData ] = useState(undefined);
|
const [ memberData, setMemberData ] = useState(undefined);
|
||||||
const [ groupData, setGroupData ] = useState(undefined);
|
const [ groupData, setGroupData ] = useState(undefined);
|
||||||
|
|
||||||
|
@ -87,7 +88,15 @@ function RightBox({ OIdentifier , history , admin }) {
|
||||||
<Box
|
<Box
|
||||||
name="组织团队"
|
name="组织团队"
|
||||||
count={groupData && groupData.total_count}
|
count={groupData && groupData.total_count}
|
||||||
bottom={admin && <Button type={'primary'} onClick={()=>history.push(`/${OIdentifier}/teams/new`)}>新建团队</Button>}
|
bottom={
|
||||||
|
admin &&
|
||||||
|
<CheckProfile
|
||||||
|
showCompeleteDialog={showCompeleteDialog}
|
||||||
|
completeProfile={completeProfile}
|
||||||
|
sureFunc={()=>history.push(`/${OIdentifier}/teams/new`)}
|
||||||
|
className={"ant-btn ant-btn-primary"}
|
||||||
|
>新建团队</CheckProfile>
|
||||||
|
}
|
||||||
url={`/${OIdentifier}/teams`}
|
url={`/${OIdentifier}/teams`}
|
||||||
>
|
>
|
||||||
{
|
{
|
||||||
|
|
|
@ -19,7 +19,9 @@ function FocusButton({is_watch , fontClass, starText, is_block , id , successFun
|
||||||
}).then((result) => {
|
}).then((result) => {
|
||||||
if (result && result.data.status === 0) {
|
if (result && result.data.status === 0) {
|
||||||
successFunc && successFunc();
|
successFunc && successFunc();
|
||||||
setWatchFlag(!watchFlag);
|
if(!flag){
|
||||||
|
setWatchFlag(!watchFlag);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
setIsSpin(false);
|
setIsSpin(false);
|
||||||
})
|
})
|
||||||
|
|
|
@ -76,6 +76,8 @@ class comments extends Component {
|
||||||
content: "",
|
content: "",
|
||||||
reply_content: undefined,
|
reply_content: undefined,
|
||||||
});
|
});
|
||||||
|
this.state.new_journal_id = result.data.id;
|
||||||
|
this.getjournalslist(page, limit);
|
||||||
this.setState({
|
this.setState({
|
||||||
showFiles: false,
|
showFiles: false,
|
||||||
content: "",
|
content: "",
|
||||||
|
@ -86,10 +88,13 @@ class comments extends Component {
|
||||||
journal_spin: false,
|
journal_spin: false,
|
||||||
attachment_clean: false,
|
attachment_clean: false,
|
||||||
});
|
});
|
||||||
this.state.new_journal_id = result.data.id;
|
|
||||||
this.getjournalslist(page, limit);
|
|
||||||
}
|
}
|
||||||
this.props.showNotification(result.data.message);
|
this.setState({
|
||||||
|
journal_spin: false
|
||||||
|
});
|
||||||
|
if(result && result.data.status !== 411){
|
||||||
|
this.props.showNotification(result.data.message);
|
||||||
|
}
|
||||||
})
|
})
|
||||||
.catch((error) => {
|
.catch((error) => {
|
||||||
this.setState({
|
this.setState({
|
||||||
|
|
|
@ -218,6 +218,7 @@ ul.ant-menu.menuStyle{
|
||||||
border-bottom: 2px solid transparent!important;
|
border-bottom: 2px solid transparent!important;
|
||||||
position: relative;
|
position: relative;
|
||||||
a{
|
a{
|
||||||
|
font-size: 16px;
|
||||||
& >i{
|
& >i{
|
||||||
font-size: 15px!important;
|
font-size: 15px!important;
|
||||||
margin-right: 8px;
|
margin-right: 8px;
|
||||||
|
|
|
@ -221,7 +221,7 @@ class Infos extends Component {
|
||||||
{user && user.description}
|
{user && user.description}
|
||||||
</div>
|
</div>
|
||||||
<div>
|
<div>
|
||||||
{user && current_user && user.login === current_user.login && (
|
{/* {user && current_user && user.login === current_user.login && (
|
||||||
<div className="user-info-star-button ">
|
<div className="user-info-star-button ">
|
||||||
<Button
|
<Button
|
||||||
block
|
block
|
||||||
|
@ -234,7 +234,7 @@ class Infos extends Component {
|
||||||
修改资料
|
修改资料
|
||||||
</Button>
|
</Button>
|
||||||
</div>
|
</div>
|
||||||
)}
|
)} */}
|
||||||
{current_user && user && user.login !== current_user.login && (
|
{current_user && user && user.login !== current_user.login && (
|
||||||
<div className="user-info-star-button ">
|
<div className="user-info-star-button ">
|
||||||
<FocusButton
|
<FocusButton
|
||||||
|
@ -349,18 +349,18 @@ class Infos extends Component {
|
||||||
return <Organize {...this.props} {...this.state} />;
|
return <Organize {...this.props} {...this.state} />;
|
||||||
}}
|
}}
|
||||||
></Route>
|
></Route>
|
||||||
<Route
|
{/* <Route
|
||||||
path="/:username/info"
|
path="/:username/info"
|
||||||
render={() => {
|
render={() => {
|
||||||
return <UpdateInfo {...this.props} {...this.state} resetUser={this.resetUser}/>;
|
return <UpdateInfo {...this.props} {...this.state} resetUser={this.resetUser}/>;
|
||||||
}}
|
}}
|
||||||
></Route>
|
></Route> */}
|
||||||
<Route
|
{/* <Route
|
||||||
path="/:username/password"
|
path="/:username/password"
|
||||||
render={() => {
|
render={() => {
|
||||||
return <UpdateInfo {...this.props} {...this.state}/>;
|
return <UpdateInfo {...this.props} {...this.state}/>;
|
||||||
}}
|
}}
|
||||||
></Route>
|
></Route> */}
|
||||||
|
|
||||||
<Route
|
<Route
|
||||||
path="/:username/statistics"
|
path="/:username/statistics"
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
import React, { Component } from "react";
|
import React, { Component } from "react";
|
||||||
import { Link } from "react-router-dom";
|
|
||||||
import { Menu, Input, Spin, Pagination, Popover, Button, Divider } from "antd";
|
import { Menu, Input, Spin, Pagination, Popover, Button, Divider } from "antd";
|
||||||
|
import CheckProfile from '../Component/ProfileModal/Profile';
|
||||||
|
|
||||||
import axios from "axios";
|
import axios from "axios";
|
||||||
import ListItem from "../Main/IndexItem";
|
import ListItem from "../Main/IndexItem";
|
||||||
|
@ -74,6 +74,7 @@ class InfosUser extends Component {
|
||||||
|
|
||||||
//切换种类
|
//切换种类
|
||||||
changeCategory = (cate) => {
|
changeCategory = (cate) => {
|
||||||
|
this.state.page = 1;
|
||||||
this.state.category = cate.target.value;
|
this.state.category = cate.target.value;
|
||||||
this.get_projects();
|
this.get_projects();
|
||||||
};
|
};
|
||||||
|
@ -115,14 +116,15 @@ class InfosUser extends Component {
|
||||||
newItem =()=> (
|
newItem =()=> (
|
||||||
<Menu>
|
<Menu>
|
||||||
<Menu.Item key="created_mirror">
|
<Menu.Item key="created_mirror">
|
||||||
<Link to={`/projects/mirror/new`}>新建镜像项目</Link>
|
<CheckProfile {...this.props} sureFunc={()=>{this.props.history.push('/projects/mirror/new')}}>新建镜像项目</CheckProfile>
|
||||||
</Menu.Item>
|
</Menu.Item>
|
||||||
<Menu.Item key="created_deposit">
|
<Menu.Item key="created_deposit">
|
||||||
<Link to={`/projects/deposit/new`}>新建托管项目</Link>
|
<CheckProfile {...this.props} sureFunc={()=>{this.props.history.push('/projects/deposit/new')}} >新建托管项目</CheckProfile>
|
||||||
</Menu.Item>
|
</Menu.Item>
|
||||||
</Menu>
|
</Menu>
|
||||||
);
|
);
|
||||||
|
|
||||||
|
|
||||||
category_button=(category)=>{
|
category_button=(category)=>{
|
||||||
const { current_user, user } = this.props;
|
const { current_user, user } = this.props;
|
||||||
const button_lists =
|
const button_lists =
|
||||||
|
@ -187,7 +189,7 @@ class InfosUser extends Component {
|
||||||
{current_user && user && current_user.login === user.login && (
|
{current_user && user && current_user.login === user.login && (
|
||||||
<Popover
|
<Popover
|
||||||
content={this.newItem()}
|
content={this.newItem()}
|
||||||
trigger={["click"]}
|
trigger={["hover"]}
|
||||||
placement="bottom"
|
placement="bottom"
|
||||||
className="mr50"
|
className="mr50"
|
||||||
>
|
>
|
||||||
|
@ -235,7 +237,7 @@ class InfosUser extends Component {
|
||||||
<div className="edu-txt-center pt30 mb30 border-top-grey">
|
<div className="edu-txt-center pt30 mb30 border-top-grey">
|
||||||
<Pagination
|
<Pagination
|
||||||
simple
|
simple
|
||||||
defaultCurrent={page}
|
current={page}
|
||||||
total={total}
|
total={total}
|
||||||
pageSize={limit}
|
pageSize={limit}
|
||||||
onChange={this.changePage}
|
onChange={this.changePage}
|
||||||
|
|
|
@ -9,8 +9,9 @@ const { TextArea } = Input;
|
||||||
export default Form.create()(
|
export default Form.create()(
|
||||||
forwardRef((props)=>{
|
forwardRef((props)=>{
|
||||||
const { getFieldDecorator, validateFields , setFieldsValue } = props && props.form;
|
const { getFieldDecorator, validateFields , setFieldsValue } = props && props.form;
|
||||||
const { username } = props && props.match && props.match.params;
|
// const { username } = props && props.match && props.match.params;
|
||||||
const { user , resetUser , current_user } = props;
|
const { resetUserInfo , current_user } = props;
|
||||||
|
console.log(props);
|
||||||
|
|
||||||
useEffect(()=>{
|
useEffect(()=>{
|
||||||
if(current_user && current_user.login){
|
if(current_user && current_user.login){
|
||||||
|
@ -30,10 +31,10 @@ export default Form.create()(
|
||||||
}
|
}
|
||||||
|
|
||||||
function submitFunc(values) {
|
function submitFunc(values) {
|
||||||
const url = `/users/${username}.json`;
|
const url = `/users/${current_user && current_user.login}.json`;
|
||||||
const params={
|
const params={
|
||||||
user: {
|
user: {
|
||||||
nickname: values.real_name,
|
nickname: values.nickname,
|
||||||
user_extension_attributes: {
|
user_extension_attributes: {
|
||||||
province: values.location && values.location[0],
|
province: values.location && values.location[0],
|
||||||
city: values.location && values.location[1],
|
city: values.location && values.location[1],
|
||||||
|
@ -44,8 +45,7 @@ export default Form.create()(
|
||||||
Axios.put(url,params).then(result=>{
|
Axios.put(url,params).then(result=>{
|
||||||
if(result && result.data){
|
if(result && result.data){
|
||||||
props.showNotification("资料修改成功!")
|
props.showNotification("资料修改成功!")
|
||||||
resetUser && resetUser(result.data);
|
resetUserInfo && resetUserInfo();
|
||||||
props.history.push(`/${username}`)
|
|
||||||
}
|
}
|
||||||
}).catch(error=>{})
|
}).catch(error=>{})
|
||||||
}
|
}
|
||||||
|
@ -68,7 +68,7 @@ export default Form.create()(
|
||||||
)}
|
)}
|
||||||
</Form.Item>
|
</Form.Item>
|
||||||
<Form.Item label="姓名">
|
<Form.Item label="姓名">
|
||||||
{getFieldDecorator("real_name",{
|
{getFieldDecorator("nickname",{
|
||||||
rules:[{required:true,message:"请输入姓名"}]
|
rules:[{required:true,message:"请输入姓名"}]
|
||||||
})(
|
})(
|
||||||
<Input placeholder="请输入您的姓名" maxLength={20} style={{width:"400px"}}/>
|
<Input placeholder="请输入您的姓名" maxLength={20} style={{width:"400px"}}/>
|
||||||
|
@ -126,7 +126,7 @@ export default Form.create()(
|
||||||
<AlignCenter>
|
<AlignCenter>
|
||||||
<span className="ant-form-item-label"></span>
|
<span className="ant-form-item-label"></span>
|
||||||
<Button type={"primary"} onClick={submit}>提交</Button>
|
<Button type={"primary"} onClick={submit}>提交</Button>
|
||||||
<Button type={"default"} onClick={()=>props.history.push(`/${username}`)} className="ml20">取消</Button>
|
{/* <Button type={"default"} onClick={()=>props.history.push(`/${current_user && current_user.login}`)} className="ml20">取消</Button> */}
|
||||||
</AlignCenter>
|
</AlignCenter>
|
||||||
</Form>
|
</Form>
|
||||||
)
|
)
|
||||||
|
|
|
@ -6,21 +6,16 @@ import Base from './Base';
|
||||||
import Password from './Password';
|
import Password from './Password';
|
||||||
|
|
||||||
function Index(props){
|
function Index(props){
|
||||||
const { username } = props && props.match && props.match.params;
|
// const { username } = props && props.match && props.match.params;
|
||||||
const { pathname } = props && props.location;
|
const { pathname } = props && props.location;
|
||||||
const { current_user } = props;
|
// const { current_user } = props;
|
||||||
|
|
||||||
useEffect(()=>{
|
|
||||||
if((username && current_user && (current_user.login !== username))){
|
|
||||||
props.history.push(`/${username}`);
|
|
||||||
}
|
|
||||||
},[current_user,username])
|
|
||||||
|
|
||||||
const [ key , setKey ] = useState("0");
|
const [ key , setKey ] = useState("0");
|
||||||
|
|
||||||
useEffect(()=>{
|
useEffect(()=>{
|
||||||
if(pathname){
|
if(pathname){
|
||||||
if(pathname === `/${username}/info`){
|
if(pathname === `/settings/profile`){
|
||||||
setKey("0");
|
setKey("0");
|
||||||
}else{
|
}else{
|
||||||
setKey("1");
|
setKey("1");
|
||||||
|
@ -32,7 +27,7 @@ function Index(props){
|
||||||
return(
|
return(
|
||||||
<div>
|
<div>
|
||||||
<Menu selectedKeys={[key]} mode={'horizontal'} className="infosRightMenu">
|
<Menu selectedKeys={[key]} mode={'horizontal'} className="infosRightMenu">
|
||||||
<Menu.Item key="0"><Link to={`/${username}/info`}>基本资料</Link></Menu.Item>
|
<Menu.Item key="0"><Link to={`/settings/profile`}>基本资料</Link></Menu.Item>
|
||||||
{/* <Menu.Item key="1"><Link to={`/${username}/password`}>密码管理</Link></Menu.Item> */}
|
{/* <Menu.Item key="1"><Link to={`/${username}/password`}>密码管理</Link></Menu.Item> */}
|
||||||
</Menu>
|
</Menu>
|
||||||
<div style={{padding:"20px"}}>
|
<div style={{padding:"20px"}}>
|
||||||
|
|
|
@ -6,9 +6,19 @@
|
||||||
.ant-form-explain{
|
.ant-form-explain{
|
||||||
position: absolute;
|
position: absolute;
|
||||||
}
|
}
|
||||||
|
.ant-row.ant-form-item{
|
||||||
|
margin-bottom: 12px;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
.formBase.passMan{
|
.formBase.passMan{
|
||||||
.ant-form-item-label{
|
.ant-form-item-label{
|
||||||
width: 92px;
|
width: 92px;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
.infosRightMenu{
|
||||||
|
.ant-menu-item{
|
||||||
|
a{
|
||||||
|
font-size: 16px;
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
|
@ -5,7 +5,7 @@ import Search from '../Component/Search';
|
||||||
import Item from './Team-item';
|
import Item from './Team-item';
|
||||||
import Nodata from '../Nodata';
|
import Nodata from '../Nodata';
|
||||||
import axios from 'axios';
|
import axios from 'axios';
|
||||||
import { Link } from 'react-router-dom';
|
import CheckProfile from '../Component/ProfileModal/Profile';
|
||||||
|
|
||||||
const limit = 15;
|
const limit = 15;
|
||||||
function Team(props){
|
function Team(props){
|
||||||
|
@ -48,6 +48,7 @@ function Team(props){
|
||||||
</Menu>
|
</Menu>
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
||||||
return(
|
return(
|
||||||
<div>
|
<div>
|
||||||
<div className="headerbox">
|
<div className="headerbox">
|
||||||
|
@ -57,7 +58,7 @@ function Team(props){
|
||||||
<p>
|
<p>
|
||||||
{
|
{
|
||||||
checkIfLogin() &&
|
checkIfLogin() &&
|
||||||
<Link to={`/organize/new`}><i className="iconfont icon-xinjian1 mr3 font-14"></i>新建组织</Link>
|
<CheckProfile {...props} sureFunc={()=>{props.history.push('/organize/new')}}><i className="iconfont icon-xinjian1 mr3 font-14"></i>新建组织</CheckProfile>
|
||||||
}
|
}
|
||||||
<Dropdown overlay={menu}>
|
<Dropdown overlay={menu}>
|
||||||
<a>排序<i className="iconfont icon-sanjiaoxing-down ml3 font-14"></i></a>
|
<a>排序<i className="iconfont icon-sanjiaoxing-down ml3 font-14"></i></a>
|
||||||
|
|
|
@ -4,9 +4,13 @@ class WatcherUsers extends Component {
|
||||||
render() {
|
render() {
|
||||||
const {user, current_user , fetchUser } = this.props;
|
const {user, current_user , fetchUser } = this.props;
|
||||||
return (
|
return (
|
||||||
<div className="minH-650">
|
user && user.login &&
|
||||||
{user && user.login && <CommonLists userType="watch_users" login={user.login} current_user={current_user} fetchUser={fetchUser}/>}
|
<CommonLists
|
||||||
</div>
|
userType="watch_users"
|
||||||
|
login={user.login}
|
||||||
|
current_user={current_user}
|
||||||
|
fetchUser={fetchUser}
|
||||||
|
/>
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -6,6 +6,7 @@ import { Spin } from 'antd';
|
||||||
import './TPMIndex.css';
|
import './TPMIndex.css';
|
||||||
import LoginDialog from '../login/LoginDialog';
|
import LoginDialog from '../login/LoginDialog';
|
||||||
import EducoderAccount from '../../forge/Component/EducoderAccount';
|
import EducoderAccount from '../../forge/Component/EducoderAccount';
|
||||||
|
import ProfileModal from '../../forge/Component/ProfileModal/Index';
|
||||||
|
|
||||||
export function TPMIndexHOC(WrappedComponent) {
|
export function TPMIndexHOC(WrappedComponent) {
|
||||||
return class II extends React.Component {
|
return class II extends React.Component {
|
||||||
|
@ -24,7 +25,9 @@ export function TPMIndexHOC(WrappedComponent) {
|
||||||
isloginCancel: undefined,
|
isloginCancel: undefined,
|
||||||
mygetHelmetapi: null,
|
mygetHelmetapi: null,
|
||||||
giteaVisible:false,
|
giteaVisible:false,
|
||||||
email:undefined
|
email:undefined,
|
||||||
|
completeProfile:false,
|
||||||
|
showCP:false
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -151,7 +154,8 @@ export function TPMIndexHOC(WrappedComponent) {
|
||||||
if (response && response.data) {
|
if (response && response.data) {
|
||||||
this.initCommonState(response.data)
|
this.initCommonState(response.data)
|
||||||
this.setState({
|
this.setState({
|
||||||
tpmLoading: false
|
tpmLoading: false,
|
||||||
|
completeProfile:response.data.profile_completed
|
||||||
})
|
})
|
||||||
if (this.props.match.path === "/" && response.data.login) {
|
if (this.props.match.path === "/" && response.data.login) {
|
||||||
this.props.history.push(`/${response.data.login}`);
|
this.props.history.push(`/${response.data.login}`);
|
||||||
|
@ -204,23 +208,35 @@ export function TPMIndexHOC(WrappedComponent) {
|
||||||
}).catch(error=>{})
|
}).catch(error=>{})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
showCompeleteDialog=()=>{
|
||||||
|
this.setState({
|
||||||
|
showCP:true
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
render() {
|
render() {
|
||||||
let { isRender , current_user , giteaVisible , email } = this.state;
|
let { isRender , current_user , giteaVisible , email , completeProfile , showCP } = this.state;
|
||||||
const common = {
|
const common = {
|
||||||
showLoginDialog: this.showLoginDialog,
|
showLoginDialog: this.showLoginDialog,
|
||||||
checkIfLogin: this.checkIfLogin,
|
checkIfLogin: this.checkIfLogin,
|
||||||
resetUserInfo:this.fetchUsers
|
resetUserInfo:this.fetchUsers,
|
||||||
|
showCompeleteDialog:this.showCompeleteDialog
|
||||||
};
|
};
|
||||||
return (
|
return (
|
||||||
<div className="indexHOC">
|
<div className="indexHOC">
|
||||||
<EducoderAccount visible={giteaVisible} email={email} onOk={this.onOk}/>
|
<EducoderAccount visible={giteaVisible} email={email} onOk={this.onOk}/>
|
||||||
|
<ProfileModal
|
||||||
|
visible={!completeProfile && showCP}
|
||||||
|
onCancel={()=>{this.setState({showCP:false})}}
|
||||||
|
history={this.props.history}
|
||||||
|
/>
|
||||||
{isRender === true ? <LoginDialog
|
{isRender === true ? <LoginDialog
|
||||||
Modifyloginvalue={() => this.hideLoginDialog()}
|
Modifyloginvalue={() => this.hideLoginDialog()}
|
||||||
{...this.props}
|
{...this.props}
|
||||||
{...this.state}
|
{...this.state}
|
||||||
/> : ""}
|
/> : ""}
|
||||||
<Header {...this.state} {...this.props}></Header>
|
<Header {...this.state} {...this.props} {...common}></Header>
|
||||||
<Spin spinning={this.state.globalLoading} delay={0} className="globalSpin"
|
<Spin spinning={this.state.globalLoading} delay={0} className="globalSpin"
|
||||||
size="large" tip={this._gLoadingTip || "加载中..."}
|
size="large" tip={this._gLoadingTip || "加载中..."}
|
||||||
>
|
>
|
||||||
|
|
Loading…
Reference in New Issue