新功能
This commit is contained in:
@ -206,7 +206,7 @@
|
||||
>
|
||||
<img
|
||||
v-if="form.logo"
|
||||
:src="imagePath + form.logo"
|
||||
:src="getImageUrl(form.logo)"
|
||||
class="list-img"
|
||||
/>
|
||||
<i v-if="!form.logo" class="el-icon-plus"></i>
|
||||
@ -348,6 +348,8 @@ import {
|
||||
getMerchantInfo,
|
||||
saveMerchant,
|
||||
} from '@/api/merchant'
|
||||
import { resolveImageUrl } from '@/utils/image'
|
||||
import { getUploadFileName } from '@/utils/upload'
|
||||
export default {
|
||||
name: 'MerchantIndex',
|
||||
data() {
|
||||
@ -433,6 +435,9 @@ export default {
|
||||
this.getList()
|
||||
},
|
||||
methods: {
|
||||
getImageUrl(path) {
|
||||
return resolveImageUrl(this.imagePath, path)
|
||||
},
|
||||
// 查询日志
|
||||
getList() {
|
||||
this.loading = true
|
||||
@ -560,8 +565,10 @@ export default {
|
||||
handleAccount(row) {
|
||||
this.$router.push({ path: '/system/account/index?merchantId=' + row.id })
|
||||
},
|
||||
handleUploadSuccess(file) {
|
||||
this.form.logo = file.data.fileName
|
||||
handleUploadSuccess(res) {
|
||||
const fileName = getUploadFileName(res)
|
||||
if (!fileName) return
|
||||
this.form.logo = fileName
|
||||
},
|
||||
},
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user