askbot-dragon 1.5.80-beta → 1.5.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.
- package/package.json +1 -1
- package/src/assets/js/hammer.js +2 -13
- package/src/assets/less/converSationContainer/common.less +0 -7
- package/src/components/AnswerDocknowledge.vue +3 -42
- package/src/components/ConversationContainer.vue +14 -46
- package/src/components/askVideo.vue +1 -24
- package/src/components/associationIntention.vue +4 -1
- package/src/components/formTemplate.vue +18 -4
- package/src/components/pdfPosition.vue +62 -261
- package/src/components/previewPdf.vue +8 -21
- package/src/components/newPdfPosition.vue +0 -878
package/package.json
CHANGED
package/src/assets/js/hammer.js
CHANGED
|
@@ -3,15 +3,6 @@ export function zoomElement (el) {
|
|
|
3
3
|
let store = {
|
|
4
4
|
scale: 1
|
|
5
5
|
};
|
|
6
|
-
if (!el){
|
|
7
|
-
return
|
|
8
|
-
}
|
|
9
|
-
let scale = 1;
|
|
10
|
-
if (el.style.transform){
|
|
11
|
-
let transForm = el.style.transform;
|
|
12
|
-
var values = transForm.split('(')[1].split(')')[0].split(',');
|
|
13
|
-
scale = values[0] ? values[0] : 1
|
|
14
|
-
}
|
|
15
6
|
// 缩放事件的处理
|
|
16
7
|
el.addEventListener('touchstart', function (event) {
|
|
17
8
|
let touches = event.touches;
|
|
@@ -76,15 +67,13 @@ export function zoomElement (el) {
|
|
|
76
67
|
newScale = 3;
|
|
77
68
|
}
|
|
78
69
|
// 最小缩放比例限制
|
|
79
|
-
if(newScale <
|
|
80
|
-
newScale =
|
|
70
|
+
if(newScale < 1) {
|
|
71
|
+
newScale = 1;
|
|
81
72
|
}
|
|
82
73
|
// 记住使用的缩放值
|
|
83
74
|
store.scale = newScale;
|
|
84
75
|
// 图像应用缩放效果
|
|
85
76
|
el.style.transform = 'scale(' + newScale + ')';
|
|
86
|
-
el.style.transformOrigin = 'top left'
|
|
87
|
-
|
|
88
77
|
}
|
|
89
78
|
});
|
|
90
79
|
document.addEventListener('touchend', function () {
|
|
@@ -35,13 +35,6 @@
|
|
|
35
35
|
border-radius: 6px;
|
|
36
36
|
background-color: #bfceec !important;
|
|
37
37
|
}
|
|
38
|
-
@media screen and (max-width: 767px){
|
|
39
|
-
::-webkit-scrollbar {
|
|
40
|
-
width: 0;
|
|
41
|
-
height: 0;
|
|
42
|
-
background-color:@system_bordercolor_4;
|
|
43
|
-
}
|
|
44
|
-
}
|
|
45
38
|
|
|
46
39
|
// 弹窗body
|
|
47
40
|
.el-dialog__body{
|
|
@@ -67,7 +67,7 @@
|
|
|
67
67
|
</div>
|
|
68
68
|
</div>
|
|
69
69
|
</div>
|
|
70
|
-
<previewPdf ref="previewPdf" :url="previewHref" :
|
|
70
|
+
<previewPdf ref="previewPdf" :url="previewHref" :sourceFileType="sourceFileType" officePreviewType="pdf"></previewPdf>
|
|
71
71
|
</div>
|
|
72
72
|
</template>
|
|
73
73
|
|
|
@@ -151,11 +151,6 @@ export default {
|
|
|
151
151
|
MP3: "audio",
|
|
152
152
|
yqhtml: "yqhtml",
|
|
153
153
|
feishuhtml:"feishuhtml"
|
|
154
|
-
},
|
|
155
|
-
watermark: {
|
|
156
|
-
textWatermarkValue:'',
|
|
157
|
-
visitorWatermarkValue:'',
|
|
158
|
-
source:""
|
|
159
154
|
}
|
|
160
155
|
}
|
|
161
156
|
},
|
|
@@ -203,9 +198,6 @@ export default {
|
|
|
203
198
|
methods: {
|
|
204
199
|
//预览图片
|
|
205
200
|
lookAttach(url, item, event) {
|
|
206
|
-
// console.log(item.knowledgeId);
|
|
207
|
-
// this.$http.get("/knowledge-api/internal/knowledgeBaseStructure/" + "642ffbccde420e2772f7787b")
|
|
208
|
-
// debugger
|
|
209
201
|
event.preventDefault();
|
|
210
202
|
if (this.isAskLightning == 1 && !this.isApp){
|
|
211
203
|
window.parent.postMessage({
|
|
@@ -238,10 +230,8 @@ export default {
|
|
|
238
230
|
}
|
|
239
231
|
this.$http.post(httpUrl, {
|
|
240
232
|
"fileInOssPath":url
|
|
241
|
-
}).then(
|
|
233
|
+
}).then(res =>{
|
|
242
234
|
if(res.data.code == '0') {
|
|
243
|
-
this.watermark = await this.getknowledgeBaseStructure(item.knowledgeId);
|
|
244
|
-
this.watermark.source = item.source;
|
|
245
235
|
this.previewHref = res.data.data;
|
|
246
236
|
this.sourceFileType = url.substring(url.lastIndexOf('.'))
|
|
247
237
|
let isOhmPc = sessionStorage.getItem('isOhmPc')
|
|
@@ -254,18 +244,7 @@ export default {
|
|
|
254
244
|
}
|
|
255
245
|
this.$refs.previewPdf.fileType = type
|
|
256
246
|
this.$refs.previewPdf.tagIds = item.tagIds
|
|
257
|
-
this.$refs.previewPdf.isMessageRecord = this.isMessageRecord ? true : false
|
|
258
|
-
let index = url.indexOf("?");
|
|
259
|
-
let newFileInOssPath = url;
|
|
260
|
-
if (index !== -1){
|
|
261
|
-
newFileInOssPath = url.substring(0, url.indexOf("?"))
|
|
262
|
-
}
|
|
263
|
-
let fileName = newFileInOssPath.substring(newFileInOssPath.lastIndexOf('.'))
|
|
264
|
-
if (fileName === '.doc' || fileName === '.docx' || fileName === '.txt'|| fileName === '.html'){
|
|
265
|
-
this.$refs.previewPdf.fileName = fileName;
|
|
266
|
-
} else {
|
|
267
|
-
this.$refs.previewPdf.fileName = '';
|
|
268
|
-
}
|
|
247
|
+
this.$refs.previewPdf.isMessageRecord = this.isMessageRecord ? true : false
|
|
269
248
|
if(item.tagIds && item.tagIds.length != 0) {
|
|
270
249
|
this.$refs.previewPdf.loading = false
|
|
271
250
|
return
|
|
@@ -316,24 +295,6 @@ export default {
|
|
|
316
295
|
// return res.data
|
|
317
296
|
})
|
|
318
297
|
// return imgurl
|
|
319
|
-
},
|
|
320
|
-
async getknowledgeBaseStructure(knowledgeId) {
|
|
321
|
-
let watermark = {
|
|
322
|
-
textWatermarkValue:'',
|
|
323
|
-
visitorWatermarkValue:''
|
|
324
|
-
}
|
|
325
|
-
await this.$http.get("/knowledge-api/internal/knowledgeBaseStructure/" + knowledgeId).then( async res =>{
|
|
326
|
-
if(res.data) {
|
|
327
|
-
watermark.textWatermarkValue = await res.data.textWatermarkValue
|
|
328
|
-
if(res.data.visitorWatermark) {
|
|
329
|
-
let userInfo = sessionStorage.getItem('userInfo') || localStorage.getItem('userInfo')
|
|
330
|
-
if(userInfo && userInfo !== 'null') {
|
|
331
|
-
watermark.visitorWatermarkValue = JSON.parse(userInfo).realName
|
|
332
|
-
}
|
|
333
|
-
}
|
|
334
|
-
}
|
|
335
|
-
})
|
|
336
|
-
return watermark
|
|
337
298
|
}
|
|
338
299
|
}
|
|
339
300
|
}
|
|
@@ -34,7 +34,7 @@
|
|
|
34
34
|
</div> -->
|
|
35
35
|
|
|
36
36
|
<text-message :text="text" @submitClick="submitClick"></text-message>
|
|
37
|
-
<answer-docknowledge :isAskLightning="2" :msg="answerDocknowledge"></answer-docknowledge>
|
|
37
|
+
<!-- <answer-docknowledge :isAskLightning="2" :msg="answerDocknowledge"></answer-docknowledge> -->
|
|
38
38
|
<!-- <voice-component @closeVoice="closeVoice">
|
|
39
39
|
<div slot="voiceTip">
|
|
40
40
|
松开发送
|
|
@@ -108,7 +108,7 @@ import AnswerVoice from "@/components/AnswerVoice";
|
|
|
108
108
|
// import ChatContent from "./chatContent";
|
|
109
109
|
// import FeedBack from '@/components/feedBack'
|
|
110
110
|
// 知识类型
|
|
111
|
-
import AnswerDocknowledge from "./AnswerDocknowledge.vue";
|
|
111
|
+
// import AnswerDocknowledge from "./AnswerDocknowledge.vue";
|
|
112
112
|
export default {
|
|
113
113
|
name: 'ConversationContainer',
|
|
114
114
|
components: {
|
|
@@ -134,7 +134,7 @@ export default {
|
|
|
134
134
|
FormTemplate,
|
|
135
135
|
// FileType,
|
|
136
136
|
// ChatContent,
|
|
137
|
-
AnswerDocknowledge,
|
|
137
|
+
// AnswerDocknowledge,
|
|
138
138
|
},
|
|
139
139
|
props: {
|
|
140
140
|
messages: Array
|
|
@@ -191,48 +191,17 @@ export default {
|
|
|
191
191
|
answerDocknowledge:
|
|
192
192
|
// {"content":{"knowledgeId":"64915d6e098ec248701da267","actionType":"answer_doc_knowledge","text":"跳舞不仅要有实力,还要有好的穿搭,本文针对街舞爱好者提供了穿搭指南,给你带来灵感和帮助!","list":[{"tagIds":[],"format":"html","updateTime":"2023-06-20 16:03:58","source":"WECHAT","url":"https://guoranwisdom.oss-cn-zhangjiakou.aliyuncs.com/137993c6d830416696bbd771fc61d423/1937/2023/06/20/16/03/微信同步/52720/501775e41a724d7da06e66b3b4686407.html","knowledgeId":"64915d6e098ec248701da267","from":"跳舞要有范儿,穿搭占一半!快来get你的街舞穿搭指南~"}],"renderType":0,"type":0,"isKnowledgeSummary":true},"type":"answer_doc_knowledge","sessionId":1687251699065,"keyId":"1a079f48-ace3-4064-89b4-8a292c6a8a93_________","isKnowledgeSummary":true},
|
|
193
193
|
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
"knowledgeId": null,
|
|
206
|
-
"actionType": "answer_doc_knowledge",
|
|
207
|
-
"images": null,
|
|
208
|
-
"knowledgePartId": null,
|
|
209
|
-
"srcContentId": null,
|
|
210
|
-
"text": "新能源车是指采用新型能源的轿车、客车、货车等机动车辆,包括纯电动汽车、插电式混合动力汽车和燃料电池汽车。根据数据显示,2020年我国新能源汽车销售量达到139万辆,同比增长10.9%。预计2021年新能源车市场将继续保持高速增长,销售量有望超过200万辆。政府对新能源汽车实行补贴政策,同时逐步放松对新能源车的限购和限行政策。此外,中国汽车企业在新能源车领域的技术研发能力也不断提升,各大品牌纷纷推出新能源车型,采用更优秀的动力电池和电控系统,提高了车辆的续航里程。因此,新能源车市场发展前景广阔。",
|
|
211
|
-
"list": [
|
|
212
|
-
{
|
|
213
|
-
"owner": null,
|
|
214
|
-
"tagId": "6525183560177f6223d52a14",
|
|
215
|
-
"enterprise": null,
|
|
216
|
-
"tagIds": [
|
|
217
|
-
"6525183560177f6223d52a14"
|
|
218
|
-
],
|
|
219
|
-
"format": "docx",
|
|
220
|
-
"srcContentId": "99cada54a02161f979acc28c5b8b913e",
|
|
221
|
-
"updateTime": "2023-10-10 17:24:05",
|
|
222
|
-
"source": "CORP_LOCAL_FILE",
|
|
223
|
-
"srcContent": "新能源车指的是采用新型能源的轿车、客车、货车等机动车辆。目前主要的新能源车包括纯电动汽车、插电式混合动力汽车、燃料电池汽车等。以下是对新能源车的分析报告:市场发展趋势:随着环保和能源安全意识的增强,新能源车市场呈现快速发展态势。数据显示,2020年我国新能源汽车销售量达到139万辆,同比增长10.9%。预计2021年新能源车市场仍将保持高速增长,销售量有望达到200万辆以上。政策扶持力度加大:我国政府对新能源汽车实行补贴政策,以鼓励消费者选择绿色出行方式。此外,对新能源车限购、限行等政策也逐步放松。政策扶持的加大将进一步促进新能",
|
|
224
|
-
"url": "http://guoranwisdom.oss-cn-zhangjiakou.aliyuncs.com/43aadcaac45f4be19b63fd18ca68f2e6/2023/10/10/17/23/a27c5c1dd534d180c5512c907d5c9888/新能源车分析报告 (1).docx?uploadId=0921CB01AB5847E8BEF44730EE5DACF7",
|
|
225
|
-
"knowledgeId": "6525182f002ff5198983a90c",
|
|
226
|
-
"knowledgePartId": "YfHmGIsBvcIPGxbfkvwK",
|
|
227
|
-
"from": "新能源车分析报告 (1)",
|
|
228
|
-
"introduction": "新能源车指的是采用新型能源的轿车、客车、货车等机动车辆。目前主要的新能源车包括纯电动汽车、插电式混合动力汽车、燃料电池汽车等。以下是对新能源车的分析报告:市场发展趋势:随着环保和能源安全意识的增强,新能源车市场呈现快速发展态势。数据显示,2020年我国新能源汽车销售量达到139万辆,同比增长10.9%。预计2021年新能源车市场仍将保持高速增长,销售量有望达到200万辆以上。政策扶持力度加大:我国政府对新能源汽车实行补贴政策,以鼓励消费者选择绿色出行方式。此外,对新能源车限购、限行等政策也逐步放松。政策扶持的加大将进一步促进新能"
|
|
229
|
-
}
|
|
230
|
-
],
|
|
231
|
-
"renderType": 0,
|
|
232
|
-
"type": 0,
|
|
233
|
-
"srcContent": null
|
|
234
|
-
}
|
|
235
|
-
},
|
|
194
|
+
{
|
|
195
|
+
"content": {
|
|
196
|
+
"images": [{ url: 'https://static.guoranbot.com/images/knowledge/e0f6898c6b0d47fa98e8f71ceab1bde8/安全标志--禁止标志.png' }],
|
|
197
|
+
"actionType": "answer_doc_knowledge",
|
|
198
|
+
"text": "中国的省份名称有湖北省、广西壮族自治区等。",
|
|
199
|
+
"list": [{ "tagIds": [], "format": "yqhtml", "srcContentId": "8ee0fa9bb5a89ea01f588843589bf931", "updateTime": "2023-04-14 20:15:50", "source": "YUQUE", "srcContent": "功能概述分院科室的建立。分院科室医生关联。分院科室建立时,科室编码需要与集团提供的科室编码保持一致。科室维护进入扁鹊基础配置模块,如图进入科室维护界面进行科室新增输入科室信息进行科室增加。", "url": "https://guoranwisdom.oss-cn-zhangjiakou.aliyuncs.com/yuque/7faaefde11374c7992c377731ea4dddc/dinga77cc098b0b5e113ee0f45d8e4f7c288/2023/4/14/19/54/31/acc2421dcfd04db39eba0c37e7d3b580.html", "knowledgeId": "643940bb6cbe816b83ebbaaf", "knowledgePartId": "lPexf4cBYkmDoUE2eSUt", "from": "2.3 科室", "introduction": "功能概述分院科室的建立。分院科室医生关联。分院科室建立时,科室编码需要与集团提供的科室编码保持一致。科室维护进入扁鹊基础配置模块,如图进入科室维护界面进行科室新增输入科室信息进行科室增加。" }, { "tagIds": [], "format": "feishuhtml", "srcContentId": "8ee0fa9bb5a89ea01f588843589bf931", "updateTime": "2023-04-13 23:19:48", "source": "YUQUE", "srcContent": "功能概述分院科室的建立。分院科室医生关联。分院科室建立时,科室编码需要与集团提供的科室编码保持一致。科室维护进入扁鹊基础配置模块,如图进入科室维护界面进行科室新增输入科室信息进行科室增加。", "url": "https://guoranwisdom.oss-cn-zhangjiakou.aliyuncs.com/yuque/7faaefde11374c7992c377731ea4dddc/dinga77cc098b0b5e113ee0f45d8e4f7c288/2023/4/13/22/20/40/0e48cc7b15b34d2f84fe49fd1a89d606.html", "knowledgeId": "643817509ab4545bef50db64", "knowledgePartId": "NeYze4cBh77-s6lwjWOl", "from": "2.12 重要异常科室对照", "introduction": "功能概述分院科室的建立。分院科室医生关联。分院科室建立时,科室编码需要与集团提供的科室编码保持一致。科室维护进入扁鹊基础配置模块,如图进入科室维护界面进行科室新增输入科室信息进行科室增加。" }, { "tagIds": ['12312313123'], "format": "yqhtml", "srcContentId": "8ee0fa9bb5a89ea01f588843589bf931", "updateTime": "2023-04-13 23:19:02", "source": "YUQUE", "srcContent": "功能概述分院科室的建立。分院科室医生关联。分院科室建立时,科室编码需要与集团提供的科室编码保持一致。科室维护进入扁鹊基础配置模块,如图进入科室维护界面进行科室新增输入科室信息进行科室增加。", "url": "https://guoranwisdom.oss-cn-zhangjiakou.aliyuncs.com/yuque/7faaefde11374c7992c377731ea4dddc/dinga77cc098b0b5e113ee0f45d8e4f7c288/2023/4/13/22/20/18/5cdf1295ec1649f6ab73948aa82ea810.html", "knowledgeId": "643817509ab4545bef50db58", "knowledgePartId": "Hvcye4cBYkmDoUE21h6V", "from": "2.3 科室", "introduction": "功能概述分院科室的建立。分院科室医生关联。分院科室建立时,科室编码需要与集团提供的科室编码保持一致。科室维护进入扁鹊基础配置模块,如图进入科室维护界面进行科室新增输入科室信息进行科室增加。" }, { "tagId": "6475eab868110215ab821a7c", "tagIds": ["6475eab868110215ab821a7c"], "format": "xlsx", "srcContentId": "0bf639060655ff3ec217484a2fc7827d", "updateTime": "2023-05-30 20:28:21", "source": "CORP_LOCAL_FILE", "srcContent": "产品:外观,解释:VX50有两种套餐可下单: 套餐一:只购买VX50终端设备,不包含摄像头、麦克风 套餐二:除购买VX50终端设备外,可选购SC701云台摄像头及MC30/MC31麦克风", "url": "https://guoranwisdom.oss-cn-zhangjiakou.aliyuncs.com/5ecf2fcd704541149201ab9c1c31162d/2023/05/30/20/11/85b7b2a5f61e2b060387656e88c02d50/VX30与VX50对比表.xlsx", "knowledgeId": "6475e7eac724c54c46cbfa2d", "knowledgePartId": "T_uhbIgB3v-0X8BLeDAh", "from": "VX30与VX50对比表", "introduction": "产品:外观,解释:VX50有两种套餐可下单: 套餐一:只购买VX50终端设备,不包含摄像头、麦克风 套餐二:除购买VX50终端设备外,可选购SC701云台摄像头及MC30/MC31麦克风" },],
|
|
200
|
+
"renderType": 0,
|
|
201
|
+
"type": 0
|
|
202
|
+
},
|
|
203
|
+
"type": "answer_doc_knowledge"
|
|
204
|
+
},
|
|
236
205
|
ActionAiGuideObj: {
|
|
237
206
|
// 智能引导
|
|
238
207
|
type: "answer_intellect_guide",
|
|
@@ -4665,7 +4634,6 @@ export default {
|
|
|
4665
4634
|
url:
|
|
4666
4635
|
'https://guoranopen-zjk.oss-cn-zhangjiakou.aliyuncs.com/2021/08/24/07/35/41221223-c180-4f3f-bdc8-94875b693965/WeChat_20210719215122.mp4',
|
|
4667
4636
|
videoFlag: false,
|
|
4668
|
-
nodownload: false,
|
|
4669
4637
|
videoUploadPercent: 0,
|
|
4670
4638
|
isShowUploadVideo: true,
|
|
4671
4639
|
recommend: {
|
|
@@ -15,16 +15,13 @@
|
|
|
15
15
|
:controlslist="nodownload&&'nodownload'"
|
|
16
16
|
:raw-controls="true"
|
|
17
17
|
x5-video-player-type="h5-page"
|
|
18
|
-
style="object-fit: contain;width: calc(100vw -
|
|
18
|
+
style="object-fit: contain;width: calc(100vw - 139px);height: 160px;background-color: black;border-radius: 25px;max-width: 230px;padding-left: 10px"
|
|
19
19
|
preload
|
|
20
20
|
:poster="videoSrc+'?spm=qipa250&x-oss-process=video/snapshot,t_1000,f_jpg,w_0,h_0,m_fast'"
|
|
21
21
|
class="video-player vjs-custom-skin"
|
|
22
22
|
:id="msg.id+'key'">
|
|
23
23
|
<source :src="videoSrc"/>
|
|
24
24
|
</video>
|
|
25
|
-
<div v-show="!nodownload" class="dragon-video-download">
|
|
26
|
-
<a :href="msg.content.url" download><span class="el-icon-download"></span></a>
|
|
27
|
-
</div>
|
|
28
25
|
<div id="output"></div>
|
|
29
26
|
</div>
|
|
30
27
|
</template>
|
|
@@ -126,8 +123,6 @@
|
|
|
126
123
|
video::-webkit-media-controls-mute-button { display: none !important;}
|
|
127
124
|
#dragon-video{
|
|
128
125
|
position: relative;
|
|
129
|
-
width: calc(100vw - 109px);
|
|
130
|
-
max-width: 260px;
|
|
131
126
|
#outputVideo{
|
|
132
127
|
position: absolute;
|
|
133
128
|
top: 0px;
|
|
@@ -139,24 +134,6 @@ video::-webkit-media-controls-mute-button { display: none !important;}
|
|
|
139
134
|
}
|
|
140
135
|
|
|
141
136
|
}
|
|
142
|
-
.dragon-video-download{
|
|
143
|
-
position: absolute;
|
|
144
|
-
width: 40px;
|
|
145
|
-
height: 26px;
|
|
146
|
-
background-color: rgba(54, 106, 255, 0.5);
|
|
147
|
-
border-radius: 13px;
|
|
148
|
-
text-align: center;
|
|
149
|
-
bottom: 2px;
|
|
150
|
-
right: 6px;
|
|
151
|
-
a {
|
|
152
|
-
span {
|
|
153
|
-
height: 26px;
|
|
154
|
-
line-height: 26px;
|
|
155
|
-
display: block;
|
|
156
|
-
color: white;
|
|
157
|
-
}
|
|
158
|
-
}
|
|
159
|
-
}
|
|
160
137
|
}
|
|
161
138
|
|
|
162
139
|
</style>
|
|
@@ -233,7 +233,7 @@
|
|
|
233
233
|
this.$emit("onRadioClick", id, name, apikey,optionApiKey);
|
|
234
234
|
},
|
|
235
235
|
onImageClick(url){
|
|
236
|
-
this.$emit('onImageClick',
|
|
236
|
+
this.$emit('onImageClick',url)
|
|
237
237
|
},
|
|
238
238
|
msgContent(content){
|
|
239
239
|
console.debug('215',content)
|
|
@@ -343,6 +343,9 @@
|
|
|
343
343
|
display: block;
|
|
344
344
|
}
|
|
345
345
|
}
|
|
346
|
+
img {
|
|
347
|
+
max-width: 300px;
|
|
348
|
+
}
|
|
346
349
|
}
|
|
347
350
|
/deep/.el-drawer__body{
|
|
348
351
|
height: 100%;
|
|
@@ -1870,7 +1870,12 @@ export default {
|
|
|
1870
1870
|
if (type === 'TIME_PICKER') {
|
|
1871
1871
|
if(this.formList.form.formFieldRelation[i].value!==''&& this.formList.form.formFieldRelation[i].value!==null)
|
|
1872
1872
|
{
|
|
1873
|
-
|
|
1873
|
+
// 判断是否是时间戳 时间戳为字符串转换为Number
|
|
1874
|
+
var regex = /^\d{13}$/;
|
|
1875
|
+
if (regex.test(this.formList.form.formFieldRelation[i].value)){
|
|
1876
|
+
this.formList.form.formFieldRelation[i].value = Number(this.formList.form.formFieldRelation[i].value)
|
|
1877
|
+
}
|
|
1878
|
+
const dateTime = new Date(this.formList.form.formFieldRelation[i].value);
|
|
1874
1879
|
if (!this.formList.form.formFieldRelation[i].formField.extInfo.mold ||
|
|
1875
1880
|
this.formList.form.formFieldRelation[i].formField.extInfo.mold == 'TIME' ||
|
|
1876
1881
|
this.getMoldTime(this.formList.form.formFieldRelation[i].formField.formField) == 'TIME'){
|
|
@@ -1883,10 +1888,18 @@ export default {
|
|
|
1883
1888
|
this.extInfoFieldValue[this.formList.form.formFieldRelation[i].fieldId] = this.formList.form.formFieldRelation[i].value;
|
|
1884
1889
|
this.formList.form.formFieldRelation[i].value = new Date().getFullYear() + "-" + (new Date().getMonth() + 1) + "-" + new Date().getDate() + " " + this.formList.form.formFieldRelation[i].value;
|
|
1885
1890
|
} else {
|
|
1886
|
-
|
|
1891
|
+
if (regex.test(this.formList.form.formFieldRelation[i].value)){
|
|
1892
|
+
this.extInfoFieldValue[this.formList.form.formFieldRelation[i].fieldId] = dateTime
|
|
1893
|
+
} else {
|
|
1894
|
+
this.extInfoFieldValue[this.formList.form.formFieldRelation[i].fieldId] = this.formList.form.formFieldRelation[i].value
|
|
1895
|
+
}
|
|
1887
1896
|
}
|
|
1888
1897
|
} else {
|
|
1889
|
-
|
|
1898
|
+
if (regex.test(this.formList.form.formFieldRelation[i].value)){
|
|
1899
|
+
this.extInfoFieldValue[this.formList.form.formFieldRelation[i].fieldId] = dateTime.Format('hh:mm')
|
|
1900
|
+
} else {
|
|
1901
|
+
this.extInfoFieldValue[this.formList.form.formFieldRelation[i].fieldId] = this.formList.form.formFieldRelation[i].value
|
|
1902
|
+
}
|
|
1890
1903
|
}
|
|
1891
1904
|
}
|
|
1892
1905
|
else if (this.formList.form.formFieldRelation[i].formField.extInfo.mold == 'DATA_TIME' ||
|
|
@@ -2240,7 +2253,8 @@ export default {
|
|
|
2240
2253
|
}
|
|
2241
2254
|
let extInfo = {
|
|
2242
2255
|
extInfoFieldValue:this.extInfoFieldValue,
|
|
2243
|
-
attachmentList:this.attachmentList
|
|
2256
|
+
attachmentList:this.attachmentList,
|
|
2257
|
+
attachments: this.attachmentList.map(item =>{ return item.url})
|
|
2244
2258
|
}
|
|
2245
2259
|
this.$set(this.formShow,'extInfo',extInfo)
|
|
2246
2260
|
let newForm = JSON.parse(JSON.stringify(this.formShow));
|