From 5e4f53570fcbc01e73f0949d56e4990c45c43502 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9D=A8=E6=A0=91=E6=9E=97?= <904079904@qq.com> Date: Fri, 10 Jan 2020 19:15:57 +0800 Subject: [PATCH 1/5] =?UTF-8?q?=E6=B8=85=E7=90=86conslog?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/modules/question/NewMyShixunModel.js | 40 +++++++------- .../react/src/modules/question/Paperreview.js | 18 +++---- .../src/modules/question/Paperreview_item.js | 22 ++++---- .../src/modules/question/Paperreview_items.js | 6 +-- .../modules/question/Paperreview_judgment.js | 2 +- .../modules/question/Paperreview_multlple.js | 2 +- .../modules/question/Paperreview_program.js | 2 +- public/react/src/modules/question/Question.js | 36 ++++++------- .../modules/question/Questionitem_banks.js | 42 +++++++-------- .../question/component/ChoquesEditor.js | 24 ++++----- .../modules/question/component/Contentpart.js | 4 +- .../question/component/Contentquestionbank.js | 10 ++-- .../question/component/Headplugselection.js | 4 +- .../question/component/Headplugselections.js | 17 +++--- .../question/component/IntelligentModel.js | 2 +- .../question/component/Itembankstop.js | 54 +++++++++---------- .../question/component/JudquestionEditor.js | 34 ++++++------ .../question/component/Newknledpots.js | 10 ++-- .../component/Paperreview_itemModel.js | 4 +- .../component/Paperreview_itemModels.js | 4 +- .../modules/question/component/SiderBars.js | 6 +-- .../question/component/SingleEditor.js | 48 ++++++++++------- .../comthetestpaper/Comthetestpaperst.js | 38 ++++++------- .../comthetestpaper/Intelligentcomponents.js | 30 +++++------ .../src/modules/testpaper/Intecomponents.js | 32 +++++------ .../modules/testpaper/Paperlibraryeditid.js | 10 ++-- .../modules/testpaper/Paperlibraryseeid.js | 4 +- .../src/modules/testpaper/Testpaperlibrary.js | 20 +++---- .../component/Contentquestionbank.js | 10 ++-- .../component/Paperlibraryseeid_item.js | 36 ++++++------- .../component/Paperlibraryseeid_itemss.js | 22 ++++---- 31 files changed, 299 insertions(+), 294 deletions(-) diff --git a/public/react/src/modules/question/NewMyShixunModel.js b/public/react/src/modules/question/NewMyShixunModel.js index 8922abd76..232ba9d72 100644 --- a/public/react/src/modules/question/NewMyShixunModel.js +++ b/public/react/src/modules/question/NewMyShixunModel.js @@ -97,7 +97,7 @@ class NewMyShixunModel extends Component { } - setsub_discipline_id=(sub_discipline_id)=>{ + setsub_discipline_id=(discipline_id,sub_discipline_id)=>{ this.setState({ sub_discipline_id:sub_discipline_id, tag_discipline_id:null, @@ -107,7 +107,7 @@ class NewMyShixunModel extends Component { oj_status:null }) var data = { - discipline_id:this.state.discipline_id, + discipline_id:discipline_id, sub_discipline_id:sub_discipline_id, tag_discipline_id:null, public: this.state.defaultActiveKey, @@ -161,8 +161,8 @@ class NewMyShixunModel extends Component { this.callback(defaultActiveKeys); let url = `/users/get_navigation_info.json`; axios.get(url, {}).then((response) => { - // ////console.log("开始请求/get_navigation_info.json"); - // ////console.log(response); + // //////console.log("开始请求/get_navigation_info.json"); + // //////console.log(response); if (response != undefined) { if (response.status === 200) { this.setState({ @@ -180,8 +180,8 @@ class NewMyShixunModel extends Component { axios.get(urls, {params: { source:"question" }}).then((response) => { - console.log("Questiondisciplines"); - console.log(response.data); + //console.log("Questiondisciplines"); + //console.log(response.data); if (response) { this.setState({ disciplinesdata: response.data.disciplines, @@ -254,15 +254,15 @@ class NewMyShixunModel extends Component { } else { } - ////console.log("item_banks"); - ////console.log(response); + //////console.log("item_banks"); + //////console.log(response); this.setState({ Contentdata: response.data, items_count: response.data.items_count, }) this.getdataslen(response.data.items); }).catch((error) => { - ////console.log(error) + //////console.log(error) this.setState({ booljupyterurls:false, }) @@ -288,8 +288,8 @@ class NewMyShixunModel extends Component { } else { } - ////console.log("item_banks"); - ////console.log(response); + //////console.log("item_banks"); + //////console.log(response); this.setState({ Contentdata: response.data, items_count: response.data.items_count, @@ -590,7 +590,7 @@ class NewMyShixunModel extends Component { } }) .catch(function (error) { - //console.log(error); + ////console.log(error); }); } publicopentimu = (id) => { @@ -616,7 +616,7 @@ class NewMyShixunModel extends Component { this.getdata(data); } }).catch((error) => { - //console.log(error); + ////console.log(error); }) } @@ -625,8 +625,8 @@ class NewMyShixunModel extends Component { // const url = "/item_baskets/basket_list.json"; // axios.get(url) // .then((result) => { - // // //console.log("getbasket_listdata"); - // // //console.log(result.data); + // // ////console.log("getbasket_listdata"); + // // ////console.log(result.data); // this.setState({ // completion_questions_count: result.data.completion_questions_count, // judgement_questions_count: result.data.judgement_questions_count, @@ -638,7 +638,7 @@ class NewMyShixunModel extends Component { // }) // // }).catch((error) => { - // // //console.log(error); + // // ////console.log(error); // this.setState({ // completion_questions_count: 0, // judgement_questions_count: 0, @@ -687,7 +687,7 @@ class NewMyShixunModel extends Component { // }) } }).catch((error) => { - //console.log(error); + ////console.log(error); }) } // 撤销 @@ -715,7 +715,7 @@ class NewMyShixunModel extends Component { this.getbasket_listdata(); } }).catch((error) => { - //console.log(error); + ////console.log(error); }) }else{ url=`/examination_banks/${this.props.exam_id}/revoke_item.json`; @@ -741,7 +741,7 @@ class NewMyShixunModel extends Component { this.getbasket_listdata(); } }).catch((error) => { - //console.log(error); + ////console.log(error); }) } @@ -815,7 +815,7 @@ class NewMyShixunModel extends Component { } }) .catch(function (error) { - //console.log(error); + ////console.log(error); }); } diff --git a/public/react/src/modules/question/Paperreview.js b/public/react/src/modules/question/Paperreview.js index b321a40a2..2adc77c03 100644 --- a/public/react/src/modules/question/Paperreview.js +++ b/public/react/src/modules/question/Paperreview.js @@ -67,8 +67,8 @@ class Paperreview extends Component { //初始化 componentDidMount() { - console.log("Paperreview.js"); - console.log(this.props.match.params); + //console.log("Paperreview.js"); + //console.log(this.props.match.params); this.setState({ artificialtype:this.props.match.params.type }) @@ -185,7 +185,7 @@ class Paperreview extends Component { } }).catch((error) => { - ////console.log(error) + //////console.log(error) this.setState({ booljupyterurls: false, }) @@ -238,7 +238,7 @@ class Paperreview extends Component { this.props.history.replace('/paperlibrary'); } }).catch((error) => { - console.log(error); + //console.log(error); }) }else{ @@ -321,12 +321,12 @@ class Paperreview extends Component { axios.post(url, data) .then((result) => { if (result.data.status == 0) { - console.log(result); + //console.log(result); var data = {} this.getdata(data); } }).catch((error) => { - console.log(error); + //console.log(error); }) } //换题 @@ -338,12 +338,12 @@ class Paperreview extends Component { axios.post(url, data) .then((result) => { if (result.data.status == 0) { - console.log(result); + //console.log(result); var data = {} this.getdata(data); } }).catch((error) => { - console.log(error); + //console.log(error); }) } @@ -361,7 +361,7 @@ class Paperreview extends Component { render() { let {page, limit, count, Headertop, visible, placement, modalsType, item_type,artificialtype,Cohetepaperbool,newmyshixunmodelbool,Intelligentformation} = this.state; const params = this.props && this.props.match && this.props.match.params; - // //console.log(params); + // ////console.log(params); return (