jiangping
2024-01-26 0afc0d40e019c168d47a79e90bdff2aba29ad553
开发业务接口
已修改3个文件
39 ■■■■■ 文件已修改
company/src/components/business/OperaInsuranceApplyWindow.vue 12 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
server/service/src/main/java/com/doumee/core/utils/Constants.java 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
server/service/src/main/java/com/doumee/service/business/impl/InsuranceApplyServiceImpl.java 23 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
company/src/components/business/OperaInsuranceApplyWindow.vue
@@ -16,12 +16,12 @@
                    </div>
                    <div class="desc_item_label_right">
                        <el-button type="primary" @click="$refs.InsuranceDetails.open('投保详情单')">导出详单</el-button>
                        <el-button type="primary" @click="visible2 = true">上传投保单</el-button>
                        <el-button type="primary" @click="visible3 = true">上传保险单</el-button>
                        <el-button type="primary" @click="visible5 = true">驳回退回申请</el-button>
                        <el-button type="primary" @click="$refs.InsuranceDetails.open('投保详情单')">投保审核</el-button>
                        <el-button type="danger" @click="visible1 = true">退回投保</el-button>
                        <el-button type="danger" @click="visible4 = true">修改保险单</el-button>
                        <el-button v-if="model.status == 0 " type="primary" @click="visible2 = true">上传投保单</el-button>
                        <el-button v-if="model.status == 3 "  type="primary" @click="visible3 = true">上传保险单</el-button>
                        <el-button  v-if="model.status == 6 || model.status == 7|| model.status == 8" type="primary" @click="visible5 = true">处理退回申请</el-button>
                        <el-button v-if="model.status == 0 "  type="primary" @click="$refs.InsuranceDetails.open('投保详情单')">投保审核</el-button>
                        <el-button v-if="model.status != 5 " type="danger" @click="visible1 = true">退回投保</el-button>
                        <el-button v-if="model.status == 5 "  type="danger" @click="visible4 = true">修改保险单</el-button>
                    </div>
                </div>
                <div class="desc_item_from">
server/service/src/main/java/com/doumee/core/utils/Constants.java
@@ -732,9 +732,9 @@
        CA_PALTFORM_REFUSE_APPLY(20, "驳回退回申请",""),
        CA_PALTFORM_EDIT_PIDAN(21, "修改批单","修改原因:${param}"),
        PALTFORM_EDIT_BD(22, "修改保单","修改原因:${param}"),
        CA_JIAJIAN_APPLY_SIGN(23, "加减保申请企业签章",""),
        CA_CHANGUNIT_APPLY_SIGN(24, "换成申请企业签章",""),
        CA_JIAJIAN_APPLY_SIGN(23, "加减保申请企业签章",""),
        ;
        // 成员变量
        private String name;
@@ -803,7 +803,7 @@
        COMPANY_BACK_APPLY_WAIT_SIGNATURE(7, "企业申请退回(待签章)","提交意见:${param}",5),
        COMPANY_BACK_APPLY_SIGNATURE(8, "企业申请退回(已签章)","提交意见:${param}",5),
        CLOSE(9, "订单关闭","",6),
        PLATFORM_CHECK_PASS(10,"平台投保审核通过","",1),
        PLATFORM_CHECK_PASS(10,"平台投保审核通过","提交意见:${param}",1),
        ;
        // 成员变量
        private String name;
server/service/src/main/java/com/doumee/service/business/impl/InsuranceApplyServiceImpl.java
@@ -100,7 +100,7 @@
        InsuranceApply update = new InsuranceApply();
        update.setEditDate(new Date());
        update.setEditor(user.getId());
        update.setStatus(Constants.InsuranceApplyStatus.PLATFORM_RETURN.getKey());
        update.setStatus(Constants.InsuranceApplyStatus.FAIL_RETURN.getKey());
        update.setCheckDate(update.getEditDate());
        update.setCheckInfo(insuranceApply.getCheckInfo());
        update.setCheckUserId(user.getId());
@@ -530,14 +530,14 @@
    }
    /**
     * 审核通过
     * 审核通过或者不通过
     * @param insuranceApply
     * @return
     */
    @Override
    @Transactional(rollbackFor = {Exception.class,BusinessException.class})
    public Integer check(InsuranceApply insuranceApply) {
        if(insuranceApply.getId() == null ||StringUtils.isBlank(insuranceApply.getCheckInfo())){
        if(insuranceApply.getId() == null || StringUtils.isBlank(insuranceApply.getCheckInfo())){
            throw  new BusinessException(ResponseStatus.BAD_REQUEST);
        }
        InsuranceApply model = insuranceApplyMapper.selectById(insuranceApply.getId());
@@ -548,19 +548,28 @@
        if(!Constants.equalsInteger(model.getStatus(),Constants.InsuranceApplyStatus.UPLOAD.getKey())){
            throw  new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(),"对不起,该申请状态已流转,当前不支持该操作~");
        }
        Constants.ApplyLogType applyLogType = null;
        LoginUserInfo user = (LoginUserInfo) SecurityUtils.getSubject().getPrincipal();
        InsuranceApply update = new InsuranceApply();
        update.setEditDate(new Date());
        update.setEditor(user.getId());
        update.setStatus(Constants.InsuranceApplyStatus.PLATFORM_CHECK_PASS.getKey());
        update.setCheckDate(update.getEditDate());
        update.setCheckInfo(insuranceApply.getCheckInfo());
        update.setCheckUserId(user.getId());
        update.setId(model.getId());
        if(insuranceApply.getDealBackApply() ==1){
            //如果是不通过
            applyLogType = Constants.ApplyLogType.PLATFORM_RETURN ;
            update.setStatus(Constants.InsuranceApplyStatus.PLATFORM_RETURN.getKey());
        }else{
            applyLogType = Constants.ApplyLogType.PLATFORM_CHECK_PASS;
            update.setStatus(Constants.InsuranceApplyStatus.PLATFORM_CHECK_PASS.getKey());
        }
        insuranceApplyMapper.updateById(update);
        Constants.ApplyLogType applyLogType = Constants.ApplyLogType.PLATFORM_CHECK_PASS;
        ApplyLog log = new ApplyLog(update,applyLogType.getName(),null,update.getId(),applyLogType.getKey(),JSONObject.toJSONString(model), JSONObject.toJSONString(update));
        String info =applyLogType.getInfo();
        info = info.replace("${param}", update.getCheckInfo());
        ApplyLog log = new ApplyLog(update,applyLogType.getName(),info,update.getId(),applyLogType.getKey(),JSONObject.toJSONString(model), JSONObject.toJSONString(update));
        applyLogMapper.insert(log);
        return  1;