|
@ -91,7 +91,7 @@ |
|
|
<template slot-scope="scope"> |
|
|
<template slot-scope="scope"> |
|
|
<!-- <svg-icon :icon-class="scope.row.icon ? scope.row.icon : ''" /> --> |
|
|
<!-- <svg-icon :icon-class="scope.row.icon ? scope.row.icon : ''" /> --> |
|
|
<img v-if="!scope.row.bookCover" src="~@/assets/images/cover-bg.png" alt="" style="height: 60px;"> |
|
|
<img v-if="!scope.row.bookCover" src="~@/assets/images/cover-bg.png" alt="" style="height: 60px;"> |
|
|
<img v-else :src="baseApi + '/api/fileRelevant/getImg?imgType=2&imgId=' + scope.row.bookCover" alt="" style="height: 60px;"> |
|
|
|
|
|
|
|
|
<img v-else :src="baseApi + '/api/fileRelevant/getImg?imgType=2&imgId=' + scope.row.bookCover + '.jpg'" alt="" style="height: 60px;"> |
|
|
</template> |
|
|
</template> |
|
|
</el-table-column> |
|
|
</el-table-column> |
|
|
<el-table-column label="题名" prop="title" width="300px" :show-overflow-tooltip="true" /> |
|
|
<el-table-column label="题名" prop="title" width="300px" :show-overflow-tooltip="true" /> |
|
@ -196,7 +196,7 @@ export default { |
|
|
// 初始化编辑时候 |
|
|
// 初始化编辑时候 |
|
|
[CRUD.HOOK.beforeToEdit](crud, form) { |
|
|
[CRUD.HOOK.beforeToEdit](crud, form) { |
|
|
if (this.crud.form.bookCover) { |
|
|
if (this.crud.form.bookCover) { |
|
|
this.bookCover = this.baseApi + '/api/fileRelevant/getImg?imgType=2&imgId=' + this.crud.form.bookCover |
|
|
|
|
|
|
|
|
this.bookCover = this.baseApi + '/api/fileRelevant/getImg?imgType=2&imgId=' + this.crud.form.bookCover + '.jpg' |
|
|
} else { |
|
|
} else { |
|
|
this.bookCover = require('@/assets/images/cover-bg.png') |
|
|
this.bookCover = require('@/assets/images/cover-bg.png') |
|
|
} |
|
|
} |
|
@ -226,7 +226,7 @@ export default { |
|
|
console.log(value) |
|
|
console.log(value) |
|
|
if (value) { |
|
|
if (value) { |
|
|
this.form.bookCover = value |
|
|
this.form.bookCover = value |
|
|
this.bookCover = this.baseApi + '/api/fileRelevant/getImg?imgType=2&imgId=' + value |
|
|
|
|
|
|
|
|
this.bookCover = this.baseApi + '/api/fileRelevant/getImg?imgType=2&imgId=' + value + '.jpg' |
|
|
} else { |
|
|
} else { |
|
|
this.form.bookCover = null |
|
|
this.form.bookCover = null |
|
|
this.bookCover = null |
|
|
this.bookCover = null |
|
|