diff --git a/src/App.js b/src/App.js index 17be118b0..d03337319 100644 --- a/src/App.js +++ b/src/App.js @@ -3,7 +3,7 @@ import './App.css'; import { ConfigProvider } from 'antd' import zhCN from 'antd/lib/locale-provider/zh_CN'; import { - BrowserRouter as Router, + // BrowserRouter as Router, Route, Switch } from 'react-router-dom'; @@ -108,6 +108,12 @@ class App extends Component { initAxiosInterceptors(this.props); let pathname = window.location.pathname ? window.location.pathname.split('/')[1] : ''; pathname && this.getPathnameType(pathname); + + this.unlisten = this.props.history.listen((location,action) => { + // 最新路由的 location 对象,可以通过比较 pathname 是否相同来判断路由的变化情况 + let newPathname = location.pathname.split('/')[1]; + newPathname&&this.getPathnameType(newPathname); + }); } getPathnameType = (pathname) => { @@ -124,6 +130,8 @@ class App extends Component { } } + + HideAddcoursestypess = (i) => { this.setState({ Addcoursestype: false, @@ -146,7 +154,14 @@ class App extends Component { window.addEventListener('error', (event) => { const msg = `${event.type}: ${event.message}`; }); + + } + + componentWillUnmount() { + this.unlisten && this.unlisten(); // 执行解绑 + } + //修改登录方法 Modifyloginvalue = () => { this.setState({ @@ -225,121 +240,121 @@ class App extends Component { this.Modifyloginvalue()}> - - - {/* wiki预览 */} - { - return () - } - } /> - - {/*项目*/} - { - return () - } - }> - - { - return () - } - }> - - {/*项目*/} - { - return () - } - }> - - { - return () - } - } - /> - {/*403*/} - - - - - {/*404*/} - - - {/* 查询 */} - - - ( - personal && personal.length > 0 ? - - : - - ) - } - /> - - {/* 判断为用户/组织,并进入对应页面 */} - { - pathType === 'User' ? - { - return () - } - } - /> : pathType === 'Organization' ? { - return () - } - }> - : pathType === '404' ? : + {/* */} + + {/* wiki预览 */} + { + return () } + } /> - - {/* 组织 */} - {/* { - return () - } - }> - */} - - {/* 个人主页 */} - - { - return () - } - }> - - ( - personal && personal.length > 0 ? - - : - - ) + {/*项目*/} + { + return () } - /> - - - + }> + + { + return () + } + }> + + {/*项目*/} + { + return () + } + }> + + { + return () + } + } + /> + {/*403*/} + + + + + {/*404*/} + + + {/* 查询 */} + + + ( + personal && personal.length > 0 ? + + : + + ) + } + /> + + {/* 判断为用户/组织,并进入对应页面 */} + { + pathType === 'User' ? + { + return () + } + } + /> : pathType === 'Organization' ? { + return () + } + }> + : pathType === '404' ? : ( + personal && personal.length > 0 ? + + : + + ) + } + /> + } + + + {/* 组织 */} + { + return () + } + }> + + + {/* 个人主页 */} + + { + return () + } + }> + + + + + {/* */} diff --git a/src/college/College.js b/src/college/College.js index 85d43fb7e..f7a3ab6c7 100644 --- a/src/college/College.js +++ b/src/college/College.js @@ -195,7 +195,7 @@ class College extends Component { align: 'center', className: "edu-txt-center font-14 maxnamewidth105", render: (text, record) => ( - { diff --git a/src/context/TPIContextProvider.js b/src/context/TPIContextProvider.js index 22b247272..f3ea3e0fd 100644 --- a/src/context/TPIContextProvider.js +++ b/src/context/TPIContextProvider.js @@ -435,11 +435,11 @@ class TPIContextProvider extends Component { image_url: "avatars/User/1" login: "innov" name: "Coder" - user_url: "/users/innov" + user_url: "/innov" */ let user = resData.user; user.username = resData.user.name; - user.user_url = `/users/${resData.user.login}`; + user.user_url = `/${resData.user.login}`; // user.image_url = resData.image_url; user.is_teacher = resData.is_teacher; resData.user = user; diff --git a/src/forge/Activity/ActivityItem.js b/src/forge/Activity/ActivityItem.js index b726a4af0..d5af3c692 100644 --- a/src/forge/Activity/ActivityItem.js +++ b/src/forge/Activity/ActivityItem.js @@ -32,7 +32,7 @@ class ActivityItem extends Component {

}

