319图层服务详情页

This commit is contained in:
gaoyuanwei 2022-06-29 10:18:26 +08:00
parent 111aa16692
commit dc57556a6c
3 changed files with 71 additions and 30 deletions

View File

@ -93,7 +93,16 @@
const flag = ref(true) const flag = ref(true)
if (props.dataList.infoList) { if (props.dataList.infoList) {
let obj = props.dataList.infoList.filter( let obj = props.dataList.infoList.filter(
(item) => item.attrType === '技术文档' (item) =>
item.attrType === '服务类型' ||
item.attrType === '覆盖区域' ||
item.attrType === '切片策略' ||
item.attrType === '坐标系' ||
item.attrType === '切片尺寸' ||
item.attrType === '最小级别' ||
item.attrType === '数据范围' ||
item.attrType === '图层类型' ||
item.attrType === '最大级别'
)[0] )[0]
if (!obj) { if (!obj) {
flag.value = false flag.value = false
@ -128,7 +137,18 @@
() => props.dataList, () => props.dataList,
(val) => { (val) => {
if (val) { if (val) {
let obj = val.infoList.filter((item) => item.attrType === '技术文档')[0] let obj = val.infoList.filter(
(item) =>
item.attrType === '服务类型' ||
item.attrType === '覆盖区域' ||
item.attrType === '切片策略' ||
item.attrType === '坐标系' ||
item.attrType === '切片尺寸' ||
item.attrType === '最小级别' ||
item.attrType === '数据范围' ||
item.attrType === '图层类型' ||
item.attrType === '最大级别'
)[0]
if (!obj) { if (!obj) {
flag.value = false flag.value = false
} else { } else {
@ -211,7 +231,7 @@
font-size: 0.2rem; font-size: 0.2rem;
color: #666666; color: #666666;
display: block; display: block;
margin-right: 0.8rem; margin-right: 0.5rem;
width: 120px; width: 120px;
} }
p { p {

View File

@ -89,14 +89,13 @@
list.value.push(item.attrType) list.value.push(item.attrType)
} else if (item.attrType === '图层缩略图') { } else if (item.attrType === '图层缩略图') {
list.value.push('图层展示') list.value.push('图层展示')
} else if (item.attrType === '坐标系') {
list.value.push('图层信息')
} else if (item.attrType === '是否可预览') { } else if (item.attrType === '是否可预览') {
if (item.attrValue === '是') { if (item.attrValue === '是') {
list.value.push('图层预览') list.value.push('图层预览')
} }
} }
}) })
list.value.push('图层信息')
list.value.push('使用方式') list.value.push('使用方式')
navList.value.forEach((item) => { navList.value.forEach((item) => {
console.log(item) console.log(item)
@ -144,14 +143,13 @@
list.value.push(item.attrType) list.value.push(item.attrType)
} else if (item.attrType === '图层缩略图') { } else if (item.attrType === '图层缩略图') {
list.value.push('图层展示') list.value.push('图层展示')
} else if (item.attrType === '坐标系') {
list.value.push('图层信息')
} else if (item.attrType === '是否可预览') { } else if (item.attrType === '是否可预览') {
if (item.attrValue === '是') { if (item.attrValue === '是') {
list.value.push('图层预览') list.value.push('图层预览')
} }
} }
}) })
list.value.push('图层信息')
list.value.push('使用方式') list.value.push('使用方式')
navList.value.forEach((item) => { navList.value.forEach((item) => {
console.log(item) console.log(item)

View File

@ -17,7 +17,7 @@
</p> </p>
<p> <p>
<span>样式服务地址</span> <span>样式服务地址</span>
<span>{{ item.linkValue }}</span> <span>{{ item.csslnkValue }}</span>
</p> </p>
</div> </div>
</div> </div>
@ -27,7 +27,9 @@
</div> </div>
</div> </div>
<div class="content-right"> <div class="content-right">
<div class="content-right-title">{{ item.contact }}</div> <div class="content-right-title">
{{ item.contact }}{{ item.facilitator.values }}
</div>
<div class="content-right-content"> <div class="content-right-content">
<p> <p>
<span>{{ item.people.name }}</span> <span>{{ item.people.name }}</span>
@ -54,6 +56,7 @@
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({
link: '',
title: '使用方式', title: '使用方式',
englishTitle: 'USAGE', englishTitle: 'USAGE',
content: [ content: [
@ -81,25 +84,32 @@
const flag = ref(true) const flag = ref(true)
if (props.dataList.infoList) { if (props.dataList.infoList) {
let obj = props.dataList.infoList.filter( let obj = props.dataList.infoList.filter(
(item) => item.attrType === '技术文档' (item) =>
item.attrType === '技术文档' ||
item.attrType === '服务商' ||
item.attrType === '服务商联系人' ||
item.attrType === '服务商联系电话'
)[0] )[0]
if (!obj) { if (!obj) {
flag.value = false flag.value = false
} else { } else {
// eslint-disable-next-line vue/no-setup-props-destructure // eslint-disable-next-line vue/no-setup-props-destructure
dataFrom.value.content[0].link.value = props.dataList.apiUrl // dataFrom.value.content[0].link.value = props.dataList.apiUrl
dataFrom.value.content[0].facilitator.values = props.dataList.deptContacts dataFrom.value.content[0].facilitator.values = props.dataList.deptName
dataFrom.value.content[0].people.value = props.dataList.deptContacts
dataFrom.value.content[0].phone.value = props.dataList.deptPhone
console.log('dataList', props.dataList) console.log('dataList', props.dataList)
props.dataList.infoList.map((item) => { props.dataList.infoList.map((item) => {
if (item.attrType === '组件地址') { if (item.attrType === '使用手册') {
dataFrom.value.link = item.attrValue || '--'
} else if (item.attrType === '服务地址') {
dataFrom.value.content[0].linkValue = item.attrValue || '--' dataFrom.value.content[0].linkValue = item.attrValue || '--'
} else if (item.attrType === '服务商') { } else if (item.attrType === '样式服务地址') {
dataFrom.value.content[0].facilitator.value = item.attrValue || '--' dataFrom.value.content[0].csslnkValue = item.attrValue || '--'
} else if (item.attrType === '服务商联系人') {
dataFrom.value.content[0].people.value = item.attrValue || '--'
} else if (item.attrType === '服务商联系电话') {
dataFrom.value.content[0].phone.value = item.attrValue || '--'
} }
// else if (item.attrType === '') {
// dataFrom.value.content[0].phone.value = item.deptPhone || '--'
// }
}) })
} }
} }
@ -107,24 +117,37 @@
() => props.dataList, () => props.dataList,
(val) => { (val) => {
if (val) { if (val) {
let obj = val.infoList.filter((item) => item.attrType === '技术文档')[0] let obj = val.infoList.filter(
(item) =>
item.attrType === '技术文档' ||
item.attrType === '服务商' ||
item.attrType === '服务商联系人' ||
item.attrType === '服务商联系电话'
)[0]
if (!obj) { if (!obj) {
flag.value = false flag.value = false
} else { } else {
dataFrom.value.content[0].link.value = val.apiUrl // dataFrom.value.content[0].link.value = val.apiUrl
dataFrom.value.content[0].facilitator.value = val.deptContacts dataFrom.value.content[0].facilitator.values = val.deptName
dataFrom.value.content[0].people.value = val.deptContacts
dataFrom.value.content[0].phone.value = val.deptPhone
console.log('dataList', val) console.log('dataList', val)
val.infoList.map((item) => { val.infoList.map((item) => {
if (item.attrType === '组件地址') { if (item.attrType === '使用手册') {
dataFrom.value.link = item.attrValue || '--'
} else if (item.attrType === '服务地址') {
dataFrom.value.content[0].linkValue = item.attrValue || '--' dataFrom.value.content[0].linkValue = item.attrValue || '--'
} else if (item.attrType === '服务商') { } else if (item.attrType === '样式服务地址') {
dataFrom.value.content[0].facilitator.value = dataFrom.value.content[0].csslnkValue = item.attrValue || '--'
item.attrValue || '--'
} else if (item.attrType === '服务商联系人') {
dataFrom.value.content[0].people.value = item.attrValue || '--'
} else if (item.attrType === '服务商联系电话') {
dataFrom.value.content[0].phone.value = item.attrValue || '--'
} }
// else if (item.attrType === '') {
// dataFrom.value.content[0].facilitator.value =
// item.attrValue || '--'
// } else if (item.attrType === '') {
// dataFrom.value.content[0].people.value = item.attrValue || '--'
// } else if (item.attrType === '') {
// dataFrom.value.content[0].phone.value = item.attrValue || '--'
// }
}) })
} }
} }