askbot-dragon 1.6.76-beta → 1.6.76
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/README.md +27 -27
- package/babel.config.js +6 -6
- package/dragon.iml +7 -7
- package/package.json +58 -55
- package/public/index.html +75 -72
- package/public/pdfjs/cmaps/78-EUC-H.bcmap +0 -0
- package/public/pdfjs/cmaps/78-EUC-V.bcmap +0 -0
- package/public/pdfjs/cmaps/78-H.bcmap +0 -0
- package/public/pdfjs/cmaps/78-RKSJ-H.bcmap +0 -0
- package/public/pdfjs/cmaps/78-RKSJ-V.bcmap +0 -0
- package/public/pdfjs/cmaps/78-V.bcmap +0 -0
- package/public/pdfjs/cmaps/78ms-RKSJ-H.bcmap +0 -0
- package/public/pdfjs/cmaps/78ms-RKSJ-V.bcmap +0 -0
- package/public/pdfjs/cmaps/83pv-RKSJ-H.bcmap +0 -0
- package/public/pdfjs/cmaps/90ms-RKSJ-H.bcmap +0 -0
- package/public/pdfjs/cmaps/90ms-RKSJ-V.bcmap +0 -0
- package/public/pdfjs/cmaps/90msp-RKSJ-H.bcmap +0 -0
- package/public/pdfjs/cmaps/90msp-RKSJ-V.bcmap +0 -0
- package/public/pdfjs/cmaps/90pv-RKSJ-H.bcmap +0 -0
- package/public/pdfjs/cmaps/90pv-RKSJ-V.bcmap +0 -0
- package/public/pdfjs/cmaps/Add-H.bcmap +0 -0
- package/public/pdfjs/cmaps/Add-RKSJ-H.bcmap +0 -0
- package/public/pdfjs/cmaps/Add-RKSJ-V.bcmap +0 -0
- package/public/pdfjs/cmaps/Add-V.bcmap +0 -0
- package/public/pdfjs/cmaps/Adobe-CNS1-0.bcmap +0 -0
- package/public/pdfjs/cmaps/Adobe-CNS1-1.bcmap +0 -0
- package/public/pdfjs/cmaps/Adobe-CNS1-2.bcmap +0 -0
- package/public/pdfjs/cmaps/Adobe-CNS1-3.bcmap +0 -0
- package/public/pdfjs/cmaps/Adobe-CNS1-4.bcmap +0 -0
- package/public/pdfjs/cmaps/Adobe-CNS1-5.bcmap +0 -0
- package/public/pdfjs/cmaps/Adobe-CNS1-6.bcmap +0 -0
- package/public/pdfjs/cmaps/Adobe-CNS1-UCS2.bcmap +0 -0
- package/public/pdfjs/cmaps/Adobe-GB1-0.bcmap +0 -0
- package/public/pdfjs/cmaps/Adobe-GB1-1.bcmap +0 -0
- package/public/pdfjs/cmaps/Adobe-GB1-2.bcmap +0 -0
- package/public/pdfjs/cmaps/Adobe-GB1-3.bcmap +0 -0
- package/public/pdfjs/cmaps/Adobe-GB1-4.bcmap +0 -0
- package/public/pdfjs/cmaps/Adobe-GB1-5.bcmap +0 -0
- package/public/pdfjs/cmaps/Adobe-GB1-UCS2.bcmap +0 -0
- package/public/pdfjs/cmaps/Adobe-Japan1-0.bcmap +0 -0
- package/public/pdfjs/cmaps/Adobe-Japan1-1.bcmap +0 -0
- package/public/pdfjs/cmaps/Adobe-Japan1-2.bcmap +0 -0
- package/public/pdfjs/cmaps/Adobe-Japan1-3.bcmap +0 -0
- package/public/pdfjs/cmaps/Adobe-Japan1-4.bcmap +0 -0
- package/public/pdfjs/cmaps/Adobe-Japan1-5.bcmap +0 -0
- package/public/pdfjs/cmaps/Adobe-Japan1-6.bcmap +0 -0
- package/public/pdfjs/cmaps/Adobe-Japan1-UCS2.bcmap +0 -0
- package/public/pdfjs/cmaps/Adobe-Korea1-0.bcmap +0 -0
- package/public/pdfjs/cmaps/Adobe-Korea1-1.bcmap +0 -0
- package/public/pdfjs/cmaps/Adobe-Korea1-2.bcmap +0 -0
- package/public/pdfjs/cmaps/Adobe-Korea1-UCS2.bcmap +0 -0
- package/public/pdfjs/cmaps/B5-H.bcmap +0 -0
- package/public/pdfjs/cmaps/B5-V.bcmap +0 -0
- package/public/pdfjs/cmaps/B5pc-H.bcmap +0 -0
- package/public/pdfjs/cmaps/B5pc-V.bcmap +0 -0
- package/public/pdfjs/cmaps/CNS-EUC-H.bcmap +0 -0
- package/public/pdfjs/cmaps/CNS-EUC-V.bcmap +0 -0
- package/public/pdfjs/cmaps/CNS1-H.bcmap +0 -0
- package/public/pdfjs/cmaps/CNS1-V.bcmap +0 -0
- package/public/pdfjs/cmaps/CNS2-H.bcmap +0 -0
- package/public/pdfjs/cmaps/CNS2-V.bcmap +3 -0
- package/public/pdfjs/cmaps/ETHK-B5-H.bcmap +0 -0
- package/public/pdfjs/cmaps/ETHK-B5-V.bcmap +0 -0
- package/public/pdfjs/cmaps/ETen-B5-H.bcmap +0 -0
- package/public/pdfjs/cmaps/ETen-B5-V.bcmap +0 -0
- package/public/pdfjs/cmaps/ETenms-B5-H.bcmap +3 -0
- package/public/pdfjs/cmaps/ETenms-B5-V.bcmap +0 -0
- package/public/pdfjs/cmaps/EUC-H.bcmap +0 -0
- package/public/pdfjs/cmaps/EUC-V.bcmap +0 -0
- package/public/pdfjs/cmaps/Ext-H.bcmap +0 -0
- package/public/pdfjs/cmaps/Ext-RKSJ-H.bcmap +0 -0
- package/public/pdfjs/cmaps/Ext-RKSJ-V.bcmap +0 -0
- package/public/pdfjs/cmaps/Ext-V.bcmap +0 -0
- package/public/pdfjs/cmaps/GB-EUC-H.bcmap +0 -0
- package/public/pdfjs/cmaps/GB-EUC-V.bcmap +0 -0
- package/public/pdfjs/cmaps/GB-H.bcmap +4 -0
- package/public/pdfjs/cmaps/GB-V.bcmap +0 -0
- package/public/pdfjs/cmaps/GBK-EUC-H.bcmap +0 -0
- package/public/pdfjs/cmaps/GBK-EUC-V.bcmap +0 -0
- package/public/pdfjs/cmaps/GBK2K-H.bcmap +0 -0
- package/public/pdfjs/cmaps/GBK2K-V.bcmap +0 -0
- package/public/pdfjs/cmaps/GBKp-EUC-H.bcmap +0 -0
- package/public/pdfjs/cmaps/GBKp-EUC-V.bcmap +0 -0
- package/public/pdfjs/cmaps/GBT-EUC-H.bcmap +0 -0
- package/public/pdfjs/cmaps/GBT-EUC-V.bcmap +0 -0
- package/public/pdfjs/cmaps/GBT-H.bcmap +0 -0
- package/public/pdfjs/cmaps/GBT-V.bcmap +0 -0
- package/public/pdfjs/cmaps/GBTpc-EUC-H.bcmap +0 -0
- package/public/pdfjs/cmaps/GBTpc-EUC-V.bcmap +0 -0
- package/public/pdfjs/cmaps/GBpc-EUC-H.bcmap +0 -0
- package/public/pdfjs/cmaps/GBpc-EUC-V.bcmap +0 -0
- package/public/pdfjs/cmaps/H.bcmap +0 -0
- package/public/pdfjs/cmaps/HKdla-B5-H.bcmap +0 -0
- package/public/pdfjs/cmaps/HKdla-B5-V.bcmap +0 -0
- package/public/pdfjs/cmaps/HKdlb-B5-H.bcmap +0 -0
- package/public/pdfjs/cmaps/HKdlb-B5-V.bcmap +0 -0
- package/public/pdfjs/cmaps/HKgccs-B5-H.bcmap +0 -0
- package/public/pdfjs/cmaps/HKgccs-B5-V.bcmap +0 -0
- package/public/pdfjs/cmaps/HKm314-B5-H.bcmap +0 -0
- package/public/pdfjs/cmaps/HKm314-B5-V.bcmap +0 -0
- package/public/pdfjs/cmaps/HKm471-B5-H.bcmap +0 -0
- package/public/pdfjs/cmaps/HKm471-B5-V.bcmap +0 -0
- package/public/pdfjs/cmaps/HKscs-B5-H.bcmap +0 -0
- package/public/pdfjs/cmaps/HKscs-B5-V.bcmap +0 -0
- package/public/pdfjs/cmaps/Hankaku.bcmap +0 -0
- package/public/pdfjs/cmaps/Hiragana.bcmap +0 -0
- package/public/pdfjs/cmaps/KSC-EUC-H.bcmap +0 -0
- package/public/pdfjs/cmaps/KSC-EUC-V.bcmap +0 -0
- package/public/pdfjs/cmaps/KSC-H.bcmap +0 -0
- package/public/pdfjs/cmaps/KSC-Johab-H.bcmap +0 -0
- package/public/pdfjs/cmaps/KSC-Johab-V.bcmap +0 -0
- package/public/pdfjs/cmaps/KSC-V.bcmap +0 -0
- package/public/pdfjs/cmaps/KSCms-UHC-H.bcmap +0 -0
- package/public/pdfjs/cmaps/KSCms-UHC-HW-H.bcmap +0 -0
- package/public/pdfjs/cmaps/KSCms-UHC-HW-V.bcmap +0 -0
- package/public/pdfjs/cmaps/KSCms-UHC-V.bcmap +0 -0
- package/public/pdfjs/cmaps/KSCpc-EUC-H.bcmap +0 -0
- package/public/pdfjs/cmaps/KSCpc-EUC-V.bcmap +0 -0
- package/public/pdfjs/cmaps/Katakana.bcmap +0 -0
- package/public/pdfjs/cmaps/LICENSE +36 -0
- package/public/pdfjs/cmaps/NWP-H.bcmap +0 -0
- package/public/pdfjs/cmaps/NWP-V.bcmap +0 -0
- package/public/pdfjs/cmaps/RKSJ-H.bcmap +0 -0
- package/public/pdfjs/cmaps/RKSJ-V.bcmap +0 -0
- package/public/pdfjs/cmaps/Roman.bcmap +0 -0
- package/public/pdfjs/cmaps/UniCNS-UCS2-H.bcmap +0 -0
- package/public/pdfjs/cmaps/UniCNS-UCS2-V.bcmap +0 -0
- package/public/pdfjs/cmaps/UniCNS-UTF16-H.bcmap +0 -0
- package/public/pdfjs/cmaps/UniCNS-UTF16-V.bcmap +0 -0
- package/public/pdfjs/cmaps/UniCNS-UTF32-H.bcmap +0 -0
- package/public/pdfjs/cmaps/UniCNS-UTF32-V.bcmap +0 -0
- package/public/pdfjs/cmaps/UniCNS-UTF8-H.bcmap +0 -0
- package/public/pdfjs/cmaps/UniCNS-UTF8-V.bcmap +0 -0
- package/public/pdfjs/cmaps/UniGB-UCS2-H.bcmap +0 -0
- package/public/pdfjs/cmaps/UniGB-UCS2-V.bcmap +0 -0
- package/public/pdfjs/cmaps/UniGB-UTF16-H.bcmap +0 -0
- package/public/pdfjs/cmaps/UniGB-UTF16-V.bcmap +0 -0
- package/public/pdfjs/cmaps/UniGB-UTF32-H.bcmap +0 -0
- package/public/pdfjs/cmaps/UniGB-UTF32-V.bcmap +0 -0
- package/public/pdfjs/cmaps/UniGB-UTF8-H.bcmap +0 -0
- package/public/pdfjs/cmaps/UniGB-UTF8-V.bcmap +0 -0
- package/public/pdfjs/cmaps/UniJIS-UCS2-H.bcmap +0 -0
- package/public/pdfjs/cmaps/UniJIS-UCS2-HW-H.bcmap +0 -0
- package/public/pdfjs/cmaps/UniJIS-UCS2-HW-V.bcmap +0 -0
- package/public/pdfjs/cmaps/UniJIS-UCS2-V.bcmap +0 -0
- package/public/pdfjs/cmaps/UniJIS-UTF16-H.bcmap +0 -0
- package/public/pdfjs/cmaps/UniJIS-UTF16-V.bcmap +0 -0
- package/public/pdfjs/cmaps/UniJIS-UTF32-H.bcmap +0 -0
- package/public/pdfjs/cmaps/UniJIS-UTF32-V.bcmap +0 -0
- package/public/pdfjs/cmaps/UniJIS-UTF8-H.bcmap +0 -0
- package/public/pdfjs/cmaps/UniJIS-UTF8-V.bcmap +0 -0
- package/public/pdfjs/cmaps/UniJIS2004-UTF16-H.bcmap +0 -0
- package/public/pdfjs/cmaps/UniJIS2004-UTF16-V.bcmap +0 -0
- package/public/pdfjs/cmaps/UniJIS2004-UTF32-H.bcmap +0 -0
- package/public/pdfjs/cmaps/UniJIS2004-UTF32-V.bcmap +0 -0
- package/public/pdfjs/cmaps/UniJIS2004-UTF8-H.bcmap +0 -0
- package/public/pdfjs/cmaps/UniJIS2004-UTF8-V.bcmap +0 -0
- package/public/pdfjs/cmaps/UniJISPro-UCS2-HW-V.bcmap +0 -0
- package/public/pdfjs/cmaps/UniJISPro-UCS2-V.bcmap +0 -0
- package/public/pdfjs/cmaps/UniJISPro-UTF8-V.bcmap +0 -0
- package/public/pdfjs/cmaps/UniJISX0213-UTF32-H.bcmap +0 -0
- package/public/pdfjs/cmaps/UniJISX0213-UTF32-V.bcmap +0 -0
- package/public/pdfjs/cmaps/UniJISX02132004-UTF32-H.bcmap +0 -0
- package/public/pdfjs/cmaps/UniJISX02132004-UTF32-V.bcmap +0 -0
- package/public/pdfjs/cmaps/UniKS-UCS2-H.bcmap +0 -0
- package/public/pdfjs/cmaps/UniKS-UCS2-V.bcmap +0 -0
- package/public/pdfjs/cmaps/UniKS-UTF16-H.bcmap +0 -0
- package/public/pdfjs/cmaps/UniKS-UTF16-V.bcmap +0 -0
- package/public/pdfjs/cmaps/UniKS-UTF32-H.bcmap +0 -0
- package/public/pdfjs/cmaps/UniKS-UTF32-V.bcmap +0 -0
- package/public/pdfjs/cmaps/UniKS-UTF8-H.bcmap +0 -0
- package/public/pdfjs/cmaps/UniKS-UTF8-V.bcmap +0 -0
- package/public/pdfjs/cmaps/V.bcmap +0 -0
- package/public/pdfjs/cmaps/WP-Symbol.bcmap +0 -0
- package/public/pdfjs/standard_fonts/FoxitDingbats.pfb +0 -0
- package/public/pdfjs/standard_fonts/FoxitFixed.pfb +0 -0
- package/public/pdfjs/standard_fonts/FoxitFixedBold.pfb +0 -0
- package/public/pdfjs/standard_fonts/FoxitFixedBoldItalic.pfb +0 -0
- package/public/pdfjs/standard_fonts/FoxitFixedItalic.pfb +0 -0
- package/public/pdfjs/standard_fonts/FoxitSans.pfb +0 -0
- package/public/pdfjs/standard_fonts/FoxitSansBold.pfb +0 -0
- package/public/pdfjs/standard_fonts/FoxitSansBoldItalic.pfb +0 -0
- package/public/pdfjs/standard_fonts/FoxitSansItalic.pfb +0 -0
- package/public/pdfjs/standard_fonts/FoxitSerif.pfb +0 -0
- package/public/pdfjs/standard_fonts/FoxitSerifBold.pfb +0 -0
- package/public/pdfjs/standard_fonts/FoxitSerifBoldItalic.pfb +0 -0
- package/public/pdfjs/standard_fonts/FoxitSerifItalic.pfb +0 -0
- package/public/pdfjs/standard_fonts/FoxitSymbol.pfb +0 -0
- package/public/pdfjs/standard_fonts/LICENSE_FOXIT +27 -0
- package/public/pdfjs/standard_fonts/LICENSE_LIBERATION +102 -0
- package/public/pdfjs/standard_fonts/LiberationSans-Bold.ttf +0 -0
- package/public/pdfjs/standard_fonts/LiberationSans-BoldItalic.ttf +0 -0
- package/public/pdfjs/standard_fonts/LiberationSans-Italic.ttf +0 -0
- package/public/pdfjs/standard_fonts/LiberationSans-Regular.ttf +0 -0
- package/src/App.vue +31 -31
- package/src/api/index.js +1 -1
- package/src/api/mock.http +2 -2
- package/src/api/requestUrl.js +185 -185
- package/src/assets/image/default_avt_ui.png +0 -0
- package/src/assets/image/filtType/audio.png +0 -0
- package/src/assets/image/filtType/excel1.png +0 -0
- package/src/assets/image/filtType/general.png +0 -0
- package/src/assets/image/filtType/html.png +0 -0
- package/src/assets/image/filtType/image1.png +0 -0
- package/src/assets/image/filtType/link.png +0 -0
- package/src/assets/image/filtType/md2.png +0 -0
- package/src/assets/image/filtType/mode.png +0 -0
- package/src/assets/image/filtType/news.png +0 -0
- package/src/assets/image/filtType/pdf1.png +0 -0
- package/src/assets/image/filtType/ppt1.png +0 -0
- package/src/assets/image/filtType/selfadd1.png +0 -0
- package/src/assets/image/filtType/txt1.png +0 -0
- package/src/assets/image/filtType/video.png +0 -0
- package/src/assets/image/filtType/wechat.png +0 -0
- package/src/assets/image/filtType/word1.png +0 -0
- package/src/assets/image/loading.gif +0 -0
- package/src/assets/js/AliyunlssUtil.js +117 -92
- package/src/assets/js/Base64Util.js +22 -22
- package/src/assets/js/common.js +287 -252
- package/src/assets/js/hammer.js +89 -100
- package/src/assets/js/script.js +36 -36
- package/src/assets/less/common.css +6773 -6773
- package/src/assets/less/converSationContainer/common.less +192 -199
- package/src/assets/less/converSationContainer/converSatonContainer.less +486 -493
- package/src/assets/less/iconfont.css +37 -37
- package/src/assets/less/ticketMessage.less +294 -294
- package/src/assets/less/variables.less +122 -0
- package/src/components/ActionAlertIframe.vue +155 -177
- package/src/components/AiGuide.vue +473 -466
- package/src/components/AnswerDocknowledge.vue +1207 -1059
- package/src/components/AnswerVoice.vue +286 -285
- package/src/components/AskIFrame.vue +15 -15
- package/src/components/ConversationContainer.vue +10880 -4934
- package/src/components/FileType.vue +86 -86
- package/src/components/Message.vue +27 -27
- package/src/components/MyEditor.vue +343 -351
- package/src/components/QwFeedback.vue +304 -0
- package/src/components/actionSatisfaction.vue +109 -107
- package/src/components/actionSendToBot.vue +64 -62
- package/src/components/answerDissatisfaction.vue +64 -62
- package/src/components/answerRadio.vue +261 -186
- package/src/components/ask-components/DissatisfactionOptions.vue +58 -57
- package/src/components/ask-components/Msgloading.vue +38 -37
- package/src/components/ask-components/SatisfactionV2.vue +15 -15
- package/src/components/askVideo.vue +214 -162
- package/src/components/assetDetails.vue +379 -378
- package/src/components/assetMessage.vue +231 -228
- package/src/components/associationIntention.vue +414 -355
- package/src/components/attachmentPreview.vue +92 -90
- package/src/components/botActionSatisfactor.vue +70 -68
- package/src/components/chatContent.vue +514 -513
- package/src/components/feedBack.vue +138 -136
- package/src/components/fielListView.vue +352 -351
- package/src/components/file/AliyunOssComponents.vue +108 -108
- package/src/components/formTemplate.vue +3517 -3572
- package/src/components/imgView.vue +32 -0
- package/src/components/intelligentSummary.vue +232 -227
- package/src/components/interruptComponents/imageSelectionAnswer.vue +203 -0
- package/src/components/interruptComponents/multipleChoiceAnswer.vue +134 -0
- package/src/components/interruptComponents/singleChoiceAnswer.vue +82 -0
- package/src/components/kkview.vue +1130 -1138
- package/src/components/loadingProcess.vue +164 -164
- package/src/components/markDownText.vue +961 -0
- package/src/components/message/ActionAlertIframe.vue +112 -112
- package/src/components/message/ShopMessage.vue +164 -164
- package/src/components/message/TextMessage.vue +926 -924
- package/src/components/message/TicketMessage.vue +201 -201
- package/src/components/message/swiper/index.js +4 -4
- package/src/components/message/swiper/ticketSwiper.vue +503 -503
- package/src/components/message/swiper/ticketSwiperItem.vue +61 -61
- package/src/components/msgLoading.vue +231 -231
- package/src/components/myPopup.vue +75 -70
- package/src/components/outputComponents/outputCom.vue +149 -0
- package/src/components/pagination.vue +130 -0
- package/src/components/pdfPosition.vue +1337 -1506
- package/src/components/popup.vue +230 -227
- package/src/components/preview/docView.vue +263 -0
- package/src/components/preview/excelView.vue +260 -0
- package/src/components/preview/markDownView.vue +70 -0
- package/src/components/preview/newPositionPreview.vue +601 -0
- package/src/components/preview/pdfView.vue +973 -0
- package/src/components/previewDoc.vue +253 -247
- package/src/components/previewPdf.vue +1106 -757
- package/src/components/previewWisdom.vue +252 -0
- package/src/components/receiverMessagePlatform.vue +71 -65
- package/src/components/recommend.vue +82 -80
- package/src/components/selector/hOption.vue +20 -20
- package/src/components/selector/hSelector.vue +199 -199
- package/src/components/selector/hWrapper.vue +216 -216
- package/src/components/senderMessagePlatform.vue +60 -50
- package/src/components/source/BotMessage.vue +24 -24
- package/src/components/source/CustomMessage.vue +24 -24
- package/src/components/test.vue +260 -260
- package/src/components/tree.vue +310 -295
- package/src/components/utils/AliyunIssUtil.js +103 -81
- package/src/components/utils/ckeditor.js +185 -174
- package/src/components/utils/format_date.js +25 -25
- package/src/components/utils/index.js +6 -6
- package/src/components/utils/math_utils.js +29 -29
- package/src/components/voiceComponent.vue +122 -119
- package/src/components/welcomeKnowledgeFile.vue +346 -340
- package/src/components/welcomeLlmCard.vue +142 -140
- package/src/components/welcomeSuggest.vue +99 -97
- package/src/locales/cn.json +100 -0
- package/src/locales/en.json +99 -0
- package/src/main.js +76 -57
- package/vue.config.js +54 -54
- package/src/components/newPdfPosition.vue +0 -878
|
@@ -1,81 +1,103 @@
|
|
|
1
|
-
const OSS = require('ali-oss');
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
let
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
}
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
}
|
|
72
|
-
|
|
73
|
-
function
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
1
|
+
// const OSS = require('ali-oss');
|
|
2
|
+
const OSS = window.OSS
|
|
3
|
+
|
|
4
|
+
const getPrivateOssConfig = () => {
|
|
5
|
+
let mainSource = sessionStorage.getItem('_mainSource') ? sessionStorage.getItem('_mainSource') : "askbot";
|
|
6
|
+
switch (mainSource) {
|
|
7
|
+
case "askbot":
|
|
8
|
+
return {
|
|
9
|
+
region: "oss-cn-zhangjiakou",
|
|
10
|
+
accessKeyId: "LTAI4G3QtdEdwkEbihBngAsK",
|
|
11
|
+
accessKeySecret: "OwgdVfc5PeCkIgqIdug660xmiSPchn",
|
|
12
|
+
bucket: "guoranopen-zjk",
|
|
13
|
+
}
|
|
14
|
+
case "lishi":
|
|
15
|
+
return {
|
|
16
|
+
region: "oss-ap-southeast-1",
|
|
17
|
+
accessKeyId: "LTAI5tAusPLDNJJwkvUbqi2T",
|
|
18
|
+
accessKeySecret: "xqPVaunOIbvTe3g9qsXal2IZO6RftK",
|
|
19
|
+
bucket: "askbotopen-ls",
|
|
20
|
+
};
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
let IDX = 256, HEX = [], SIZE = 256, BUFFER;
|
|
25
|
+
while (IDX--) HEX[IDX] = (IDX + 256).toString(16).substring(1);
|
|
26
|
+
let mainId = sessionStorage.getItem('_mainId') ? sessionStorage.getItem('_mainId') : "";
|
|
27
|
+
function uid(len) {
|
|
28
|
+
let i = 0, tmp = (len || 11);
|
|
29
|
+
if (!BUFFER || ((IDX + tmp) > SIZE * 2)) {
|
|
30
|
+
for (BUFFER = '', IDX = 0; i < SIZE; i++) {
|
|
31
|
+
BUFFER += HEX[Math.random() * 256 | 0];
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
return BUFFER.substring(IDX, IDX++ + tmp);
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
function dataFormat(fmt, date = new Date()) {
|
|
39
|
+
const o = {
|
|
40
|
+
"M+": date.getMonth() + 1, //月份
|
|
41
|
+
"d+": date.getDate(), //日
|
|
42
|
+
"h+": date.getHours(), //小时
|
|
43
|
+
"m+": date.getMinutes(), //分
|
|
44
|
+
"s+": date.getSeconds(), //秒
|
|
45
|
+
"q+": Math.floor((date.getMonth() + 3) / 3), //季度
|
|
46
|
+
"S": date.getMilliseconds() //毫秒
|
|
47
|
+
};
|
|
48
|
+
if (/(y+)/.test(fmt)) fmt = fmt.replace(RegExp.$1, (date.getFullYear() + "").substr(4 - RegExp.$1.length));
|
|
49
|
+
for (const k in o)
|
|
50
|
+
if (new RegExp("(" + k + ")").test(fmt)) fmt = fmt.replace(RegExp.$1, (RegExp.$1.length === 1) ? (o[k]) : (("00" + o[k]).substr(("" + o[k]).length)));
|
|
51
|
+
return fmt;
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
function pathGenerate(filename) {
|
|
55
|
+
return "front-oss/" + mainId + '/' + dataFormat("yyyy/MM/dd/hh/mm/") + uid(32) + "/" + filename;
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
|
|
59
|
+
function upload(data) {
|
|
60
|
+
let ossClient = new OSS(getPrivateOssConfig());
|
|
61
|
+
// object-key可以自定义为文件名(例如file.txt)或目录(例如abc/test/file.txt)的形式,实现将文件上传至当前Bucket或Bucket下的指定目录。
|
|
62
|
+
let objectKey = pathGenerate(data.name);
|
|
63
|
+
let result = ossClient.put(objectKey, data, {
|
|
64
|
+
headers: {
|
|
65
|
+
// 通过文件URL访问文件时,指定以附件形式下载文件,下载后的文件名称定义为example.jpg。
|
|
66
|
+
'Content-Disposition': `attachment; filename="${encodeURIComponent(data.name)}"`
|
|
67
|
+
},
|
|
68
|
+
});
|
|
69
|
+
console.debug(result);
|
|
70
|
+
return result;
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
function multipartUpload(data, callback, extCallback) {
|
|
74
|
+
let ossClient = new OSS(getPrivateOssConfig());
|
|
75
|
+
// object-key可以自定义为文件名(例如file.txt)或目录(例如abc/test/file.txt)的形式,实现将文件上传至当前Bucket或Bucket下的指定目录。
|
|
76
|
+
let objectKey = pathGenerate(data.name);
|
|
77
|
+
|
|
78
|
+
let res = ossClient.multipartUpload(objectKey, data, {
|
|
79
|
+
headers: {
|
|
80
|
+
// 通过文件URL访问文件时,指定以附件形式下载文件,下载后的文件名称定义为example.jpg。
|
|
81
|
+
'Content-Disposition': `attachment; filename="${encodeURIComponent(data.name)}"`
|
|
82
|
+
},
|
|
83
|
+
progress: function (p, checkpoint) {
|
|
84
|
+
console.debug('progress callback', p, checkpoint);
|
|
85
|
+
// 断点记录点。浏览器重启后无法直接继续上传,您需要手动触发上传操作。
|
|
86
|
+
if (callback && callback instanceof Function) {
|
|
87
|
+
callback(p, checkpoint, data, extCallback);
|
|
88
|
+
}
|
|
89
|
+
}
|
|
90
|
+
})
|
|
91
|
+
return res;
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
function ossFileUrl(path, cname) {
|
|
95
|
+
let ossConfig = getPrivateOssConfig();
|
|
96
|
+
if (cname == null) {
|
|
97
|
+
return 'https://' + ossConfig.bucket + '.' + ossConfig.region + '.aliyuncs.com/' + path;
|
|
98
|
+
} else {
|
|
99
|
+
return cname + '/' + path;
|
|
100
|
+
}
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
export { upload, multipartUpload, ossFileUrl }
|
|
@@ -1,174 +1,185 @@
|
|
|
1
|
-
/* eslint-disable */
|
|
2
|
-
import {multipartUpload, ossFileUrl} from "./AliyunIssUtil";
|
|
3
|
-
import { v4 as uuidv4 } from "uuid";
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
const
|
|
116
|
-
|
|
117
|
-
xhr.
|
|
118
|
-
xhr.
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
//
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
1
|
+
/* eslint-disable */
|
|
2
|
+
import { multipartUpload, ossFileUrl } from "./AliyunIssUtil";
|
|
3
|
+
import { v4 as uuidv4 } from "uuid";
|
|
4
|
+
|
|
5
|
+
const getPrivateOssConfig = () => {
|
|
6
|
+
let mainSource = sessionStorage.getItem('_mainSource') ? sessionStorage.getItem('_mainSource') : "askbot";
|
|
7
|
+
switch (mainSource) {
|
|
8
|
+
case "askbot":
|
|
9
|
+
return {
|
|
10
|
+
region: "oss-cn-zhangjiakou",
|
|
11
|
+
accessKeyId: "LTAI4G3QtdEdwkEbihBngAsK",
|
|
12
|
+
accessKeySecret: "OwgdVfc5PeCkIgqIdug660xmiSPchn",
|
|
13
|
+
bucket: "guoranopen-zjk",
|
|
14
|
+
}
|
|
15
|
+
case "lishi":
|
|
16
|
+
return {
|
|
17
|
+
region: "oss-ap-southeast-1",
|
|
18
|
+
accessKeyId: "LTAI5tAusPLDNJJwkvUbqi2T",
|
|
19
|
+
accessKeySecret: "xqPVaunOIbvTe3g9qsXal2IZO6RftK",
|
|
20
|
+
bucket: "askbotopen-ls",
|
|
21
|
+
};
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
class MyUploadAdapter {
|
|
25
|
+
constructor(loader, editor) {
|
|
26
|
+
// 要在上载期间使用的文件加载器实例
|
|
27
|
+
this.loader = loader;
|
|
28
|
+
this.editor = editor
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
// 启动上载过程
|
|
32
|
+
upload() {
|
|
33
|
+
return this.loader.file
|
|
34
|
+
.then(file => new Promise(() => {
|
|
35
|
+
/* this._initRequest();
|
|
36
|
+
this._initListeners( resolve, reject, file );
|
|
37
|
+
this._sendRequest( file );*/
|
|
38
|
+
let command = this.editor.commands.get("insertAskComponent");
|
|
39
|
+
let uid = uuidv4()
|
|
40
|
+
command.execute({
|
|
41
|
+
tag: "section",
|
|
42
|
+
options: {
|
|
43
|
+
className: 'self-p-section',
|
|
44
|
+
data: 'self-p-section'
|
|
45
|
+
},
|
|
46
|
+
});
|
|
47
|
+
command.execute({
|
|
48
|
+
tag: "span-editable",
|
|
49
|
+
options: {
|
|
50
|
+
name: file.name + '正在上传...',
|
|
51
|
+
data: uid,
|
|
52
|
+
editable: false,
|
|
53
|
+
type: 'upload'
|
|
54
|
+
}
|
|
55
|
+
})
|
|
56
|
+
this.uploadFile(file)
|
|
57
|
+
}));
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
// 中止上载过程
|
|
61
|
+
abort() {
|
|
62
|
+
if (this.xhr) {
|
|
63
|
+
this.xhr.abort();
|
|
64
|
+
}
|
|
65
|
+
}
|
|
66
|
+
uploadFile(file) {
|
|
67
|
+
let imgInfo = {
|
|
68
|
+
url: '',
|
|
69
|
+
}
|
|
70
|
+
let res = multipartUpload(
|
|
71
|
+
file,
|
|
72
|
+
null,
|
|
73
|
+
imgInfo
|
|
74
|
+
);
|
|
75
|
+
res.then(resp => {
|
|
76
|
+
imgInfo.url = ossFileUrl(resp.name)
|
|
77
|
+
let root = this.editor.model.document.getRoot()
|
|
78
|
+
let children = root.getChildren()
|
|
79
|
+
for (let child of children) {
|
|
80
|
+
for (let index = 0; index < child._children._nodes.length; index++) {
|
|
81
|
+
if (child._children._nodes[index].name == 'askComponentPlaceholderContainer') {
|
|
82
|
+
if (child._children._nodes[index]._children._nodes[0]) {
|
|
83
|
+
let attrs = child._children._nodes[index]._children._nodes[0]._attrs
|
|
84
|
+
if (attrs) {
|
|
85
|
+
let attrsList = [...attrs.keys()]
|
|
86
|
+
for (let j = 0; j < attrsList.length; j++) {
|
|
87
|
+
if (attrsList[j] == 'data') {
|
|
88
|
+
// this.editor.uploadImg = this.editor.uploadImg.filter(id =>{return id != attrs.get(attrsList[j])})
|
|
89
|
+
this.editor.model.change(writer => {
|
|
90
|
+
writer.remove(child._children._nodes[index]);
|
|
91
|
+
});
|
|
92
|
+
}
|
|
93
|
+
}
|
|
94
|
+
}
|
|
95
|
+
}
|
|
96
|
+
}
|
|
97
|
+
}
|
|
98
|
+
}
|
|
99
|
+
let command = this.editor.commands.get("insertAskComponent");
|
|
100
|
+
command.execute({
|
|
101
|
+
tag: "img",
|
|
102
|
+
options: {
|
|
103
|
+
width: '100%',
|
|
104
|
+
alt: resp.name + 0,
|
|
105
|
+
src: imgInfo.url
|
|
106
|
+
},
|
|
107
|
+
});
|
|
108
|
+
this.editor.execute('insertParagraph', {
|
|
109
|
+
position: this.editor.model.document.selection.focus
|
|
110
|
+
})
|
|
111
|
+
})
|
|
112
|
+
}
|
|
113
|
+
// 使用传递给构造函数的URL初始化XMLHttpRequest对象.
|
|
114
|
+
_initRequest() {
|
|
115
|
+
const xhr = this.xhr = new XMLHttpRequest();
|
|
116
|
+
console.log(xhr)
|
|
117
|
+
xhr.open('POST', '/open-api/oss/public?token=8c98087dfd2d48f856d8c95c09115def', true);
|
|
118
|
+
xhr.responseType = '';
|
|
119
|
+
}
|
|
120
|
+
|
|
121
|
+
// 初始化 XMLHttpRequest 监听.
|
|
122
|
+
_initListeners(resolve, reject, file) {
|
|
123
|
+
const xhr = this.xhr;
|
|
124
|
+
const loader = this.loader;
|
|
125
|
+
console.log(this.loader)
|
|
126
|
+
const genericErrorText = `无法上传文件: ${file.name}.`;
|
|
127
|
+
|
|
128
|
+
xhr.addEventListener('error', () => reject(genericErrorText));
|
|
129
|
+
xhr.addEventListener('abort', () => reject());
|
|
130
|
+
xhr.addEventListener('load', () => {
|
|
131
|
+
const response = xhr.response;
|
|
132
|
+
// 当code==200说明上传成功,可以增加弹框提示;
|
|
133
|
+
// 当上传失败时,必须调用reject()函数。
|
|
134
|
+
|
|
135
|
+
console.log('response', xhr)
|
|
136
|
+
|
|
137
|
+
if (!response || response.error) {
|
|
138
|
+
return reject(response && response.error ? response.error.message : genericErrorText);
|
|
139
|
+
}
|
|
140
|
+
//上传成功,从后台获取图片的url地址
|
|
141
|
+
resolve({
|
|
142
|
+
default: response
|
|
143
|
+
});
|
|
144
|
+
});
|
|
145
|
+
|
|
146
|
+
// 支持时上传进度。文件加载器有#uploadTotal和#upload属性,用于在编辑器用户界面中显示上载进度栏。
|
|
147
|
+
if (xhr.upload) {
|
|
148
|
+
xhr.upload.addEventListener('progress', evt => {
|
|
149
|
+
if (evt.lengthComputable) {
|
|
150
|
+
loader.uploadTotal = evt.total;
|
|
151
|
+
loader.uploaded = evt.loaded;
|
|
152
|
+
}
|
|
153
|
+
});
|
|
154
|
+
}
|
|
155
|
+
}
|
|
156
|
+
|
|
157
|
+
// 准备数据并发送请求
|
|
158
|
+
_sendRequest(file) {
|
|
159
|
+
//通过FormData构造函数创建一个空对象
|
|
160
|
+
const data = new FormData();
|
|
161
|
+
//通过append()方法在末尾追加key为files值为file的数据
|
|
162
|
+
|
|
163
|
+
console.log('file', file)
|
|
164
|
+
data.append('file', file);//上传的参数data
|
|
165
|
+
// data.append( 'memberId', "666" );
|
|
166
|
+
/**
|
|
167
|
+
* 重要提示:这是实现诸如身份验证和CSRF保护等安全机制的正确位置。
|
|
168
|
+
* 例如,可以使用XMLHttpRequest.setRequestHeader()设置包含应用程序先前生成的CSRF令牌的请求头。
|
|
169
|
+
*/
|
|
170
|
+
this.xhr.send(data);
|
|
171
|
+
}
|
|
172
|
+
}
|
|
173
|
+
|
|
174
|
+
function MyCustomUploadAdapterPlugin(editor) {
|
|
175
|
+
editor.plugins.get('FileRepository').createUploadAdapter = (loader) => {
|
|
176
|
+
// 在这里将URL配置为后端上载脚本
|
|
177
|
+
console.log(loader, 'loader');
|
|
178
|
+
return new MyUploadAdapter(loader, editor);
|
|
179
|
+
}
|
|
180
|
+
}
|
|
181
|
+
|
|
182
|
+
export {
|
|
183
|
+
MyUploadAdapter,
|
|
184
|
+
MyCustomUploadAdapterPlugin
|
|
185
|
+
}
|
|
@@ -1,26 +1,26 @@
|
|
|
1
|
-
const formatDate = (fmt) => { //author: meizz
|
|
2
|
-
var o = {
|
|
3
|
-
"M+": this.getMonth() + 1, //月份
|
|
4
|
-
"d+": this.getDate(), //日
|
|
5
|
-
"h+": this.getHours(), //小时
|
|
6
|
-
"m+": this.getMinutes(), //分
|
|
7
|
-
"s+": this.getSeconds(), //秒
|
|
8
|
-
"q+": Math.floor((this.getMonth() + 3) / 3), //季度
|
|
9
|
-
"S": this.getMilliseconds() //毫秒
|
|
10
|
-
};
|
|
11
|
-
if (/(y+)/.test(fmt)) fmt = fmt.replace(RegExp.$1, (this.getFullYear() + "").substr(4 - RegExp.$1.length));
|
|
12
|
-
for (var k in o)
|
|
13
|
-
if (new RegExp("(" + k + ")").test(fmt)) fmt = fmt.replace(RegExp.$1, (RegExp.$1.length == 1) ? (o[k]) : (("00" + o[k]).substr(("" + o[k]).length)));
|
|
14
|
-
return fmt;
|
|
15
|
-
}
|
|
16
|
-
function forMatTime(value){
|
|
17
|
-
let startTime = ''
|
|
18
|
-
let currentTime = new Date(), year = currentTime.getFullYear(),
|
|
19
|
-
month = currentTime.getMonth() + 1 < 10 ? '0' + (currentTime.getMonth() + 1) : currentTime.getMonth() + 1,
|
|
20
|
-
day = currentTime.getDate() < 10 ? '0' + currentTime.getDate() : currentTime.getDate();
|
|
21
|
-
startTime = year + "-" + month + "-" + day +' ' + value;
|
|
22
|
-
return new Date(startTime)
|
|
23
|
-
}
|
|
24
|
-
export { formatDate,forMatTime };
|
|
25
|
-
|
|
1
|
+
const formatDate = (fmt) => { //author: meizz
|
|
2
|
+
var o = {
|
|
3
|
+
"M+": this.getMonth() + 1, //月份
|
|
4
|
+
"d+": this.getDate(), //日
|
|
5
|
+
"h+": this.getHours(), //小时
|
|
6
|
+
"m+": this.getMinutes(), //分
|
|
7
|
+
"s+": this.getSeconds(), //秒
|
|
8
|
+
"q+": Math.floor((this.getMonth() + 3) / 3), //季度
|
|
9
|
+
"S": this.getMilliseconds() //毫秒
|
|
10
|
+
};
|
|
11
|
+
if (/(y+)/.test(fmt)) fmt = fmt.replace(RegExp.$1, (this.getFullYear() + "").substr(4 - RegExp.$1.length));
|
|
12
|
+
for (var k in o)
|
|
13
|
+
if (new RegExp("(" + k + ")").test(fmt)) fmt = fmt.replace(RegExp.$1, (RegExp.$1.length == 1) ? (o[k]) : (("00" + o[k]).substr(("" + o[k]).length)));
|
|
14
|
+
return fmt;
|
|
15
|
+
}
|
|
16
|
+
function forMatTime(value){
|
|
17
|
+
let startTime = ''
|
|
18
|
+
let currentTime = new Date(), year = currentTime.getFullYear(),
|
|
19
|
+
month = currentTime.getMonth() + 1 < 10 ? '0' + (currentTime.getMonth() + 1) : currentTime.getMonth() + 1,
|
|
20
|
+
day = currentTime.getDate() < 10 ? '0' + currentTime.getDate() : currentTime.getDate();
|
|
21
|
+
startTime = year + "-" + month + "-" + day +' ' + value;
|
|
22
|
+
return new Date(startTime)
|
|
23
|
+
}
|
|
24
|
+
export { formatDate,forMatTime };
|
|
25
|
+
|
|
26
26
|
// new Date("2019-12-14T00:09:16.000+0000").Format("yyyy-MM-dd hh:mm:ss")
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import {formatDate} from './format_date';
|
|
2
|
-
|
|
3
|
-
let utils = {
|
|
4
|
-
formatDate
|
|
5
|
-
}
|
|
6
|
-
|
|
1
|
+
import {formatDate} from './format_date';
|
|
2
|
+
|
|
3
|
+
let utils = {
|
|
4
|
+
formatDate
|
|
5
|
+
}
|
|
6
|
+
|
|
7
7
|
export { utils }
|