Skip to content

Commit 29af850

Browse files
committed
revert(system/notice): 暂时移除修改公告删除已读通知
1 parent 35cd63e commit 29af850

File tree

3 files changed

+1
-23
lines changed

3 files changed

+1
-23
lines changed

continew-system/src/main/java/top/continew/admin/system/controller/NoticeController.java

Lines changed: 1 addition & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -17,11 +17,8 @@
1717
package top.continew.admin.system.controller;
1818

1919
import cn.hutool.core.collection.CollUtil;
20-
import io.swagger.v3.oas.annotations.Parameter;
21-
import io.swagger.v3.oas.annotations.enums.ParameterIn;
2220
import io.swagger.v3.oas.annotations.tags.Tag;
23-
import org.springframework.validation.annotation.Validated;
24-
import org.springframework.web.bind.annotation.*;
21+
import org.springframework.web.bind.annotation.RestController;
2522
import top.continew.admin.common.controller.BaseController;
2623
import top.continew.admin.system.enums.NoticeMethodEnum;
2724
import top.continew.admin.system.enums.NoticeScopeEnum;
@@ -34,7 +31,6 @@
3431
import top.continew.starter.extension.crud.annotation.CrudApi;
3532
import top.continew.starter.extension.crud.annotation.CrudRequestMapping;
3633
import top.continew.starter.extension.crud.enums.Api;
37-
import top.continew.starter.extension.crud.validation.CrudValidationGroup;
3834

3935
import java.lang.reflect.Method;
4036
import java.util.Arrays;
@@ -73,13 +69,4 @@ public void preHandle(CrudApi crudApi, Object[] args, Method targetMethod, Class
7369
.contains(method), "通知方式 [{}] 不正确", method));
7470
}
7571
}
76-
@Parameter(name = "id", description = "ID", example = "1", in = ParameterIn.PATH)
77-
@ResponseBody
78-
@PutMapping({"/{id}"})
79-
public void update(@Validated({CrudValidationGroup.Update.class}) @RequestBody NoticeReq req,
80-
@PathVariable("id") Long id) {
81-
//更新公告并删除阅读记录
82-
this.baseService.update(req, id);
83-
this.baseService.deleteReadLog(List.of(id));
84-
}
8572
}

continew-system/src/main/java/top/continew/admin/system/service/NoticeService.java

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -66,9 +66,4 @@ public interface NoticeService extends BaseService<NoticeResp, NoticeDetailResp,
6666
* @return 仪表盘公告列表
6767
*/
6868
List<DashboardNoticeResp> listDashboard();
69-
/**
70-
* 删除阅读记录
71-
*
72-
*/
73-
void deleteReadLog(List<Long> ids);
7469
}

continew-system/src/main/java/top/continew/admin/system/service/impl/NoticeServiceImpl.java

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -182,8 +182,4 @@ public List<DashboardNoticeResp> listDashboard() {
182182
Long userId = UserContextHolder.getUserId();
183183
return baseMapper.selectDashboardList(userId);
184184
}
185-
@Override
186-
public void deleteReadLog(List<Long> ids) {
187-
noticeLogService.deleteByNoticeIds(ids);
188-
}
189185
}

0 commit comments

Comments
 (0)