diff --git a/src/AppConfig.js b/src/AppConfig.js index 36c1529d..73f3a38e 100644 --- a/src/AppConfig.js +++ b/src/AppConfig.js @@ -25,7 +25,7 @@ if (isDev) { } debugType = window.location.search.indexOf('debug=t') !== -1 ? 'teacher' : window.location.search.indexOf('debug=s') !== -1 ? 'student' : - window.location.search.indexOf('debug=a') !== -1 ? 'admin' : parsed.debug || 'admin' + window.location.search.indexOf('debug=a') !== -1 ? 'admin' : parsed.debug || 'student' } window._debugType = debugType; export function initAxiosInterceptors(props) { diff --git a/src/forge/users/GeneralView/Index.jsx b/src/forge/users/GeneralView/Index.jsx index 8fd8d0a0..24efe37c 100644 --- a/src/forge/users/GeneralView/Index.jsx +++ b/src/forge/users/GeneralView/Index.jsx @@ -48,6 +48,7 @@ function Index(props) { // 在贡献度日历表中选择一个时间 function chooseTime(data) { if(data){ + setPage(1); setActivityDate(data[0]); } } diff --git a/src/forge/users/Infos.js b/src/forge/users/Infos.js index 525a2b82..cd33bf13 100644 --- a/src/forge/users/Infos.js +++ b/src/forge/users/Infos.js @@ -1,6 +1,6 @@ import React, { Component } from "react"; import { Link } from "react-router-dom"; -import { Avatar, Tag, Button, Spin , Menu } from "antd"; +import { Button, Spin , Menu } from "antd"; import FocusButton from "../UsersList/focus_button"; import axios from "axios"; @@ -14,7 +14,10 @@ import './Index.scss'; import Loadable from "react-loadable"; import Loading from "../../Loading"; - +const UpdateInfo = Loadable({ + loader: () => import("./Material/Index"), + loading: Loading, +}); const InfosDevOps = Loadable({ loader: () => import("./devOpsCI"), loading: Loading, @@ -134,20 +137,6 @@ class Infos extends Component { }) } - // change_project_type = (type) => { - // const {user} = this.state - // this.setState({ - // project_type: type , - // route_type: undefined - // }) - // let url = `/users/${user && user.login}` - // if (type){ - // url = `/users/${user && user.login}/projects/${type}` - // } - // this.props.history.push(url) - - // }; - change_devops_type=(type)=>{ const {user} = this.state; this.setState({ @@ -209,16 +198,25 @@ class Infos extends Component {