新版仿ok交易所-后端
1
zj
5 days ago 3d8c9b6f4455b4efd34812c8e66073bebfacfce7
trading-order-admin/src/main/java/com/yami/trading/admin/controller/cms/BannerController.java
@@ -64,11 +64,6 @@
    @ApiOperation(value = "新增")
    @PostMapping("add")
    public Result<?> add(@RequestBody @Valid BannerModel model) {
        model.setLoginSafeword(passwordManager.decryptPassword(model.getLoginSafeword()));
        SysUser sysUser = sysUserService.getSysUserById(SecurityUtils.getSysUser().getUserId());
        if (!passwordEncoder.matches(model.getLoginSafeword(), sysUser.getSafePassword())) {
            throw new YamiShopBindException("资金密码不正确!");
        }
        if (StrUtil.isEmpty(model.getImage())){
            throw new YamiShopBindException("展示图片不能为空");
        }
@@ -88,11 +83,6 @@
    @ApiOperation(value = "更新")
    @PostMapping("update")
    public Result<?> update(@RequestBody @Valid BannerModel model) {
        model.setLoginSafeword(passwordManager.decryptPassword(model.getLoginSafeword()));
        SysUser sysUser = sysUserService.getSysUserById(SecurityUtils.getSysUser().getUserId());
        if (!passwordEncoder.matches(model.getLoginSafeword(), sysUser.getSafePassword())) {
            throw new YamiShopBindException("资金密码不正确!");
        }
        if (StrUtil.isEmpty(model.getImage())){
            throw new YamiShopBindException("展示图片不能为空");
        }