From cc73ea5320fed8a39e00bfc0fa02810199559122 Mon Sep 17 00:00:00 2001 From: WXL <1785969728@qq.com> Date: 星期二, 16 七月 2024 15:55:40 +0800 Subject: [PATCH] 测试完成 --- src/views/repositoryai/verbaltrick/particulars/index.vue | 157 ++++++++++++++++++++++++++++++++-------------------- 1 files changed, 96 insertions(+), 61 deletions(-) diff --git a/src/views/repositoryai/verbaltrick/particulars/index.vue b/src/views/repositoryai/verbaltrick/particulars/index.vue index f239964..14a7cbf 100644 --- a/src/views/repositoryai/verbaltrick/particulars/index.vue +++ b/src/views/repositoryai/verbaltrick/particulars/index.vue @@ -104,9 +104,9 @@ </el-row> <el-row :gutter="20"> <el-col :span="20"> - <el-form-item label="闂涓绘棬" prop="questiontitle"> + <el-form-item label="闂涓绘棬" prop="scriptTopic"> <el-input - v-model="indexform.questiontitle" + v-model="indexform.scriptTopic" placeholder="璇疯緭鍏ラ棶棰樹富鏃�" maxlength="80" /> @@ -154,40 +154,46 @@ > </div> </el-form-item> - <el-form-item label="閫氱煡鍙橀噺" prop="name"> - <div style="margin-bottom: 5px" v-for="item in variablelist"> - <el-row> - <el-col :span="5"> - <el-input - v-model="item.variatename" - placeholder="璇疯緭鍏ュ彉閲忓悕" - ></el-input> - </el-col> - <el-col :span="8" :offset="1"> - <el-input - v-model="item.variate" - placeholder="璇疯緭鍏ュ彉閲忓唴瀹�" - ></el-input> - </el-col> - <el-col :span="8" :offset="1"> - <el-button - type="success" - icon="el-icon-plus" - circle - @click="addvariable(item)" - ></el-button> - <el-button - v-if="!item.default" - type="danger" - icon="el-icon-delete" - circle - @click="delvariable(item)" - ></el-button> - </el-col> - </el-row> - </div> - </el-form-item> - + <el-drawer + title="鍙橀噺缂栬緫" + :visible.sync="variabledeawer" + direction="ttb" + size="35%" + > + <el-form-item label="閫氱煡鍙橀噺" prop="name"> + <div style="margin-bottom: 5px" v-for="item in variablelist"> + <el-row> + <el-col :span="5"> + <el-input + v-model="item.variatename" + placeholder="璇疯緭鍏ュ彉閲忓悕" + ></el-input> + </el-col> + <el-col :span="8" :offset="1"> + <el-input + v-model="item.variate" + placeholder="璇疯緭鍏ュ彉閲忓唴瀹�" + ></el-input> + </el-col> + <el-col :span="8" :offset="1"> + <el-button + type="success" + icon="el-icon-plus" + circle + @click="addvariable(item)" + ></el-button> + <el-button + v-if="!item.default" + type="danger" + icon="el-icon-delete" + circle + @click="delvariable(item)" + ></el-button> + </el-col> + </el-row> + </div> + </el-form-item> + </el-drawer> <el-row> <el-col :span="6"> <el-form-item label="浠呴檺闄㈠尯" prop="region"> @@ -250,30 +256,33 @@ </el-row> <el-row> <el-col :span="24"> - <div - style="display: flex; margin-left: 100px; margin-bottom: 10px" - > - <div - v-for="item in variablelist" - class="tsgname" - @click="tsgnameto(item)" - > - {{ item.variatename }} + <el-form-item label="闂鍙橀噺" prop="scriptContent"> + <div style="display: flex; margin-bottom: 10px"> + <div + v-for="item in variablelist" + class="tsgname" + @click="tsgnameto(item)" + > + {{ item.variatename }} + </div> + <div class="tsgnamebj" @click="variabledeawer = true"> + 鍙橀噺缂栬緫 + </div> </div> - </div> + </el-form-item> </el-col></el-row > <el-row> <el-col :span="24"> - <el-form-item label="闂鏂囨湰" prop="questionText"> + <el-form-item label="闂鏂囨湰" prop="scriptContent"> <el-input - :rows="2" + :rows="2" type="textarea" - id="questionText" + id="scriptContent" show-word-limit placeholder="璇疯緭鍏ュ唴瀹�" - v-model.sync="indexform.questionText" - @focus="handleInput('questionText')" + v-model.sync="indexform.scriptContent" + @focus="handleInput('scriptContent')" /> </el-form-item> </el-col ></el-row> @@ -404,12 +413,21 @@ label-width="100px" > <el-row> - <el-col :span="12"> + <el-col :span="8"> <el-form-item label="鎸囨爣鍚嶇О" prop="deptId"> <el-input v-model="indexform.targetname" placeholder="璇疯緭鍏ユ寚鏍囧悕绉�" - maxlength="40" + maxlength="20" + /> + </el-form-item> + </el-col> + <el-col :span="12"> + <el-form-item label="鎸囨爣鎻忚堪" prop="deptId"> + <el-input + v-model="indexform.targetdesc" + placeholder="璇疯緭鍏ユ寚鏍囨弿杩�" + maxlength="60" /> </el-form-item> </el-col> @@ -418,7 +436,7 @@ <el-row> <el-col :span="24"> <el-form-item label="鍊肩被鍨�"> - <el-radio-group v-model="indexform.valueType"> + <el-radio-group disabled v-model="indexform.valueType"> <el-radio :label="1">閫夐」</el-radio> <el-radio :label="2">鏂囨湰</el-radio> <el-radio :label="3">鏁板��</el-radio> @@ -434,6 +452,7 @@ @deloption="deloption" @syioption="syioption" @xiayioption="xiayioption" + :intent="false" /> </el-card> <el-row :gutter="20"> @@ -558,6 +577,7 @@ deptId: undefined, IDnumber: undefined, }, + variabledeawer: false, }; }, @@ -674,13 +694,13 @@ .confirm('鏄惁娣诲姞"' + res.rows[0].targetname + '"鎸囨爣鐨勯�夐」锛�') .then(() => { this.indexform.valueType = res.rows[0].valueType; - this.indexform.questiontitle = res.rows[0].targetname; + this.indexform.scriptTopic = res.rows[0].targetname; this.indexform.targetname = res.rows[0].targetname; - this.indexform.questionText = res.rows[0].targetdesc; + this.indexform.targetdesc = res.rows[0].targetdesc; this.indexform.isAvailable = "0"; this.indexform.language = "鏅�氳瘽"; this.indexform.isenable = res.rows[0].isenable; - this.$forceUpdate() + this.$forceUpdate(); res.rows[0].targetoptionList.forEach((item) => { item.isoperation = 1; this.indexform.ivrLibaScriptTargetoptionList.push(item); @@ -891,8 +911,8 @@ let inputValueArr = ""; let el = document.querySelector("#" + this.currentInputId); //el.selectionStart; 杩欏氨鏄綋鍓嶅厜鏍囨墍鍦ㄧ殑浣嶇疆锛堝瓧绗︿覆涓瓧绗︾殑index锛� - if (this.currentInputId == "questionText") { - inputValueArr = this.indexform.questionText.split(""); + if (this.currentInputId == "scriptContent") { + inputValueArr = this.indexform.scriptContent.split(""); } else if (this.currentInputId == "noMatchText") { inputValueArr = this.indexform.noMatchText.split(""); } else if (this.currentInputId == "slienceText") { @@ -913,8 +933,8 @@ // 鎶婃暟缁勯噸鏂拌浆鎹负瀛楃涓插苟璧嬪�� inputValueArr = inputValueArr.join(""); console.log(inputValueArr); - if (this.currentInputId == "questionText") { - this.indexform.questionText = inputValueArr; + if (this.currentInputId == "scriptContent") { + this.indexform.scriptContent = inputValueArr; } else if (this.currentInputId == "noMatchText") { this.indexform.noMatchText = inputValueArr; } else if (this.currentInputId == "slienceText") { @@ -1028,6 +1048,21 @@ .tsgname:hover { background: #3366f5; } +.tsgnamebj { + width: 90px; + margin-left: 15px; + text-align: center; + cursor: pointer; + height: 40px; + line-height: 40px; + background: #49dbb7; + color: #ffff; + font-size: 18px; + border-radius: 5px; +} +.tsgnamebj:hover { + background: #27c449; +} ::v-deep .addtopic-input { input { -- Gitblit v1.9.3