Compare commits

..

No commits in common. "07d387b5a267b64b98ee520b76b0a34ace5738ef" and "57758bbfa4c377f0829fb1c23403579de7f22b40" have entirely different histories.

3 changed files with 48 additions and 62 deletions

View File

@ -6,7 +6,7 @@
* @Description: 应用详情
-->
<template>
<div class="algorithm-on-trial" v-if="flag && whoShow1.itShowQingDao">
<div class="algorithm-on-trial" v-if="flag">
<detals-title title="应用详情" type="PROBATION"></detals-title>
<div class="main">
<div class="main-left">
@ -35,16 +35,14 @@
import { ref, defineProps, watch } from 'vue'
import { message } from 'ant-design-vue'
let flag = ref(true)
const whoShow1 = ref(whoShow)
console.log('whoShow1', whoShow1.value.itShowQingDao)
const props = defineProps({
dataList: { type: Object, default: null },
})
const dataFrom = ref({
linkName: '访问地址',
link: '',
link: 'http://localhost:8080/#/detailsfdddffffffffffffffdfgdfgdfdgdfgdfg',
numberName: '试用账号',
number: '',
number: 'zhangfeihu',
passwordName: '试用密码',
password: '**************************',
password2: '',
@ -54,17 +52,15 @@
if (obj !== '已申请') {
flag.value = false
} else {
dataFrom.value.link = props.dataList.link
props.dataList.infoList.map((item) => {
if (item.attrType == '试用用户名') {
if (item.attrType == '访问地址') {
dataFrom.value.link = item.attrValue
} else if (item.attrType == '试用用户名') {
dataFrom.value.number = item.attrValue
} else if (item.attrType == '试用密码') {
dataFrom.value.password2 = item.attrValue
}
})
if (dataFrom.value.password2 === '') {
dataFrom.value.password = ''
}
}
}
const clickLink = (link) => {
@ -72,19 +68,15 @@
}
//
const copyFunction = (data, name) => {
if (data !== '') {
let url = data
let oInput = document.createElement('input')
oInput.value = url
document.body.appendChild(oInput)
oInput.select() // ;
console.log(oInput.value)
document.execCommand('Copy') //
oInput.remove() //
message.success(name + '成功')
} else {
message.error('复制为空')
}
let url = data
let oInput = document.createElement('input')
oInput.value = url
document.body.appendChild(oInput)
oInput.select() // ;
console.log(oInput.value)
document.execCommand('Copy') //
oInput.remove() //
message.success(name + '成功')
}
message.config({
top: '100px', //
@ -104,17 +96,15 @@
if (obj !== '已申请') {
flag.value = false
} else {
dataFrom.value.link = props.dataList.link
props.dataList.infoList.map((item) => {
if (item.attrType == '试用用户名') {
if (item.attrType == '访问地址') {
dataFrom.value.link = item.attrValue
} else if (item.attrType == '试用用户名') {
dataFrom.value.number = item.attrValue
} else if (item.attrType == '试用密码') {
dataFrom.value.password2 = item.attrValue
}
})
if (dataFrom.value.password2 === '') {
dataFrom.value.password = ''
}
}
}
}

View File

@ -56,19 +56,11 @@
},
],
})
const whoShow1 = ref(whoShow)
//
const props = defineProps({
dataList: { type: Object, default: null },
})
if (props.dataList.infoList) {
if (!whoShow1.value.itShowQingDao) {
let obj = {
attrType: '访问地址',
attrValue: props.dataList.link || '------',
}
dataFrom.value.content[0].childrenContent.push(obj)
}
props.dataList.infoList.map((item) => {
if (
item.attrType === '部署区域' ||
@ -83,13 +75,14 @@
attrValue: '是',
}
dataFrom.value.content[1].childrenContent.push(isAndNo)
} else if (item.attrType === '访问地址') {
let obj = {
attrType: '访问地址',
attrValue: item.attrValue || '------',
}
dataFrom.value.content[0].childrenContent.push(obj)
}
// } else if (item.attrType === '访') {
// let obj = {
// attrType: '访',
// attrValue: item.attrValue || '------',
// }
// dataFrom.value.content[0].childrenContent.push(obj)
// }
})
if (dataFrom.value.content[1].childrenContent.length <= 0) {
let data = [
@ -107,25 +100,18 @@
})
}
}
//访
const addressFunction = (name, itemValue) => {
if (name == '访问地址') {
window.open(itemValue)
}
}
// //访
// const addressFunction = (name, itemValue) => {
// if (name == '访') {
// window.open(itemValue)
// }
// }
watch(
() => props.dataList,
(val) => {
if (val) {
dataFrom.value.content[0].childrenContent = []
dataFrom.value.content[1].childrenContent = []
if (!whoShow1.value.itShowQingDao) {
let obj = {
attrType: '访问地址',
attrValue: props.dataList.link || '------',
}
dataFrom.value.content[0].childrenContent.push(obj)
}
props.dataList.infoList.map((item) => {
if (
item.attrType === '部署区域' ||
@ -141,6 +127,13 @@
}
dataFrom.value.content[1].childrenContent.push(isAndNo)
}
// } else if (item.attrType === '访') {
// let obj = {
// attrType: '访',
// attrValue: item.attrValue || '------',
// }
// dataFrom.value.content[0].childrenContent.push(obj)
// }
})
if (dataFrom.value.content[1].childrenContent.length <= 0) {
debugger

View File

@ -58,7 +58,6 @@
key: 'common-problem',
},
])
const whoShow1 = ref(whoShow)
const props = defineProps({
selectNow: { type: String, default: '' },
dataList: { type: Object, default: null },
@ -101,11 +100,13 @@
list.value.push(item.attrType)
} else if (item.attrType === '应用展示视频') {
list.value.push('应用展示')
} else if (
item.attrType === '访问地址' &&
props.dataList.applyState === '已申请'
) {
list.value.push('应用详情')
}
})
if (props.dataList.link && whoShow1.value.itShowQingDao) {
list.value.push('应用详情')
}
list.value.unshift('关联组件')
list.value.push('部署与安全')
list.value.push('归属部门与服务商')
@ -145,11 +146,13 @@
list.value.push(item.attrType)
} else if (item.attrType === '应用展示视频') {
list.value.push('应用展示')
} else if (
item.attrType === '访问地址' &&
props.dataList.applyState === '已申请'
) {
list.value.push('应用详情')
}
})
if (props.dataList.link && whoShow1.value.itShowQingDao) {
list.value.push('应用详情')
}
list.value.unshift('关联组件')
list.value.push('部署与安全')
list.value.push('归属部门与服务商')