Merge branch 'dev_item_bank' of http://bdgit.educoder.net/Hjqreturn/educoder into dev_item_bank
commit
0433b7a72a
@ -0,0 +1,20 @@
|
|||||||
|
class ModifyCourseGroupForCourses < ActiveRecord::Migration[5.2]
|
||||||
|
def change
|
||||||
|
groups = CourseGroup.where(course_id:3429).order("created_at desc").group(:name)
|
||||||
|
ActiveRecord::Base.transaction do
|
||||||
|
groups.each do |g|
|
||||||
|
CourseGroup.where(name: g.name).where.not(id: g.id).each do |cg|
|
||||||
|
cg.course_members.each do |cm|
|
||||||
|
cm.update_attributes!(course_group_id: g.id)
|
||||||
|
end
|
||||||
|
cg.exercise_group_settings.update_all(course_group_id: g.id)
|
||||||
|
cg.attachment_group_settings.update_all(course_group_id: g.id)
|
||||||
|
cg.homework_group_reviews.update_all(course_group_id: g.id)
|
||||||
|
cg.homework_group_settings.update_all(course_group_id: g.id)
|
||||||
|
cg.teacher_course_groups.update_all(course_group_id: g.id)
|
||||||
|
cg.destroy!
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
After Width: | Height: | Size: 3.6 KiB |
File diff suppressed because one or more lines are too long
Binary file not shown.
File diff suppressed because one or more lines are too long
Before Width: | Height: | Size: 375 KiB After Width: | Height: | Size: 381 KiB |
Binary file not shown.
Binary file not shown.
Binary file not shown.
@ -0,0 +1,43 @@
|
|||||||
|
import React, { Component } from 'react';
|
||||||
|
import {getImageUrl} from 'educoder';
|
||||||
|
import { Modal} from 'antd';
|
||||||
|
import axios from 'axios';
|
||||||
|
import './../testioncss/testioncss.css'
|
||||||
|
//立即申请试用
|
||||||
|
class QuestionModal extends Component {
|
||||||
|
|
||||||
|
constructor(props) {
|
||||||
|
super(props);
|
||||||
|
this.state={
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
render() {
|
||||||
|
|
||||||
|
return(
|
||||||
|
<Modal
|
||||||
|
keyboard={false}
|
||||||
|
closable={false}
|
||||||
|
footer={null}
|
||||||
|
destroyOnClose={true}
|
||||||
|
title="提示"
|
||||||
|
centered={true}
|
||||||
|
visible={this.props.modalsType===undefined?false:this.props.modalsType}
|
||||||
|
width="442px"
|
||||||
|
>
|
||||||
|
<div className="educouddiv">
|
||||||
|
<div className={"tabeltext-alignleft mt10"}><p className="titiles">{this.props.titilesm}</p></div>
|
||||||
|
<div className={"tabeltext-alignleft mt10"}><p className="titiles">{this.props.titiless}</p></div>
|
||||||
|
<div className="clearfix mt30 edu-txt-center">
|
||||||
|
<a className="task-btn mr30 w80" onClick={()=>this.props.modalCancel()}>取消</a>
|
||||||
|
<a className="task-btn task-btn-orange w80" onClick={()=>this.props.setDownload()}>确定</a>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</Modal>
|
||||||
|
)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
export default QuestionModal;
|
@ -0,0 +1,66 @@
|
|||||||
|
import React, { Component } from 'react';
|
||||||
|
import {getImageUrl} from 'educoder';
|
||||||
|
import { Modal} from 'antd';
|
||||||
|
import axios from 'axios';
|
||||||
|
import './../testioncss/testioncss.css'
|
||||||
|
//立即申请试用
|
||||||
|
class QuestionModals extends Component {
|
||||||
|
|
||||||
|
constructor(props) {
|
||||||
|
super(props);
|
||||||
|
this.state={
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
render() {
|
||||||
|
|
||||||
|
return(
|
||||||
|
<Modal
|
||||||
|
keyboard={false}
|
||||||
|
closable={false}
|
||||||
|
footer={null}
|
||||||
|
destroyOnClose={true}
|
||||||
|
title="提示"
|
||||||
|
centered={true}
|
||||||
|
visible={this.props.modalsTypes===undefined?false:this.props.modalsTypes}
|
||||||
|
width="442px"
|
||||||
|
>
|
||||||
|
<div className="educouddiv">
|
||||||
|
<div className={"tabeltext-alignleft mt10"}><p className="titiles">是否删除试题栏中{
|
||||||
|
|
||||||
|
this.props.titilesms&&this.props.titilesms==="SINGLE"?
|
||||||
|
"单选题"
|
||||||
|
:
|
||||||
|
this.props.titilesms&&this.props.titilesms==="MULTIPLE"?
|
||||||
|
"多选题"
|
||||||
|
:
|
||||||
|
this.props.titilesms&&this.props.titilesms==="JUDGMENT"?
|
||||||
|
"判断题"
|
||||||
|
:
|
||||||
|
this.props.titilesms&&this.props.titilesms==="COMPLETION"?
|
||||||
|
"填空题"
|
||||||
|
:
|
||||||
|
this.props.titilesms&&this.props.titilesms==="SUBJECTIVE"?
|
||||||
|
"简答题"
|
||||||
|
:
|
||||||
|
this.props.titilesms&&this.props.titilesms==="PROGRAM"?
|
||||||
|
"编程题"
|
||||||
|
:
|
||||||
|
this.props.titilesms&&this.props.titilesms==="PRACTICAL"?
|
||||||
|
"实训题"
|
||||||
|
:""
|
||||||
|
|
||||||
|
}</p></div>
|
||||||
|
<div className="clearfix mt30 edu-txt-center">
|
||||||
|
<a className="task-btn mr30 w80" onClick={()=>this.props.modalCancels()}>取消</a>
|
||||||
|
<a className="task-btn task-btn-orange w80" onClick={()=>this.props.setDownloads(this.props.titilesms)}>确定</a>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</Modal>
|
||||||
|
)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
export default QuestionModals;
|
File diff suppressed because one or more lines are too long
Binary file not shown.
File diff suppressed because one or more lines are too long
Before Width: | Height: | Size: 374 KiB After Width: | Height: | Size: 381 KiB |
Binary file not shown.
Binary file not shown.
Binary file not shown.
Loading…
Reference in new issue