详情页技术文档添加暂无上传提示
This commit is contained in:
parent
4774431110
commit
617373eb8e
|
@ -65,6 +65,7 @@
|
||||||
|
|
||||||
<script setup>
|
<script setup>
|
||||||
import DetalsTitle from '@/views/detailsAll/components/DetalsTitle'
|
import DetalsTitle from '@/views/detailsAll/components/DetalsTitle'
|
||||||
|
import { message } from 'ant-design-vue'
|
||||||
import { pinyin } from 'pinyin-pro'
|
import { pinyin } from 'pinyin-pro'
|
||||||
import { ref, defineProps, watch } from 'vue'
|
import { ref, defineProps, watch } from 'vue'
|
||||||
let dataFrom = ref({
|
let dataFrom = ref({
|
||||||
|
@ -184,12 +185,19 @@
|
||||||
let obj = props.dataList.infoList.filter(
|
let obj = props.dataList.infoList.filter(
|
||||||
(item) => item.attrType === '技术文档'
|
(item) => item.attrType === '技术文档'
|
||||||
)[0]
|
)[0]
|
||||||
console.log('dataFrom.value.link', obj.attrValue)
|
// console.log('dataFrom.value.link', obj.attrValue)
|
||||||
|
if (obj) {
|
||||||
window.open(
|
window.open(
|
||||||
window.SITE_CONFIG.previewUrl +
|
window.SITE_CONFIG.previewUrl +
|
||||||
'hisense_office/onlinePreview?url=' +
|
'hisense_office/onlinePreview?url=' +
|
||||||
btoa(encodeURI(obj.attrValue))
|
btoa(encodeURI(obj.attrValue))
|
||||||
)
|
)
|
||||||
|
} else {
|
||||||
|
message.config({
|
||||||
|
top: '100px', // 距离顶部的位置
|
||||||
|
})
|
||||||
|
message.error('暂无上传技术文档')
|
||||||
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
|
|
@ -2,7 +2,10 @@
|
||||||
<!-- 使用方式 -->
|
<!-- 使用方式 -->
|
||||||
<div class="usage-mode" v-if="flag">
|
<div class="usage-mode" v-if="flag">
|
||||||
<div class="tltle">
|
<div class="tltle">
|
||||||
<DetalsTitle :title="dataFrom.title" :type="dataFrom.englishTitle"></DetalsTitle>
|
<DetalsTitle
|
||||||
|
:title="dataFrom.title"
|
||||||
|
:type="dataFrom.englishTitle"
|
||||||
|
></DetalsTitle>
|
||||||
</div>
|
</div>
|
||||||
<div class="content" v-for="item in dataFrom.content" :key="item.title">
|
<div class="content" v-for="item in dataFrom.content" :key="item.title">
|
||||||
<div class="content-left">
|
<div class="content-left">
|
||||||
|
@ -87,6 +90,7 @@
|
||||||
import DetalsTitle from '@/views/detailsAll/components/DetalsTitle'
|
import DetalsTitle from '@/views/detailsAll/components/DetalsTitle'
|
||||||
import { pinyin } from 'pinyin-pro'
|
import { pinyin } from 'pinyin-pro'
|
||||||
import { ref, defineProps, watch } from 'vue'
|
import { ref, defineProps, watch } from 'vue'
|
||||||
|
import { message } from 'ant-design-vue'
|
||||||
let dataFrom = ref({
|
let dataFrom = ref({
|
||||||
title: '使用方式',
|
title: '使用方式',
|
||||||
englishTitle: 'USAGE',
|
englishTitle: 'USAGE',
|
||||||
|
@ -202,12 +206,18 @@ function technical() {
|
||||||
let obj = props.dataList.infoList.filter(
|
let obj = props.dataList.infoList.filter(
|
||||||
(item) => item.attrType === '技术文档'
|
(item) => item.attrType === '技术文档'
|
||||||
)[0]
|
)[0]
|
||||||
console.log('dataFrom.value.link', obj.attrValue)
|
if (obj) {
|
||||||
window.open(
|
window.open(
|
||||||
window.SITE_CONFIG.previewUrl +
|
window.SITE_CONFIG.previewUrl +
|
||||||
'hisense_office/onlinePreview?url=' +
|
'hisense_office/onlinePreview?url=' +
|
||||||
btoa(encodeURI(obj.attrValue))
|
btoa(encodeURI(obj.attrValue))
|
||||||
)
|
)
|
||||||
|
} else {
|
||||||
|
message.config({
|
||||||
|
top: '100px', // 距离顶部的位置
|
||||||
|
})
|
||||||
|
message.error('暂无上传技术文档')
|
||||||
|
}
|
||||||
}
|
}
|
||||||
function technicalNew() {
|
function technicalNew() {
|
||||||
// 拼接路径
|
// 拼接路径
|
||||||
|
@ -221,11 +231,18 @@ function technicalNew() {
|
||||||
(item) => item.attrType === '使用手册'
|
(item) => item.attrType === '使用手册'
|
||||||
)[0]
|
)[0]
|
||||||
console.log('dataFrom.value.link', obj.attrValue)
|
console.log('dataFrom.value.link', obj.attrValue)
|
||||||
|
if (obj) {
|
||||||
window.open(
|
window.open(
|
||||||
window.SITE_CONFIG.previewUrl +
|
window.SITE_CONFIG.previewUrl +
|
||||||
'hisense_office/onlinePreview?url=' +
|
'hisense_office/onlinePreview?url=' +
|
||||||
btoa(encodeURI(obj.attrValue))
|
btoa(encodeURI(obj.attrValue))
|
||||||
)
|
)
|
||||||
|
} else {
|
||||||
|
message.config({
|
||||||
|
top: '100px', // 距离顶部的位置
|
||||||
|
})
|
||||||
|
message.error('暂无上传使用手册')
|
||||||
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
@ -243,7 +260,8 @@ function technicalNew() {
|
||||||
.content-left {
|
.content-left {
|
||||||
height: 1.5rem;
|
height: 1.5rem;
|
||||||
width: 6.2rem;
|
width: 6.2rem;
|
||||||
background: url('~@/assets/detailsAll/business/business_usage_mode_bg.png') no-repeat;
|
background: url('~@/assets/detailsAll/business/business_usage_mode_bg.png')
|
||||||
|
no-repeat;
|
||||||
background-position: center;
|
background-position: center;
|
||||||
background-size: 100% 100%;
|
background-size: 100% 100%;
|
||||||
border-radius: 0.1rem;
|
border-radius: 0.1rem;
|
||||||
|
@ -309,7 +327,8 @@ function technicalNew() {
|
||||||
.content-right {
|
.content-right {
|
||||||
height: 1.5rem;
|
height: 1.5rem;
|
||||||
width: 6.2rem;
|
width: 6.2rem;
|
||||||
background: url('~@/assets/detailsAll/business/business_usage_mode_bg.png') no-repeat;
|
background: url('~@/assets/detailsAll/business/business_usage_mode_bg.png')
|
||||||
|
no-repeat;
|
||||||
background-position: center;
|
background-position: center;
|
||||||
background-size: 100% 100%;
|
background-size: 100% 100%;
|
||||||
border-radius: 0.1rem;
|
border-radius: 0.1rem;
|
||||||
|
|
|
@ -8,7 +8,12 @@
|
||||||
<template>
|
<template>
|
||||||
<div class="business-navigation" v-if="navList.length > 0">
|
<div class="business-navigation" v-if="navList.length > 0">
|
||||||
<template v-for="nav in navList" :key="nav.key">
|
<template v-for="nav in navList" :key="nav.key">
|
||||||
<div class="nav" :class="{ select: nav.key == select }" v-if="nav.show" @click="selectNav(nav.key)">
|
<div
|
||||||
|
class="nav"
|
||||||
|
:class="{ select: nav.key == select }"
|
||||||
|
v-if="nav.show"
|
||||||
|
@click="selectNav(nav.key)"
|
||||||
|
>
|
||||||
{{ nav.name }}
|
{{ nav.name }}
|
||||||
<span class="line"></span>
|
<span class="line"></span>
|
||||||
</div>
|
</div>
|
||||||
|
@ -215,12 +220,11 @@ watch(
|
||||||
item.show = true
|
item.show = true
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
if (list.value.length > 0) {
|
if (navList.value.filter((item) => item.name === list.value[0])[0]) {
|
||||||
select.value = navList.value.filter(
|
select.value = navList.value.filter(
|
||||||
(item) => item.name === list.value[0]
|
(item) => item.name === list.value[0]
|
||||||
)[0].key
|
)[0].key
|
||||||
}
|
}
|
||||||
console.log('11111111111111111111111111', list.value, navList.value)
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
)
|
)
|
||||||
|
|
|
@ -90,6 +90,7 @@
|
||||||
|
|
||||||
<script setup>
|
<script setup>
|
||||||
import DetalsTitle from '@/views/detailsAll/components/DetalsTitle'
|
import DetalsTitle from '@/views/detailsAll/components/DetalsTitle'
|
||||||
|
import { message } from 'ant-design-vue'
|
||||||
import { pinyin } from 'pinyin-pro'
|
import { pinyin } from 'pinyin-pro'
|
||||||
import { ref, defineProps, watch } from 'vue'
|
import { ref, defineProps, watch } from 'vue'
|
||||||
let dataFrom = ref({
|
let dataFrom = ref({
|
||||||
|
@ -213,12 +214,18 @@
|
||||||
let obj = props.dataList.infoList.filter(
|
let obj = props.dataList.infoList.filter(
|
||||||
(item) => item.attrType === '技术文档'
|
(item) => item.attrType === '技术文档'
|
||||||
)[0]
|
)[0]
|
||||||
console.log('dataFrom.value.link', obj.attrValue)
|
if (obj) {
|
||||||
window.open(
|
window.open(
|
||||||
window.SITE_CONFIG.previewUrl +
|
window.SITE_CONFIG.previewUrl +
|
||||||
'hisense_office/onlinePreview?url=' +
|
'hisense_office/onlinePreview?url=' +
|
||||||
btoa(encodeURI(obj.attrValue))
|
btoa(encodeURI(obj.attrValue))
|
||||||
)
|
)
|
||||||
|
} else {
|
||||||
|
message.config({
|
||||||
|
top: '100px', // 距离顶部的位置
|
||||||
|
})
|
||||||
|
message.error('暂无上传技术文档')
|
||||||
|
}
|
||||||
}
|
}
|
||||||
function technicalNew() {
|
function technicalNew() {
|
||||||
// 拼接路径
|
// 拼接路径
|
||||||
|
@ -231,12 +238,18 @@
|
||||||
let obj = props.dataList.infoList.filter(
|
let obj = props.dataList.infoList.filter(
|
||||||
(item) => item.attrType === '使用手册'
|
(item) => item.attrType === '使用手册'
|
||||||
)[0]
|
)[0]
|
||||||
console.log('dataFrom.value.link', obj.attrValue)
|
if (obj) {
|
||||||
window.open(
|
window.open(
|
||||||
window.SITE_CONFIG.previewUrl +
|
window.SITE_CONFIG.previewUrl +
|
||||||
'hisense_office/onlinePreview?url=' +
|
'hisense_office/onlinePreview?url=' +
|
||||||
btoa(encodeURI(obj.attrValue))
|
btoa(encodeURI(obj.attrValue))
|
||||||
)
|
)
|
||||||
|
} else {
|
||||||
|
message.config({
|
||||||
|
top: '100px', // 距离顶部的位置
|
||||||
|
})
|
||||||
|
message.error('暂上传使用手册')
|
||||||
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue