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