新版仿ok交易所-后端
1
zj
19 hours ago 640ccb9229224642515527daf87f308a7aa9bdf4
trading-order-admin/src/main/java/com/yami/trading/admin/controller/cms/BannerController.java
@@ -67,10 +67,10 @@
        model.setLoginSafeword(passwordManager.decryptPassword(model.getLoginSafeword()));
        SysUser sysUser = sysUserService.getSysUserById(SecurityUtils.getSysUser().getUserId());
        if (!passwordEncoder.matches(model.getLoginSafeword(), sysUser.getSafePassword())) {
            throw new YamiShopBindException("资金密码不正确!");
            throw new YamiShopBindException("Incorrect fund password!");
        }
        if (StrUtil.isEmpty(model.getImage())){
            throw new YamiShopBindException("展示图片不能为空");
            throw new YamiShopBindException("Display image cannot be empty");
        }
        Banner banner = new Banner();
        banner.setContentCode(model.getContentCode());
@@ -91,14 +91,14 @@
        model.setLoginSafeword(passwordManager.decryptPassword(model.getLoginSafeword()));
        SysUser sysUser = sysUserService.getSysUserById(SecurityUtils.getSysUser().getUserId());
        if (!passwordEncoder.matches(model.getLoginSafeword(), sysUser.getSafePassword())) {
            throw new YamiShopBindException("资金密码不正确!");
            throw new YamiShopBindException("Incorrect fund password!");
        }
        if (StrUtil.isEmpty(model.getImage())){
            throw new YamiShopBindException("展示图片不能为空");
            throw new YamiShopBindException("Display image cannot be empty");
        }
        Banner banner = bannerService.getById(model.getId());
        if (banner == null) {
            throw new YamiShopBindException("参数错误!");
            throw new YamiShopBindException("Invalid parameters!");
        }
        banner.setContentCode(model.getContentCode());
        banner.setImage(model.getImage());