From 1f777f76a41dbcd4a98bc7882417ce554b4b9300 Mon Sep 17 00:00:00 2001 From: lihuilin Date: Thu, 27 Nov 2025 11:34:16 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B4=BB=E5=8A=A8=E6=9D=83=E9=99=90?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/activityManage/activity.vue | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/src/views/activityManage/activity.vue b/src/views/activityManage/activity.vue index bc74406..13c5c28 100644 --- a/src/views/activityManage/activity.vue +++ b/src/views/activityManage/activity.vue @@ -193,6 +193,10 @@ const editForm = ref({ }) const marketOptions = ref([]) const getActivity = async function () { + if (!hasMenuPermission(permissionMapping.view_activity)) { + ElMessage.error('无此权限') + return + } const rechargeActivity = { activityName: searchForm.value.activityName, businessBelong: searchForm.value.businessBelong, @@ -219,6 +223,10 @@ const getActivity = async function () { } } const handleAdd = async function () { + if (!hasMenuPermission(permissionMapping.add_activity)) { + ElMessage.error('无此权限') + return + } const activityName = addForm.value.activityName if (!validateActivityName(activityName)) return @@ -274,6 +282,10 @@ const handleAdd = async function () { // 新增节流 const throttleGetActivity = _.throttle(handleAdd, 5000, { trailing: false }); const handleEdit = async function () { + if (!hasMenuPermission(permissionMapping.edit_activity)) { + ElMessage.error('无此权限') + return + } const activityName = editForm.value.activityName if (!validateActivityName(activityName)) return @@ -323,6 +335,10 @@ const handleEdit = async function () { } } const handleDel = async function (row) { + if (!hasMenuPermission(permissionMapping.delete_activity)) { + ElMessage.error('无此权限') + return + } if (!currentDelRow.value) { ElMessage.error('当前选择无数据') return