|
@@ -73,6 +73,19 @@
|
|
|
:show-tooltip-when-overflow="true"
|
|
|
label="图号">
|
|
|
</el-table-column>
|
|
|
+ <el-table-column
|
|
|
+ prop="simplePic"
|
|
|
+ header-align="center"
|
|
|
+ align="center"
|
|
|
+ min-width="120"
|
|
|
+ label="简图">
|
|
|
+ <template slot-scope="scope">
|
|
|
+ <el-popover placement="right" title="" trigger="hover">
|
|
|
+ <img :src="scope.row.simplePic" style="height: 400px;width: 500px">
|
|
|
+ <img slot="reference" :src="scope.row.simplePic" :alt="scope.row.simplePic" style="max-height: 50px;max-width: 130px">
|
|
|
+ </el-popover>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
<el-table-column
|
|
|
prop="productName"
|
|
|
header-align="center"
|
|
@@ -299,6 +312,7 @@
|
|
|
import ChangeForm from './product-change'
|
|
|
import {bomStateOption, writeStateOption} from '@/utils/enums'
|
|
|
import UploadComponent from '@/views/modules/common/upload-component-v2'
|
|
|
+ import { downloadUrl } from '@/api/file'
|
|
|
|
|
|
export default {
|
|
|
name: 'product-management',
|
|
@@ -379,6 +393,13 @@ export default {
|
|
|
getProductList(params).then(({data}) => {
|
|
|
if (data && data.code === '200') {
|
|
|
this.dataList = data.data.records
|
|
|
+ this.dataList.forEach(item => {
|
|
|
+ if (item.attachList2 && item.attachList2.length > 0) {
|
|
|
+ item.simplePic = downloadUrl + item.attachList2[0].url
|
|
|
+ } else {
|
|
|
+ item.simplePic = ''
|
|
|
+ }
|
|
|
+ })
|
|
|
this.totalPage = Number(data.data.total)
|
|
|
} else {
|
|
|
this.dataList = []
|
|
@@ -652,7 +673,8 @@ export default {
|
|
|
this.$http({
|
|
|
url: this.$http.adornUrl(`/biz-service/product/importExcel`),
|
|
|
method: 'POST',
|
|
|
- data: formData
|
|
|
+ data: formData,
|
|
|
+ timeout: 0
|
|
|
}).then(({data}) => {
|
|
|
this.importLoading = false
|
|
|
if (data && data.code === '200') {
|