Browse Source

bug修改

master
qushutong 6 years ago
parent
commit
80a1605453
  1. 4
      src/views/modules/news/banner-add-or-update.vue
  2. 4
      src/views/modules/news/news-publish.vue
  3. 2
      src/views/modules/news/notice-add-or-update.vue

4
src/views/modules/news/banner-add-or-update.vue

@ -85,6 +85,7 @@
:action="this.uploadUrl" :action="this.uploadUrl"
:show-file-list="false" :show-file-list="false"
:on-success="handleAvatarSuccess" :on-success="handleAvatarSuccess"
:on-error="handelError"
:before-upload="beforeAvatarUpload"> :before-upload="beforeAvatarUpload">
<img v-if="dataForm.imgUrl" <img v-if="dataForm.imgUrl"
:src="dataForm.imgUrl" :src="dataForm.imgUrl"
@ -226,6 +227,9 @@ export default {
beforeAvatarUpload (file) { beforeAvatarUpload (file) {
this.loading = true this.loading = true
}, },
handelError () {
this.loading = false
},
getListFromDict (dictType) { getListFromDict (dictType) {
this.$http.get(`/sys/dict/listSimple/` + dictType).then(({ data: res }) => { this.$http.get(`/sys/dict/listSimple/` + dictType).then(({ data: res }) => {
if (res.code !== 0) { if (res.code !== 0) {

4
src/views/modules/news/news-publish.vue

@ -95,6 +95,7 @@
:action="uploadUrl" :action="uploadUrl"
:show-file-list="false" :show-file-list="false"
:on-success="handleAvatarSuccess" :on-success="handleAvatarSuccess"
:on-error="handelError"
:before-upload="beforeAvatarUpload"> :before-upload="beforeAvatarUpload">
<img v-if="dataForm.newsImageUrl" <img v-if="dataForm.newsImageUrl"
:src="dataForm.newsImageUrl" :src="dataForm.newsImageUrl"
@ -414,6 +415,9 @@ export default {
}, },
beforeAvatarUpload (file) { beforeAvatarUpload (file) {
this.loading = true this.loading = true
},
handelError () {
this.loading = false
} }
}, },
components: { components: {

2
src/views/modules/news/notice-add-or-update.vue

@ -191,6 +191,8 @@ export default {
this.$refs['dataForm'].resetFields() this.$refs['dataForm'].resetFields()
if (this.dataForm.id) { if (this.dataForm.id) {
this.getInfo() this.getInfo()
} else {
this.dataForm = {}
} }
}) })
}, },

Loading…
Cancel
Save