From 876e250c27eeca4df0c13c3d222103afd9e06b7e Mon Sep 17 00:00:00 2001 From: Helius <wangdoubleone@gmail.com> Date: Thu, 04 Aug 2022 16:07:04 +0800 Subject: [PATCH] fix --- src/main/java/com/xcong/farmer/cms/modules/core/controller/CmsCoreController.java | 19 ++++++++++++------- 1 files changed, 12 insertions(+), 7 deletions(-) diff --git a/src/main/java/com/xcong/farmer/cms/modules/core/controller/CmsCoreController.java b/src/main/java/com/xcong/farmer/cms/modules/core/controller/CmsCoreController.java index 8c5ae0f..7b46150 100644 --- a/src/main/java/com/xcong/farmer/cms/modules/core/controller/CmsCoreController.java +++ b/src/main/java/com/xcong/farmer/cms/modules/core/controller/CmsCoreController.java @@ -4,6 +4,7 @@ import com.xcong.farmer.cms.modules.core.service.ICmsCoreService; import com.xcong.farmer.cms.modules.system.service.IArticleService; import com.xcong.farmer.cms.modules.system.service.IReleaseService; +import com.xcong.farmer.cms.modules.system.util.LoginUserUtil; import io.swagger.annotations.Api; import io.swagger.annotations.ApiOperation; import lombok.extern.slf4j.Slf4j; @@ -27,25 +28,29 @@ @ApiOperation(value = "发布文章", notes = "发布文章") @PostMapping(value = "releaseArticle/{id}") public Result releaseArticle(@PathVariable("id") Long id) { - releaseService.releaseArticle(id); +// Long companyId = LoginUserUtil.getCompanyId(); + Long companyId = 24L; + releaseService.releaseArticle(id, companyId); return Result.ok("success"); } @ApiOperation(value = "发布栏目", notes = "发布栏目") @PostMapping(value = "releaseColumn/{type}/{id}") public Result releaseColumn(@PathVariable("id") Long id, @PathVariable("type") Integer type) { - boolean article = false; - if (type == 1) { - article = true; - } - releaseService.releaseColumn(id, article); +// Long companyId = LoginUserUtil.getCompanyId(); + Long companyId = 24L; + releaseService.releaseColumn(id, type, companyId); return Result.ok("success"); } @ApiOperation(value = "发布首页", notes = "发布首页") @PostMapping(value = "/releaseIndex") public Result releaseIndex() { - releaseService.releaseIndex(); +// Long companyId = LoginUserUtil.getCompanyId(); + Long companyId = 24L; + releaseService.releaseIndex(companyId, true); return Result.ok("success"); } + + } -- Gitblit v1.9.1