askbot-dragon 1.6.80-beta → 1.6.82-beta

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.
Files changed (101) hide show
  1. package/README.md +27 -27
  2. package/babel.config.js +6 -6
  3. package/dragon.iml +7 -7
  4. package/package.json +55 -55
  5. package/public/index.html +72 -72
  6. package/src/App.vue +31 -31
  7. package/src/api/index.js +1 -1
  8. package/src/api/mock.http +2 -2
  9. package/src/api/requestUrl.js +185 -185
  10. package/src/assets/image/default_avt_ui.png +0 -0
  11. package/src/assets/image/filtType/audio.png +0 -0
  12. package/src/assets/image/filtType/excel1.png +0 -0
  13. package/src/assets/image/filtType/general.png +0 -0
  14. package/src/assets/image/filtType/image1.png +0 -0
  15. package/src/assets/image/filtType/link.png +0 -0
  16. package/src/assets/image/filtType/md2.png +0 -0
  17. package/src/assets/image/filtType/mode.png +0 -0
  18. package/src/assets/image/filtType/news.png +0 -0
  19. package/src/assets/image/filtType/pdf1.png +0 -0
  20. package/src/assets/image/filtType/ppt1.png +0 -0
  21. package/src/assets/image/filtType/selfadd1.png +0 -0
  22. package/src/assets/image/filtType/txt1.png +0 -0
  23. package/src/assets/image/filtType/video.png +0 -0
  24. package/src/assets/image/filtType/wechat.png +0 -0
  25. package/src/assets/image/filtType/word1.png +0 -0
  26. package/src/assets/image/loading.gif +0 -0
  27. package/src/assets/js/AliyunlssUtil.js +92 -92
  28. package/src/assets/js/Base64Util.js +22 -22
  29. package/src/assets/js/common.js +252 -252
  30. package/src/assets/js/hammer.js +89 -100
  31. package/src/assets/js/script.js +36 -36
  32. package/src/assets/less/common.css +6773 -6773
  33. package/src/assets/less/converSationContainer/common.less +192 -199
  34. package/src/assets/less/converSationContainer/converSatonContainer.less +493 -493
  35. package/src/assets/less/iconfont.css +37 -37
  36. package/src/assets/less/ticketMessage.less +294 -294
  37. package/src/components/ActionAlertIframe.vue +154 -177
  38. package/src/components/AiGuide.vue +468 -466
  39. package/src/components/AnswerDocknowledge.vue +1068 -1061
  40. package/src/components/AnswerVoice.vue +285 -285
  41. package/src/components/AskIFrame.vue +15 -15
  42. package/src/components/ConversationContainer.vue +5140 -4934
  43. package/src/components/FileType.vue +86 -86
  44. package/src/components/Message.vue +27 -27
  45. package/src/components/MyEditor.vue +350 -351
  46. package/src/components/actionSatisfaction.vue +107 -107
  47. package/src/components/actionSendToBot.vue +62 -62
  48. package/src/components/answerDissatisfaction.vue +62 -62
  49. package/src/components/answerRadio.vue +186 -186
  50. package/src/components/ask-components/DissatisfactionOptions.vue +57 -57
  51. package/src/components/ask-components/Msgloading.vue +37 -37
  52. package/src/components/ask-components/SatisfactionV2.vue +15 -15
  53. package/src/components/askVideo.vue +139 -162
  54. package/src/components/assetDetails.vue +378 -378
  55. package/src/components/assetMessage.vue +228 -228
  56. package/src/components/associationIntention.vue +374 -355
  57. package/src/components/attachmentPreview.vue +90 -90
  58. package/src/components/botActionSatisfactor.vue +68 -68
  59. package/src/components/chatContent.vue +513 -513
  60. package/src/components/feedBack.vue +136 -136
  61. package/src/components/fielListView.vue +351 -351
  62. package/src/components/file/AliyunOssComponents.vue +108 -108
  63. package/src/components/formTemplate.vue +3572 -3572
  64. package/src/components/intelligentSummary.vue +227 -231
  65. package/src/components/kkview.vue +1138 -1138
  66. package/src/components/loadingProcess.vue +164 -164
  67. package/src/components/message/ActionAlertIframe.vue +112 -112
  68. package/src/components/message/ShopMessage.vue +164 -164
  69. package/src/components/message/TextMessage.vue +924 -924
  70. package/src/components/message/TicketMessage.vue +201 -201
  71. package/src/components/message/swiper/index.js +4 -4
  72. package/src/components/message/swiper/ticketSwiper.vue +503 -503
  73. package/src/components/message/swiper/ticketSwiperItem.vue +61 -61
  74. package/src/components/msgLoading.vue +231 -231
  75. package/src/components/myPopup.vue +70 -70
  76. package/src/components/pdfPosition.vue +1334 -1508
  77. package/src/components/popup.vue +227 -227
  78. package/src/components/previewDoc.vue +247 -247
  79. package/src/components/previewPdf.vue +779 -799
  80. package/src/components/receiverMessagePlatform.vue +65 -65
  81. package/src/components/recommend.vue +80 -80
  82. package/src/components/selector/hOption.vue +20 -20
  83. package/src/components/selector/hSelector.vue +199 -199
  84. package/src/components/selector/hWrapper.vue +216 -216
  85. package/src/components/senderMessagePlatform.vue +50 -50
  86. package/src/components/source/BotMessage.vue +24 -24
  87. package/src/components/source/CustomMessage.vue +24 -24
  88. package/src/components/test.vue +260 -260
  89. package/src/components/tree.vue +294 -294
  90. package/src/components/utils/AliyunIssUtil.js +81 -81
  91. package/src/components/utils/ckeditor.js +174 -174
  92. package/src/components/utils/format_date.js +25 -25
  93. package/src/components/utils/index.js +6 -6
  94. package/src/components/utils/math_utils.js +29 -29
  95. package/src/components/voiceComponent.vue +119 -119
  96. package/src/components/welcomeKnowledgeFile.vue +340 -340
  97. package/src/components/welcomeLlmCard.vue +140 -140
  98. package/src/components/welcomeSuggest.vue +97 -97
  99. package/src/main.js +57 -57
  100. package/vue.config.js +54 -54
  101. package/src/components/newPdfPosition.vue +0 -878
