forked from Gitlink/forgeplus-react
before merge
This commit is contained in:
parent
d6b1da7971
commit
622715919e
|
@ -0,0 +1,317 @@
|
|||
{
|
||||
"auto_complete":
|
||||
{
|
||||
"selected_items":
|
||||
[
|
||||
[
|
||||
"samp",
|
||||
"samp2_method"
|
||||
],
|
||||
[
|
||||
"modu",
|
||||
"module_method"
|
||||
],
|
||||
[
|
||||
"cu",
|
||||
"currentTerm"
|
||||
],
|
||||
[
|
||||
"req",
|
||||
"requestVote"
|
||||
],
|
||||
[
|
||||
"reque",
|
||||
"RequestVote"
|
||||
],
|
||||
[
|
||||
"App",
|
||||
"AppendEntries"
|
||||
],
|
||||
[
|
||||
"hea",
|
||||
"heartBeatInterval"
|
||||
],
|
||||
[
|
||||
"time",
|
||||
"timeOut"
|
||||
],
|
||||
[
|
||||
"ele",
|
||||
"electionTimeout"
|
||||
],
|
||||
[
|
||||
"R",
|
||||
"Raft"
|
||||
],
|
||||
[
|
||||
"vote",
|
||||
"votedFor"
|
||||
],
|
||||
[
|
||||
"Ra",
|
||||
"RaftState"
|
||||
],
|
||||
[
|
||||
"is",
|
||||
"isleader"
|
||||
]
|
||||
]
|
||||
},
|
||||
"buffers":
|
||||
[
|
||||
{
|
||||
"file": "src/redux/actions/actionTypes.js",
|
||||
"settings":
|
||||
{
|
||||
"buffer_size": 5688,
|
||||
"encoding": "UTF-8",
|
||||
"line_ending": "Unix"
|
||||
}
|
||||
}
|
||||
],
|
||||
"build_system": "",
|
||||
"build_system_choices":
|
||||
[
|
||||
],
|
||||
"build_varint": "",
|
||||
"command_palette":
|
||||
{
|
||||
"height": 0.0,
|
||||
"last_filter": "",
|
||||
"selected_items":
|
||||
[
|
||||
],
|
||||
"width": 0.0
|
||||
},
|
||||
"console":
|
||||
{
|
||||
"height": 171.0,
|
||||
"history":
|
||||
[
|
||||
"ls"
|
||||
]
|
||||
},
|
||||
"distraction_free":
|
||||
{
|
||||
"menu_visible": true,
|
||||
"show_minimap": false,
|
||||
"show_open_files": false,
|
||||
"show_tabs": false,
|
||||
"side_bar_visible": false,
|
||||
"status_bar_visible": false
|
||||
},
|
||||
"expanded_folders":
|
||||
[
|
||||
"/home/qyzh/new_trustie/forgeplus-react"
|
||||
],
|
||||
"file_history":
|
||||
[
|
||||
"/home/qyzh/OSS/forgeplus/app/models/user.rb",
|
||||
"/home/qyzh/OSS/forgeplus/db/structure.sql",
|
||||
"/home/qyzh/OSS/forgeplus/app/controllers/settings_controller.rb",
|
||||
"/home/qyzh/OSS/forgeplus/app/controllers/application_controller.rb",
|
||||
"/home/qyzh/OSS/Trustie/app/controllers/projects_controller.rb",
|
||||
"/home/qyzh/temp.sh",
|
||||
"/home/qyzh/OSS/Trustie/Gemfile",
|
||||
"/home/qyzh/.npm/_logs/2020-06-07T02_42_06_886Z-debug.log",
|
||||
"/home/qyzh/OSS/forgeplus/app/controllers/users_controller.rb",
|
||||
"/home/qyzh/OSS/forgeplus/app/controllers/accounts_controller.rb",
|
||||
"/home/qyzh/custom/conf/app.ini",
|
||||
"/home/qyzh/OSS/Trustie_old/Gemfile.lock",
|
||||
"/home/qyzh/OSS/Trustie/Gemfile.lock",
|
||||
"/home/qyzh/ruby_study/test.rb",
|
||||
"/home/qyzh/RubymineProjects/myblog/app/controller/users_controller.rb",
|
||||
"/home/qyzh/OSS/forgeplus/app/libs/limit_forbid_control.rb",
|
||||
"/home/qyzh/OSS/forgeplus/log/development.log",
|
||||
"/home/qyzh/NJU-DisSys-2017/src/raft/raft.go",
|
||||
"/home/qyzh/OSS/forgeplus/config/application.rb",
|
||||
"/home/qyzh/RubymineProjects/demo/app/helpers/welcome_helper.rb",
|
||||
"/home/qyzh/RubymineProjects/demo/app/controllers/welcome_controller.rb",
|
||||
"/home/qyzh/RubymineProjects/demo/config/routes.rb",
|
||||
"/home/qyzh/RubymineProjects/demo/app/views/welcome/index.html.erb",
|
||||
"/home/qyzh/trustie/Gemfile",
|
||||
"/home/qyzh/trustie/Gemfile.lock",
|
||||
"/home/qyzh/ruby_study/test",
|
||||
"/home/qyzh/NJU-DisSys-2017/src/labrpc/test_test.go",
|
||||
"/home/qyzh/NJU-DisSys-2017/src/labrpc/labrpc.go",
|
||||
"/home/qyzh/NJU-DisSys-2017/src/raft/test_test.go",
|
||||
"/home/qyzh/NJU-DisSys-2017/src/raft/persister.go",
|
||||
"/home/qyzh/NJU-DisSys-2017/src/raft/util.go",
|
||||
"/home/qyzh/NJU-DisSys-2017/src/raft/config.go"
|
||||
],
|
||||
"find":
|
||||
{
|
||||
"height": 29.0
|
||||
},
|
||||
"find_in_files":
|
||||
{
|
||||
"height": 0.0,
|
||||
"where_history":
|
||||
[
|
||||
]
|
||||
},
|
||||
"find_state":
|
||||
{
|
||||
"case_sensitive": true,
|
||||
"find_history":
|
||||
[
|
||||
"current_user",
|
||||
"user_set",
|
||||
"login",
|
||||
"platform",
|
||||
"Platform不包含于列表中",
|
||||
"find_by_",
|
||||
"find_by",
|
||||
"3.2.22",
|
||||
"bug",
|
||||
"persister",
|
||||
"currentTerm",
|
||||
"currentTern",
|
||||
"term",
|
||||
"your",
|
||||
"electionInterval",
|
||||
"your",
|
||||
"if",
|
||||
"your",
|
||||
"Persister",
|
||||
"make",
|
||||
"Your code here",
|
||||
"Call",
|
||||
"labrpc",
|
||||
"main"
|
||||
],
|
||||
"highlight": true,
|
||||
"in_selection": false,
|
||||
"preserve_case": false,
|
||||
"regex": false,
|
||||
"replace_history":
|
||||
[
|
||||
],
|
||||
"reverse": false,
|
||||
"show_context": true,
|
||||
"use_buffer2": true,
|
||||
"whole_word": false,
|
||||
"wrap": true
|
||||
},
|
||||
"groups":
|
||||
[
|
||||
{
|
||||
"selected": 0,
|
||||
"sheets":
|
||||
[
|
||||
{
|
||||
"buffer": 0,
|
||||
"file": "src/redux/actions/actionTypes.js",
|
||||
"semi_transient": false,
|
||||
"settings":
|
||||
{
|
||||
"buffer_size": 5688,
|
||||
"regions":
|
||||
{
|
||||
},
|
||||
"selection":
|
||||
[
|
||||
[
|
||||
0,
|
||||
0
|
||||
]
|
||||
],
|
||||
"settings":
|
||||
{
|
||||
"syntax": "Packages/JavaScript/JavaScript.sublime-syntax",
|
||||
"tab_size": 2,
|
||||
"translate_tabs_to_spaces": true
|
||||
},
|
||||
"translation.x": 0.0,
|
||||
"translation.y": 0.0,
|
||||
"zoom_level": 1.0
|
||||
},
|
||||
"stack_index": 0,
|
||||
"type": "text"
|
||||
}
|
||||
]
|
||||
}
|
||||
],
|
||||
"incremental_find":
|
||||
{
|
||||
"height": 29.0
|
||||
},
|
||||
"input":
|
||||
{
|
||||
"height": 0.0
|
||||
},
|
||||
"layout":
|
||||
{
|
||||
"cells":
|
||||
[
|
||||
[
|
||||
0,
|
||||
0,
|
||||
1,
|
||||
1
|
||||
]
|
||||
],
|
||||
"cols":
|
||||
[
|
||||
0.0,
|
||||
1.0
|
||||
],
|
||||
"rows":
|
||||
[
|
||||
0.0,
|
||||
1.0
|
||||
]
|
||||
},
|
||||
"menu_visible": true,
|
||||
"output.find_results":
|
||||
{
|
||||
"height": 0.0
|
||||
},
|
||||
"pinned_build_system": "",
|
||||
"project": "forgeplus-react.sublime-project",
|
||||
"replace":
|
||||
{
|
||||
"height": 54.0
|
||||
},
|
||||
"save_all_on_build": true,
|
||||
"select_file":
|
||||
{
|
||||
"height": 0.0,
|
||||
"last_filter": "",
|
||||
"selected_items":
|
||||
[
|
||||
],
|
||||
"width": 0.0
|
||||
},
|
||||
"select_project":
|
||||
{
|
||||
"height": 0.0,
|
||||
"last_filter": "",
|
||||
"selected_items":
|
||||
[
|
||||
],
|
||||
"width": 0.0
|
||||
},
|
||||
"select_symbol":
|
||||
{
|
||||
"height": 0.0,
|
||||
"last_filter": "",
|
||||
"selected_items":
|
||||
[
|
||||
],
|
||||
"width": 0.0
|
||||
},
|
||||
"selected_group": 0,
|
||||
"settings":
|
||||
{
|
||||
},
|
||||
"show_minimap": true,
|
||||
"show_open_files": false,
|
||||
"show_tabs": true,
|
||||
"side_bar_visible": true,
|
||||
"side_bar_width": 288.0,
|
||||
"status_bar_visible": true,
|
||||
"template_settings":
|
||||
{
|
||||
}
|
||||
}
|
10
src/App.js
10
src/App.js
|
@ -81,6 +81,11 @@ const OrganizeIndex = Loadable({
|
|||
loader: () => import('./forge/Team/Index'),
|
||||
loading: Loading,
|
||||
})
|
||||
// Sponsor
|
||||
const Sponsor = Loadable({
|
||||
loader: () => import('./forge/sponsor/Sponsor'),
|
||||
loading: Loading,
|
||||
})
|
||||
|
||||
class App extends Component {
|
||||
constructor(props) {
|
||||
|
@ -270,6 +275,11 @@ class App extends Component {
|
|||
return (<InfosIndex {...this.props} {...props} {...this.state} />)
|
||||
}
|
||||
}></Route>
|
||||
<Route exact path="/sponsor/:username"
|
||||
render={
|
||||
(props) => (<Sponsor {...this.props} {...props} {...this.state}></Sponsor>)
|
||||
}>
|
||||
</Route>
|
||||
<Route exact path="/"
|
||||
render={
|
||||
(props) => (<Projects {...this.props} {...props} {...this.state}></Projects>)
|
||||
|
|
|
@ -0,0 +1,32 @@
|
|||
import React, { Component } from "react";
|
||||
|
||||
import { Route, Switch } from "react-router-dom";
|
||||
import { withRouter } from "react-router";
|
||||
|
||||
import { SnackbarHOC } from "educoder";
|
||||
import { CNotificationHOC } from "../../modules/courses/common/CNotificationHOC";
|
||||
import { TPMIndexHOC } from "../../modules/tpm/TPMIndexHOC";
|
||||
|
||||
|
||||
import Loadable from "react-loadable";
|
||||
import Loading from "../../Loading";
|
||||
import { ImageLayerOfCommentHOC } from "../../modules/page/layers/ImageLayerOfCommentHOC";
|
||||
|
||||
class Sponsor extends Component {
|
||||
|
||||
render(){
|
||||
return (
|
||||
<p>This is sponsor page</p>
|
||||
);
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
export default withRouter(
|
||||
ImageLayerOfCommentHOC({
|
||||
imgSelector: ".imageLayerParent img, .imageLayerParent .imageTarget",
|
||||
parentSelector: ".newMain",
|
||||
})(CNotificationHOC()(SnackbarHOC()(TPMIndexHOC(Sponsor))))
|
||||
);
|
||||
|
|
@ -113,6 +113,14 @@ class Infos extends Component {
|
|||
this.props.history.push(`/users/${user && user.login}/organizes`)
|
||||
}
|
||||
|
||||
sponsor_link = () => {
|
||||
const {user} = this.state
|
||||
this.setState({
|
||||
route_type: undefined
|
||||
})
|
||||
this.props.history.push(`/sponsor/${user && user.login}`)
|
||||
}
|
||||
|
||||
|
||||
render() {
|
||||
const { current_user, mygetHelmetapi } = this.props;
|
||||
|
@ -240,6 +248,21 @@ class Infos extends Component {
|
|||
</p>
|
||||
</div>
|
||||
</div>
|
||||
{current_user && user && current_user.id === user.id && (
|
||||
<div className="bgcF">
|
||||
<div className="list-l-Menu">
|
||||
<p className="list-l-p pd20" onClick={() => this.sponsor_link()} >
|
||||
<span className="font-16 color-grey-3">
|
||||
{/* <i className="iconfont icon-itsm-liuchengguanli font-15 mr5"></i> */}
|
||||
Sponsor
|
||||
</span>
|
||||
{/* <span className="color-blue font-16">
|
||||
{user && user.undo_events}
|
||||
</span> */}
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
)}
|
||||
</div>
|
||||
<div className="list-right">
|
||||
{user && (
|
||||
|
|
Loading…
Reference in New Issue