|
@@ -5,7 +5,7 @@
|
|
|
<span class="left-icon flex flex-items-center">
|
|
|
<span class="file-attachment-text text-nowrap">附件下载</span>
|
|
|
</span>
|
|
|
- <div class="right-content flex flex-items-center">
|
|
|
+ <div class="right-content flex flex-items-center" v-if="canShowTip">
|
|
|
<!-- 免费用户,无体验次数(没体验过) -->
|
|
|
<template v-if="isFree && freeFileNum === 0">
|
|
|
<span class="attachment-tag text-nowrap">
|
|
@@ -58,6 +58,7 @@
|
|
|
<script>
|
|
|
import { mapState, mapGetters } from 'vuex'
|
|
|
import { useGetContentAttachment } from '@/composables/attachment-download/'
|
|
|
+import { IsCustomTopNet } from '@/views/article-content/composables/useContentStore'
|
|
|
|
|
|
export default {
|
|
|
name: 'AttachmentDownload',
|
|
@@ -158,6 +159,13 @@ export default {
|
|
|
type: a.fileType
|
|
|
}
|
|
|
})
|
|
|
+ },
|
|
|
+ canShowTip() {
|
|
|
+ // 定制化用户不展示提示和留资
|
|
|
+ if (IsCustomTopNet.value) {
|
|
|
+ return false
|
|
|
+ }
|
|
|
+ return true
|
|
|
}
|
|
|
},
|
|
|
created() {
|
|
@@ -209,6 +217,10 @@ export default {
|
|
|
)
|
|
|
},
|
|
|
async startDownloadFile(file) {
|
|
|
+ // 定制化用户直接下载
|
|
|
+ if (IsCustomTopNet.value) {
|
|
|
+ return this.downloadFile(file)
|
|
|
+ }
|
|
|
// 大客户直接下载
|
|
|
if (location.pathname.indexOf('entservice') !== -1) {
|
|
|
return this.downloadFile(file)
|
|
@@ -309,7 +321,16 @@ export default {
|
|
|
// downUrl: 原始url
|
|
|
// fileUrl: 下载地址
|
|
|
const { downUrl, fileUrl } = await this.getAttachmentInfo(file)
|
|
|
- this.refreshResourcePackCount()
|
|
|
+
|
|
|
+ let skipRefresh = false
|
|
|
+ // 定制化用户不展示提示和留资
|
|
|
+ if (IsCustomTopNet.value) {
|
|
|
+ skipRefresh = true
|
|
|
+ }
|
|
|
+
|
|
|
+ if (!skipRefresh) {
|
|
|
+ this.refreshResourcePackCount()
|
|
|
+ }
|
|
|
|
|
|
if (downUrl && fileUrl) {
|
|
|
location.href = fileUrl
|