- + {item.user_name} diff --git a/src/forge/Component/Contributors.jsx b/src/forge/Component/Contributors.jsx index 1e26354a5..dd7d40e39 100644 --- a/src/forge/Component/Contributors.jsx +++ b/src/forge/Component/Contributors.jsx @@ -52,8 +52,8 @@ function Contributors({contributors,owner,projectsId}){ - - {data.name} + + {data.name} { data.is_watch ? FocusFunc(false,data.login)}>取消关注:FocusFunc(true,data.login)}>关注 @@ -145,7 +145,7 @@ function Contributors({contributors,owner,projectsId}){ list.map((item,key)=>{ return( - + setVisibleFunc(true,item.login,key)}/> diff --git a/src/forge/Component/MemberCards.jsx b/src/forge/Component/MemberCards.jsx index 393ddbb17..f2ba3d09b 100644 --- a/src/forge/Component/MemberCards.jsx +++ b/src/forge/Component/MemberCards.jsx @@ -45,9 +45,9 @@ const Div = styled.div`{ export default (({ user , img, name, time, focusStatus, is_current_user, login , successFunc }) => { return (

- +
- {name} + {name} { is_current_user ? diff --git a/src/forge/Component/User.jsx b/src/forge/Component/User.jsx index 4d22c77bf..bc652dcfb 100644 --- a/src/forge/Component/User.jsx +++ b/src/forge/Component/User.jsx @@ -20,7 +20,7 @@ export default ({ url , name , column , id , login })=>{ `; return( id? - + { url && } {name} diff --git a/src/forge/Head/Header.js b/src/forge/Head/Header.js index 7364ebd38..628c3f3f0 100644 --- a/src/forge/Head/Header.js +++ b/src/forge/Head/Header.js @@ -385,16 +385,16 @@ class NewHeader extends Component { if (new_link && (new_link.indexOf("courses") > -1 || new_link.indexOf("contests") > -1)) { if (user_login) { if (new_link.indexOf("courses") > -1) { - new_link = new_link.replace(/courses/g, "users/" + user_login + "/courses") + new_link = new_link.replace(/courses/g, user_login + "/courses") } else if (new_link.indexOf("contests") > -1) { - new_link = new_link.replace(/contests/g, "users/" + user_login + "/contests") + new_link = new_link.replace(/contests/g, user_login + "/contests") } } else { is_hidden = true } } if (user_login && (new_link && new_link.indexOf("homes") > -1)) { - new_link = new_link.replace(/homes/g, "users/" + user_login + "/user_activities") + new_link = new_link.replace(/homes/g, user_login + "/user_activities") } var waiLian = (new_link && str.filter(item=>new_link.indexOf(item)>-1) ); @@ -442,7 +442,7 @@ class NewHeader extends Component { : - + 头像 diff --git a/src/forge/Main/CoderRootCommit.js b/src/forge/Main/CoderRootCommit.js index b6ca0be67..c25035cb8 100644 --- a/src/forge/Main/CoderRootCommit.js +++ b/src/forge/Main/CoderRootCommit.js @@ -147,7 +147,7 @@ class CoderRootCommit extends Component{

{ item.id ? - + {item.image_url?:""} : diff --git a/src/forge/Main/Detail.js b/src/forge/Main/Detail.js index 583b4db3d..4f930ce42 100644 --- a/src/forge/Main/Detail.js +++ b/src/forge/Main/Detail.js @@ -413,11 +413,10 @@ class Detail extends Component { } textFunc = (forked_from_project_id,fork_info)=>{ - let type = fork_info && fork_info.fork_project_user_type; return forked_from_project_id && fork_info ?

复刻自 - {fork_info.fork_project_user_name} + {fork_info.fork_project_user_name} / {fork_info.fork_form_name}
: "" @@ -453,7 +452,7 @@ class Detail extends Component {
{project && project.author && - {project.author.name} + {project.author.name} } / {projectDetail && projectDetail.name} diff --git a/src/forge/Main/IndexItem.js b/src/forge/Main/IndexItem.js index 4e83e4393..18fd49c68 100644 --- a/src/forge/Main/IndexItem.js +++ b/src/forge/Main/IndexItem.js @@ -28,7 +28,7 @@ class IndexItem extends Component { : - + } diff --git a/src/forge/Main/sub/Contribute.jsx b/src/forge/Main/sub/Contribute.jsx index f65b45248..76d56dc89 100644 --- a/src/forge/Main/sub/Contribute.jsx +++ b/src/forge/Main/sub/Contribute.jsx @@ -52,7 +52,7 @@ function Contribute(props){
- {item.name} + {item.name}

提交{item.contributions}次

diff --git a/src/forge/Merge/MergeItem.js b/src/forge/Merge/MergeItem.js index 32f3f8114..bfb8eace7 100644 --- a/src/forge/Merge/MergeItem.js +++ b/src/forge/Merge/MergeItem.js @@ -78,7 +78,7 @@ class MergeItem extends Component {

{item && item.author_name} @@ -156,7 +156,7 @@ class MergeItem extends Component {

  • {item.assign_user_name ? ( {item.assign_user_name} diff --git a/src/forge/Merge/MergeSubmit.js b/src/forge/Merge/MergeSubmit.js index 8f2275d81..8c80fddf9 100644 --- a/src/forge/Merge/MergeSubmit.js +++ b/src/forge/Merge/MergeSubmit.js @@ -100,7 +100,7 @@ class MergeSubmit extends Component{ width:"10%", render: (text,item) => ( - + diff --git a/src/forge/Merge/MessageCount.js b/src/forge/Merge/MessageCount.js index f3e58657a..427dda900 100644 --- a/src/forge/Merge/MessageCount.js +++ b/src/forge/Merge/MessageCount.js @@ -386,14 +386,14 @@ class MessageCount extends Component { }
    - + - + {data.issue.author_name} @@ -408,7 +408,7 @@ class MessageCount extends Component { 审查人员: {data.issue.assign_user_name ? ( {data.issue.assign_user_name} diff --git a/src/forge/Newfile/UserSubmitComponent.js b/src/forge/Newfile/UserSubmitComponent.js index 5cba3cf62..25504f64a 100644 --- a/src/forge/Newfile/UserSubmitComponent.js +++ b/src/forge/Newfile/UserSubmitComponent.js @@ -150,7 +150,7 @@ class UserSubmitComponent extends Component { return (
    - + { return( -
  • - +
  • +

    - {i.user && i.user.name} + {i.user && i.user.name} {i.time_ago}

    diff --git a/src/forge/Notice/Index.jsx b/src/forge/Notice/Index.jsx index 63d097486..9c52fca16 100644 --- a/src/forge/Notice/Index.jsx +++ b/src/forge/Notice/Index.jsx @@ -33,7 +33,7 @@ function Index(props){ useEffect(()=>{ if((username && current_user && (current_user.login !== username))){ - props.history.push(`/users/${username}`); + props.history.push(`/${username}`); } },[current_user,username]) @@ -47,14 +47,14 @@ function Index(props){ useEffect(()=>{ if(pathname && username){ - if(pathname === `/users/${username}/notice`){ + if(pathname === `/${username}/notice`){ setMenu("notify"); changeNum(user.undo_messages); } - if(pathname === `/users/${username}/notice/undo`){ + if(pathname === `/${username}/notice/undo`){ setMenu("undo"); } - if(pathname === `/users/${username}/notice/apply`){ + if(pathname === `/${username}/notice/apply`){ setMenu("apply"); } } @@ -84,19 +84,19 @@ function Index(props){
    • - + 通知 {messagesCount ? {messagesCount}:""}
    • - + 接收仓库 {transferCount ? {transferCount}:""}
    • - + 成员申请 {applyCount ? {applyCount}:""} @@ -104,19 +104,19 @@ function Index(props){
    { return ; }} > { return ; }} > { return ; }} diff --git a/src/forge/Notice/Notify.jsx b/src/forge/Notice/Notify.jsx index 761366d3d..18a79cfc3 100644 --- a/src/forge/Notice/Notify.jsx +++ b/src/forge/Notice/Notify.jsx @@ -46,9 +46,9 @@ function Notify(props){ case 'canceled': return

    取消转移【{project && project.name}】仓库

    case 'common': - return

    正在将【{project && project.name}】仓库转移给【{owner && owner.name}】

    + return

    正在将【{project && project.name}】仓库转移给【{owner && owner.name}】

    case 'successed': - return

    {project && project.name}】仓库成功转移给【{owner && owner.name}】

    + return

    {project && project.name}】仓库成功转移给【{owner && owner.name}】

    default: return

    拒绝转移【{project && project.name}】仓库

    } @@ -81,11 +81,11 @@ function Notify(props){ { list.map((i,k)=>{ return( -
  • - +
  • +

    - {i.applied_user && i.applied_user.name} + {i.applied_user && i.applied_user.name} {i.time_ago}

    { i.applied_type === "AppliedProject" ? renderApplyStatus(i.status,i.applied):renderStatus(i.status,i.applied)} diff --git a/src/forge/Notice/UndoEvent.jsx b/src/forge/Notice/UndoEvent.jsx index d93a1f83a..bf700be28 100644 --- a/src/forge/Notice/UndoEvent.jsx +++ b/src/forge/Notice/UndoEvent.jsx @@ -68,16 +68,16 @@ function UndoEvent(props){ { list.map((i,k)=>{ return( -
  • - +
  • +

    - {i.user && i.user.name} + {i.user && i.user.name} {i.time_ago}

    请求将仓库【{i.project && i.project.name}】 - 转移给【{i.owner && i.owner.name}】,是否接受?

    + 转移给【{i.owner && i.owner.name}】,是否接受?

    { i.status === "common" && diff --git a/src/forge/Order/Detail.js b/src/forge/Order/Detail.js index 644a653dd..f5294b8a0 100644 --- a/src/forge/Order/Detail.js +++ b/src/forge/Order/Detail.js @@ -207,7 +207,7 @@ class Detail extends Component {
    {data && data.author_name} diff --git a/src/forge/Order/OrderItem.js b/src/forge/Order/OrderItem.js index 3c5e5cf85..1369b5976 100644 --- a/src/forge/Order/OrderItem.js +++ b/src/forge/Order/OrderItem.js @@ -67,7 +67,7 @@ class OrderItem extends Component {
  • { item.author_name ? - + {item.author_name} : "--" @@ -76,7 +76,7 @@ class OrderItem extends Component {
  • { item.assign_user_name ? - + {item.assign_user_name} : "--" diff --git a/src/forge/Settings/CollaboratorMember.jsx b/src/forge/Settings/CollaboratorMember.jsx index 1104a8646..447e3b262 100644 --- a/src/forge/Settings/CollaboratorMember.jsx +++ b/src/forge/Settings/CollaboratorMember.jsx @@ -186,7 +186,7 @@ function CollaboratorMember({projectsId,owner,project_id,author,showNotification render: (text, item) => ( ( - + {text} ), diff --git a/src/forge/Settings/Setting.js b/src/forge/Settings/Setting.js index ba6e7a5a7..02295ce0d 100644 --- a/src/forge/Settings/Setting.js +++ b/src/forge/Settings/Setting.js @@ -351,7 +351,7 @@ class Setting extends Component { { is_transfering ? 此仓库正在转移给【 - {transfer && {transfer.name}} + {transfer && {transfer.name}} 】,请联系对方接收此仓库。 : `将此仓库转移给其他用户或组织` diff --git a/src/forge/Source/Index.jsx b/src/forge/Source/Index.jsx index 8ba925878..e158d7fba 100644 --- a/src/forge/Source/Index.jsx +++ b/src/forge/Source/Index.jsx @@ -217,7 +217,7 @@ function Index(props){ data.map((item,key)=>{ return(
  • - +
    diff --git a/src/forge/Team/Group/Setting/GroupMemberSetting.jsx b/src/forge/Team/Group/Setting/GroupMemberSetting.jsx index a0d8ec781..998e73390 100644 --- a/src/forge/Team/Group/Setting/GroupMemberSetting.jsx +++ b/src/forge/Team/Group/Setting/GroupMemberSetting.jsx @@ -87,7 +87,7 @@ export default ((props) => { align: "center", render: (value, item) => { return ( - {item.user.name} + {item.user.name} ) } }, diff --git a/src/forge/Team/New.jsx b/src/forge/Team/New.jsx index 414a8d158..34cda6b76 100644 --- a/src/forge/Team/New.jsx +++ b/src/forge/Team/New.jsx @@ -56,6 +56,10 @@ export default Form.create()( }) } + function test(){ + history.push(`/test2org`); + } + useEffect(()=>{ setFieldsValue({ visibility:"common" @@ -145,6 +149,7 @@ export default Form.create()(

    +

    ) diff --git a/src/forge/Team/RightBox.jsx b/src/forge/Team/RightBox.jsx index 5425e6222..c4e70fd02 100644 --- a/src/forge/Team/RightBox.jsx +++ b/src/forge/Team/RightBox.jsx @@ -72,9 +72,9 @@ function RightBox({ OIdentifier , history , admin }) { memberData.organization_users.map((item,key)=>{ return(
    - +
    - {item.user && item.user.name} + {item.user && item.user.name} 加入时间:{item.created_at}
    diff --git a/src/forge/Team/Setting/TeamSettingCommon.jsx b/src/forge/Team/Setting/TeamSettingCommon.jsx index 441743593..a9eca4004 100644 --- a/src/forge/Team/Setting/TeamSettingCommon.jsx +++ b/src/forge/Team/Setting/TeamSettingCommon.jsx @@ -92,7 +92,7 @@ export default Form.create()( }).then(result=>{ if(result && result.data){ // 删除后跳转到个人中心的组织页面 - history.push(`/users/${current_user && current_user.login}/organizes`); + history.push(`/${current_user && current_user.login}/organizes`); } }) setVisible(false); diff --git a/src/forge/Team/Setting/TeamSettingMember.jsx b/src/forge/Team/Setting/TeamSettingMember.jsx index 34f0e28ed..1ead66e99 100644 --- a/src/forge/Team/Setting/TeamSettingMember.jsx +++ b/src/forge/Team/Setting/TeamSettingMember.jsx @@ -64,7 +64,7 @@ export default (({organizeDetail})=>{ width:"5%", render:(value)=>{ return( - value && + value && ) } }, @@ -73,7 +73,7 @@ export default (({organizeDetail})=>{ dataIndex: 'user', width:"15%", render:(value,item)=>{ - return {value && value.name} + return {value && value.name} } }, { diff --git a/src/forge/Team/TeamGroupItems.jsx b/src/forge/Team/TeamGroupItems.jsx index b482942c7..f7f12b2d2 100644 --- a/src/forge/Team/TeamGroupItems.jsx +++ b/src/forge/Team/TeamGroupItems.jsx @@ -86,7 +86,7 @@ function TeamGroupItems({organizeDetail,limit, count , history}){ { item.users && item.users.map((i,k)=>{ return( - k < count ? + k < count ? : k === count ? diff --git a/src/forge/UsersList/fork_users.js b/src/forge/UsersList/fork_users.js index e38f46190..1e4c3e940 100644 --- a/src/forge/UsersList/fork_users.js +++ b/src/forge/UsersList/fork_users.js @@ -83,7 +83,7 @@ class ForkUsers extends Component {
    { function goUser(login) { - window.location.href = `/users/${login}`; + window.location.href = `/${login}`; } // 复制链接 diff --git a/src/forge/comments/children_comments.js b/src/forge/comments/children_comments.js index 8a8ccbc80..450a30f13 100644 --- a/src/forge/comments/children_comments.js +++ b/src/forge/comments/children_comments.js @@ -113,7 +113,7 @@ class children_comments extends Component {
    {item && item.user_name} diff --git a/src/forge/comments/children_journals.js b/src/forge/comments/children_journals.js index e293c9f37..2337ce87c 100644 --- a/src/forge/comments/children_journals.js +++ b/src/forge/comments/children_journals.js @@ -77,7 +77,7 @@ class children_journals extends Component {
    {item && item.user_name} diff --git a/src/forge/comments/comments.js b/src/forge/comments/comments.js index 93925da65..a66ea03a1 100644 --- a/src/forge/comments/comments.js +++ b/src/forge/comments/comments.js @@ -304,7 +304,7 @@ class comments extends Component { return (
    {item && item.user_name} diff --git a/src/forge/users/GeneralView/ConcentrateProject.jsx b/src/forge/users/GeneralView/ConcentrateProject.jsx index bfcf290d5..05030b64e 100644 --- a/src/forge/users/GeneralView/ConcentrateProject.jsx +++ b/src/forge/users/GeneralView/ConcentrateProject.jsx @@ -58,7 +58,7 @@ function ConcentrateProject({userLogin,current}) { { list.map((i,k)=>{ return( -
  • +
  • {i.name}

    {i.description}

    diff --git a/src/forge/users/Index.jsx b/src/forge/users/Index.jsx index c7f6fe924..c02820c5d 100644 --- a/src/forge/users/Index.jsx +++ b/src/forge/users/Index.jsx @@ -12,9 +12,7 @@ const Infos = Loadable({ }); export default withRouter( (CNotificationHOC()(SnackbarHOC()(TPMIndexHOC((props)=>{ - console.log(props); return( -
    -
    ) })))) ) \ No newline at end of file diff --git a/src/forge/users/Infos.js b/src/forge/users/Infos.js index bcd011136..bfe0b6b88 100644 --- a/src/forge/users/Infos.js +++ b/src/forge/users/Infos.js @@ -72,22 +72,21 @@ class Infos extends Component { renderPath=(pathname)=>{ const { username } = this.props.match.params; - console.log(username); - if(pathname === `/users/${username}`){ + if(pathname === `/${username}`){ this.setState({menuKey:"0",route_type:undefined}); - }else if(pathname === `/users/${username}/statistics`){ + }else if(pathname === `/${username}/statistics`){ this.setState({menuKey:"1",route_type:undefined}); - }else if(pathname.indexOf(`/users/${username}/projects`)>-1){ + }else if(pathname.indexOf(`/${username}/projects`)>-1){ this.setState({menuKey:"2",route_type:undefined}); - }else if(pathname.indexOf(`/users/${username}/notice`)>-1){ + }else if(pathname.indexOf(`/${username}/notice`)>-1){ this.setState({menuKey:"3",route_type:undefined}); - }else if(pathname.indexOf(`/users/${username}/devops`)>-1){ + }else if(pathname.indexOf(`/${username}/devops`)>-1){ this.setState({menuKey:"4",route_type:undefined}); - }else if(pathname === `/users/${username}/organizes`){ + }else if(pathname === `/${username}/organizes`){ this.setState({menuKey:"5",route_type:undefined}); - }else if(pathname === `/users/${username}/watchers`){ + }else if(pathname === `/${username}/watchers`){ this.setState({menuKey:undefined,route_type:"watchers"}); - }else if(pathname === `/users/${username}/fan_users`){ + }else if(pathname === `/${username}/fan_users`){ this.setState({menuKey:undefined,route_type:"fan_users"}); }else{ this.setState({menuKey:undefined,route_type:undefined}); @@ -147,7 +146,7 @@ class Infos extends Component { project_type: type , route_type: undefined }) - this.props.history.push(`/users/${user && user.login}/devops/${type}`); + this.props.history.push(`/${user && user.login}/devops/${type}`); } undo_link = () => { @@ -156,7 +155,7 @@ class Infos extends Component { route_type: undefined, project_type:"notice", },()=>{ - this.props.history.push(`/users/${user && user.login}/notice`); + this.props.history.push(`/${user && user.login}/notice`); this.fetchUser(); }) } @@ -173,7 +172,7 @@ class Infos extends Component { route_type: undefined, project_type:"organizes" }) - this.props.history.push(`/users/${user && user.login}/organizes`) + this.props.history.push(`/${user && user.login}/organizes`) } resetUser=()=>{ @@ -250,7 +249,7 @@ class Infos extends Component {
  • this.route_link("watchers")} > @@ -258,7 +257,7 @@ class Infos extends Component { {user && user.watching_count} this.route_link("fan_users")} className={`with50 text-center pull-left ${route_type === "fan_users" ? "text-primary" : ""}`} > @@ -281,13 +280,13 @@ class Infos extends Component {
    { !route_type && menuKey && - 概览 - 数据统计 - 项目 + 概览 + 数据统计 + 项目 { current_user && user && user.login === current_user.login ? - + 待办事项 {undo_events && undo_events >0 ? ({undo_events}):""} @@ -295,11 +294,11 @@ class Infos extends Component { } { current_user && current_user.login && current_user.login === username ? - DevOps工作流 + DevOps工作流 :"" } - + 组织 { user && user.user_org_count && user.user_org_count > 0 ? ({user.user_org_count}):""} @@ -309,68 +308,68 @@ class Infos extends Component { {user && ( { return ; }} > { return ; }} > { return ; }} > { return ; }} > { return ; }} > { return ; }} > { return ; }} > { return ; }} > { return ; }} > { return ; }} > { return ; }} diff --git a/src/forge/users/Material/Base.jsx b/src/forge/users/Material/Base.jsx index 6ece348f6..24e92905e 100644 --- a/src/forge/users/Material/Base.jsx +++ b/src/forge/users/Material/Base.jsx @@ -45,7 +45,7 @@ export default Form.create()( if(result && result.data){ props.showNotification("资料修改成功!") resetUser && resetUser(result.data); - props.history.push(`/users/${username}`) + props.history.push(`/${username}`) } }).catch(error=>{}) } @@ -71,7 +71,7 @@ export default Form.create()( {getFieldDecorator("real_name",{ rules:[{required:true,message:"请输入姓名"}] })( - + )}
    @@ -90,7 +90,7 @@ export default Form.create()( {getFieldDecorator("custom_department",{ rules:[{required:true,message:"请输入单位名称"}] })( - + )} @@ -120,13 +120,13 @@ export default Form.create()( {getFieldDecorator("description",{ rules:[] })( -