dev_aliyun2
杨树林 5 years ago committed by harry
parent 22cba4b17b
commit 2834ce5eb6

@ -13,6 +13,7 @@ import JudquestionEditor from "./component/JudquestionEditor";
import Bottomsubmit from "../../modules/modals/Bottomsubmit";
import { connect } from 'react-redux';
import actions from "../../redux/actions";
var restricte=false;
class Questionitem_banks extends Component {
constructor(props) {
super(props);
@ -28,7 +29,8 @@ class Questionitem_banks extends Component {
knowledgepoints: [],
disciplmy:[],
pages:1,
}
}
}
@ -300,6 +302,7 @@ class Questionitem_banks extends Component {
.then((result) => {
if (result.data.status == 0) {
// this.props.showNotification(`新增单选题成功`);
this.restricte=true;
this.props.history.replace('/question');
}
@ -311,6 +314,7 @@ class Questionitem_banks extends Component {
.then((result) => {
if (result.data.status == 0) {
// this.props.showNotification(`编辑单选题成功`);
this.restricte=true;
this.props.history.replace('/question');
@ -378,6 +382,7 @@ class Questionitem_banks extends Component {
.then((result) => {
if (result.data.status == 0) {
// this.props.showNotification(`新增多选题成功`);
this.restricte=true;
this.props.history.replace('/question');
@ -391,6 +396,7 @@ class Questionitem_banks extends Component {
.then((result) => {
if (result.data.status == 0) {
// this.props.showNotification(`编辑多选题成功`);
this.restricte=true;
this.props.history.replace('/question');
@ -445,6 +451,7 @@ class Questionitem_banks extends Component {
.then((result) => {
if (result.data.status == 0) {
// this.props.showNotification(`新增判断题成功`);
this.restricte=true;
this.props.history.replace('/question');
}
@ -457,6 +464,7 @@ class Questionitem_banks extends Component {
.then((result) => {
if (result.data.status == 0) {
// this.props.showNotification(`编辑判断题成功`);
this.restricte=true;
this.props.history.replace('/question');
}
@ -489,10 +497,12 @@ class Questionitem_banks extends Component {
let arrays=myrbkc.join(',');
// console.log("开始打印了");
// console.log(arrays);
// window.open( `/problems/new?difficult=${Getdatasdata[0].rbnd}&sub_discipline_id=${Getdatasdata[3].rbkc[1]}&tag_discipline_id=${arrays}&newoj=1&pages=${this.state.pages}`);
this.props.history.replace( `/problems/new?difficult=${Getdatasdata[0].rbnd}&sub_discipline_id=${Getdatasdata[3].rbkc[1]}&tag_discipline_id=${arrays}&newoj=1&pages=${this.state.pages}`);
this.restricte=true;
window.open(`/problems/new?difficult=${Getdatasdata[0].rbnd}&sub_discipline_id=${Getdatasdata[3].rbkc[1]}&tag_discipline_id=${arrays}&newoj=1&pages=${this.state.pages}`);
setTimeout(() => {
this.restricte=true;
}, 1000);
// this.props.history.replace( `/problems/new?difficult=${Getdatasdata[0].rbnd}&sub_discipline_id=${Getdatasdata[3].rbkc[1]}&tag_discipline_id=${arrays}&newoj=1&pages=${this.state.pages}`);
}
@ -508,24 +518,30 @@ class Questionitem_banks extends Component {
}
render() {
let { page, limit, count, Headertop, visible, placement, modalsType, item_type } = this.state;
let {page, limit, count, Headertop, visible, placement, modalsType, item_type,restricte} = this.state;
const params = this.props && this.props.match && this.props.match.params;
// ////console.log(params);
return (
<div>
<div id={"Itembankstopid"} className="newMain clearfix intermediatecenter "
>
<Prompt
when={true}
message={() => '你确定离开此页面吗?'}
/>
{
restricte===false?
<Prompt
when={true}
message={() => '你确定离开此页面吗?'}
/>
:
""
}
<style>
{
`
body{
width: 100%!important;
}
.newFooter{
display: none;

Loading…
Cancel
Save