This commit is contained in:
谢思 2022-11-03 14:47:52 +08:00
parent 0a19859bf7
commit ba7333f1ad
10 changed files with 24 additions and 24 deletions

View File

@ -185,7 +185,7 @@ function checkPathname(projectsId, owner, pathname) {
name = "source"
} else if (url.indexOf(`/wiki`) > -1) {
name = "wiki"
} else if (url.indexOf(`/server`) > -1) {
} else if (url.indexOf(`/service`) > -1) {
name = "server"
}
}
@ -686,7 +686,7 @@ class Detail extends Component {
<Spin spinning={secondSync} className="spinstyle" tip="正在同步镜像" size="large">
<Switch {...this.props}>
{/* 服务 */}
<Route path="/:owner/:projectsId/server"
<Route path="/:owner/:projectsId/service"
render={
() => (<Server {...this.props} {...this.state} {...common} />)
}

View File

@ -136,7 +136,7 @@ function DetailBanner({ history,list , owner , projectsId ,showNotification , ur
{
item.menu_name === "services" &&
<li className={pathname === "server" ? "active" : ""}>
<Link className='newTab' to={{ pathname: `/${owner}/${projectsId}/server`, state }}>
<Link className='newTab' to={{ pathname: `/${owner}/${projectsId}/service`, state }}>
<i className={"iconfont icon-fuwuicon color-grey-3 mr5 font-15"} style={{marginTop:"1px"}}></i>
<span>服务</span><div className='newBtnImg'></div>
</Link>

View File

@ -48,7 +48,7 @@ function New({ form , showNotification , history }) {
{getFieldDecorator("key",{
rules:[{required:true,message:"请输入密钥"}]
})(
<TextArea placeholder="支持以'ssh-rsa','ssh-dss','ssh-ed25519','ecdsa-sha2-nistp256','ecdsa-sha2-nistp384','ecdsa-sha2-nistp521'开头" autoSize={{ minRows: 6, maxRows: 6 }}/>
<TextArea placeholder="支持以'ssh-rsa','ssh-ed25519','ecdsa-sha2-nistp256','ecdsa-sha2-nistp384','ecdsa-sha2-nistp521'开头" autoSize={{ minRows: 6, maxRows: 6 }}/>
)}
</Form.Item>
<button style={{width:"100px"}} onClick={submit} className="but25">确定</button>

View File

@ -22,17 +22,17 @@ function ServerIndex(props){
return(
<div className="panels">
<Switch {...props}>
<Route path="/:owner/:projectsId/server/reposyncer"
<Route path="/:owner/:projectsId/service/reposyncer"
render={
() => (<Reposyncer {...props}/>)
}
></Route>
<Route path="/:owner/:projectsId/server/:id"
<Route path="/:owner/:projectsId/service/codeanalysis"
render={
() => (<Data {...props}/>)
}
></Route>
<Route path="/:owner/:projectsId/server"
<Route path="/:owner/:projectsId/service"
render={
() => (<List {...props}/>)
}

View File

@ -11,7 +11,7 @@ function Main(props){
useEffect(()=>{
if(current_user && !current_user.login){
props.history.push(`/login?go_page=/${owner}/${projectsId}/server`);
props.history.push(`/login?go_page=/${owner}/${projectsId}/service`);
}else{
setHas_trace_user(current_user.has_trace_user);
}
@ -20,7 +20,7 @@ function Main(props){
function onOk(){
setVisible(false);
resetUserInfo && resetUserInfo();
props.history.push(`/${owner}/${projectsId}/server/1`);
props.history.push(`/${owner}/${projectsId}/service/codeanalysis`);
}
function openDetail(){
@ -29,7 +29,7 @@ function Main(props){
}else if(!has_trace_user){
setVisible(true);
}else{
props.history.push(`/${owner}/${projectsId}/server/1`);
props.history.push(`/${owner}/${projectsId}/service/codeanalysis`);
}
}
return(
@ -39,7 +39,7 @@ function Main(props){
<li>
<span className="servername">
<img src={require('./img/logo.png')} alt=""/>
<a onClick={openDetail}>鸟代码溯源</a>
<a onClick={openDetail}>鸟代码溯源</a>
</span>
<p className="task-hide-2 serverdesc">支持软件源代码的溯源分析自主度评估开源漏洞检测开源许可证合规性分析等</p>
<span className="serverbtn">
@ -49,11 +49,11 @@ function Main(props){
<li>
<div className="servername" style={{marginBottom: '8px'}}>
{/* <img src={require('./img/logo.png')} alt=""/> */}
<Link to={`/${owner}/${projectsId}/server/reposyncer`}>Reposyncer仓库同步</Link>
<Link to={`/${owner}/${projectsId}/service/reposyncer`}>Reposyncer仓库同步</Link>
</div>
<p className="task-hide-2 serverdesc">支持不同开源托管平台自动同步推送/拉取相关代码实现多平台项目同步开发功能</p>
<span className="serverbtn">
<Link to={`/${owner}/${projectsId}/server/reposyncer`} className="btnhover">查看详情</Link>
<Link to={`/${owner}/${projectsId}/service/reposyncer`} className="btnhover">查看详情</Link>
</span>
</li>
</ul>

View File

@ -162,7 +162,7 @@ function Data(props) {
repeatBranch={repeatBranch}
/>
<div className="servertitle">
<span className="systitle">鸟代码溯源服务</span>
<span className="systitle">鸟代码溯源服务</span>
{!operateTime && isManager && <a className="btnhover" onClick={createCheck}>新建分析</a>}
</div>
<Spin spinning={spining}>

View File

@ -38,7 +38,7 @@ function EditStore(props){
axios.post(`/${owner}/${projectsId}/synchronizes.json`,values).then(res=>{
if(res && res.data.message === "success"){
message.success('绑定成功');
window.location.href = `/${owner}/${projectsId}/server/reposyncer`;
window.location.href = `/${owner}/${projectsId}/service/reposyncer`;
}else{
// message.error('');
}

View File

@ -125,7 +125,7 @@ function RecordList(props){
return <div className="storeListBox">
<div className="font-16">
<Link to={`/${owner}/${projectsId}/server/reposyncer`} className="blueSpan">仓库绑定</Link>
<Link to={`/${owner}/${projectsId}/service/reposyncer`} className="blueSpan">仓库绑定</Link>
<span> &gt; 同步分支</span>
</div>
<div className="headBox font-16 pl15 mt20 mb10">

View File

@ -28,7 +28,7 @@ function StoreList(props){
if(res && res.data.message === "success"){
message.success('取消绑定成功');
setVisible(false);
props.history.push(`/${owner}/${projectsId}/server`)
props.history.push(`/${owner}/${projectsId}/service`)
}
})
}
@ -44,7 +44,7 @@ function StoreList(props){
<p className="font-22 mt10">欢迎使用跨平台代码同步服务</p>
<div className="introBox font-15">跨平台代码同步服务提供跨托管平台的项目协同开发同步功能支持用户在任何一个托管平台上的代码提交代码推送合并请求等操作自动同步至其他托管平台不仅增加每个开源项目与开发者的流量也使不同平台的开源项目维护与更新变得方便与快捷</div>
<div className="borBox"></div>
<Button type="primary" style={{width: '112px', height: '36px'}}><Link to={`/${owner}/${projectsId}/server/reposyncer/store/edit`}>开始体验</Link></Button>
<Button type="primary" style={{width: '112px', height: '36px'}}><Link to={`/${owner}/${projectsId}/service/reposyncer/store/edit`}>开始体验</Link></Button>
</div>}
{/* 已绑定仓库信息 */}
{storeDetail && <div className="listStore mt20">
@ -55,7 +55,7 @@ function StoreList(props){
<span>{storeDetail && storeDetail.github_address}</span>
</div>
<div>
<Button style={{width: '94px', height:'36px', padding: 0}} className="blue_border_but mr20"><Link to={`/${owner}/${projectsId}/server/reposyncer/record/github`}>查看同步分支</Link></Button>
<Button style={{width: '94px', height:'36px', padding: 0}} className="blue_border_but mr20"><Link to={`/${owner}/${projectsId}/service/reposyncer/record/github`}>查看同步分支</Link></Button>
<Button style={{width: '94px', height:'36px', padding: 0}} className="blue_border_but" onClick={()=>{setVisibleNew(true);setCreateJobBy('Github')}}>新建同步分支</Button>
</div>
</div>}
@ -65,11 +65,11 @@ function StoreList(props){
<span>{storeDetail.gitee_address}</span>
</div>
<div>
<Button style={{width: '94px', height:'36px', padding: 0}} className="blue_border_but mr20"><Link to={`/${owner}/${projectsId}/server/reposyncer/record/gitee`}>查看同步分支</Link></Button>
<Button style={{width: '94px', height:'36px', padding: 0}} className="blue_border_but mr20"><Link to={`/${owner}/${projectsId}/service/reposyncer/record/gitee`}>查看同步分支</Link></Button>
<Button style={{width: '94px', height:'36px', padding: 0}} className="blue_border_but" onClick={()=>{setVisibleNew(true);setCreateJobBy('Gitee')}}>新建同步分支</Button>
</div>
</div>}
{/* <Button type="primary" style={{width: '134px', height:'36px', padding: 0}} className="mt30"><Link to={`/${owner}/${projectsId}/server/reposyncer/store/edit`}>更改绑定仓库信息</Link></Button> */}
{/* <Button type="primary" style={{width: '134px', height:'36px', padding: 0}} className="mt30"><Link to={`/${owner}/${projectsId}/service/reposyncer/store/edit`}>更改绑定仓库信息</Link></Button> */}
<Button style={{width: '134px', height:'36px'}} className="red_border_but mt40" onClick={()=>{setVisible(true)}}>清空仓库绑定</Button>
</div>}
<Modal

View File

@ -41,19 +41,19 @@ function Reposyncer(propsF){
return <div className="reposyncerBox">
<Switch {...propsF}>
<Route
path="/:owner/:projectsId/server/reposyncer/record/:type"
path="/:owner/:projectsId/service/reposyncer/record/:type"
render={(props) => (
<RecordList {...propsF} {...props} storeDetail={storeDetail}/>
)}
></Route>
<Route
path="/:owner/:projectsId/server/reposyncer/store/edit"
path="/:owner/:projectsId/service/reposyncer/store/edit"
render={(props) => (
<EditStore {...propsF} {...props}/>
)}
></Route>
<Route
path="/:owner/:projectsId/server/reposyncer"
path="/:owner/:projectsId/service/reposyncer"
render={(props) => (
<StoreList {...propsF} {...props} storeDetail={storeDetail}/>
)}