From 3c1126fbff1aaed94a2e16c2ef98a03e36bf49f1 Mon Sep 17 00:00:00 2001
From: Administrator <admin>
Date: Fri, 06 May 2022 12:01:13 +0800
Subject: [PATCH] 心理咨询,业主反馈修改,bean copy 修改
---
src/main/java/org/springblade/modules/social/controller/SocialController.java | 30 ++++++++++++++++++++++++++++--
1 files changed, 28 insertions(+), 2 deletions(-)
diff --git a/src/main/java/org/springblade/modules/social/controller/SocialController.java b/src/main/java/org/springblade/modules/social/controller/SocialController.java
index 806b5ba..5506733 100644
--- a/src/main/java/org/springblade/modules/social/controller/SocialController.java
+++ b/src/main/java/org/springblade/modules/social/controller/SocialController.java
@@ -38,6 +38,7 @@
import org.springblade.modules.social.service.ISocialService;
import org.springblade.modules.social.vo.SocialVO;
import org.springblade.modules.system.excel.UserExcel;
+import org.springblade.modules.system.service.MyAsyncService;
import org.springframework.web.bind.annotation.*;
import org.springframework.web.multipart.MultipartFile;
@@ -63,6 +64,8 @@
public class SocialController extends BladeController {
private final ISocialService socialService;
+
+ private final MyAsyncService myAsyncService;
/**
* 详情
@@ -104,8 +107,31 @@
@ApiOperationSupport(order = 4)
@ApiOperation(value = "新增", notes = "传入social")
public R save(@Valid @RequestBody Social social) {
- socialService.upSoil(social.getCardid());
- return R.status(socialService.save(social));
+ //修改为已参保
+ socialService.upSoil(social.getNamb());
+ //新增社保记录
+ boolean save = socialService.save(social);
+ if (save){
+ //内网同步
+ String s = "insert into sys_socil(" +
+ "id,namb,sex,nation,telephone,cardid,residence,address," +
+ "nature,amount,insuredtime,deptid) " +
+ "values(" + "'" + social.getId() + "'" + "," +
+ "'" + social.getNamb() + "'" + "," +
+ "'" + social.getSex() + "'" + "," +
+ "'" + social.getNation() + "'" + "," +
+ "'" + social.getTelephone() + "'" + "," +
+ "'" + social.getCardid() + "'" + "," +
+ "'" + social.getResidence() + "'" + "," +
+ "'" + social.getAddress() + "'" + "," +
+ "'" + social.getNature() + "'" + "," +
+ "'" + social.getAmount() + "'" + "," +
+ "," + "'" + new SimpleDateFormat("yyyy-MM-dd").format(social.getInsuredtime()) + "'" +
+ "," + "'" + social.getDeptid() + "'"
+ + ")";
+ myAsyncService.FTP(s);
+ }
+ return R.status(save);
}
/**
--
Gitblit v1.9.3