From e033f8a6f821cdb06bbf17e5f10da2d8a8d7297e Mon Sep 17 00:00:00 2001 From: wzy <wzy19931122ai@163.com> Date: Tue, 17 May 2022 21:45:39 +0800 Subject: [PATCH] fix score orderList and flowList and editor --- src/main/java/cc/mrbird/febs/mall/controller/ViewScoreController.java | 31 +++++++++++++++++++++++++++++++ 1 files changed, 31 insertions(+), 0 deletions(-) diff --git a/src/main/java/cc/mrbird/febs/mall/controller/ViewScoreController.java b/src/main/java/cc/mrbird/febs/mall/controller/ViewScoreController.java index 579ac3e..dd05b26 100644 --- a/src/main/java/cc/mrbird/febs/mall/controller/ViewScoreController.java +++ b/src/main/java/cc/mrbird/febs/mall/controller/ViewScoreController.java @@ -5,14 +5,20 @@ import cc.mrbird.febs.common.utils.FebsUtil; import cc.mrbird.febs.mall.dto.ScoreSettingDto; import cc.mrbird.febs.mall.entity.DataDictionaryCustom; +import cc.mrbird.febs.mall.entity.MallGoods; import cc.mrbird.febs.mall.mapper.DataDictionaryCustomMapper; +import cc.mrbird.febs.mall.mapper.MallGoodsImagesMapper; +import cc.mrbird.febs.mall.service.impl.AdminMallGoodsService; import com.alibaba.fastjson.JSONObject; import lombok.RequiredArgsConstructor; import org.apache.shiro.authz.annotation.RequiresPermissions; import org.springframework.stereotype.Controller; import org.springframework.ui.Model; import org.springframework.web.bind.annotation.GetMapping; +import org.springframework.web.bind.annotation.PathVariable; import org.springframework.web.bind.annotation.RequestMapping; + +import java.util.List; @Controller("scoreView") @RequestMapping(FebsConstant.VIEW_PREFIX + "modules/score") @@ -20,6 +26,8 @@ public class ViewScoreController { private final DataDictionaryCustomMapper dataDictionaryCustomMapper; + private final AdminMallGoodsService mallGoodsService; + private final MallGoodsImagesMapper mallGoodsImagesMapper; @GetMapping("setting") // @RequiresPermissions("orderList:view") @@ -40,4 +48,27 @@ public String goodsAdd() { return FebsUtil.view("modules/score/goodsAdd"); } + + @GetMapping("goods/update/{id}") + public String goodsUpdate(@PathVariable("id") Long id, Model model) { + MallGoods mallGoods = mallGoodsService.selectGoodsById(id); + + List<String> images = mallGoodsImagesMapper.selectByGoodId(mallGoods.getId()); + mallGoods.setImages(images); + + model.addAttribute("scoreGoods", mallGoods); + return FebsUtil.view("modules/score/goodsUpdate"); + } + + @GetMapping(value = "/order/list") + @RequiresPermissions("score:order:list") + public String orderList() { + return FebsUtil.view("modules/score/orderList"); + } + + @GetMapping(value = "/flow/list") + @RequiresPermissions("score:flow:view") + public String scoreFlow() { + return FebsUtil.view("modules/score/moneyFlowList"); + } } -- Gitblit v1.9.1