|
|
@ -18,6 +18,7 @@ |
|
|
|
package com.epmet.modules.notice.controller; |
|
|
|
|
|
|
|
import com.epmet.commons.tools.annotation.LoginUser; |
|
|
|
import com.epmet.commons.tools.exception.RenException; |
|
|
|
import com.epmet.commons.tools.security.dto.TokenDto; |
|
|
|
import com.epmet.commons.tools.utils.Result; |
|
|
|
import com.epmet.commons.tools.validator.ValidatorUtils; |
|
|
@ -66,11 +67,15 @@ public class NoticeReadRecordController { |
|
|
|
* @return |
|
|
|
* @Author sun |
|
|
|
* @Description 小组通知阅读状态修改 |
|
|
|
* 只给居民端使用 |
|
|
|
**/ |
|
|
|
@PostMapping(value = "readtype") |
|
|
|
public Result readType(@LoginUser TokenDto tokenDto, @RequestBody ReadTypeFormDTO formDTO){ |
|
|
|
ValidatorUtils.validateEntity(formDTO, ReadTypeFormDTO.Read.class); |
|
|
|
formDTO.setUserId(tokenDto.getUserId()); |
|
|
|
if(!"resi".equals(tokenDto.getApp())){ |
|
|
|
throw new RenException(String.format("接口仅用于居民端使用,请检查用户是否为居民端用户,userId->", formDTO.getUserId())); |
|
|
|
} |
|
|
|
noticeReafdRecordService.readType(formDTO); |
|
|
|
return new Result(); |
|
|
|
} |
|
|
|