Commit b203ab1e by liuchenxi

update: 添加变量

parent 117ada51
......@@ -432,7 +432,7 @@ export default {
},
// 向短信内容中插入模板变量
addVar(key, val) {
const curPos = this.$refs['textarea'].$el.firstChild.firstChild.selectionStart;
const curPos = this.$refs['textarea'].$el.children[0].selectionStart;
let curContent = this.form.content;
this.form.content = curContent.slice(0, curPos) + `{${key}}` + curContent.slice(curPos, curContent.length);
this.templateVisbile = false;
......
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