From 3af175c506ec3a9575d2c014616c7ae32e546f7b Mon Sep 17 00:00:00 2001
From: YeMingfei666 <1619116647@qq.com>
Date: Mon, 31 Mar 2025 15:57:19 +0800
Subject: [PATCH] =?UTF-8?q?feat:=20=E5=8F=B0=E6=A1=8C=E5=88=97=E8=A1=A8?=
=?UTF-8?q?=E5=A2=9E=E5=8A=A0=E7=BB=91=E5=AE=9A=E6=A1=8C=E7=A0=81=E5=8A=9F?=
=?UTF-8?q?=E8=83=BD=EF=BC=88=E6=9A=82=E6=97=B6=E9=9A=90=E8=97=8F=EF=BC=89?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/api/account/table.ts | 10 ++-
.../tool/table/components/bind-table-code.vue | 82 +++++++++++++++++++
src/views/tool/table/index.vue | 18 +++-
3 files changed, 107 insertions(+), 3 deletions(-)
create mode 100644 src/views/tool/table/components/bind-table-code.vue
diff --git a/src/api/account/table.ts b/src/api/account/table.ts
index 02586a5..57185f5 100644
--- a/src/api/account/table.ts
+++ b/src/api/account/table.ts
@@ -45,7 +45,15 @@ const API = {
method: "delete",
data: { id },
});
- }
+ },
+ //绑定桌码
+ bindTableCode(data: any) {
+ return request({
+ url: `${baseURL}/bind`,
+ method: "post",
+ data
+ });
+ },
}
export default API;
/**
diff --git a/src/views/tool/table/components/bind-table-code.vue b/src/views/tool/table/components/bind-table-code.vue
new file mode 100644
index 0000000..276f708
--- /dev/null
+++ b/src/views/tool/table/components/bind-table-code.vue
@@ -0,0 +1,82 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/src/views/tool/table/index.vue b/src/views/tool/table/index.vue
index 269de33..d641456 100644
--- a/src/views/tool/table/index.vue
+++ b/src/views/tool/table/index.vue
@@ -68,11 +68,12 @@
-
编辑
+
-
删除
@@ -224,6 +225,8 @@
+
+
@@ -236,8 +239,15 @@ import shopAreaApi from "@/api/account/shopArea";
import tableApi from "@/api/account/table";
import addEara from "./components/addEara.vue";
import addTable from "./components/addTable.vue";
+import bindCode from "./components/bind-table-code.vue";
import downloadTableCode from "./components/downloadTableCode.vue";
+//绑定桌码
+const refBindCode = ref();
+function showBindCode(item) {
+ refBindCode.value.open(item);
+}
+
//桌台二维码
const refDownloadTableCode = ref();
function showDownloadTableCode() {
@@ -282,6 +292,10 @@ function downloadShopCpde() {
* @param item
*/
function tableComman(command, item) {
+ if (command === "bindTableCode") {
+ showBindCode(item);
+ return;
+ }
if (command === "edit") {
return refAddTable.value.show(item);
}