From d62ee4d9179e3b352b44f0d5528de3ac6286083d Mon Sep 17 00:00:00 2001
From: wuxw <928255095@qq.com>
Date: 星期四, 11 四月 2019 18:25:57 +0800
Subject: [PATCH] 员工权限开发
---
WebService/src/main/java/com/java110/web/components/NavComponent.java | 51 +++++++++++++++++++++++++++++++++++++++++++++++++--
1 files changed, 49 insertions(+), 2 deletions(-)
diff --git a/WebService/src/main/java/com/java110/web/components/NavComponent.java b/WebService/src/main/java/com/java110/web/components/NavComponent.java
index e21ca7d..ff4f7cf 100644
--- a/WebService/src/main/java/com/java110/web/components/NavComponent.java
+++ b/WebService/src/main/java/com/java110/web/components/NavComponent.java
@@ -2,6 +2,9 @@
import com.alibaba.fastjson.JSONArray;
import com.alibaba.fastjson.JSONObject;
+import com.java110.core.context.IPageData;
+import com.java110.web.smo.INavServiceSMO;
+import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.http.HttpStatus;
import org.springframework.http.ResponseEntity;
import org.springframework.stereotype.Component;
@@ -14,10 +17,12 @@
@Component("nav")
public class NavComponent {
+ @Autowired
+ private INavServiceSMO navServiceSMOImpl;
- public ResponseEntity<String> getNavData(String param){
+ public ResponseEntity<String> getNavData(IPageData pd){
- String result = "{'welcomeText':'娆㈣繋璁块棶HC灏忓尯绠$悊绯荤粺锛屽鏂囷紒','noticeSize':10," +
+ String result = "{'noticeSize':10," +
"'moreNoticeUrl':'/moreNotice','notices':[" +
"{'msg':'鏂扮郴缁熷紑鍙戞祴璇�','date':'2019-03-19'}," +
"{'msg':'鏉冮檺妫�鏌ユ祴璇�','date':'2019-03-21'}," +
@@ -28,4 +33,46 @@
return new ResponseEntity<String>(nav.toJSONString(), HttpStatus.OK);
}
+
+
+ /**
+ * 閫�鍑虹櫥褰�
+ * @param pd
+ * @return
+ */
+ public ResponseEntity<String> logout(IPageData pd){
+ ResponseEntity<String> responseEntity = null;
+ try{
+ responseEntity = navServiceSMOImpl.doExit(pd);
+ }catch (Exception e){
+ responseEntity = new ResponseEntity<String>(e.getMessage(), HttpStatus.INTERNAL_SERVER_ERROR);
+ }finally {
+ return responseEntity;
+ }
+ }
+
+ /**
+ * 鑾峰彇鐢ㄦ埛淇℃伅
+ * @param pd
+ * @return
+ */
+ public ResponseEntity<String> getUserInfo(IPageData pd){
+ ResponseEntity<String> responseEntity = null;
+ try{
+ responseEntity = navServiceSMOImpl.getUserInfo(pd);
+ }catch (Exception e){
+ responseEntity = new ResponseEntity<String>(e.getMessage(), HttpStatus.INTERNAL_SERVER_ERROR);
+ }finally {
+ return responseEntity;
+ }
+ }
+
+
+ public INavServiceSMO getNavServiceSMOImpl() {
+ return navServiceSMOImpl;
+ }
+
+ public void setNavServiceSMOImpl(INavServiceSMO navServiceSMOImpl) {
+ this.navServiceSMOImpl = navServiceSMOImpl;
+ }
}
--
Gitblit v1.8.0