merge-pre_develop_dev

This commit is contained in:
caishi 2021-09-06 14:21:43 +08:00
parent 3f918b53d9
commit be379d39e3
3 changed files with 2 additions and 8 deletions

View File

@ -96,10 +96,6 @@ const ProjectIndex = Loadable({
// 此处仅维护前端可能的一级路由,不用进行项目或者组织判断的字段。
const keyWord = ["explore", "settings", "setting", "CCF", "mulan", "wiki", "issues", "setting", "trending", "code", "projects", "pulls", "mine", "login", "register", "email", "export", "nopage", "404", "403", "500", "501", "search"];
const ProjectIndex = Loadable({
loader: () => import("./forge/Index"),
loading: Loading,
});
class App extends Component {
constructor(props) {
super(props);

View File

@ -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 || 'student'
window.location.search.indexOf('debug=a') !== -1 ? 'admin' : parsed.debug || 'admin'
}
window._debugType = debugType;
export function initAxiosInterceptors(props) {
@ -86,7 +86,7 @@ export function initAxiosInterceptors(props) {
if (response.data.status === 404) {
let responseURL = response.request ? response.request.responseURL:'';
if (responseURL.indexOf('/api/users/') === -1 && responseURL.indexOf('/api/organizations/') === -1 && responseURL.indexOf('/api/owners/') === -1) {
if (responseURL.indexOf('/api/users/') === -1 || responseURL.indexOf('/api/organizations/') === -1 || responseURL.indexOf('/api/owners/') === -1) {
locationurl('/nopage');
}
}

View File

@ -237,14 +237,12 @@ class Setting extends Component {
const { getFieldDecorator } = this.props.form;
const { projectsId , owner } = this.props.match.params;
const { projectDetail } = this.props;
const { projectsId , owner } = this.props.match.params;
const { CategoryList, LanguageList, private_check ,loading , divertVisible , is_transfering, transfer } = this.state;
let mirror = projectDetail && projectDetail.mirror;
let type = projectDetail && projectDetail.type;
const forked_from_project_id = this.props && this.props.projectDetail && this.props.projectDetail.forked_from_project_id;
const { CategoryList, LanguageList, private_check ,loading , divertVisible , permission , is_transfering } = this.state;
return (
<div>
<DivertModal