Merge branch 'dev_aliyun' into dev_Ysm

dev_hs
cxt 6 years ago
commit d89c483532

@ -694,12 +694,12 @@ class CoursesController < ApplicationController
if order == 1
# REDO:Extension
@students = @students.includes(user: :user_extension).order("user_extensions.student_id")
@students = @students.includes(user: :user_extension).order("user_extensions.student_id, course_members.id")
elsif order == 2
@students = @students.includes(:course_group).order("course_groups.position")
@students = @students.includes(:course_group).order("course_groups.position, course_members.id")
else
# REDO:Extension
@students = @students.includes(user: :user_extension).order("user_extensions.student_id")
@students = @students.includes(user: :user_extension).order("user_extensions.student_id, course_members.id")
end
if course_group_id.present?
@ -927,10 +927,10 @@ class CoursesController < ApplicationController
return normal_status(-1, "课堂已结束,无法加入") if course.is_end
# 实名认证和职业认证的身份判断
return normal_status(-1, "该课堂要求成员完成实名和职业认证") if course.authentication &&
course.professional_certification && (!current_user.authentication || !current_user.professional_certification)
return normal_status(-1, "该课堂要求成员完成实名认证") if course.authentication && !current_user.authentication
return normal_status(-1, "该课堂要求成员完成职业认证") if course.professional_certification && !current_user.professional_certification
return normal_status(-2, "该课堂要求成员完成实名和职业认证") if course.authentication &&
course.professional_certification && (!current_user.authentication && !current_user.professional_certification)
return normal_status(-2, "该课堂要求成员完成实名认证") if course.authentication && !current_user.authentication
return normal_status(-2, "该课堂要求成员完成职业认证") if course.professional_certification && !current_user.professional_certification
# 身份验证
if params[:professor].blank? && params[:assistant_professor].blank? && params[:student].blank?

@ -461,11 +461,7 @@ class Selectsetting extends Component{
</ul>
<div className="pl20 pr20"
style={{"Height":"204px"}}>
<style>{`
<style>{`
.color-grey-9a{color: #9A9A9A !important;}
.datastyle{
width: 120px;
@ -480,7 +476,12 @@ class Selectsetting extends Component{
display: inline-block;
float: left;
}
.settingbox{
max-height: 123px;
overflow-y: auto;
}
`}</style>
<div className="pl20 pr20 settingbox">
<div className="clearfix edu-txt-center lineh-40 bor-bottom-greyE">
<li className="fl" style={{width: '241px'}}>
<span className={"isabox"} title={datalist&&datalist.title}> {datalist&&datalist.title} </span>
@ -632,7 +633,7 @@ class Selectsetting extends Component{
{this.state.newfileListtypes===true?<p className={"color-red"}>请先上传资源</p>:""}
<p className={"winth540"}>
<p className={this.state.fileListtype===true?"mt15":""}>
<style>{`
.ant-checkbox-wrapper{
margin-left:0px !important;
@ -640,19 +641,19 @@ class Selectsetting extends Component{
}
`}</style>
<div className={this.state.fileListtype===true?"mt30":""}>
<Checkbox
checked={is_public}
onChange={this.onChangepublics}>
<span className={"font-14"}>勾选后所有用户可见否则仅课堂成员可见</span>
</Checkbox>
</div>
{/*<div className={this.state.fileListtype===true?"mt30":""}>*/}
{/*<Checkbox*/}
{/*checked={is_public}*/}
{/*onChange={this.onChangepublics}>*/}
{/*<span className={"font-14"}>勾选后所有用户可见,否则仅课堂成员可见</span>*/}
{/*</Checkbox>*/}
{/*</div>*/}
{/*{this.props.has_course_groups&&this.props.has_course_groups===true?:""}*/}
{/*{this.state.course_groupss&&this.state.course_groupss.length>0?<Checkbox*/}
{/*checked={unified_setting}*/}
{/*onChange={this.onChangesettings}>*/}
{/*<span>统一设置</span><span className={"font-14 color-grey-9"}>(选中则所有分班使用相同的发布设置,否则各个单独设置)</span>*/}
{/*</Checkbox>:""}*/}
{this.state.course_groupss&&this.state.course_groupss.length>0?<Checkbox
checked={unified_setting}
onChange={this.onChangesettings}>
<span>统一设置</span><span className={"font-14 color-grey-9"}>(使)</span>
</Checkbox>:""}
<style>
{`
@ -744,6 +745,7 @@ class Selectsetting extends Component{
{/*{this.state.course_group_idtypes===true?<p className={"color-red"}>请选择分班</p>:""}*/}
{/*{course_group_publish_timestype===true?<p className={"color-red mt10"}>请填写完整</p>:""}*/}
<textarea placeholder="请输入资源描述最大限制100个字符" className={"mt10"} value={description} onInput={this.settextarea} style={{
width: '100%',
height:'120px',

@ -469,7 +469,7 @@ class Sendresource extends Component{
{newfileListtype===true&&this.state.fileListtype===false?<p className={"color-red"}>请先上传资源</p>:""}
<p className={"winth540"}>
<p className={this.state.fileListtype===true?"mt25":""}>
<style>{`
.ant-checkbox-wrapper{
margin-left:0px !important;
@ -477,13 +477,13 @@ class Sendresource extends Component{
}
`}</style>
<div className={this.state.fileListtype===true?"mt30":""}></div><Checkbox checked={is_public} onChange={this.onChangepublic}>
<span className={"font-14"}>勾选后所有用户可见否则仅课堂成员可见</span>
</Checkbox>
{/*<div className={this.state.fileListtype===true?"mt30":""}></div><Checkbox checked={is_public} onChange={this.onChangepublic}>*/}
{/*<span className={"font-14"}>勾选后所有用户可见,否则仅课堂成员可见</span>*/}
{/*</Checkbox>*/}
{/*{this.state.course_groups_count&&this.state.course_groups_count>0?<Checkbox checked={is_unified_setting} onChange={this.onChangesetting}>*/}
{/*<span>统一设置</span><span className={"font-14 color-grey-9"}>(选中则所有分班使用相同的发布设置,否则各个单独设置)</span>*/}
{/*</Checkbox>:""}*/}
{this.state.course_groups_count&&this.state.course_groups_count>0?<Checkbox checked={is_unified_setting} onChange={this.onChangesetting}>
<span>统一设置</span><span className={"font-14 color-grey-9"}>(使)</span>
</Checkbox>:""}
<style>{`
.Selectleft20{
margin-left: 20px !important;

@ -234,15 +234,15 @@ class InfosPackage extends Component{
</div>
<div className="item-other">
<div className="item-group item-other-visit">
<span className="item-group-icon"><i className="fa fa-eye"></i></span>
<span className="item-group-icon mr10"><i className="fa fa-eye"></i></span>
<span className="item-group-text">{item.visit_count}人浏览</span>
</div>
<div className="item-group item-other-deadline">
<span className="item-group-icon"><i className="fa fa-clock-o"></i></span>
<span className="item-group-icon mr10"><i className="fa fa-clock-o"></i></span>
<span className="item-group-text">{moment(item.deadline_at).format("YYYY-MM-DD HH:mm")}竞标截止</span>
</div>
<div className="item-group item-other-bidding pagemancenter">
<span className="item-group-icon"><i className="fa fa-user"></i></span>
<span className="item-group-icon mr10"><i className="fa fa-user"></i></span>
<span className="item-group-text">{item.bidding_users_count}人竞标</span>
</div>
<div className="item-group item-other-publish-at">

Loading…
Cancel
Save