Commit 2d180589 by yuananting

fix:灰度调试

parent b3142d23
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
* @Author: yuananting * @Author: yuananting
* @Date: 2021-02-25 13:46:35 * @Date: 2021-02-25 13:46:35
* @LastEditors: yuananting * @LastEditors: yuananting
* @LastEditTime: 2021-03-25 15:39:55 * @LastEditTime: 2021-03-25 16:47:32
* @Description: 助学工具-题库-题目管理-新增题目 * @Description: 助学工具-题库-题目管理-新增题目
* @Copyrigh: © 2020 杭州杰竞科技有限公司 版权所有 * @Copyrigh: © 2020 杭州杰竞科技有限公司 版权所有
*/ */
...@@ -391,6 +391,7 @@ class AddNewQuestion extends Component { ...@@ -391,6 +391,7 @@ class AddNewQuestion extends Component {
}} }}
questionInfo={gapFillingContent} questionInfo={gapFillingContent}
onSetState={(newContent) => { onSetState={(newContent) => {
console.log("newContent填空", newContent)
Object.assign(gapFillingContent, newContent); Object.assign(gapFillingContent, newContent);
}} }}
/> />
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
* @Author: yuananting * @Author: yuananting
* @Date: 2021-02-25 14:34:29 * @Date: 2021-02-25 14:34:29
* @LastEditors: yuananting * @LastEditors: yuananting
* @LastEditTime: 2021-03-25 15:40:18 * @LastEditTime: 2021-03-25 16:46:35
* @Description: 助学工具-题库-题目管理-新建题目Tab * @Description: 助学工具-题库-题目管理-新建题目Tab
* @Copyrigh: © 2020 杭州杰竞科技有限公司 版权所有 * @Copyrigh: © 2020 杭州杰竞科技有限公司 版权所有
*/ */
...@@ -97,6 +97,7 @@ class NewQuestionTab extends Component { ...@@ -97,6 +97,7 @@ class NewQuestionTab extends Component {
const { questionInfo } = nextProps; const { questionInfo } = nextProps;
if (this.props.questionInfo !== questionInfo) { if (this.props.questionInfo !== questionInfo) {
if (questionInfo.gapFillingAnswerList !== this.state.gapFillingAnswer) { if (questionInfo.gapFillingAnswerList !== this.state.gapFillingAnswer) {
console.log("shouldComponentUpdate", questionInfo.gapFillingAnswerList)
this.setState({ this.setState({
gapFillingAnswer: questionInfo.gapFillingAnswerList, gapFillingAnswer: questionInfo.gapFillingAnswerList,
}); });
...@@ -572,8 +573,11 @@ class NewQuestionTab extends Component { ...@@ -572,8 +573,11 @@ class NewQuestionTab extends Component {
} }
changeBlankCount = (data, idx) => { changeBlankCount = (data, idx) => {
console.log("___data___", data)
const { gapFillingAnswer } = this.state; const { gapFillingAnswer } = this.state;
let _gap = [...gapFillingAnswer]; let _gap = [...gapFillingAnswer];
console.log("___changeBlankCount__gapFillingAnswer____", gapFillingAnswer)
console.log("***_gap:111", _gap)
if (data.length <= idx) { if (data.length <= idx) {
_gap.splice(idx, 1); _gap.splice(idx, 1);
} else { } else {
...@@ -595,6 +599,7 @@ class NewQuestionTab extends Component { ...@@ -595,6 +599,7 @@ class NewQuestionTab extends Component {
item.editInput = false; item.editInput = false;
return item; return item;
}); });
console.log("***_gap:222", _gap)
} }
this.setState( this.setState(
......
...@@ -160,6 +160,7 @@ class QuestionEditor extends Component { ...@@ -160,6 +160,7 @@ class QuestionEditor extends Component {
} }
editorRoot.config.onchange = (html) => { editorRoot.config.onchange = (html) => {
console.log("onchange")
const conLen = html.replace(/<(?!img|input).*?>/g, "").length; const conLen = html.replace(/<(?!img|input).*?>/g, "").length;
counter++; counter++;
const { focusFlag } = this.state; const { focusFlag } = this.state;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment