121
This commit is contained in:
parent
e5939bc8b0
commit
e2bd373db2
|
@ -36,6 +36,7 @@
|
|||
</template>
|
||||
</el-popconfirm>
|
||||
</div>
|
||||
<!-- 数据展示 -->
|
||||
<el-table :data="tableData" border stripe header-cell-class-name="headerBg" :cell-style="{textAlign: 'center'}"
|
||||
@selection-change="handleSelectionChange" :header-cell-style="{'text-align': 'center'}"
|
||||
>
|
||||
|
@ -47,7 +48,7 @@
|
|||
</div>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="商品图片">
|
||||
<el-table-column prop="goodImg" label="商品图片">
|
||||
<template #default="scope">
|
||||
<div>
|
||||
<img :src="scope.row.goodImg" alt="" style="height: 50px;">
|
||||
|
@ -98,7 +99,7 @@
|
|||
编辑
|
||||
</el-button>
|
||||
<el-button size="small" @click="handleOff(scope.$index, scope.row)">
|
||||
{{scope.row.attribute}}
|
||||
{{ status }}
|
||||
</el-button>
|
||||
<el-button
|
||||
size="small"
|
||||
|
@ -122,9 +123,9 @@
|
|||
<el-pagination
|
||||
@size-change="handleSizeChange"
|
||||
@current-change="handleCurrentChange"
|
||||
:current-page="pageNum"
|
||||
:page-size="pageSize"
|
||||
:page-sizes="[2, 5, 10, 20]"
|
||||
:current-page="searchParams.current"
|
||||
:page-size="searchParams.pageSize"
|
||||
:page-sizes="[5, 10, 15, 20]"
|
||||
:small="null"
|
||||
:disabled="null"
|
||||
:background="null"
|
||||
|
@ -268,6 +269,8 @@ const Region = ref('');
|
|||
let selectedProduct = ref('');
|
||||
const loading = ref(false)
|
||||
const tableData = ref([]);
|
||||
//商品状态
|
||||
const status = ref(0)
|
||||
let editForm = ref({
|
||||
id: '',
|
||||
goodImg: '',
|
||||
|
@ -298,7 +301,8 @@ const handleRevise = (index: number, row: any) => {
|
|||
editForm.value = row;
|
||||
};
|
||||
const handleOff = (index: number, row: any) => {
|
||||
if (row.attribute === '上架') {
|
||||
console.log(row)
|
||||
if (row.isShelves === '上架') {
|
||||
row.isShelves = '上架';
|
||||
row.attribute = '下架';
|
||||
} else if (row.attribute === '下架') {
|
||||
|
|
Loading…
Reference in New Issue
Block a user