在Spring boot中如何實現session?
不知道怎么創建session對象,來保存登錄的用戶信息?
ActionContext.getContext().getSession();????//這種方法好像不行
ServletActionContext.getRequest().getSession();????//也不行
不知道怎么創建session對象,來保存登錄的用戶信息?
ActionContext.getContext().getSession();????//這種方法好像不行
ServletActionContext.getRequest().getSession();????//也不行
2017-05-19
舉報
2018-04-25
我在controller中每次取到的session都不是同一個怎么處理
2017-06-19
HttpSession session = request.getSession();
2017-05-22
定義方法時,直接在參數列表中傳入HttpSession,直接用session這個對象就可以了