From 9057e04efad1b7d61c77a72e5c37a504d0aee935 Mon Sep 17 00:00:00 2001 From: doum <doum> Date: 星期五, 26 九月 2025 09:24:03 +0800 Subject: [PATCH] H5静态化 --- admin/src/components/base/BasePage.vue | 22 +++++++++++++++++++--- 1 files changed, 19 insertions(+), 3 deletions(-) diff --git a/admin/src/components/base/BasePage.vue b/admin/src/components/base/BasePage.vue index 38cf164..c291eca 100644 --- a/admin/src/components/base/BasePage.vue +++ b/admin/src/components/base/BasePage.vue @@ -9,14 +9,25 @@ } }, computed: { - ...mapState(['userInfo']), + ...mapState(['userInfo','tableHeightNew']), // 鏄惁涓鸿秴绾х鐞嗗憳 isAdmin () { return this.userInfo.roles.findIndex(code => code === this.adminCode) > -1 } }, methods: { - // 鏄惁鍖呭惈鎸囧畾瑙掕壊 + /** + * 鍒ゆ柇鏄惁涓篋EBUG妯″紡 + */ + isDebug () { + return process.env.VUE_APP_DEBUG === 'on' + }, + /** + * 鏄惁鍖呭惈鎸囧畾瑙掕壊 + * + * @param roles 鐩爣瑙掕壊鏁扮粍 + * @returns {boolean} + */ containRoles (roles) { if (roles == null) { return true @@ -34,7 +45,12 @@ } return false }, - // 鏄惁鍖呭惈鎸囧畾鏉冮檺 + /** + * 鏄惁鍖呭惈鎸囧畾鏉冮檺 + * + * @param permissions 鐩爣鏉冮檺鏁扮粍 + * @returns {boolean} + */ containPermissions (permissions) { if (permissions == null) { return true -- Gitblit v1.9.3