From b4915babf2213dd846288772cc7139cd6c52b591 Mon Sep 17 00:00:00 2001 From: qubiaobiao <3294694717@qq.com> Date: Thu, 11 Jun 2026 13:15:46 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E4=BF=AE=E6=94=B9SN=E5=8F=B7?= =?UTF-8?q?=E6=95=B0=E9=87=8F=E5=8A=9F=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/url.js | 2 ++ src/components/mainPage/SNAdmin.vue | 31 ++++++++++++++++++++++++++++- 2 files changed, 32 insertions(+), 1 deletion(-) diff --git a/src/api/url.js b/src/api/url.js index e2c02d7..a828494 100644 --- a/src/api/url.js +++ b/src/api/url.js @@ -180,6 +180,8 @@ export default { searchAllocationSN: "/accountManager/searchAllocationSN", // 搜索可分配的单位用户 searchAllocationUser: "/accountManager/searchAllocationUser", + // 修改可管理的SN号数量 + editSNCount: "/accountManager/editSNCount", // B端分配SN号 allocationSN: "/accountManager/allocationSN", // 查看B端SN号分配记录 diff --git a/src/components/mainPage/SNAdmin.vue b/src/components/mainPage/SNAdmin.vue index 79daab9..033d094 100644 --- a/src/components/mainPage/SNAdmin.vue +++ b/src/components/mainPage/SNAdmin.vue @@ -43,7 +43,7 @@ >
用户可管理的SN号数量 -
+
+ + 修改 +
确认{{ mode ? "绑定" : "解绑" }} @@ -227,6 +230,32 @@ const searchAllocationSN = () => { }); }; +const editSNCount = () => { + if (selectedUser.value === "") { + ElMessage.warning("请选择用户!"); + return; + } + const data = { + user_uid: userObj.value[selectedUser.value].uid, + length: snCount.value + }; + $http.post($url.editSNCount, data).then((res) => { + if (res.data.code === 200) { + resetCheckForm(); + usersArr.value = []; + SNArr.value = []; + searchAllocationUser(); + searchAllocationSN(); + ElMessage({ + message: "修改成功!", + type: "success", + }); + } else { + ElMessage.error("修改失败!"); + } + }); +}; + const allocationSN = () => { if ( selectedUser.value === "" ||