Commit 59dc1a92 authored by fangxinjiang's avatar fangxinjiang

险种增加字段见费出单-fxj

parent 1724575e
......@@ -91,4 +91,10 @@ public class TInsuranceType extends BaseEntity {
@Schema(description = "启用状态")
private String enable;
/**
* 是否见费出单 0是 1 否
*/
@NotBlank(message = "是否见费出单不能为空")
@Schema(description = "是否见费出单")
private String isJfcd;
}
\ No newline at end of file
......@@ -61,4 +61,10 @@ public class InsuranceTypeExportVo {
@Schema(description = "启用状态")
private String enable;
/**
* 是否见费出单 0是 1 否
*/
@Schema(description = "是否见费出单")
private String isJfcd;
}
......@@ -93,6 +93,10 @@ public class TInsuranceTypeServiceImpl extends ServiceImpl<TInsuranceTypeMapper,
if(!ValidityUtil.validate50(receiptUnitName)){
return R.failed("收款单位名称格式不正确");
}
if (!CommonConstants.ZERO_STRING.equals(insuranceType.getIsJfcd())
&& !CommonConstants.ONE_STRING.equals(insuranceType.getIsJfcd())){
return R.failed("是否见费出单必填且只能为是或否");
}
LambdaQueryWrapper<TInsuranceCompany> companyWrapper = new LambdaQueryWrapper<>();
companyWrapper.eq(TInsuranceCompany::getId,companyId).eq(TInsuranceCompany::getDeleteFlag, CommonConstants.ZERO_INT);
TInsuranceCompany insuranceCompany = tInsuranceCompanyService.getOne(companyWrapper);
......@@ -158,6 +162,10 @@ public class TInsuranceTypeServiceImpl extends ServiceImpl<TInsuranceTypeMapper,
if(Common.isEmpty(byId) || byId.getDeleteFlag() == CommonConstants.ONE_INT){
return R.failed("当前险种信息不存在或已被删除");
}
if (!CommonConstants.ZERO_STRING.equals(insuranceType.getIsJfcd())
&& !CommonConstants.ONE_STRING.equals(insuranceType.getIsJfcd())){
return R.failed("是否见费出单必填且只能为是或否");
}
if(byId.getName().equals(insuranceType.getName())){
insuranceType.setUpdateBy(user.getId());
insuranceType.setUpdateTime(LocalDateTime.now());
......
......@@ -19,6 +19,7 @@
<result property="updateTime" column="UPDATE_TIME" jdbcType="TIMESTAMP"/>
<result property="isAdress" column="IS_ADRESS" jdbcType="VARCHAR"/>
<result property="enable" column="ENABLE" jdbcType="VARCHAR"/>
<result property="isJfcd" column="IS_JFCD" jdbcType="VARCHAR"/>
</resultMap>
<sql id="Base_Column_List">
......@@ -68,7 +69,7 @@
a.BANK_NAME as bankName,
a.BANK_NO as bankNo,
a.AGE_LIMIT as ageLimit,
a.IS_ADRESS as isAdress,a.ENABLE as enable
a.IS_ADRESS as isAdress,a.ENABLE as enable,a.IS_JFCD as isJfcd
from
t_insurance_type a,
t_insurance_company b
......@@ -91,6 +92,9 @@
<if test="insuranceType.enable != null and insuranceType.enable.trim() != ''">
and a.ENABLE = #{insuranceType.enable}
</if>
<if test="insuranceType.isJfcd != null and insuranceType.isJfcd.trim() != ''">
and a.IS_JFCD = #{insuranceType.isJfcd}
</if>
ORDER BY a.CREATE_TIME DESC
</select>
......@@ -102,7 +106,7 @@
a.BANK_NO as bankNo,
a.RECEIPT_UNIT_NAME as receiptUnitName,
if(a.AGE_LIMIT = '0','限制(16-70岁)','无') as ageLimit,
if(a.IS_ADRESS = '0','是',if(ifnull(a.IS_ADRESS,3) = 3,'','否')) as isAdress,a.ENABLE as enable
if(a.IS_ADRESS = '0','是',if(ifnull(a.IS_ADRESS,3) = 3,'','否')) as isAdress,a.ENABLE as enable,a.IS_JFCD as isJfcd
from
t_insurance_type a,
t_insurance_company b
......@@ -122,6 +126,9 @@
<if test="insuranceType.enable != null and insuranceType.enable.trim() != ''">
and a.ENABLE = #{insuranceType.enable}
</if>
<if test="insuranceType.isJfcd != null and insuranceType.isJfcd.trim() != ''">
and a.IS_JFCD = #{insuranceType.isJfcd}
</if>
ORDER BY a.CREATE_TIME DESC
</select>
......@@ -136,7 +143,7 @@
a.BANK_NAME as bankName,
a.BANK_NO as bankNo,
a.AGE_LIMIT as ageLimit,
a.IS_ADRESS as isAdress,a.ENABLE as enable
a.IS_ADRESS as isAdress,a.ENABLE as enable,a.IS_JFCD as isJfcd
from
t_insurance_type a,
t_insurance_company b
......
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