@@ -1,1061 +1,1068 @@
1
- <!--
2
- isLiBang 字段判断 是否为立邦主体
3
- 立邦有自己单独的组件分支,但考虑到后期结构改动如果较大改动会不方便,所以还是在推荐知识消息中 在此判断是否是立邦主体。方便后期维护
4
- -->
5
- <template>
6
- <div class="answer-docknowledge">
7
- <div :class="['answer-docknowledge-header', msg.content.isKnowledgeSummary ? 'bgc' : '']">
8
- <div v-if="msg.content.isKnowledgeSummary" class="tips">AI为您总结生成了以下摘要</div>
9
- <!-- <div v-if="msg.content.type == 0" class="answer-text">
10
- <template v-if="msg.content.renderType == 1">
11
- <p v-html="msg.content.text"></p>
12
- </template>
13
- <template v-else>{{ msg.content.text }}</template>
14
- </div> -->
15
- <div class="answer-text">
16
- <template v-if="msg.content.renderType == 1">
17
- <p v-html="msg.content.text"></p>
18
- </template>
19
- <template v-else>{{ msg.content.text }}</template>
20
- </div>
21
- <div v-if="msg.content.images && msg.content.images.length != 0" class="answer-kn-image-box">
22
- <img v-for="(imageItem, imageItemIndex) in msg.content.images"
23
- style="max-width: 230px;border-radius: 25px;margin-bottom: 15px" :src="imageItem.url"
24
- :key="imageItemIndex" alt @click="lookAttach(imageItem.url, imageItem, $event)" />
25
- </div>
26
- </div>
27
- <template v-if="!isLiBang">
28
- <div class="ad-list" :class="msg.content.type == 0 ? 'ad-list-recognition' : ''">
29
- <template v-if="msg.content.type == 1">
30
- <div v-for="(item, itemIndex) in msg.content.list" :key="itemIndex" class="ad-list-cell">
31
- <div class="alc-title">
32
- <div class="alc-box">
33
- <div class="alc-source-left">
34
- <span class="source-form">出自</span>
35
- <img class="alc-title-icon" height="24px" width="24px" :src="getIconSrc(item)" alt=""
36
- srcset="">
37
- <span class="alc-title-from">{{ item.from }}</span>
38
- </div>
39
- </div>
40
- <div v-html="item.introduction" v-if="!srcContentTypeIMG(item)" class="alc-box-introduction">
41
- </div>
42
- <div v-else class="alc-box-introduction">
43
- <img :src="item.expiredUrl" alt="" @click="lookAttach(item.url, item, $event)">
44
- </div>
45
- <div v-if="item.previewImage" class="alc-box-introduction-previewImage">
46
- <img :src="item.previewImage" alt=""
47
- @click="lookAttach(item.previewImage, { url: item.previewImage }, $event)">
48
- </div>
49
- <div class="alc-updateTime">
50
- <div v-show="docSource[item.source]" class="upload-source">
51
- {{ docSource[item.source] }}
52
- </div>
53
- <div v-show="item.url" class="alc-content-text">
54
- <span @click="lookAttach(item.url, item, $event)" class="aci-view">查看 ></span>
55
- </div>
56
- </div>
57
- </div>
58
- <div class="alc-content" v-if="false">
59
- <div v-if="msg.content.type == 1" class="alc-content-text">
60
- {{ item.introduction }}
61
- <span @click="lookAttach(item.url, item, $event)" class="aci-view">查看原文 ></span>
62
- </div>
63
- <span v-if="!isPC" class="alc-title-updateTime">最后更新时间: {{ item.updateTime }}</span>
64
- <div v-if="false" class="alc-content-info">
65
- <div class="alcc-box">
66
- <span class="aci-owner">所有者: {{ item.owner }}</span>
67
- <span class="aci-enterprise">所属企业: {{ item.enterprise }}</span>
68
- <span class="aci-source">文件来源: {{ item.source }}</span>
69
- </div>
70
- </div>
71
- </div>
72
- </div>
73
- </template>
74
- <template v-if="msg.content.type == 0">
75
- <div v-for="(item, itemIndex) in msg.content.list" :key="itemIndex" class="ad-list-cell-recognition">
76
- <div class="alc-source-name" @click="lookAttach(item.url, item, $event)">
77
- <img class="alc-title-icon" height="18px" width="18px" :src="getIconSrc(item)" alt srcset />
78
- <span class="alc-title-from">{{ item.from }}</span>&nbsp;-&nbsp;
79
- <div v-show="docSource[item.source]" class="upload-source">
80
- {{ docSource[item.source] }}
81
- </div>
82
- <i class="iconfont guoran-right"></i>
83
- </div>
84
- </div>
85
- </template>
86
- <div class="ad-loadmore" v-if="loadMoreFlag" @click="lazyLoadKnowledegList">查看更多</div>
87
- </div>
88
- </template>
89
- <template v-if="isLiBang">
90
- <div class="libang_list" :class="msg.content.type == 0 ? 'libang_list_recognition' : ''">
91
- <template v-if="msg.content.type == 1">
92
- <div v-for="(item, itemIndex) in msg.content.list" :key="itemIndex" class="libang_list_cell">
93
- <div class="libang_title">
94
- <div class="libang_box">
95
- <div class="libang_source_left">
96
- <span class="source-form">出自</span>
97
- <img class="libang_title_icon" height="24px" width="24px" :src="getIconSrc(item)" alt=""
98
- srcset="">
99
- <span class="libang_title_from">{{ item.from }}</span>
100
- </div>
101
- </div>
102
- <div v-html="item.introduction" v-if="!srcContentTypeIMG(item)" class="libang_box_introduction">
103
- </div>
104
- <div v-else class="libang_box_introduction">
105
- <img :src="item.expiredUrl" alt="" @click="lookAttach(item.url, item, $event)">
106
- </div>
107
- <div v-if="item.previewImage" class="libang_box_introduction_previewImage">
108
- <img :src="item.previewImage" alt=""
109
- @click="lookAttach(item.previewImage, { url: item.previewImage }, $event)">
110
- </div>
111
- <div class="libang_updateTime">
112
- <div class="libang_updataTime_left">
113
- <div v-show="docSource[item.source]" class="upload-source">
114
- {{ docSource[item.source] }}
115
- </div>
116
- <div class="libang_floder" @click.stop="clickFloder(item)">
117
- {{ item.folderName }}
118
- </div>
119
- </div>
120
- <div v-show="item.url" class="libang_content_text">
121
- <span @click="lookAttach(item.url, item, $event)" class="aci-view">查看 ></span>
122
- </div>
123
- </div>
124
- </div>
125
- <!-- <div class="alc-content" v-if="false">
126
- <div v-if="msg.content.type == 1" class="alc-content-text">
127
- {{ item.introduction }}
128
- <span @click="lookAttach(item.url, item, $event)" class="aci-view">查看原文 ></span>
129
- </div>
130
- <span v-if="!isPC" class="alc-title-updateTime">最后更新时间: {{ item.updateTime }}</span>
131
- <div v-if="false" class="alc-content-info">
132
- <div class="alcc-box">
133
- <span class="aci-owner">所有者: {{ item.owner }}</span>
134
- <span class="aci-enterprise">所属企业: {{ item.enterprise }}</span>
135
- <span class="aci-source">文件来源: {{ item.source }}</span>
136
- </div>
137
- </div>
138
- </div> -->
139
- </div>
140
- </template>
141
- <template v-if="msg.content.type == 0">
142
- <div v-for="(item, itemIndex) in msg.content.list" :key="itemIndex"
143
- class="libang_list_cell_recognition">
144
- <div class="libang_list_cell_left" @click="lookAttach(item.url, item, $event)">
145
- <div class="libang_source_name" >
146
- <img class="libang_title_icon" height="18px" width="18px" :src="getIconSrc(item)" alt srcset />
147
- <span class="libang_title_from">{{ item.from }}</span>&nbsp;-&nbsp;
148
- <div v-show="docSource[item.source]" class="upload_source">
149
- {{ docSource[item.source] }}
150
- </div>
151
- </div>
152
- <div class="libang_source_floder" @click.stop="clickFloder(item)">
153
- {{ item.folderName }}
154
- </div>
155
- </div>
156
- <i class="iconfont guoran-right"></i>
157
- </div>
158
- </template>
159
- <div class="ad-loadmore" v-if="loadMoreFlag" @click="lazyLoadKnowledegList">查看更多</div>
160
- </div>
161
- </template>
162
-
163
- <previewPdf ref="previewPdf" :url="previewHref" :previewOssPath="previewOssPath" :title="title"
164
- :folderName="folderName" :folderUrl="folderUrl"
165
- :sourceFileType="sourceFileType" officePreviewType="pdf" @previewToDialog="previewToDialog"
166
- @recommendQues="recommendQues" @close="close" @open="open" :isHasChat="isHasChat"
167
- :knowledgeId="previewKnowledgeId" :isLiBang="isLiBang" @previewClickFloder="previewClickFloder"></previewPdf>
168
- </div>
169
- </template>
170
-
171
- <script>
172
- /* eslint-disable */
173
- import previewPdf from "./previewPdf";
174
- import { isMobile } from "../assets/js/common";
175
- export default {
176
- name: "answerDocknowledge",
177
- components: { previewPdf },
178
- data () {
179
- return {
180
- isPC: true,
181
- previewHref: "",
182
- sourceFileType: '',
183
- // docSource: {
184
- // LOCAL_FILE: "来源于本地文件",
185
- // CREATED_BY_ONESELF: "来源于自建知识",
186
- // WECHAT: "来源于微信",
187
- // AUTO_SYN_FROM_LOCAL_FILE: "自动同步于本地",
188
- // YUQUE: "来源于语雀",
189
- // CORP_LOCAL_FILE: '来源于企业知识库',
190
- // FEISHU: '来源于飞书-云文档'
191
- // },
192
- docSource: {
193
- LOCAL_FILE: "个人知识",
194
- CREATED_BY_ONESELF: "个人知识",
195
- WECHAT: "个人知识",
196
- AUTO_SYN_FROM_LOCAL_FILE: "个人知识",
197
- YUQUE: "企业知识",
198
- CORP_LOCAL_FILE: '企业知识',
199
- FEISHU: '企业知识'
200
- },
201
- imageObj: {
202
- PDF: 'pdf1',
203
- pdf: 'pdf1',
204
- TXT: 'txt1',
205
- txt: 'txt1',
206
- selfadd: 'selfadd1',
207
- md: "md2",
208
- html: 'selfadd1',
209
- mode: "mode",
210
- general: 'general',
211
- word: "word1",
212
- Word: "word1",
213
- docx: "word1",
214
- doc: "word1",
215
- WORD: "word1",
216
- Excel: 'excel1',
217
- EXCEL: 'excel1',
218
- excel: 'excel1',
219
- PPT: 'ppt1',
220
- ppt: 'ppt1',
221
- pptx: 'ppt1',
222
- img: "image1",
223
- image: "image1",
224
- video: "video",
225
- audio: 'audio',
226
- link: "link",
227
- wechat: "wechat",
228
- mp4: "video",
229
- MP4: "video",
230
- xlsx: "excel1",
231
- SLSX: "excel1",
232
- xls: "excel1",
233
- XLS: "excel1",
234
- jpg: "image1",
235
- JPG: "image1",
236
- jpeg: "image1",
237
- JPEG: "image1",
238
- png: "image1",
239
- PNG: "image1",
240
- webp: "image1",
241
- WEBP: "image1",
242
- gif: "image1",
243
- GIF: "image1",
244
- svg: "image1",
245
- SVG: "image1",
246
- bmp: "image1",
247
- BMP: "image1",
248
- avi: "video",
249
- AVI: "video",
250
- mov: "video",
251
- MOV: "video",
252
- rmvb: "video",
253
- RMVB: "video",
254
- wav: "audio",
255
- WAV: "audio",
256
- mp3: "audio",
257
- MP3: "audio",
258
- yqhtml: "yqhtml",
259
- feishuhtml: "feishuhtml"
260
- },
261
- allKnowledgeList: [],
262
- loadMoreFlag: false,
263
- title: '',
264
- folderName:'',
265
- folderUrl:'',
266
- previewKnowledgeId: "",
267
- previewKnowledge: {},
268
- previewOssPath: ""
269
- }
270
- },
271
- props: ['msg', 'isAskLightning', 'isMessageRecord', "isApp", "isHasChat", "activeKnowledgeId", "isLiBang"],
272
- beforeMounted () {
273
- },
274
- watch: {
275
- // msg: {
276
- // handler (n) {
277
- // console.log(n, 'answerDocknowledge');
278
- // n.content.list.forEach(element => {
279
- // console.log(this.imageObj[element.format], 1111);
280
- // element.src = 'https://static.guoranbot.com/cdn-office-website/askbot_doc/' + this.imageObj[element.format] + '.png';
281
- // if ((element.format === "txt" || element.format === "html") && element.source === "WECHAT") {
282
- // element.src = 'https://static.guoranbot.com/cdn-office-website/askbot_doc/wechat.png';
283
- // }
284
- // });
285
- // },
286
- // deep: true,
287
- // immediate: true
288
- // }
289
- },
290
- created () {
291
- var system = {};
292
- system.pingtai = /(Win32|Win16|WinCE|Mac68K|MacIntel|MacIntel|MacPPC|Linux mips64)/i.test(navigator.platform);
293
- if (system.pingtai) {
294
- //电脑
295
- this.isPC = true;
296
- } else {
297
- //手机
298
- this.isPC = false;
299
- }
300
- // this.msg.content.list.forEach(element => {
301
- // console.log(this.imageObj[element.format],1111);
302
- // element.src = 'https://static.guoranbot.com/cdn-office-website/askbot_doc/' + this.imageObj[element.format] + '.png';
303
- // if ((element.format === "txt" || element.format === "html") && element.source === "WECHAT") {
304
- // element.src = 'https://static.guoranbot.com/cdn-office-website/askbot_doc/wechat.png';
305
- // }
306
- // });
307
- },
308
- mounted () {
309
- console.log(this.msg.content, 'this.msg.content');
310
- // if(this.msg.content.type == 1) {
311
-
312
- // }
313
- if (this.msg.content.list && this.msg.content.list.length > 0) {
314
- this.loadMoreFlag = true
315
- this.allKnowledgeList = JSON.parse(JSON.stringify(this.msg.content.list))
316
- // console.log(this.allKnowledgeList.length, 'this.allKnowledgeList');
317
- this.msg.content.list = []
318
- this.lazyLoadKnowledegList()
319
- }
320
- },
321
- methods: {
322
- getIconSrc (element) {
323
- if ((element.format === "txt" || element.format === "html") && element.source === "WECHAT") {
324
- return 'https://static.guoranbot.com/cdn-office-website/askbot_doc/wechat.png'
325
- } else {
326
- return 'https://static.guoranbot.com/cdn-office-website/askbot_doc/' + this.imageObj[element.format] + '.png'
327
- }
328
- },
329
- //预览图片
330
- lookAttach (url, item, event) {
331
- // console.log(item.knowledgeId);
332
- // this.$http.get("/knowledge-api/internal/knowledgeBaseStructure/" + "642ffbccde420e2772f7787b")
333
- // debugger
334
- event.preventDefault();
335
- if (this.isAskLightning == 1 && !this.isApp){
336
- window.parent.postMessage({
337
- data: "bot_preview",
338
- item: JSON.stringify(item),
339
- url: url
340
- },"*");
341
- } else {
342
- // if (isMobile()) {
343
- // this.$refs.previewPdf.drawer = true;
344
- // this.$refs.previewPdf.previewShowPopup = false;
345
- // } else {
346
- // this.$refs.previewPdf.drawer = false;
347
- // }
348
- this.title = item.from || item.name
349
- this.folderName = item.folderName
350
- this.folderUrl = item.folderUrl
351
- this.previewKnowledge = item;
352
- this.previewKnowledgeId = item.knowledgeId
353
- this.$refs.previewPdf.previewShowPopup = false;
354
- this.$refs.previewPdf.drawer = false;
355
- this.previewOssPath = url;
356
- let index = url.lastIndexOf('?')
357
- let type = ''
358
- let httpUrl = '/knowledge-api/knowledge/getTemporaryCertificate'
359
- if (index !== -1) {
360
- url = url.substring(0, index)
361
- type = this.fileType(url)
362
- } else {
363
- type = this.fileType(url)
364
- }
365
- if (type === '' || type === 'OTHER') {
366
- httpUrl = httpUrl += '?needEncrypt=true'
367
- } else {
368
- httpUrl = httpUrl += '?needEncrypt=false'
369
- }
370
- this.$http.post(httpUrl, {
371
- "fileInOssPath":url
372
- }).then(res =>{
373
- if(res.data.code == '0') {
374
- this.previewHref = res.data.data;
375
- this.sourceFileType = url.substring(url.lastIndexOf('.'))
376
- let isOhmPc = sessionStorage.getItem('isOhmPc')
377
- if (isMobile() || isOhmPc == 'true'){
378
- this.$refs.previewPdf.drawer = true;
379
- this.$refs.previewPdf.previewShowPopup = true;
380
- } else {
381
- this.$refs.previewPdf.previewShowPopup = false;
382
- this.$refs.previewPdf.drawer = true;
383
- }
384
- //聊一聊按钮的选中状态
385
- if (this.activeKnowledgeId == item.knowledgeId){
386
- this.$refs.previewPdf.previewKnowledgeId = this.activeKnowledgeId
387
- } else {
388
- this.$refs.previewPdf.previewKnowledgeId = ""
389
- }
390
- this.$refs.previewPdf.fileType = type
391
- this.$refs.previewPdf.tagIds = item.tagIds
392
- this.$refs.previewPdf.isMessageRecord = this.isMessageRecord ? true : false ;
393
- let index = url.indexOf("?");
394
- let newFileInOssPath = url;
395
- if (index !== -1){
396
- newFileInOssPath = url.substring(0, url.indexOf("?"))
397
- }
398
- let fileName = newFileInOssPath.substring(newFileInOssPath.lastIndexOf('.'))
399
- if (fileName === '.doc' || fileName === '.docx' || fileName === '.txt'|| fileName === '.html'){
400
- this.$refs.previewPdf.fileName = fileName;
401
- } else {
402
- this.$refs.previewPdf.fileName = '';
403
- }
404
- if (item.tagIds && item.tagIds.length != 0) {
405
- this.$refs.previewPdf.loading = false
406
- return
407
- }
408
- this.$nextTick(() => {
409
- if (item.source == 'CREATED_BY_ONESELF' || type === 'HTML') {
410
- this.$refs.previewPdf.getBolb(item)
411
- }
412
- this.$refs.previewPdf.loadIframe(item)
413
- this.$refs.previewPdf.showSummary = true;
414
- })
415
- }
416
- })
417
- }
418
- },
419
- open () {
420
- this.$emit('openPreviewDialog')
421
- },
422
- close () {
423
- this.$emit('closePreviewDialog')
424
- },
425
- fileType (url) {
426
- const fileType = url.substring(url.lastIndexOf('.'));
427
- if (fileType === '.mp4' || fileType === '.MP4' || fileType === '.MOV' || fileType === '.MOVC' || fileType === '.mov' || fileType === '.movc' || fileType === '.mav' || fileType === '.MAV' || fileType == '.mp3' || fileType == '.MP3' || fileType === '.wav') {
428
- return 'VIDEO'
429
- } else if (fileType === '.html') {
430
- return 'HTML'
431
- } else if (fileType === '.png' || fileType === '.jpg' || fileType === '.jpeg') {
432
- return 'IMAGE'
433
- } else {
434
- return 'OTHER'
435
- }
436
- },
437
- srcContentTypeIMG (item) {
438
- let url = item.url || '';
439
- const type = url.substring(url.lastIndexOf('.'));
440
- if (type === '.jpg' || type === '.jpeg' || type === '.png' || type === '.gif') {
441
- this.getSrc(item)
442
- return true
443
- } else {
444
- return false
445
- }
446
- },
447
- getSrc (item) {
448
- // let imgurl = ''
449
- this.$http.post(
450
- '/knowledge-api/temporary-certificate/or-origin?expired=30',
451
- item.url,
452
- {
453
- headers: {
454
- "Content-Type": "application/json",
455
- },
456
- }).then(res => {
457
- console.log(res, '=====');
458
- // imgurl = await res.bodyText
459
- this.$set(item, 'expiredUrl', res.data ? res.data : res.bodyText)
460
- // return res.data
461
- })
462
- // return imgurl
463
- },
464
- lazyLoadKnowledegList () {
465
- if (this.allKnowledgeList.length !== 0) {
466
- let arr = this.allKnowledgeList.splice(0, 5)
467
- if (arr.length < 5) {
468
- this.loadMoreFlag = false
469
- this.msg.content.list = [...this.msg.content.list, ...arr]
470
- return
471
- }
472
- if (this.allKnowledgeList.length == 0) {
473
- this.loadMoreFlag = false
474
- }
475
- this.msg.content.list = [...this.msg.content.list, ...arr]
476
- return
477
- }
478
- },
479
- previewToDialog (flag) {
480
- if (!flag) {
481
- this.$refs.previewPdf.previewKnowledgeId = ""
482
- } else {
483
- this.$refs.previewPdf.previewKnowledgeId = this.previewKnowledgeId
484
- }
485
- this.$emit('previewToDialog', flag, this.previewKnowledgeId, this.previewKnowledge)
486
- },
487
- clearKnowledgeId () {
488
- this.previewKnowledgeId = "";
489
- },
490
- recommendQues (item, knowledgeId) {
491
- this.$emit('recommendQues', item, knowledgeId)
492
- },
493
- clickFloder(item) {
494
- this.$emit('clickFloder', item)
495
- },
496
- previewClickFloder() {
497
- let item = null
498
- this.msg.content.list.forEach(element => {
499
- if(element.knowledgeId == this.previewKnowledgeId) {
500
- item = element
501
- }
502
- });
503
- this.$emit('clickFloder', item)
504
- }
505
- }
506
- }
507
- </script>
508
-
509
- <style scoped lang="less">
510
- .answer-docknowledge {
511
- min-width: 100px;
512
- background: #ffffff;
513
-
514
- .answer-docknowledge-header {
515
- .tips {
516
- width: 154px;
517
- height: 22px;
518
- background: #366aff;
519
- border-radius: 5px;
520
- text-align: center;
521
- line-height: 22px;
522
- color: #fff;
523
- font-size: 12px;
524
- margin-bottom: 7px;
525
- }
526
-
527
- .answer-text {
528
- // font-size: 13px;
529
- text-align: left;
530
- line-height: 25px;
531
- padding: 0px 0px 12px 0px;
532
-
533
- .aci-view {
534
- // font-size: 13px;
535
- display: inline-block;
536
- // margin-left: 5px;
537
- color: #366aff;
538
- cursor: pointer;
539
- }
540
- }
541
-
542
- &.bgc {
543
- padding: 10px;
544
- background: #eef1ff;
545
- border-radius: 10px;
546
- margin-bottom: 16px;
547
-
548
- .answer-text {
549
- padding: 0;
550
- }
551
- }
552
-
553
- .answer-kn-image-box {
554
- margin-bottom: 10px;
555
- }
556
- }
557
-
558
-
559
- .ad-list-recognition {
560
- display: flex;
561
- align-items: center;
562
- flex-wrap: wrap;
563
- }
564
-
565
- .libang_list_recognition {
566
- display: flex;
567
- align-items: center;
568
- flex-wrap: wrap;
569
- }
570
-
571
- .ad-list {
572
- .ad-list-cell {
573
- border-top: solid 1px #eeeeee;
574
- padding: 10px 0 10px;
575
-
576
- .alc-title {
577
- display: flex;
578
- flex-wrap: wrap;
579
- align-items: center;
580
- justify-content: space-between;
581
- line-height: 16px;
582
-
583
- .alc-box {
584
- display: flex;
585
- align-items: center;
586
- justify-content: space-between;
587
- // font-size: 12px;
588
- width: 100%;
589
-
590
- .alc-source-left {
591
- display: flex;
592
- align-items: center;
593
-
594
- .source-form {
595
- width: 34px;
596
- flex: none;
597
- color: #a9b3c6;
598
- }
599
- }
600
-
601
- .alc-content-text {
602
- width: 55px;
603
- flex: none;
604
-
605
- .aci-view {
606
- color: #366aff;
607
- cursor: pointer;
608
- }
609
- }
610
-
611
- .alc-title-from {
612
- line-height: 22px;
613
- word-break: break-all !important;
614
- text-align: left;
615
- flex: auto;
616
- display: flex;
617
- justify-content: flex-start;
618
- }
619
- }
620
-
621
- .alc-box-introduction {
622
- overflow: hidden;
623
- text-overflow: ellipsis;
624
- display: -webkit-box;
625
- -webkit-line-clamp: 3;
626
- -webkit-box-orient: vertical;
627
- margin-top: 10px;
628
- color: #616161;
629
- // font-size: 12px;
630
- line-height: 24px;
631
- text-align: left;
632
-
633
- img {
634
- width: 50px;
635
- height: 50px;
636
- margin: 10px;
637
- cursor: pointer;
638
- }
639
- }
640
-
641
- .alc-box-introduction-previewImage {
642
- width: 100%;
643
- display: block;
644
- overflow: hidden;
645
- text-overflow: ellipsis;
646
- display: -webkit-box;
647
- -webkit-line-clamp:3;
648
- -webkit-box-orient:vertical;
649
- margin-top: 10px;
650
- color: #616161;
651
- // font-size: 12px;
652
- line-height: 24px;
653
- text-align: left;
654
- img {
655
- max-width: 300px;
656
- width: 100%;
657
- max-height: 150px;
658
- margin: 10px;
659
- cursor: pointer;
660
- }
661
- }
662
-
663
- .alc-updateTime {
664
- display: flex;
665
- align-items: center;
666
- justify-content: space-between;
667
- font-size: 13px;
668
- width: 100%;
669
- margin-top: 10px;
670
-
671
- .upload-source {
672
- flex: none;
673
- height: 18px;
674
- line-height: 18px;
675
- background: #e9f9f8;
676
- border: 1px solid #aff2cd;
677
- border-radius: 2px;
678
- display: flex;
679
- align-items: center;
680
- justify-content: center;
681
- padding: 0 8px;
682
- color: #00c2bb;
683
- }
684
-
685
- .time {
686
- color: #999999;
687
- margin-left: 10px;
688
- }
689
-
690
- .alc-content-text {
691
- color: #366aff;
692
- cursor: pointer;
693
- }
694
- }
695
-
696
- .alc-title-icon {
697
- margin: 0 2px;
698
- width: 18px;
699
- height: 18px;
700
- flex: none;
701
- }
702
-
703
- .alc-title-updateTime {
704
- text-align: right;
705
- color: #999999;
706
- // font-size: 13px;
707
- }
708
- }
709
-
710
- .alc-content {
711
- .alc-title-updateTime {
712
- margin-top: 6px;
713
- display: block;
714
- text-align: right;
715
- color: #999999;
716
- // font-size: 13px;
717
- }
718
-
719
- .alc-content-text {
720
- margin-bottom: 6px;
721
- width: 55px;
722
- flex: none;
723
-
724
- .aci-view {
725
- display: inline-block;
726
- margin-left: 30px;
727
- color: #366aff;
728
- cursor: pointer;
729
- }
730
- }
731
-
732
- .alc-content-info {
733
- display: flex;
734
- flex-wrap: wrap;
735
- justify-content: space-between;
736
-
737
- .alcc-box {
738
- display: flex;
739
- flex-wrap: wrap;
740
- color: #999999;
741
-
742
- .aci-owner {
743
- margin-right: 20px;
744
- }
745
-
746
- .aci-enterprise {
747
- margin-right: 20px;
748
- }
749
- }
750
- }
751
- }
752
- }
753
-
754
- .ad-list-cell-recognition {
755
- .alc-source-name {
756
- flex: none;
757
- padding: 3px;
758
- margin-right: 5px;
759
- margin-bottom: 5px;
760
- background: #f2f6ff;
761
- border-radius: 5px;
762
- display: flex;
763
- align-items: center;
764
- justify-content: space-between;
765
- cursor: pointer;
766
-
767
- img {
768
- vertical-align: middle;
769
- // width: 16px;
770
- // height: 16px;
771
- margin: 0 3px 0 5px;
772
- }
773
-
774
- .alc-title-from {
775
- // margin-right: 5px;
776
- max-width: 240px;
777
- overflow: hidden;
778
- text-overflow: ellipsis;
779
- white-space: nowrap;
780
- }
781
-
782
- .upload-source {
783
- margin-right: 5px;
784
- }
785
-
786
- i {
787
- font-size: 12px;
788
- }
789
- }
790
- }
791
-
792
- .ad-loadmore {
793
- width: 100%;
794
- height: 40px;
795
- display: flex;
796
- align-items: center;
797
- justify-content: center;
798
- // background: #FFFFFF;
799
- color: #366aff;
800
- font-size: 14px;
801
- margin-top: 8px;
802
- cursor: pointer;
803
- }
804
- }
805
-
806
- .libang_list {
807
- .libang_list_cell {
808
- border-top: solid 1px #eeeeee;
809
- padding: 10px 0 10px;
810
-
811
- .libang_title {
812
- display: flex;
813
- flex-wrap: wrap;
814
- align-items: center;
815
- justify-content: space-between;
816
- line-height: 16px;
817
-
818
- .libang_box {
819
- display: flex;
820
- align-items: center;
821
- justify-content: space-between;
822
- // font-size: 12px;
823
- width: 100%;
824
-
825
- .libang_source_left {
826
- display: flex;
827
- align-items: center;
828
-
829
- .source-form {
830
- width: 34px;
831
- flex: none;
832
- color: #a9b3c6;
833
- }
834
- }
835
-
836
- .alc-content-text {
837
- width: 55px;
838
- flex: none;
839
-
840
- .aci-view {
841
- color: #366aff;
842
- cursor: pointer;
843
- }
844
- }
845
-
846
- .libang_title_from {
847
- line-height: 22px;
848
- word-break: break-all !important;
849
- text-align: left;
850
- flex: auto;
851
- display: flex;
852
- justify-content: flex-start;
853
- }
854
- }
855
-
856
- .libang_box_introduction {
857
- overflow: hidden;
858
- text-overflow: ellipsis;
859
- display: -webkit-box;
860
- -webkit-line-clamp: 3;
861
- -webkit-box-orient: vertical;
862
- margin-top: 10px;
863
- color: #616161;
864
- // font-size: 12px;
865
- line-height: 24px;
866
- text-align: left;
867
-
868
- img {
869
- width: 50px;
870
- height: 50px;
871
- margin: 10px;
872
- cursor: pointer;
873
- }
874
- }
875
-
876
- .libang_box_introduction_previewImage {
877
- overflow: hidden;
878
- text-overflow: ellipsis;
879
- display: -webkit-box;
880
- -webkit-line-clamp: 3;
881
- -webkit-box-orient: vertical;
882
- margin-top: 10px;
883
- color: #616161;
884
- // font-size: 12px;
885
- line-height: 24px;
886
- text-align: left;
887
-
888
- img {
889
- max-width: 300px;
890
- width: 100%;
891
- max-height: 150px;
892
- margin: 10px;
893
- cursor: pointer;
894
- }
895
- }
896
-
897
- .libang_updateTime {
898
- display: flex;
899
- align-items: center;
900
- justify-content: space-between;
901
- font-size: 13px;
902
- width: 100%;
903
- margin-top: 10px;
904
- .libang_updataTime_left {
905
- width: calc(100% - 40px);
906
- display: flex;
907
- align-items: center;
908
- .upload-source {
909
- flex: none;
910
- height: 18px;
911
- line-height: 18px;
912
- background: #e9f9f8;
913
- border: 1px solid #aff2cd;
914
- border-radius: 2px;
915
- display: flex;
916
- align-items: center;
917
- justify-content: center;
918
- padding: 0 8px;
919
- color: #00c2bb;
920
- }
921
- .libang_floder {
922
- width:calc(100% - 90px);
923
- margin-left: 10px;
924
- overflow: hidden;
925
- text-overflow: ellipsis;
926
- white-space: nowrap;
927
- color: #366aff;
928
- cursor: pointer;
929
- }
930
- }
931
- .libang_content_text {
932
- color: #366aff;
933
- cursor: pointer;
934
- }
935
- .time {
936
- color: #999999;
937
- margin-left: 10px;
938
- }
939
- }
940
- .alc-title-icon {
941
- margin: 0 2px;
942
- width: 18px;
943
- height: 18px;
944
- flex: none;
945
- }
946
-
947
- .alc-title-updateTime {
948
- text-align: right;
949
- color: #999999;
950
- // font-size: 13px;
951
- }
952
- }
953
-
954
- .alc-content {
955
- .alc-title-updateTime {
956
- margin-top: 6px;
957
- display: block;
958
- text-align: right;
959
- color: #999999;
960
- // font-size: 13px;
961
- }
962
-
963
- .alc-content-text {
964
- margin-bottom: 6px;
965
- width: 55px;
966
- flex: none;
967
-
968
- .aci-view {
969
- display: inline-block;
970
- margin-left: 30px;
971
- color: #366aff;
972
- cursor: pointer;
973
- }
974
- }
975
-
976
- .alc-content-info {
977
- display: flex;
978
- flex-wrap: wrap;
979
- justify-content: space-between;
980
-
981
- .alcc-box {
982
- display: flex;
983
- flex-wrap: wrap;
984
- color: #999999;
985
-
986
- .aci-owner {
987
- margin-right: 20px;
988
- }
989
-
990
- .aci-enterprise {
991
- margin-right: 20px;
992
- }
993
- }
994
- }
995
- }
996
- }
997
-
998
- .libang_list_cell_recognition {
999
- background: #f2f6ff;
1000
- display: flex;
1001
- align-items: center;
1002
- justify-content: space-between;
1003
- padding: 3px;
1004
- margin-right: 5px;
1005
- margin-bottom: 5px;
1006
- border-radius: 5px;
1007
- cursor: pointer;
1008
- font-size: 14px;
1009
-
1010
- .libang_list_cell_left {
1011
- margin-right: 5px;
1012
- .libang_source_name {
1013
- display: flex;
1014
- align-items: center;
1015
- height: 20px;
1016
- margin-bottom: 2px;
1017
- img {
1018
- vertical-align: middle;
1019
- // width: 16px;
1020
- // height: 16px;
1021
- margin: 0 3px;
1022
- }
1023
-
1024
- .libang_title_from {
1025
- max-width: 226px;
1026
- overflow: hidden;
1027
- text-overflow: ellipsis;
1028
- white-space: nowrap;
1029
- line-height: 20px;
1030
- }
1031
- }
1032
- .libang_source_floder {
1033
- max-width: calc(226px - 24px);
1034
- margin-left: 24px;
1035
- text-align: left;
1036
- color: #366aff;
1037
- overflow: hidden;
1038
- text-overflow: ellipsis;
1039
- white-space: nowrap;
1040
- cursor: pointer;
1041
- }
1042
- }
1043
- i {
1044
- font-size: 12px;
1045
- }
1046
- }
1047
-
1048
- .ad-loadmore {
1049
- width: 100%;
1050
- height: 40px;
1051
- display: flex;
1052
- align-items: center;
1053
- justify-content: center;
1054
- // background: #FFFFFF;
1055
- color: #366aff;
1056
- font-size: 14px;
1057
- margin-top: 8px;
1058
- cursor: pointer;
1059
- }
1060
- }
1061
- }</style>
1
+ <!--
2
+ isLiBang 字段判断 是否为立邦主体
3
+ 立邦有自己单独的组件分支,但考虑到后期结构改动如果较大改动会不方便,所以还是在推荐知识消息中 在此判断是否是立邦主体。方便后期维护
4
+ -->
5
+ <template>
6
+ <div class="answer-docknowledge">
7
+ <div :class="['answer-docknowledge-header', msg.content.isKnowledgeSummary ? 'bgc' : '']">
8
+ <div v-if="msg.content.isKnowledgeSummary" class="tips">AI为您总结生成了以下摘要</div>
9
+ <!-- <div v-if="msg.content.type == 0" class="answer-text">
10
+ <template v-if="msg.content.renderType == 1">
11
+ <p v-html="msg.content.text"></p>
12
+ </template>
13
+ <template v-else>{{ msg.content.text }}</template>
14
+ </div> -->
15
+ <div class="answer-text">
16
+ <template v-if="msg.content.renderType == 1">
17
+ <p v-html="msg.content.text"></p>
18
+ </template>
19
+ <template v-else>{{ msg.content.text }}</template>
20
+ </div>
21
+ <div v-if="msg.content.images && msg.content.images.length != 0" class="answer-kn-image-box">
22
+ <img v-for="(imageItem, imageItemIndex) in msg.content.images"
23
+ style="max-width: 230px;border-radius: 25px;margin-bottom: 15px" :src="imageItem.url"
24
+ :key="imageItemIndex" alt @click="lookAttach(imageItem.url, imageItem, $event)" />
25
+ </div>
26
+ </div>
27
+ <template v-if="!isLiBang">
28
+ <div class="ad-list" :class="msg.content.type == 0 ? 'ad-list-recognition' : ''">
29
+ <template v-if="msg.content.type == 1">
30
+ <div v-for="(item, itemIndex) in msg.content.list" :key="itemIndex" class="ad-list-cell">
31
+ <div class="alc-title">
32
+ <div class="alc-box">
33
+ <div class="alc-source-left">
34
+ <span class="source-form">出自</span>
35
+ <img class="alc-title-icon" height="24px" width="24px" :src="getIconSrc(item)" alt=""
36
+ srcset="">
37
+ <span class="alc-title-from">{{ item.from }}</span>
38
+ </div>
39
+ </div>
40
+ <div v-html="item.introduction" v-if="!srcContentTypeIMG(item)" class="alc-box-introduction">
41
+ </div>
42
+ <div v-else class="alc-box-introduction">
43
+ <img :src="item.expiredUrl" alt="" @click="lookAttach(item.url, item, $event)">
44
+ </div>
45
+ <div v-if="item.previewImage" class="alc-box-introduction-previewImage">
46
+ <img :src="item.previewImage" alt=""
47
+ @click="lookAttach(item.previewImage, { url: item.previewImage }, $event)">
48
+ </div>
49
+ <div class="alc-updateTime">
50
+ <div v-show="docSource[item.source]" class="upload-source">
51
+ {{ docSource[item.source] }}
52
+ </div>
53
+ <div v-show="item.url" class="alc-content-text">
54
+ <span @click="lookAttach(item.url, item, $event)" class="aci-view">查看 ></span>
55
+ </div>
56
+ </div>
57
+ </div>
58
+ <div class="alc-content" v-if="false">
59
+ <div v-if="msg.content.type == 1" class="alc-content-text">
60
+ {{ item.introduction }}
61
+ <span @click="lookAttach(item.url, item, $event)" class="aci-view">查看原文 ></span>
62
+ </div>
63
+ <span v-if="!isPC" class="alc-title-updateTime">最后更新时间: {{ item.updateTime }}</span>
64
+ <div v-if="false" class="alc-content-info">
65
+ <div class="alcc-box">
66
+ <span class="aci-owner">所有者: {{ item.owner }}</span>
67
+ <span class="aci-enterprise">所属企业: {{ item.enterprise }}</span>
68
+ <span class="aci-source">文件来源: {{ item.source }}</span>
69
+ </div>
70
+ </div>
71
+ </div>
72
+ </div>
73
+ </template>
74
+ <template v-if="msg.content.type == 0">
75
+ <div v-for="(item, itemIndex) in msg.content.list" :key="itemIndex" class="ad-list-cell-recognition">
76
+ <div class="alc-source-name" @click="lookAttach(item.url, item, $event)">
77
+ <img class="alc-title-icon" height="18px" width="18px" :src="getIconSrc(item)" alt srcset />
78
+ <span class="alc-title-from">{{ item.from }}</span>&nbsp;-&nbsp;
79
+ <div v-show="docSource[item.source]" class="upload-source">
80
+ {{ docSource[item.source] }}
81
+ </div>
82
+ <i class="iconfont guoran-right"></i>
83
+ </div>
84
+ </div>
85
+ </template>
86
+ <div class="ad-loadmore" v-if="loadMoreFlag" @click="lazyLoadKnowledegList">查看更多</div>
87
+ </div>
88
+ </template>
89
+ <template v-if="isLiBang">
90
+ <div class="libang_list" :class="msg.content.type == 0 ? 'libang_list_recognition' : ''">
91
+ <template v-if="msg.content.type == 1">
92
+ <div v-for="(item, itemIndex) in msg.content.list" :key="itemIndex" class="libang_list_cell">
93
+ <div class="libang_title">
94
+ <div class="libang_box">
95
+ <div class="libang_source_left">
96
+ <span class="source-form">出自</span>
97
+ <img class="libang_title_icon" height="24px" width="24px" :src="getIconSrc(item)" alt=""
98
+ srcset="">
99
+ <span class="libang_title_from">{{ item.from }}</span>
100
+ </div>
101
+ </div>
102
+ <div v-html="item.introduction" v-if="!srcContentTypeIMG(item)" class="libang_box_introduction">
103
+ </div>
104
+ <div v-else class="libang_box_introduction">
105
+ <img :src="item.expiredUrl" alt="" @click="lookAttach(item.url, item, $event)">
106
+ </div>
107
+ <div v-if="item.previewImage" class="libang_box_introduction_previewImage">
108
+ <img :src="item.previewImage" alt=""
109
+ @click="lookAttach(item.previewImage, { url: item.previewImage }, $event)">
110
+ </div>
111
+ <div class="libang_updateTime">
112
+ <div class="libang_updataTime_left">
113
+ <div v-show="docSource[item.source]" class="upload-source">
114
+ {{ docSource[item.source] }}
115
+ </div>
116
+ <div class="libang_floder" @click.stop="clickFloder(item)">
117
+ <i class="iconfont guoran-tongyichicun-wenjianjia-zhankaizhuangtai--folderOpen"></i>
118
+ {{ item.folderName }}
119
+ </div>
120
+ </div>
121
+ <div v-show="item.url" class="libang_content_text">
122
+ <span @click="lookAttach(item.url, item, $event)" class="aci-view">查看 ></span>
123
+ </div>
124
+ </div>
125
+ </div>
126
+ <!-- <div class="alc-content" v-if="false">
127
+ <div v-if="msg.content.type == 1" class="alc-content-text">
128
+ {{ item.introduction }}
129
+ <span @click="lookAttach(item.url, item, $event)" class="aci-view">查看原文 ></span>
130
+ </div>
131
+ <span v-if="!isPC" class="alc-title-updateTime">最后更新时间: {{ item.updateTime }}</span>
132
+ <div v-if="false" class="alc-content-info">
133
+ <div class="alcc-box">
134
+ <span class="aci-owner">所有者: {{ item.owner }}</span>
135
+ <span class="aci-enterprise">所属企业: {{ item.enterprise }}</span>
136
+ <span class="aci-source">文件来源: {{ item.source }}</span>
137
+ </div>
138
+ </div>
139
+ </div> -->
140
+ </div>
141
+ </template>
142
+ <template v-if="msg.content.type == 0">
143
+ <div v-for="(item, itemIndex) in msg.content.list" :key="itemIndex"
144
+ class="libang_list_cell_recognition" @click="lookAttach(item.url, item, $event)">
145
+ <div class="libang_list_cell_left" >
146
+ <div class="libang_source_name" >
147
+ <img class="libang_title_icon" height="18px" width="18px" :src="getIconSrc(item)" alt srcset />
148
+ <span class="libang_title_from">{{ item.from }}</span>&nbsp;-&nbsp;
149
+ <div v-show="docSource[item.source]" class="upload_source">
150
+ {{ docSource[item.source] }}
151
+ </div>
152
+ </div>
153
+ <div class="libang_source_floder" @click.stop="clickFloder(item)">
154
+ <i class="iconfont guoran-tongyichicun-wenjianjia-zhankaizhuangtai--folderOpen"></i>
155
+ {{ item.folderName }}
156
+ </div>
157
+ </div>
158
+ <i class="iconfont guoran-right" @click="lookAttach(item.url, item, $event)"></i>
159
+ </div>
160
+ </template>
161
+ <div class="ad-loadmore" v-if="loadMoreFlag" @click="lazyLoadKnowledegList">查看更多</div>
162
+ </div>
163
+ </template>
164
+
165
+ <previewPdf ref="previewPdf" :url="previewHref" :previewOssPath="previewOssPath" :title="title"
166
+ :folderName="folderName" :folderUrl="folderUrl"
167
+ :sourceFileType="sourceFileType" officePreviewType="pdf" @previewToDialog="previewToDialog"
168
+ @recommendQues="recommendQues" @close="close" @open="open" :isHasChat="isHasChat"
169
+ :knowledgeId="previewKnowledgeId" :isLiBang="isLiBang" @previewClickFloder="previewClickFloder"></previewPdf>
170
+ </div>
171
+ </template>
172
+
173
+ <script>
174
+ /* eslint-disable */
175
+ import previewPdf from "./previewPdf";
176
+ import { isMobile } from "../assets/js/common";
177
+ export default {
178
+ name: "answerDocknowledge",
179
+ components: { previewPdf },
180
+ data () {
181
+ return {
182
+ isPC: true,
183
+ previewHref: "",
184
+ sourceFileType: '',
185
+ // docSource: {
186
+ // LOCAL_FILE: "来源于本地文件",
187
+ // CREATED_BY_ONESELF: "来源于自建知识",
188
+ // WECHAT: "来源于微信",
189
+ // AUTO_SYN_FROM_LOCAL_FILE: "自动同步于本地",
190
+ // YUQUE: "来源于语雀",
191
+ // CORP_LOCAL_FILE: '来源于企业知识库',
192
+ // FEISHU: '来源于飞书-云文档'
193
+ // },
194
+ docSource: {
195
+ LOCAL_FILE: "个人知识",
196
+ CREATED_BY_ONESELF: "个人知识",
197
+ WECHAT: "个人知识",
198
+ AUTO_SYN_FROM_LOCAL_FILE: "个人知识",
199
+ YUQUE: "企业知识",
200
+ CORP_LOCAL_FILE: '企业知识',
201
+ FEISHU: '企业知识'
202
+ },
203
+ imageObj: {
204
+ PDF: 'pdf1',
205
+ pdf: 'pdf1',
206
+ TXT: 'txt1',
207
+ txt: 'txt1',
208
+ selfadd: 'selfadd1',
209
+ md: "md2",
210
+ html: 'selfadd1',
211
+ mode: "mode",
212
+ general: 'general',
213
+ word: "word1",
214
+ Word: "word1",
215
+ docx: "word1",
216
+ doc: "word1",
217
+ WORD: "word1",
218
+ Excel: 'excel1',
219
+ EXCEL: 'excel1',
220
+ excel: 'excel1',
221
+ PPT: 'ppt1',
222
+ ppt: 'ppt1',
223
+ pptx: 'ppt1',
224
+ img: "image1",
225
+ image: "image1",
226
+ video: "video",
227
+ audio: 'audio',
228
+ link: "link",
229
+ wechat: "wechat",
230
+ mp4: "video",
231
+ MP4: "video",
232
+ xlsx: "excel1",
233
+ SLSX: "excel1",
234
+ xls: "excel1",
235
+ XLS: "excel1",
236
+ jpg: "image1",
237
+ JPG: "image1",
238
+ jpeg: "image1",
239
+ JPEG: "image1",
240
+ png: "image1",
241
+ PNG: "image1",
242
+ webp: "image1",
243
+ WEBP: "image1",
244
+ gif: "image1",
245
+ GIF: "image1",
246
+ svg: "image1",
247
+ SVG: "image1",
248
+ bmp: "image1",
249
+ BMP: "image1",
250
+ avi: "video",
251
+ AVI: "video",
252
+ mov: "video",
253
+ MOV: "video",
254
+ rmvb: "video",
255
+ RMVB: "video",
256
+ wav: "audio",
257
+ WAV: "audio",
258
+ mp3: "audio",
259
+ MP3: "audio",
260
+ yqhtml: "yqhtml",
261
+ feishuhtml: "feishuhtml"
262
+ },
263
+ allKnowledgeList: [],
264
+ loadMoreFlag: false,
265
+ title: '',
266
+ folderName:'',
267
+ folderUrl:'',
268
+ previewKnowledgeId: "",
269
+ previewKnowledge: {},
270
+ previewOssPath: ""
271
+ }
272
+ },
273
+ props: ['msg', 'isAskLightning', 'isMessageRecord', "isApp", "isHasChat", "activeKnowledgeId", "isLiBang"],
274
+ beforeMounted () {
275
+ },
276
+ watch: {
277
+ // msg: {
278
+ // handler (n) {
279
+ // console.log(n, 'answerDocknowledge');
280
+ // n.content.list.forEach(element => {
281
+ // console.log(this.imageObj[element.format], 1111);
282
+ // element.src = 'https://static.guoranbot.com/cdn-office-website/askbot_doc/' + this.imageObj[element.format] + '.png';
283
+ // if ((element.format === "txt" || element.format === "html") && element.source === "WECHAT") {
284
+ // element.src = 'https://static.guoranbot.com/cdn-office-website/askbot_doc/wechat.png';
285
+ // }
286
+ // });
287
+ // },
288
+ // deep: true,
289
+ // immediate: true
290
+ // }
291
+ },
292
+ created () {
293
+ var system = {};
294
+ system.pingtai = /(Win32|Win16|WinCE|Mac68K|MacIntel|MacIntel|MacPPC|Linux mips64)/i.test(navigator.platform);
295
+ if (system.pingtai) {
296
+ //电脑
297
+ this.isPC = true;
298
+ } else {
299
+ //手机
300
+ this.isPC = false;
301
+ }
302
+ // this.msg.content.list.forEach(element => {
303
+ // console.log(this.imageObj[element.format],1111);
304
+ // element.src = 'https://static.guoranbot.com/cdn-office-website/askbot_doc/' + this.imageObj[element.format] + '.png';
305
+ // if ((element.format === "txt" || element.format === "html") && element.source === "WECHAT") {
306
+ // element.src = 'https://static.guoranbot.com/cdn-office-website/askbot_doc/wechat.png';
307
+ // }
308
+ // });
309
+ },
310
+ mounted () {
311
+ console.log(this.msg.content, 'this.msg.content');
312
+ // if(this.msg.content.type == 1) {
313
+
314
+ // }
315
+ if (this.msg.content.list && this.msg.content.list.length > 0) {
316
+ this.loadMoreFlag = true
317
+ this.allKnowledgeList = JSON.parse(JSON.stringify(this.msg.content.list))
318
+ // console.log(this.allKnowledgeList.length, 'this.allKnowledgeList');
319
+ this.msg.content.list = []
320
+ this.lazyLoadKnowledegList()
321
+ }
322
+ },
323
+ methods: {
324
+ getIconSrc (element) {
325
+ if ((element.format === "txt" || element.format === "html") && element.source === "WECHAT") {
326
+ return require("../assets/image/filtType/wechat.png")
327
+ } else {
328
+ return require("../assets/image/filtType/" + this.imageObj[element.format] + '.png')
329
+
330
+ }
331
+ },
332
+ //预览图片
333
+ lookAttach (url, item, event) {
334
+ // console.log(item.knowledgeId);
335
+ // this.$http.get("/knowledge-api/internal/knowledgeBaseStructure/" + "642ffbccde420e2772f7787b")
336
+ // debugger
337
+ event.preventDefault();
338
+ if (this.isAskLightning == 1 && !this.isApp){
339
+ window.parent.postMessage({
340
+ data: "bot_preview",
341
+ item: JSON.stringify(item),
342
+ url: url
343
+ },"*");
344
+ } else {
345
+ // if (isMobile()) {
346
+ // this.$refs.previewPdf.drawer = true;
347
+ // this.$refs.previewPdf.previewShowPopup = false;
348
+ // } else {
349
+ // this.$refs.previewPdf.drawer = false;
350
+ // }
351
+ this.title = item.from || item.name
352
+ this.folderName = item.folderName
353
+ this.folderUrl = item.folderUrl
354
+ this.previewKnowledge = item;
355
+ this.previewKnowledgeId = item.knowledgeId
356
+ this.$refs.previewPdf.previewShowPopup = false;
357
+ this.$refs.previewPdf.drawer = false;
358
+ this.previewOssPath = url;
359
+ let index = url.lastIndexOf('?')
360
+ let type = ''
361
+ let httpUrl = '/knowledge-api/knowledge/getTemporaryCertificate'
362
+ if (index !== -1) {
363
+ url = url.substring(0, index)
364
+ type = this.fileType(url)
365
+ } else {
366
+ type = this.fileType(url)
367
+ }
368
+ if (type === '' || type === 'OTHER') {
369
+ httpUrl = httpUrl += '?needEncrypt=true'
370
+ } else {
371
+ httpUrl = httpUrl += '?needEncrypt=false'
372
+ }
373
+ this.$http.post(httpUrl, {
374
+ "fileInOssPath":url
375
+ }).then(res =>{
376
+ if(res.data.code == '0') {
377
+ this.previewHref = res.data.data;
378
+ this.sourceFileType = url.substring(url.lastIndexOf('.'))
379
+ let isOhmPc = sessionStorage.getItem('isOhmPc')
380
+ if (isMobile() || isOhmPc == 'true'){
381
+ this.$refs.previewPdf.drawer = true;
382
+ this.$refs.previewPdf.previewShowPopup = true;
383
+ } else {
384
+ this.$refs.previewPdf.previewShowPopup = false;
385
+ this.$refs.previewPdf.drawer = true;
386
+ }
387
+ //聊一聊按钮的选中状态
388
+ if (this.activeKnowledgeId == item.knowledgeId){
389
+ this.$refs.previewPdf.previewKnowledgeId = this.activeKnowledgeId
390
+ } else {
391
+ this.$refs.previewPdf.previewKnowledgeId = ""
392
+ }
393
+ this.$refs.previewPdf.fileType = type
394
+ this.$refs.previewPdf.tagIds = item.tagIds
395
+ this.$refs.previewPdf.isMessageRecord = this.isMessageRecord ? true : false ;
396
+ let index = url.indexOf("?");
397
+ let newFileInOssPath = url;
398
+ if (index !== -1){
399
+ newFileInOssPath = url.substring(0, url.indexOf("?"))
400
+ }
401
+ let fileName = newFileInOssPath.substring(newFileInOssPath.lastIndexOf('.'))
402
+ if (fileName === '.doc' || fileName === '.docx' || fileName === '.txt'|| fileName === '.html'){
403
+ this.$refs.previewPdf.fileName = fileName;
404
+ } else {
405
+ this.$refs.previewPdf.fileName = '';
406
+ }
407
+ if (item.tagIds && item.tagIds.length != 0) {
408
+ this.$refs.previewPdf.loading = false
409
+ return
410
+ }
411
+ this.$nextTick(() => {
412
+ if (item.source == 'CREATED_BY_ONESELF' || type === 'HTML') {
413
+ this.$refs.previewPdf.getBolb(item)
414
+ }
415
+ this.$refs.previewPdf.loadIframe(item)
416
+ this.$refs.previewPdf.showSummary = true;
417
+ })
418
+ }
419
+ })
420
+ }
421
+ },
422
+ open () {
423
+ this.$emit('openPreviewDialog')
424
+ },
425
+ close () {
426
+ this.$emit('closePreviewDialog')
427
+ },
428
+ fileType (url) {
429
+ const fileType = url.substring(url.lastIndexOf('.'));
430
+ if (fileType === '.mp4' || fileType === '.MP4' || fileType === '.MOV' || fileType === '.MOVC' || fileType === '.mov' || fileType === '.movc' || fileType === '.mav' || fileType === '.MAV' || fileType == '.mp3' || fileType == '.MP3' || fileType === '.wav') {
431
+ return 'VIDEO'
432
+ } else if (fileType === '.html') {
433
+ return 'HTML'
434
+ } else {
435
+ return 'OTHER'
436
+ }
437
+ },
438
+ srcContentTypeIMG (item) {
439
+ let url = item.url || '';
440
+ const type = url.substring(url.lastIndexOf('.'));
441
+ if (type === '.jpg' || type === '.jpeg' || type === '.png' || type === '.gif') {
442
+ this.getSrc(item)
443
+ return true
444
+ } else {
445
+ return false
446
+ }
447
+ },
448
+ getSrc (item) {
449
+ // let imgurl = ''
450
+ this.$http.post(
451
+ '/knowledge-api/temporary-certificate/or-origin?expired=30',
452
+ item.url,
453
+ {
454
+ headers: {
455
+ "Content-Type": "application/json",
456
+ },
457
+ }).then(res => {
458
+ console.log(res, '=====');
459
+ // imgurl = await res.bodyText
460
+ this.$set(item, 'expiredUrl', res.data ? res.data : res.bodyText)
461
+ // return res.data
462
+ })
463
+ // return imgurl
464
+ },
465
+ lazyLoadKnowledegList () {
466
+ if (this.allKnowledgeList.length !== 0) {
467
+ let arr = this.allKnowledgeList.splice(0, 5)
468
+ if (arr.length < 5) {
469
+ this.loadMoreFlag = false
470
+ this.msg.content.list = [...this.msg.content.list, ...arr]
471
+ return
472
+ }
473
+ if (this.allKnowledgeList.length == 0) {
474
+ this.loadMoreFlag = false
475
+ }
476
+ this.msg.content.list = [...this.msg.content.list, ...arr]
477
+ return
478
+ }
479
+ },
480
+ previewToDialog (flag) {
481
+ if (!flag) {
482
+ this.$refs.previewPdf.previewKnowledgeId = ""
483
+ } else {
484
+ this.$refs.previewPdf.previewKnowledgeId = this.previewKnowledgeId
485
+ }
486
+ this.$emit('previewToDialog', flag, this.previewKnowledgeId, this.previewKnowledge)
487
+ },
488
+ clearKnowledgeId () {
489
+ this.previewKnowledgeId = "";
490
+ },
491
+ recommendQues (item, knowledgeId) {
492
+ this.$emit('recommendQues', item, knowledgeId)
493
+ },
494
+ clickFloder(item) {
495
+ this.$emit('clickFloder', item)
496
+ },
497
+ previewClickFloder() {
498
+ let item = null
499
+ this.msg.content.list.forEach(element => {
500
+ if(element.knowledgeId == this.previewKnowledgeId) {
501
+ item = element
502
+ }
503
+ });
504
+ this.$emit('clickFloder', item)
505
+ }
506
+ }
507
+ }
508
+ </script>
509
+
510
+ <style scoped lang="less">
511
+ .answer-docknowledge {
512
+ min-width: 100px;
513
+ background: #ffffff;
514
+
515
+ .answer-docknowledge-header {
516
+ .tips {
517
+ width: 154px;
518
+ height: 22px;
519
+ background: #366aff;
520
+ border-radius: 5px;
521
+ text-align: center;
522
+ line-height: 22px;
523
+ color: #fff;
524
+ font-size: 12px;
525
+ margin-bottom: 7px;
526
+ }
527
+
528
+ .answer-text {
529
+ // font-size: 13px;
530
+ text-align: left;
531
+ line-height: 25px;
532
+ padding: 0px 0px 12px 0px;
533
+
534
+ .aci-view {
535
+ // font-size: 13px;
536
+ display: inline-block;
537
+ // margin-left: 5px;
538
+ color: #366aff;
539
+ cursor: pointer;
540
+ }
541
+ }
542
+
543
+ &.bgc {
544
+ padding: 10px;
545
+ background: #eef1ff;
546
+ border-radius: 10px;
547
+ margin-bottom: 16px;
548
+
549
+ .answer-text {
550
+ padding: 0;
551
+ }
552
+ }
553
+
554
+ .answer-kn-image-box {
555
+ margin-bottom: 10px;
556
+ }
557
+ }
558
+
559
+
560
+ .ad-list-recognition {
561
+ display: flex;
562
+ align-items: center;
563
+ flex-wrap: wrap;
564
+ }
565
+
566
+ .libang_list_recognition {
567
+ display: flex;
568
+ align-items: center;
569
+ flex-wrap: wrap;
570
+ }
571
+
572
+ .ad-list {
573
+ .ad-list-cell {
574
+ border-top: solid 1px #eeeeee;
575
+ padding: 10px 0 10px;
576
+
577
+ .alc-title {
578
+ display: flex;
579
+ flex-wrap: wrap;
580
+ align-items: center;
581
+ justify-content: space-between;
582
+ line-height: 16px;
583
+
584
+ .alc-box {
585
+ display: flex;
586
+ align-items: center;
587
+ justify-content: space-between;
588
+ // font-size: 12px;
589
+ width: 100%;
590
+
591
+ .alc-source-left {
592
+ display: flex;
593
+ align-items: center;
594
+
595
+ .source-form {
596
+ width: 34px;
597
+ flex: none;
598
+ color: #a9b3c6;
599
+ }
600
+ }
601
+
602
+ .alc-content-text {
603
+ width: 55px;
604
+ flex: none;
605
+
606
+ .aci-view {
607
+ color: #366aff;
608
+ cursor: pointer;
609
+ }
610
+ }
611
+
612
+ .alc-title-from {
613
+ line-height: 22px;
614
+ word-break: break-all !important;
615
+ text-align: left;
616
+ flex: auto;
617
+ display: flex;
618
+ justify-content: flex-start;
619
+ }
620
+ }
621
+
622
+ .alc-box-introduction {
623
+ overflow: hidden;
624
+ text-overflow: ellipsis;
625
+ display: -webkit-box;
626
+ -webkit-line-clamp: 3;
627
+ -webkit-box-orient: vertical;
628
+ margin-top: 10px;
629
+ color: #616161;
630
+ // font-size: 12px;
631
+ line-height: 24px;
632
+ text-align: left;
633
+
634
+ img {
635
+ width: 50px;
636
+ height: 50px;
637
+ margin: 10px;
638
+ cursor: pointer;
639
+ }
640
+ }
641
+
642
+ .alc-box-introduction-previewImage {
643
+ width: 100%;
644
+ display: block;
645
+ overflow: hidden;
646
+ text-overflow: ellipsis;
647
+ display: -webkit-box;
648
+ -webkit-line-clamp:3;
649
+ -webkit-box-orient:vertical;
650
+ margin-top: 10px;
651
+ color: #616161;
652
+ // font-size: 12px;
653
+ line-height: 24px;
654
+ text-align: left;
655
+ img {
656
+ max-width: 300px;
657
+ width: 100%;
658
+ max-height: 150px;
659
+ margin: 10px;
660
+ cursor: pointer;
661
+ }
662
+ }
663
+
664
+ .alc-updateTime {
665
+ display: flex;
666
+ align-items: center;
667
+ justify-content: space-between;
668
+ font-size: 13px;
669
+ width: 100%;
670
+ margin-top: 10px;
671
+
672
+ .upload-source {
673
+ flex: none;
674
+ height: 18px;
675
+ line-height: 18px;
676
+ background: #e9f9f8;
677
+ border: 1px solid #aff2cd;
678
+ border-radius: 2px;
679
+ display: flex;
680
+ align-items: center;
681
+ justify-content: center;
682
+ padding: 0 8px;
683
+ color: #00c2bb;
684
+ }
685
+
686
+ .time {
687
+ color: #999999;
688
+ margin-left: 10px;
689
+ }
690
+
691
+ .alc-content-text {
692
+ color: #366aff;
693
+ cursor: pointer;
694
+ }
695
+ }
696
+
697
+ .alc-title-icon {
698
+ margin: 0 2px;
699
+ width: 18px;
700
+ height: 18px;
701
+ flex: none;
702
+ }
703
+
704
+ .alc-title-updateTime {
705
+ text-align: right;
706
+ color: #999999;
707
+ // font-size: 13px;
708
+ }
709
+ }
710
+
711
+ .alc-content {
712
+ .alc-title-updateTime {
713
+ margin-top: 6px;
714
+ display: block;
715
+ text-align: right;
716
+ color: #999999;
717
+ // font-size: 13px;
718
+ }
719
+
720
+ .alc-content-text {
721
+ margin-bottom: 6px;
722
+ width: 55px;
723
+ flex: none;
724
+
725
+ .aci-view {
726
+ display: inline-block;
727
+ margin-left: 30px;
728
+ color: #366aff;
729
+ cursor: pointer;
730
+ }
731
+ }
732
+
733
+ .alc-content-info {
734
+ display: flex;
735
+ flex-wrap: wrap;
736
+ justify-content: space-between;
737
+
738
+ .alcc-box {
739
+ display: flex;
740
+ flex-wrap: wrap;
741
+ color: #999999;
742
+
743
+ .aci-owner {
744
+ margin-right: 20px;
745
+ }
746
+
747
+ .aci-enterprise {
748
+ margin-right: 20px;
749
+ }
750
+ }
751
+ }
752
+ }
753
+ }
754
+
755
+ .ad-list-cell-recognition {
756
+ .alc-source-name {
757
+ flex: none;
758
+ padding: 3px;
759
+ margin-right: 5px;
760
+ margin-bottom: 5px;
761
+ background: #f2f6ff;
762
+ border-radius: 5px;
763
+ display: flex;
764
+ align-items: center;
765
+ justify-content: space-between;
766
+ cursor: pointer;
767
+
768
+ img {
769
+ vertical-align: middle;
770
+ // width: 16px;
771
+ // height: 16px;
772
+ margin: 0 3px 0 5px;
773
+ }
774
+
775
+ .alc-title-from {
776
+ // margin-right: 5px;
777
+ max-width: 240px;
778
+ overflow: hidden;
779
+ text-overflow: ellipsis;
780
+ white-space: nowrap;
781
+ }
782
+
783
+ .upload-source {
784
+ margin-right: 5px;
785
+ }
786
+
787
+ i {
788
+ font-size: 12px;
789
+ }
790
+ }
791
+ }
792
+
793
+ .ad-loadmore {
794
+ width: 100%;
795
+ height: 40px;
796
+ display: flex;
797
+ align-items: center;
798
+ justify-content: center;
799
+ // background: #FFFFFF;
800
+ color: #366aff;
801
+ font-size: 14px;
802
+ margin-top: 8px;
803
+ cursor: pointer;
804
+ }
805
+ }
806
+
807
+ .libang_list {
808
+ .libang_list_cell {
809
+ border-top: solid 1px #eeeeee;
810
+ padding: 10px 0 10px;
811
+
812
+ .libang_title {
813
+ display: flex;
814
+ flex-wrap: wrap;
815
+ align-items: center;
816
+ justify-content: space-between;
817
+ line-height: 16px;
818
+
819
+ .libang_box {
820
+ display: flex;
821
+ align-items: center;
822
+ justify-content: space-between;
823
+ // font-size: 12px;
824
+ width: 100%;
825
+
826
+ .libang_source_left {
827
+ display: flex;
828
+ align-items: center;
829
+
830
+ .source-form {
831
+ width: 34px;
832
+ flex: none;
833
+ color: #a9b3c6;
834
+ }
835
+ }
836
+
837
+ .alc-content-text {
838
+ width: 55px;
839
+ flex: none;
840
+
841
+ .aci-view {
842
+ color: #366aff;
843
+ cursor: pointer;
844
+ }
845
+ }
846
+
847
+ .libang_title_from {
848
+ line-height: 22px;
849
+ word-break: break-all !important;
850
+ text-align: left;
851
+ flex: auto;
852
+ display: flex;
853
+ justify-content: flex-start;
854
+ }
855
+ }
856
+
857
+ .libang_box_introduction {
858
+ overflow: hidden;
859
+ text-overflow: ellipsis;
860
+ display: -webkit-box;
861
+ -webkit-line-clamp: 3;
862
+ -webkit-box-orient: vertical;
863
+ margin-top: 10px;
864
+ color: #616161;
865
+ // font-size: 12px;
866
+ line-height: 24px;
867
+ text-align: left;
868
+
869
+ img {
870
+ width: 50px;
871
+ height: 50px;
872
+ margin: 10px;
873
+ cursor: pointer;
874
+ }
875
+ }
876
+
877
+ .libang_box_introduction_previewImage {
878
+ overflow: hidden;
879
+ text-overflow: ellipsis;
880
+ display: -webkit-box;
881
+ -webkit-line-clamp: 3;
882
+ -webkit-box-orient: vertical;
883
+ margin-top: 10px;
884
+ color: #616161;
885
+ // font-size: 12px;
886
+ line-height: 24px;
887
+ text-align: left;
888
+
889
+ img {
890
+ max-width: 300px;
891
+ width: 100%;
892
+ max-height: 150px;
893
+ margin: 10px;
894
+ cursor: pointer;
895
+ }
896
+ }
897
+
898
+ .libang_updateTime {
899
+ display: flex;
900
+ align-items: center;
901
+ justify-content: space-between;
902
+ font-size: 13px;
903
+ width: 100%;
904
+ margin-top: 10px;
905
+ .libang_updataTime_left {
906
+ width: calc(100% - 40px);
907
+ display: flex;
908
+ align-items: center;
909
+ .upload-source {
910
+ flex: none;
911
+ height: 18px;
912
+ line-height: 18px;
913
+ background: #e9f9f8;
914
+ border: 1px solid #aff2cd;
915
+ border-radius: 2px;
916
+ display: flex;
917
+ align-items: center;
918
+ justify-content: center;
919
+ padding: 0 8px;
920
+ color: #00c2bb;
921
+ }
922
+ .libang_floder {
923
+ width:calc(100% - 90px);
924
+ // margin-left: 10px;
925
+ overflow: hidden;
926
+ text-overflow: ellipsis;
927
+ white-space: nowrap;
928
+ color: #366aff;
929
+ cursor: pointer;
930
+ text-align: left;
931
+ i {
932
+ margin-left: 8px;
933
+ }
934
+ }
935
+ }
936
+ .libang_content_text {
937
+ color: #366aff;
938
+ cursor: pointer;
939
+ }
940
+ .time {
941
+ color: #999999;
942
+ margin-left: 10px;
943
+ }
944
+ }
945
+ .alc-title-icon {
946
+ margin: 0 2px;
947
+ width: 18px;
948
+ height: 18px;
949
+ flex: none;
950
+ }
951
+
952
+ .alc-title-updateTime {
953
+ text-align: right;
954
+ color: #999999;
955
+ // font-size: 13px;
956
+ }
957
+ }
958
+
959
+ .alc-content {
960
+ .alc-title-updateTime {
961
+ margin-top: 6px;
962
+ display: block;
963
+ text-align: right;
964
+ color: #999999;
965
+ // font-size: 13px;
966
+ }
967
+
968
+ .alc-content-text {
969
+ margin-bottom: 6px;
970
+ width: 55px;
971
+ flex: none;
972
+
973
+ .aci-view {
974
+ display: inline-block;
975
+ margin-left: 30px;
976
+ color: #366aff;
977
+ cursor: pointer;
978
+ }
979
+ }
980
+
981
+ .alc-content-info {
982
+ display: flex;
983
+ flex-wrap: wrap;
984
+ justify-content: space-between;
985
+
986
+ .alcc-box {
987
+ display: flex;
988
+ flex-wrap: wrap;
989
+ color: #999999;
990
+
991
+ .aci-owner {
992
+ margin-right: 20px;
993
+ }
994
+
995
+ .aci-enterprise {
996
+ margin-right: 20px;
997
+ }
998
+ }
999
+ }
1000
+ }
1001
+ }
1002
+
1003
+ .libang_list_cell_recognition {
1004
+ background: #f2f6ff;
1005
+ display: flex;
1006
+ align-items: center;
1007
+ justify-content: space-between;
1008
+ padding: 3px;
1009
+ margin-right: 5px;
1010
+ margin-bottom: 5px;
1011
+ border-radius: 5px;
1012
+ cursor: pointer;
1013
+ font-size: 14px;
1014
+
1015
+ .libang_list_cell_left {
1016
+ margin-right: 5px;
1017
+ .libang_source_name {
1018
+ display: flex;
1019
+ align-items: center;
1020
+ height: 20px;
1021
+ margin-bottom: 2px;
1022
+ img {
1023
+ vertical-align: middle;
1024
+ // width: 16px;
1025
+ // height: 16px;
1026
+ margin: 0 3px;
1027
+ }
1028
+
1029
+ .libang_title_from {
1030
+ max-width: 226px;
1031
+ overflow: hidden;
1032
+ text-overflow: ellipsis;
1033
+ white-space: nowrap;
1034
+ line-height: 20px;
1035
+ }
1036
+ }
1037
+ .libang_source_floder {
1038
+ max-width: calc(226px - 24px);
1039
+ text-align: left;
1040
+ color: #366aff;
1041
+ overflow: hidden;
1042
+ text-overflow: ellipsis;
1043
+ white-space: nowrap;
1044
+ cursor: pointer;
1045
+ .iconfont {
1046
+ margin: 0 8px;
1047
+ }
1048
+ }
1049
+ }
1050
+ i {
1051
+ font-size: 12px;
1052
+ }
1053
+ }
1054
+
1055
+ .ad-loadmore {
1056
+ width: 100%;
1057
+ height: 40px;
1058
+ display: flex;
1059
+ align-items: center;
1060
+ justify-content: center;
1061
+ // background: #FFFFFF;
1062
+ color: #366aff;
1063
+ font-size: 14px;
1064
+ margin-top: 8px;
1065
+ cursor: pointer;
1066
+ }
1067
+ }
1068
+ }</style>