|
@@ -2,7 +2,10 @@ package com.jpsoft.smart.modules.mobile.controller;
|
|
|
|
|
|
import com.github.pagehelper.Page;
|
|
import com.github.pagehelper.Page;
|
|
import com.jpsoft.smart.modules.base.entity.MessageNotice;
|
|
import com.jpsoft.smart.modules.base.entity.MessageNotice;
|
|
|
|
+import com.jpsoft.smart.modules.base.entity.MessageNoticeCompany;
|
|
|
|
+import com.jpsoft.smart.modules.base.entity.PersonInfo;
|
|
import com.jpsoft.smart.modules.base.service.MessageNoticeService;
|
|
import com.jpsoft.smart.modules.base.service.MessageNoticeService;
|
|
|
|
+import com.jpsoft.smart.modules.base.service.PersonInfoService;
|
|
import com.jpsoft.smart.modules.common.dto.MessageResult;
|
|
import com.jpsoft.smart.modules.common.dto.MessageResult;
|
|
import com.jpsoft.smart.modules.common.dto.Sort;
|
|
import com.jpsoft.smart.modules.common.dto.Sort;
|
|
import com.jpsoft.smart.modules.common.utils.PojoUtils;
|
|
import com.jpsoft.smart.modules.common.utils.PojoUtils;
|
|
@@ -26,6 +29,8 @@ public class MessageNoticeApiController {
|
|
|
|
|
|
@Autowired
|
|
@Autowired
|
|
private MessageNoticeService messageNoticeService;
|
|
private MessageNoticeService messageNoticeService;
|
|
|
|
+ @Autowired
|
|
|
|
+ private PersonInfoService personInfoService;
|
|
|
|
|
|
@ApiOperation(value="获取信息")
|
|
@ApiOperation(value="获取信息")
|
|
@RequestMapping(value = "detail",method = RequestMethod.POST)
|
|
@RequestMapping(value = "detail",method = RequestMethod.POST)
|
|
@@ -91,6 +96,7 @@ public class MessageNoticeApiController {
|
|
@ApiOperation(value="列表")
|
|
@ApiOperation(value="列表")
|
|
@RequestMapping(value = "pageListShort",method = RequestMethod.POST)
|
|
@RequestMapping(value = "pageListShort",method = RequestMethod.POST)
|
|
public MessageResult<Map> pageListShort(
|
|
public MessageResult<Map> pageListShort(
|
|
|
|
+ String openId,
|
|
String token,
|
|
String token,
|
|
@RequestParam(value="pageIndex",defaultValue="1") int pageIndex,
|
|
@RequestParam(value="pageIndex",defaultValue="1") int pageIndex,
|
|
@RequestParam(value="pageSize",defaultValue="20") int pageSize,
|
|
@RequestParam(value="pageSize",defaultValue="20") int pageSize,
|
|
@@ -98,10 +104,12 @@ public class MessageNoticeApiController {
|
|
|
|
|
|
//当前用户ID
|
|
//当前用户ID
|
|
System.out.println(subject);
|
|
System.out.println(subject);
|
|
|
|
+ PersonInfo personInfo = personInfoService.findByOpenId(openId);
|
|
|
|
|
|
MessageResult<Map> msgResult = new MessageResult<>();
|
|
MessageResult<Map> msgResult = new MessageResult<>();
|
|
|
|
|
|
Map<String,Object> searchParams = new HashMap<>();
|
|
Map<String,Object> searchParams = new HashMap<>();
|
|
|
|
+ searchParams.put("companyId", personInfo.getCompanyId());
|
|
|
|
|
|
List<Sort> sortList = new ArrayList<>();
|
|
List<Sort> sortList = new ArrayList<>();
|
|
sortList.add(new Sort("create_time","desc"));
|
|
sortList.add(new Sort("create_time","desc"));
|