From c1e48a47b39dbd6919bfd9cf2e7023e9f3d6fee8 Mon Sep 17 00:00:00 2001
From: 101captain <237651143@qq.com>
Date: 星期五, 05 十一月 2021 10:24:21 +0800
Subject: [PATCH] 1105测试代码修改

---
 springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/service/impl/SysConfServiceImpl.java |   21 +++++++++++++++++++++
 1 files changed, 21 insertions(+), 0 deletions(-)

diff --git a/springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/service/impl/SysConfServiceImpl.java b/springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/service/impl/SysConfServiceImpl.java
index 24fd362..0404aaf 100644
--- a/springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/service/impl/SysConfServiceImpl.java
+++ b/springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/service/impl/SysConfServiceImpl.java
@@ -1,5 +1,7 @@
 package com.panzhihua.service_community.service.impl;
 
+import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
+import com.panzhihua.common.constants.NeighborCircleConstants;
 import org.springframework.stereotype.Service;
 
 import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
@@ -53,4 +55,23 @@
         }
     }
 
+    @Override
+    public R editSysConfValue(Long communityId, Integer status){
+        String key = NeighborCircleConstants.NEIGHBOR_CIRCLE_AUTO_EXAMINE;
+
+        SysConfDO confDO = this.baseMapper.selectOne(new QueryWrapper<SysConfDO>().lambda().eq(SysConfDO::getCommunityId,communityId)
+                .eq(SysConfDO::getCode,key + communityId));
+        if(confDO == null){
+            return R.fail("未查询到该系统配置");
+        }
+        confDO.setCommunityId(communityId);
+        confDO.setCode(key + communityId);
+        confDO.setValue(status+"");
+        if(this.baseMapper.updateById(confDO) > 0){
+            return R.ok(confDO.getValue());
+        }else{
+            return R.fail();
+        }
+    }
+
 }

--
Gitblit v1.7.1