askbot-dragon 88.0.9 → 88.0.11
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
|
@@ -36,6 +36,7 @@
|
|
|
36
36
|
|
|
37
37
|
<!-- <text-message :text="text" @submitClick="submitClick"></text-message> -->
|
|
38
38
|
<answer-docknowledge :isAskLightning="2" :msg="answerDocknowledge"></answer-docknowledge>
|
|
39
|
+
<welcomeSuggest :msg="welcomeSuggest"></welcomeSuggest>
|
|
39
40
|
<!-- <voice-component @closeVoice="closeVoice">
|
|
40
41
|
<div slot="voiceTip">
|
|
41
42
|
松开发送
|
|
@@ -43,7 +44,7 @@
|
|
|
43
44
|
</voice-component>-->
|
|
44
45
|
<!-- 点选 -->
|
|
45
46
|
<!-- <div v-html="htmlContainer"></div> -->
|
|
46
|
-
|
|
47
|
+
<answer-radio :msg="answerRadios"></answer-radio>
|
|
47
48
|
<!-- <ticket-message :content="updateTicetmessageObj"></ticket-message> -->
|
|
48
49
|
<!-- <ticket-message :content="contents"></ticket-message> -->
|
|
49
50
|
<!--
|
|
@@ -71,7 +72,7 @@
|
|
|
71
72
|
<welcome-llm-card v-else-if="item.type === 'welcome_llm_card'" :msgContent="item.content"></welcome-llm-card>
|
|
72
73
|
</div> -->
|
|
73
74
|
<!-- <answer-voice @stopOtherAudio="stopOtherAudio" ref="audioTagCell" :msg="answerVoiceObj1"></answer-voice> -->
|
|
74
|
-
|
|
75
|
+
|
|
75
76
|
<!-- <FileType :urls="urls" :color="black"></FileType>-->
|
|
76
77
|
<!-- <FileType :urls="urls" :color="black"></FileType>
|
|
77
78
|
<chat-content :messageList="messageList"></chat-content> -->
|
|
@@ -117,6 +118,7 @@ import AnswerVoice from "@/components/AnswerVoice";
|
|
|
117
118
|
import AnswerDocknowledge from "./AnswerDocknowledge.vue";
|
|
118
119
|
import WelcomeKnowledgeFile from "./welcomeKnowledgeFile";
|
|
119
120
|
import WelcomeLlmCard from "./welcomeLlmCard";
|
|
121
|
+
import welcomeSuggest from "./welcomeSuggest"
|
|
120
122
|
export default {
|
|
121
123
|
name: 'ConversationContainer',
|
|
122
124
|
components: {
|
|
@@ -145,7 +147,8 @@ export default {
|
|
|
145
147
|
// FileType,
|
|
146
148
|
// ChatContent,
|
|
147
149
|
AnswerDocknowledge,
|
|
148
|
-
MyEditor
|
|
150
|
+
MyEditor,
|
|
151
|
+
welcomeSuggest
|
|
149
152
|
},
|
|
150
153
|
props: {
|
|
151
154
|
messages: Array
|
|
@@ -153,6 +156,37 @@ export default {
|
|
|
153
156
|
data() {
|
|
154
157
|
return {
|
|
155
158
|
black: '',
|
|
159
|
+
welcomeSuggest:{
|
|
160
|
+
content:{
|
|
161
|
+
"problemRecommendationValue": [
|
|
162
|
+
"工作不了了呢为什么1",
|
|
163
|
+
"工作不了了呢为什么2",
|
|
164
|
+
"工作不了了呢为什么3",
|
|
165
|
+
"工作不了了呢为什么4",
|
|
166
|
+
"工作不了了呢为什么5",
|
|
167
|
+
"工作不了了呢为什么6",
|
|
168
|
+
"工作不了了呢为什么7",
|
|
169
|
+
"工作不了了呢为什么8",
|
|
170
|
+
"工作不了了呢为什么9",
|
|
171
|
+
"工作不了了呢为什么10",
|
|
172
|
+
"工作不了了呢为什么11",
|
|
173
|
+
"工作不了了呢为什么12",
|
|
174
|
+
"工作不了了呢为什么13"
|
|
175
|
+
],
|
|
176
|
+
"actionType": "SEND_CONTENT",
|
|
177
|
+
"pageCount": 3,
|
|
178
|
+
"enableProblemRecommendation": true,
|
|
179
|
+
"problemRecommendationDesc": "您还可以这样问我",
|
|
180
|
+
"icon": "https://static.guoranbot.com/cdn-office-website/askbot_doc/mmt-cell-img-m1.png",
|
|
181
|
+
"description": "打印机不工作了,如何维修",
|
|
182
|
+
"page": true,
|
|
183
|
+
"scopes": [],
|
|
184
|
+
"title": "解决日常办公问题,寻求帮助",
|
|
185
|
+
"value": [
|
|
186
|
+
"打印机不工作了,如何维修"
|
|
187
|
+
]
|
|
188
|
+
}
|
|
189
|
+
},
|
|
156
190
|
answerVoiceObj: {
|
|
157
191
|
"actionCategory": "START_NODE",
|
|
158
192
|
"apiKey": "81d9d6c3f13d4e1aa239cacee3192475",
|
|
@@ -52,6 +52,7 @@
|
|
|
52
52
|
<div class="summaryBtn"
|
|
53
53
|
:class="showSummary ? 'summaryActiveBtn' : ''"
|
|
54
54
|
@click="summaryFun"
|
|
55
|
+
v-if="isHasChat"
|
|
55
56
|
>
|
|
56
57
|
<i class="iconfont guoran-tongyichicun-write-29-jiqiren"></i>
|
|
57
58
|
<span>智能摘要</span>
|
|
@@ -73,7 +74,7 @@
|
|
|
73
74
|
</div>
|
|
74
75
|
<div id="drawer_content_pre">
|
|
75
76
|
<intelligent-summary
|
|
76
|
-
v-show="showSummary"
|
|
77
|
+
v-show="showSummary && isHasChat"
|
|
77
78
|
:knowledgeId="knowledgeId"
|
|
78
79
|
@closeSummary="closeSummary"
|
|
79
80
|
@recommendQues="recommendQues"
|
|
@@ -0,0 +1,98 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<div class="welcome_suggest">
|
|
3
|
+
<div class="title">
|
|
4
|
+
<div class="title_desc">{{ msg.content.problemRecommendationDesc }}</div>
|
|
5
|
+
<div class="title_change_batch" v-if="msg.content.page && msg.content.problemRecommendationValue.length > msg.content.pageCount" @click="changeBatch">
|
|
6
|
+
<i class="iconfont guoran-tongyichicun-huanyipi"></i>
|
|
7
|
+
<span>换一批</span>
|
|
8
|
+
</div>
|
|
9
|
+
</div>
|
|
10
|
+
<div class="content">
|
|
11
|
+
<div
|
|
12
|
+
class="welcome_item"
|
|
13
|
+
v-for="(item,index) in suggestList"
|
|
14
|
+
:key="index"
|
|
15
|
+
@click="handleWelcome(item)"
|
|
16
|
+
>{{ item }}</div>
|
|
17
|
+
</div>
|
|
18
|
+
<div class></div>
|
|
19
|
+
</div>
|
|
20
|
+
</template>
|
|
21
|
+
<script>
|
|
22
|
+
export default {
|
|
23
|
+
props: ["msg"],
|
|
24
|
+
data () {
|
|
25
|
+
return {
|
|
26
|
+
pageCount: 1,
|
|
27
|
+
suggestList: []
|
|
28
|
+
}
|
|
29
|
+
},
|
|
30
|
+
mounted () {
|
|
31
|
+
if(this.msg.content.page) {
|
|
32
|
+
this.changeBatch()
|
|
33
|
+
} else {
|
|
34
|
+
this.suggestList = this.msg.content.problemRecommendationValue
|
|
35
|
+
}
|
|
36
|
+
},
|
|
37
|
+
methods: {
|
|
38
|
+
changeBatch () {
|
|
39
|
+
let msgSuggestList = JSON.parse(JSON.stringify(this.msg.content.problemRecommendationValue))
|
|
40
|
+
this.suggestList = msgSuggestList.splice((this.pageCount - 1) * this.msg.content.pageCount, this.msg.content.pageCount)
|
|
41
|
+
if (this.pageCount == Math.ceil(this.msg.content.problemRecommendationValue.length / this.msg.content.pageCount)) {
|
|
42
|
+
this.pageCount = 1
|
|
43
|
+
} else {
|
|
44
|
+
this.pageCount = this.pageCount + 1
|
|
45
|
+
}
|
|
46
|
+
},
|
|
47
|
+
handleWelcome (item) {
|
|
48
|
+
this.$emit('handleWelcome', item)
|
|
49
|
+
}
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
</script>
|
|
53
|
+
<style lang="less" scoped>
|
|
54
|
+
.welcome_suggest {
|
|
55
|
+
width: 100%;
|
|
56
|
+
height: auto;
|
|
57
|
+
.title {
|
|
58
|
+
width: 100%;
|
|
59
|
+
height: 28px;
|
|
60
|
+
display: flex;
|
|
61
|
+
align-items: center;
|
|
62
|
+
justify-content: space-between;
|
|
63
|
+
.title_desc {
|
|
64
|
+
flex: 1 0;
|
|
65
|
+
overflow: hidden;
|
|
66
|
+
text-overflow: ellipsis;
|
|
67
|
+
white-space: nowrap;
|
|
68
|
+
}
|
|
69
|
+
.title_change_batch {
|
|
70
|
+
cursor: pointer;
|
|
71
|
+
color: #366aff;
|
|
72
|
+
height: 28px;
|
|
73
|
+
width: 70px;
|
|
74
|
+
display: flex;
|
|
75
|
+
align-items: center;
|
|
76
|
+
font-size: 14px;
|
|
77
|
+
i {
|
|
78
|
+
margin-right: 5px;
|
|
79
|
+
}
|
|
80
|
+
}
|
|
81
|
+
}
|
|
82
|
+
.content {
|
|
83
|
+
display: flex;
|
|
84
|
+
align-items: center;
|
|
85
|
+
flex-wrap: wrap;
|
|
86
|
+
margin-top: 8px;
|
|
87
|
+
.welcome_item {
|
|
88
|
+
padding: 3px 8px;
|
|
89
|
+
background: #EEF1FF;
|
|
90
|
+
color: #366aff;
|
|
91
|
+
margin-right: 5px;
|
|
92
|
+
margin-bottom: 5px;
|
|
93
|
+
border-radius: 28px;
|
|
94
|
+
cursor: pointer;
|
|
95
|
+
}
|
|
96
|
+
}
|
|
97
|
+
}
|
|
98
|
+
</style>
|