|
|
@@ -22,6 +22,7 @@ import org.springframework.web.bind.annotation.*;
|
|
|
|
|
|
import javax.servlet.http.HttpServletRequest;
|
|
|
import java.util.List;
|
|
|
+import java.util.Optional;
|
|
|
|
|
|
/**
|
|
|
* server/投诉建议
|
|
|
@@ -126,5 +127,21 @@ public class UserSuggestController {
|
|
|
userSuggestService.recommendGoods(userRecommendGoodsRecord);
|
|
|
return GatewayResponse.SUCCESS.newBuilder().toResult();
|
|
|
}
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 标记留意已读
|
|
|
+ */
|
|
|
+ @PutMapping("/update/status/{feedBackId}")
|
|
|
+ public Result<String> updateFeedBackStatus(@PathVariable Long feedBackId) {
|
|
|
+ long userId = StpUserUtil.getLoginIdAsLong();
|
|
|
+ List<Long> userIdList = userBindRelationService.getRelationUserIdList(userId, null);
|
|
|
+ Optional.ofNullable(userFeedbackRecordMapper.selectById(feedBackId)).ifPresent(fe->{
|
|
|
+ if (userIdList.contains(fe.getUserId())) {
|
|
|
+ fe.setIsNewReply(false);
|
|
|
+ userFeedbackRecordMapper.updateById(fe);
|
|
|
+ }
|
|
|
+ });
|
|
|
+ return GatewayResponse.SUCCESS.newBuilder().toResult();
|
|
|
+ }
|
|
|
}
|
|
|
|