Commit 321127c9 by chenwq

表格-图片-预览大图

1 parent 072310ca
...@@ -168,9 +168,30 @@ html { ...@@ -168,9 +168,30 @@ html {
border: 0; border: 0;
} }
.marketing .table-show-img { .table-popover-block {
width: 160px; position: relative;
height: 160px; height: 160px !important;
overflow: hidden;
border-width: 0 !important;
padding: 0 !important;
margin-bottom: 10px !important;
}
.table-popover-block.el-popper .popper__arrow {
display: none !important;
}
.table-popover-img {
width: 100%;
// height: 100%;
position: absolute;
top: 50%;
left: 50%;
transform: translate(-50%, -50%);
}
.marketing .pointer {
cursor: pointer;
} }
.marketing .img-w-100 { .marketing .img-w-100 {
......
...@@ -17,10 +17,16 @@ ...@@ -17,10 +17,16 @@
<!-- 表格区域 开始 --> <!-- 表格区域 开始 -->
<GLTable ref="zoneRef" :getListApi="getListApi" :noDataImg="url" :searchForm="searchForm" :tableParams="tableParams" :pageConf="pageConf" :beforeSearchFn="beforeSearchFn" @setTableFinishFun="setTableFinishFun"> <GLTable ref="zoneRef" :getListApi="getListApi" :noDataImg="url" :searchForm="searchForm" :tableParams="tableParams" :pageConf="pageConf" :beforeSearchFn="beforeSearchFn" @setTableFinishFun="setTableFinishFun">
<div slot="logoUrl" class="table-image" slot-scope="scope"> <div slot="logoUrl" class="table-image" slot-scope="scope">
<img class="img-60" :src="scope.scope.logoUrl" /> <el-popover placement="top" width="160" trigger="hover" popper-class="table-popover-block">
<img class="table-popover-img" :src="scope.scope.logoUrl" />
<img class="img-60 pointer" slot="reference" :src="scope.scope.logoUrl" />
</el-popover>
</div> </div>
<div slot="showImageUrl" class="table-image" slot-scope="scope"> <div slot="showImageUrl" class="table-image" slot-scope="scope">
<img class="img-60" :src="scope.scope.showImageUrl" /> <el-popover placement="top" width="160" trigger="hover" popper-class="table-popover-block">
<img class="table-popover-img" :src="scope.scope.showImageUrl" />
<img class="img-60 pointer" slot="reference" :src="scope.scope.showImageUrl" />
</el-popover>
</div> </div>
<!-- <div class="table-btns" slot="auth-button" slot-scope="scope"> <!-- <div class="table-btns" slot="auth-button" slot-scope="scope">
<GLButton type="text" fn="编辑" @click="handleEdit(2, scope.scope)">编辑</GLButton> <GLButton type="text" fn="编辑" @click="handleEdit(2, scope.scope)">编辑</GLButton>
......
...@@ -18,7 +18,10 @@ ...@@ -18,7 +18,10 @@
<!-- 表格区域 开始 --> <!-- 表格区域 开始 -->
<GLTable ref="proGroupRef" class="table-img" :getListApi="getListApi" :noDataImg="url" :searchForm="tableSearchForm" :tableParams="tableParams" :pageConf="pageConf" :beforeSearchFn="beforeSearchFn" @setTableFinishFun="setTableFinishFun"> <GLTable ref="proGroupRef" class="table-img" :getListApi="getListApi" :noDataImg="url" :searchForm="tableSearchForm" :tableParams="tableParams" :pageConf="pageConf" :beforeSearchFn="beforeSearchFn" @setTableFinishFun="setTableFinishFun">
<div slot="goodsImage" class="table-image" slot-scope="scope"> <div slot="goodsImage" class="table-image" slot-scope="scope">
<img class="img-60" :src="scope.scope.goodsImage" /> <el-popover placement="top" width="160" trigger="hover" popper-class="table-popover-block">
<img class="table-popover-img" :src="scope.scope.goodsImage" />
<img class="img-60 pointer" slot="reference" :src="scope.scope.goodsImage" />
</el-popover>
</div> </div>
<div class="table-btns" slot="auth-button" slot-scope="scope"> <div class="table-btns" slot="auth-button" slot-scope="scope">
<el-button type="text" @click="handleUpOrDown(scope.scope)">{{ scope.scope.goodsStatus ? '下架' : '上架' }}</el-button> <el-button type="text" @click="handleUpOrDown(scope.scope)">{{ scope.scope.goodsStatus ? '下架' : '上架' }}</el-button>
...@@ -333,10 +336,10 @@ export default { ...@@ -333,10 +336,10 @@ export default {
this.$refs.proGroupRef.data.forEach(item => { this.$refs.proGroupRef.data.forEach(item => {
item.saleAmount = item.goodsStatistics.saleAmount item.saleAmount = item.goodsStatistics.saleAmount
if (item.specificationDetailList.length > 1) { if (item.specificationDetailList.length > 1) {
let retailPriceList = item.specificationDetailList.sort(function(a, b) { let retailPriceList = item.specificationDetailList.sort(function (a, b) {
return a.retailPrice - b.retailPrice return a.retailPrice - b.retailPrice
}) })
let stockeList = item.specificationDetailList.sort(function(a, b) { let stockeList = item.specificationDetailList.sort(function (a, b) {
return a.stock - b.stock return a.stock - b.stock
}) })
let minRatilPrice = retailPriceList[0].retailPrice / 100 let minRatilPrice = retailPriceList[0].retailPrice / 100
......
...@@ -18,7 +18,10 @@ ...@@ -18,7 +18,10 @@
<!-- 表格区域 开始 --> <!-- 表格区域 开始 -->
<GLTable ref="proGroupRef" class="table-img" :getListApi="getListApi" :noDataImg="url" :searchForm="tableSearchForm" :tableParams="tableParams" :pageConf="pageConf" :beforeSearchFn="beforeSearchFn" @setTableFinishFun="setTableFinishFun"> <GLTable ref="proGroupRef" class="table-img" :getListApi="getListApi" :noDataImg="url" :searchForm="tableSearchForm" :tableParams="tableParams" :pageConf="pageConf" :beforeSearchFn="beforeSearchFn" @setTableFinishFun="setTableFinishFun">
<template slot="goodsImage" slot-scope="scope"> <template slot="goodsImage" slot-scope="scope">
<img class="img-60" :src="scope.scope.goodsImage" /> <el-popover placement="top" width="160" trigger="hover" popper-class="table-popover-block">
<img class="table-popover-img" :src="scope.scope.goodsImage" />
<img class="img-60 pointer" slot="reference" :src="scope.scope.goodsImage" />
</el-popover>
</template> </template>
<div class="table-btns" slot="auth-button" slot-scope="scope"> <div class="table-btns" slot="auth-button" slot-scope="scope">
<!-- <el-button v-if="!scope.scope.goodsStatus" type="text" @click="handleEdit(2, scope.scope)">编辑</el-button> --> <!-- <el-button v-if="!scope.scope.goodsStatus" type="text" @click="handleEdit(2, scope.scope)">编辑</el-button> -->
...@@ -293,7 +296,7 @@ export default { ...@@ -293,7 +296,7 @@ export default {
handleDwonNotice(row) { handleDwonNotice(row) {
this.$alert('你带货的' + row.goodsName + '商品现已下架,下架原因:' + row.offReason, '商品下架通知', { this.$alert('你带货的' + row.goodsName + '商品现已下架,下架原因:' + row.offReason, '商品下架通知', {
confirmButtonText: '确定', confirmButtonText: '确定',
callback: action => {} callback: action => { }
}) })
}, },
handleUpOrDown(row) { handleUpOrDown(row) {
...@@ -383,10 +386,10 @@ export default { ...@@ -383,10 +386,10 @@ export default {
this.$refs.proGroupRef.data.forEach(item => { this.$refs.proGroupRef.data.forEach(item => {
item.saleAmount = item.goodsStatistics.saleAmount item.saleAmount = item.goodsStatistics.saleAmount
if (item.specificationDetailList.length > 1) { if (item.specificationDetailList.length > 1) {
let retailPriceList = item.specificationDetailList.sort(function(a, b) { let retailPriceList = item.specificationDetailList.sort(function (a, b) {
return a.retailPrice - b.retailPrice return a.retailPrice - b.retailPrice
}) })
let stockeList = item.specificationDetailList.sort(function(a, b) { let stockeList = item.specificationDetailList.sort(function (a, b) {
return a.stock - b.stock return a.stock - b.stock
}) })
let minRatilPrice = retailPriceList[0].retailPrice / 100 let minRatilPrice = retailPriceList[0].retailPrice / 100
......
...@@ -16,12 +16,10 @@ ...@@ -16,12 +16,10 @@
<!-- 表格区域 开始 --> <!-- 表格区域 开始 -->
<GLTable ref="takeGoodRef" class="table-img" :getListApi="getListApi" :noDataImg="url" :searchForm="tableSearchForm" :tableParams="tableParams" :pageConf="pageConf" :beforeSearchFn="beforeSearchFn" @setTableFinishFun="setTableFinishFun"> <GLTable ref="takeGoodRef" class="table-img" :getListApi="getListApi" :noDataImg="url" :searchForm="tableSearchForm" :tableParams="tableParams" :pageConf="pageConf" :beforeSearchFn="beforeSearchFn" @setTableFinishFun="setTableFinishFun">
<div slot="goodsImage" slot-scope="scope"> <div slot="goodsImage" slot-scope="scope">
<!-- <el-tooltip placement="top" trigger="hover" popper-class="table-show-img" effect="light" :visible-arrow="false"> <el-popover placement="top" width="160" trigger="hover" popper-class="table-popover-block">
<div slot="content" class="table-show-img"> <img class="table-popover-img" :src="scope.scope.goods.goodsImage" />
<img class="img-w-100" :src="scope.scope.goods.goodsImage" /> <img class="img-60 pointer" slot="reference" :src="scope.scope.goods.goodsImage" />
</div> --> </el-popover>
<img class="img-60" :src="scope.scope.goods.goodsImage" />
<!-- </el-tooltip> -->
</div> </div>
<div class="table-btns" slot="auth-button" slot-scope="scope"> <div class="table-btns" slot="auth-button" slot-scope="scope">
<el-button v-if="!scope.scope.taked" type="text" @click="handleSingleTakeGood(scope.scope)">带货</el-button> <el-button v-if="!scope.scope.taked" type="text" @click="handleSingleTakeGood(scope.scope)">带货</el-button>
...@@ -44,6 +42,7 @@ export default { ...@@ -44,6 +42,7 @@ export default {
return { return {
size: 'small', size: 'small',
url: url, url: url,
hideAfter: 100000,
searchForm: { searchForm: {
goodsName: '', goodsName: '',
createDate: [] createDate: []
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!