diff --git a/public/react/src/modules/question/Question.js b/public/react/src/modules/question/Question.js index 204ed6280..b53fd7b5a 100644 --- a/public/react/src/modules/question/Question.js +++ b/public/react/src/modules/question/Question.js @@ -52,7 +52,7 @@ class Question extends Component { single_questions_count: 0, subjective_questions_count: 0, page:1, - per_page:20, + per_page:10, disciplinesdata:[], discipline_id:null, sub_discipline_id:null, @@ -78,7 +78,7 @@ class Question extends Component { item_type: this.state.item_type, keywords: this.state.keywords, page: this.state.page, - per_page:20, + per_page:10, }; this.getdata(data); @@ -98,7 +98,7 @@ class Question extends Component { item_type: this.state.item_type, keywords: this.state.keywords, page: this.state.page, - per_page:20, + per_page:10, }; this.getdata(data); } @@ -116,7 +116,7 @@ class Question extends Component { item_type: this.state.item_type, keywords: this.state.keywords, page: this.state.page, - per_page:20, + per_page:10, }; this.getdata(data); } @@ -130,7 +130,7 @@ class Question extends Component { tag_discipline_id:this.state.tag_discipline_id, public: defaultActiveKey, page:1, - per_page:20, + per_page:10, }; this.getdata(data); @@ -161,33 +161,6 @@ class Question extends Component { this.setState({ disciplinesdata: response.data.disciplines, }) - const didata = response.data.disciplines; - var kc=0; - var zsd=0; - - for (var i = 0; i < didata.length; i++) { - //方向 - const fxdidata = didata[i].sub_disciplines; - for (var j = 0; j < fxdidata.length; j++) { - kc=kc+1; - //课程 - const zsddata = fxdidata[j].tag_disciplines; - for (var k = 0; k < zsddata.length; k++) { - //知识点 - zsd=zsd+1; - - } - } - - - } - - this.setState({ - disciplinesdata: response.data.disciplines, - disciplinesdatakc:kc, - disciplinesdatazsd:zsd, - }) - } }); } @@ -204,7 +177,7 @@ class Question extends Component { item_type: this.state.item_type, difficulty: this.state.difficulty, page: this.state.page, - per_page:20, + per_page:10, }; this.getdata(data); @@ -257,7 +230,7 @@ class Question extends Component { item_type: this.state.item_type, keywords: this.state.keywords, page: pageNumber, - per_page:20, + per_page:10, }; this.getdata(data); } @@ -361,7 +334,7 @@ class Question extends Component { difficulty: difficulty, item_type: this.state.item_type, page: this.state.page, - per_page:20, + per_page:10, }; this.getdata(data); @@ -381,7 +354,7 @@ class Question extends Component { difficulty: this.state.difficulty, item_type: item_type, page: this.state.page, - per_page:20, + per_page:10, }; this.getdata(data); @@ -428,7 +401,7 @@ class Question extends Component { item_type: this.state.item_type, keywords: e.target.value, page: this.state.page, - per_page:20, + per_page:10, }; this.getdata(data); @@ -447,7 +420,7 @@ class Question extends Component { item_type: this.state.item_type, keywords: value, page: this.state.page, - per_page:20, + per_page:10, }; this.getdata(data); @@ -470,7 +443,7 @@ class Question extends Component { item_type: this.state.item_type, keywords: this.state.keywords, page: this.state.page, - per_page:20, + per_page:10, }; this.getdata(data); } @@ -495,7 +468,7 @@ class Question extends Component { item_type: this.state.item_type, keywords: this.state.keywords, page: this.state.page, - per_page:20, + per_page:10, }; this.getdata(data); } @@ -555,7 +528,7 @@ class Question extends Component { item_type: this.state.item_type, keywords: this.state.keywords, page: this.state.page, - per_page:20, + per_page:10, }; this.getdata(data); this.getbasket_listdata(); @@ -585,7 +558,7 @@ class Question extends Component { item_type: this.state.item_type, keywords: this.state.keywords, page: this.state.page, - per_page:20, + per_page:10, }; this.getdata(data); this.getbasket_listdata(); @@ -626,7 +599,7 @@ class Question extends Component { item_type: this.state.item_type, keywords: this.state.keywords, page: this.state.page, - per_page:20, + per_page:10, }; this.getdata(data); this.getbasket_listdata(); @@ -724,7 +697,7 @@ class Question extends Component { {/*