From 08881d6b6412822d5035f63a0775ca1f213c8668 Mon Sep 17 00:00:00 2001
From: WXL (wul) <wl_5969728@163.com>
Date: 星期一, 20 十月 2025 10:17:22 +0800
Subject: [PATCH] 测试完成
---
src/views/repositoryai/verbaltrick/index.vue | 218 +++++++++++++++++++++++++++++++++++++++++-------------
1 files changed, 165 insertions(+), 53 deletions(-)
diff --git a/src/views/repositoryai/verbaltrick/index.vue b/src/views/repositoryai/verbaltrick/index.vue
index eccc72b..29576cc 100644
--- a/src/views/repositoryai/verbaltrick/index.vue
+++ b/src/views/repositoryai/verbaltrick/index.vue
@@ -4,7 +4,7 @@
<div class="sidecolumn">
<div class="sidecolumn-top">
<div class="top-wj">闂绫诲瀷</div>
- <div class="top-tj" @click="dialogFormVisible = true">+娣诲姞</div>
+ <div class="top-tj" @click="Newcategory">+娣诲姞</div>
</div>
<div class="center-ss">
<el-input
@@ -29,7 +29,7 @@
>
<span class="custom-tree-node" slot-scope="{ node, data }">
<span>{{ node.label }}</span>
- <span>
+ <span v-if="data.id > 0">
<el-button
type="text"
icon="el-icon-delete"
@@ -37,6 +37,17 @@
size="mini"
@click="() => remove(node, data)"
>
+ </el-button>
+ </span>
+ <span v-if="data.id > 0">
+ <el-button
+ type="text"
+ circle
+ size="mini"
+ @click="() => altertag(node, data)"
+ ><span class="button-textxg"
+ ><i class="el-icon-edit-outline"></i
+ ></span>
</el-button>
</span>
</span>
@@ -57,48 +68,26 @@
v-show="showSearch"
label-width="98px"
>
- <el-form-item label="鍙敤闄㈠尯" prop="status">
- <el-select v-model="queryParams.courtyard" placeholder="璇烽�夋嫨">
- <el-option
- v-for="item in languagelist"
- :key="item.value"
- :label="item.label"
- :value="item.value"
- >
- </el-option>
- </el-select>
- </el-form-item>
- <el-form-item label="闂鏍囬" prop="userName">
+ <el-form-item label="闂鏍囬" prop="scriptTopic">
<el-input
- v-model="queryParams.userName"
+ v-model="queryParams.scriptTopic"
placeholder="璇疯緭鍏�"
clearable
style="width: 200px"
@keyup.enter.native="handleQuery"
/>
</el-form-item>
- <el-form-item label="鍏宠仈鎸囨爣" prop="userName">
+ <el-form-item label="鍏宠仈鎸囨爣" prop="targetname">
<el-input
- v-model="queryParams.userName"
+ v-model="queryParams.targetname"
placeholder="璇疯緭鍏�"
clearable
style="width: 200px"
@keyup.enter.native="handleQuery"
/>
- </el-form-item>
- <el-form-item label="閫傜敤鏂瑰紡" prop="status">
- <el-select v-model="queryParams.suitway" placeholder="璇烽�夋嫨">
- <el-option
- v-for="item in mode"
- :key="item.value"
- :label="item.label"
- :value="item.value"
- >
- </el-option>
- </el-select>
</el-form-item>
<el-form-item label="璇█" prop="status">
- <el-select v-model="queryParams.status" placeholder="璇烽�夋嫨">
+ <el-select v-model="queryParams.language" placeholder="璇烽�夋嫨">
<el-option
v-for="item in languagelist"
:key="item.value"
@@ -108,8 +97,11 @@
</el-option>
</el-select>
</el-form-item>
- <el-form-item label="鏄惁鍙敤" prop="status">
- <el-select v-model="queryParams.status" placeholder="璇烽�夋嫨">
+ <el-form-item label="鏄惁鍙敤" prop="isavailable">
+ <el-select
+ v-model="queryParams.isavailable"
+ placeholder="璇烽�夋嫨"
+ >
<el-option
v-for="item in qyoptions"
:key="item.value"
@@ -178,29 +170,23 @@
prop="id"
/>
<el-table-column
- label="闂涓婚"
+ label="闂鏍囬"
fixed
align="center"
- key="questiontitle"
- prop="questiontitle"
+ key="scriptTopic"
+ prop="scriptTopic"
:show-overflow-tooltip="true"
/>
<el-table-column
label="闂鏂囨湰"
align="center"
- key="questiontext"
- prop="questiontext"
+ key="scriptContent"
+ prop="scriptContent"
width="200"
:show-overflow-tooltip="true"
/>
- <el-table-column
- label="闂璇煶"
- align="center"
- key="questionvoice"
- prop="questionvoice"
- width="200"
- /><el-table-column
+ <el-table-column
label="鍏宠仈鎸囨爣"
align="center"
key="targetname"
@@ -217,6 +203,17 @@
>
<template slot-scope="scope">
<dict-tag :options="mode" :value="scope.row.suitway" />
+ </template>
+ </el-table-column>
+ <el-table-column
+ label="闂绫诲瀷"
+ align="center"
+ key="valueType"
+ prop="valueType"
+ width="120"
+ >
+ <template slot-scope="scope">
+ <dict-tag :options="valuetype" :value="scope.row.valueType" />
</template>
</el-table-column>
<el-table-column
@@ -322,11 +319,11 @@
</div>
</div>
<!-- 娣诲姞绫诲埆寮规 -->
- <el-dialog title="鏂板绫诲埆" width="30%" :visible.sync="dialogFormVisible">
+ <el-dialog :title="title" width="30%" :visible.sync="dialogFormVisible">
<div style="text-align: center; margin-bottom: 20px">
<el-radio-group v-model="radio">
- <el-radio-button label="涓诲垎绫�"></el-radio-button>
- <el-radio-button label="瀛愬垎绫�"></el-radio-button>
+ <el-radio-button label="涓诲垎绫�" v-show="zifon"></el-radio-button>
+ <el-radio-button label="瀛愬垎绫�" v-show="zufon"></el-radio-button>
</el-radio-group>
</div>
<el-divider></el-divider>
@@ -351,7 +348,7 @@
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
- <el-button @click="dialogFormVisible = false">鍙� 娑�</el-button>
+ <el-button @click="getDeptTree()">鍙� 娑�</el-button>
<el-button type="primary" @click="submitsidecolumn">纭� 瀹�</el-button>
</div>
</el-dialog>
@@ -403,6 +400,55 @@
<el-button type="primary" @click="confirmillness">纭� 瀹�</el-button>
</span>
</el-dialog>
+ <!-- 闅忚棰樼洰棰勮 -->
+ <el-dialog title="闅忚棰樼洰棰勮" :visible.sync="topicVisible" width="50%">
+ <div class="preview-left">
+ <div v-if="topicform.valueType == 1">
+ <div class="dev-text">
+ [鍗曢�塢<span>{{ topicform.scriptContent }}</span>
+ </div>
+
+ <div class="dev-xx">
+ <el-radio-group v-model="topicform.asrtext">
+ <el-radio
+ v-for="(
+ topicforms, index
+ ) in topicform.ivrLibaScriptTargetoptionList"
+ :key="topicforms.targetvalue"
+ :label="topicforms.targetvalue"
+ >{{ topicforms.targetvalue }}</el-radio
+ >
+ </el-radio-group>
+ </div>
+ </div>
+ <div class="scriptTopic-dev" v-if="topicform.valueType == 2">
+ <div class="dev-text">
+ [澶氶�塢<span>{{ topicform.scriptContent }}</span>
+ </div>
+ <div class="dev-xx">
+ <el-checkbox-group v-model="topicform.remark">
+ <el-checkbox
+ v-for="(
+ topicforms, index
+ ) in topicform.ivrLibaScriptTargetoptionList"
+ :key="topicforms.targetvalue"
+ :label="topicforms.targetvalue"
+ >{{ topicforms.targetvalue }}
+ </el-checkbox>
+ </el-checkbox-group>
+ </div>
+ </div>
+ <div class="scriptTopic-dev" v-if="topicform.valueType == 3">
+ <div class="dev-text">
+ [濉┖]<span>{{ topicform.scriptContent }}</span>
+ </div>
+ <div class="dev-xx">
+ <el-input placeholder="璇疯緭鍏ョ瓟妗�" v-model="radioas" clearable>
+ </el-input>
+ </div>
+ </div>
+ </div>
+ </el-dialog>
</div>
</template>
@@ -410,8 +456,9 @@
import {
getverbaltricklist,
verbaltrickinfo,
- delverbaltrickinfo,
getverbaltrick,
+ delverbaltrickinfo,
+ compileverbaltrickclassify,
getillnesslist,
illnesslistget,
getillness,
@@ -445,9 +492,13 @@
total: 0,
namequestionnaire: "",
haoquestionnaire: "",
+ topicform: {
+ scriptContent: "",
+ },
idds: "",
amendtag: false, //鏄惁淇敼绫诲埆
dialogFormVisible: false, //淇敼娣诲姞绫诲埆寮规
+ topicVisible: false, //棰勮寮规
indexid: null,
inputValue: "",
inputVisible: false,
@@ -476,7 +527,7 @@
},
],
// 寮瑰嚭灞傛爣棰�
- title: "",
+ title: "绫诲埆缂栬緫",
// 鏄惁鏄剧ず寮瑰嚭灞�
open: false,
// 鏃ユ湡鑼冨洿
@@ -495,11 +546,13 @@
indexopen: false, //寮规灞曠ず鍚�
propss: { multiple: true },
radio: "涓诲垎绫�",
-
+ zufon: true,
+ zifon: true,
usable: [],
mode: [],
languagelist: [],
+ valuetype:[],
qyoptions: [],
// 鏌ヨ鍙傛暟
queryParams: {
@@ -521,6 +574,7 @@
this.getDeptTree();
this.mode = store.getters.mode;
this.languagelist = store.getters.languagelist;
+ this.valuetype = store.getters.valuetypelb;
this.qyoptions = store.getters.usable;
},
@@ -583,7 +637,7 @@
handleAdd() {
this.$router.push({
path: "/knowledge/verbaltrick/particulars/",
- query: { id: "" },
+ query: { id: "", categoryid: this.queryParams.categoryid },
});
},
// 鍒嗙被鏍�-----------------------------------------
@@ -597,12 +651,21 @@
getDeptTree() {
getbaltrickclassify({}).then((res) => {
this.deptOptions = res.rows;
- console.log(res);
+ this.dialogFormVisible = false;
});
},
// 娣诲姞绫诲埆鏍�
submitsidecolumn() {
+ if (this.classifyform.id) {
+ compileverbaltrickclassify(this.classifyform).then((res) => {
+ this.getDeptTree();
+ this.$modal.msgSuccess("淇敼鎴愬姛");
+ this.classifyform = {};
+ this.dialogFormVisible = false;
+ });
+ return;
+ }
let calssvalue = {};
if (
this.classifyform.pid &&
@@ -656,6 +719,27 @@
.catch(() => {});
}
},
+ altertag(a, b) {
+ this.dialogFormVisible = true;
+ if (!b.pid) {
+ this.radio = "涓诲垎绫�";
+ this.title = "淇敼涓诲垎绫�";
+ this.zufon = false;
+ } else {
+ this.radio = "瀛愬垎绫�";
+ this.title = "淇敼瀛愬垎绫�";
+ this.zifon = false;
+ }
+ this.classifyform = b;
+ this.dialogFormVisible = true;
+ },
+ Newcategory(){
+ this.classifyform= {}, //绫诲埆琛ㄥ崟
+ this.radio = "涓诲垎绫�";
+ this.dialogFormVisible = true
+ this.zifon = true;
+ this.zufon = true;
+ },
// 绛涢�夎妭鐐�
filterNode(value, data) {
@@ -668,7 +752,13 @@
},
// 棰勮
- preview(row) {},
+ preview(row) {
+ getverbaltrick({ id: row.id }).then((res) => {
+ this.topicform = res.data;
+ console.log(this.topicform);
+ this.topicVisible = true;
+ });
+ },
// 鐤剧梾-----------------------
illnessUpdate(row) {
this.illnessVisible = true;
@@ -910,6 +1000,28 @@
font-size: 20px;
}
}
+.preview-left {
+ margin: 20px;
+ // margin: 20px;
+ padding: 30px;
+ // background: #ffff;
+ border: 1px solid #dcdfe6;
+ -webkit-box-shadow: 0 2px 4px 0 rgba(0, 0, 0, 0.12),
+ 0 0 6px 0 rgba(0, 0, 0, 0.04);
+
+ .dev-text {
+ margin-bottom: 10px;
+ text-align: left;
+ font-size: 22px;
+ }
+ .scriptTopic-dev {
+ margin-bottom: 25px;
+ font-size: 20px !important;
+ .dev-text {
+ margin-bottom: 10px;
+ }
+ }
+}
.button-text {
color: rgb(70, 204, 238);
}
--
Gitblit v1.9.3