Browse Source

修改

origin/feature/monitoring
曲树通 4 years ago
parent
commit
09b0d36f15
  1. 14
      src/views/modules/sys/dept-add-or-update.vue

14
src/views/modules/sys/dept-add-or-update.vue

@ -132,7 +132,7 @@
<el-upload class="avatar-uploader" <el-upload class="avatar-uploader"
:action="uploadUrl" :action="uploadUrl"
:show-file-list="false" :show-file-list="false"
:on-success="handleAvatarBannerSuccess" :on-success="handleDeptBusinessSuccess"
:on-error="handelError" :on-error="handelError"
:before-upload="beforeAvatarUpload"> :before-upload="beforeAvatarUpload">
<img v-if="dataForm.deptBusinessUrl" <img v-if="dataForm.deptBusinessUrl"
@ -152,7 +152,7 @@
<el-upload class="avatar-uploader" <el-upload class="avatar-uploader"
:action="uploadUrl" :action="uploadUrl"
:show-file-list="false" :show-file-list="false"
:on-success="handleAvatarBannerSuccess" :on-success="handleDeptPartySuccess"
:on-error="handelError" :on-error="handelError"
:before-upload="beforeAvatarUpload"> :before-upload="beforeAvatarUpload">
<img v-if="dataForm.deptPartyUrl" <img v-if="dataForm.deptPartyUrl"
@ -218,6 +218,7 @@ export default {
deptPartyUrl:'', deptPartyUrl:'',
deptBusinessUrl:'' deptBusinessUrl:''
}, },
loading: false,
uploadUrl: '', uploadUrl: '',
secondOrgDictList: [], secondOrgDictList: [],
mapSelectVisible: false mapSelectVisible: false
@ -361,9 +362,13 @@ export default {
this.loading = false this.loading = false
this.dataForm.headPic = res.data.url this.dataForm.headPic = res.data.url
}, },
handleAvatarBannerSuccess (res, file) { handleDeptBusinessSuccess (res, file) {
this.loading = false this.loading = false
this.dataForm.bannerUrl = res.data.url this.dataForm.deptBusinessUrl = res.data.url
},
handleDeptPartySuccess (res, file) {
this.loading = false
this.dataForm.deptPartyUrl = res.data.url
}, },
beforeAvatarUpload (file) { beforeAvatarUpload (file) {
this.loading = true this.loading = true
@ -398,6 +403,7 @@ export default {
duration: 500, duration: 500,
onClose: () => { onClose: () => {
this.visible = false this.visible = false
this.mapSelectVisible = false
this.$emit('refreshDataList') this.$emit('refreshDataList')
} }
}) })

Loading…
Cancel
Save