|
@@ -580,7 +580,7 @@ export default {
|
|
|
// 获取本课的 本教材的 本套的 的例句
|
|
|
getContent(Mname, {
|
|
|
courseware_id: this.currentTreeID, // 课件id
|
|
|
- word: this.data.new_word, //生词
|
|
|
+ word: this.data.new_word_str, //生词
|
|
|
search_scope: 0, //检索范围0 本课件 1本教材 2本套
|
|
|
is_contain_word_variants: false,
|
|
|
is_filter_repetitive_sentence: "true",
|
|
@@ -1015,12 +1015,12 @@ export default {
|
|
|
//生命周期 - 创建完成(可以访问当前this实例)
|
|
|
created() {
|
|
|
// 去掉生词里的标点
|
|
|
- let new_word_str = "";
|
|
|
- for (let i = 0; i < this.data.new_word.length; i++) {
|
|
|
- if (/[\u4E00-\u9FA5\uF900-\uFA2D]/.test(this.data.new_word[i])) {
|
|
|
- new_word_str += this.data.new_word[i];
|
|
|
- }
|
|
|
- }
|
|
|
+ let new_word_str = this.data.new_word.replace(/\(.*?\)/g, "");
|
|
|
+ // for (let i = 0; i < this.data.new_word.length; i++) {
|
|
|
+ // if (/[\u4E00-\u9FA5\uF900-\uFA2D]/.test(this.data.new_word[i])) {
|
|
|
+ // new_word_str += JSON.parse(JSON.stringify(this.data.new_word[i]));
|
|
|
+ // }
|
|
|
+ // }
|
|
|
this.data.new_word_str = new_word_str;
|
|
|
},
|
|
|
//生命周期 - 挂载完成(可以访问DOM元素)
|