Commit c1d9620f authored by huyuchen's avatar huyuchen

huych-户配置调整

parent c7754985
...@@ -85,69 +85,37 @@ public class TSocialDeadlineInfo extends BaseEntity { ...@@ -85,69 +85,37 @@ public class TSocialDeadlineInfo extends BaseEntity {
@TableField(updateStrategy = FieldStrategy.IGNORED) @TableField(updateStrategy = FieldStrategy.IGNORED)
private String town; private String town;
/** /**
* 社保增员起始日期 * 社保(增员)起始日
*/ */
@ExcelAttribute(name = "社保增员起始日期", isNotEmpty = true, errorInfo = "社保增员起始日期不能为空", isDate = true) @ExcelAttribute(name = "社保起始日", isNotEmpty = true, errorInfo = "社保起始日不能为空", isDate = true)
@NotBlank(message = "社保增员起始日期不能为空") @NotBlank(message = "社保起始日不能为空")
@ExcelProperty("社保增员起始日期") @ExcelProperty("社保起始日")
@Schema(description = "社保增员起始日期") @Schema(description = "社保起始日")
private Date socialStartDate; private Date socialStartDate;
/** /**
* 社保增员截止日期 * 社保(增员)截止日
*/ */
@ExcelAttribute(name = "社保增员截止日期", isNotEmpty = true, errorInfo = "社保增员截止日期不能为空", isDate = true) @ExcelAttribute(name = "社保截止日", isNotEmpty = true, errorInfo = "社保截止日不能为空", isDate = true)
@NotBlank(message = "社保增员截止日期不能为空") @NotBlank(message = "社保截止日不能为空")
@ExcelProperty("社保增员截止日期") @ExcelProperty("社保截止日")
@Schema(description = "社保增员截止日期") @Schema(description = "社保截止日")
private Date socialEndDate; private Date socialEndDate;
/** /**
* 社保减员起始日期 * 医疗(增员)起始日
*/
@ExcelAttribute(name = "社保减员起始日期", isNotEmpty = true, errorInfo = "社保减员起始日期不能为空", isDate = true)
@NotBlank(message = "社保减员起始日期不能为空")
@ExcelProperty("社保减员起始日期")
@Schema(description = "社保减员起始日期")
private Date socialStartDateReduce;
/**
* 社保减员截止日期
*/
@ExcelAttribute(name = "社保减员截止日期", isNotEmpty = true, errorInfo = "社保减员截止日期不能为空", isDate = true)
@NotBlank(message = "社保减员截止日期不能为空")
@ExcelProperty("社保减员截止日期")
@Schema(description = "社保减员截止日期")
private Date socialEndDateReduce;
/**
* 医保增员起始日期
*/ */
@ExcelAttribute(name = "医保增员起始日期", isNotEmpty = true, errorInfo = "医保增员起始日期不能为空", isDate = true) @ExcelAttribute(name = "医疗起始日", isNotEmpty = true, errorInfo = "医疗起始日不能为空", isDate = true)
@NotBlank(message = "医保增员起始日期不能为空") @NotBlank(message = "医疗起始日不能为空")
@ExcelProperty("医保增员起始日期") @ExcelProperty("医疗起始日")
@Schema(description = "医保增员起始日期") @Schema(description = "医疗起始日")
private Date medicalStartDate; private Date medicalStartDate;
/** /**
* 医保增员截止日期 * 医疗(增员)截止日
*/ */
@ExcelAttribute(name = "医保增员截止日期", isNotEmpty = true, errorInfo = "医保增员截止日期不能为空", isDate = true) @ExcelAttribute(name = "医疗截止日", isNotEmpty = true, errorInfo = "医疗截止日不能为空", isDate = true)
@NotBlank(message = "医保增员截止日期不能为空") @NotBlank(message = "医疗截止日不能为空")
@ExcelProperty("医保增员截止日期") @ExcelProperty("医疗截止日")
@Schema(description = "医保增员截止日期") @Schema(description = "医疗截止日")
private Date medicalEndDate; private Date medicalEndDate;
/**
* 医保减员起始日期
*/
@ExcelAttribute(name = "医保减员起始日期", isNotEmpty = true, errorInfo = "医保减员起始日期不能为空", isDate = true)
@NotBlank(message = "医保减员起始日期不能为空")
@ExcelProperty("医保减员起始日期")
@Schema(description = "医保减员起始日期")
private Date medicalStartDateReduce;
/**
* 医保减员截止日期
*/
@ExcelAttribute(name = "医保减员截止日期", isNotEmpty = true, errorInfo = "医保减员截止日期不能为空", isDate = true)
@NotBlank(message = "医保减员截止日期不能为空")
@ExcelProperty("医保减员截止日期")
@Schema(description = "医保减员截止日期")
private Date medicalEndDateReduce;
/** /**
* 更新人 * 更新人
*/ */
...@@ -173,4 +141,41 @@ public class TSocialDeadlineInfo extends BaseEntity { ...@@ -173,4 +141,41 @@ public class TSocialDeadlineInfo extends BaseEntity {
@Schema(description = "配置类型:0 非基础配置 1基础配置(后面配置都是按他生成的)") @Schema(description = "配置类型:0 非基础配置 1基础配置(后面配置都是按他生成的)")
private String type; private String type;
/**
* 社保减员起始日期
*/
@ExcelAttribute(name = "社保减员起始日期", isNotEmpty = true, errorInfo = "社保减员起始日期不能为空", isDate = true)
@NotBlank(message = "社保减员起始日期不可为空")
@ExcelProperty("社保减员起始日期")
@Schema(description = "社保减员起始日期")
private Date socialStartDateReduce;
/**
* 医疗减员起始日期
*/
@ExcelAttribute(name = "医疗减员起始日期", isNotEmpty = true, errorInfo = "医疗减员起始日期不能为空", isDate = true)
@NotBlank(message = "医疗减员起始日期不能为空")
@ExcelProperty("医疗减员起始日期")
@Schema(description = "医疗减员起始日期")
private Date medicalStartDateReduce;
/**
* 社保减员截止日期
*/
@ExcelAttribute(name = "社保减员截止日期", isNotEmpty = true, errorInfo = "社保减员截止日期不能为空", isDate = true)
@NotBlank(message = "社保减员截止日期不能为空")
@ExcelProperty("社保减员截止日期")
@Schema(description = "社保减员截止日期")
private Date socialEndDateReduce;
/**
* 医疗减员截止日期
*/
@ExcelAttribute(name = "医疗减员截止日期", isNotEmpty = true, errorInfo = "医疗减员截止日期不能为空", isDate = true)
@NotBlank(message = "医疗减员截止日期不能为空")
@ExcelProperty("医疗减员截止日期")
@Schema(description = "医疗减员截止日期")
private Date medicalEndDateReduce;
} }
...@@ -145,4 +145,12 @@ public class SocialHandleSearchVo extends TDispatchInfo { ...@@ -145,4 +145,12 @@ public class SocialHandleSearchVo extends TDispatchInfo {
@ExcelProperty("医生大反馈" ) @ExcelProperty("医生大反馈" )
@ExcelIgnore @ExcelIgnore
private String ysdRemark; private String ysdRemark;
/**
* 社保ID
*/
@TableField(exist = false)
@Schema(description ="社保ID")
@ExcelIgnore
private String socialId;
} }
<?xml version="1.0"?> <?xml version="1.0"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" <project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 xsi:schemaLocation="http://maven.apache.org/POM/4.0.0
http://maven.apache.org/xsd/maven-4.0.0.xsd"> http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion> <modelVersion>4.0.0</modelVersion>
<parent> <parent>
<groupId>com.yifu.cloud.plus.v1</groupId> <groupId>com.yifu.cloud.plus.v1</groupId>
<artifactId>yifu</artifactId> <artifactId>yifu</artifactId>
<version>1.0.0</version> <version>1.0.0</version>
<relativePath>../../pom.xml</relativePath> <relativePath>../../pom.xml</relativePath>
</parent> </parent>
<artifactId>yifu-social-biz</artifactId> <artifactId>yifu-social-biz</artifactId>
<packaging>jar</packaging> <packaging>jar</packaging>
<description>yifu-social 业务模块</description> <description>yifu-social 业务模块</description>
<dependencies> <dependencies>
<dependency> <dependency>
<groupId>com.yifu.cloud.plus.v1</groupId> <groupId>com.yifu.cloud.plus.v1</groupId>
<artifactId>yifu-social-api</artifactId> <artifactId>yifu-social-api</artifactId>
...@@ -67,18 +67,18 @@ ...@@ -67,18 +67,18 @@
<groupId>org.springframework.boot</groupId> <groupId>org.springframework.boot</groupId>
<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-archives-api</artifactId> <artifactId>yifu-archives-api</artifactId>
<version>1.0.0</version> <version>1.0.0</version>
<scope>compile</scope> <scope>compile</scope>
</dependency> </dependency>
<dependency> <dependency>
<groupId>com.yifu.cloud.plus.v1</groupId> <groupId>com.yifu.cloud.plus.v1</groupId>
<artifactId>yifu-salary-api</artifactId> <artifactId>yifu-salary-api</artifactId>
<version>1.0.0</version> <version>1.0.0</version>
<scope>compile</scope> <scope>compile</scope>
</dependency> </dependency>
<dependency> <dependency>
<groupId>org.apache.shardingsphere</groupId> <groupId>org.apache.shardingsphere</groupId>
<artifactId>shardingsphere-jdbc-core-spring-boot-starter</artifactId> <artifactId>shardingsphere-jdbc-core-spring-boot-starter</artifactId>
...@@ -100,13 +100,28 @@ ...@@ -100,13 +100,28 @@
</dependency> </dependency>
<!-- Apache POI --> <!-- Apache POI -->
<dependency>
<groupId>org.apache.poi</groupId>
<artifactId>poi</artifactId>
<version>5.2.3</version> <!-- 使用最新版本 -->
</dependency>
<dependency>
<groupId>org.apache.poi</groupId>
<artifactId>poi-ooxml</artifactId>
<version>5.2.3</version>
</dependency>
<dependency>
<groupId>commons-io</groupId>
<artifactId>commons-io</artifactId>
<version>2.12.0</version>
</dependency>
<dependency> <dependency>
<groupId>spire.xls</groupId> <groupId>spire.xls</groupId>
<artifactId>spire.xls</artifactId> <artifactId>spire.xls</artifactId>
<version>5.3.0</version> <version>5.3.0</version>
<type>jar</type> <type>jar</type>
</dependency> </dependency>
</dependencies> </dependencies>
<build> <build>
<plugins> <plugins>
......
...@@ -50,6 +50,7 @@ import org.springframework.web.multipart.MultipartFile; ...@@ -50,6 +50,7 @@ import org.springframework.web.multipart.MultipartFile;
import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse; import javax.servlet.http.HttpServletResponse;
import java.net.URL;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.List; import java.util.List;
...@@ -66,21 +67,21 @@ import java.util.List; ...@@ -66,21 +67,21 @@ import java.util.List;
@Tag(name = "派单信息记录表管理") @Tag(name = "派单信息记录表管理")
public class TDispatchInfoController { public class TDispatchInfoController {
private final TDispatchInfoService tDispatchInfoService; private final TDispatchInfoService tDispatchInfoService;
private final MenuUtil menuUtil; private final MenuUtil menuUtil;
private final DaprArchivesProperties daprArchivesProperties; private final DaprArchivesProperties daprArchivesProperties;
/** /**
* 简单分页查询 * 简单分页查询
* @param page 分页对象 * @param page 分页对象
* @param tDispatchInfo 派单信息记录表 * @param tDispatchInfo 派单信息记录表
* @return * @return
*/ */
@Operation(description = "简单分页查询") @Operation(description = "简单分页查询")
@GetMapping("/page") @GetMapping("/page")
public R<IPage<TDispatchInfoPageVo>> getTDispatchInfoPage(Page<TDispatchInfo> page, TDispatchInfoSearchVo tDispatchInfo) { public R<IPage<TDispatchInfoPageVo>> getTDispatchInfoPage(Page<TDispatchInfo> page, TDispatchInfoSearchVo tDispatchInfo) {
tDispatchInfo.setDeleteFlag(CommonConstants.ZERO_STRING); tDispatchInfo.setDeleteFlag(CommonConstants.ZERO_STRING);
YifuUser user = SecurityUtils.getUser(); YifuUser user = SecurityUtils.getUser();
menuUtil.setAuthSql(user, tDispatchInfo); menuUtil.setAuthSql(user, tDispatchInfo);
...@@ -93,21 +94,21 @@ public class TDispatchInfoController { ...@@ -93,21 +94,21 @@ public class TDispatchInfoController {
} }
} }
tDispatchInfo.setCreateBy(user.getId()); tDispatchInfo.setCreateBy(user.getId());
return new R<>(tDispatchInfoService.getTDispatchInfoPageAudit(page,tDispatchInfo)); return new R<>(tDispatchInfoService.getTDispatchInfoPageAudit(page,tDispatchInfo));
} }
/** /**
* 不分页查询 * 不分页查询
* @param tDispatchInfo 派单信息记录表 * @param tDispatchInfo 派单信息记录表
* @return * @return
*/ */
@Operation(summary = "不分页查询", description = "不分页查询") @Operation(summary = "不分页查询", description = "不分页查询")
@PostMapping("/noPage" ) @PostMapping("/noPage" )
//@PreAuthorize("@pms.hasPermission('demo_tdispatchinfo_get')" ) //@PreAuthorize("@pms.hasPermission('demo_tdispatchinfo_get')" )
public R<List<TDispatchInfo>> getTDispatchInfoNoPage(@RequestBody TDispatchInfoSearchVo tDispatchInfo) { public R<List<TDispatchInfo>> getTDispatchInfoNoPage(@RequestBody TDispatchInfoSearchVo tDispatchInfo) {
tDispatchInfo.setDeleteFlag(CommonConstants.ZERO_STRING); tDispatchInfo.setDeleteFlag(CommonConstants.ZERO_STRING);
return R.ok(tDispatchInfoService.noPageDiy(tDispatchInfo)); return R.ok(tDispatchInfoService.noPageDiy(tDispatchInfo));
} }
/** /**
* 简单分页查询--申请 * 简单分页查询--申请
* @param page 分页对象 * @param page 分页对象
...@@ -265,17 +266,17 @@ public class TDispatchInfoController { ...@@ -265,17 +266,17 @@ public class TDispatchInfoController {
tDispatchInfo.setCreateBy(user.getId()); tDispatchInfo.setCreateBy(user.getId());
return new R<>(tDispatchInfoService.getTDispatchFundHandlePage(page,tDispatchInfo)); return new R<>(tDispatchInfoService.getTDispatchFundHandlePage(page,tDispatchInfo));
} }
/** /**
* 通过id查询派单信息记录表 * 通过id查询派单信息记录表
* @param id * @param id
* @return R * @return R
*/ */
@Operation(summary = "通过id查询", description = "通过id查询:hasPermission('demo_tdispatchinfo_get')") @Operation(summary = "通过id查询", description = "通过id查询:hasPermission('demo_tdispatchinfo_get')")
@GetMapping("/{id}" ) @GetMapping("/{id}" )
@PreAuthorize("@pms.hasPermission('demo_tdispatchinfo_get')" ) @PreAuthorize("@pms.hasPermission('demo_tdispatchinfo_get')" )
public R<TDispatchInfo> getById(@PathVariable("id" ) String id) { public R<TDispatchInfo> getById(@PathVariable("id" ) String id) {
return R.ok(tDispatchInfoService.getById(id)); return R.ok(tDispatchInfoService.getById(id));
} }
/** /**
* 通过id查询派单相关系信息 * 通过id查询派单相关系信息
...@@ -291,56 +292,56 @@ public class TDispatchInfoController { ...@@ -291,56 +292,56 @@ public class TDispatchInfoController {
} }
/** /**
* 新增派单信息记录表 * 新增派单信息记录表
* @param tDispatchInfo 派单信息记录表 * @param tDispatchInfo 派单信息记录表
* @return R * @return R
*/ */
@Operation(summary = "新增派单信息记录表", description = "新增派单信息记录表:hasPermission('demo_tdispatchinfo_add')") @Operation(summary = "新增派单信息记录表", description = "新增派单信息记录表:hasPermission('demo_tdispatchinfo_add')")
@SysLog("新增派单信息记录表" ) @SysLog("新增派单信息记录表" )
@PostMapping @PostMapping
@PreAuthorize("@pms.hasPermission('demo_tdispatchinfo_add')" ) @PreAuthorize("@pms.hasPermission('demo_tdispatchinfo_add')" )
public R<Boolean> save(@RequestBody TDispatchInfo tDispatchInfo) { public R<Boolean> save(@RequestBody TDispatchInfo tDispatchInfo) {
return R.ok(tDispatchInfoService.save(tDispatchInfo)); return R.ok(tDispatchInfoService.save(tDispatchInfo));
} }
/** /**
* 修改派单信息记录表 * 修改派单信息记录表
* @param tDispatchInfo 派单信息记录表 * @param tDispatchInfo 派单信息记录表
* @return R * @return R
*/ */
@Operation(summary = "修改派单信息记录表", description = "修改派单信息记录表:hasPermission('demo_tdispatchinfo_edit')") @Operation(summary = "修改派单信息记录表", description = "修改派单信息记录表:hasPermission('demo_tdispatchinfo_edit')")
@SysLog("修改派单信息记录表" ) @SysLog("修改派单信息记录表" )
@PutMapping @PutMapping
@PreAuthorize("@pms.hasPermission('demo_tdispatchinfo_edit')" ) @PreAuthorize("@pms.hasPermission('demo_tdispatchinfo_edit')" )
public R<Boolean> updateById(@RequestBody TDispatchInfo tDispatchInfo) { public R<Boolean> updateById(@RequestBody TDispatchInfo tDispatchInfo) {
return R.ok(tDispatchInfoService.updateById(tDispatchInfo)); return R.ok(tDispatchInfoService.updateById(tDispatchInfo));
} }
/** /**
* 通过id删除派单信息记录表 * 通过id删除派单信息记录表
* @param id id * @param id id
* @return R * @return R
*/ */
@Operation(summary = "通过id删除派单信息记录表", description = "通过id删除派单信息记录表:hasPermission('demo_tdispatchinfo_del')") @Operation(summary = "通过id删除派单信息记录表", description = "通过id删除派单信息记录表:hasPermission('demo_tdispatchinfo_del')")
@SysLog("通过id删除派单信息记录表" ) @SysLog("通过id删除派单信息记录表" )
@DeleteMapping("/{id}" ) @DeleteMapping("/{id}" )
@PreAuthorize("@pms.hasPermission('demo_tdispatchinfo_del')" ) @PreAuthorize("@pms.hasPermission('demo_tdispatchinfo_del')" )
public R<Boolean> removeById(@PathVariable String id) { public R<Boolean> removeById(@PathVariable String id) {
return tDispatchInfoService.removeByIdDiy(id); return tDispatchInfoService.removeByIdDiy(id);
} }
/** /**
* 派单信息记录表 批量导入 * 派单信息记录表 批量导入
* *
* @author fxj * @author fxj
* @date 2022-07-15 11:38:05 * @date 2022-07-15 11:38:05
**/ **/
@SneakyThrows @SneakyThrows
@Operation(description = "批量新增派单信息记录表 hasPermission('demo_tdispatchinfo-batch-import')") @Operation(description = "批量新增派单信息记录表 hasPermission('demo_tdispatchinfo-batch-import')")
@SysLog("批量新增派单信息记录表") @SysLog("批量新增派单信息记录表")
@PostMapping("/importListAdd") @PostMapping("/importListAdd")
//@PreAuthorize("@pms.hasPermission('demo_tdispatchinfo-batch-import')") //@PreAuthorize("@pms.hasPermission('demo_tdispatchinfo-batch-import')")
public R<List<ErrorMessage>> importListAdd(@RequestBody MultipartFile file, @RequestParam(required = false)String orderId){ public R<List<ErrorMessage>> importListAdd(@RequestBody MultipartFile file, @RequestParam(required = false)String orderId){
YifuUser user = SecurityUtils.getUser(); YifuUser user = SecurityUtils.getUser();
if (Common.isEmpty(user)){ if (Common.isEmpty(user)){
return R.failed(CommonConstants.USER_FAIL); return R.failed(CommonConstants.USER_FAIL);
...@@ -364,17 +365,17 @@ public class TDispatchInfoController { ...@@ -364,17 +365,17 @@ public class TDispatchInfoController {
//主动释放锁 //主动释放锁
RedisDistributedLock.unlock(key, requestId); RedisDistributedLock.unlock(key, requestId);
} }
} }
/** /**
* 派单信息记录表 批量导出 * 派单信息记录表 批量导出
* @author hgw * @author hgw
* @date 2022-7-28 11:01:56 * @date 2022-7-28 11:01:56
**/ **/
@Operation(description = "导出派单信息记录表 hasPermission('tdispatchinfo-export')") @Operation(description = "导出派单信息记录表 hasPermission('tdispatchinfo-export')")
@PostMapping("/export") @PostMapping("/export")
@PreAuthorize("@pms.hasPermission('tdispatchinfo-export')") @PreAuthorize("@pms.hasPermission('tdispatchinfo-export')")
public void export(HttpServletResponse response, @RequestBody TDispatchInfoSearchVo searchVo) { public void export(HttpServletResponse response, @RequestBody TDispatchInfoSearchVo searchVo) {
YifuUser user = SecurityUtils.getUser(); YifuUser user = SecurityUtils.getUser();
menuUtil.setAuthSql(user, searchVo); menuUtil.setAuthSql(user, searchVo);
if (Common.isNotNull(searchVo.getAuthSql())) { if (Common.isNotNull(searchVo.getAuthSql())) {
...@@ -387,7 +388,7 @@ public class TDispatchInfoController { ...@@ -387,7 +388,7 @@ public class TDispatchInfoController {
} }
searchVo.setCreateBy(user.getId()); searchVo.setCreateBy(user.getId());
tDispatchInfoService.listExport(response,searchVo); tDispatchInfoService.listExport(response,searchVo);
} }
/** /**
* 派单审核记录批量导出 * 派单审核记录批量导出
...@@ -435,7 +436,7 @@ public class TDispatchInfoController { ...@@ -435,7 +436,7 @@ public class TDispatchInfoController {
@PostMapping("/importListReduce") @PostMapping("/importListReduce")
//@PreAuthorize("@pms.hasPermission('demo_tdispatchinfo-batch-reduce')") //@PreAuthorize("@pms.hasPermission('demo_tdispatchinfo-batch-reduce')")
public R<List<ErrorMessage>> importListReduce(@RequestBody MultipartFile file, @RequestParam(required = false)String orderId public R<List<ErrorMessage>> importListReduce(@RequestBody MultipartFile file, @RequestParam(required = false)String orderId
,@RequestParam(required = false) String flag){ ,@RequestParam(required = false) String flag){
YifuUser user = SecurityUtils.getUser(); YifuUser user = SecurityUtils.getUser();
if (Common.isEmpty(user)){ if (Common.isEmpty(user)){
return R.failed(CommonConstants.USER_FAIL); return R.failed(CommonConstants.USER_FAIL);
...@@ -487,15 +488,15 @@ public class TDispatchInfoController { ...@@ -487,15 +488,15 @@ public class TDispatchInfoController {
* @Date 16:54 2022/7/25 * @Date 16:54 2022/7/25
* @Param * @Param
* @return * @return
**/ **/
@Operation(description = "派单申请批量审核,传参派单ID hasPermission('wxhr:tdispatchinfo_addApplyAudit') auditStatus:1审核通过 2审核不通过") @Operation(description = "派单申请批量审核,传参派单ID hasPermission('wxhr:tdispatchinfo_addApplyAudit') auditStatus:1审核通过 2审核不通过")
@SysLog("派单申请批量审核") @SysLog("派单申请批量审核")
@PostMapping("/addApplyAudit") @PostMapping("/addApplyAudit")
//@PreAuthorize("@pms.hasPermission('wxhr:tdispatchinfo_addApplyAudit')") //@PreAuthorize("@pms.hasPermission('wxhr:tdispatchinfo_addApplyAudit')")
public R<List<ErrorMessage>> addApplyAudit(@RequestBody List<String> idList, public R<List<ErrorMessage>> addApplyAudit(@RequestBody List<String> idList,
@RequestParam(name = "auditStatus", required = true) String auditStatus, @RequestParam(name = "auditStatus", required = true) String auditStatus,
@RequestParam(name = "auditRemark", required = false) String auditRemark, @RequestParam(name = "auditRemark", required = false) String auditRemark,
@RequestParam(name = "remark", required = false) String remark) { @RequestParam(name = "remark", required = false) String remark) {
YifuUser user = SecurityUtils.getUser(); YifuUser user = SecurityUtils.getUser();
if (Common.isEmpty(user)){ if (Common.isEmpty(user)){
return R.failed(CommonConstants.USER_FAIL); return R.failed(CommonConstants.USER_FAIL);
...@@ -538,11 +539,11 @@ public class TDispatchInfoController { ...@@ -538,11 +539,11 @@ public class TDispatchInfoController {
@PostMapping("/addApplyHandle") @PostMapping("/addApplyHandle")
//@PreAuthorize("@pms.hasPermission('wxhr:tdispatchinfo_addApplyHandle')") //@PreAuthorize("@pms.hasPermission('wxhr:tdispatchinfo_addApplyHandle')")
public R<List<ErrorMessage>> addApplyHandle(@RequestBody List<String> idList, public R<List<ErrorMessage>> addApplyHandle(@RequestBody List<String> idList,
@RequestParam(name = "typeSub", required = true) String typeSub, @RequestParam(name = "typeSub", required = true) String typeSub,
@RequestParam(name = "handleStatus", required = true) String handleStatus, @RequestParam(name = "handleStatus", required = true) String handleStatus,
@RequestParam(name = "handleRemark", required = false) String handleRemark, @RequestParam(name = "handleRemark", required = false) String handleRemark,
@RequestParam(name = "socialType", required = false) String socialType, @RequestParam(name = "socialType", required = false) String socialType,
@RequestParam(name = "remark", required = false) String remark) { @RequestParam(name = "remark", required = false) String remark) {
YifuUser user = SecurityUtils.getUser(); YifuUser user = SecurityUtils.getUser();
if (Common.isEmpty(user)){ if (Common.isEmpty(user)){
return R.failed(CommonConstants.USER_FAIL); return R.failed(CommonConstants.USER_FAIL);
...@@ -608,12 +609,12 @@ public class TDispatchInfoController { ...@@ -608,12 +609,12 @@ public class TDispatchInfoController {
* @Description 导出社保士兵信息 * @Description 导出社保士兵信息
* @Date 2024-5-13 11:35:26 * @Date 2024-5-13 11:35:26
* @Param * @Param
**/ **/
@PostMapping("/doExportSocialSoldier") @PostMapping("/doExportSocialSoldier")
@Operation(description = "导出社保士兵信息") @Operation(description = "导出社保士兵信息")
@SysLog("导出社保士兵信息") @SysLog("导出社保士兵信息")
public void doExportSocialSoldier(HttpServletResponse response, HttpServletRequest request, public void doExportSocialSoldier(HttpServletResponse response, HttpServletRequest request,
@RequestBody SocialHandleSearchVo searchVo) { @RequestBody SocialHandleSearchVo searchVo) {
searchVo.setDeleteFlag(CommonConstants.ZERO_STRING); searchVo.setDeleteFlag(CommonConstants.ZERO_STRING);
YifuUser user = SecurityUtils.getUser(); YifuUser user = SecurityUtils.getUser();
menuUtil.setAuthSql(user, searchVo); menuUtil.setAuthSql(user, searchVo);
...@@ -629,7 +630,7 @@ public class TDispatchInfoController { ...@@ -629,7 +630,7 @@ public class TDispatchInfoController {
* @Description 导出 社保花名册 * @Description 导出 社保花名册
* @Date 17:40 2022/7/27 * @Date 17:40 2022/7/27
* @Param * @Param
**/ **/
@PostMapping("/doexportSocialRecordRoster") @PostMapping("/doexportSocialRecordRoster")
@Operation(description = "导出社保花名册 hasPermission('wxhr:tdispatchinfo_doexportSocialRecordRoster')") @Operation(description = "导出社保花名册 hasPermission('wxhr:tdispatchinfo_doexportSocialRecordRoster')")
@SysLog("导出社保花名册信息") @SysLog("导出社保花名册信息")
...@@ -652,7 +653,7 @@ public class TDispatchInfoController { ...@@ -652,7 +653,7 @@ public class TDispatchInfoController {
* @Date 20:05 2022/7/27 * @Date 20:05 2022/7/27
* @Param * @Param
* @return * @return
**/ **/
@PostMapping("/doexportFundRecordChange") @PostMapping("/doexportFundRecordChange")
@Operation(description = "导出公积金变更清册 hasPermission('wxhr:tdispatchinfo_doexportFundRecordChange')") @Operation(description = "导出公积金变更清册 hasPermission('wxhr:tdispatchinfo_doexportFundRecordChange')")
@SysLog("导出公积金变更清册") @SysLog("导出公积金变更清册")
...@@ -673,7 +674,7 @@ public class TDispatchInfoController { ...@@ -673,7 +674,7 @@ public class TDispatchInfoController {
* @Date 20:05 2022/7/27 * @Date 20:05 2022/7/27
* @Param * @Param
* @return * @return
**/ **/
@GetMapping("/doExportFundSupplementaryRecord") @GetMapping("/doExportFundSupplementaryRecord")
@Operation(description = "导出公积金补缴清册 hasPermission('wxhr:tdispatchinfo_doExportFundSupplementaryRecord')") @Operation(description = "导出公积金补缴清册 hasPermission('wxhr:tdispatchinfo_doExportFundSupplementaryRecord')")
@SysLog("导出公积金补缴清册") @SysLog("导出公积金补缴清册")
...@@ -724,7 +725,7 @@ public class TDispatchInfoController { ...@@ -724,7 +725,7 @@ public class TDispatchInfoController {
* @Date 15:29 2023/5/8 * @Date 15:29 2023/5/8
* @Param * @Param
* @return * @return
**/ **/
@SneakyThrows @SneakyThrows
@Operation(summary = "单个派增 权限:social_dispatchinfo_add", description = "单个派增") @Operation(summary = "单个派增 权限:social_dispatchinfo_add", description = "单个派增")
@PostMapping("/fundImportHandle") @PostMapping("/fundImportHandle")
...@@ -807,7 +808,7 @@ public class TDispatchInfoController { ...@@ -807,7 +808,7 @@ public class TDispatchInfoController {
@SysLog("导出医保花名册") @SysLog("导出医保花名册")
//@PreAuthorize("@pms.hasPermission('wxhr:tdispatchinfo_doexportFundRecordChange')") //@PreAuthorize("@pms.hasPermission('wxhr:tdispatchinfo_doexportFundRecordChange')")
public void doexportMedicalInfo(HttpServletResponse response, HttpServletRequest request, public void doexportMedicalInfo(HttpServletResponse response, HttpServletRequest request,
@RequestBody SocialHandleSearchVo searchVo) { @RequestBody SocialHandleSearchVo searchVo) {
YifuUser user = SecurityUtils.getUser(); YifuUser user = SecurityUtils.getUser();
menuUtil.setAuthSql(user, searchVo); menuUtil.setAuthSql(user, searchVo);
if (Common.isNotNull(searchVo.getAuthSql()) && searchVo.getAuthSql().contains(CommonConstants.A_DEPT_ID)) { if (Common.isNotNull(searchVo.getAuthSql()) && searchVo.getAuthSql().contains(CommonConstants.A_DEPT_ID)) {
...@@ -856,7 +857,7 @@ public class TDispatchInfoController { ...@@ -856,7 +857,7 @@ public class TDispatchInfoController {
@Operation(description = "导出住房公积金变更清册") @Operation(description = "导出住房公积金变更清册")
@SysLog("导出住房公积金变更清册") @SysLog("导出住房公积金变更清册")
public void doexportFundInfo(HttpServletResponse response, HttpServletRequest request, public void doexportFundInfo(HttpServletResponse response, HttpServletRequest request,
@RequestBody SocialHandleSearchVo searchVo) { @RequestBody SocialHandleSearchVo searchVo) {
YifuUser user = SecurityUtils.getUser(); YifuUser user = SecurityUtils.getUser();
menuUtil.setAuthSql(user, searchVo); menuUtil.setAuthSql(user, searchVo);
if (Common.isNotNull(searchVo.getAuthSql()) && searchVo.getAuthSql().contains(CommonConstants.A_DEPT_ID)) { if (Common.isNotNull(searchVo.getAuthSql()) && searchVo.getAuthSql().contains(CommonConstants.A_DEPT_ID)) {
...@@ -877,7 +878,7 @@ public class TDispatchInfoController { ...@@ -877,7 +878,7 @@ public class TDispatchInfoController {
@Operation(description = "导出住房公积金补缴清册") @Operation(description = "导出住房公积金补缴清册")
@SysLog("导出住房公积金补缴清册") @SysLog("导出住房公积金补缴清册")
public void doexportFundInfoOne(HttpServletResponse response, HttpServletRequest request, public void doexportFundInfoOne(HttpServletResponse response, HttpServletRequest request,
@RequestBody SocialHandleSearchVo searchVo) { @RequestBody SocialHandleSearchVo searchVo) {
YifuUser user = SecurityUtils.getUser(); YifuUser user = SecurityUtils.getUser();
menuUtil.setAuthSql(user, searchVo); menuUtil.setAuthSql(user, searchVo);
if (Common.isNotNull(searchVo.getAuthSql()) && searchVo.getAuthSql().contains(CommonConstants.A_DEPT_ID)) { if (Common.isNotNull(searchVo.getAuthSql()) && searchVo.getAuthSql().contains(CommonConstants.A_DEPT_ID)) {
...@@ -886,4 +887,21 @@ public class TDispatchInfoController { ...@@ -886,4 +887,21 @@ public class TDispatchInfoController {
searchVo.setCreateBy(user.getId()); searchVo.setCreateBy(user.getId());
tDispatchInfoService.doexportFundInfoOne(response,searchVo); tDispatchInfoService.doexportFundInfoOne(response,searchVo);
} }
/**
* @Author fxj
* @Description 导出花名册
* @Date 14:02 2024/12/10
* @Param
* @return
**/
@PostMapping("/doExportRoster")
@Operation(description = "导出花名册")
@SysLog("导出花名册")
public R<URL> doExportRoster(@RequestParam("socialId") String socialId, @RequestParam("type") String type,@RequestParam("unitCreditCode")String unitCreditCode) {
return tDispatchInfoService.doExportRoster(socialId,type,unitCreditCode);
}
} }
...@@ -32,6 +32,7 @@ import org.springframework.transaction.annotation.Transactional; ...@@ -32,6 +32,7 @@ import org.springframework.transaction.annotation.Transactional;
import javax.servlet.http.HttpServletResponse; import javax.servlet.http.HttpServletResponse;
import java.io.InputStream; import java.io.InputStream;
import java.net.URL;
import java.util.List; import java.util.List;
import java.util.Map; import java.util.Map;
...@@ -42,12 +43,12 @@ import java.util.Map; ...@@ -42,12 +43,12 @@ import java.util.Map;
* @date 2022-07-15 11:38:05 * @date 2022-07-15 11:38:05
*/ */
public interface TDispatchInfoService extends IService<TDispatchInfo> { public interface TDispatchInfoService extends IService<TDispatchInfo> {
/** /**
* 派单信息记录表简单分页查询 * 派单信息记录表简单分页查询
* @param tDispatchInfo 派单信息记录表 * @param tDispatchInfo 派单信息记录表
* @return * @return
*/ */
IPage<TDispatchInfoPageVo> getTDispatchInfoPage(Page<TDispatchInfo> page, TDispatchInfoSearchVo tDispatchInfo); IPage<TDispatchInfoPageVo> getTDispatchInfoPage(Page<TDispatchInfo> page, TDispatchInfoSearchVo tDispatchInfo);
IPage<TDispatchInfoPageVo> getTDispatchInfoPageAudit(Page<TDispatchInfo> page, TDispatchInfoSearchVo tDispatchInfo); IPage<TDispatchInfoPageVo> getTDispatchInfoPageAudit(Page<TDispatchInfo> page, TDispatchInfoSearchVo tDispatchInfo);
...@@ -55,11 +56,11 @@ public interface TDispatchInfoService extends IService<TDispatchInfo> { ...@@ -55,11 +56,11 @@ public interface TDispatchInfoService extends IService<TDispatchInfo> {
R<List<ErrorMessage>> importSocialHandler(InputStream inputStream,String mId, boolean isAutoHandle); R<List<ErrorMessage>> importSocialHandler(InputStream inputStream,String mId, boolean isAutoHandle);
void listExport(HttpServletResponse response, TDispatchInfoSearchVo searchVo); void listExport(HttpServletResponse response, TDispatchInfoSearchVo searchVo);
void listAuditExport(HttpServletResponse response, TDispatchInfoSearchVo searchVo); void listAuditExport(HttpServletResponse response, TDispatchInfoSearchVo searchVo);
List<TDispatchInfo> noPageDiy(TDispatchInfoSearchVo searchVo); List<TDispatchInfo> noPageDiy(TDispatchInfoSearchVo searchVo);
@Transactional @Transactional
@ShardingTransactionType(TransactionType.BASE) @ShardingTransactionType(TransactionType.BASE)
...@@ -77,7 +78,7 @@ public interface TDispatchInfoService extends IService<TDispatchInfo> { ...@@ -77,7 +78,7 @@ public interface TDispatchInfoService extends IService<TDispatchInfo> {
DispatchDetailVo getSocialAndFundInfoById(String id); DispatchDetailVo getSocialAndFundInfoById(String id);
List<ErrorMessage> addBatchApplyAudit(List<String> idsList, YifuUser user, int flag, String auditStatus, String auditRemark, String remark); List<ErrorMessage> addBatchApplyAudit(List<String> idsList, YifuUser user, int flag, String auditStatus, String auditRemark, String remark);
R<List<ErrorMessage>> addApplyAudit(List<String> ids, String auditStatus, String auditRemark, String remark); R<List<ErrorMessage>> addApplyAudit(List<String> ids, String auditStatus, String auditRemark, String remark);
...@@ -161,4 +162,5 @@ public interface TDispatchInfoService extends IService<TDispatchInfo> { ...@@ -161,4 +162,5 @@ public interface TDispatchInfoService extends IService<TDispatchInfo> {
**/ **/
List<SocialHandleExportVo> getRecordRosterList(SocialHandleSearchVo searchVo, String idStr); List<SocialHandleExportVo> getRecordRosterList(SocialHandleSearchVo searchVo, String idStr);
R<URL> doExportRoster(String socialId, String type,String unitCreditCode);
} }
...@@ -83,7 +83,9 @@ import org.springframework.transaction.annotation.Transactional; ...@@ -83,7 +83,9 @@ import org.springframework.transaction.annotation.Transactional;
import javax.servlet.ServletOutputStream; import javax.servlet.ServletOutputStream;
import javax.servlet.http.HttpServletResponse; import javax.servlet.http.HttpServletResponse;
import java.io.*; import java.io.FileOutputStream;
import java.io.IOException;
import java.io.InputStream;
import java.math.BigDecimal; import java.math.BigDecimal;
import java.net.URL; import java.net.URL;
import java.net.URLEncoder; import java.net.URLEncoder;
...@@ -502,8 +504,8 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T ...@@ -502,8 +504,8 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
if (Common.isNotNull(empVoMap)) { if (Common.isNotNull(empVoMap)) {
empVo = empVoMap.get(excel.getEmpIdcard()); empVo = empVoMap.get(excel.getEmpIdcard());
} }
if (Common.isNotNull(socialFund) if (Common.isNotNull(socialFund)
&& Common.isNotNull(socialFund.getSocialId()) && Common.isNotNull(socialFund.getSocialId())
&& (CommonConstants.FOUR_STRING.equals(socialFund.getSocialStatus()) && (CommonConstants.FOUR_STRING.equals(socialFund.getSocialStatus())
|| CommonConstants.TWELVE_STRING.equals(socialFund.getSocialStatus()))){ || CommonConstants.TWELVE_STRING.equals(socialFund.getSocialStatus()))){
// 部分失败 // 部分失败
...@@ -568,7 +570,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T ...@@ -568,7 +570,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
} }
} else { } else {
if (Common.isNotNull(excel.getProvidentStart()) || Common.isNotNull(excel.getProvidentCardinal()) || if (Common.isNotNull(excel.getProvidentStart()) || Common.isNotNull(excel.getProvidentCardinal()) ||
Common.isNotNull(excel.getProvidentPer())) { Common.isNotNull(excel.getProvidentPer())) {
errorMessageList.add(new ErrorMessage(excel.getRowIndex(), MsgUtils.getMessage(ErrorCodes.FUND_HOLD_IS_EMPTY))); errorMessageList.add(new ErrorMessage(excel.getRowIndex(), MsgUtils.getMessage(ErrorCodes.FUND_HOLD_IS_EMPTY)));
excelVOTemp.put(excel.getRowIndex().toString(),excel.getEmpIdcard()); excelVOTemp.put(excel.getRowIndex().toString(),excel.getEmpIdcard());
continue; continue;
...@@ -748,7 +750,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T ...@@ -748,7 +750,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
if (Common.isNotNull(socialFund) && Common.isNotNull(dispatch)){ if (Common.isNotNull(socialFund) && Common.isNotNull(dispatch)){
socialFund.setDispatchId(dispatch.getId()); socialFund.setDispatchId(dispatch.getId());
} }
initSocialFundAndInsert(emp, social, fund, socialFund,project,dispatchPart,injury); initSocialFundAndInsert(emp, social, fund, socialFund,project,dispatchPart,injury);
} }
// 生成预付数据 // 生成预付数据
if (Common.isNotNull(socialFund) && Common.isNotNull(socialFund.getId())){ if (Common.isNotNull(socialFund) && Common.isNotNull(socialFund.getId())){
...@@ -1112,7 +1114,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T ...@@ -1112,7 +1114,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
* @Date 14:12 2022/8/17 * @Date 14:12 2022/8/17
* @Param * @Param
* @return * @return
**/ **/
private Date getFirstBuyMonthSocial(TSocialInfo social) { private Date getFirstBuyMonthSocial(TSocialInfo social) {
if (Common.isEmpty(social) || Common.isEmpty(social.getSocialStartDate())){ if (Common.isEmpty(social) || Common.isEmpty(social.getSocialStartDate())){
return null; return null;
...@@ -1279,13 +1281,13 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T ...@@ -1279,13 +1281,13 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
return zeroArr[num] + nowNums; return zeroArr[num] + nowNums;
} }
private boolean initDispatchAddInfo(YifuUser user, private boolean initDispatchAddInfo(YifuUser user,
Map<String, TDispatchInfo> dispatchMap, Map<String, TDispatchInfo> dispatchMap,
DispatchEmpVo empVo, DispatchEmpVo empVo,
SysBaseSetInfo socialSet, SysBaseSetInfo socialSet,
SysBaseSetInfo fundSet, SysBaseSetInfo fundSet,
TDispatchImportVo excel, TDispatchImportVo excel,
TSocialFundInfo socialFund, TSocialFundInfo socialFund,
boolean injury) { boolean injury) {
// 是否SSC:SSC派单组-1659015946137583618L SSC审核组-1659016108176130049L // 是否SSC:SSC派单组-1659015946137583618L SSC审核组-1659016108176130049L
long roleId = 1659015946137583618L; long roleId = 1659015946137583618L;
boolean isSsc = haveRole(user, roleId); boolean isSsc = haveRole(user, roleId);
...@@ -1906,7 +1908,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T ...@@ -1906,7 +1908,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
&& Common.isEmpty(social.getUnemployStart()) && Common.isEmpty(social.getUnemployStart())
&& Common.isEmpty(social.getBigailmentStart()) && Common.isEmpty(social.getBigailmentStart())
&& Common.isNotNull(social.getWorkInjuryStart()) && Common.isNotNull(social.getWorkInjuryStart())
)){ )){
social.setBigailmentHandle(null); social.setBigailmentHandle(null);
social.setPersonalBigailmentCardinal(null); social.setPersonalBigailmentCardinal(null);
social.setPersonalBigailmentPer(null); social.setPersonalBigailmentPer(null);
...@@ -2484,7 +2486,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T ...@@ -2484,7 +2486,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
} }
if ((Common.isEmpty(empVo) || Common.isEmpty(empVo.getContractStart())) if ((Common.isEmpty(empVo) || Common.isEmpty(empVo.getContractStart()))
&& Common.isNotNull(excel.getContractName()) && ( && Common.isNotNull(excel.getContractName()) && (
Common.isEmpty(excel.getContractType()) Common.isEmpty(excel.getContractType())
|| Common.isEmpty(excel.getContractStart()) || Common.isEmpty(excel.getContractStart())
)) { )) {
errorMessageList.add(new ErrorMessage(excel.getRowIndex(), MsgUtils.getMessage(ErrorCodes.EMP_DISPATCH_CONTRACT_NOT_EMPTY))); errorMessageList.add(new ErrorMessage(excel.getRowIndex(), MsgUtils.getMessage(ErrorCodes.EMP_DISPATCH_CONTRACT_NOT_EMPTY)));
...@@ -2500,21 +2502,21 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T ...@@ -2500,21 +2502,21 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
return true; return true;
} }
if (CommonConstants.ONE_STRING.equals(excel.getPaymentType()) if (CommonConstants.ONE_STRING.equals(excel.getPaymentType())
&& (Common.isNullOrZero(excel.getPensionCardinal()) || Common.isEmpty(excel.getPensionStart())) && (Common.isNullOrZero(excel.getPensionCardinal()) || Common.isEmpty(excel.getPensionStart()))
&& !( && !(
Common.isEmpty(excel.getPensionStart()) Common.isEmpty(excel.getPensionStart())
&& Common.isNotNull(excel.getWorkInjuryStart()) && Common.isNotNull(excel.getWorkInjuryStart())
&& Common.isEmpty(excel.getMedicalStart()) && Common.isEmpty(excel.getMedicalStart())
&& Common.isEmpty(excel.getBirthStart()) && Common.isEmpty(excel.getBirthStart())
&& Common.isEmpty(excel.getUnemployStart()) && Common.isEmpty(excel.getUnemployStart())
&& Common.isEmpty(excel.getBigailmentStart()) && Common.isEmpty(excel.getBigailmentStart())
&& Common.isNullOrZero(excel.getPensionCardinal()) && Common.isNullOrZero(excel.getPensionCardinal())
&& Common.isNullOrZero(excel.getMedicalCardinal()) && Common.isNullOrZero(excel.getMedicalCardinal())
&& Common.isNullOrZero(excel.getBirthCardinal()) && Common.isNullOrZero(excel.getBirthCardinal())
&& Common.isNullOrZero(excel.getUnemploymentCardinal()) && Common.isNullOrZero(excel.getUnemploymentCardinal())
&& !Common.isNullOrZero(excel.getWorkInjuryCardinal()) && !Common.isNullOrZero(excel.getWorkInjuryCardinal())
&& Common.isNullOrZero(excel.getBigailmentCardinal()) && Common.isNullOrZero(excel.getBigailmentCardinal())
) )
){ ){
//养老基数为空 兼职工伤除外 //养老基数为空 兼职工伤除外
errorMessageList.add(new ErrorMessage(excel.getRowIndex(), MsgUtils.getMessage(ErrorCodes.EMP_DISPATCH_SOCIAL_DIY_MEDICAL_NOT_EMPTY))); errorMessageList.add(new ErrorMessage(excel.getRowIndex(), MsgUtils.getMessage(ErrorCodes.EMP_DISPATCH_SOCIAL_DIY_MEDICAL_NOT_EMPTY)));
...@@ -2563,7 +2565,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T ...@@ -2563,7 +2565,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
|| CommonConstants.THREE_STRING.equals(socialFund.getSocialStatus()) || CommonConstants.THREE_STRING.equals(socialFund.getSocialStatus())
|| CommonConstants.TWO_STRING.equals(socialFund.getSocialStatus()) || CommonConstants.TWO_STRING.equals(socialFund.getSocialStatus())
|| CommonConstants.ELEVEN_STRING.equals(socialFund.getSocialStatus()) || CommonConstants.ELEVEN_STRING.equals(socialFund.getSocialStatus())
) )
){ ){
errorMessageList.add(new ErrorMessage(excel.getRowIndex(), MsgUtils.getMessage(ErrorCodes.EMP_DISPATCH_SOCIAL_EXISTING))); errorMessageList.add(new ErrorMessage(excel.getRowIndex(), MsgUtils.getMessage(ErrorCodes.EMP_DISPATCH_SOCIAL_EXISTING)));
return true; return true;
...@@ -2770,9 +2772,9 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T ...@@ -2770,9 +2772,9 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
|| (Common.isNotNull(excel.getBirthCardinal()) || (Common.isNotNull(excel.getBirthCardinal())
&& excel.getBirthCardinal().compareTo(excel.getRecordBase()) != CommonConstants.ZERO_INT) && excel.getBirthCardinal().compareTo(excel.getRecordBase()) != CommonConstants.ZERO_INT)
|| (Common.isNotNull(excel.getBigailmentCardinal()) || (Common.isNotNull(excel.getBigailmentCardinal())
&& CommonConstants.ONE_STRING.equals(socialSet.getCollectType()) && CommonConstants.ONE_STRING.equals(socialSet.getCollectType())
&& CommonConstants.ONE_STRING.equals(socialSet.getValueType()) && CommonConstants.ONE_STRING.equals(socialSet.getValueType())
&& excel.getBigailmentCardinal().compareTo(excel.getRecordBase()) != CommonConstants.ZERO_INT); && excel.getBigailmentCardinal().compareTo(excel.getRecordBase()) != CommonConstants.ZERO_INT);
if (flag){ if (flag){
errorMessageList.add(new ErrorMessage(excel.getRowIndex(), MsgUtils.getMessage(ErrorCodes.EMP_DISPATCH_SOCIAL_BASE_LIMIT_ERROR))); errorMessageList.add(new ErrorMessage(excel.getRowIndex(), MsgUtils.getMessage(ErrorCodes.EMP_DISPATCH_SOCIAL_BASE_LIMIT_ERROR)));
return true; return true;
...@@ -2809,13 +2811,13 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T ...@@ -2809,13 +2811,13 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
} }
//最低最高时候去校验时候去校验 //最低最高时候去校验时候去校验
if (Common.isEmpty(excel.getTrustRemark()) && ((CommonConstants.ZERO_STRING.equals(excel.getPaymentType()) if (Common.isEmpty(excel.getTrustRemark()) && ((CommonConstants.ZERO_STRING.equals(excel.getPaymentType())
&& (socialSet.getLowerPersion().compareTo(excel.getRecordBase()) != CommonConstants.ZERO_INT || && (socialSet.getLowerPersion().compareTo(excel.getRecordBase()) != CommonConstants.ZERO_INT ||
socialSet.getLowerMedical().compareTo(excel.getRecordBase()) != CommonConstants.ZERO_INT || socialSet.getLowerMedical().compareTo(excel.getRecordBase()) != CommonConstants.ZERO_INT ||
socialSet.getLowerUnemployment().compareTo(excel.getRecordBase()) != CommonConstants.ZERO_INT || socialSet.getLowerUnemployment().compareTo(excel.getRecordBase()) != CommonConstants.ZERO_INT ||
socialSet.getLowerInjury().compareTo(excel.getRecordBase()) != CommonConstants.ZERO_INT || socialSet.getLowerInjury().compareTo(excel.getRecordBase()) != CommonConstants.ZERO_INT ||
socialSet.getLowerBirth().compareTo(excel.getRecordBase()) != CommonConstants.ZERO_INT || ( socialSet.getLowerBirth().compareTo(excel.getRecordBase()) != CommonConstants.ZERO_INT || (
CommonConstants.ONE_STRING.equals(socialSet.getCollectType()) CommonConstants.ONE_STRING.equals(socialSet.getCollectType())
&& CommonConstants.ONE_STRING.equals(socialSet.getValueType()) && && CommonConstants.ONE_STRING.equals(socialSet.getValueType()) &&
socialSet.getLowerBig().compareTo(excel.getRecordBase()) != CommonConstants.ZERO_INT))) || socialSet.getLowerBig().compareTo(excel.getRecordBase()) != CommonConstants.ZERO_INT))) ||
(CommonConstants.TWO_STRING.equals(excel.getPaymentType()) (CommonConstants.TWO_STRING.equals(excel.getPaymentType())
&& (socialSet.getUpPersion().compareTo(excel.getRecordBase()) != CommonConstants.ZERO_INT || && (socialSet.getUpPersion().compareTo(excel.getRecordBase()) != CommonConstants.ZERO_INT ||
...@@ -2972,7 +2974,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T ...@@ -2972,7 +2974,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
@Override @Override
public void batchReduceDispatch(List<TDispatchReduceVo> excelVOList, List<ErrorMessage> errorMessageList, public void batchReduceDispatch(List<TDispatchReduceVo> excelVOList, List<ErrorMessage> errorMessageList,
YifuUser user, String orderId, String flag) { YifuUser user, String orderId, String flag) {
if (!Common.isNotNull(excelVOList)){ if (!Common.isNotNull(excelVOList)){
return; return;
} }
...@@ -3066,7 +3068,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T ...@@ -3066,7 +3068,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
continue; continue;
} }
// 自定义校验 // 自定义校验
if (validReduce(errorMessageList,excelVOTemp, socialFundMap,socialFund, excel)){ if (validReduce(errorMessageList,excelVOTemp, socialFundMap,socialFund, excel)){
continue; continue;
} }
if (Common.isNotNull(empVoMap)) { if (Common.isNotNull(empVoMap)) {
...@@ -3498,7 +3500,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T ...@@ -3498,7 +3500,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
sf.setSocialAddStatus(CommonConstants.ONE_STRING); sf.setSocialAddStatus(CommonConstants.ONE_STRING);
sf.setSocialStatus(CommonConstants.ONE_STRING); sf.setSocialStatus(CommonConstants.ONE_STRING);
} }
//派增审核不通过 需要处理预估数据 //派增审核不通过 需要处理预估数据
} else if (CommonConstants.ONE_INT == flag) { } else if (CommonConstants.ONE_INT == flag) {
socialInfo.setDeleteFlag(CommonConstants.ONE_STRING); socialInfo.setDeleteFlag(CommonConstants.ONE_STRING);
// 作废更新:社保状态、同步预估数据 审核不通过直接作废 // 作废更新:社保状态、同步预估数据 审核不通过直接作废
...@@ -3964,7 +3966,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T ...@@ -3964,7 +3966,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
**/ **/
@Transactional(rollbackFor = Exception.class) @Transactional(rollbackFor = Exception.class)
public List<ErrorMessage> addBatchApplyHandle(ConcurrentHashMap<String, String> socialMap,ConcurrentHashMap<String, String> fundMap, public List<ErrorMessage> addBatchApplyHandle(ConcurrentHashMap<String, String> socialMap,ConcurrentHashMap<String, String> fundMap,
List<String> idsList, String typeSub, YifuUser user List<String> idsList, String typeSub, YifuUser user
, int flag, String handleStatus, String handleRemark, String socialType, String remark, boolean isAutoHandle) { , int flag, String handleStatus, String handleRemark, String socialType, String remark, boolean isAutoHandle) {
List<ErrorMessage> errorList = new ArrayList<>(); List<ErrorMessage> errorList = new ArrayList<>();
if (!Common.isNotNull(idsList)) { if (!Common.isNotNull(idsList)) {
...@@ -4019,7 +4021,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T ...@@ -4019,7 +4021,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
|| ((CommonConstants.ONE_STRING.equals(sf.getBigailmentHandle()) || ((CommonConstants.ONE_STRING.equals(sf.getBigailmentHandle())
|| CommonConstants.FOUR_STRING.equals(sf.getBigailmentHandle())) || CommonConstants.FOUR_STRING.equals(sf.getBigailmentHandle()))
&& CommonConstants.ZERO_STRING.equals(sf.getIsIllness())) && CommonConstants.ZERO_STRING.equals(sf.getIsIllness()))
)) ))
&& !((CommonConstants.ONE_STRING.equals(sf.getPensionHandle()) && !((CommonConstants.ONE_STRING.equals(sf.getPensionHandle())
|| CommonConstants.FOUR_STRING.equals(sf.getPensionHandle())) || CommonConstants.FOUR_STRING.equals(sf.getPensionHandle()))
&& (CommonConstants.ONE_STRING.equals(sf.getMedicalHandle()) && (CommonConstants.ONE_STRING.equals(sf.getMedicalHandle())
...@@ -4362,7 +4364,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T ...@@ -4362,7 +4364,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
vo.setDepartNo(dis.getSettleDomainCode()); vo.setDepartNo(dis.getSettleDomainCode());
if (Common.isNotNull(dis.getChangeContractAndEmployee()) if (Common.isNotNull(dis.getChangeContractAndEmployee())
&& CommonConstants.ZERO_STRING.equals(dis.getChangeContractAndEmployee()) && CommonConstants.ZERO_STRING.equals(dis.getChangeContractAndEmployee())
&& (Common.isNotNull(vo.getSocialStatus()) || Common.isNotNull(vo.getFundStatus()))) { && (Common.isNotNull(vo.getSocialStatus()) || Common.isNotNull(vo.getFundStatus()))) {
vo.setChangeContractAndEmployee(dis.getChangeContractAndEmployee()); vo.setChangeContractAndEmployee(dis.getChangeContractAndEmployee());
vo.setUserId(user.getId()); vo.setUserId(user.getId());
vo.setUserName(user.getNickname()); vo.setUserName(user.getNickname());
...@@ -4444,7 +4446,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T ...@@ -4444,7 +4446,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
* @Date 15:18 2022/8/9 * @Date 15:18 2022/8/9
* @Param * @Param
* @return * @return
**/ **/
private void initSocialFundStatus(TSocialInfo socialInfo, TProvidentFund providentFund, UpProjectSocialFundVo vo, TSocialFundInfo sf) { private void initSocialFundStatus(TSocialInfo socialInfo, TProvidentFund providentFund, UpProjectSocialFundVo vo, TSocialFundInfo sf) {
if (Common.isNotNull(socialInfo)){ if (Common.isNotNull(socialInfo)){
// 办理失败或审核不通过且无办理成功项 // 办理失败或审核不通过且无办理成功项
...@@ -4465,18 +4467,18 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T ...@@ -4465,18 +4467,18 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
|| CommonConstants.TWELVE_STRING.equals(sf.getSocialStatus()) || CommonConstants.TWELVE_STRING.equals(sf.getSocialStatus())
|| ( || (
CommonConstants.TEN_STRING.equals(sf.getSocialStatus()) CommonConstants.TEN_STRING.equals(sf.getSocialStatus())
&& (CommonConstants.ONE_STRING.equals(sf.getPensionHandle()) && (CommonConstants.ONE_STRING.equals(sf.getPensionHandle())
|| CommonConstants.ONE_STRING.equals(sf.getMedicalHandle()) || CommonConstants.ONE_STRING.equals(sf.getMedicalHandle())
|| CommonConstants.ONE_STRING.equals(sf.getWorkInjuryHandle()) || CommonConstants.ONE_STRING.equals(sf.getWorkInjuryHandle())
|| CommonConstants.ONE_STRING.equals(sf.getBirthHandle()) || CommonConstants.ONE_STRING.equals(sf.getBirthHandle())
|| CommonConstants.ONE_STRING.equals(sf.getUnemployHandle())) || CommonConstants.ONE_STRING.equals(sf.getUnemployHandle()))
|| CommonConstants.FOUR_STRING.equals(sf.getPensionHandle()) || CommonConstants.FOUR_STRING.equals(sf.getPensionHandle())
|| CommonConstants.FOUR_STRING.equals(sf.getMedicalHandle()) || CommonConstants.FOUR_STRING.equals(sf.getMedicalHandle())
|| CommonConstants.FOUR_STRING.equals(sf.getWorkInjuryHandle()) || CommonConstants.FOUR_STRING.equals(sf.getWorkInjuryHandle())
|| CommonConstants.FOUR_STRING.equals(sf.getBirthHandle()) || CommonConstants.FOUR_STRING.equals(sf.getBirthHandle())
|| CommonConstants.FOUR_STRING.equals(sf.getUnemployHandle()) || CommonConstants.FOUR_STRING.equals(sf.getUnemployHandle())
|| CommonConstants.ONE_STRING.equals(sf.getBigailmentHandle()) || CommonConstants.ONE_STRING.equals(sf.getBigailmentHandle())
|| CommonConstants.FOUR_STRING.equals(sf.getBigailmentHandle())) || CommonConstants.FOUR_STRING.equals(sf.getBigailmentHandle()))
){ ){
vo.setSocialStatus(CommonConstants.TWO_STRING); vo.setSocialStatus(CommonConstants.TWO_STRING);
} }
...@@ -4529,7 +4531,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T ...@@ -4529,7 +4531,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
* @Date 14:34 2023/1/31 * @Date 14:34 2023/1/31
* @Param socialType 派单项(1养老 2医疗 3失业 4工伤 5生育 6大病),socialInfo 社保信息 type 0 派增 1 派减 * @Param socialType 派单项(1养老 2医疗 3失业 4工伤 5生育 6大病),socialInfo 社保信息 type 0 派增 1 派减
* @return * @return
**/ **/
private StringBuilder getHandleRemark(String socialType, TSocialInfo socialInfo, String type, TSocialFundInfo sf) { private StringBuilder getHandleRemark(String socialType, TSocialInfo socialInfo, String type, TSocialFundInfo sf) {
StringBuilder socialTypeRemark; StringBuilder socialTypeRemark;
socialTypeRemark = new StringBuilder(); socialTypeRemark = new StringBuilder();
...@@ -4565,7 +4567,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T ...@@ -4565,7 +4567,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
socialTypeRemark.append(CommonConstants.SOCIAL_HANDLE_TYPE[Integer.parseInt(st)]).append("、"); socialTypeRemark.append(CommonConstants.SOCIAL_HANDLE_TYPE[Integer.parseInt(st)]).append("、");
} }
} }
// 派减派单项处理 // 派减派单项处理
} else if (CommonConstants.ONE_STRING.equals(type)){ } else if (CommonConstants.ONE_STRING.equals(type)){
for (String st : stArr) { for (String st : stArr) {
// socialType (1养老 2医疗 3失业 4工伤 5生育 6大病) // socialType (1养老 2医疗 3失业 4工伤 5生育 6大病)
...@@ -4638,11 +4640,11 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T ...@@ -4638,11 +4640,11 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
// 有部分办理失败的多次派单 优化,存在办理失败的 更新为 部分办理失败 // 有部分办理失败的多次派单 优化,存在办理失败的 更新为 部分办理失败
if (CommonConstants.EIGHT_STRING.equals(sf.getSocialStatus()) && if (CommonConstants.EIGHT_STRING.equals(sf.getSocialStatus()) &&
(CommonConstants.FOUR_STRING.equals(sf.getPensionHandle()) (CommonConstants.FOUR_STRING.equals(sf.getPensionHandle())
|| CommonConstants.FOUR_STRING.equals(sf.getMedicalHandle()) || CommonConstants.FOUR_STRING.equals(sf.getMedicalHandle())
|| CommonConstants.FOUR_STRING.equals(sf.getUnemployHandle()) || CommonConstants.FOUR_STRING.equals(sf.getUnemployHandle())
|| CommonConstants.FOUR_STRING.equals(sf.getWorkInjuryHandle()) || CommonConstants.FOUR_STRING.equals(sf.getWorkInjuryHandle())
|| CommonConstants.FOUR_STRING.equals(sf.getBirthHandle()) || CommonConstants.FOUR_STRING.equals(sf.getBirthHandle())
|| CommonConstants.FOUR_STRING.equals(sf.getBigailmentHandle()))){ || CommonConstants.FOUR_STRING.equals(sf.getBigailmentHandle()))){
sf.setSocialStatus(CommonConstants.TWELVE_STRING); sf.setSocialStatus(CommonConstants.TWELVE_STRING);
sf.setSocialReduceStatus(CommonConstants.SIX_STRING); sf.setSocialReduceStatus(CommonConstants.SIX_STRING);
sf.setSocialReduceDate(null); sf.setSocialReduceDate(null);
...@@ -4697,7 +4699,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T ...@@ -4697,7 +4699,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
&& (Common.isEmpty(sf.getBigailmentHandle()) && (Common.isEmpty(sf.getBigailmentHandle())
|| CommonConstants.TWO_STRING.equals(sf.getBigailmentHandle()) || CommonConstants.TWO_STRING.equals(sf.getBigailmentHandle())
|| CommonConstants.THREE_STRING.equals(sf.getBigailmentHandle())) || CommonConstants.THREE_STRING.equals(sf.getBigailmentHandle()))
) { ) {
// 全部失败(或者为空):全部失败 // 全部失败(或者为空):全部失败
socialInfo.setHandleStatus(CommonConstants.TWO_STRING); socialInfo.setHandleStatus(CommonConstants.TWO_STRING);
socialInfo.setReduceCan(CommonConstants.dingleDigitStrArray[1]);//改成不可派减状态 socialInfo.setReduceCan(CommonConstants.dingleDigitStrArray[1]);//改成不可派减状态
...@@ -4710,7 +4712,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T ...@@ -4710,7 +4712,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
|| (Common.isEmpty(sf.getWorkInjuryHandle()) || CommonConstants.ZERO_STRING.equals(sf.getWorkInjuryHandle())) || (Common.isEmpty(sf.getWorkInjuryHandle()) || CommonConstants.ZERO_STRING.equals(sf.getWorkInjuryHandle()))
|| (Common.isEmpty(sf.getBirthHandle()) || CommonConstants.ZERO_STRING.equals(sf.getBirthHandle())) || (Common.isEmpty(sf.getBirthHandle()) || CommonConstants.ZERO_STRING.equals(sf.getBirthHandle()))
|| (Common.isNotNull(sf.getBigailmentHandle()) && CommonConstants.ZERO_STRING.equals(sf.getBigailmentHandle()) || (Common.isNotNull(sf.getBigailmentHandle()) && CommonConstants.ZERO_STRING.equals(sf.getBigailmentHandle())
)) { )) {
// 含有办理中的:办理中 // 含有办理中的:办理中
socialInfo.setHandleStatus(CommonConstants.FOUR_STRING); socialInfo.setHandleStatus(CommonConstants.FOUR_STRING);
socialInfo.setReduceCan(CommonConstants.dingleDigitStrArray[1]);//改成不可派减状态 socialInfo.setReduceCan(CommonConstants.dingleDigitStrArray[1]);//改成不可派减状态
...@@ -4758,9 +4760,9 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T ...@@ -4758,9 +4760,9 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
&& ( && (
((CommonConstants.FOUR_STRING.equals(socialInfo.getBigailmentHandle()) ((CommonConstants.FOUR_STRING.equals(socialInfo.getBigailmentHandle())
|| CommonConstants.TWO_STRING.equals(socialInfo.getBigailmentHandle())) || CommonConstants.TWO_STRING.equals(socialInfo.getBigailmentHandle()))
&& CommonConstants.ZERO_STRING.equals(socialInfo.getIsIllness()) && CommonConstants.ZERO_STRING.equals(socialInfo.getIsIllness())
) )
|| Common.isEmpty(socialInfo.getBigailmentHandle())) || Common.isEmpty(socialInfo.getBigailmentHandle()))
){ ){
if (partHandleStatus(socialInfo, sf, dis)) return; if (partHandleStatus(socialInfo, sf, dis)) return;
if (CommonConstants.TWO_STRING.equals(socialInfo.getPensionHandle()) if (CommonConstants.TWO_STRING.equals(socialInfo.getPensionHandle())
...@@ -4803,7 +4805,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T ...@@ -4803,7 +4805,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
&& ( ( && ( (
(CommonConstants.THREE_STRING.equals(socialInfo.getBigailmentHandle()) (CommonConstants.THREE_STRING.equals(socialInfo.getBigailmentHandle())
|| CommonConstants.TWO_STRING.equals(socialInfo.getBigailmentHandle())) || CommonConstants.TWO_STRING.equals(socialInfo.getBigailmentHandle()))
&& CommonConstants.ZERO_STRING.equals(socialInfo.getIsIllness())) && CommonConstants.ZERO_STRING.equals(socialInfo.getIsIllness()))
|| Common.isEmpty(socialInfo.getBigailmentHandle())) || Common.isEmpty(socialInfo.getBigailmentHandle()))
){ ){
// 针对增增减的情况 直接派减完成第二次派增后 无法继续办理第一次派单项的情况优化 2023-04-07 fxj // 针对增增减的情况 直接派减完成第二次派增后 无法继续办理第一次派单项的情况优化 2023-04-07 fxj
...@@ -5341,7 +5343,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T ...@@ -5341,7 +5343,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
* @Date 17:59 2022/7/27 * @Date 17:59 2022/7/27
* @Param * @Param
* @return * @return
**/ **/
private int getRecordRosterCount(SocialHandleSearchVo searchVo, String idStr) { private int getRecordRosterCount(SocialHandleSearchVo searchVo, String idStr) {
List<String> ids = new ArrayList<>(); List<String> ids = new ArrayList<>();
if (Common.isNotNull(idStr)){ if (Common.isNotNull(idStr)){
...@@ -5975,7 +5977,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T ...@@ -5975,7 +5977,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
* @Date 15:46 2023/5/8 * @Date 15:46 2023/5/8
* @Param * @Param
* @return * @return
**/ **/
@Transactional(rollbackFor = Exception.class) @Transactional(rollbackFor = Exception.class)
@ShardingTransactionType(TransactionType.BASE) @ShardingTransactionType(TransactionType.BASE)
@Override @Override
...@@ -6048,7 +6050,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T ...@@ -6048,7 +6050,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
* @Date 16:45 2023/5/8 * @Date 16:45 2023/5/8
* @Param * @Param
* @return * @return
**/ **/
public void fundImportHandle(List<FundImportHandleVo> excelVOList, List<ErrorMessage> errorMessageList, public void fundImportHandle(List<FundImportHandleVo> excelVOList, List<ErrorMessage> errorMessageList,
YifuUser user,TDispatchInfo dispatchInfo,ConcurrentHashMap<String, String> map, boolean isAutoFlag) { YifuUser user,TDispatchInfo dispatchInfo,ConcurrentHashMap<String, String> map, boolean isAutoFlag) {
if (!Common.isNotNull(excelVOList)) { if (!Common.isNotNull(excelVOList)) {
...@@ -7408,7 +7410,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T ...@@ -7408,7 +7410,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
//第三列 //第三列
//第四列 //第四列
int b=Double.valueOf(a).intValue(); int b=Double.valueOf(a).intValue();
String c=int2big(b); String c=int2big(b);
//第五列 //第五列
list.add(Lists.newArrayList(c, c)); list.add(Lists.newArrayList(c, c));
list.add(Lists.newArrayList(c, c)); list.add(Lists.newArrayList(c, c));
...@@ -7522,7 +7524,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T ...@@ -7522,7 +7524,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
* @Date 15:58 2024/12/10 * @Date 15:58 2024/12/10
* @Param socialId:社保明细ID type: 1 社保增 2社保减 3 医保增 4 医保减 * @Param socialId:社保明细ID type: 1 社保增 2社保减 3 医保增 4 医保减
* @return * @return
**/ **/
@Override @Override
public R<URL> doExportRoster(String socialId, String type,String unitCreditCode) { public R<URL> doExportRoster(String socialId, String type,String unitCreditCode) {
SocialHandleSearchVo searchVo = new SocialHandleSearchVo(); SocialHandleSearchVo searchVo = new SocialHandleSearchVo();
...@@ -7533,11 +7535,6 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T ...@@ -7533,11 +7535,6 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
if (Common.isEmpty(socialInfo)){ if (Common.isEmpty(socialInfo)){
return R.failed(CommonConstants.PARAM_IS_NOT_ERROR); return R.failed(CommonConstants.PARAM_IS_NOT_ERROR);
} }
//查询户名称对应的户配置 以获取公章信息
SysBaseSetInfo socialBaseSet = baseSetMapper.selectById(socialInfo.getSocialHousehold());
if (Common.isEmpty(socialBaseSet)){
return R.failed(CommonConstants.PARAM_IS_NOT_ERROR);
}
searchVo.setSocialHouseholdName(socialInfo.getSocialHouseholdName()); searchVo.setSocialHouseholdName(socialInfo.getSocialHouseholdName());
//searchVo.setDisMonth(DateUtil.getThisMonth()); //searchVo.setDisMonth(DateUtil.getThisMonth());
searchVo.setDisMonth("202410"); searchVo.setDisMonth("202410");
...@@ -7561,7 +7558,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T ...@@ -7561,7 +7558,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
* @Date 16:29 2024/12/10 * @Date 16:29 2024/12/10
* @Param * @Param
* @return * @return
**/ **/
public R<URL> doExportRosterMedical(SocialHandleSearchVo searchVo,String type){ public R<URL> doExportRosterMedical(SocialHandleSearchVo searchVo,String type){
String fileName = DispatchConstants.SOCIAL_MEDICAL_EXPORT + searchVo.getSocialHouseholdName() + "_" + DateUtil.getThisMonth() + CommonConstants.XLSX; String fileName = DispatchConstants.SOCIAL_MEDICAL_EXPORT + searchVo.getSocialHouseholdName() + "_" + DateUtil.getThisMonth() + CommonConstants.XLSX;
//获取要导出的列表 //获取要导出的列表
...@@ -7711,7 +7708,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T ...@@ -7711,7 +7708,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
* @Date 16:28 2024/12/10 * @Date 16:28 2024/12/10
* @Param * @Param
* @return * @return
**/ **/
public R<URL> doExportRosterSocial(SocialHandleSearchVo searchVo,String type){ public R<URL> doExportRosterSocial(SocialHandleSearchVo searchVo,String type){
String fileName = DispatchConstants.SOCIAL_MEDICAL_EXPORT + searchVo.getSocialHouseholdName() + "_" + DateUtil.getThisMonth() + CommonConstants.XLS; String fileName = DispatchConstants.SOCIAL_MEDICAL_EXPORT + searchVo.getSocialHouseholdName() + "_" + DateUtil.getThisMonth() + CommonConstants.XLS;
String projectRoot = System.getProperty("user.dir"); String projectRoot = System.getProperty("user.dir");
...@@ -7878,12 +7875,6 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T ...@@ -7878,12 +7875,6 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
excelWriter.finish(); excelWriter.finish();
} }
//读取文件 生成电子章 //读取文件 生成电子章
FileInputStream inputStream = new FileInputStream(filePath);
String outPath = projectRoot+"//out_"+fileName;
FileOutputStream fileOUt = new FileOutputStream(outPath);
URL url =ossUtil.getObjectUrl(null,"");
InputStream inStream = url.openStream();
excelMergeImage.addPictureToExcel(inputStream,inStream,fileOUt,0);
}catch (Exception e){ }catch (Exception e){
log.error("执行异常" ,e); log.error("执行异常" ,e);
......
package com.yifu.cloud.plus.v1.yifu.social.util;
import org.apache.commons.compress.utils.IOUtils;
import org.apache.poi.hssf.usermodel.HSSFWorkbook;
import org.apache.poi.ss.usermodel.*;
import org.apache.poi.xssf.usermodel.XSSFWorkbook;
import org.springframework.stereotype.Component;
import javax.imageio.ImageIO;
import java.awt.Color;
import java.awt.*;
import java.awt.image.BufferedImage;
import java.io.*;
/**
* @Author fxj
* @Date 2024/12/9
* @Description
* @Version 1.0
*/
@Component
public class ExcelMergeImage {
public static void main(String[] args) throws IOException {
String excelFilePath = "E:\\test\\11\\1.xls";
String imageFilePath = "E:\\test\\11\\1.png";
//convertExcelToImage(excelFilePath, imageFilePath);
//stampAdder();
}
public static void convertExcelToImage(String excelFilePath, String imageFilePath) throws IOException {
FileInputStream fis = new FileInputStream(new File(excelFilePath));
Workbook workbook;
if (excelFilePath.endsWith(".xls")) {
workbook = new HSSFWorkbook(fis); // For Excel 97-2003 (.xls) format
} else if (excelFilePath.endsWith(".xlsx")) {
workbook = new XSSFWorkbook(fis); // For Excel 2007 and later (.xlsx) format
} else {
throw new IllegalArgumentException("Unsupported file type");
}
Sheet sheet = workbook.getSheetAt(0);
int rowCount = 16; //sheet.getPhysicalNumberOfRows();
int colCount = 25;//sheet.getRow(0).getPhysicalNumberOfCells();
BufferedImage image = new BufferedImage(896, 424, BufferedImage.TYPE_INT_RGB);
Graphics2D graphics = image.createGraphics();
for (int i = 0; i < rowCount; i++) {
Row row = sheet.getRow(i);
for (int j = 0; j < colCount; j++) {
Cell cell = row.getCell(j);
if (cell != null) {
graphics.fillRect(j*150, i*47, 896, 424);
graphics.setColor(Color.black); // 设置边框颜色
graphics.drawRect(j*150, i*47, 896, 424);
String cellValue = getCellValueAsString(cell);
graphics.drawString(cellValue, j * 150+10, i * 45+30);
}
}
}
graphics.dispose();
ImageIO.write(image, "png", new File(imageFilePath));
workbook.close();
fis.close();
}
private static String getCellValueAsString(Cell cell) {
String cellValue = "";
if (cell != null) {
switch (cell.getCellType()) {
case STRING:
cellValue = cell.getStringCellValue();
break;
case NUMERIC:
cellValue = String.valueOf(cell.getNumericCellValue());
break;
case BOOLEAN:
cellValue = String.valueOf(cell.getBooleanCellValue());
break;
case FORMULA:
cellValue = cell.getCellFormula();
break;
default:
cellValue = "";
}
}
return cellValue;
}
/**
* @Author fxj
* @Description 03格式excel添加电子印章或图片
* @Date 15:32 2024/12/9
* @Param
* @return
**/
public FileOutputStream addPictureToExcel(FileInputStream fis,
InputStream imageIs,
FileOutputStream fileOut,
int SheetNum){
Workbook workbook = null;
try {
workbook = new HSSFWorkbook(fis);
Sheet sheet = workbook.getSheetAt(SheetNum);
// 在合适的位置添加印章
Drawing<?> drawing = sheet.createDrawingPatriarch();
CreationHelper helper = workbook.getCreationHelper();
ClientAnchor anchor = helper.createClientAnchor();
anchor.setCol1(2);
anchor.setRow1(0);
anchor.setCol2(4);
anchor.setRow2(7);
// 添加印章图片
int pictureIdx = workbook.addPicture(IOUtils.toByteArray(imageIs), Workbook.PICTURE_TYPE_PNG);
drawing.createPicture(anchor, pictureIdx);
workbook.write(fileOut);
}catch (Exception e){
e.printStackTrace();
}finally {
try {
if (null != fis){
fis.close();
}
if (null != workbook){
workbook.close();
}
} catch (IOException e) {
e.printStackTrace();
}
}
return fileOut;
}
}
package com.yifu.cloud.plus.v1.yifu.social.util;
import com.spire.xls.Workbook;
import com.spire.xls.Worksheet;
import com.yifu.cloud.plus.v1.yifu.common.core.constant.CommonConstants;
import com.yifu.cloud.plus.v1.yifu.common.core.util.OSSUtil;
import com.yifu.cloud.plus.v1.yifu.common.core.util.R;
import org.springframework.stereotype.Component;
import java.io.File;
import java.io.InputStream;
import java.net.URL;
/**
* @Author fxj
* @Date 2024/12/9
* @Description excel 转换为 图片 并上传阿里云 (上传后自动删除生成的图片文件)
* @Version 1.0
*/
@Component
public class ExcelToImage {
public R<URL> excelToImg(InputStream inputStream ,OSSUtil ossUtil){
String projectRoot = System.getProperty("user.dir");
//加载Excel工作表
Workbook wb = new Workbook();
wb.loadFromHtml(inputStream);
//获取工作表
Worksheet sheet = wb.getWorksheets().get(0);
//调用方法将Excel工作表保存为图片
sheet.saveToImage(projectRoot+"\\ToImg.png");
File file = null;
try {
file = new File(projectRoot+"\\ToImg.png");
if (file.exists()){
String key = System.currentTimeMillis() + file.getName();
if (ossUtil.uploadFileByFile(file,key,null)){
return R.ok(ossUtil.getObjectUrl(null,key));
}else {
return R.failed(CommonConstants.RESULT_DATA_FAIL+":ExcelToImage上传OSS异常");
}
}
} catch (Exception e) {
e.printStackTrace();
return R.failed(CommonConstants.RESULT_DATA_FAIL+":ExcelToImage转换异常-"+e.getMessage());
} finally {
if (file.exists()){
file.delete();
}
}
return R.failed(CommonConstants.RESULT_DATA_FAIL);
//调用方法,将指定Excel单元格数据范围保存为图片
//sheet.saveToImage("ToImg2.png",8,1,30,7);
/*//调用方法将Excel保存为HTML
sheet.saveToHtml("ToHtml.html");
//调用方法将Excel保存为XPS
sheet.saveToFile("ToXPS.xps", String.valueOf(FileFormat.XPS));
//调用方法将Excel保存为CSV
sheet.saveToFile("ToCSV.csv", String.valueOf(FileFormat.CSV));
//调用方法将Excel保存为XML
sheet.saveToFile("ToXML.xml", String.valueOf(FileFormat.XML));
//调用方法将Excel保存为PostScript
sheet.saveToFile("ToPostScript.postscript", String.valueOf(FileFormat.PostScript));
//调用方法将Excel保存为PCL
sheet.saveToFile("ToPCL.pcl", String.valueOf(FileFormat.PCL));*/
}
}
...@@ -23,90 +23,90 @@ ...@@ -23,90 +23,90 @@
<mapper namespace="com.yifu.cloud.plus.v1.yifu.social.mapper.TDispatchInfoMapper"> <mapper namespace="com.yifu.cloud.plus.v1.yifu.social.mapper.TDispatchInfoMapper">
<resultMap id="tDispatchInfoMap" type="com.yifu.cloud.plus.v1.yifu.social.entity.TDispatchInfo"> <resultMap id="tDispatchInfoMap" type="com.yifu.cloud.plus.v1.yifu.social.entity.TDispatchInfo">
<id property="id" column="ID"/> <id property="id" column="ID"/>
<result property="empId" column="EMP_ID"/> <result property="empId" column="EMP_ID"/>
<result property="empName" column="EMP_NAME"/> <result property="empName" column="EMP_NAME"/>
<result property="empNo" column="EMP_NO"/> <result property="empNo" column="EMP_NO"/>
<result property="empIdcard" column="EMP_IDCARD"/> <result property="empIdcard" column="EMP_IDCARD"/>
<result property="empType" column="EMP_TYPE"/> <result property="empType" column="EMP_TYPE"/>
<result property="empMobile" column="EMP_MOBILE"/> <result property="empMobile" column="EMP_MOBILE"/>
<result property="empNational" column="EMP_NATIONAL"/> <result property="empNational" column="EMP_NATIONAL"/>
<result property="status" column="STATUS"/> <result property="status" column="STATUS"/>
<result property="type" column="TYPE"/> <result property="type" column="TYPE"/>
<result property="socialId" column="SOCIAL_ID"/> <result property="socialId" column="SOCIAL_ID"/>
<result property="fundId" column="FUND_ID"/> <result property="fundId" column="FUND_ID"/>
<result property="typeSub" column="TYPE_SUB"/> <result property="typeSub" column="TYPE_SUB"/>
<result property="processInstId" column="PROCESS_INST_ID"/> <result property="processInstId" column="PROCESS_INST_ID"/>
<result property="settleDomain" column="SETTLE_DOMAIN"/> <result property="settleDomain" column="SETTLE_DOMAIN"/>
<result property="deleteFlag" column="DELETE_FLAG"/> <result property="deleteFlag" column="DELETE_FLAG"/>
<result property="socialReduceDate" column="SOCIAL_REDUCE_DATE"/> <result property="socialReduceDate" column="SOCIAL_REDUCE_DATE"/>
<result property="fundReduceDate" column="FUND_REDUCE_DATE"/> <result property="fundReduceDate" column="FUND_REDUCE_DATE"/>
<result property="leaveDate" column="LEAVE_DATE"/> <result property="leaveDate" column="LEAVE_DATE"/>
<result property="reduceReason" column="REDUCE_REASON"/> <result property="reduceReason" column="REDUCE_REASON"/>
<result property="reduceRemark" column="REDUCE_REMARK"/> <result property="reduceRemark" column="REDUCE_REMARK"/>
<result property="belongUnit" column="BELONG_UNIT"/> <result property="belongUnit" column="BELONG_UNIT"/>
<result property="currentOperator" column="CURRENT_OPERATOR"/> <result property="currentOperator" column="CURRENT_OPERATOR"/>
<result property="dispatchIdBak" column="DISPATCH_ID_BAK"/> <result property="dispatchIdBak" column="DISPATCH_ID_BAK"/>
<result property="contractStart" column="CONTRACT_START"/> <result property="contractStart" column="CONTRACT_START"/>
<result property="contractEnd" column="CONTRACT_END"/> <result property="contractEnd" column="CONTRACT_END"/>
<result property="contractTerm" column="CONTRACT_TERM"/> <result property="contractTerm" column="CONTRACT_TERM"/>
<result property="empRegisType" column="EMP_REGIS_TYPE"/> <result property="empRegisType" column="EMP_REGIS_TYPE"/>
<result property="fileAddr" column="FILE_ADDR"/> <result property="fileAddr" column="FILE_ADDR"/>
<result property="post" column="POST"/> <result property="post" column="POST"/>
<result property="trustRemark" column="TRUST_REMARK"/> <result property="trustRemark" column="TRUST_REMARK"/>
<result property="fileProvince" column="FILE_PROVINCE"/> <result property="fileProvince" column="FILE_PROVINCE"/>
<result property="fileCity" column="FILE_CITY"/> <result property="fileCity" column="FILE_CITY"/>
<result property="fileTown" column="FILE_TOWN"/> <result property="fileTown" column="FILE_TOWN"/>
<result property="contractType" column="CONTRACT_TYPE"/> <result property="contractType" column="CONTRACT_TYPE"/>
<result property="socialHandleStatus" column="SOCIAL_HANDLE_STATUS"/> <result property="socialHandleStatus" column="SOCIAL_HANDLE_STATUS"/>
<result property="fundHandleStatus" column="FUND_HANDLE_STATUS"/> <result property="fundHandleStatus" column="FUND_HANDLE_STATUS"/>
<result property="handleRemark" column="HANDLE_REMARK"/> <result property="handleRemark" column="HANDLE_REMARK"/>
<result property="auditRemark" column="AUDIT_REMARK"/> <result property="auditRemark" column="AUDIT_REMARK"/>
<result property="fundHandleRemark" column="FUND_HANDLE_REMARK"/> <result property="fundHandleRemark" column="FUND_HANDLE_REMARK"/>
<result property="socialHandleRemark" column="SOCIAL_HANDLE_REMARK"/> <result property="socialHandleRemark" column="SOCIAL_HANDLE_REMARK"/>
<result property="socialProvince" column="SOCIAL_PROVINCE"/> <result property="socialProvince" column="SOCIAL_PROVINCE"/>
<result property="socialCity" column="SOCIAL_CITY"/> <result property="socialCity" column="SOCIAL_CITY"/>
<result property="socialTown" column="SOCIAL_TOWN"/> <result property="socialTown" column="SOCIAL_TOWN"/>
<result property="fundProvince" column="FUND_PROVINCE"/> <result property="fundProvince" column="FUND_PROVINCE"/>
<result property="fundCity" column="FUND_CITY"/> <result property="fundCity" column="FUND_CITY"/>
<result property="fundTown" column="FUND_TOWN"/> <result property="fundTown" column="FUND_TOWN"/>
<result property="auditUser" column="AUDIT_USER"/> <result property="auditUser" column="AUDIT_USER"/>
<result property="auditUserName" column="AUDIT_USER_NAME"/> <result property="auditUserName" column="AUDIT_USER_NAME"/>
<result property="auditTime" column="AUDIT_TIME"/> <result property="auditTime" column="AUDIT_TIME"/>
<result property="workingHours" column="WORKING_HOURS"/> <result property="workingHours" column="WORKING_HOURS"/>
<result property="createBy" column="CREATE_BY"/> <result property="createBy" column="CREATE_BY"/>
<result property="updateBy" column="UPDATE_BY"/> <result property="updateBy" column="UPDATE_BY"/>
<result property="createName" column="CREATE_NAME"/> <result property="createName" column="CREATE_NAME"/>
<result property="updateTime" column="UPDATE_TIME"/> <result property="updateTime" column="UPDATE_TIME"/>
<result property="organName" column="ORGAN_NAME"/> <result property="organName" column="ORGAN_NAME"/>
<result property="dispatchItem" column="DISPATCH_ITEM"/> <result property="dispatchItem" column="DISPATCH_ITEM"/>
<result property="settleDomainName" column="SETTLE_DOMAIN_NAME"/> <result property="settleDomainName" column="SETTLE_DOMAIN_NAME"/>
<result property="settleDomainCode" column="SETTLE_DOMAIN_CODE"/> <result property="settleDomainCode" column="SETTLE_DOMAIN_CODE"/>
<result property="belongUnitName" column="BELONG_UNIT_NAME"/> <result property="belongUnitName" column="BELONG_UNIT_NAME"/>
<result property="dispatchCode" column="DISPATCH_CODE"/> <result property="dispatchCode" column="DISPATCH_CODE"/>
<result property="againDispatchCode" column="AGAIN_DISPATCH_CODE"/> <result property="againDispatchCode" column="AGAIN_DISPATCH_CODE"/>
<result property="contractSubName" column="CONTRACT_SUB_NAME"/> <result property="contractSubName" column="CONTRACT_SUB_NAME"/>
<result property="contractId" column="CONTRACT_ID"/> <result property="contractId" column="CONTRACT_ID"/>
<result property="educationName" column="EDUCATION_NAME"/> <result property="educationName" column="EDUCATION_NAME"/>
<result property="tryPeriod" column="TRY_PERIOD"/> <result property="tryPeriod" column="TRY_PERIOD"/>
<result property="idCardProvince" column="ID_CARD_PROVINCE"/> <result property="idCardProvince" column="ID_CARD_PROVINCE"/>
<result property="idCardCity" column="ID_CARD_CITY"/> <result property="idCardCity" column="ID_CARD_CITY"/>
<result property="idCardTown" column="ID_CARD_TOWN"/> <result property="idCardTown" column="ID_CARD_TOWN"/>
<result property="idCardAddress" column="ID_CARD_ADDRESS"/> <result property="idCardAddress" column="ID_CARD_ADDRESS"/>
<result property="applyNo" column="APPLY_NO"/> <result property="applyNo" column="APPLY_NO"/>
<result property="createTime" column="CREATE_TIME"/> <result property="createTime" column="CREATE_TIME"/>
<result property="orderId" column="ORDER_ID"/> <result property="orderId" column="ORDER_ID"/>
<result property="schoolName" column="SCHOOL_NAME"/> <result property="schoolName" column="SCHOOL_NAME"/>
<result property="major" column="MAJOR"/> <result property="major" column="MAJOR"/>
<result property="firstPayTime" column="FIRST_PAY_TIME"/> <result property="firstPayTime" column="FIRST_PAY_TIME"/>
<result property="graduationTime" column="GRADUATION_TIME"/> <result property="graduationTime" column="GRADUATION_TIME"/>
<result property="autoFlag" column="AUTO_FLAG"/> <result property="autoFlag" column="AUTO_FLAG"/>
</resultMap> </resultMap>
<resultMap id="dispatchPageMap" type="com.yifu.cloud.plus.v1.yifu.social.vo.TDispatchInfoPageVo" extends="tDispatchInfoMap"> <resultMap id="dispatchPageMap" type="com.yifu.cloud.plus.v1.yifu.social.vo.TDispatchInfoPageVo" extends="tDispatchInfoMap">
<result property="providentHouseholdName" column="PROVIDENT_HOUSEHOLD_NAME"/> <result property="providentHouseholdName" column="PROVIDENT_HOUSEHOLD_NAME"/>
<result property="socialHouseholdName" column="SOCIAL_HOUSEHOLD_NAME"/> <result property="socialHouseholdName" column="SOCIAL_HOUSEHOLD_NAME"/>
...@@ -356,7 +356,7 @@ ...@@ -356,7 +356,7 @@
<result property="graduationTime" column="GRADUATION_TIME"/> <result property="graduationTime" column="GRADUATION_TIME"/>
</resultMap> </resultMap>
<sql id="Base_Column_List"> <sql id="Base_Column_List">
a.ID, a.ID,
a.EMP_ID, a.EMP_ID,
a.EMP_NAME, a.EMP_NAME,
...@@ -435,239 +435,239 @@ ...@@ -435,239 +435,239 @@
a.MAJOR, a.MAJOR,
a.FIRST_PAY_TIME, a.FIRST_PAY_TIME,
a.GRADUATION_TIME,a.AUTO_FLAG a.GRADUATION_TIME,a.AUTO_FLAG
</sql> </sql>
<sql id="tDispatchInfo_where"> <sql id="tDispatchInfo_where">
<if test="tDispatchInfo != null"> <if test="tDispatchInfo != null">
<if test="tDispatchInfo.dispatchItems != null and tDispatchInfo.dispatchItems.size >0"> <if test="tDispatchInfo.dispatchItems != null and tDispatchInfo.dispatchItems.size >0">
AND AND
<foreach item="item" index="index" collection="tDispatchInfo.dispatchItems" open="(" separator="or" close=")"> <foreach item="item" index="index" collection="tDispatchInfo.dispatchItems" open="(" separator="or" close=")">
INSTR(a.DISPATCH_ITEM,#{item}) INSTR(a.DISPATCH_ITEM,#{item})
</foreach> </foreach>
</if> </if>
<if test="tDispatchInfo.idList != null and tDispatchInfo.idList.size >0"> <if test="tDispatchInfo.idList != null and tDispatchInfo.idList.size >0">
AND a.ID in AND a.ID in
<foreach item="idStr" index="index" collection="tDispatchInfo.idList" open="(" separator="," close=")"> <foreach item="idStr" index="index" collection="tDispatchInfo.idList" open="(" separator="," close=")">
#{idStr} #{idStr}
</foreach> </foreach>
</if> </if>
<if test="tDispatchInfo.empTypeList != null and tDispatchInfo.empTypeList.length>0"> <if test="tDispatchInfo.empTypeList != null and tDispatchInfo.empTypeList.length>0">
AND a.EMP_TYPE IN AND a.EMP_TYPE IN
<foreach collection="tDispatchInfo.empTypeList" item="item" index="index" open="(" separator="," close=")"> <foreach collection="tDispatchInfo.empTypeList" item="item" index="index" open="(" separator="," close=")">
#{item} #{item}
</foreach> </foreach>
</if> </if>
<if test="tDispatchInfo.autoFlag != null and tDispatchInfo.autoFlag.trim() != ''"> <if test="tDispatchInfo.autoFlag != null and tDispatchInfo.autoFlag.trim() != ''">
AND a.AUTO_FLAG = #{tDispatchInfo.autoFlag} AND a.AUTO_FLAG = #{tDispatchInfo.autoFlag}
</if> </if>
<if test="tDispatchInfo.id != null and tDispatchInfo.id.trim() != ''"> <if test="tDispatchInfo.id != null and tDispatchInfo.id.trim() != ''">
AND a.ID = #{tDispatchInfo.id} AND a.ID = #{tDispatchInfo.id}
</if> </if>
<if test="tDispatchInfo.orderId != null and tDispatchInfo.orderId.trim() != ''"> <if test="tDispatchInfo.orderId != null and tDispatchInfo.orderId.trim() != ''">
AND a.ORDER_ID = #{tDispatchInfo.orderId} AND a.ORDER_ID = #{tDispatchInfo.orderId}
</if> </if>
<if test="tDispatchInfo.empId != null and tDispatchInfo.empId.trim() != ''"> <if test="tDispatchInfo.empId != null and tDispatchInfo.empId.trim() != ''">
AND a.EMP_ID = #{tDispatchInfo.empId} AND a.EMP_ID = #{tDispatchInfo.empId}
</if> </if>
<if test="tDispatchInfo.empName != null and tDispatchInfo.empName.trim() != ''"> <if test="tDispatchInfo.empName != null and tDispatchInfo.empName.trim() != ''">
AND a.EMP_NAME like concat('%',#{tDispatchInfo.empName},'%') AND a.EMP_NAME like concat('%',#{tDispatchInfo.empName},'%')
</if> </if>
<if test="tDispatchInfo.empNo != null and tDispatchInfo.empNo.trim() != ''"> <if test="tDispatchInfo.empNo != null and tDispatchInfo.empNo.trim() != ''">
AND a.EMP_NO = #{tDispatchInfo.empNo} AND a.EMP_NO = #{tDispatchInfo.empNo}
</if> </if>
<if test="tDispatchInfo.empIdcard != null and tDispatchInfo.empIdcard.trim() != ''"> <if test="tDispatchInfo.empIdcard != null and tDispatchInfo.empIdcard.trim() != ''">
AND a.EMP_IDCARD like concat('%',#{tDispatchInfo.empIdcard},'%') AND a.EMP_IDCARD like concat('%',#{tDispatchInfo.empIdcard},'%')
</if> </if>
<if test="tDispatchInfo.empType != null and tDispatchInfo.empType.trim() != ''"> <if test="tDispatchInfo.empType != null and tDispatchInfo.empType.trim() != ''">
AND a.EMP_TYPE in #{tDispatchInfo.empType} AND a.EMP_TYPE in #{tDispatchInfo.empType}
</if> </if>
<if test="tDispatchInfo.empMobile != null and tDispatchInfo.empMobile.trim() != ''"> <if test="tDispatchInfo.empMobile != null and tDispatchInfo.empMobile.trim() != ''">
AND a.EMP_MOBILE = #{tDispatchInfo.empMobile} AND a.EMP_MOBILE = #{tDispatchInfo.empMobile}
</if> </if>
<if test="tDispatchInfo.empNational != null and tDispatchInfo.empNational.trim() != ''"> <if test="tDispatchInfo.empNational != null and tDispatchInfo.empNational.trim() != ''">
AND a.EMP_NATIONAL = #{tDispatchInfo.empNational} AND a.EMP_NATIONAL = #{tDispatchInfo.empNational}
</if> </if>
<if test="tDispatchInfo.status != null and tDispatchInfo.status.trim() != ''"> <if test="tDispatchInfo.status != null and tDispatchInfo.status.trim() != ''">
AND a.STATUS = #{tDispatchInfo.status} AND a.STATUS = #{tDispatchInfo.status}
</if> </if>
<if test="tDispatchInfo.type != null and tDispatchInfo.type.trim() != ''"> <if test="tDispatchInfo.type != null and tDispatchInfo.type.trim() != ''">
AND a.TYPE = #{tDispatchInfo.type} AND a.TYPE = #{tDispatchInfo.type}
</if> </if>
<if test="tDispatchInfo.socialId != null and tDispatchInfo.socialId.trim() != ''"> <if test="tDispatchInfo.socialId != null and tDispatchInfo.socialId.trim() != ''">
AND a.SOCIAL_ID = #{tDispatchInfo.socialId} AND a.SOCIAL_ID = #{tDispatchInfo.socialId}
</if> </if>
<if test="tDispatchInfo.fundId != null and tDispatchInfo.fundId.trim() != ''"> <if test="tDispatchInfo.fundId != null and tDispatchInfo.fundId.trim() != ''">
AND a.FUND_ID = #{tDispatchInfo.fundId} AND a.FUND_ID = #{tDispatchInfo.fundId}
</if> </if>
<if test="tDispatchInfo.typeSub != null and tDispatchInfo.typeSub.trim() != ''"> <if test="tDispatchInfo.typeSub != null and tDispatchInfo.typeSub.trim() != ''">
AND a.TYPE_SUB = #{tDispatchInfo.typeSub} AND a.TYPE_SUB = #{tDispatchInfo.typeSub}
</if> </if>
<if test="tDispatchInfo.processInstId != null and tDispatchInfo.processInstId.trim() != ''"> <if test="tDispatchInfo.processInstId != null and tDispatchInfo.processInstId.trim() != ''">
AND a.PROCESS_INST_ID = #{tDispatchInfo.processInstId} AND a.PROCESS_INST_ID = #{tDispatchInfo.processInstId}
</if> </if>
<if test="tDispatchInfo.settleDomain != null and tDispatchInfo.settleDomain.trim() != ''"> <if test="tDispatchInfo.settleDomain != null and tDispatchInfo.settleDomain.trim() != ''">
AND a.SETTLE_DOMAIN = #{tDispatchInfo.settleDomain} AND a.SETTLE_DOMAIN = #{tDispatchInfo.settleDomain}
</if> </if>
<if test="tDispatchInfo.settleDomainName != null and tDispatchInfo.settleDomainName.trim() != ''"> <if test="tDispatchInfo.settleDomainName != null and tDispatchInfo.settleDomainName.trim() != ''">
AND a.SETTLE_DOMAIN_NAME like CONCAT(#{tDispatchInfo.settleDomainName}, '%') AND a.SETTLE_DOMAIN_NAME like CONCAT(#{tDispatchInfo.settleDomainName}, '%')
</if> </if>
<if test="tDispatchInfo.settleDomainCode != null and tDispatchInfo.settleDomainCode.trim() != ''"> <if test="tDispatchInfo.settleDomainCode != null and tDispatchInfo.settleDomainCode.trim() != ''">
AND a.SETTLE_DOMAIN_CODE = #{tDispatchInfo.settleDomainCode} AND a.SETTLE_DOMAIN_CODE = #{tDispatchInfo.settleDomainCode}
</if> </if>
<if test="tDispatchInfo.deleteFlag != null and tDispatchInfo.deleteFlag.trim() != ''"> <if test="tDispatchInfo.deleteFlag != null and tDispatchInfo.deleteFlag.trim() != ''">
AND a.DELETE_FLAG = #{tDispatchInfo.deleteFlag} AND a.DELETE_FLAG = #{tDispatchInfo.deleteFlag}
</if> </if>
<if test="tDispatchInfo.socialReduceDate != null"> <if test="tDispatchInfo.socialReduceDate != null">
AND a.SOCIAL_REDUCE_DATE = #{tDispatchInfo.socialReduceDate} AND a.SOCIAL_REDUCE_DATE = #{tDispatchInfo.socialReduceDate}
</if> </if>
<if test="tDispatchInfo.fundReduceDate != null"> <if test="tDispatchInfo.fundReduceDate != null">
AND a.FUND_REDUCE_DATE = #{tDispatchInfo.fundReduceDate} AND a.FUND_REDUCE_DATE = #{tDispatchInfo.fundReduceDate}
</if> </if>
<if test="tDispatchInfo.leaveDate != null"> <if test="tDispatchInfo.leaveDate != null">
AND a.LEAVE_DATE = #{tDispatchInfo.leaveDate} AND a.LEAVE_DATE = #{tDispatchInfo.leaveDate}
</if> </if>
<if test="tDispatchInfo.reduceReason != null and tDispatchInfo.reduceReason.trim() != ''"> <if test="tDispatchInfo.reduceReason != null and tDispatchInfo.reduceReason.trim() != ''">
AND a.REDUCE_REASON = #{tDispatchInfo.reduceReason} AND a.REDUCE_REASON = #{tDispatchInfo.reduceReason}
</if> </if>
<if test="tDispatchInfo.reduceRemark != null and tDispatchInfo.reduceRemark.trim() != ''"> <if test="tDispatchInfo.reduceRemark != null and tDispatchInfo.reduceRemark.trim() != ''">
AND a.REDUCE_REMARK = #{tDispatchInfo.reduceRemark} AND a.REDUCE_REMARK = #{tDispatchInfo.reduceRemark}
</if> </if>
<if test="tDispatchInfo.belongUnit != null and tDispatchInfo.belongUnit.trim() != ''"> <if test="tDispatchInfo.belongUnit != null and tDispatchInfo.belongUnit.trim() != ''">
AND a.BELONG_UNIT = #{tDispatchInfo.belongUnit} AND a.BELONG_UNIT = #{tDispatchInfo.belongUnit}
</if> </if>
<if test="tDispatchInfo.currentOperator != null and tDispatchInfo.currentOperator.trim() != ''"> <if test="tDispatchInfo.currentOperator != null and tDispatchInfo.currentOperator.trim() != ''">
AND a.CURRENT_OPERATOR = #{tDispatchInfo.currentOperator} AND a.CURRENT_OPERATOR = #{tDispatchInfo.currentOperator}
</if> </if>
<if test="tDispatchInfo.dispatchIdBak != null and tDispatchInfo.dispatchIdBak.trim() != ''"> <if test="tDispatchInfo.dispatchIdBak != null and tDispatchInfo.dispatchIdBak.trim() != ''">
AND a.DISPATCH_ID_BAK = #{tDispatchInfo.dispatchIdBak} AND a.DISPATCH_ID_BAK = #{tDispatchInfo.dispatchIdBak}
</if> </if>
<if test="tDispatchInfo.contractStart != null"> <if test="tDispatchInfo.contractStart != null">
AND a.CONTRACT_START = #{tDispatchInfo.contractStart} AND a.CONTRACT_START = #{tDispatchInfo.contractStart}
</if> </if>
<if test="tDispatchInfo.contractEnd != null"> <if test="tDispatchInfo.contractEnd != null">
AND a.CONTRACT_END = #{tDispatchInfo.contractEnd} AND a.CONTRACT_END = #{tDispatchInfo.contractEnd}
</if> </if>
<if test="tDispatchInfo.contractTerm != null"> <if test="tDispatchInfo.contractTerm != null">
AND a.CONTRACT_TERM = #{tDispatchInfo.contractTerm} AND a.CONTRACT_TERM = #{tDispatchInfo.contractTerm}
</if> </if>
<if test="tDispatchInfo.empRegisType != null and tDispatchInfo.empRegisType.trim() != ''"> <if test="tDispatchInfo.empRegisType != null and tDispatchInfo.empRegisType.trim() != ''">
AND a.EMP_REGIS_TYPE = #{tDispatchInfo.empRegisType} AND a.EMP_REGIS_TYPE = #{tDispatchInfo.empRegisType}
</if> </if>
<if test="tDispatchInfo.fileAddr != null and tDispatchInfo.fileAddr.trim() != ''"> <if test="tDispatchInfo.fileAddr != null and tDispatchInfo.fileAddr.trim() != ''">
AND a.FILE_ADDR = #{tDispatchInfo.fileAddr} AND a.FILE_ADDR = #{tDispatchInfo.fileAddr}
</if> </if>
<if test="tDispatchInfo.post != null and tDispatchInfo.post.trim() != ''"> <if test="tDispatchInfo.post != null and tDispatchInfo.post.trim() != ''">
AND a.POST = #{tDispatchInfo.post} AND a.POST = #{tDispatchInfo.post}
</if> </if>
<if test="tDispatchInfo.trustRemark != null and tDispatchInfo.trustRemark.trim() != ''"> <if test="tDispatchInfo.trustRemark != null and tDispatchInfo.trustRemark.trim() != ''">
AND a.TRUST_REMARK = #{tDispatchInfo.trustRemark} AND a.TRUST_REMARK = #{tDispatchInfo.trustRemark}
</if> </if>
<if test="tDispatchInfo.fileProvince != null"> <if test="tDispatchInfo.fileProvince != null">
AND a.FILE_PROVINCE = #{tDispatchInfo.fileProvince} AND a.FILE_PROVINCE = #{tDispatchInfo.fileProvince}
</if> </if>
<if test="tDispatchInfo.fileCity != null"> <if test="tDispatchInfo.fileCity != null">
AND a.FILE_CITY = #{tDispatchInfo.fileCity} AND a.FILE_CITY = #{tDispatchInfo.fileCity}
</if> </if>
<if test="tDispatchInfo.fileTown != null"> <if test="tDispatchInfo.fileTown != null">
AND a.FILE_TOWN = #{tDispatchInfo.fileTown} AND a.FILE_TOWN = #{tDispatchInfo.fileTown}
</if> </if>
<if test="tDispatchInfo.contractType != null and tDispatchInfo.contractType.trim() != ''"> <if test="tDispatchInfo.contractType != null and tDispatchInfo.contractType.trim() != ''">
AND a.CONTRACT_TYPE = #{tDispatchInfo.contractType} AND a.CONTRACT_TYPE = #{tDispatchInfo.contractType}
</if> </if>
<if test="tDispatchInfo.socialHandleStatus != null and tDispatchInfo.socialHandleStatus.trim() != ''"> <if test="tDispatchInfo.socialHandleStatus != null and tDispatchInfo.socialHandleStatus.trim() != ''">
AND a.SOCIAL_HANDLE_STATUS = #{tDispatchInfo.socialHandleStatus} AND a.SOCIAL_HANDLE_STATUS = #{tDispatchInfo.socialHandleStatus}
</if> </if>
<if test="tDispatchInfo.fundHandleStatus != null and tDispatchInfo.fundHandleStatus.trim() != ''"> <if test="tDispatchInfo.fundHandleStatus != null and tDispatchInfo.fundHandleStatus.trim() != ''">
AND a.FUND_HANDLE_STATUS = #{tDispatchInfo.fundHandleStatus} AND a.FUND_HANDLE_STATUS = #{tDispatchInfo.fundHandleStatus}
</if> </if>
<if test="tDispatchInfo.handleRemark != null and tDispatchInfo.handleRemark.trim() != ''"> <if test="tDispatchInfo.handleRemark != null and tDispatchInfo.handleRemark.trim() != ''">
AND a.HANDLE_REMARK = #{tDispatchInfo.handleRemark} AND a.HANDLE_REMARK = #{tDispatchInfo.handleRemark}
</if> </if>
<if test="tDispatchInfo.auditRemark != null and tDispatchInfo.auditRemark.trim() != ''"> <if test="tDispatchInfo.auditRemark != null and tDispatchInfo.auditRemark.trim() != ''">
AND a.AUDIT_REMARK = #{tDispatchInfo.auditRemark} AND a.AUDIT_REMARK = #{tDispatchInfo.auditRemark}
</if> </if>
<if test="tDispatchInfo.fundHandleRemark != null and tDispatchInfo.fundHandleRemark.trim() != ''"> <if test="tDispatchInfo.fundHandleRemark != null and tDispatchInfo.fundHandleRemark.trim() != ''">
AND a.FUND_HANDLE_REMARK = #{tDispatchInfo.fundHandleRemark} AND a.FUND_HANDLE_REMARK = #{tDispatchInfo.fundHandleRemark}
</if> </if>
<if test="tDispatchInfo.socialHandleRemark != null and tDispatchInfo.socialHandleRemark.trim() != ''"> <if test="tDispatchInfo.socialHandleRemark != null and tDispatchInfo.socialHandleRemark.trim() != ''">
AND a.SOCIAL_HANDLE_REMARK = #{tDispatchInfo.socialHandleRemark} AND a.SOCIAL_HANDLE_REMARK = #{tDispatchInfo.socialHandleRemark}
</if> </if>
<if test="tDispatchInfo.socialProvince != null and tDispatchInfo.socialProvince.trim() != ''"> <if test="tDispatchInfo.socialProvince != null and tDispatchInfo.socialProvince.trim() != ''">
AND a.SOCIAL_PROVINCE = #{tDispatchInfo.socialProvince} AND a.SOCIAL_PROVINCE = #{tDispatchInfo.socialProvince}
</if> </if>
<if test="tDispatchInfo.socialCity != null and tDispatchInfo.socialCity.trim() != ''"> <if test="tDispatchInfo.socialCity != null and tDispatchInfo.socialCity.trim() != ''">
AND a.SOCIAL_CITY = #{tDispatchInfo.socialCity} AND a.SOCIAL_CITY = #{tDispatchInfo.socialCity}
</if> </if>
<if test="tDispatchInfo.socialTown != null and tDispatchInfo.socialTown.trim() != ''"> <if test="tDispatchInfo.socialTown != null and tDispatchInfo.socialTown.trim() != ''">
AND a.SOCIAL_TOWN = #{tDispatchInfo.socialTown} AND a.SOCIAL_TOWN = #{tDispatchInfo.socialTown}
</if> </if>
<if test="tDispatchInfo.fundProvince != null and tDispatchInfo.fundProvince.trim() != ''"> <if test="tDispatchInfo.fundProvince != null and tDispatchInfo.fundProvince.trim() != ''">
AND a.FUND_PROVINCE = #{tDispatchInfo.fundProvince} AND a.FUND_PROVINCE = #{tDispatchInfo.fundProvince}
</if> </if>
<if test="tDispatchInfo.fundCity != null and tDispatchInfo.fundCity.trim() != ''"> <if test="tDispatchInfo.fundCity != null and tDispatchInfo.fundCity.trim() != ''">
AND a.FUND_CITY = #{tDispatchInfo.fundCity} AND a.FUND_CITY = #{tDispatchInfo.fundCity}
</if> </if>
<if test="tDispatchInfo.fundTown != null and tDispatchInfo.fundTown.trim() != ''"> <if test="tDispatchInfo.fundTown != null and tDispatchInfo.fundTown.trim() != ''">
AND a.FUND_TOWN = #{tDispatchInfo.fundTown} AND a.FUND_TOWN = #{tDispatchInfo.fundTown}
</if> </if>
<if test="tDispatchInfo.auditUser != null and tDispatchInfo.auditUser.trim() != ''"> <if test="tDispatchInfo.auditUser != null and tDispatchInfo.auditUser.trim() != ''">
AND a.AUDIT_USER = #{tDispatchInfo.auditUser} AND a.AUDIT_USER = #{tDispatchInfo.auditUser}
</if> </if>
<if test="tDispatchInfo.auditUserName != null and tDispatchInfo.auditUserName.trim() != ''"> <if test="tDispatchInfo.auditUserName != null and tDispatchInfo.auditUserName.trim() != ''">
AND a.AUDIT_USER_NAME like concat('%',#{tDispatchInfo.auditUserName},'%') AND a.AUDIT_USER_NAME like concat('%',#{tDispatchInfo.auditUserName},'%')
</if> </if>
<if test="tDispatchInfo.auditTime != null"> <if test="tDispatchInfo.auditTime != null">
AND a.AUDIT_TIME = #{tDispatchInfo.auditTime} AND a.AUDIT_TIME = #{tDispatchInfo.auditTime}
</if> </if>
<if test="tDispatchInfo.auditTimeStart != null"> <if test="tDispatchInfo.auditTimeStart != null">
AND a.AUDIT_TIME <![CDATA[>=]]> #{tDispatchInfo.auditTimeStart} AND a.AUDIT_TIME <![CDATA[>=]]> #{tDispatchInfo.auditTimeStart}
</if> </if>
<if test="tDispatchInfo.auditTimeEnd != null"> <if test="tDispatchInfo.auditTimeEnd != null">
AND a.AUDIT_TIME <![CDATA[<=]]> #{tDispatchInfo.auditTimeEnd} AND a.AUDIT_TIME <![CDATA[<=]]> #{tDispatchInfo.auditTimeEnd}
</if> </if>
<if test="tDispatchInfo.workingHours != null and tDispatchInfo.workingHours.trim() != ''"> <if test="tDispatchInfo.workingHours != null and tDispatchInfo.workingHours.trim() != ''">
AND a.WORKING_HOURS = #{tDispatchInfo.workingHours} AND a.WORKING_HOURS = #{tDispatchInfo.workingHours}
</if> </if>
<if test="tDispatchInfo.updateBy != null and tDispatchInfo.updateBy.trim() != ''"> <if test="tDispatchInfo.updateBy != null and tDispatchInfo.updateBy.trim() != ''">
AND a.UPDATE_BY = #{tDispatchInfo.updateBy} AND a.UPDATE_BY = #{tDispatchInfo.updateBy}
</if> </if>
<if test="tDispatchInfo.createName != null and tDispatchInfo.createName.trim() != ''"> <if test="tDispatchInfo.createName != null and tDispatchInfo.createName.trim() != ''">
AND a.CREATE_NAME = #{tDispatchInfo.createName} AND a.CREATE_NAME = #{tDispatchInfo.createName}
</if> </if>
<if test="tDispatchInfo.updateTime != null"> <if test="tDispatchInfo.updateTime != null">
AND a.UPDATE_TIME = #{tDispatchInfo.updateTime} AND a.UPDATE_TIME = #{tDispatchInfo.updateTime}
</if> </if>
<if test="tDispatchInfo.organName != null and tDispatchInfo.organName.trim() != ''"> <if test="tDispatchInfo.organName != null and tDispatchInfo.organName.trim() != ''">
AND a.ORGAN_NAME = #{tDispatchInfo.organName} AND a.ORGAN_NAME = #{tDispatchInfo.organName}
</if> </if>
<if test="tDispatchInfo.dispatchItem != null and tDispatchInfo.dispatchItem.trim() != ''"> <if test="tDispatchInfo.dispatchItem != null and tDispatchInfo.dispatchItem.trim() != ''">
AND a.DISPATCH_ITEM = #{tDispatchInfo.dispatchItem} AND a.DISPATCH_ITEM = #{tDispatchInfo.dispatchItem}
</if> </if>
<if test="tDispatchInfo.belongUnitName != null and tDispatchInfo.belongUnitName.trim() != ''"> <if test="tDispatchInfo.belongUnitName != null and tDispatchInfo.belongUnitName.trim() != ''">
AND a.BELONG_UNIT_NAME = #{tDispatchInfo.belongUnitName} AND a.BELONG_UNIT_NAME = #{tDispatchInfo.belongUnitName}
</if> </if>
<if test="tDispatchInfo.socialHouseholdName != null and tDispatchInfo.socialHouseholdName.trim() != ''"> <if test="tDispatchInfo.socialHouseholdName != null and tDispatchInfo.socialHouseholdName.trim() != ''">
AND a.SOCIAL_HOUSEHOLD_NAME like CONCAT(CONCAT(#{tDispatchInfo.socialHouseholdName}), '%') AND a.SOCIAL_HOUSEHOLD_NAME like CONCAT(CONCAT(#{tDispatchInfo.socialHouseholdName}), '%')
</if> </if>
<if test="tDispatchInfo.providentHouseholdName != null and tDispatchInfo.providentHouseholdName.trim() != ''"> <if test="tDispatchInfo.providentHouseholdName != null and tDispatchInfo.providentHouseholdName.trim() != ''">
AND a.PROVIDENT_HOUSEHOLD_NAME like CONCAT(CONCAT(#{tDispatchInfo.providentHouseholdName}), '%') AND a.PROVIDENT_HOUSEHOLD_NAME like CONCAT(CONCAT(#{tDispatchInfo.providentHouseholdName}), '%')
</if> </if>
<if test="tDispatchInfo.createTimeStart != null"> <if test="tDispatchInfo.createTimeStart != null">
AND a.CREATE_TIME <![CDATA[ >= ]]> #{tDispatchInfo.createTimeStart} AND a.CREATE_TIME <![CDATA[ >= ]]> #{tDispatchInfo.createTimeStart}
</if> </if>
<if test="tDispatchInfo.createTimeEnd != null"> <if test="tDispatchInfo.createTimeEnd != null">
AND a.CREATE_TIME <![CDATA[ <= ]]> #{tDispatchInfo.createTimeEnd} AND a.CREATE_TIME <![CDATA[ <= ]]> #{tDispatchInfo.createTimeEnd}
</if> </if>
<if test="tDispatchInfo.authSql != null and tDispatchInfo.authSql.trim() != ''"> <if test="tDispatchInfo.authSql != null and tDispatchInfo.authSql.trim() != ''">
${tDispatchInfo.authSql} ${tDispatchInfo.authSql}
</if> </if>
<if test="tDispatchInfo.noCreateUser != null and tDispatchInfo.noCreateUser.trim() != ''"> <if test="tDispatchInfo.noCreateUser != null and tDispatchInfo.noCreateUser.trim() != ''">
AND a.CREATE_BY != #{tDispatchInfo.noCreateUser} AND a.CREATE_BY != #{tDispatchInfo.noCreateUser}
</if> </if>
</if> </if>
</sql> </sql>
<sql id="tDispatchInfoAudit_where"> <sql id="tDispatchInfoAudit_where">
<if test="tDispatchInfo != null"> <if test="tDispatchInfo != null">
...@@ -747,19 +747,19 @@ ...@@ -747,19 +747,19 @@
</if> </if>
</sql> </sql>
<!--tDispatchInfo简单分页查询--> <!--tDispatchInfo简单分页查询-->
<select id="getTDispatchInfoPage" resultMap="dispatchPageMap"> <select id="getTDispatchInfoPage" resultMap="dispatchPageMap">
SELECT SELECT
<include refid="Base_Column_List"/>, <include refid="Base_Column_List"/>,
a.SOCIAL_HOUSEHOLD_NAME, a.SOCIAL_HOUSEHOLD_NAME,
a.PROVIDENT_HOUSEHOLD_NAME a.PROVIDENT_HOUSEHOLD_NAME
FROM t_dispatch_info a FROM t_dispatch_info a
<where> <where>
1=1 1=1
<include refid="tDispatchInfo_where"/> <include refid="tDispatchInfo_where"/>
</where> </where>
order by a.APPLY_NO desc order by a.APPLY_NO desc
</select> </select>
<!--tDispatchInfo简单分页查询--> <!--tDispatchInfo简单分页查询-->
<select id="getTDispatchInfoPageAudit" resultMap="dispatchPageMap"> <select id="getTDispatchInfoPageAudit" resultMap="dispatchPageMap">
...@@ -777,7 +777,7 @@ ...@@ -777,7 +777,7 @@
</select> </select>
<!-- 派单导出 --> <!-- 派单导出 -->
<select id="exportDispatch" resultMap="exportMap"> <select id="exportDispatch" resultMap="exportMap">
select select
a.EMP_NAME, a.EMP_NAME,
a.EMP_IDCARD, a.EMP_IDCARD,
...@@ -983,15 +983,15 @@ ...@@ -983,15 +983,15 @@
left join t_dispatch_social_fund_info h on a.id = h.REDUCE_SOCIAL_FUND_ID left join t_dispatch_social_fund_info h on a.id = h.REDUCE_SOCIAL_FUND_ID
left join t_social_info s on s.id=a.SOCIAL_ID left join t_social_info s on s.id=a.SOCIAL_ID
left join t_provident_fund c on c.id=a.FUND_ID left join t_provident_fund c on c.id=a.FUND_ID
<where> <where>
a.DELETE_FLAG = '0' a.DELETE_FLAG = '0'
<include refid="tDispatchInfo_where"/> <include refid="tDispatchInfo_where"/>
</where> </where>
order by a.APPLY_NO desc order by a.APPLY_NO desc
<if test="tDispatchInfo.limitStart != null"> <if test="tDispatchInfo.limitStart != null">
limit #{tDispatchInfo.limitStart},#{tDispatchInfo.limitEnd} limit #{tDispatchInfo.limitStart},#{tDispatchInfo.limitEnd}
</if> </if>
</select> </select>
<!-- 派单审核导出 --> <!-- 派单审核导出 -->
<select id="exportAuditDispatch" resultMap="exportAuditMap"> <select id="exportAuditDispatch" resultMap="exportAuditMap">
...@@ -999,7 +999,7 @@ ...@@ -999,7 +999,7 @@
a.EMP_NAME, a.EMP_NAME,
a.EMP_IDCARD, a.EMP_IDCARD,
a.EMP_MOBILE, a.EMP_MOBILE,
a.EMP_TYPE, a.EMP_TYPE,
a.ID_CARD_ADDRESS, a.ID_CARD_ADDRESS,
a.BELONG_UNIT_NAME, a.BELONG_UNIT_NAME,
a.SETTLE_DOMAIN_NAME, a.SETTLE_DOMAIN_NAME,
...@@ -1038,8 +1038,8 @@ ...@@ -1038,8 +1038,8 @@
c.PERSONAL_PROVIDENT_PER, c.PERSONAL_PROVIDENT_PER,
a.EDUCATION_NAME, a.EDUCATION_NAME,
a.SCHOOL_NAME, a.SCHOOL_NAME,
a.MAJOR, a.MAJOR,
a.FIRST_PAY_TIME, a.FIRST_PAY_TIME,
a.GRADUATION_TIME a.GRADUATION_TIME
from t_dispatch_info a from t_dispatch_info a
left join t_dispatch_social_fund_info h on a.id = h.REDUCE_SOCIAL_FUND_ID left join t_dispatch_social_fund_info h on a.id = h.REDUCE_SOCIAL_FUND_ID
...@@ -1378,15 +1378,15 @@ ...@@ -1378,15 +1378,15 @@
<!-- 导出社保士兵count --> <!-- 导出社保士兵count -->
<select id="getSocialSoldierCount" resultType="java.lang.Integer"> <select id="getSocialSoldierCount" resultType="java.lang.Integer">
SELECT SELECT
count(1) count(1)
from ( from (
SELECT SELECT
1 1
FROM t_dispatch_info a FROM t_dispatch_info a
left join t_social_info s on a.SOCIAL_ID = s.id 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 left join t_dispatch_social_fund_info h on a.id = h.REDUCE_SOCIAL_FUND_ID
<include refid="where_getSocialSoldier"/> <include refid="where_getSocialSoldier"/>
group by s.id group by s.id
) a ) a
</select> </select>
...@@ -1403,91 +1403,91 @@ ...@@ -1403,91 +1403,91 @@
<!-- hgw 2024-5-10 10:42:33 社保士兵列表查询 --> <!-- hgw 2024-5-10 10:42:33 社保士兵列表查询 -->
<select id="getTSocialSoldierHandlePage" resultMap="socialSoldierPageMap"> <select id="getTSocialSoldierHandlePage" resultMap="socialSoldierPageMap">
SELECT SELECT
SUBSTRING_INDEX(GROUP_CONCAT(a.ID ORDER BY a.CREATE_TIME desc),',',1) ID, SUBSTRING_INDEX(GROUP_CONCAT(a.ID ORDER BY a.CREATE_TIME desc),',',1) ID,
a.EMP_ID, a.EMP_ID,
a.EMP_NAME, a.EMP_NAME,
a.EMP_NO, a.EMP_NO,
a.EMP_IDCARD, a.EMP_IDCARD,
a.EMP_TYPE, a.EMP_TYPE,
a.EMP_MOBILE, a.EMP_MOBILE,
a.EMP_NATIONAL, a.EMP_NATIONAL,
a.STATUS, a.STATUS,
SUBSTRING_INDEX(GROUP_CONCAT(a.TYPE ORDER BY a.CREATE_TIME desc),',',1) TYPE, SUBSTRING_INDEX(GROUP_CONCAT(a.TYPE ORDER BY a.CREATE_TIME desc),',',1) TYPE,
SUBSTRING_INDEX(GROUP_CONCAT(a.SOCIAL_ID ORDER BY a.CREATE_TIME desc),',',1) SOCIAL_ID, SUBSTRING_INDEX(GROUP_CONCAT(a.SOCIAL_ID ORDER BY a.CREATE_TIME desc),',',1) SOCIAL_ID,
a.FUND_ID, a.FUND_ID,
a.TYPE_SUB, a.TYPE_SUB,
a.PROCESS_INST_ID, a.PROCESS_INST_ID,
a.SETTLE_DOMAIN, a.SETTLE_DOMAIN,
a.DELETE_FLAG, a.DELETE_FLAG,
a.SOCIAL_REDUCE_DATE, a.SOCIAL_REDUCE_DATE,
a.FUND_REDUCE_DATE, a.FUND_REDUCE_DATE,
a.LEAVE_DATE, a.LEAVE_DATE,
a.REDUCE_REASON, a.REDUCE_REASON,
a.REDUCE_REMARK, a.REDUCE_REMARK,
a.BELONG_UNIT, a.BELONG_UNIT,
a.CURRENT_OPERATOR, a.CURRENT_OPERATOR,
a.DISPATCH_ID_BAK, a.DISPATCH_ID_BAK,
a.CONTRACT_START, a.CONTRACT_START,
a.CONTRACT_END, a.CONTRACT_END,
a.CONTRACT_TERM, a.CONTRACT_TERM,
a.EMP_REGIS_TYPE, a.EMP_REGIS_TYPE,
a.ENJOIN_DATE, a.ENJOIN_DATE,
a.FILE_ADDR, a.FILE_ADDR,
a.POST, a.POST,
a.TRUST_REMARK, a.TRUST_REMARK,
a.FILE_PROVINCE, a.FILE_PROVINCE,
a.FILE_CITY, a.FILE_CITY,
a.FILE_TOWN, a.FILE_TOWN,
a.CONTRACT_TYPE, a.CONTRACT_TYPE,
SUBSTRING_INDEX(GROUP_CONCAT(a.SOCIAL_HANDLE_STATUS ORDER BY a.CREATE_TIME desc),',',1) SOCIAL_HANDLE_STATUS, SUBSTRING_INDEX(GROUP_CONCAT(a.SOCIAL_HANDLE_STATUS ORDER BY a.CREATE_TIME desc),',',1) SOCIAL_HANDLE_STATUS,
a.FUND_HANDLE_STATUS, a.FUND_HANDLE_STATUS,
a.HANDLE_REMARK, a.HANDLE_REMARK,
a.AUDIT_REMARK, a.AUDIT_REMARK,
a.FUND_HANDLE_REMARK, a.FUND_HANDLE_REMARK,
a.SOCIAL_HANDLE_REMARK, a.SOCIAL_HANDLE_REMARK,
a.SOCIAL_PROVINCE, a.SOCIAL_PROVINCE,
a.SOCIAL_CITY, a.SOCIAL_CITY,
a.SOCIAL_TOWN, a.SOCIAL_TOWN,
a.FUND_PROVINCE, a.FUND_PROVINCE,
a.FUND_CITY, a.FUND_CITY,
a.FUND_TOWN, a.FUND_TOWN,
a.AUDIT_USER, a.AUDIT_USER,
a.AUDIT_USER_NAME, a.AUDIT_USER_NAME,
a.AUDIT_TIME, a.AUDIT_TIME,
a.WORKING_HOURS, a.WORKING_HOURS,
a.CREATE_BY, a.CREATE_BY,
a.UPDATE_BY, a.UPDATE_BY,
a.CREATE_NAME, a.CREATE_NAME,
a.CREATE_TIME, a.CREATE_TIME,
a.UPDATE_TIME, a.UPDATE_TIME,
a.ORGAN_NAME, a.ORGAN_NAME,
a.DISPATCH_ITEM, a.DISPATCH_ITEM,
a.SETTLE_DOMAIN_NAME, a.SETTLE_DOMAIN_NAME,
a.BELONG_UNIT_NAME, a.BELONG_UNIT_NAME,
a.DISPATCH_CODE, a.DISPATCH_CODE,
a.AGAIN_DISPATCH_CODE, a.AGAIN_DISPATCH_CODE,
a.SETTLE_DOMAIN_CODE, a.SETTLE_DOMAIN_CODE,
a.CONTRACT_SUB_NAME, a.CONTRACT_SUB_NAME,
a.CONTRACT_ID, a.CONTRACT_ID,
a.EDUCATION_NAME, a.EDUCATION_NAME,
a.TRY_PERIOD, a.TRY_PERIOD,
a.ID_CARD_PROVINCE, a.ID_CARD_PROVINCE,
a.ID_CARD_CITY, a.ID_CARD_CITY,
a.ID_CARD_TOWN, a.ID_CARD_TOWN,
a.ID_CARD_ADDRESS, a.ID_CARD_ADDRESS,
SUBSTRING_INDEX(GROUP_CONCAT(a.APPLY_NO ORDER BY a.CREATE_TIME desc),',',1) APPLY_NO, SUBSTRING_INDEX(GROUP_CONCAT(a.APPLY_NO ORDER BY a.CREATE_TIME desc),',',1) APPLY_NO,
a.ORDER_ID, a.ORDER_ID,
a.SCHOOL_NAME, a.SCHOOL_NAME,
a.MAJOR, a.MAJOR,
a.FIRST_PAY_TIME, a.FIRST_PAY_TIME,
a.GRADUATION_TIME,a.AUTO_FLAG a.GRADUATION_TIME,a.AUTO_FLAG
,a.SOCIAL_HOUSEHOLD_NAME,s.YGS_HANDLE_STATUS,s.YSD_HANDLE_STATUS ,a.SOCIAL_HOUSEHOLD_NAME,s.YGS_HANDLE_STATUS,s.YSD_HANDLE_STATUS
,s.YGS_REMARK,s.YSD_REMARK,s.YGS_REMARK_OLD,s.YSD_REMARK_OLD ,s.YGS_REMARK,s.YSD_REMARK,s.YGS_REMARK_OLD,s.YSD_REMARK_OLD
FROM t_dispatch_info a FROM t_dispatch_info a
left join t_social_info s on a.SOCIAL_ID = s.id 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 left join t_dispatch_social_fund_info h on a.id = h.REDUCE_SOCIAL_FUND_ID
<include refid="where_getSocialSoldier"/> <include refid="where_getSocialSoldier"/>
group by s.id group by s.id
order by a.AUDIT_TIME desc order by a.AUDIT_TIME desc
</select> </select>
...@@ -1495,7 +1495,7 @@ ...@@ -1495,7 +1495,7 @@
<select id="getTDispatchSocialHandlePage" resultMap="dispatchPageMap"> <select id="getTDispatchSocialHandlePage" resultMap="dispatchPageMap">
SELECT SELECT
<include refid="Base_Column_List"/>, <include refid="Base_Column_List"/>,
a.SOCIAL_HOUSEHOLD_NAME,a.EXPORT_SOCIAL_FLAG,s.YGS_HANDLE_STATUS,s.YSD_HANDLE_STATUS a.SOCIAL_HOUSEHOLD_NAME,a.EXPORT_SOCIAL_FLAG,s.YGS_HANDLE_STATUS,s.YSD_HANDLE_STATUS
FROM t_dispatch_info a FROM t_dispatch_info a
left join t_social_info s on a.SOCIAL_ID = s.id 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 left join t_dispatch_social_fund_info h on a.id = h.REDUCE_SOCIAL_FUND_ID
...@@ -1577,6 +1577,7 @@ ...@@ -1577,6 +1577,7 @@
SELECT count(1) from ( SELECT count(1) from (
SELECT 1 SELECT 1
FROM t_dispatch_info a FROM t_dispatch_info a
left join t_social_info s on s.id=a.SOCIAL_ID
<where> <where>
<include refid="where_getSocialDisRecord"/> <include refid="where_getSocialDisRecord"/>
</where> </where>
...@@ -1586,33 +1587,33 @@ ...@@ -1586,33 +1587,33 @@
<!--tDispatchInfo 社保医疗花名册派单数据--> <!--tDispatchInfo 社保医疗花名册派单数据-->
<select id="getSocialDisRecord" resultMap="socialDisExportMap"> <select id="getSocialDisRecord" resultMap="socialDisExportMap">
SELECT SELECT
(@i :=@i+1) as NUM, (@i :=@i+1) as NUM,
h.EMP_NAME, h.EMP_NAME,
h.IDCARD_TYPE, h.IDCARD_TYPE,
h.EMP_IDCARD, h.EMP_IDCARD,
h.DIS_MONTH, h.DIS_MONTH,
h.MEDICAL_CARDINAL, h.MEDICAL_CARDINAL,
h.CHANGE_TYPE_ONE, h.CHANGE_TYPE_ONE,
h.CHANGE_TYPE_TWO, h.CHANGE_TYPE_TWO,
h.CHANGE_TYPE_THREE, h.CHANGE_TYPE_THREE,
h.CHANGE_TYPE_FOUR, h.CHANGE_TYPE_FOUR,
h.EMP_MOBILE, h.EMP_MOBILE,
h.EDUCATION_NAME, h.EDUCATION_NAME,
h.REMARK h.REMARK
from ( from (
select select
a.EMP_NAME, a.EMP_NAME,
'身份证' as IDCARD_TYPE, '身份证' as IDCARD_TYPE,
a.EMP_IDCARD, a.EMP_IDCARD,
replace(DATE_FORMAT(a.CREATE_TIME,"%Y-%m"),'-','') as DIS_MONTH, replace(DATE_FORMAT(a.CREATE_TIME,"%Y-%m"),'-','') as DIS_MONTH,
s.UNIT_MEDICAL_CARDINAL as MEDICAL_CARDINAL, s.UNIT_MEDICAL_CARDINAL as MEDICAL_CARDINAL,
'' as CHANGE_TYPE_ONE, '' as CHANGE_TYPE_ONE,
'√' as CHANGE_TYPE_TWO, '√' as CHANGE_TYPE_TWO,
'' as CHANGE_TYPE_THREE, '' as CHANGE_TYPE_THREE,
'' as CHANGE_TYPE_FOUR, '' as CHANGE_TYPE_FOUR,
a.EMP_MOBILE, a.EMP_MOBILE,
a.EDUCATION_NAME, a.EDUCATION_NAME,
'' as REMARK '' as REMARK
FROM t_dispatch_info a FROM t_dispatch_info a
left join t_social_info s on s.id=a.SOCIAL_ID left join t_social_info s on s.id=a.SOCIAL_ID
<where> <where>
...@@ -1949,81 +1950,81 @@ ...@@ -1949,81 +1950,81 @@
</foreach> </foreach>
</if> </if>
<if test="tDispatchInfo.dispatchItems != null and tDispatchInfo.dispatchItems.size >0"> <if test="tDispatchInfo.dispatchItems != null and tDispatchInfo.dispatchItems.size >0">
AND AND
<foreach item="item" index="index" collection="tDispatchInfo.dispatchItems" open="(" separator="or" close=")"> <foreach item="item" index="index" collection="tDispatchInfo.dispatchItems" open="(" separator="or" close=")">
INSTR(a.DISPATCH_ITEM,#{item}) INSTR(a.DISPATCH_ITEM,#{item})
</foreach> </foreach>
</if> </if>
<if test="tDispatchInfo.type != null and tDispatchInfo.type.trim() != ''"> <if test="tDispatchInfo.type != null and tDispatchInfo.type.trim() != ''">
AND a.TYPE = #{tDispatchInfo.type} AND a.TYPE = #{tDispatchInfo.type}
</if> </if>
<if test="tDispatchInfo.socialProvince != null and tDispatchInfo.socialProvince!= null"> <if test="tDispatchInfo.socialProvince != null and tDispatchInfo.socialProvince!= null">
AND if(ifnull(h.id,0) != '0',h.social_province,s.social_province) = #{tDispatchInfo.socialProvince} AND if(ifnull(h.id,0) != '0',h.social_province,s.social_province) = #{tDispatchInfo.socialProvince}
<if test="tDispatchInfo.socialCity != null and tDispatchInfo.socialCity!= null"> <if test="tDispatchInfo.socialCity != null and tDispatchInfo.socialCity!= null">
AND if(ifnull(h.id,0) != '0',h.social_city,s.social_city) = #{tDispatchInfo.socialCity} AND if(ifnull(h.id,0) != '0',h.social_city,s.social_city) = #{tDispatchInfo.socialCity}
</if>
<if test="tDispatchInfo.socialTown != null and tDispatchInfo.socialTown!= null">
AND if(ifnull(h.id,0) != '0',h.social_town,s.social_town) = #{tDispatchInfo.socialTown}
</if>
</if>
<if test="tDispatchInfo.empName != null and tDispatchInfo.empName.trim() != ''">
AND a.EMP_NAME like concat('%',#{tDispatchInfo.empName},'%')
</if>
<if test="tDispatchInfo.empIdcard != null and tDispatchInfo.empIdcard.trim() != ''">
AND a.EMP_IDCARD like concat('%',#{tDispatchInfo.empIdcard},'%')
</if> </if>
<if test="tDispatchInfo.status != null and tDispatchInfo.status.trim() != ''"> <if test="tDispatchInfo.socialTown != null and tDispatchInfo.socialTown!= null">
AND a.STATUS = #{tDispatchInfo.status} AND if(ifnull(h.id,0) != '0',h.social_town,s.social_town) = #{tDispatchInfo.socialTown}
</if> </if>
</if>
<if test="tDispatchInfo.empName != null and tDispatchInfo.empName.trim() != ''">
AND a.EMP_NAME like concat('%',#{tDispatchInfo.empName},'%')
</if>
<if test="tDispatchInfo.empIdcard != null and tDispatchInfo.empIdcard.trim() != ''">
AND a.EMP_IDCARD like concat('%',#{tDispatchInfo.empIdcard},'%')
</if>
<if test="tDispatchInfo.status != null and tDispatchInfo.status.trim() != ''">
AND a.STATUS = #{tDispatchInfo.status}
</if>
<if test="tDispatchInfo.settleDomain != null and tDispatchInfo.settleDomain.trim() != ''"> <if test="tDispatchInfo.settleDomain != null and tDispatchInfo.settleDomain.trim() != ''">
AND a.SETTLE_DOMAIN = #{tDispatchInfo.settleDomain} AND a.SETTLE_DOMAIN = #{tDispatchInfo.settleDomain}
</if> </if>
<if test="tDispatchInfo.settleDomainCode != null and tDispatchInfo.settleDomainCode.trim() != ''"> <if test="tDispatchInfo.settleDomainCode != null and tDispatchInfo.settleDomainCode.trim() != ''">
AND a.SETTLE_DOMAIN_CODE = #{tDispatchInfo.settleDomainCode} AND a.SETTLE_DOMAIN_CODE = #{tDispatchInfo.settleDomainCode}
</if> </if>
<if test="tDispatchInfo.socialHandleStatus != null and tDispatchInfo.socialHandleStatus.trim() != ''"> <if test="tDispatchInfo.socialHandleStatus != null and tDispatchInfo.socialHandleStatus.trim() != ''">
AND a.SOCIAL_HANDLE_STATUS = #{tDispatchInfo.socialHandleStatus} AND a.SOCIAL_HANDLE_STATUS = #{tDispatchInfo.socialHandleStatus}
</if> </if>
<if test="tDispatchInfo.createName != null and tDispatchInfo.createName.trim() != ''"> <if test="tDispatchInfo.createName != null and tDispatchInfo.createName.trim() != ''">
AND a.CREATE_NAME = #{tDispatchInfo.createName} AND a.CREATE_NAME = #{tDispatchInfo.createName}
</if> </if>
<if test="tDispatchInfo.settleDomainName != null and tDispatchInfo.settleDomainName.trim() != ''"> <if test="tDispatchInfo.settleDomainName != null and tDispatchInfo.settleDomainName.trim() != ''">
AND a.SETTLE_DOMAIN_NAME like CONCAT(CONCAT(#{tDispatchInfo.settleDomainName}), '%') AND a.SETTLE_DOMAIN_NAME like CONCAT(CONCAT(#{tDispatchInfo.settleDomainName}), '%')
</if> </if>
<if test="tDispatchInfo.belongUnitName != null and tDispatchInfo.belongUnitName.trim() != ''"> <if test="tDispatchInfo.belongUnitName != null and tDispatchInfo.belongUnitName.trim() != ''">
AND a.BELONG_UNIT_NAME = #{tDispatchInfo.belongUnitName} AND a.BELONG_UNIT_NAME = #{tDispatchInfo.belongUnitName}
</if> </if>
<if test="tDispatchInfo.createTimeEnd != null"> <if test="tDispatchInfo.createTimeEnd != null">
AND a.CREATE_TIME <![CDATA[<=]]> #{tDispatchInfo.createTimeEnd} AND a.CREATE_TIME <![CDATA[<=]]> #{tDispatchInfo.createTimeEnd}
</if> </if>
<if test="tDispatchInfo.createTimeStart != null"> <if test="tDispatchInfo.createTimeStart != null">
AND a.CREATE_TIME <![CDATA[>=]]> #{tDispatchInfo.createTimeStart} AND a.CREATE_TIME <![CDATA[>=]]> #{tDispatchInfo.createTimeStart}
</if> </if>
<if test="tDispatchInfo.auditTimeStart != null"> <if test="tDispatchInfo.auditTimeStart != null">
AND a.AUDIT_TIME <![CDATA[>=]]> #{tDispatchInfo.auditTimeStart} AND a.AUDIT_TIME <![CDATA[>=]]> #{tDispatchInfo.auditTimeStart}
</if>
<if test="tDispatchInfo.auditTimeEnd != null">
AND a.AUDIT_TIME <![CDATA[<=]]> #{tDispatchInfo.auditTimeEnd}
</if>
<if test="tDispatchInfo.auditUserName != null and tDispatchInfo.auditUserName.trim() != ''">
AND a.AUDIT_USER_NAME like concat('%',#{tDispatchInfo.auditUserName},'%')
</if>
<if test="tDispatchInfo.socialHouseholdName != null and tDispatchInfo.socialHouseholdName.trim() != ''">
AND a.SOCIAL_HOUSEHOLD_NAME like CONCAT(CONCAT(#{tDispatchInfo.socialHouseholdName}), '%')
</if>
<if test="tDispatchInfo.authSql != null and tDispatchInfo.authSql.trim() != ''">
${tDispatchInfo.authSql}
</if>
<if test="tDispatchInfo.exportSocialFlag != null and tDispatchInfo.exportSocialFlag.trim() != ''">
AND a.EXPORT_SOCIAL_FLAG = ${tDispatchInfo.exportSocialFlag}
</if>
</if> </if>
<if test="tDispatchInfo.auditTimeEnd != null">
AND a.AUDIT_TIME <![CDATA[<=]]> #{tDispatchInfo.auditTimeEnd}
</if>
<if test="tDispatchInfo.auditUserName != null and tDispatchInfo.auditUserName.trim() != ''">
AND a.AUDIT_USER_NAME like concat('%',#{tDispatchInfo.auditUserName},'%')
</if>
<if test="tDispatchInfo.socialHouseholdName != null and tDispatchInfo.socialHouseholdName.trim() != ''">
AND a.SOCIAL_HOUSEHOLD_NAME like CONCAT(CONCAT(#{tDispatchInfo.socialHouseholdName}), '%')
</if>
<if test="tDispatchInfo.authSql != null and tDispatchInfo.authSql.trim() != ''">
${tDispatchInfo.authSql}
</if>
<if test="tDispatchInfo.exportSocialFlag != null and tDispatchInfo.exportSocialFlag.trim() != ''">
AND a.EXPORT_SOCIAL_FLAG = ${tDispatchInfo.exportSocialFlag}
</if>
</if>
</sql> </sql>
...@@ -2136,128 +2137,133 @@ ...@@ -2136,128 +2137,133 @@
</sql> </sql>
<sql id="where_getFundRecord"> <sql id="where_getFundRecord">
a.DELETE_FLAG = 0 a.DELETE_FLAG = 0
<if test="idsStr != null and idsStr.size > 0"> <if test="idsStr != null and idsStr.size > 0">
AND a.ID in AND a.ID in
<foreach item="items" index="index" collection="idsStr" open="(" separator="," close=")"> <foreach item="items" index="index" collection="idsStr" open="(" separator="," close=")">
#{items} #{items}
</foreach> </foreach>
</if> </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.fund_id is not null AND a.fund_id is not null
AND a.STATUS = "2" AND a.STATUS = "2"
and (( a.type = '0' AND f.HANDLE_STATUS = '0') or ( a.type ='1' AND f.HANDLE_STATUS = '1' and f.REDUCE_CAN = '1')) and (( a.type = '0' AND f.HANDLE_STATUS = '0') or ( a.type ='1' AND f.HANDLE_STATUS = '1' and f.REDUCE_CAN = '1'))
and a.FUND_HANDLE_STATUS='0' and a.FUND_HANDLE_STATUS='0'
<!--<if test="tDispatchInfo.status != null and tDispatchInfo.status.trim() != ''"> <!--<if test="tDispatchInfo.status != null and tDispatchInfo.status.trim() != ''">
/*待办理组合判断*/ /*待办理组合判断*/
<if test="'2'.toString() == tDispatchInfo.status.trim() and tDispatchInfo.typeSub != null "> <if test="'2'.toString() == tDispatchInfo.status.trim() and tDispatchInfo.typeSub != null ">
/*社保代办理*/ /*社保代办理*/
<if test=" '0'.toString()==tDispatchInfo.typeSub.trim() "> <if test=" '0'.toString()==tDispatchInfo.typeSub.trim() ">
<if test="tDispatchInfo.socialHandleStatus != null and tDispatchInfo.socialHandleStatus != ''"> <if test="tDispatchInfo.socialHandleStatus != null and tDispatchInfo.socialHandleStatus != ''">
</if>
<if test="tDispatchInfo.socialHandleStatus == null or tDispatchInfo.socialHandleStatus == ''">
and (( a.type = '0' AND b.HANDLE_STATUS in ('0','4')) or ( a.type ='1' AND b.HANDLE_STATUS in ('1','5') and b.REDUCE_CAN = '1'))
and a.SOCIAL_HANDLE_STATUS in ('0','4')
</if>
</if> </if>
/* 公积金办理*/ <if test="tDispatchInfo.socialHandleStatus == null or tDispatchInfo.socialHandleStatus == ''">
<if test=" '1'.toString()==tDispatchInfo.typeSub.trim() "> and (( a.type = '0' AND b.HANDLE_STATUS in ('0','4')) or ( a.type ='1' AND b.HANDLE_STATUS in ('1','5') and b.REDUCE_CAN = '1'))
and (( a.type = '0' AND c.HANDLE_STATUS = '0') or ( a.type ='1' AND c.HANDLE_STATUS = '1' and c.REDUCE_CAN = '1')) and a.SOCIAL_HANDLE_STATUS in ('0','4')
and a.FUND_HANDLE_STATUS='0'
</if> </if>
</if> </if>
</if>--> /* 公积金办理*/
<if test=" '1'.toString()==tDispatchInfo.typeSub.trim() ">
and (( a.type = '0' AND c.HANDLE_STATUS = '0') or ( a.type ='1' AND c.HANDLE_STATUS = '1' and c.REDUCE_CAN = '1'))
and a.FUND_HANDLE_STATUS='0'
</if>
</if>
</if>-->
<if test="tDispatchInfo != null"> <if test="tDispatchInfo != null">
<if test="tDispatchInfo.dispatchItems != null and tDispatchInfo.dispatchItems.size >0"> <if test="tDispatchInfo.dispatchItems != null and tDispatchInfo.dispatchItems.size >0">
AND AND
<foreach item="item" index="index" collection="tDispatchInfo.dispatchItems" open="(" separator="or" close=")"> <foreach item="item" index="index" collection="tDispatchInfo.dispatchItems" open="(" separator="or" close=")">
INSTR(a.DISPATCH_ITEM,#{item}) INSTR(a.DISPATCH_ITEM,#{item})
</foreach> </foreach>
</if> </if>
<if test="tDispatchInfo.empTypeList != null and tDispatchInfo.empTypeList.length>0"> <if test="tDispatchInfo.empTypeList != null and tDispatchInfo.empTypeList.length>0">
AND a.EMP_TYPE IN AND a.EMP_TYPE IN
<foreach collection="tDispatchInfo.empTypeList" item="item" index="index" open="(" separator="," close=")"> <foreach collection="tDispatchInfo.empTypeList" item="item" index="index" open="(" separator="," close=")">
#{item} #{item}
</foreach> </foreach>
</if> </if>
<if test="tDispatchInfo.fundProvince != null and tDispatchInfo.fundProvince.trim() != ''"> <if test="tDispatchInfo.fundProvince != null and tDispatchInfo.fundProvince.trim() != ''">
AND a.FUND_PROVINCE = #{tDispatchInfo.fundProvince} AND a.FUND_PROVINCE = #{tDispatchInfo.fundProvince}
</if> </if>
<if test="tDispatchInfo.type != null and tDispatchInfo.type.trim() != ''"> <if test="tDispatchInfo.type != null and tDispatchInfo.type.trim() != ''">
AND a.TYPE = #{tDispatchInfo.type} AND a.TYPE = #{tDispatchInfo.type}
</if> </if>
<if test="tDispatchInfo.fundCity != null and tDispatchInfo.fundCity.trim() != ''"> <if test="tDispatchInfo.fundCity != null and tDispatchInfo.fundCity.trim() != ''">
AND a.FUND_CITY = #{tDispatchInfo.fundCity} AND a.FUND_CITY = #{tDispatchInfo.fundCity}
</if> </if>
<if test="tDispatchInfo.fundTown != null and tDispatchInfo.fundTown.trim() != ''"> <if test="tDispatchInfo.fundTown != null and tDispatchInfo.fundTown.trim() != ''">
AND a.FUND_TOWN = #{tDispatchInfo.fundTown} AND a.FUND_TOWN = #{tDispatchInfo.fundTown}
</if> </if>
<if test="tDispatchInfo.empName != null and tDispatchInfo.empName.trim() != ''"> <if test="tDispatchInfo.empName != null and tDispatchInfo.empName.trim() != ''">
AND a.EMP_NAME like concat('%',#{tDispatchInfo.empName},'%') AND a.EMP_NAME like concat('%',#{tDispatchInfo.empName},'%')
</if> </if>
<if test="tDispatchInfo.empIdcard != null and tDispatchInfo.empIdcard.trim() != ''"> <if test="tDispatchInfo.empIdcard != null and tDispatchInfo.empIdcard.trim() != ''">
AND a.EMP_IDCARD like concat('%',#{tDispatchInfo.empIdcard},'%') AND a.EMP_IDCARD like concat('%',#{tDispatchInfo.empIdcard},'%')
</if> </if>
<if test="tDispatchInfo.status != null and tDispatchInfo.status.trim() != ''"> <if test="tDispatchInfo.status != null and tDispatchInfo.status.trim() != ''">
AND a.STATUS = #{tDispatchInfo.status} AND a.STATUS = #{tDispatchInfo.status}
</if> </if>
<if test="tDispatchInfo.settleDomain != null and tDispatchInfo.settleDomain.trim() != ''"> <if test="tDispatchInfo.settleDomain != null and tDispatchInfo.settleDomain.trim() != ''">
AND a.SETTLE_DOMAIN = #{tDispatchInfo.settleDomain} AND a.SETTLE_DOMAIN = #{tDispatchInfo.settleDomain}
</if> </if>
<if test="tDispatchInfo.settleDomainCode != null and tDispatchInfo.settleDomainCode.trim() != ''"> <if test="tDispatchInfo.settleDomainCode != null and tDispatchInfo.settleDomainCode.trim() != ''">
AND a.SETTLE_DOMAIN_CODE = #{tDispatchInfo.settleDomainCode} AND a.SETTLE_DOMAIN_CODE = #{tDispatchInfo.settleDomainCode}
</if> </if>
<if test="tDispatchInfo.socialHandleStatus != null and tDispatchInfo.socialHandleStatus.trim() != ''"> <if test="tDispatchInfo.socialHandleStatus != null and tDispatchInfo.socialHandleStatus.trim() != ''">
AND a.SOCIAL_HANDLE_STATUS = #{tDispatchInfo.socialHandleStatus} AND a.SOCIAL_HANDLE_STATUS = #{tDispatchInfo.socialHandleStatus}
</if> </if>
<if test="tDispatchInfo.createName != null and tDispatchInfo.createName.trim() != ''"> <if test="tDispatchInfo.createName != null and tDispatchInfo.createName.trim() != ''">
AND a.CREATE_NAME = #{tDispatchInfo.createName} AND a.CREATE_NAME = #{tDispatchInfo.createName}
</if> </if>
<if test="tDispatchInfo.settleDomainName != null and tDispatchInfo.settleDomainName.trim() != ''"> <if test="tDispatchInfo.settleDomainName != null and tDispatchInfo.settleDomainName.trim() != ''">
AND a.SETTLE_DOMAIN_NAME like CONCAT(CONCAT(#{tDispatchInfo.settleDomainName}), '%') AND a.SETTLE_DOMAIN_NAME like CONCAT(CONCAT(#{tDispatchInfo.settleDomainName}), '%')
</if> </if>
<if test="tDispatchInfo.belongUnitName != null and tDispatchInfo.belongUnitName.trim() != ''"> <if test="tDispatchInfo.belongUnitName != null and tDispatchInfo.belongUnitName.trim() != ''">
AND a.BELONG_UNIT_NAME = #{tDispatchInfo.belongUnitName} AND a.BELONG_UNIT_NAME = #{tDispatchInfo.belongUnitName}
</if> </if>
<if test="tDispatchInfo.createTimeEnd != null"> <if test="tDispatchInfo.createTimeEnd != null">
AND a.CREATE_TIME <![CDATA[<=]]> #{tDispatchInfo.createTimeEnd} AND a.CREATE_TIME <![CDATA[<=]]> #{tDispatchInfo.createTimeEnd}
</if> </if>
<if test="tDispatchInfo.createTimeStart != null"> <if test="tDispatchInfo.createTimeStart != null">
AND a.CREATE_TIME <![CDATA[>=]]> #{tDispatchInfo.createTimeStart} AND a.CREATE_TIME <![CDATA[>=]]> #{tDispatchInfo.createTimeStart}
</if> </if>
<if test="tDispatchInfo.auditTimeStart != null"> <if test="tDispatchInfo.auditTimeStart != null">
AND a.AUDIT_TIME <![CDATA[>=]]> #{tDispatchInfo.auditTimeStart} AND a.AUDIT_TIME <![CDATA[>=]]> #{tDispatchInfo.auditTimeStart}
</if> </if>
<if test="tDispatchInfo.auditTimeEnd != null"> <if test="tDispatchInfo.auditTimeEnd != null">
AND a.AUDIT_TIME <![CDATA[<=]]> #{tDispatchInfo.auditTimeEnd} AND a.AUDIT_TIME <![CDATA[<=]]> #{tDispatchInfo.auditTimeEnd}
</if> </if>
<if test="tDispatchInfo.auditUserName != null and tDispatchInfo.auditUserName.trim() != ''"> <if test="tDispatchInfo.auditUserName != null and tDispatchInfo.auditUserName.trim() != ''">
AND a.AUDIT_USER_NAME like concat('%',#{tDispatchInfo.auditUserName},'%') AND a.AUDIT_USER_NAME like concat('%',#{tDispatchInfo.auditUserName},'%')
</if> </if>
<if test="tDispatchInfo.providentHouseholdName != null and tDispatchInfo.providentHouseholdName.trim() != ''"> <if test="tDispatchInfo.providentHouseholdName != null and tDispatchInfo.providentHouseholdName.trim() != ''">
AND a.PROVIDENT_HOUSEHOLD_NAME like CONCAT(CONCAT(#{tDispatchInfo.providentHouseholdName}), '%') AND a.PROVIDENT_HOUSEHOLD_NAME like CONCAT(CONCAT(#{tDispatchInfo.providentHouseholdName}), '%')
</if> </if>
<if test="tDispatchInfo.authSql != null and tDispatchInfo.authSql.trim() != ''"> <if test="tDispatchInfo.authSql != null and tDispatchInfo.authSql.trim() != ''">
${tDispatchInfo.authSql} ${tDispatchInfo.authSql}
</if> </if>
<if test="tDispatchInfo.exportFundFlag != null and tDispatchInfo.exportFundFlag.trim() != ''"> <if test="tDispatchInfo.exportFundFlag != null and tDispatchInfo.exportFundFlag.trim() != ''">
AND a.EXPORT_FUND_FLAG = ${tDispatchInfo.exportFundFlag} AND a.EXPORT_FUND_FLAG = ${tDispatchInfo.exportFundFlag}
</if>
</if> </if>
</if>
</sql> </sql>
<sql id="where_getSocialDisRecord"> <sql id="where_getSocialDisRecord">
a.DELETE_FLAG = 0 a.DELETE_FLAG = 0
AND a.social_id is not null AND a.social_id is not null
<if test='tDispatchInfo.socialId != null and tDispatchInfo.socialId.trim() == "0" '>
AND a.social_id = #{tDispatchInfo.socialId}
</if>
<!-- dispatch-status 未提交1待审核2审核通过3审核不通过4办理完成5待SSC审核 --> <!-- dispatch-status 未提交1待审核2审核通过3审核不通过4办理完成5待SSC审核 -->
<if test='tDispatchInfo.auditStatus != null and tDispatchInfo.auditStatus.trim() == "0" '> <if test='tDispatchInfo.auditStatus != null and tDispatchInfo.auditStatus.trim() == "0" '>
AND a.STATUS in ('2','4') AND a.STATUS in ('2','4')
...@@ -2354,6 +2360,9 @@ ...@@ -2354,6 +2360,9 @@
<sql id="where_getSocialPersionDisRecord"> <sql id="where_getSocialPersionDisRecord">
a.DELETE_FLAG = 0 a.DELETE_FLAG = 0
AND a.social_id is not null AND a.social_id is not null
<if test='tDispatchInfo.socialId != null and tDispatchInfo.socialId.trim() == "0" '>
AND a.social_id = #{tDispatchInfo.socialId}
</if>
<!-- dispatch-status 未提交1待审核2审核通过3审核不通过4办理完成5待SSC审核 --> <!-- dispatch-status 未提交1待审核2审核通过3审核不通过4办理完成5待SSC审核 -->
<if test='tDispatchInfo.auditStatus != null and tDispatchInfo.auditStatus.trim() == "0"'> <if test='tDispatchInfo.auditStatus != null and tDispatchInfo.auditStatus.trim() == "0"'>
AND a.STATUS in ('2','4') AND a.STATUS in ('2','4')
...@@ -2392,7 +2401,7 @@ ...@@ -2392,7 +2401,7 @@
</select> </select>
<update id="updateExportSocialFlagById"> <update id="updateExportSocialFlagById">
update t_dispatch_info a set a.EXPORT_SOCIAL_FLAG = #{status} WHERE a.id = #{id} update t_dispatch_info a set a.EXPORT_SOCIAL_FLAG = #{status} WHERE a.id = #{id}
</update> </update>
<update id="updateExportFundFlagById"> <update id="updateExportFundFlagById">
update t_dispatch_info a set a.EXPORT_FUND_FLAG = #{status} WHERE a.id = #{id} update t_dispatch_info a set a.EXPORT_FUND_FLAG = #{status} WHERE a.id = #{id}
...@@ -2469,7 +2478,7 @@ ...@@ -2469,7 +2478,7 @@
count(a.EMP_IDCARD) as NUMBER, count(a.EMP_IDCARD) as NUMBER,
SUM(ROUND(((PERIOD_DIFF(#{tDispatchInfo.disMonth},REPLACE ( DATE_FORMAT( s.PROVIDENT_START, "%Y-%m" ), '-', '' )))+1)*s.UNIT_PROVIDENT_FEE*2 )) AS SUPPLEMENTART_AMOUNT_SUM SUM(ROUND(((PERIOD_DIFF(#{tDispatchInfo.disMonth},REPLACE ( DATE_FORMAT( s.PROVIDENT_START, "%Y-%m" ), '-', '' )))+1)*s.UNIT_PROVIDENT_FEE*2 )) AS SUPPLEMENTART_AMOUNT_SUM
FROM t_dispatch_info a FROM t_dispatch_info a
left join t_provident_fund s on s.id = a.FUND_ID left join t_provident_fund s on s.id = a.FUND_ID
<where> <where>
<include refid="where_getFund"/> <include refid="where_getFund"/>
</where> </where>
...@@ -2477,7 +2486,7 @@ ...@@ -2477,7 +2486,7 @@
<select id="getFundPersionExportVoOne" resultMap="CompanyProVo"> <select id="getFundPersionExportVoOne" resultMap="CompanyProVo">
SELECT SELECT
F.COMPANY_PRO AS COMPANY_PRO F.COMPANY_PRO AS COMPANY_PRO
FROM `sys_house_hold_info` A FROM `sys_house_hold_info` A
LEFT JOIN sys_area B ON A.PROVINCE = B.ID LEFT JOIN sys_area B ON A.PROVINCE = B.ID
LEFT JOIN sys_area C ON A.CITY = C.ID LEFT JOIN sys_area C ON A.CITY = C.ID
...@@ -2491,25 +2500,25 @@ ...@@ -2491,25 +2500,25 @@
<select id="getFundSumExportVoTwo" resultMap="HouseNameConfigVo"> <select id="getFundSumExportVoTwo" resultMap="HouseNameConfigVo">
SELECT SELECT
A.CUSTOMER_NO, A.CUSTOMER_NO,
A.FUND_BANK, A.FUND_BANK,
F.COMPANY_PRO AS COMPANY_PRO F.COMPANY_PRO AS COMPANY_PRO
FROM FROM
`sys_house_hold_info` A `sys_house_hold_info` A
LEFT JOIN sys_area B ON A.PROVINCE = B.ID LEFT JOIN sys_area B ON A.PROVINCE = B.ID
LEFT JOIN sys_area C ON A.CITY = C.ID LEFT JOIN sys_area C ON A.CITY = C.ID
LEFT JOIN sys_area D ON A.TOWN = D.ID LEFT JOIN sys_area D ON A.TOWN = D.ID
LEFT JOIN sys_base_set_info E ON A.ID = E.DEPART_ID LEFT JOIN sys_base_set_info E ON A.ID = E.DEPART_ID
LEFT JOIN sys_pay_proportion F ON E.ID = F.SYS_BASE_SET_ID LEFT JOIN sys_pay_proportion F ON E.ID = F.SYS_BASE_SET_ID
WHERE WHERE
A.TYPE = '1' A.TYPE = '1'
AND A.`NAME` IN (#{houseName}) AND A.`NAME` IN (#{houseName})
AND E.`STATUS` = '0' AND E.`STATUS` = '0'
AND AND
(PERIOD_DIFF(#{tDispatchInfo.disMonth},REPLACE ( DATE_FORMAT( E.APPLY_START_DATE , "%Y-%m" ), '-', '' )))>0 (PERIOD_DIFF(#{tDispatchInfo.disMonth},REPLACE ( DATE_FORMAT( E.APPLY_START_DATE , "%Y-%m" ), '-', '' )))>0
and and
((PERIOD_DIFF(#{tDispatchInfo.disMonth},REPLACE ( DATE_FORMAT( E.APPLY_END_DATE , "%Y-%m" ), '-', '' ))) <![CDATA[ < ]]>0 ((PERIOD_DIFF(#{tDispatchInfo.disMonth},REPLACE ( DATE_FORMAT( E.APPLY_END_DATE , "%Y-%m" ), '-', '' ))) <![CDATA[ < ]]>0
OR ( APPLY_END_DATE IS NULL OR APPLY_END_DATE = '' )) OR ( APPLY_END_DATE IS NULL OR APPLY_END_DATE = '' ))
GROUP BY A.`NAME` GROUP BY A.`NAME`
</select> </select>
<resultMap id="autoFlagMap" type="com.yifu.cloud.plus.v1.yifu.social.vo.AutoFlagVo"> <resultMap id="autoFlagMap" type="com.yifu.cloud.plus.v1.yifu.social.vo.AutoFlagVo">
...@@ -2518,7 +2527,7 @@ ...@@ -2518,7 +2527,7 @@
</resultMap> </resultMap>
<select id="getAutoFlag" resultMap="autoFlagMap"> <select id="getAutoFlag" resultMap="autoFlagMap">
select a.id as "dispatchId", select a.id as "dispatchId",
b.AUTO_STATUS as 'autoFlag' b.AUTO_STATUS as 'autoFlag'
FROM t_dispatch_info a FROM t_dispatch_info a
LEFT JOIN sys_house_hold_info b on a.SOCIAL_HOUSEHOLD_NAME=b.`NAME` and b.TYPE='0' LEFT JOIN sys_house_hold_info b on a.SOCIAL_HOUSEHOLD_NAME=b.`NAME` and b.TYPE='0'
where a.SOCIAL_HOUSEHOLD_NAME is not null where a.SOCIAL_HOUSEHOLD_NAME is not null
......
...@@ -23,32 +23,31 @@ ...@@ -23,32 +23,31 @@
<mapper namespace="com.yifu.cloud.plus.v1.yifu.social.mapper.TSocialDeadlineInfoMapper"> <mapper namespace="com.yifu.cloud.plus.v1.yifu.social.mapper.TSocialDeadlineInfoMapper">
<resultMap id="tSocialDeadlineInfoMap" type="com.yifu.cloud.plus.v1.yifu.social.entity.TSocialDeadlineInfo"> <resultMap id="tSocialDeadlineInfoMap" type="com.yifu.cloud.plus.v1.yifu.social.entity.TSocialDeadlineInfo">
<id property="id" column="ID"/> <id property="id" column="ID"/>
<result property="month" column="MONTH"/> <result property="month" column="MONTH"/>
<result property="province" column="PROVINCE"/> <result property="province" column="PROVINCE"/>
<result property="city" column="CITY"/> <result property="city" column="CITY"/>
<result property="town" column="TOWN"/> <result property="town" column="TOWN"/>
<result property="socialEndDate" column="SOCIAL_END_DATE"/> <result property="socialEndDate" column="SOCIAL_END_DATE"/>
<result property="medicalEndDate" column="MEDICAL_END_DATE"/> <result property="medicalEndDate" column="MEDICAL_END_DATE"/>
<result property="createBy" column="CREATE_BY"/> <result property="createBy" column="CREATE_BY"/>
<result property="createName" column="CREATE_NAME"/> <result property="createName" column="CREATE_NAME"/>
<result property="createTime" column="CREATE_TIME"/> <result property="createTime" column="CREATE_TIME"/>
<result property="updateBy" column="UPDATE_BY"/> <result property="updateBy" column="UPDATE_BY"/>
<result property="updateName" column="UPDATE_NAME"/> <result property="updateName" column="UPDATE_NAME"/>
<result property="updateTime" column="UPDATE_TIME"/> <result property="updateTime" column="UPDATE_TIME"/>
<result property="status" column="STATUS"/> <result property="status" column="STATUS"/>
<result property="type" column="TYPE"/> <result property="type" column="TYPE"/>
<result property="socialStartDate" column="SOCIAL_START_DATE"/> <result property="socialStartDate" column="SOCIAL_START_DATE"/>
<result property="medicalStartDate" column="MEDICAL_START_DATE"/> <result property="medicalStartDate" column="MEDICAL_START_DATE"/>
<result property="socialStartDateReduce" column="SOCIAL_START_DATE_REDUCE"/>
<result property="socialStartDateReduce" column="SOCIAL_START_DATE_REDUCE"/> <result property="medicalStartDateReduce" column="MEDICAL_START_DATE_REDUCE"/>
<result property="medicalStartDateReduce" column="MEDICAL_START_DATE_REDUCE"/> <result property="socialEndDateReduce" column="SOCIAL_END_DATE_REDUCE"/>
<result property="socialEndDateReduce" column="SOCIAL_END_DATE_REDUCE"/> <result property="medicalEndDateReduce" column="MEDICAL_END_DATE_REDUCE"/>
<result property="medicalEndDateReduce" column="MEDICAL_END_DATE_REDUCE"/> </resultMap>
</resultMap> <sql id="Base_Column_List">
<sql id="Base_Column_List"> a.ID,
a.ID,
a.MONTH, a.MONTH,
a.PROVINCE, a.PROVINCE,
a.CITY, a.CITY,
...@@ -62,77 +61,76 @@ ...@@ -62,77 +61,76 @@
a.UPDATE_NAME, a.UPDATE_NAME,
a.UPDATE_TIME, a.UPDATE_TIME,
a.STATUS,a.TYPE, a.STATUS,a.TYPE,
a.SOCIAL_START_DATE, a.SOCIAL_START_DATE,a.MEDICAL_START_DATE,
a.MEDICAL_START_DATE,
a.SOCIAL_START_DATE_REDUCE, a.SOCIAL_START_DATE_REDUCE,
a.MEDICAL_START_DATE_REDUCE, a.MEDICAL_START_DATE_REDUCE,
a.SOCIAL_END_DATE_REDUCE, a.SOCIAL_END_DATE_REDUCE,
a.MEDICAL_END_DATE_REDUCE a.MEDICAL_END_DATE_REDUCE
</sql> </sql>
<sql id="tSocialDeadlineInfo_where"> <sql id="tSocialDeadlineInfo_where">
<if test="tSocialDeadlineInfo != null"> <if test="tSocialDeadlineInfo != null">
<if test="tSocialDeadlineInfo.id != null and tSocialDeadlineInfo.id.trim() != ''"> <if test="tSocialDeadlineInfo.id != null and tSocialDeadlineInfo.id.trim() != ''">
AND a.ID = #{tSocialDeadlineInfo.id} AND a.ID = #{tSocialDeadlineInfo.id}
</if> </if>
<if test="tSocialDeadlineInfo.month != null and tSocialDeadlineInfo.month.trim() != ''"> <if test="tSocialDeadlineInfo.month != null and tSocialDeadlineInfo.month.trim() != ''">
AND a.MONTH = #{tSocialDeadlineInfo.month} AND a.MONTH = #{tSocialDeadlineInfo.month}
</if> </if>
<if test="tSocialDeadlineInfo.province != null and tSocialDeadlineInfo.province.trim() != ''"> <if test="tSocialDeadlineInfo.province != null and tSocialDeadlineInfo.province.trim() != ''">
AND a.PROVINCE = #{tSocialDeadlineInfo.province} AND a.PROVINCE = #{tSocialDeadlineInfo.province}
</if> </if>
<if test="tSocialDeadlineInfo.city != null and tSocialDeadlineInfo.city.trim() != ''"> <if test="tSocialDeadlineInfo.city != null and tSocialDeadlineInfo.city.trim() != ''">
AND a.CITY = #{tSocialDeadlineInfo.city} AND a.CITY = #{tSocialDeadlineInfo.city}
</if> </if>
<if test="tSocialDeadlineInfo.town != null and tSocialDeadlineInfo.town.trim() != ''"> <if test="tSocialDeadlineInfo.town != null and tSocialDeadlineInfo.town.trim() != ''">
AND a.TOWN = #{tSocialDeadlineInfo.town} AND a.TOWN = #{tSocialDeadlineInfo.town}
</if> </if>
<if test="tSocialDeadlineInfo.socialEndDate != null"> <if test="tSocialDeadlineInfo.socialEndDate != null">
AND a.SOCIAL_END_DATE = #{tSocialDeadlineInfo.socialEndDate} AND a.SOCIAL_END_DATE = #{tSocialDeadlineInfo.socialEndDate}
</if> </if>
<if test="tSocialDeadlineInfo.medicalEndDate != null"> <if test="tSocialDeadlineInfo.medicalEndDate != null">
AND a.MEDICAL_END_DATE = #{tSocialDeadlineInfo.medicalEndDate} AND a.MEDICAL_END_DATE = #{tSocialDeadlineInfo.medicalEndDate}
</if> </if>
<if test="tSocialDeadlineInfo.createBy != null and tSocialDeadlineInfo.createBy.trim() != ''"> <if test="tSocialDeadlineInfo.createBy != null and tSocialDeadlineInfo.createBy.trim() != ''">
AND a.CREATE_BY = #{tSocialDeadlineInfo.createBy} AND a.CREATE_BY = #{tSocialDeadlineInfo.createBy}
</if> </if>
<if test="tSocialDeadlineInfo.createName != null and tSocialDeadlineInfo.createName.trim() != ''"> <if test="tSocialDeadlineInfo.createName != null and tSocialDeadlineInfo.createName.trim() != ''">
AND a.CREATE_NAME = #{tSocialDeadlineInfo.createName} AND a.CREATE_NAME = #{tSocialDeadlineInfo.createName}
</if> </if>
<if test="tSocialDeadlineInfo.createTime != null"> <if test="tSocialDeadlineInfo.createTime != null">
AND a.CREATE_TIME = #{tSocialDeadlineInfo.createTime} AND a.CREATE_TIME = #{tSocialDeadlineInfo.createTime}
</if> </if>
<if test="tSocialDeadlineInfo.updateBy != null and tSocialDeadlineInfo.updateBy.trim() != ''"> <if test="tSocialDeadlineInfo.updateBy != null and tSocialDeadlineInfo.updateBy.trim() != ''">
AND a.UPDATE_BY = #{tSocialDeadlineInfo.updateBy} AND a.UPDATE_BY = #{tSocialDeadlineInfo.updateBy}
</if> </if>
<if test="tSocialDeadlineInfo.updateName != null and tSocialDeadlineInfo.updateName.trim() != ''"> <if test="tSocialDeadlineInfo.updateName != null and tSocialDeadlineInfo.updateName.trim() != ''">
AND a.UPDATE_NAME = #{tSocialDeadlineInfo.updateName} AND a.UPDATE_NAME = #{tSocialDeadlineInfo.updateName}
</if> </if>
<if test="tSocialDeadlineInfo.updateTime != null"> <if test="tSocialDeadlineInfo.updateTime != null">
AND a.UPDATE_TIME = #{tSocialDeadlineInfo.updateTime} AND a.UPDATE_TIME = #{tSocialDeadlineInfo.updateTime}
</if> </if>
<if test="tSocialDeadlineInfo.status != null and tSocialDeadlineInfo.status.trim() != ''"> <if test="tSocialDeadlineInfo.status != null and tSocialDeadlineInfo.status.trim() != ''">
AND a.STATUS = #{tSocialDeadlineInfo.status} AND a.STATUS = #{tSocialDeadlineInfo.status}
</if> </if>
<if test="tSocialDeadlineInfo.monthEnd != 0"> <if test="tSocialDeadlineInfo.monthEnd != 0">
AND a.MONTH <![CDATA[<=]]> #{tSocialDeadlineInfo.monthEnd} AND a.MONTH <![CDATA[<=]]> #{tSocialDeadlineInfo.monthEnd}
</if> </if>
<if test="tSocialDeadlineInfo.monthStart != 0"> <if test="tSocialDeadlineInfo.monthStart != 0">
AND a.MONTH <![CDATA[>=]]> #{tSocialDeadlineInfo.monthStart} AND a.MONTH <![CDATA[>=]]> #{tSocialDeadlineInfo.monthStart}
</if> </if>
<if test="tSocialDeadlineInfo.type != null and tSocialDeadlineInfo.type.trim() != ''"> <if test="tSocialDeadlineInfo.type != null and tSocialDeadlineInfo.type.trim() != ''">
AND a.TYPE = #{tSocialDeadlineInfo.type} AND a.TYPE = #{tSocialDeadlineInfo.type}
</if> </if>
</if> </if>
</sql> </sql>
<!--tSocialDeadlineInfo简单分页查询--> <!--tSocialDeadlineInfo简单分页查询-->
<select id="getTSocialDeadlineInfoPage" resultMap="tSocialDeadlineInfoMap"> <select id="getTSocialDeadlineInfoPage" resultMap="tSocialDeadlineInfoMap">
SELECT SELECT
<include refid="Base_Column_List"/> <include refid="Base_Column_List"/>
FROM t_social_deadline_info a FROM t_social_deadline_info a
<where> <where>
1=1 1=1
<include refid="tSocialDeadlineInfo_where"/> <include refid="tSocialDeadlineInfo_where"/>
</where> </where>
order by a.month DESC order by a.month DESC
</select> </select>
</mapper> </mapper>
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