Merge branches 'dev_aliyun' and 'new_shixuns_repository' of https://bdgit.educoder.net/Hjqreturn/educoder into new_shixuns_repository

dev_static
杨树明 5 years ago
commit e35dda71f3

@ -1,5 +1,5 @@
class GitsController < ApplicationController
skip_before_action :check_sign
# 说明:
# 以下Git认证只针对新版gitGitlab的Git认证不走该控制器
# 思路:
@ -39,7 +39,7 @@ class GitsController < ApplicationController
# 用户是否对对象拥有权限
system_user = User.find_by_login(input_username) || User.find_by_mail(input_username) || User.find_by_phone(input_username)
# 如果用户名密码错误
if system_user && !system_user.check_password?(input_password)
if system_user.blank? || system_user && !system_user.check_password?(input_password)
uid_logger_error("git start: password is wrong")
result = false
else

@ -41,6 +41,7 @@ class MainContent extends Component {
hideCodeEvaluate = () => {
const vncContainer = this.refs['vncContainer']
if (vncContainer) {
// console.log('点击的关闭按钮')
vncContainer.onBottomDrawerClose && vncContainer.onBottomDrawerClose()
}
}
@ -124,7 +125,7 @@ class MainContent extends Component {
</div>
}
></VNCContainer>
<div id="actionView" className="-layout-h -center -bg-grey-90 -grey-20 -bg-darkblack" style={{height:'48px'}}>
<div id="actionView" className="-layout-h -center -bg-grey-90 -grey-20 -bg-darkblack">
<ActionView {...this.props}
onRunCodeTest={onRunCodeTest}
></ActionView>
@ -179,7 +180,9 @@ class MainContent extends Component {
</div>
</div>
<div id="actionView" className="-layout-h -center -bg-grey-90 -grey-20 -bg-darkblack" style={{height:'48px'}}>
<div id="actionView"
style={{ position: 'absolute', width: '100%', bottom: '0', height: '51px'}}
className="-layout-h -center -bg-grey-90 -grey-20 -bg-darkblack">
<ActionView {...this.props} onRunCodeTest={onRunCodeTest}></ActionView>
</div>

@ -39,6 +39,47 @@
user-select: none;
}
.btn_test_case,
.btn_test_case_active{
display: inline-block;
position: absolute;
width: 56px;
height: 28px;
bottom: 23px;
line-height: 28px;
background: rgba(42,58,79,1);
z-index: 10;
left: 50%;
margin-left: -28px;
border-bottom-left-radius: 100px;
border-bottom-right-radius: 100px;
color: #fff;
text-align: center;
cursor: pointer;
opacity: .4;
transition: all .3s;
}
.btn_test_case:hover,
.btn_test_case_active:hover{
opacity: 1;
}
.btn_test_case .btn-arrow{
position: relative;
font-size: 12px;
line-height: 28px;
bottom: 2px;
}
.btn_test_case_active{
bottom: 203px;
z-index: 10000;
}
.btn_test_case_active .btn-arrow{
bottom: 4px;
}
@keyframes mymove
{
from {right:0px;}

@ -204,6 +204,10 @@ class VNCContainer extends Component {
render() {
const { challenge, vnc_url, git_url } = this.props
const _classCtx = this.state.bottomDrawer ? 'btn_test_case_active' : 'btn_test_case';
const _classes = this.state.bottomDrawer
? `iconfont icon-xiajiantou btn-arrow`
: 'iconfont icon-shangjiantou btn-arrow';
const secondDrawerChildren = this.renderSecondDrawerChildren();
return (
<React.Fragment>
@ -352,9 +356,16 @@ class VNCContainer extends Component {
>
{ this.props.codeEvaluate }
</Drawer>
<FloatButton onClick={this.swtichBottomDrawer}
{/* <FloatButton onClick={this.swtichBottomDrawer}
className="codeEvaluateFloatButton"
>测试集</FloatButton>
>测试集</FloatButton> */}
<div
className={_classCtx}
onClick={this.swtichBottomDrawer}
>
{/* <span className="iconfont icon-shangjiantou btn-arrow"></span> */}
<span className={_classes}></span>
</div>
</VNCDisplay>

@ -135,11 +135,13 @@ class VNCDisplay extends Component {
<div className="vncDisply" style={{height: '100%'}}>
<style>{`
.vncDisply #top_bar {
position: absolute;
background-color: #6e84a3;
color: white;
font: bold 12px Helvetica;
padding: 6px 5px 4px 5px;
border-bottom: 1px outset;
width: 100%;
}
.vncDisply #status {
text-align: center;
@ -166,7 +168,7 @@ class VNCDisplay extends Component {
<div id="status">Loading</div>
<div id="sendCtrlAltDelButton">Send CtrlAltDel</div>
</div>
<div id="screen">
<div id="screen" style={{ height: 'calc(100vh - 105px)' }}>
</div>
{this.props.children}

Loading…
Cancel
Save