BUG修改
This commit is contained in:
parent
3acee93e23
commit
e8b741077e
|
@ -510,45 +510,45 @@ export default {
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
this.submitFrom.infoList = this.submitFrom.infoList.sort((a, b) => arr.indexOf(a.attrType) - arr.indexOf(b.attrType))
|
this.submitFrom.infoList = this.submitFrom.infoList.sort((a, b) => arr.indexOf(a.attrType) - arr.indexOf(b.attrType))
|
||||||
// if (this.submitFrom.id) {
|
if (this.submitFrom.id) {
|
||||||
// // 解决编辑无组件类型
|
// 解决编辑无组件类型
|
||||||
// this.submitFrom.infoList.map(val => {
|
this.submitFrom.infoList.map(val => {
|
||||||
// if (val.attrType === '组件类型') {
|
if (val.attrType === '组件类型') {
|
||||||
// val.attrValue = this.radio
|
val.attrValue = this.radio
|
||||||
// }
|
}
|
||||||
// })
|
})
|
||||||
// console.log('编辑===============>', this.submitFrom)
|
console.log('编辑===============>', this.submitFrom)
|
||||||
// console.log(this.submitFrom.infoList, '===============abc')
|
console.log(this.submitFrom.infoList, '===============abc')
|
||||||
// // 去重
|
// 去重
|
||||||
// const newArr = this.submitFrom.infoList.filter((element, index, self) => {
|
const newArr = this.submitFrom.infoList.filter((element, index, self) => {
|
||||||
// return self.findIndex(x => x.attrType === element.attrType) === index
|
return self.findIndex(x => x.attrType === element.attrType) === index
|
||||||
// })
|
})
|
||||||
// this.submitFrom.infoList = newArr
|
this.submitFrom.infoList = newArr
|
||||||
// console.log(this.submitFrom.infoList, '====================================wpwpwp')
|
console.log(this.submitFrom.infoList, '====================================wpwpwp')
|
||||||
// this.$http
|
this.$http
|
||||||
// .put('/resource/update', this.submitFrom)
|
.put('/resource/update', this.submitFrom)
|
||||||
// .then(({ data: res }) => {
|
.then(({ data: res }) => {
|
||||||
// if (res.code !== 0) {
|
if (res.code !== 0) {
|
||||||
// this.$message.error('修改失败!')
|
this.$message.error('修改失败!')
|
||||||
// } else {
|
} else {
|
||||||
// this.$message.success('修改成功!')
|
this.$message.success('修改成功!')
|
||||||
// this.clear()
|
this.clear()
|
||||||
// }
|
}
|
||||||
// })
|
})
|
||||||
// .catch(() => {})
|
.catch(() => {})
|
||||||
// } else {
|
} else {
|
||||||
// this.$http
|
this.$http
|
||||||
// .post('/resource/insert?source= b', this.submitFrom)
|
.post('/resource/insert?source= b', this.submitFrom)
|
||||||
// .then(({ data: res }) => {
|
.then(({ data: res }) => {
|
||||||
// if (res.code !== 0) {
|
if (res.code !== 0) {
|
||||||
// this.$message.error('上架失败!')
|
this.$message.error('上架失败!')
|
||||||
// } else {
|
} else {
|
||||||
// this.$message.success('上架成功!')
|
this.$message.success('上架成功!')
|
||||||
// this.clear()
|
this.clear()
|
||||||
// }
|
}
|
||||||
// })
|
})
|
||||||
// .catch(() => {})
|
.catch(() => {})
|
||||||
// }
|
}
|
||||||
},
|
},
|
||||||
// 新修改
|
// 新修改
|
||||||
UpdateData (item) {
|
UpdateData (item) {
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
* @Author: hisense.liangjunhua
|
* @Author: hisense.liangjunhua
|
||||||
* @Date: 2022-06-13 10:22:27
|
* @Date: 2022-06-13 10:22:27
|
||||||
* @LastEditors: hisense.liangjunhua
|
* @LastEditors: hisense.liangjunhua
|
||||||
* @LastEditTime: 2022-07-15 11:50:22
|
* @LastEditTime: 2022-07-15 16:13:40
|
||||||
* @Description: 算法上架
|
* @Description: 算法上架
|
||||||
-->
|
-->
|
||||||
<template>
|
<template>
|
||||||
|
@ -31,12 +31,14 @@
|
||||||
></put-on-the-shelf>
|
></put-on-the-shelf>
|
||||||
<put-on-the-shelf
|
<put-on-the-shelf
|
||||||
v-else-if="showView === '算法优势'"
|
v-else-if="showView === '算法优势'"
|
||||||
|
ref="sfys"
|
||||||
:refData="refData"
|
:refData="refData"
|
||||||
:dataFrom="dataFrom"
|
:dataFrom="dataFrom"
|
||||||
:configure="sfys"
|
:configure="sfys"
|
||||||
></put-on-the-shelf>
|
></put-on-the-shelf>
|
||||||
<put-on-the-shelf
|
<put-on-the-shelf
|
||||||
v-else-if="showView === '应用场景'"
|
v-else-if="showView === '应用场景'"
|
||||||
|
ref="yycj"
|
||||||
:refData="refData"
|
:refData="refData"
|
||||||
:dataFrom="dataFrom"
|
:dataFrom="dataFrom"
|
||||||
:configure="yycj"
|
:configure="yycj"
|
||||||
|
@ -80,6 +82,7 @@
|
||||||
></algorithm-deployment-use> -->
|
></algorithm-deployment-use> -->
|
||||||
</div>
|
</div>
|
||||||
<div class="btn" :class="showView === '基本信息' ? 'first' : ''">
|
<div class="btn" :class="showView === '基本信息' ? 'first' : ''">
|
||||||
|
<button @click="close()">取消</button>
|
||||||
<button v-show="showView !== '基本信息'" @click="back()">上一步</button>
|
<button v-show="showView !== '基本信息'" @click="back()">上一步</button>
|
||||||
<button v-show="showView === '部署与使用'" @click="preview()">
|
<button v-show="showView === '部署与使用'" @click="preview()">
|
||||||
预览
|
预览
|
||||||
|
@ -216,6 +219,9 @@
|
||||||
getUser().then((res) => {
|
getUser().then((res) => {
|
||||||
dataFrom.value.deptId = res.data.data.deptId
|
dataFrom.value.deptId = res.data.data.deptId
|
||||||
})
|
})
|
||||||
|
const close = () => {
|
||||||
|
window.close()
|
||||||
|
}
|
||||||
const back = () => {
|
const back = () => {
|
||||||
navList.value.forEach((val, index) => {
|
navList.value.forEach((val, index) => {
|
||||||
if (val.key === showView.value && index > 0) {
|
if (val.key === showView.value && index > 0) {
|
||||||
|
@ -446,8 +452,8 @@
|
||||||
}
|
}
|
||||||
.btn {
|
.btn {
|
||||||
display: flex;
|
display: flex;
|
||||||
justify-content: space-between;
|
justify-content: space-around;
|
||||||
padding: 10px 400px 0;
|
padding: 10px 350px 0;
|
||||||
button {
|
button {
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
width: 80px;
|
width: 80px;
|
||||||
|
@ -467,7 +473,7 @@
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
.first {
|
.first {
|
||||||
justify-content: center;
|
justify-content: space-around;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
* @Author: hisense.liangjunhua
|
* @Author: hisense.liangjunhua
|
||||||
* @Date: 2022-06-17 14:11:08
|
* @Date: 2022-06-17 14:11:08
|
||||||
* @LastEditors: hisense.liangjunhua
|
* @LastEditors: hisense.liangjunhua
|
||||||
* @LastEditTime: 2022-07-15 11:51:18
|
* @LastEditTime: 2022-07-15 14:57:15
|
||||||
* @Description: 上架
|
* @Description: 上架
|
||||||
-->
|
-->
|
||||||
<template>
|
<template>
|
||||||
|
@ -111,7 +111,7 @@
|
||||||
></upload>
|
></upload>
|
||||||
</div>
|
</div>
|
||||||
<div class="submit">
|
<div class="submit">
|
||||||
<a-button type="primary" @click="add(title.name)">提交</a-button>
|
<a-button type="primary" @click="add(title.name)">添加</a-button>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
Loading…
Reference in New Issue