fix: 修改绑定桌码根据环境变量配置是否显示

This commit is contained in:
YeMingfei666 2025-03-31 16:28:56 +08:00
parent db5eee31a1
commit ad2ce6cad7
2 changed files with 6 additions and 2 deletions

View File

@ -1,4 +1,6 @@
# 有VITE_APP_NAME=production时隐藏台桌列表绑定桌码功能
VITE_APP_NAME=production
# WebSocket端点(可选) # WebSocket端点(可选)

View File

@ -70,9 +70,9 @@
<el-dropdown-item command="edit"> <el-dropdown-item command="edit">
<span>编辑</span> <span>编辑</span>
</el-dropdown-item> </el-dropdown-item>
<!-- <el-dropdown-item command="bindTableCode" > <el-dropdown-item command="bindTableCode" v-if="envName !== 'production'">
<span>绑定桌码</span> <span>绑定桌码</span>
</el-dropdown-item> --> </el-dropdown-item>
<el-dropdown-item command="del"> <el-dropdown-item command="del">
<span>删除</span> <span>删除</span>
</el-dropdown-item> </el-dropdown-item>
@ -242,6 +242,8 @@ import addTable from "./components/addTable.vue";
import bindCode from "./components/bind-table-code.vue"; import bindCode from "./components/bind-table-code.vue";
import downloadTableCode from "./components/downloadTableCode.vue"; import downloadTableCode from "./components/downloadTableCode.vue";
const envName = import.meta.env.VITE_APP_NAME;
// //
const refBindCode = ref(); const refBindCode = ref();
function showBindCode(item) { function showBindCode(item) {