From 7804263c6061aef813f0db27cb3046f746572606 Mon Sep 17 00:00:00 2001 From: admin <weikou2014> Date: 星期六, 06 三月 2021 16:07:26 +0800 Subject: [PATCH] 后台管理优化 --- src/main/java/com/yeshi/buwan/util/SystemUtil.java | 32 ++++++++++++++++++++++++++++++++ 1 files changed, 32 insertions(+), 0 deletions(-) diff --git a/src/main/java/com/yeshi/buwan/util/SystemUtil.java b/src/main/java/com/yeshi/buwan/util/SystemUtil.java index 8d2110c..0660bea 100644 --- a/src/main/java/com/yeshi/buwan/util/SystemUtil.java +++ b/src/main/java/com/yeshi/buwan/util/SystemUtil.java @@ -1,6 +1,10 @@ package com.yeshi.buwan.util; import com.yeshi.buwan.domain.DetailSystem; +import com.yeshi.buwan.domain.SystemInfo; + +import javax.servlet.http.HttpSession; +import java.util.List; public class SystemUtil { @@ -21,4 +25,32 @@ return 1; } + + /** + * 鑾峰彇system + * + * @param session + * @return + */ + public static SystemInfo getAdminSelectedSystem(HttpSession session) { + SystemInfo systemInfo = (SystemInfo) session.getAttribute("SELECTED-SYSTEM"); + return systemInfo; + } + + + public static String getAdminSelectedSystemId(HttpSession session) { + return getAdminSelectedSystem(session).getId(); + } + + /** + * 淇濆瓨System + * + * @param session + * @param systemInfo + */ + public static void saveAdminSelectedSystem(HttpSession session, SystemInfo systemInfo) { + session.setAttribute("SELECTED-SYSTEM", systemInfo); + } + + } -- Gitblit v1.8.0