From a499e5a737991461554805af6b72fba65a680776 Mon Sep 17 00:00:00 2001
From: qirong <2032486488@qq.com>
Date: 星期五, 07 四月 2023 11:53:41 +0800
Subject: [PATCH] 更改环境
---
ycl-platform/src/main/java/com/ycl/controller/NewsChannelController.java | 22 ++++++++++------------
1 files changed, 10 insertions(+), 12 deletions(-)
diff --git a/ycl-platform/src/main/java/com/ycl/controller/NewsChannelController.java b/ycl-platform/src/main/java/com/ycl/controller/NewsChannelController.java
index 070ef4e..fc86ef8 100644
--- a/ycl-platform/src/main/java/com/ycl/controller/NewsChannelController.java
+++ b/ycl-platform/src/main/java/com/ycl/controller/NewsChannelController.java
@@ -35,8 +35,6 @@
@Resource
private NewsChannelService newsChannelService;
- @Autowired
- private NewsChannelColumnService newsChannelColumnService;
/**
* 鍒嗛〉鏌ヨ鎵�鏈夋暟鎹�
@@ -55,11 +53,11 @@
* @param id 涓婚敭
* @return 鍗曟潯鏁版嵁
*/
- @GetMapping("{id}")
- @ApiOperation(value = "鎸塱d鏌ヨ鏁版嵁")
- public R selectOne(@PathVariable Serializable id) {
- return success(this.newsChannelService.getById(id));
- }
+// @GetMapping("{id}")
+// @ApiOperation(value = "鎸塱d鏌ヨ鏁版嵁")
+// public R selectOne(@PathVariable Serializable id) {
+// return success(this.newsChannelService.getById(id));
+// }
/**
* 鏂板鏁版嵁
@@ -71,8 +69,8 @@
@ApiOperation(value = "鏂板鏁版嵁")
public R insert(@RequestBody NewsChannel newsChannel) {
int result = this.newsChannelService.insertOneChannel(newsChannel);
- List<String> columnId = newsChannel.getColumnId();
- columnId.stream().forEach(item->newsChannelColumnService.save(NewsChannelColumn.builder().channelId(newsChannel.getId()).columnId(Integer.parseInt(item)).build()));
+// List<String> columnId = newsChannel.getColumnId();
+// columnId.stream().forEach(item->newsChannelColumnService.save(NewsChannelColumn.builder().channelId(newsChannel.getId()).columnId(Integer.parseInt(item)).build()));
return success(result);
}
@@ -85,9 +83,9 @@
@PutMapping
@ApiOperation(value = "淇敼鏁版嵁")
public R update(@RequestBody NewsChannel newsChannel) {
- List<String> columnId = newsChannel.getColumnId();
- newsChannelColumnService.remove(new QueryWrapper<NewsChannelColumn>().eq("channel_id",newsChannel.getId()));
- columnId.stream().forEach(item->newsChannelColumnService.save(NewsChannelColumn.builder().channelId(newsChannel.getId()).columnId(Integer.parseInt(item)).build()));
+// List<String> columnId = newsChannel.getColumnId();
+// newsChannelColumnService.remove(new QueryWrapper<NewsChannelColumn>().eq("channel_id",newsChannel.getId()));
+// columnId.stream().forEach(item->newsChannelColumnService.save(NewsChannelColumn.builder().channelId(newsChannel.getId()).columnId(Integer.parseInt(item)).build()));
return success(this.newsChannelService.updateById(newsChannel));
}
--
Gitblit v1.8.0