BUG修改
This commit is contained in:
parent
cf296916e1
commit
622f2f645b
|
@ -424,7 +424,7 @@ export default {
|
|||
this.submitFrom.infoList.push(obj)
|
||||
},
|
||||
submitData () {
|
||||
console.log('编辑11111111111===============>', this.putOnTheShelfList)
|
||||
console.log('提交11111111111===============>', this.putOnTheShelfList)
|
||||
const arr = []
|
||||
this.putOnTheShelfList.map(item => {
|
||||
item.children.map(child => {
|
||||
|
@ -510,45 +510,45 @@ export default {
|
|||
})
|
||||
})
|
||||
this.submitFrom.infoList = this.submitFrom.infoList.sort((a, b) => arr.indexOf(a.attrType) - arr.indexOf(b.attrType))
|
||||
if (this.submitFrom.id) {
|
||||
// 解决编辑无组件类型
|
||||
this.submitFrom.infoList.map(val => {
|
||||
if (val.attrType === '组件类型') {
|
||||
val.attrValue = this.radio
|
||||
}
|
||||
})
|
||||
console.log('编辑===============>', this.submitFrom)
|
||||
console.log(this.submitFrom.infoList, '===============abc')
|
||||
// 去重
|
||||
const newArr = this.submitFrom.infoList.filter((element, index, self) => {
|
||||
return self.findIndex(x => x.attrType === element.attrType) === index
|
||||
})
|
||||
this.submitFrom.infoList = newArr
|
||||
console.log(this.submitFrom.infoList, '====================================wpwpwp')
|
||||
this.$http
|
||||
.put('/resource/update', this.submitFrom)
|
||||
.then(({ data: res }) => {
|
||||
if (res.code !== 0) {
|
||||
this.$message.error('修改失败!')
|
||||
} else {
|
||||
this.$message.success('修改成功!')
|
||||
this.clear()
|
||||
}
|
||||
})
|
||||
.catch(() => {})
|
||||
} else {
|
||||
this.$http
|
||||
.post('/resource/insert?source= b', this.submitFrom)
|
||||
.then(({ data: res }) => {
|
||||
if (res.code !== 0) {
|
||||
this.$message.error('上架失败!')
|
||||
} else {
|
||||
this.$message.success('上架成功!')
|
||||
this.clear()
|
||||
}
|
||||
})
|
||||
.catch(() => {})
|
||||
}
|
||||
// if (this.submitFrom.id) {
|
||||
// // 解决编辑无组件类型
|
||||
// this.submitFrom.infoList.map(val => {
|
||||
// if (val.attrType === '组件类型') {
|
||||
// val.attrValue = this.radio
|
||||
// }
|
||||
// })
|
||||
// console.log('编辑===============>', this.submitFrom)
|
||||
// console.log(this.submitFrom.infoList, '===============abc')
|
||||
// // 去重
|
||||
// const newArr = this.submitFrom.infoList.filter((element, index, self) => {
|
||||
// return self.findIndex(x => x.attrType === element.attrType) === index
|
||||
// })
|
||||
// this.submitFrom.infoList = newArr
|
||||
// console.log(this.submitFrom.infoList, '====================================wpwpwp')
|
||||
// this.$http
|
||||
// .put('/resource/update', this.submitFrom)
|
||||
// .then(({ data: res }) => {
|
||||
// if (res.code !== 0) {
|
||||
// this.$message.error('修改失败!')
|
||||
// } else {
|
||||
// this.$message.success('修改成功!')
|
||||
// this.clear()
|
||||
// }
|
||||
// })
|
||||
// .catch(() => {})
|
||||
// } else {
|
||||
// this.$http
|
||||
// .post('/resource/insert?source= b', this.submitFrom)
|
||||
// .then(({ data: res }) => {
|
||||
// if (res.code !== 0) {
|
||||
// this.$message.error('上架失败!')
|
||||
// } else {
|
||||
// this.$message.success('上架成功!')
|
||||
// this.clear()
|
||||
// }
|
||||
// })
|
||||
// .catch(() => {})
|
||||
// }
|
||||
},
|
||||
// 新修改
|
||||
UpdateData (item) {
|
||||
|
|
|
@ -114,6 +114,9 @@ export default {
|
|||
if (!this.data.note1) {
|
||||
this.$http.get('/sys/user/info').then(({ data: res }) => {
|
||||
this.data.note1 = res.data.deptId
|
||||
this.$http.get('/sys/dept/' + res.data.deptId).then(res => {
|
||||
console.log(res.data.data, '部门信息=============================')
|
||||
})
|
||||
})
|
||||
}
|
||||
})
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* @Author: hisense.liangjunhua
|
||||
* @Date: 2022-06-17 14:11:08
|
||||
* @LastEditors: hisense.liangjunhua
|
||||
* @LastEditTime: 2022-07-13 18:14:42
|
||||
* @LastEditTime: 2022-07-15 11:06:55
|
||||
* @Description: 上架
|
||||
-->
|
||||
<template>
|
||||
|
@ -110,13 +110,13 @@
|
|||
:options="item.options"
|
||||
/>
|
||||
<a-input
|
||||
v-else-if="item.type == 'text'"
|
||||
v-else-if="item.type == 'AbilityType '"
|
||||
v-model:value="item.note1"
|
||||
:placeholder="'请输入' + item.name"
|
||||
:disabled="true"
|
||||
/>
|
||||
<a-input
|
||||
v-else-if="item.type == 'text2'"
|
||||
v-else-if="item.type == 'ComponentType'"
|
||||
v-model:value="item.note1"
|
||||
:placeholder="'请输入' + item.name"
|
||||
:disabled="true"
|
||||
|
@ -179,11 +179,14 @@
|
|||
:list="props.videoList"
|
||||
tip="支持视频类型,大小不超过100M"
|
||||
></upload>
|
||||
<a-button v-else-if="item.type == 'dialog'" @click="sourceClick">
|
||||
<a-button
|
||||
v-else-if="item.type == 'AssociatedApplication'"
|
||||
@click="sourceClick"
|
||||
>
|
||||
请选择来源应用
|
||||
</a-button>
|
||||
<a-button
|
||||
v-else-if="item.type == 'dialog2'"
|
||||
v-else-if="item.type == 'AssociatedComponents'"
|
||||
@click="componentsClick"
|
||||
>
|
||||
请选择关联组件
|
||||
|
|
Loading…
Reference in New Issue