Commit 0118f33d authored by fangxinjiang's avatar fangxinjiang

Merge remote-tracking branch 'origin/MVP1.7.19' into MVP1.7.19

parents d870b874 06398a3f
...@@ -33,8 +33,8 @@ spec: # 资源规范字段 ...@@ -33,8 +33,8 @@ spec: # 资源规范字段
#dapr.io/sidecar-memory-limit: "800Mi" #Dapr sidecar可以使用的最大内存量。默认情况下未设置 请参阅 https://kubernetes.io/docs/tasks/administer-cluster/manage-resources/quota-memory-cpu-namespace/ 的有效值。 #dapr.io/sidecar-memory-limit: "800Mi" #Dapr sidecar可以使用的最大内存量。默认情况下未设置 请参阅 https://kubernetes.io/docs/tasks/administer-cluster/manage-resources/quota-memory-cpu-namespace/ 的有效值。
#dapr.io/sidecar-cpu-request: 1 #Dapr sidecar要求的 CPU 数量 #dapr.io/sidecar-cpu-request: 1 #Dapr sidecar要求的 CPU 数量
#dapr.io/sidecar-memory-request #Dapr sidecar 请求的内存数量 #dapr.io/sidecar-memory-request #Dapr sidecar 请求的内存数量
dapr.io/app-max-request-size: "600" # 明确指定应用请求大小 dapr.io/app-max-request-size: "800" # 明确指定应用请求大小
dapr.io/http-max-request-size: "600" #增加http和grpc服务器请求正文参数的最大大小,单位为MB,以处理大文件的上传。 默认值为 4 MB dapr.io/http-max-request-size: "800" #增加http和grpc服务器请求正文参数的最大大小,单位为MB,以处理大文件的上传。 默认值为 4 MB
dapr.io/http-read-buffer-size: "4096" #Dapr has a default limit of 4KB for the http header read buffer size. When sending http headers that are bigger than the default 4KB, you can increase this value. Otherwise, you may encounter a Too big request header dapr.io/http-read-buffer-size: "4096" #Dapr has a default limit of 4KB for the http header read buffer size. When sending http headers that are bigger than the default 4KB, you can increase this value. Otherwise, you may encounter a Too big request header
dapr.io/sidecar-listen-addresses: "0.0.0.0" dapr.io/sidecar-listen-addresses: "0.0.0.0"
# 更多dapr配置请参考 https://www.bookstack.cn/read/dapr-1.5-zh/cc77b74e2cc2f4d4.md # 更多dapr配置请参考 https://www.bookstack.cn/read/dapr-1.5-zh/cc77b74e2cc2f4d4.md
...@@ -64,7 +64,7 @@ spec: # 资源规范字段 ...@@ -64,7 +64,7 @@ spec: # 资源规范字段
#cpu: 300m # CPU,1核心 = 1000m #cpu: 300m # CPU,1核心 = 1000m
requests: # 容器运行时,最低资源需求,也就是说最少需要多少资源容器才能正常运行 requests: # 容器运行时,最低资源需求,也就是说最少需要多少资源容器才能正常运行
#cpu: 100m #cpu: 100m
memory: "500Mi" memory: "800Mi"
#livenessProbe: # pod 内部健康检查的设置 #livenessProbe: # pod 内部健康检查的设置
# httpGet: # 通过httpget检查健康,返回200-399之间,则认为容器正常 # httpGet: # 通过httpget检查健康,返回200-399之间,则认为容器正常
# path: /healthCheck # URI地址 # path: /healthCheck # URI地址
......
...@@ -34,9 +34,9 @@ spring: ...@@ -34,9 +34,9 @@ spring:
servlet: servlet:
multipart: multipart:
#所有上传文件最大大小 #所有上传文件最大大小
max-request-size: 600MB max-request-size: 800MB
#单个文件最大大小 #单个文件最大大小
max-file-size: 600MB max-file-size: 800MB
#swagger 文档 https://springdoc.org/ #swagger 文档 https://springdoc.org/
### OpenAPI3 注解 ### OpenAPI3 注解
# OpenAPI 3 注解位置 # OpenAPI 3 注解位置
......
...@@ -249,6 +249,9 @@ ...@@ -249,6 +249,9 @@
#{idStr} #{idStr}
</foreach> </foreach>
</if> </if>
<if test="employeeRegistrationLeave.customerUsernameNew != null and employeeRegistrationLeave.customerUsernameNew.trim() != ''">
AND a.customer_username_new like CONCAT('%',#{employeeRegistrationLeave.customerUsernameNew},'%')
</if>
<if test="employeeRegistrationLeave.employeeName != null and employeeRegistrationLeave.employeeName.trim() != ''"> <if test="employeeRegistrationLeave.employeeName != null and employeeRegistrationLeave.employeeName.trim() != ''">
AND b.employee_name like CONCAT('%',#{employeeRegistrationLeave.employeeName},'%') AND b.employee_name like CONCAT('%',#{employeeRegistrationLeave.employeeName},'%')
</if> </if>
......
...@@ -437,6 +437,16 @@ public class SysHouseHoldInfo extends BaseEntity { ...@@ -437,6 +437,16 @@ public class SysHouseHoldInfo extends BaseEntity {
@ExcelProperty("医保推送类型") @ExcelProperty("医保推送类型")
private String isSingleYsdPush; private String isSingleYsdPush;
/**
* 推送时,医保完成后才推送社保,默认0否
*/
@ExcelAttribute(name = "根据医保结果办理养工失" )
@Schema(description ="根据医保结果办理养工失")
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty("根据医保结果办理养工失")
private String isYsdOkPushYgs;
/** /**
* 户与失败原因关联list * 户与失败原因关联list
*/ */
......
...@@ -72,5 +72,14 @@ public class TSocialFreindPushAndGet { ...@@ -72,5 +72,14 @@ public class TSocialFreindPushAndGet {
@ExcelProperty("创建人姓名") @ExcelProperty("创建人姓名")
@Schema(description = "创建人姓名") @Schema(description = "创建人姓名")
private String createUserName; private String createUserName;
/**
* 创建人ID
*/
@ExcelAttribute(name = "创建人ID", isNotEmpty = true, errorInfo = "创建人ID不能为空", maxLength = 64)
@NotBlank(message = "创建人ID不能为空")
@Length(max = 64, message = "创建人ID不能超过64个字符")
@ExcelProperty("创建人ID")
@Schema(description = "创建人ID")
private String createBy;
} }
...@@ -93,5 +93,13 @@ public class TSocialFriendReduceSet { ...@@ -93,5 +93,13 @@ public class TSocialFriendReduceSet {
@ExcelProperty("类型") @ExcelProperty("类型")
@Schema(description = "类型1:社保;2:医保;3池州特殊减员映射") @Schema(description = "类型1:社保;2:医保;3池州特殊减员映射")
private String mvpType; private String mvpType;
/**
* 户名称(可以为空)
*/
@ExcelAttribute(name = "户名称", maxLength = 50)
@Length(max = 50, message = "户名称")
@ExcelProperty("户名称")
@Schema(description = "户名称")
private String huName;
} }
...@@ -233,6 +233,22 @@ public class TDispatchInfoController { ...@@ -233,6 +233,22 @@ public class TDispatchInfoController {
return new R<>(tDispatchInfoService.getTSocialSoldierHandlePage(page,tDispatchInfo)); return new R<>(tDispatchInfoService.getTSocialSoldierHandlePage(page,tDispatchInfo));
} }
/**
* @Description: 获取税友自动化办理推送的条数,限制【社保办理权限】菜单的办理人权限
* @Author: hgw
* @Date: 2026-01-21 09点16分
* @return: com.yifu.cloud.plus.v1.yifu.common.core.util.R<com.baomidou.mybatisplus.core.metadata.IPage < com.yifu.cloud.plus.v1.yifu.social.entity.TDispatchInfo>>
**/
@Operation(description = "获取税友自动化办理推送的条数,限制【社保办理权限】菜单的办理人权限")
@GetMapping("/countSocialFriendByAuth")
public R<Long> countSocialFriendByAuth() {
YifuUser user = SecurityUtils.getUser();
if (user == null || Common.isEmpty(user.getId())) {
return R.failed("请登录!");
}
return new R<>(tDispatchInfoService.countSocialFriendByAuth(user.getId()));
}
/** /**
* @Description: 简单分页查询--自动化办理查询 * @Description: 简单分页查询--自动化办理查询
* @Author: hgw * @Author: hgw
......
...@@ -84,7 +84,7 @@ public class TSocialFriendController { ...@@ -84,7 +84,7 @@ public class TSocialFriendController {
@SysLog("1定时任务推送税友") @SysLog("1定时任务推送税友")
@Inner @Inner
public R<String> doPushFriendTest() { public R<String> doPushFriendTest() {
return tSocialFriendPushService.pushFriend(null); return tSocialFriendPushService.pushFriend(null, null, CommonConstants.ONE_INT, null);
} }
@Operation(description = "2定时任务获取税友") @Operation(description = "2定时任务获取税友")
...@@ -102,12 +102,12 @@ public class TSocialFriendController { ...@@ -102,12 +102,12 @@ public class TSocialFriendController {
* @return: com.yifu.cloud.plus.v1.yifu.common.core.util.R<java.lang.String> * @return: com.yifu.cloud.plus.v1.yifu.common.core.util.R<java.lang.String>
**/ **/
@Operation(description = "主动推送税友") @Operation(description = "主动推送税友")
@GetMapping("/doPushFriendByActive") @PostMapping("/doPushFriendByActive")
@SysLog("主动推送税友") @SysLog("主动推送税友")
public R<String> doPushFriendActive() { public R<String> doPushFriendActive(@RequestBody List<String> dispatchIdList) {
if (atomicPush.incrementAndGet() <= 1) { if (atomicPush.incrementAndGet() <= 1) {
try { try {
R<String> failed = getCore(CommonConstants.ONE_INT); R<String> failed = getCore(CommonConstants.ONE_INT, dispatchIdList);
if (failed != null) return failed; if (failed != null) return failed;
} finally { } finally {
atomicPush.decrementAndGet(); atomicPush.decrementAndGet();
...@@ -126,7 +126,7 @@ public class TSocialFriendController { ...@@ -126,7 +126,7 @@ public class TSocialFriendController {
* @Date: 2025/3/18 17:27 * @Date: 2025/3/18 17:27
* @return: com.yifu.cloud.plus.v1.yifu.common.core.util.R<java.lang.String> * @return: com.yifu.cloud.plus.v1.yifu.common.core.util.R<java.lang.String>
**/ **/
private R<String> getCore(int type) { private R<String> getCore(int type, List<String> dispatchIdList) {
YifuUser user = SecurityUtils.getUser(); YifuUser user = SecurityUtils.getUser();
if (user == null || Common.isEmpty(user.getNickname())) { if (user == null || Common.isEmpty(user.getNickname())) {
return R.failed("请先登录!"); return R.failed("请先登录!");
...@@ -136,16 +136,18 @@ public class TSocialFriendController { ...@@ -136,16 +136,18 @@ public class TSocialFriendController {
LocalDateTime now = LocalDateTime.now(); LocalDateTime now = LocalDateTime.now();
// 计算10分钟前的时间 // 计算10分钟前的时间
LocalDateTime tenMinutesAgo = now.minusMinutes(10); LocalDateTime tenMinutesAgo = now.minusMinutes(10);
LocalDateTime time = tSocialFreindPushAndGetService.getMaxTimeByType(type); LocalDateTime time = tSocialFreindPushAndGetService.getMaxTimeByType(type, user.getId());
if (Common.isEmpty(time) || time.isBefore(tenMinutesAgo)) { if (Common.isEmpty(time) || time.isBefore(tenMinutesAgo)) {
TSocialFreindPushAndGet info = new TSocialFreindPushAndGet(); TSocialFreindPushAndGet info = new TSocialFreindPushAndGet();
info.setType(type); info.setType(type);
info.setCreateTime(now); info.setCreateTime(now);
info.setCreateUserName(user.getNickname()); info.setCreateUserName(user.getNickname());
info.setCreateBy(user.getId());
tSocialFreindPushAndGetService.save(info); tSocialFreindPushAndGetService.save(info);
if (type == CommonConstants.ONE_INT) { if (type == CommonConstants.ONE_INT) {
// isAuto 参数:是否自动,自动要查户配置。手动可推送养工失。 手动的都推送(大部分都是推送,芜湖要先推送医保办理成功后才推送社保)
//doJointFriendTask.pushFriendByAsync() //doJointFriendTask.pushFriendByAsync()
tSocialFriendPushService.pushFriend(null); tSocialFriendPushService.pushFriend(null, dispatchIdList, CommonConstants.ZERO_INT, user.getId());
} else { } else {
//doJointFriendTask.getInfoByRequestIdByAsync() //doJointFriendTask.getInfoByRequestIdByAsync()
tSocialFriendService.getInfoByRequestId(); tSocialFriendService.getInfoByRequestId();
...@@ -174,7 +176,7 @@ public class TSocialFriendController { ...@@ -174,7 +176,7 @@ public class TSocialFriendController {
public R<String> doGetFriendByActive() { public R<String> doGetFriendByActive() {
if (atomicGet.incrementAndGet() <= 1) { if (atomicGet.incrementAndGet() <= 1) {
try { try {
R<String> failed = getCore(CommonConstants.TWO_INT); R<String> failed = getCore(CommonConstants.TWO_INT, null);
if (failed != null) return failed; if (failed != null) return failed;
} finally { } finally {
atomicGet.decrementAndGet(); atomicGet.decrementAndGet();
......
...@@ -125,6 +125,12 @@ public interface TDispatchInfoMapper extends BaseMapper<TDispatchInfo> { ...@@ -125,6 +125,12 @@ public interface TDispatchInfoMapper extends BaseMapper<TDispatchInfo> {
IPage<TSocialSoldierPageVo> getTSocialSoldierHandlePage(Page<TSocialSoldierPageVo> page, IPage<TSocialSoldierPageVo> getTSocialSoldierHandlePage(Page<TSocialSoldierPageVo> page,
@Param("tDispatchInfo") SocialHandleSearchVo tDispatchInfo, @Param("tDispatchInfo") SocialHandleSearchVo tDispatchInfo,
@Param("idsStr") List<String> idsStr); @Param("idsStr") List<String> idsStr);
/**
* @Description: 获取税友自动化办理推送的条数,限制【社保办理权限】菜单的办理人权限
* @Author: hgw
* @Date: 2026/1/21
**/
Long countSocialFriendByAuth(@Param("userId") String userId);
/** /**
* @Description: 社保士兵列表查询 * @Description: 社保士兵列表查询
......
...@@ -39,5 +39,5 @@ public interface TSocialFreindPushAndGetMapper extends BaseMapper<TSocialFreindP ...@@ -39,5 +39,5 @@ public interface TSocialFreindPushAndGetMapper extends BaseMapper<TSocialFreindP
* @Date: 2025/3/18 15:57 * @Date: 2025/3/18 15:57
* @return: java.time.LocalDateTime * @return: java.time.LocalDateTime
**/ **/
LocalDateTime getMaxTimeByType(@Param("type") Integer type); LocalDateTime getMaxTimeByType(@Param("type") Integer type, @Param("createUserId") String createUserId);
} }
...@@ -39,7 +39,8 @@ public interface TSocialFriendMapper extends BaseMapper<TSocialInfo> { ...@@ -39,7 +39,8 @@ public interface TSocialFriendMapper extends BaseMapper<TSocialInfo> {
* @Author hgw * @Author hgw
* @Date 2024-5-10 21:16:41 * @Date 2024-5-10 21:16:41
**/ **/
List<SociaFriendYgsAddVo> getSocialSoldierYgsAddVoList(@Param("idsStr") List<String> idsStr); List<SociaFriendYgsAddVo> getSocialSoldierYgsAddVoList(@Param("idsStr") List<String> idsStr, @Param("pushIdsStr") List<String> pushIdsStr
, @Param("isAuto") Integer isAuto, @Param("userId") String userId);
/** /**
* 社保士兵养工失减少模板 * 社保士兵养工失减少模板
...@@ -47,7 +48,8 @@ public interface TSocialFriendMapper extends BaseMapper<TSocialInfo> { ...@@ -47,7 +48,8 @@ public interface TSocialFriendMapper extends BaseMapper<TSocialInfo> {
* @Author hgw * @Author hgw
* @Date 2024-5-10 21:16:41 * @Date 2024-5-10 21:16:41
**/ **/
List<SociaFriendYgsAddVo> getSocialSoldierYgsReduceVoList(@Param("idsStr") List<String> idsStr); List<SociaFriendYgsAddVo> getSocialSoldierYgsReduceVoList(@Param("idsStr") List<String> idsStr, @Param("pushIdsStr") List<String> pushIdsStr
, @Param("isAuto") Integer isAuto, @Param("userId") String userId);
/** /**
* 社保士兵医生大增加模板 * 社保士兵医生大增加模板
...@@ -55,7 +57,8 @@ public interface TSocialFriendMapper extends BaseMapper<TSocialInfo> { ...@@ -55,7 +57,8 @@ public interface TSocialFriendMapper extends BaseMapper<TSocialInfo> {
* @Author hgw * @Author hgw
* @Date 2024-5-10 21:16:41 * @Date 2024-5-10 21:16:41
**/ **/
List<SociaFriendYgsAddVo> getSocialSoldierYsdAddVoList(@Param("idsStr") List<String> idsStr); List<SociaFriendYgsAddVo> getSocialSoldierYsdAddVoList(@Param("idsStr") List<String> idsStr, @Param("pushIdsStr") List<String> pushIdsStr
, @Param("isAuto") Integer isAuto, @Param("userId") String userId);
/** /**
* 社保士兵医生大减少模板 * 社保士兵医生大减少模板
...@@ -63,7 +66,8 @@ public interface TSocialFriendMapper extends BaseMapper<TSocialInfo> { ...@@ -63,7 +66,8 @@ public interface TSocialFriendMapper extends BaseMapper<TSocialInfo> {
* @Author hgw * @Author hgw
* @Date 2024-5-10 21:16:41 * @Date 2024-5-10 21:16:41
**/ **/
List<SociaFriendYgsAddVo> getSocialSoldierYsdReduceVoList(@Param("idsStr") List<String> idsStr); List<SociaFriendYgsAddVo> getSocialSoldierYsdReduceVoList(@Param("idsStr") List<String> idsStr, @Param("pushIdsStr") List<String> pushIdsStr
, @Param("isAuto") Integer isAuto, @Param("userId") String userId);
......
...@@ -120,6 +120,12 @@ public interface TDispatchInfoService extends IService<TDispatchInfo> { ...@@ -120,6 +120,12 @@ public interface TDispatchInfoService extends IService<TDispatchInfo> {
**/ **/
IPage<TSocialSoldierPageVo> getTSocialSoldierHandlePage(Page<TSocialSoldierPageVo> page, SocialHandleSearchVo tDispatchInfo); IPage<TSocialSoldierPageVo> getTSocialSoldierHandlePage(Page<TSocialSoldierPageVo> page, SocialHandleSearchVo tDispatchInfo);
/**
* 获取税友自动化办理推送的条数,限制【社保办理权限】菜单的办理人权限
* @param userId
*/
Long countSocialFriendByAuth(String userId);
/** /**
* @param page * @param page
* @param tDispatchInfo * @param tDispatchInfo
......
...@@ -37,5 +37,5 @@ public interface TSocialFreindPushAndGetService extends IService<TSocialFreindPu ...@@ -37,5 +37,5 @@ public interface TSocialFreindPushAndGetService extends IService<TSocialFreindPu
* @Date: 2025/3/18 15:57 * @Date: 2025/3/18 15:57
* @return: java.time.LocalDateTime * @return: java.time.LocalDateTime
**/ **/
LocalDateTime getMaxTimeByType(Integer type); LocalDateTime getMaxTimeByType(Integer type, String createUserId);
} }
...@@ -33,13 +33,15 @@ import java.util.List; ...@@ -33,13 +33,15 @@ import java.util.List;
public interface TSocialFriendPushService extends IService<TSocialInfo> { public interface TSocialFriendPushService extends IService<TSocialInfo> {
/** /**
* @param isAuto 1是,0否。是否自动,自动要查户配置。手动可推送养工失。
* 手动的都推送(大部分都是推送,芜湖要先推送医保办理成功后才推送社保)
* @param dispatchIdList * @param dispatchIdList
* @Description: 根据派单id,获取要派增派减的社保、医保数据,生成文件,推送到社保士兵 * @Description: 根据派单id,获取要派增派减的社保、医保数据,生成文件,推送到社保士兵
* @Author: hgw * @Author: hgw
* @Date: 2024/5/10 17:52 * @Date: 2024/5/10 17:52
* @return: com.yifu.cloud.plus.v1.yifu.common.core.util.R<java.lang.String> * @return: com.yifu.cloud.plus.v1.yifu.common.core.util.R<java.lang.String>
**/ **/
R<String> pushFriend(List<String> dispatchIdList); R<String> pushFriend(List<String> dispatchIdList, List<String> pushDispatchIdList, Integer isAuto, String userId);
R<String> doExportRoster(String socialId, String type, String unitCreditCode, List<SociaFriendYgsAddVo> listVo); R<String> doExportRoster(String socialId, String type, String unitCreditCode, List<SociaFriendYgsAddVo> listVo);
......
...@@ -6208,6 +6208,15 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T ...@@ -6208,6 +6208,15 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
return baseMapper.getTSocialSoldierHandlePage(page, tDispatchInfo, null); return baseMapper.getTSocialSoldierHandlePage(page, tDispatchInfo, null);
} }
/**
* 获取税友自动化办理推送的条数,限制【社保办理权限】菜单的办理人权限
* @param userId
*/
@Override
public Long countSocialFriendByAuth(String userId) {
return baseMapper.countSocialFriendByAuth(userId);
}
@Override @Override
public IPage<TSocialSoldierPageVo> getPageSocialSoldierAll(Page<TSocialSoldierPageVo> page, SocialHandleSearchVo tDispatchInfo) { public IPage<TSocialSoldierPageVo> getPageSocialSoldierAll(Page<TSocialSoldierPageVo> page, SocialHandleSearchVo tDispatchInfo) {
return baseMapper.getPageSocialSoldierAll(page, tDispatchInfo, null); return baseMapper.getPageSocialSoldierAll(page, tDispatchInfo, null);
......
...@@ -43,8 +43,8 @@ public class TSocialFreindPushAndGetServiceImpl extends ServiceImpl<TSocialFrein ...@@ -43,8 +43,8 @@ public class TSocialFreindPushAndGetServiceImpl extends ServiceImpl<TSocialFrein
* @return: java.time.LocalDateTime * @return: java.time.LocalDateTime
**/ **/
@Override @Override
public LocalDateTime getMaxTimeByType(Integer type) { public LocalDateTime getMaxTimeByType(Integer type, String createUserId) {
return baseMapper.getMaxTimeByType(type); return baseMapper.getMaxTimeByType(type, createUserId);
} }
} }
...@@ -103,14 +103,19 @@ public class TSocialFriendPushServiceImpl extends ServiceImpl<TSocialFriendMappe ...@@ -103,14 +103,19 @@ public class TSocialFriendPushServiceImpl extends ServiceImpl<TSocialFriendMappe
private TDispatchInfoMapper dispatchInfoMapper; private TDispatchInfoMapper dispatchInfoMapper;
private final static String AND_STR = "&"; private final static String AND_STR = "&";
/** /**
* @param isAuto 1是,0否。是否自动推送的,自动要查户配置。手动可推送养工失。
* 手动的都推送(大部分都是推送,芜湖要先推送医保办理成功后才推送社保)
* @param dispatchIdList 审核后推送的派单ID
* @param pushDispatchIdList 手动推送的派单ID(这里不限制单个推送类型的)
* @Description: 推送到税友 * @Description: 推送到税友
* @Author: hgw * @Author: hgw
* @Date: 2024-12-12 10:03:59 * @Date: 2024-12-12 10:03:59
* @return: com.yifu.cloud.plus.v1.yifu.common.core.util.R<java.lang.String> * @return: com.yifu.cloud.plus.v1.yifu.common.core.util.R<java.lang.String>
**/ **/
@Override @Override
public R<String> pushFriend(List<String> dispatchIdList) { public R<String> pushFriend(List<String> dispatchIdList, List<String> pushDispatchIdList, Integer isAuto, String userId) {
if (atomicPushFriend.incrementAndGet() <= 1) { if (atomicPushFriend.incrementAndGet() <= 1) {
try { try {
TSocialFreindSet set = tSocialFreindSetService.getById("1"); TSocialFreindSet set = tSocialFreindSetService.getById("1");
...@@ -150,25 +155,27 @@ public class TSocialFriendPushServiceImpl extends ServiceImpl<TSocialFriendMappe ...@@ -150,25 +155,27 @@ public class TSocialFriendPushServiceImpl extends ServiceImpl<TSocialFriendMappe
if (Common.isNotNull(templateSrc)) { if (Common.isNotNull(templateSrc)) {
templateUrl = ossUtil.getObjectUrl(null, templateSrc); templateUrl = ossUtil.getObjectUrl(null, templateSrc);
} }
// 社保增员、社保减员、医保增员、医保减员 // 社保增员、社保减员、医保增员、医保减员
// 养工失新增列表 // 养工失新增列表
List<SociaFriendYgsAddVo> ygsAddlist = baseMapper.getSocialSoldierYgsAddVoList(dispatchIdList); List<SociaFriendYgsAddVo> ygsAddlist = baseMapper.getSocialSoldierYgsAddVoList(dispatchIdList, pushDispatchIdList, isAuto, userId);
if (ygsAddlist != null && !ygsAddlist.isEmpty()) { if (ygsAddlist != null && !ygsAddlist.isEmpty()) {
this.doPushSocialAndLogYgs(socialSetMap, ygsAddlist, 1, reduceYgsMap, zhangMap, templateUrl, templateSrcMap, reduceChiZhouMap); this.doPushSocialAndLogYgs(socialSetMap, ygsAddlist, 1, reduceYgsMap, zhangMap, templateUrl, templateSrcMap, reduceChiZhouMap);
} }
// 养工失减少列表 // 养工失减少列表
List<SociaFriendYgsAddVo> ygsReducelist = baseMapper.getSocialSoldierYgsReduceVoList(dispatchIdList); List<SociaFriendYgsAddVo> ygsReducelist = baseMapper.getSocialSoldierYgsReduceVoList(dispatchIdList, pushDispatchIdList, isAuto, userId);
if (ygsReducelist != null && !ygsReducelist.isEmpty()) { if (ygsReducelist != null && !ygsReducelist.isEmpty()) {
this.doPushSocialAndLogYgs(socialSetMap, ygsReducelist, 2, reduceYgsMap, zhangMap, templateUrl, templateSrcMap, reduceChiZhouMap); this.doPushSocialAndLogYgs(socialSetMap, ygsReducelist, 2, reduceYgsMap, zhangMap, templateUrl, templateSrcMap, reduceChiZhouMap);
} }
// 医生大新增列表 // 医生大新增列表
List<SociaFriendYgsAddVo> ysdAddlist = baseMapper.getSocialSoldierYsdAddVoList(dispatchIdList); List<SociaFriendYgsAddVo> ysdAddlist = baseMapper.getSocialSoldierYsdAddVoList(dispatchIdList,pushDispatchIdList, isAuto, userId);
if (ysdAddlist != null && !ysdAddlist.isEmpty()) { if (ysdAddlist != null && !ysdAddlist.isEmpty()) {
this.doPushSocialAndLogYsd(socialSetMap, ysdAddlist, 3, reduceYsdMap, zhangMap, templateUrl, templateSrcMap, reduceChiZhouMap); this.doPushSocialAndLogYsd(socialSetMap, ysdAddlist, 3, reduceYsdMap, zhangMap, templateUrl, templateSrcMap, reduceChiZhouMap);
} }
// 医生大减少列表 // 医生大减少列表
List<SociaFriendYgsAddVo> ysdReducelist = baseMapper.getSocialSoldierYsdReduceVoList(dispatchIdList); List<SociaFriendYgsAddVo> ysdReducelist = baseMapper.getSocialSoldierYsdReduceVoList(dispatchIdList, pushDispatchIdList, isAuto, userId);
if (ysdReducelist != null && !ysdReducelist.isEmpty()) { if (ysdReducelist != null && !ysdReducelist.isEmpty()) {
this.doPushSocialAndLogYsd(socialSetMap, ysdReducelist, 4, reduceYsdMap, zhangMap, templateUrl, templateSrcMap, reduceChiZhouMap); this.doPushSocialAndLogYsd(socialSetMap, ysdReducelist, 4, reduceYsdMap, zhangMap, templateUrl, templateSrcMap, reduceChiZhouMap);
} }
...@@ -243,7 +250,10 @@ public class TSocialFriendPushServiceImpl extends ServiceImpl<TSocialFriendMappe ...@@ -243,7 +250,10 @@ public class TSocialFriendPushServiceImpl extends ServiceImpl<TSocialFriendMappe
vo.setChiZhouTbyy(reduceSet.getTbyy()); vo.setChiZhouTbyy(reduceSet.getTbyy());
vo.setChiZhouZzyy(reduceSet.getZzyy()); vo.setChiZhouZzyy(reduceSet.getZzyy());
} }
reduceSet = reduceMap.get(vo.getTbyy()); reduceSet = reduceMap.get(vo.getSocialHouseholdName() + CommonConstants.DOWN_LINE_STRING + vo.getTbyy());
if (reduceSet == null) {
reduceSet = reduceMap.get(vo.getTbyy());
}
if (reduceSet != null) { if (reduceSet != null) {
vo.setTbyy(reduceSet.getTbyy()); vo.setTbyy(reduceSet.getTbyy());
vo.setZzyy(reduceSet.getZzyy()); vo.setZzyy(reduceSet.getZzyy());
...@@ -555,7 +565,10 @@ public class TSocialFriendPushServiceImpl extends ServiceImpl<TSocialFriendMappe ...@@ -555,7 +565,10 @@ public class TSocialFriendPushServiceImpl extends ServiceImpl<TSocialFriendMappe
vo.setChiZhouTbyy(reduceSet.getTbyy()); vo.setChiZhouTbyy(reduceSet.getTbyy());
vo.setChiZhouZzyy(reduceSet.getZzyy()); vo.setChiZhouZzyy(reduceSet.getZzyy());
} }
reduceSet = reduceMap.get(vo.getTbyy()); reduceSet = reduceMap.get(vo.getSocialHouseholdName() + CommonConstants.DOWN_LINE_STRING + vo.getTbyy());
if (reduceSet == null) {
reduceSet = reduceMap.get(vo.getTbyy());
}
if (reduceSet != null) { if (reduceSet != null) {
vo.setTbyy(reduceSet.getTbyy()); vo.setTbyy(reduceSet.getTbyy());
vo.setZzyy(reduceSet.getZzyy()); vo.setZzyy(reduceSet.getZzyy());
......
...@@ -18,6 +18,8 @@ package com.yifu.cloud.plus.v1.yifu.social.service.impl; ...@@ -18,6 +18,8 @@ package com.yifu.cloud.plus.v1.yifu.social.service.impl;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.google.common.collect.Maps; import com.google.common.collect.Maps;
import com.yifu.cloud.plus.v1.yifu.common.core.constant.CommonConstants;
import com.yifu.cloud.plus.v1.yifu.common.core.util.Common;
import com.yifu.cloud.plus.v1.yifu.social.entity.TSocialFriendReduceSet; import com.yifu.cloud.plus.v1.yifu.social.entity.TSocialFriendReduceSet;
import com.yifu.cloud.plus.v1.yifu.social.mapper.TSocialFriendReduceSetMapper; import com.yifu.cloud.plus.v1.yifu.social.mapper.TSocialFriendReduceSetMapper;
import com.yifu.cloud.plus.v1.yifu.social.service.TSocialFriendReduceSetService; import com.yifu.cloud.plus.v1.yifu.social.service.TSocialFriendReduceSetService;
...@@ -44,7 +46,11 @@ public class TSocialFriendReduceSetServiceImpl extends ServiceImpl<TSocialFriend ...@@ -44,7 +46,11 @@ public class TSocialFriendReduceSetServiceImpl extends ServiceImpl<TSocialFriend
if (list != null && !list.isEmpty()) { if (list != null && !list.isEmpty()) {
Map<String, TSocialFriendReduceSet> map = Maps.newHashMap(); Map<String, TSocialFriendReduceSet> map = Maps.newHashMap();
for (TSocialFriendReduceSet reduceSet : list) { for (TSocialFriendReduceSet reduceSet : list) {
map.put(reduceSet.getMvpKey(), reduceSet); if (Common.isEmpty(reduceSet.getHuName())) {
map.put(reduceSet.getMvpKey(), reduceSet);
} else {
map.put(reduceSet.getHuName() + CommonConstants.DOWN_LINE_STRING + reduceSet.getMvpKey(), reduceSet);
}
} }
return map; return map;
} }
......
...@@ -270,7 +270,7 @@ public class DoSocialTask { ...@@ -270,7 +270,7 @@ public class DoSocialTask {
**/ **/
@Async @Async
public void pushFriend(List<String> dispatchIdList) { public void pushFriend(List<String> dispatchIdList) {
tSocialFriendPushService.pushFriend(dispatchIdList); tSocialFriendPushService.pushFriend(dispatchIdList, null, CommonConstants.ONE_INT, null);
} }
@Async @Async
......
...@@ -73,6 +73,8 @@ ...@@ -73,6 +73,8 @@
<result property="ybsfqzcb" column="YBSFQZCB"/> <result property="ybsfqzcb" column="YBSFQZCB"/>
<result property="isSingleYgsPush" column="IS_SINGLE_YGS_PUSH"/> <result property="isSingleYgsPush" column="IS_SINGLE_YGS_PUSH"/>
<result property="isSingleYsdPush" column="IS_SINGLE_YSD_PUSH"/> <result property="isSingleYsdPush" column="IS_SINGLE_YSD_PUSH"/>
<!--MVP1.7.19 2026-01-20是否办理医保完成后才允许推送社保-->
<result property="isYsdOkPushYgs" column="IS_YSD_OK_PUSH_YGS"/>
</resultMap> </resultMap>
<resultMap id="sysHouseHoldSingleInfoMap" type="com.yifu.cloud.plus.v1.yifu.social.entity.SysHouseHoldInfo"> <resultMap id="sysHouseHoldSingleInfoMap" type="com.yifu.cloud.plus.v1.yifu.social.entity.SysHouseHoldInfo">
...@@ -130,6 +132,7 @@ ...@@ -130,6 +132,7 @@
,a.YBSFQZCB ,a.YBSFQZCB
,a.IS_SINGLE_YGS_PUSH ,a.IS_SINGLE_YGS_PUSH
,a.IS_SINGLE_YSD_PUSH ,a.IS_SINGLE_YSD_PUSH
,a.IS_YSD_OK_PUSH_YGS
</sql> </sql>
<sql id="sysHouseHoldInfo_where"> <sql id="sysHouseHoldInfo_where">
...@@ -191,6 +194,9 @@ ...@@ -191,6 +194,9 @@
<if test="sysHouseHoldInfo.isSign != null and sysHouseHoldInfo.isSign.trim() != ''"> <if test="sysHouseHoldInfo.isSign != null and sysHouseHoldInfo.isSign.trim() != ''">
AND a.IS_SIGN = #{sysHouseHoldInfo.isSign} AND a.IS_SIGN = #{sysHouseHoldInfo.isSign}
</if> </if>
<if test="sysHouseHoldInfo.isYsdOkPushYgs != null and sysHouseHoldInfo.isYsdOkPushYgs.trim() != ''">
AND a.IS_YSD_OK_PUSH_YGS = #{sysHouseHoldInfo.isYsdOkPushYgs}
</if>
</if> </if>
</sql> </sql>
<!--sysHouseHoldInfo简单分页查询--> <!--sysHouseHoldInfo简单分页查询-->
......
...@@ -1720,6 +1720,34 @@ ...@@ -1720,6 +1720,34 @@
ORDER BY a.AUDIT_TIME DESC ORDER BY a.AUDIT_TIME DESC
</select> </select>
<!--获取税友自动化办理推送的条数,限制【社保办理权限】菜单的办理人权限-->
<select id="countSocialFriendByAuth" resultType="java.lang.Long">
SELECT
count(1)
FROM t_dispatch_info a
LEFT JOIN t_social_info s ON a.SOCIAL_ID = s.id
LEFT JOIN t_dispatch_social_fund_info h ON a.id = h.REDUCE_SOCIAL_FUND_ID
WHERE a.DELETE_FLAG = '0'
AND a.social_id is not null
and ((a.AUTO_FLAG = '0' and s.YGS_HANDLE_STATUS in ('0','1','3')) or (a.AUTO_FLAG_YSD = '0' and s.YGS_HANDLE_STATUS in ('0','1','3')))
AND NOT EXISTS (
SELECT 1
FROM t_dispatch_info d2
WHERE d2.SOCIAL_ID = a.SOCIAL_ID
AND d2.DELETE_FLAG = '0'
AND d2.social_id is not null
and (d2.AUTO_FLAG = '0' or d2.AUTO_FLAG_YSD = '0')
AND d2.CREATE_TIME > a.CREATE_TIME
)
AND a.STATUS = "2"
and a.SOCIAL_PROVINCE = '12'
and (( a.type = '0' AND (s.HANDLE_STATUS = "0" or s.HANDLE_STATUS = "4") ) or ( a.type ='1' AND (if(ifnull(h.id,0) != '0',h.HANDLE_STATUS,s.HANDLE_STATUS) in ('1','5','6','3','7') or (s.HANDLE_STATUS in ('1','5','6','3','7') and s.REDUCE_CAN = '1')) ))
and a.SOCIAL_HANDLE_STATUS in ('0','4')
and DATE_FORMAT(a.AUDIT_TIME,'%Y%m') = DATE_FORMAT(now(),'%Y%m')
/* 以社保办理权限推送税友,查数量 */
and a.SOCIAL_HOUSEHOLD_NAME in (select SOCIAL_HOUSEHOLD from t_socialfund_house_res where user_id=#{userId} AND STATUS = '0' AND AUTH_TYPE = '1' and HOUSE_NAME_TYPE='0' )
</select>
<!-- hgw 2025-4-25 18:09:12 自动化办理查询——派单维度 --> <!-- hgw 2025-4-25 18:09:12 自动化办理查询——派单维度 -->
<select id="getPageSocialSoldierAll" resultMap="socialSoldierPageMap"> <select id="getPageSocialSoldierAll" resultMap="socialSoldierPageMap">
SELECT SELECT
......
...@@ -56,7 +56,7 @@ ...@@ -56,7 +56,7 @@
SELECT SELECT
max(a.CREATE_TIME) max(a.CREATE_TIME)
FROM t_social_freind_push_and_get a FROM t_social_freind_push_and_get a
where a.TYPE = #{type} where a.TYPE = #{type} and a.create_by = #{createUserId}
</select> </select>
</mapper> </mapper>
...@@ -144,6 +144,16 @@ ...@@ -144,6 +144,16 @@
/*派单推的,有ID,则查单个推送的,立即推*/ /*派单推的,有ID,则查单个推送的,立即推*/
and a.IS_SINGLE = '1' and a.IS_SINGLE = '1'
</if> </if>
<if test="isAuto != null and isAuto == 1">
/*自动推送时,查开关关闭,或者医保完成后才推送社保*/
and (shh.IS_YSD_OK_PUSH_YGS = '0' or s.YSD_HANDLE_STATUS = '6')
</if>
<if test="userId != null and isAuto != null and isAuto == 0 and (pushIdsStr == null or pushIdsStr.size == 0) ">
/* 以社保办理权限推送税友,查数量 */
and a.SOCIAL_HOUSEHOLD_NAME in (select SOCIAL_HOUSEHOLD from t_socialfund_house_res where user_id=#{userId} AND STATUS = '0' AND AUTH_TYPE = '1' and HOUSE_NAME_TYPE='0' )
</if>
and a.AUTO_FLAG = '0' and a.AUTO_FLAG = '0'
and a.type = '0' and s.YGS_HANDLE_STATUS in ('0','1','3') and a.type = '0' and s.YGS_HANDLE_STATUS in ('0','1','3')
and ( and (
...@@ -164,6 +174,12 @@ ...@@ -164,6 +174,12 @@
#{items} #{items}
</foreach> </foreach>
</if> </if>
<if test="pushIdsStr != null and pushIdsStr.size > 0">
AND a.ID in
<foreach item="items" index="index" collection="pushIdsStr" open="(" separator="," close=")">
#{items}
</foreach>
</if>
/** 社保办理状态:0待办理/1已办理2办理失败3已派减4 办理中 5 部分办理失败 派单社保办理状态 0 未办理 1 全部办理成功(原-已办理) 2 全部办理失败(原-办理失败) 3 部分办理成功 4 办理中 **/ /** 社保办理状态:0待办理/1已办理2办理失败3已派减4 办理中 5 部分办理失败 派单社保办理状态 0 未办理 1 全部办理成功(原-已办理) 2 全部办理失败(原-办理失败) 3 部分办理成功 4 办理中 **/
/*社保代办理 1.派单审核通过 2.派增(type=0):待办理(social_handle_status='0') or 派减(type=1):已办理完成或部分办理失败 且已派减*/ /*社保代办理 1.派单审核通过 2.派增(type=0):待办理(social_handle_status='0') or 派减(type=1):已办理完成或部分办理失败 且已派减*/
AND a.social_id is not null AND a.social_id is not null
...@@ -191,6 +207,16 @@ ...@@ -191,6 +207,16 @@
/*派单推的,有ID,则查单个推送的,立即推*/ /*派单推的,有ID,则查单个推送的,立即推*/
and a.IS_SINGLE = '1' and a.IS_SINGLE = '1'
</if> </if>
<if test="isAuto != null and isAuto == 1">
/*自动推送时,查开关关闭,或者医保完成后才推送社保*/
and (shh.IS_YSD_OK_PUSH_YGS = '0' or s.YSD_HANDLE_STATUS = '6')
</if>
<if test="userId != null and isAuto != null and isAuto == 0 and (pushIdsStr == null or pushIdsStr.size == 0) ">
/* 以社保办理权限推送税友,查数量 */
and a.SOCIAL_HOUSEHOLD_NAME in (select SOCIAL_HOUSEHOLD from t_socialfund_house_res where user_id=#{userId} AND STATUS = '0' AND AUTH_TYPE = '1' and HOUSE_NAME_TYPE='0' )
</if>
and a.AUTO_FLAG = '0' and a.AUTO_FLAG = '0'
and a.type = '1' and s.YGS_HANDLE_STATUS in ('0','1','3') and a.type = '1' and s.YGS_HANDLE_STATUS in ('0','1','3')
and ( and (
...@@ -223,6 +249,10 @@ ...@@ -223,6 +249,10 @@
/*派单推的,有ID,则查单个推送的,立即推*/ /*派单推的,有ID,则查单个推送的,立即推*/
and a.IS_SINGLE_YSD = '1' and a.IS_SINGLE_YSD = '1'
</if> </if>
<if test="userId != null and isAuto != null and isAuto == 0 and (pushIdsStr == null or pushIdsStr.size == 0) ">
/* 以社保办理权限推送税友,查数量 */
and a.SOCIAL_HOUSEHOLD_NAME in (select SOCIAL_HOUSEHOLD from t_socialfund_house_res where user_id=#{userId} AND STATUS = '0' AND AUTH_TYPE = '1' and HOUSE_NAME_TYPE='0' )
</if>
and a.AUTO_FLAG_YSD = '0' and a.AUTO_FLAG_YSD = '0'
and a.type = '0' and s.YSD_HANDLE_STATUS in ('0','1','3') and a.type = '0' and s.YSD_HANDLE_STATUS in ('0','1','3')
and ( and (
...@@ -331,6 +361,11 @@ ...@@ -331,6 +361,11 @@
/*派单推的,有ID,则查单个推送的,立即推*/ /*派单推的,有ID,则查单个推送的,立即推*/
and a.IS_SINGLE_YSD = '1' and a.IS_SINGLE_YSD = '1'
</if> </if>
<if test="userId != null and isAuto != null and isAuto == 0 and (pushIdsStr == null or pushIdsStr.size == 0) ">
/* 以社保办理权限推送税友,查数量 */
and a.SOCIAL_HOUSEHOLD_NAME in (select SOCIAL_HOUSEHOLD from t_socialfund_house_res where user_id=#{userId} AND STATUS = '0' AND AUTH_TYPE = '1' and HOUSE_NAME_TYPE='0' )
</if>
and a.AUTO_FLAG_YSD = '0' and a.AUTO_FLAG_YSD = '0'
and a.type = '1' and s.YSD_HANDLE_STATUS in ('0','1','3') and a.type = '1' and s.YSD_HANDLE_STATUS in ('0','1','3')
and ( and (
......
...@@ -31,6 +31,7 @@ ...@@ -31,6 +31,7 @@
<result property="bajcejyy" column="BAJCEJYY"/> <result property="bajcejyy" column="BAJCEJYY"/>
<result property="mvpKey" column="MVP_KEY"/> <result property="mvpKey" column="MVP_KEY"/>
<result property="mvpType" column="MVP_TYPE"/> <result property="mvpType" column="MVP_TYPE"/>
<result property="huName" column="HU_NAME"/>
</resultMap> </resultMap>
<sql id="Base_Column_List"> <sql id="Base_Column_List">
a.ID, a.ID,
...@@ -38,7 +39,8 @@ ...@@ -38,7 +39,8 @@
a.ZZYY, a.ZZYY,
a.BAJCEJYY, a.BAJCEJYY,
a.MVP_KEY, a.MVP_KEY,
a.MVP_TYPE a.MVP_TYPE,
a.HU_NAME
</sql> </sql>
<!--tSocialFriendReduceSet简单分页查询--> <!--tSocialFriendReduceSet简单分页查询-->
<select id="getTSocialFriendReduceSetList" resultMap="tSocialFriendReduceSetMap"> <select id="getTSocialFriendReduceSetList" resultMap="tSocialFriendReduceSetMap">
......
...@@ -104,10 +104,10 @@ ...@@ -104,10 +104,10 @@
<artifactId>spring-boot-starter-undertow</artifactId> <artifactId>spring-boot-starter-undertow</artifactId>
</dependency> </dependency>
<!--单元测试--> <!--单元测试-->
<dependency> <!--<dependency>
<groupId>com.yifu.cloud.plus.v1</groupId> <groupId>com.yifu.cloud.plus.v1</groupId>
<artifactId>yifu-common-test</artifactId> <artifactId>yifu-common-test</artifactId>
</dependency> </dependency>-->
</dependencies> </dependencies>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment