1.店铺设置 - 店铺信息 - 桌位费开启免餐位费不可修改输入框

2.店铺设置 - 店铺信息logo、门店、二维码、小程序码图片添加下载按钮
3.新增pad点单设置
This commit is contained in:
gyq
2024-10-24 11:10:33 +08:00
parent 36d667326e
commit abac233027
8 changed files with 711 additions and 38 deletions

View File

@@ -1,5 +1,5 @@
<template>
<el-dialog title="选择商品" :visible.sync="dialogVisible" @open="resetHandle()">
<el-dialog title="选择商品" top="5vh" :visible.sync="dialogVisible">
<el-form :model="searhForm" inline>
<el-form-item>
<el-input v-model="searhForm.name" placeholder="商品名称"></el-input>
@@ -16,8 +16,8 @@
</el-form-item>
</el-form>
<div class="head-container">
<el-table ref="table" :data="tableData.list" v-loading="tableData.loading">
<el-table-column type="selection" width="55" align="center"></el-table-column>
<el-table ref="table" :data="tableData.list" height="500" v-loading="tableData.loading">
<el-table-column type="selection" width="55" align="center" v-if="!radio"></el-table-column>
<el-table-column label="商品信息">
<template v-slot="scope">
<div class="shop_info">
@@ -36,11 +36,11 @@
</template>
</el-table-column> <el-table-column label="是否售罄">
<template v-slot="scope">
{{ scope.row.isPauseSale == 1?'':'' }}
{{ scope.row.isPauseSale == 1 ? '' : '' }}
</template>
</el-table-column> <el-table-column label="是否分销">
<template v-slot="scope">
{{ scope.row.isDistribute == 1?'':'' }}
{{ scope.row.isDistribute == 1 ? '' : '' }}
</template>
</el-table-column>
<el-table-column label="售价">
@@ -54,12 +54,17 @@
</template>
</el-table-column>
<el-table-column label="分类名称" prop="categoryName"></el-table-column>
<el-table-column label="操作">
<template v-slot="scope">
<el-button type="primary" @click="selectHandle(scope.row)">选择</el-button>
</template>
</el-table-column>
</el-table>
</div>
<el-pagination :total="tableData.total" :current-page="tableData.page + 1" :page-size="tableData.size"
@current-change="paginationChange" @size-change="sizeChange"
layout="total, sizes, prev, pager, next, jumper"></el-pagination>
<span slot="footer" class="dialog-footer">
<span slot="footer" class="dialog-footer" v-if="!radio">
<el-button @click="dialogVisible = false"> </el-button>
<el-button type="primary" @click="confirmHandle"> </el-button>
</span>
@@ -69,6 +74,13 @@
<script>
import { tbShopCategoryGet, tbProduct } from "@/api/shop";
export default {
props: {
// 是否为单选
radio: {
type: Boolean,
default: false
}
},
data() {
return {
dialogVisible: false,
@@ -88,6 +100,11 @@ export default {
}
},
methods: {
// 单选商品
selectHandle(row) {
this.$emit('success', [{ ...row }])
this.close()
},
// 确定选商品
confirmHandle() {
let res = this.$refs.table.selection
@@ -154,7 +171,7 @@ export default {
console.log(error)
}
},
show(goods) {
async show(goods, categoryId) {
this.dialogVisible = true
if (goods && goods.length) {
this.goods = goods
@@ -162,8 +179,18 @@ export default {
this.goods = []
}
this.resetHandle()
this.tbShopCategoryGet()
this.getTableData()
console.log(categoryId);
if (categoryId) {
this.searhForm.category = categoryId
}
console.log(this.searhForm);
await this.tbShopCategoryGet()
await this.getTableData()
},
close() {
this.dialogVisible = false