k94314517
2025-05-15 6544203a132369d9d1db2531596f837fcc9fa39f
git ch
已添加1个文件
已修改4个文件
346 ■■■■■ 文件已修改
server/service/src/main/java/com/doumee/core/utils/Constants.java 23 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
server/service/src/main/java/com/doumee/dao/business/dto/SettleClaimsDTO.java 98 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
server/service/src/main/java/com/doumee/dao/business/model/SettleClaims.java 25 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
server/service/src/main/java/com/doumee/service/business/impl/SettleClaimsServiceImpl.java 198 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
server/service/src/main/java/com/doumee/service/system/impl/SystemDictDataServiceImpl.java 2 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
server/service/src/main/java/com/doumee/core/utils/Constants.java
@@ -767,6 +767,7 @@
        LP_STAMP_FILE(31, "保险公司理赔盖章文件", "保险公司理赔盖章文件"),
        LP_FILE(32, "保险公司上传理赔材料一览表", "保险公司上传理赔材料一览表"),
        LP_OTHER_FILE(33, "理赔其他材料", "理赔其他材料"),
        ;
        // æˆå‘˜å˜é‡
@@ -1932,11 +1933,23 @@
    public  enum SettleClaimsStatus {
        WAIT_ACCEPTANCE(0, "待受理"),
        RETURN_ACCEPTANCE(1, "退回受理"),
        DEAL_ING(2, "受理中"),
        CONFIRM_INFORMATION(3, "确认资料"),
        FINISH_ACCEPTANCE(4, "完成受理"),
        //状态 0暂存中 1已报案 2待立案 3已立案 4立案退回 5待受理 6拒绝受理 7商议待审批
        // 8商议审批拒绝 9已受理 10待核赔  11已核赔 12待结案 13已结案 14已撤案
        WAIT_ACCEPTANCE(0, "暂存中"),
        RETURN_ACCEPTANCE(1, "已报案"),
        DEAL_ING(2, "待立案"),
        CONFIRM_INFORMATION(3, "已立案"),
        FINISH_ACCEPTANCE(4, "立案退回"),
        WAIT_DEAL(5, "待受理"),
        REJECT_DEAL(6, "拒绝受理"),
        WAIT_DISCUSS_AUDIT(7, "待商议审批"),
        WAIT_DISCUSS_REJECT(8, "商议审批拒绝"),
        ACCEPTANCE(9, "已受理"),
        WAIT_AUDIT_COMPENSATION(10, "待核赔"),
        COMPENSATION(11, "已核赔"),
        WAIT_CLOSE_CASE(12, "待结案"),
        CLOSE_CASE(13, "待结案"),
        RETURN(14, "已撤案"),
        ;
        // æˆå‘˜å˜é‡
        private String name;
server/service/src/main/java/com/doumee/dao/business/dto/SettleClaimsDTO.java
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,98 @@
package com.doumee.dao.business.dto;
import com.baomidou.mybatisplus.annotation.TableField;
import com.doumee.core.annotation.excel.ExcelColumn;
import com.doumee.dao.business.model.Multifile;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import java.util.List;
/**
 * Created by IntelliJ IDEA.
 *
 * @Author : Rk
 * @create 2025/5/15 11:19
 */
@Data
public class SettleClaimsDTO {
    @ApiModelProperty(value = "存储类型:1=保存;0=暂存;")
    private Integer saveType;
    @ApiModelProperty(value = "出险人")
    private Integer memberId;
    @ApiModelProperty(value = "出险人")
    private String idcardNo;
    @ApiModelProperty(value = "方案编码(关联solutions)", example = "1")
    private Integer solutionId;
    @ApiModelProperty(value = "派遣单位编码(关联dispatch_unit)", example = "1")
    private Integer duId;
    @ApiModelProperty(value = "工种编码(关联worktype)", example = "1")
    private Integer worktypeId;
    @ApiModelProperty(value = "事故发生时间")
    private String happenTime;
    @ApiModelProperty(value = "就诊医疗机构")
    private String hospital;
    @ApiModelProperty(value = "出险地区(关联areas)", example = "1")
    private String areaId;
    @ApiModelProperty(value = "出险地区名称(省市)")
    private String areaInfo;
    @ApiModelProperty(value = "事故描述")
    private String content;
    @ApiModelProperty(value = "事故类型 0工作期间受伤 1上下班途中受伤 2非工作时间受伤 3意外受伤", example = "1")
    private Integer type;
    @ApiModelProperty(value = "就诊类型:0住院 1门诊", example = "1")
    private Integer inHospital;
    @ApiModelProperty(value = "是否伤残: 0是 1否 2待确定")
    private String hurtType;
    @ApiModelProperty(value = "是否有医疗保险 0是 1否", example = "1")
    private Integer medicalInsurance;
    @ApiModelProperty(value = "报案视频")
    private List<Multifile> reportFileList;
    @ApiModelProperty(value = "报案人姓名")
    private String informantName;
    @ApiModelProperty(value = "报案人联系方式")
    private String informantPhone;
    @ApiModelProperty(value = "员工关系资料")
    private List<Multifile> relationFileList;
    @ApiModelProperty(value = "门诊资料")
    private List<Multifile> outpatientFileList;
    @ApiModelProperty(value = "住院资料")
    private List<Multifile> hospitalFileList;
    @ApiModelProperty(value = "伤残资料")
    private List<Multifile> disabilityFileList;
    @ApiModelProperty(value = "其他资料")
    private List<Multifile> otherFileList;
    @ApiModelProperty(value = "收款银行")
    private String receiveBank;
    @ApiModelProperty(value = "收款人")
    private String receiveUserName;
    @ApiModelProperty(value = "收款账户")
    private String receiveAccount;
}
server/service/src/main/java/com/doumee/dao/business/model/SettleClaims.java
@@ -88,6 +88,7 @@
    @ApiModelProperty(value = "费用", example = "1")
    @ExcelColumn(name="费用")
    private BigDecimal fee;
    @ApiModelProperty(value = "审核时间")
    @ExcelColumn(name="审核时间")
@@ -104,7 +105,7 @@
    @ExcelColumn(name="单号")
    private String code;
    @ApiModelProperty(value = "状态 0待受理(处理中) 1退回受理(已撤案) 2确认资料(处理中) 3完成受理(已结案)", example = "1")
    @ApiModelProperty(value = "状态 å¼ƒç”¨(0待受理(处理中) 1退回受理(已撤案)2受理中  3确认资料(处理中) 4完成受理(已结案)) 5待受理 6受理退回 7待商议 8商议待审批 9商议审批拒绝 10已受理", example = "1")
    @ExcelColumn(name="状态 0待受理(处理中) 1退回受理(已撤案) 2确认资料(处理中) 3完成受理(已结案)")
    private Integer status;
@@ -112,8 +113,8 @@
    @ExcelColumn(name="事故类型 0工作期间受伤 1上下班途中受伤 2非工作时间受伤 3意外受伤")
    private Integer type;
    @ApiModelProperty(value = "是否住院 0是 1否", example = "1")
    @ExcelColumn(name="是否住院 0是 1否")
    @ApiModelProperty(value = "就诊类型:0住院 1门诊", example = "1")
    @ExcelColumn(name="就诊类型:0住院 1门诊")
    private Integer inHospital;
    @ApiModelProperty(value = "是否有医疗保险 0是 1否", example = "1")
@@ -212,6 +213,24 @@
    @ApiModelProperty(value = "整体状态 0未提交 1待立案 2待受理 3")
    @ExcelColumn(name="整体状态")
    private String allStatus;
    @ApiModelProperty(value = "收款银行")
    @ExcelColumn(name="收款银行")
    private String receiveBank;
    @ApiModelProperty(value = "收款人")
    @ExcelColumn(name="收款人")
    private String receiveUserName;
    @ApiModelProperty(value = "收款账户")
    @ExcelColumn(name="收款账户")
    private String receiveAccount;
    @ApiModelProperty(value = "保险单附件")
    @TableField(exist = false)
    private  Multifile  baoxiandanFile;
server/service/src/main/java/com/doumee/service/business/impl/SettleClaimsServiceImpl.java
@@ -13,6 +13,7 @@
import com.doumee.dao.business.SettleClaimsLogMapper;
import com.doumee.dao.business.SettleClaimsMapper;
import com.doumee.dao.business.dto.SCSupplementDTO;
import com.doumee.dao.business.dto.SettleClaimsDTO;
import com.doumee.dao.business.join.MultifileJoinMapper;
import com.doumee.dao.business.join.SettleClaimsJoinMapper;
import com.doumee.dao.business.join.SettleClaimsLogJoinMapper;
@@ -26,10 +27,12 @@
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.github.xiaoymin.knife4j.core.util.CollectionUtils;
import com.github.yulichang.wrapper.MPJLambdaWrapper;
import io.swagger.annotations.ApiModelProperty;
import org.apache.commons.compress.archivers.zip.ZipArchiveEntry;
import org.apache.commons.compress.archivers.zip.ZipArchiveOutputStream;
import org.apache.commons.lang3.StringUtils;
import org.apache.shiro.SecurityUtils;
import org.springframework.beans.BeanUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
@@ -940,4 +943,199 @@
        QueryWrapper<SettleClaims> wrapper = new QueryWrapper<>(settleClaims);
        return settleClaimsMapper.selectCount(wrapper);
    }
    public void saveSettleClaims(SettleClaimsDTO settleClaimsDTO){
        LoginUserInfo loginUserInfo = (LoginUserInfo) SecurityUtils.getSubject().getPrincipal();
        if(!loginUserInfo.getType().equals(Constants.ONE)){
            throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(),"非企业员工无法进行该操作");
        }
        if(Objects.isNull(settleClaimsDTO)
            || Objects.isNull(settleClaimsDTO.getSaveType())
            || Objects.isNull(settleClaimsDTO.getMemberId())
            ||StringUtils.isBlank(settleClaimsDTO.getIdcardNo())
        ){
            throw new BusinessException(ResponseStatus.BAD_REQUEST);
        }
        if(Constants.equalsInteger(settleClaimsDTO.getSaveType(),Constants.ONE)){
            if(Objects.isNull(settleClaimsDTO.getSolutionId())
                    ||Objects.isNull(settleClaimsDTO.getWorktypeId())
                    ||Objects.isNull(settleClaimsDTO.getDuId())
                    ||StringUtils.isBlank(settleClaimsDTO.getHappenTime())
                    ||StringUtils.isBlank(settleClaimsDTO.getContent())
                    ||Objects.isNull(settleClaimsDTO.getType())
                    ||Objects.isNull(settleClaimsDTO.getInHospital())
                    ||Objects.isNull(settleClaimsDTO.getHurtType())
                    ||Objects.isNull(settleClaimsDTO.getMedicalInsurance())
                    ||StringUtils.isBlank(settleClaimsDTO.getInformantName())
                    ||StringUtils.isBlank(settleClaimsDTO.getInformantPhone())
                    ||StringUtils.isBlank(settleClaimsDTO.getReceiveUserName())
                    ||StringUtils.isBlank(settleClaimsDTO.getReceiveBank())
                    ||StringUtils.isBlank(settleClaimsDTO.getReceiveAccount())
            ){
                throw new BusinessException(ResponseStatus.BAD_REQUEST);
            }
        }
        SettleClaims settleClaims = new SettleClaims();
        BeanUtils.copyProperties(settleClaimsDTO,settleClaims);
        if(Objects.nonNull(settleClaims.getId())){
            settleClaims.setEditDate(new Date());
            settleClaims.setEditor(loginUserInfo.getId());
            settleClaimsMapper.updateById(settleClaims);
        }else{
            settleClaims.setCreateDate(new Date());
            settleClaims.setIsdeleted(Constants.ZERO);
            settleClaims.setCompanyId(loginUserInfo.getCompanyId());
            settleClaims.setStatus(Constants.equalsInteger(settleClaimsDTO.getSaveType(),Constants.ONE)?
                    Constants.SettleClaimsStatus.RETURN_ACCEPTANCE.getKey():Constants.SettleClaimsStatus.WAIT_ACCEPTANCE.getKey());
            settleClaims.setCreator(loginUserInfo.getId());
            settleClaims.setCheckUserId(loginUserInfo.getId());
            settleClaimsMapper.insert(settleClaims);
        }
        this.saveFile(settleClaims,settleClaimsDTO,loginUserInfo);
    }
    public void saveFile(SettleClaims settleClaims,SettleClaimsDTO settleClaimsDTO,LoginUserInfo loginUserInfo){
        multifileJoinMapper.delete(new QueryWrapper<Multifile>().lambda()
                .eq(Multifile::getObjId,settleClaims.getId())
                .in(Multifile::getObjType,
                        Constants.MultiFile.LP_SGXC_FILE.getKey(),
                        Constants.MultiFile.LP_YGGX_FILE.getKey(),
                        Constants.MultiFile.LP_MZCL_FILE.getKey(),
                        Constants.MultiFile.LP_ZYCL_FILE.getKey(),
                        Constants.MultiFile.LP_OTHER_FILE.getKey(),
                        Constants.MultiFile.LP_SCZL_FILE.getKey()
                )
        );
        List<Multifile> reportVideo = settleClaimsDTO.getReportFileList();
        if(CollectionUtils.isNotEmpty(reportVideo)){
            for (int i = 0; i < reportVideo.size(); i++) {
                Multifile multifile = reportVideo.get(i);
                if(Objects.isNull(multifile.getFileurl())
                        || Objects.isNull(multifile.getType())
                        || StringUtils.isBlank(multifile.getName())
                ){
                    throw new BusinessException(ResponseStatus.BAD_REQUEST.getCode(),"附件内容异常");
                }
                multifile.setCreator(loginUserInfo.getId());
                multifile.setCreateDate(new Date());
                multifile.setIsdeleted(Constants.ZERO);
                multifile.setObjId(settleClaims.getId());
                multifile.setObjType(Constants.MultiFile.LP_SGXC_FILE.getKey());
                multifile.setSortnum(i+1);
                multifileJoinMapper.insert(multifile);
            }
        }
        List<Multifile> relationFileList = settleClaimsDTO.getRelationFileList();
        if(CollectionUtils.isNotEmpty(relationFileList)){
            for (int i = 0; i < reportVideo.size(); i++) {
                Multifile multifile = reportVideo.get(i);
                if(Objects.isNull(multifile.getFileurl())
                        || Objects.isNull(multifile.getType())
                        || StringUtils.isBlank(multifile.getName())
                ){
                    throw new BusinessException(ResponseStatus.BAD_REQUEST.getCode(),"附件内容异常");
                }
                multifile.setCreator(loginUserInfo.getId());
                multifile.setCreateDate(new Date());
                multifile.setIsdeleted(Constants.ZERO);
                multifile.setObjId(settleClaims.getId());
                multifile.setObjType(Constants.MultiFile.LP_YGGX_FILE.getKey());
                multifile.setSortnum(i+1);
                multifileJoinMapper.insert(multifile);
            }
        }
        List<Multifile> outpatientFileList = settleClaimsDTO.getOutpatientFileList();
        if(CollectionUtils.isNotEmpty(outpatientFileList)){
            for (int i = 0; i < reportVideo.size(); i++) {
                Multifile multifile = reportVideo.get(i);
                if(Objects.isNull(multifile.getFileurl())
                        || Objects.isNull(multifile.getType())
                        || StringUtils.isBlank(multifile.getName())
                ){
                    throw new BusinessException(ResponseStatus.BAD_REQUEST.getCode(),"附件内容异常");
                }
                multifile.setCreator(loginUserInfo.getId());
                multifile.setCreateDate(new Date());
                multifile.setIsdeleted(Constants.ZERO);
                multifile.setObjId(settleClaims.getId());
                multifile.setObjType(Constants.MultiFile.LP_MZCL_FILE.getKey());
                multifile.setSortnum(i+1);
                multifileJoinMapper.insert(multifile);
            }
        }
        List<Multifile> hospitalFileList = settleClaimsDTO.getHospitalFileList();
        if(CollectionUtils.isNotEmpty(hospitalFileList)){
            for (int i = 0; i < reportVideo.size(); i++) {
                Multifile multifile = reportVideo.get(i);
                if(Objects.isNull(multifile.getFileurl())
                        || Objects.isNull(multifile.getType())
                        || StringUtils.isBlank(multifile.getName())
                ){
                    throw new BusinessException(ResponseStatus.BAD_REQUEST.getCode(),"附件内容异常");
                }
                multifile.setCreator(loginUserInfo.getId());
                multifile.setCreateDate(new Date());
                multifile.setIsdeleted(Constants.ZERO);
                multifile.setObjId(settleClaims.getId());
                multifile.setObjType(Constants.MultiFile.LP_ZYCL_FILE.getKey());
                multifile.setSortnum(i+1);
                multifileJoinMapper.insert(multifile);
            }
        }
        List<Multifile> disabilityFileList = settleClaimsDTO.getDisabilityFileList();
        if(CollectionUtils.isNotEmpty(disabilityFileList)){
            for (int i = 0; i < reportVideo.size(); i++) {
                Multifile multifile = reportVideo.get(i);
                if(Objects.isNull(multifile.getFileurl())
                        || Objects.isNull(multifile.getType())
                        || StringUtils.isBlank(multifile.getName())
                ){
                    throw new BusinessException(ResponseStatus.BAD_REQUEST.getCode(),"附件内容异常");
                }
                multifile.setCreator(loginUserInfo.getId());
                multifile.setCreateDate(new Date());
                multifile.setIsdeleted(Constants.ZERO);
                multifile.setObjId(settleClaims.getId());
                multifile.setObjType(Constants.MultiFile.LP_SCZL_FILE.getKey());
                multifile.setSortnum(i+1);
                multifileJoinMapper.insert(multifile);
            }
        }
        List<Multifile> otherFileList = settleClaimsDTO.getOtherFileList();
        if(CollectionUtils.isNotEmpty(otherFileList)){
            for (int i = 0; i < reportVideo.size(); i++) {
                Multifile multifile = reportVideo.get(i);
                if(Objects.isNull(multifile.getFileurl())
                        || Objects.isNull(multifile.getType())
                        || StringUtils.isBlank(multifile.getName())
                ){
                    throw new BusinessException(ResponseStatus.BAD_REQUEST.getCode(),"附件内容异常");
                }
                multifile.setCreator(loginUserInfo.getId());
                multifile.setCreateDate(new Date());
                multifile.setIsdeleted(Constants.ZERO);
                multifile.setObjId(settleClaims.getId());
                multifile.setObjType(Constants.MultiFile.LP_OTHER_FILE.getKey());
                multifile.setSortnum(i+1);
                multifileJoinMapper.insert(multifile);
            }
        }
    }
}
server/service/src/main/java/com/doumee/service/system/impl/SystemDictDataServiceImpl.java
@@ -211,6 +211,8 @@
                    systemDictData.setCode(riskConfigDTO.getRiskSensitiveWordsOpen());
                }else if(systemDictData.getLabel().equals(Constants.RISK_SENSITIVE_WORDS)){
                    systemDictData.setCode(riskConfigDTO.getRiskSensitiveWords());
                }else{
                    continue;
                }
                systemDictDataMapper.updateById(systemDictData);
            }