ruoyi-api/ruoyi-api-system/src/main/java/com/ruoyi/system/api/feignClient/SysConfigClient.java
@@ -7,6 +7,7 @@ import org.springframework.cloud.openfeign.FeignClient; import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.PathVariable; import org.springframework.web.bind.annotation.PostMapping; import org.springframework.web.bind.annotation.RequestBody; @@ -19,7 +20,6 @@ @GetMapping(value = "config/{configId}") R<SysConfig> getInfo(@PathVariable("configId") Long configId); @GetMapping(value = "config/update") @PostMapping(value = "config/update") void update(@RequestBody SysConfig data1); } ruoyi-modules/ruoyi-system/src/main/java/com/ruoyi/system/controller/SysConfigController.java
@@ -38,7 +38,7 @@ return getDataTable(list); } @GetMapping("/update") @PostMapping("/update") public void update (@RequestBody SysConfig data1) { configService.updateConfig(data1); ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/controller/TIntegralController.java
@@ -513,13 +513,13 @@ Long userid = tokenService.getLoginUser().getUserid(); SysUser data = sysUserClient.getSysUser(userid).getData(); if (data != null && data.getSiteId() != null) { if (data != null ) { if (data.getRoleType() == 1) { // 平台 SysConfig data1 = sysConfigClient.getInfo(8L).getData(); sysConfigClient.update(data1); TIntegralRule tIntegralRule = new TIntegralRule(); tIntegralRule.setChargeCredit(data1.getConfigValue()); tIntegralRule.setChargeCredit("{\"num1\":"+data1.getConfigValue()+"}"); tIntegralRule.setContent(data1.getRemark()); tIntegralRule.setSiteId(0); return R.ok(tIntegralRule); @@ -550,7 +550,9 @@ if (data.getRoleType() == 1) { SysConfig data1 = sysConfigClient.getInfo(8L).getData(); data1.setConfigValue(dto.getChargeCredit()); JSONObject jsonObject = JSONObject.parseObject(dto.getChargeCredit()); Integer num1 = jsonObject.getInteger("num1"); data1.setConfigValue(num1.toString()); data1.setRemark(dto.getContent()); sysConfigClient.update(data1); } else {