| | |
| | | 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") |
| | |
| | | public class ViewScoreController { |
| | | |
| | | private final DataDictionaryCustomMapper dataDictionaryCustomMapper; |
| | | private final AdminMallGoodsService mallGoodsService; |
| | | private final MallGoodsImagesMapper mallGoodsImagesMapper; |
| | | |
| | | @GetMapping("setting") |
| | | // @RequiresPermissions("orderList:view") |
| | |
| | | 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"); |
| | | } |
| | | } |