Merge remote-tracking branch 'origin/master'

main
liu.shiyi 1 year ago
commit ce354e7513

@ -191,6 +191,7 @@ export default {
value: 'verticalAround'
}
],
initialCoverPicture: '',
appInfo: '',
saveLoading: false,
createdImgLoading: false,
@ -222,6 +223,7 @@ export default {
}
},
mounted () {
this.initialCoverPicture = this.pageInfo.coverPicture || ''
this.$refs.zoomInput.$el.addEventListener('mousewheel', this.handleMouseWheel)
},
beforeDestroy () {
@ -460,7 +462,8 @@ export default {
pageInfo.coverPicture = dataUrl
}
} else {
pageInfo.coverPicture = ''
this.$message.warning('保存封面失败,将使用上次保存的封面')
pageInfo.coverPicture = this.initialCoverPicture
}
const res = await saveScreen(pageInfo)
this.$message.success('保存成功')

@ -172,6 +172,7 @@ export default {
props: {},
data () {
return {
initialCoverPicture: '',
form: {
name: '',
coverPicture: '',
@ -237,6 +238,7 @@ export default {
const type = this.$route.query.type
if (code) {
getBizComponentInfo(code).then(data => {
this.initialCoverPicture = data.coverPicture || ''
if (type && type === 'g2plot') {
this.form = {
...data,
@ -370,7 +372,8 @@ export default {
this.form.coverPicture = dataUrl
}
} else {
this.form.coverPicture = ''
this.$message.warning('保存封面失败,将使用上次保存的封面')
this.form.coverPicture = this.initialCoverPicture
}
updateBizComponent(this.form).then(() => {
this.$message({

Loading…
Cancel
Save