Commit 3b82404e by qwmqiuwenmin

fix

parent 360c7373
...@@ -30,13 +30,13 @@ public class AuthRequestUtil { ...@@ -30,13 +30,13 @@ public class AuthRequestUtil {
public static final String REDIS_FAKE_LOGIN_FLAG_PREFIX = "GIC:HAOBAN:HAOBAN_MOBILE_APP:FAKE_LOGIN_TOKEN:"; public static final String REDIS_FAKE_LOGIN_FLAG_PREFIX = "GIC:HAOBAN:HAOBAN_MOBILE_APP:FAKE_LOGIN_TOKEN:";
public static String LOGIN_SESSION_KEY = "HAOBAN:LOGINUSER"; public static String LOGIN_SESSION_KEY = "HAOBAN:LOGINUSER";
public static LoginVO getSessionUser() { // public static LoginVO getSessionUser() {
String json = (String) getSession().getAttribute(LOGIN_SESSION_KEY); // String json = (String) getSession().getAttribute(LOGIN_SESSION_KEY);
if (StringUtils.isBlank(json)){ // if (StringUtils.isBlank(json)){
return null; // return null;
} // }
return JSON.parseObject(json, LoginVO.class); // return JSON.parseObject(json, LoginVO.class);
} // }
public static void setSessionUser(Object obj) { public static void setSessionUser(Object obj) {
String userJson = JSON.toJSONString(obj); String userJson = JSON.toJSONString(obj);
......
...@@ -234,7 +234,7 @@ public class DepartmentContoller extends WebBaseController{ ...@@ -234,7 +234,7 @@ public class DepartmentContoller extends WebBaseController{
@RequestMapping("department-recycle-count") @RequestMapping("department-recycle-count")
public HaobanResponse departmentRecycleCount() { public HaobanResponse departmentRecycleCount() {
LoginVO login = (LoginVO) AuthRequestUtil.getSessionUser(); LoginVO login = (LoginVO) AuthRequestUtil.getLoginUser();
String wxEnterpriseId = login.getWxEnterpriseId(); String wxEnterpriseId = login.getWxEnterpriseId();
Integer count = departmentApiService.departmentRecycleCount(wxEnterpriseId); Integer count = departmentApiService.departmentRecycleCount(wxEnterpriseId);
Map<String,Object> map = new HashMap<String, Object>(); Map<String,Object> map = new HashMap<String, Object>();
...@@ -270,7 +270,7 @@ public class DepartmentContoller extends WebBaseController{ ...@@ -270,7 +270,7 @@ public class DepartmentContoller extends WebBaseController{
@RequestMapping("department-batch-sync") @RequestMapping("department-batch-sync")
@ResponseBody @ResponseBody
public HaobanResponse departmentBatchSync(@RequestBody SyncDepartmentQO args) { public HaobanResponse departmentBatchSync(@RequestBody SyncDepartmentQO args) {
LoginVO login = (LoginVO) AuthRequestUtil.getSessionUser(); LoginVO login = (LoginVO) AuthRequestUtil.getLoginUser();
String wxEnterpriseId = login.getWxEnterpriseId(); String wxEnterpriseId = login.getWxEnterpriseId();
String key = "haoban-sync-department-" + wxEnterpriseId; String key = "haoban-sync-department-" + wxEnterpriseId;
if(RedisUtil.getCache(key) != null){ if(RedisUtil.getCache(key) != null){
...@@ -597,7 +597,7 @@ public class DepartmentContoller extends WebBaseController{ ...@@ -597,7 +597,7 @@ public class DepartmentContoller extends WebBaseController{
@RequestMapping("department-recycle-list") @RequestMapping("department-recycle-list")
public HaobanResponse departmentRecycleList(String keyWord,Integer storeFlag,BasePageInfo pageInfo) { public HaobanResponse departmentRecycleList(String keyWord,Integer storeFlag,BasePageInfo pageInfo) {
LoginVO login = (LoginVO) AuthRequestUtil.getSessionUser(); LoginVO login = (LoginVO) AuthRequestUtil.getLoginUser();
String wxEnterpriseId = login.getWxEnterpriseId(); String wxEnterpriseId = login.getWxEnterpriseId();
Integer recycleFlag = 1; Integer recycleFlag = 1;
Page<DepartmentDTO> page = departmentApiService.pageDepartmentByParams(pageInfo,wxEnterpriseId,keyWord,storeFlag,recycleFlag); Page<DepartmentDTO> page = departmentApiService.pageDepartmentByParams(pageInfo,wxEnterpriseId,keyWord,storeFlag,recycleFlag);
......
...@@ -157,7 +157,7 @@ public class SyncDealContoller extends WebBaseController { ...@@ -157,7 +157,7 @@ public class SyncDealContoller extends WebBaseController {
@ResponseBody @ResponseBody
public HaobanResponse syncTask(String wxEnterpriseId, BasePageInfo pageInfo) { public HaobanResponse syncTask(String wxEnterpriseId, BasePageInfo pageInfo) {
if (StringUtils.isBlank(wxEnterpriseId)) { if (StringUtils.isBlank(wxEnterpriseId)) {
LoginVO login = (LoginVO) AuthRequestUtil.getSessionUser(); LoginVO login = (LoginVO) AuthRequestUtil.getLoginUser();
wxEnterpriseId = login.getWxEnterpriseId(); wxEnterpriseId = login.getWxEnterpriseId();
} }
Page<SyncTaskDTO> retPage = dealSyncOperationApiService.listSyncTask(wxEnterpriseId, pageInfo); Page<SyncTaskDTO> retPage = dealSyncOperationApiService.listSyncTask(wxEnterpriseId, pageInfo);
...@@ -176,7 +176,7 @@ public class SyncDealContoller extends WebBaseController { ...@@ -176,7 +176,7 @@ public class SyncDealContoller extends WebBaseController {
@ResponseBody @ResponseBody
public HaobanResponse syncTaskDetail(String wxEnterpriseId, String taskId, BasePageInfo pageInfo) { public HaobanResponse syncTaskDetail(String wxEnterpriseId, String taskId, BasePageInfo pageInfo) {
if (StringUtils.isBlank(wxEnterpriseId)) { if (StringUtils.isBlank(wxEnterpriseId)) {
LoginVO login = (LoginVO) AuthRequestUtil.getSessionUser(); LoginVO login = (LoginVO) AuthRequestUtil.getLoginUser();
wxEnterpriseId = login.getWxEnterpriseId(); wxEnterpriseId = login.getWxEnterpriseId();
} }
Page<PreDealLogInfoDTO> retPage = dealSyncOperationApiService.listSyncTaskDetail(wxEnterpriseId, taskId, pageInfo); Page<PreDealLogInfoDTO> retPage = dealSyncOperationApiService.listSyncTaskDetail(wxEnterpriseId, taskId, pageInfo);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment