中介新增 修改接口
This commit is contained in:
@@ -0,0 +1,154 @@
|
||||
package com.ruoyi.dpc.controller;
|
||||
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.dpc.domain.vo.EnumOptionVO;
|
||||
import com.ruoyi.dpc.enums.*;
|
||||
import io.swagger.v3.oas.annotations.Operation;
|
||||
import io.swagger.v3.oas.annotations.tags.Tag;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* DPC枚举接口Controller
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
@Tag(name = "DPC枚举接口", description = "中介黑名单相关枚举选项接口")
|
||||
@RestController
|
||||
@RequestMapping("/dpc/enum")
|
||||
public class DpcEnumController {
|
||||
|
||||
/**
|
||||
* 获取人员类型选项
|
||||
*/
|
||||
@Operation(summary = "获取人员类型选项")
|
||||
@GetMapping("/indivType")
|
||||
public AjaxResult getIndivTypeOptions() {
|
||||
List<EnumOptionVO> options = new ArrayList<>();
|
||||
for (IndivType type : IndivType.values()) {
|
||||
options.add(new EnumOptionVO(type.getCode(), type.getDesc()));
|
||||
}
|
||||
return AjaxResult.success(options);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取人员子类型选项
|
||||
*/
|
||||
@Operation(summary = "获取人员子类型选项")
|
||||
@GetMapping("/indivSubType")
|
||||
public AjaxResult getIndivSubTypeOptions() {
|
||||
List<EnumOptionVO> options = new ArrayList<>();
|
||||
for (IndivSubType type : IndivSubType.values()) {
|
||||
options.add(new EnumOptionVO(type.getCode(), type.getDesc()));
|
||||
}
|
||||
return AjaxResult.success(options);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取性别选项
|
||||
*/
|
||||
@Operation(summary = "获取性别选项")
|
||||
@GetMapping("/gender")
|
||||
public AjaxResult getGenderOptions() {
|
||||
List<EnumOptionVO> options = new ArrayList<>();
|
||||
for (Gender gender : Gender.values()) {
|
||||
options.add(new EnumOptionVO(gender.getCode(), gender.getDesc()));
|
||||
}
|
||||
return AjaxResult.success(options);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取证件类型选项
|
||||
*/
|
||||
@Operation(summary = "获取证件类型选项")
|
||||
@GetMapping("/certType")
|
||||
public AjaxResult getCertTypeOptions() {
|
||||
List<EnumOptionVO> options = new ArrayList<>();
|
||||
for (CertType type : CertType.values()) {
|
||||
options.add(new EnumOptionVO(type.getCode(), type.getDesc()));
|
||||
}
|
||||
return AjaxResult.success(options);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取关联关系选项
|
||||
*/
|
||||
@Operation(summary = "获取关联关系选项")
|
||||
@GetMapping("/relationType")
|
||||
public AjaxResult getRelationTypeOptions() {
|
||||
List<EnumOptionVO> options = new ArrayList<>();
|
||||
for (RelationType type : RelationType.values()) {
|
||||
options.add(new EnumOptionVO(type.getCode(), type.getDesc()));
|
||||
}
|
||||
return AjaxResult.success(options);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取主体类型选项
|
||||
*/
|
||||
@Operation(summary = "获取主体类型选项")
|
||||
@GetMapping("/corpType")
|
||||
public AjaxResult getCorpTypeOptions() {
|
||||
List<EnumOptionVO> options = new ArrayList<>();
|
||||
for (CorpType type : CorpType.values()) {
|
||||
options.add(new EnumOptionVO(type.getCode(), type.getDesc()));
|
||||
}
|
||||
return AjaxResult.success(options);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取企业性质选项
|
||||
*/
|
||||
@Operation(summary = "获取企业性质选项")
|
||||
@GetMapping("/corpNature")
|
||||
public AjaxResult getCorpNatureOptions() {
|
||||
List<EnumOptionVO> options = new ArrayList<>();
|
||||
for (CorpNature nature : CorpNature.values()) {
|
||||
options.add(new EnumOptionVO(nature.getCode(), nature.getDesc()));
|
||||
}
|
||||
return AjaxResult.success(options);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取中介类型选项
|
||||
*/
|
||||
@Operation(summary = "获取中介类型选项")
|
||||
@GetMapping("/intermediaryType")
|
||||
public AjaxResult getIntermediaryTypeOptions() {
|
||||
List<EnumOptionVO> options = new ArrayList<>();
|
||||
for (IntermediaryType type : IntermediaryType.values()) {
|
||||
options.add(new EnumOptionVO(type.getCode(), type.getDesc()));
|
||||
}
|
||||
return AjaxResult.success(options);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取中介状态选项
|
||||
*/
|
||||
@Operation(summary = "获取中介状态选项")
|
||||
@GetMapping("/intermediaryStatus")
|
||||
public AjaxResult getIntermediaryStatusOptions() {
|
||||
List<EnumOptionVO> options = new ArrayList<>();
|
||||
for (IntermediaryStatus status : IntermediaryStatus.values()) {
|
||||
options.add(new EnumOptionVO(status.getCode(), status.getDesc()));
|
||||
}
|
||||
return AjaxResult.success(options);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取数据来源选项
|
||||
*/
|
||||
@Operation(summary = "获取数据来源选项")
|
||||
@GetMapping("/dataSource")
|
||||
public AjaxResult getDataSourceOptions() {
|
||||
List<EnumOptionVO> options = new ArrayList<>();
|
||||
for (DataSource source : DataSource.values()) {
|
||||
options.add(new EnumOptionVO(source.getCode(), source.getDesc()));
|
||||
}
|
||||
return AjaxResult.success(options);
|
||||
}
|
||||
}
|
||||
@@ -9,9 +9,7 @@ import com.ruoyi.common.core.page.TableDataInfo;
|
||||
import com.ruoyi.common.core.page.TableSupport;
|
||||
import com.ruoyi.common.enums.BusinessType;
|
||||
import com.ruoyi.dpc.domain.DpcIntermediaryBlacklist;
|
||||
import com.ruoyi.dpc.domain.dto.DpcIntermediaryBlacklistAddDTO;
|
||||
import com.ruoyi.dpc.domain.dto.DpcIntermediaryBlacklistEditDTO;
|
||||
import com.ruoyi.dpc.domain.dto.DpcIntermediaryBlacklistQueryDTO;
|
||||
import com.ruoyi.dpc.domain.dto.*;
|
||||
import com.ruoyi.dpc.domain.excel.DpcIntermediaryBlacklistExcel;
|
||||
import com.ruoyi.dpc.domain.excel.DpcIntermediaryEntityExcel;
|
||||
import com.ruoyi.dpc.domain.excel.DpcIntermediaryPersonExcel;
|
||||
@@ -80,27 +78,73 @@ public class DpcIntermediaryBlacklistController extends BaseController {
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增中介黑名单
|
||||
* 新增中介黑名单(已废弃,请使用类型专用接口)
|
||||
*/
|
||||
@Operation(summary = "新增中介黑名单")
|
||||
@Operation(summary = "新增中介黑名单(已废弃,请使用类型专用接口)")
|
||||
@PreAuthorize("@ss.hasPermi('dpc:intermediary:add')")
|
||||
@Log(title = "中介黑名单", businessType = BusinessType.INSERT)
|
||||
@PostMapping
|
||||
@Deprecated
|
||||
public AjaxResult add(@Validated @RequestBody DpcIntermediaryBlacklistAddDTO addDTO) {
|
||||
return toAjax(intermediaryService.insertIntermediary(addDTO));
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增个人中介黑名单
|
||||
*/
|
||||
@Operation(summary = "新增个人中介黑名单")
|
||||
@PreAuthorize("@ss.hasPermi('dpc:intermediary:add')")
|
||||
@Log(title = "个人中介黑名单", businessType = BusinessType.INSERT)
|
||||
@PostMapping("/person")
|
||||
public AjaxResult addPerson(@Validated @RequestBody DpcIntermediaryPersonAddDTO addDTO) {
|
||||
return toAjax(intermediaryService.insertPersonIntermediary(addDTO));
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增机构中介黑名单
|
||||
*/
|
||||
@Operation(summary = "新增机构中介黑名单")
|
||||
@PreAuthorize("@ss.hasPermi('dpc:intermediary:add')")
|
||||
@Log(title = "机构中介黑名单", businessType = BusinessType.INSERT)
|
||||
@PostMapping("/entity")
|
||||
public AjaxResult addEntity(@Validated @RequestBody DpcIntermediaryEntityAddDTO addDTO) {
|
||||
return toAjax(intermediaryService.insertEntityIntermediary(addDTO));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改中介黑名单
|
||||
*/
|
||||
@Operation(summary = "修改中介黑名单")
|
||||
@Operation(summary = "修改中介黑名单(已废弃,请使用类型专用接口)")
|
||||
@PreAuthorize("@ss.hasPermi('dpc:intermediary:edit')")
|
||||
@Log(title = "中介黑名单", businessType = BusinessType.UPDATE)
|
||||
@PutMapping
|
||||
@Deprecated
|
||||
public AjaxResult edit(@Validated @RequestBody DpcIntermediaryBlacklistEditDTO editDTO) {
|
||||
return toAjax(intermediaryService.updateIntermediary(editDTO));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改个人中介黑名单
|
||||
*/
|
||||
@Operation(summary = "修改个人中介黑名单")
|
||||
@PreAuthorize("@ss.hasPermi('dpc:intermediary:edit')")
|
||||
@Log(title = "个人中介黑名单", businessType = BusinessType.UPDATE)
|
||||
@PutMapping("/person")
|
||||
public AjaxResult editPerson(@Validated @RequestBody DpcIntermediaryPersonEditDTO editDTO) {
|
||||
return toAjax(intermediaryService.updatePersonIntermediary(editDTO));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改机构中介黑名单
|
||||
*/
|
||||
@Operation(summary = "修改机构中介黑名单")
|
||||
@PreAuthorize("@ss.hasPermi('dpc:intermediary:edit')")
|
||||
@Log(title = "机构中介黑名单", businessType = BusinessType.UPDATE)
|
||||
@PutMapping("/entity")
|
||||
public AjaxResult editEntity(@Validated @RequestBody DpcIntermediaryEntityEditDTO editDTO) {
|
||||
return toAjax(intermediaryService.updateEntityIntermediary(editDTO));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除中介黑名单
|
||||
*/
|
||||
@@ -137,7 +181,7 @@ public class DpcIntermediaryBlacklistController extends BaseController {
|
||||
@PreAuthorize("@ss.hasPermi('dpc:intermediary:import')")
|
||||
@Log(title = "中介黑名单", businessType = BusinessType.IMPORT)
|
||||
@PostMapping("/importPersonData")
|
||||
public AjaxResult importPersonData(MultipartFile file, boolean updateSupport) throws Exception {
|
||||
public AjaxResult importPersonData(@RequestParam("file") MultipartFile file, @RequestParam(value = "updateSupport", defaultValue = "false") boolean updateSupport) throws Exception {
|
||||
List<DpcIntermediaryPersonExcel> list = EasyExcelUtil.importExcel(file.getInputStream(), DpcIntermediaryPersonExcel.class);
|
||||
String message = intermediaryService.importPersonIntermediary(list, updateSupport);
|
||||
return success(message);
|
||||
@@ -150,7 +194,7 @@ public class DpcIntermediaryBlacklistController extends BaseController {
|
||||
@PreAuthorize("@ss.hasPermi('dpc:intermediary:import')")
|
||||
@Log(title = "中介黑名单", businessType = BusinessType.IMPORT)
|
||||
@PostMapping("/importEntityData")
|
||||
public AjaxResult importEntityData(MultipartFile file, boolean updateSupport) throws Exception {
|
||||
public AjaxResult importEntityData(@RequestParam("file") MultipartFile file, @RequestParam(value = "updateSupport", defaultValue = "false") boolean updateSupport) throws Exception {
|
||||
List<DpcIntermediaryEntityExcel> list = EasyExcelUtil.importExcel(file.getInputStream(), DpcIntermediaryEntityExcel.class);
|
||||
String message = intermediaryService.importEntityIntermediary(list, updateSupport);
|
||||
return success(message);
|
||||
|
||||
@@ -111,18 +111,23 @@ public class DpcIntermediaryBlacklist implements Serializable {
|
||||
private String corpLegalCertNo;
|
||||
|
||||
/** 股东1 */
|
||||
@TableField("corp_shareholder_1")
|
||||
private String corpShareholder1;
|
||||
|
||||
/** 股东2 */
|
||||
@TableField("corp_shareholder_2")
|
||||
private String corpShareholder2;
|
||||
|
||||
/** 股东3 */
|
||||
@TableField("corp_shareholder_3")
|
||||
private String corpShareholder3;
|
||||
|
||||
/** 股东4 */
|
||||
@TableField("corp_shareholder_4")
|
||||
private String corpShareholder4;
|
||||
|
||||
/** 股东5 */
|
||||
@TableField("corp_shareholder_5")
|
||||
private String corpShareholder5;
|
||||
|
||||
// ============================================================
|
||||
|
||||
@@ -30,10 +30,6 @@ public class DpcIntermediaryBlacklistAddDTO implements Serializable {
|
||||
@NotBlank(message = "中介类型不能为空")
|
||||
private String intermediaryType;
|
||||
|
||||
/** 状态 */
|
||||
@NotBlank(message = "状态不能为空")
|
||||
private String status;
|
||||
|
||||
/** 备注 */
|
||||
@Size(max = 500, message = "备注长度不能超过500个字符")
|
||||
private String remark;
|
||||
@@ -62,14 +58,6 @@ public class DpcIntermediaryBlacklistAddDTO implements Serializable {
|
||||
this.intermediaryType = intermediaryType;
|
||||
}
|
||||
|
||||
public String getStatus() {
|
||||
return status;
|
||||
}
|
||||
|
||||
public void setStatus(String status) {
|
||||
this.status = status;
|
||||
}
|
||||
|
||||
public String getRemark() {
|
||||
return remark;
|
||||
}
|
||||
|
||||
@@ -6,6 +6,7 @@ import jakarta.validation.constraints.Size;
|
||||
|
||||
import java.io.Serial;
|
||||
import java.io.Serializable;
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* 中介人员黑名单编辑 DTO
|
||||
@@ -43,6 +44,90 @@ public class DpcIntermediaryBlacklistEditDTO implements Serializable {
|
||||
@Size(max = 500, message = "备注长度不能超过500个字符")
|
||||
private String remark;
|
||||
|
||||
// ============================================================
|
||||
// 个人类型字段 (以 indiv_ 前缀标识,individual 缩写)
|
||||
// ============================================================
|
||||
/** 人员类型(中介、职业背债人、房产中介等) */
|
||||
private String indivType;
|
||||
|
||||
/** 人员子类型(本人、配偶等) */
|
||||
private String indivSubType;
|
||||
|
||||
/** 性别(M男 F女 O其他) */
|
||||
private String indivGender;
|
||||
|
||||
/** 证件类型 */
|
||||
private String indivCertType;
|
||||
|
||||
/** 手机号码(加密存储) */
|
||||
private String indivPhone;
|
||||
|
||||
/** 微信号 */
|
||||
private String indivWechat;
|
||||
|
||||
/** 联系地址 */
|
||||
private String indivAddress;
|
||||
|
||||
/** 所在公司 */
|
||||
private String indivCompany;
|
||||
|
||||
/** 职位/职务 */
|
||||
private String indivPosition;
|
||||
|
||||
/** 关联人员ID */
|
||||
private String indivRelatedId;
|
||||
|
||||
/** 关联关系 */
|
||||
private String indivRelation;
|
||||
|
||||
// ============================================================
|
||||
// 机构类型字段 (以 corp_ 前缀标识,corporation 缩写)
|
||||
// ============================================================
|
||||
/** 统一社会信用代码 */
|
||||
private String corpCreditCode;
|
||||
|
||||
/** 主体类型(有限责任公司、股份有限公司等) */
|
||||
private String corpType;
|
||||
|
||||
/** 企业性质(国企、民企、外企等) */
|
||||
private String corpNature;
|
||||
|
||||
/** 行业分类 */
|
||||
private String corpIndustryCategory;
|
||||
|
||||
/** 所属行业 */
|
||||
private String corpIndustry;
|
||||
|
||||
/** 成立日期 */
|
||||
private Date corpEstablishDate;
|
||||
|
||||
/** 注册地址 */
|
||||
private String corpAddress;
|
||||
|
||||
/** 法定代表人 */
|
||||
private String corpLegalRep;
|
||||
|
||||
/** 法定代表人证件类型 */
|
||||
private String corpLegalCertType;
|
||||
|
||||
/** 法定代表人证件号码 */
|
||||
private String corpLegalCertNo;
|
||||
|
||||
/** 股东1 */
|
||||
private String corpShareholder1;
|
||||
|
||||
/** 股东2 */
|
||||
private String corpShareholder2;
|
||||
|
||||
/** 股东3 */
|
||||
private String corpShareholder3;
|
||||
|
||||
/** 股东4 */
|
||||
private String corpShareholder4;
|
||||
|
||||
/** 股东5 */
|
||||
private String corpShareholder5;
|
||||
|
||||
public Long getIntermediaryId() {
|
||||
return intermediaryId;
|
||||
}
|
||||
@@ -90,4 +175,212 @@ public class DpcIntermediaryBlacklistEditDTO implements Serializable {
|
||||
public void setRemark(String remark) {
|
||||
this.remark = remark;
|
||||
}
|
||||
|
||||
public String getIndivType() {
|
||||
return indivType;
|
||||
}
|
||||
|
||||
public void setIndivType(String indivType) {
|
||||
this.indivType = indivType;
|
||||
}
|
||||
|
||||
public String getIndivSubType() {
|
||||
return indivSubType;
|
||||
}
|
||||
|
||||
public void setIndivSubType(String indivSubType) {
|
||||
this.indivSubType = indivSubType;
|
||||
}
|
||||
|
||||
public String getIndivGender() {
|
||||
return indivGender;
|
||||
}
|
||||
|
||||
public void setIndivGender(String indivGender) {
|
||||
this.indivGender = indivGender;
|
||||
}
|
||||
|
||||
public String getIndivCertType() {
|
||||
return indivCertType;
|
||||
}
|
||||
|
||||
public void setIndivCertType(String indivCertType) {
|
||||
this.indivCertType = indivCertType;
|
||||
}
|
||||
|
||||
public String getIndivPhone() {
|
||||
return indivPhone;
|
||||
}
|
||||
|
||||
public void setIndivPhone(String indivPhone) {
|
||||
this.indivPhone = indivPhone;
|
||||
}
|
||||
|
||||
public String getIndivWechat() {
|
||||
return indivWechat;
|
||||
}
|
||||
|
||||
public void setIndivWechat(String indivWechat) {
|
||||
this.indivWechat = indivWechat;
|
||||
}
|
||||
|
||||
public String getIndivAddress() {
|
||||
return indivAddress;
|
||||
}
|
||||
|
||||
public void setIndivAddress(String indivAddress) {
|
||||
this.indivAddress = indivAddress;
|
||||
}
|
||||
|
||||
public String getIndivCompany() {
|
||||
return indivCompany;
|
||||
}
|
||||
|
||||
public void setIndivCompany(String indivCompany) {
|
||||
this.indivCompany = indivCompany;
|
||||
}
|
||||
|
||||
public String getIndivPosition() {
|
||||
return indivPosition;
|
||||
}
|
||||
|
||||
public void setIndivPosition(String indivPosition) {
|
||||
this.indivPosition = indivPosition;
|
||||
}
|
||||
|
||||
public String getIndivRelatedId() {
|
||||
return indivRelatedId;
|
||||
}
|
||||
|
||||
public void setIndivRelatedId(String indivRelatedId) {
|
||||
this.indivRelatedId = indivRelatedId;
|
||||
}
|
||||
|
||||
public String getIndivRelation() {
|
||||
return indivRelation;
|
||||
}
|
||||
|
||||
public void setIndivRelation(String indivRelation) {
|
||||
this.indivRelation = indivRelation;
|
||||
}
|
||||
|
||||
public String getCorpCreditCode() {
|
||||
return corpCreditCode;
|
||||
}
|
||||
|
||||
public void setCorpCreditCode(String corpCreditCode) {
|
||||
this.corpCreditCode = corpCreditCode;
|
||||
}
|
||||
|
||||
public String getCorpType() {
|
||||
return corpType;
|
||||
}
|
||||
|
||||
public void setCorpType(String corpType) {
|
||||
this.corpType = corpType;
|
||||
}
|
||||
|
||||
public String getCorpNature() {
|
||||
return corpNature;
|
||||
}
|
||||
|
||||
public void setCorpNature(String corpNature) {
|
||||
this.corpNature = corpNature;
|
||||
}
|
||||
|
||||
public String getCorpIndustryCategory() {
|
||||
return corpIndustryCategory;
|
||||
}
|
||||
|
||||
public void setCorpIndustryCategory(String corpIndustryCategory) {
|
||||
this.corpIndustryCategory = corpIndustryCategory;
|
||||
}
|
||||
|
||||
public String getCorpIndustry() {
|
||||
return corpIndustry;
|
||||
}
|
||||
|
||||
public void setCorpIndustry(String corpIndustry) {
|
||||
this.corpIndustry = corpIndustry;
|
||||
}
|
||||
|
||||
public Date getCorpEstablishDate() {
|
||||
return corpEstablishDate;
|
||||
}
|
||||
|
||||
public void setCorpEstablishDate(Date corpEstablishDate) {
|
||||
this.corpEstablishDate = corpEstablishDate;
|
||||
}
|
||||
|
||||
public String getCorpAddress() {
|
||||
return corpAddress;
|
||||
}
|
||||
|
||||
public void setCorpAddress(String corpAddress) {
|
||||
this.corpAddress = corpAddress;
|
||||
}
|
||||
|
||||
public String getCorpLegalRep() {
|
||||
return corpLegalRep;
|
||||
}
|
||||
|
||||
public void setCorpLegalRep(String corpLegalRep) {
|
||||
this.corpLegalRep = corpLegalRep;
|
||||
}
|
||||
|
||||
public String getCorpLegalCertType() {
|
||||
return corpLegalCertType;
|
||||
}
|
||||
|
||||
public void setCorpLegalCertType(String corpLegalCertType) {
|
||||
this.corpLegalCertType = corpLegalCertType;
|
||||
}
|
||||
|
||||
public String getCorpLegalCertNo() {
|
||||
return corpLegalCertNo;
|
||||
}
|
||||
|
||||
public void setCorpLegalCertNo(String corpLegalCertNo) {
|
||||
this.corpLegalCertNo = corpLegalCertNo;
|
||||
}
|
||||
|
||||
public String getCorpShareholder1() {
|
||||
return corpShareholder1;
|
||||
}
|
||||
|
||||
public void setCorpShareholder1(String corpShareholder1) {
|
||||
this.corpShareholder1 = corpShareholder1;
|
||||
}
|
||||
|
||||
public String getCorpShareholder2() {
|
||||
return corpShareholder2;
|
||||
}
|
||||
|
||||
public void setCorpShareholder2(String corpShareholder2) {
|
||||
this.corpShareholder2 = corpShareholder2;
|
||||
}
|
||||
|
||||
public String getCorpShareholder3() {
|
||||
return corpShareholder3;
|
||||
}
|
||||
|
||||
public void setCorpShareholder3(String corpShareholder3) {
|
||||
this.corpShareholder3 = corpShareholder3;
|
||||
}
|
||||
|
||||
public String getCorpShareholder4() {
|
||||
return corpShareholder4;
|
||||
}
|
||||
|
||||
public void setCorpShareholder4(String corpShareholder4) {
|
||||
this.corpShareholder4 = corpShareholder4;
|
||||
}
|
||||
|
||||
public String getCorpShareholder5() {
|
||||
return corpShareholder5;
|
||||
}
|
||||
|
||||
public void setCorpShareholder5(String corpShareholder5) {
|
||||
this.corpShareholder5 = corpShareholder5;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -2,17 +2,19 @@ package com.ruoyi.dpc.domain.dto;
|
||||
|
||||
import jakarta.validation.constraints.NotBlank;
|
||||
import jakarta.validation.constraints.Size;
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serial;
|
||||
import java.io.Serializable;
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* 机构中介黑名单新增 DTO
|
||||
* 机构中介新增 DTO
|
||||
*
|
||||
* @author ruoyi
|
||||
* @date 2026-01-29
|
||||
*/
|
||||
@Data
|
||||
public class DpcIntermediaryEntityAddDTO implements Serializable {
|
||||
|
||||
@Serial
|
||||
@@ -23,18 +25,8 @@ public class DpcIntermediaryEntityAddDTO implements Serializable {
|
||||
@Size(min = 1, max = 100, message = "机构名称长度不能超过100个字符")
|
||||
private String name;
|
||||
|
||||
/** 状态 */
|
||||
@NotBlank(message = "状态不能为空")
|
||||
private String status;
|
||||
|
||||
/** 备注 */
|
||||
@Size(max = 500, message = "备注长度不能超过500个字符")
|
||||
private String remark;
|
||||
|
||||
// ============================================================
|
||||
// 机构专属字段
|
||||
// ============================================================
|
||||
/** 统一社会信用代码 */
|
||||
@NotBlank(message = "统一社会信用代码不能为空")
|
||||
@Size(max = 18, message = "统一社会信用代码长度不能超过18个字符")
|
||||
private String corpCreditCode;
|
||||
|
||||
@@ -93,147 +85,11 @@ public class DpcIntermediaryEntityAddDTO implements Serializable {
|
||||
@Size(max = 30, message = "股东5长度不能超过30个字符")
|
||||
private String corpShareholder5;
|
||||
|
||||
public String getName() {
|
||||
return name;
|
||||
}
|
||||
/** 状态 */
|
||||
@NotBlank(message = "状态不能为空")
|
||||
private String status;
|
||||
|
||||
public void setName(String name) {
|
||||
this.name = name;
|
||||
}
|
||||
|
||||
public String getStatus() {
|
||||
return status;
|
||||
}
|
||||
|
||||
public void setStatus(String status) {
|
||||
this.status = status;
|
||||
}
|
||||
|
||||
public String getRemark() {
|
||||
return remark;
|
||||
}
|
||||
|
||||
public void setRemark(String remark) {
|
||||
this.remark = remark;
|
||||
}
|
||||
|
||||
public String getCorpCreditCode() {
|
||||
return corpCreditCode;
|
||||
}
|
||||
|
||||
public void setCorpCreditCode(String corpCreditCode) {
|
||||
this.corpCreditCode = corpCreditCode;
|
||||
}
|
||||
|
||||
public String getCorpType() {
|
||||
return corpType;
|
||||
}
|
||||
|
||||
public void setCorpType(String corpType) {
|
||||
this.corpType = corpType;
|
||||
}
|
||||
|
||||
public String getCorpNature() {
|
||||
return corpNature;
|
||||
}
|
||||
|
||||
public void setCorpNature(String corpNature) {
|
||||
this.corpNature = corpNature;
|
||||
}
|
||||
|
||||
public String getCorpIndustryCategory() {
|
||||
return corpIndustryCategory;
|
||||
}
|
||||
|
||||
public void setCorpIndustryCategory(String corpIndustryCategory) {
|
||||
this.corpIndustryCategory = corpIndustryCategory;
|
||||
}
|
||||
|
||||
public String getCorpIndustry() {
|
||||
return corpIndustry;
|
||||
}
|
||||
|
||||
public void setCorpIndustry(String corpIndustry) {
|
||||
this.corpIndustry = corpIndustry;
|
||||
}
|
||||
|
||||
public Date getCorpEstablishDate() {
|
||||
return corpEstablishDate;
|
||||
}
|
||||
|
||||
public void setCorpEstablishDate(Date corpEstablishDate) {
|
||||
this.corpEstablishDate = corpEstablishDate;
|
||||
}
|
||||
|
||||
public String getCorpAddress() {
|
||||
return corpAddress;
|
||||
}
|
||||
|
||||
public void setCorpAddress(String corpAddress) {
|
||||
this.corpAddress = corpAddress;
|
||||
}
|
||||
|
||||
public String getCorpLegalRep() {
|
||||
return corpLegalRep;
|
||||
}
|
||||
|
||||
public void setCorpLegalRep(String corpLegalRep) {
|
||||
this.corpLegalRep = corpLegalRep;
|
||||
}
|
||||
|
||||
public String getCorpLegalCertType() {
|
||||
return corpLegalCertType;
|
||||
}
|
||||
|
||||
public void setCorpLegalCertType(String corpLegalCertType) {
|
||||
this.corpLegalCertType = corpLegalCertType;
|
||||
}
|
||||
|
||||
public String getCorpLegalCertNo() {
|
||||
return corpLegalCertNo;
|
||||
}
|
||||
|
||||
public void setCorpLegalCertNo(String corpLegalCertNo) {
|
||||
this.corpLegalCertNo = corpLegalCertNo;
|
||||
}
|
||||
|
||||
public String getCorpShareholder1() {
|
||||
return corpShareholder1;
|
||||
}
|
||||
|
||||
public void setCorpShareholder1(String corpShareholder1) {
|
||||
this.corpShareholder1 = corpShareholder1;
|
||||
}
|
||||
|
||||
public String getCorpShareholder2() {
|
||||
return corpShareholder2;
|
||||
}
|
||||
|
||||
public void setCorpShareholder2(String corpShareholder2) {
|
||||
this.corpShareholder2 = corpShareholder2;
|
||||
}
|
||||
|
||||
public String getCorpShareholder3() {
|
||||
return corpShareholder3;
|
||||
}
|
||||
|
||||
public void setCorpShareholder3(String corpShareholder3) {
|
||||
this.corpShareholder3 = corpShareholder3;
|
||||
}
|
||||
|
||||
public String getCorpShareholder4() {
|
||||
return corpShareholder4;
|
||||
}
|
||||
|
||||
public void setCorpShareholder4(String corpShareholder4) {
|
||||
this.corpShareholder4 = corpShareholder4;
|
||||
}
|
||||
|
||||
public String getCorpShareholder5() {
|
||||
return corpShareholder5;
|
||||
}
|
||||
|
||||
public void setCorpShareholder5(String corpShareholder5) {
|
||||
this.corpShareholder5 = corpShareholder5;
|
||||
}
|
||||
/** 备注 */
|
||||
@Size(max = 500, message = "备注长度不能超过500个字符")
|
||||
private String remark;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,89 @@
|
||||
package com.ruoyi.dpc.domain.dto;
|
||||
|
||||
import jakarta.validation.constraints.NotBlank;
|
||||
import jakarta.validation.constraints.NotNull;
|
||||
import jakarta.validation.constraints.Size;
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serial;
|
||||
import java.io.Serializable;
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* 机构中介编辑 DTO
|
||||
*
|
||||
* @author ruoyi
|
||||
* @date 2026-01-29
|
||||
*/
|
||||
@Data
|
||||
public class DpcIntermediaryEntityEditDTO implements Serializable {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** 中介ID */
|
||||
@NotNull(message = "中介ID不能为空")
|
||||
private Long intermediaryId;
|
||||
|
||||
/** 机构名称 */
|
||||
@NotBlank(message = "机构名称不能为空")
|
||||
@Size(min = 1, max = 100, message = "机构名称长度不能超过100个字符")
|
||||
private String name;
|
||||
|
||||
/** 证件号(统一社会信用代码) */
|
||||
@Size(max = 50, message = "证件号长度不能超过50个字符")
|
||||
private String certificateNo;
|
||||
|
||||
/** 统一社会信用代码 */
|
||||
private String corpCreditCode;
|
||||
|
||||
/** 主体类型(有限责任公司、股份有限公司等) */
|
||||
private String corpType;
|
||||
|
||||
/** 企业性质(国企、民企、外企等) */
|
||||
private String corpNature;
|
||||
|
||||
/** 行业分类 */
|
||||
private String corpIndustryCategory;
|
||||
|
||||
/** 所属行业 */
|
||||
private String corpIndustry;
|
||||
|
||||
/** 成立日期 */
|
||||
private Date corpEstablishDate;
|
||||
|
||||
/** 注册地址 */
|
||||
private String corpAddress;
|
||||
|
||||
/** 法定代表人 */
|
||||
private String corpLegalRep;
|
||||
|
||||
/** 法定代表人证件类型 */
|
||||
private String corpLegalCertType;
|
||||
|
||||
/** 法定代表人证件号码 */
|
||||
private String corpLegalCertNo;
|
||||
|
||||
/** 股东1 */
|
||||
private String corpShareholder1;
|
||||
|
||||
/** 股东2 */
|
||||
private String corpShareholder2;
|
||||
|
||||
/** 股东3 */
|
||||
private String corpShareholder3;
|
||||
|
||||
/** 股东4 */
|
||||
private String corpShareholder4;
|
||||
|
||||
/** 股东5 */
|
||||
private String corpShareholder5;
|
||||
|
||||
/** 状态 */
|
||||
@NotBlank(message = "状态不能为空")
|
||||
private String status;
|
||||
|
||||
/** 备注 */
|
||||
@Size(max = 500, message = "备注长度不能超过500个字符")
|
||||
private String remark;
|
||||
}
|
||||
@@ -2,16 +2,18 @@ package com.ruoyi.dpc.domain.dto;
|
||||
|
||||
import jakarta.validation.constraints.NotBlank;
|
||||
import jakarta.validation.constraints.Size;
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serial;
|
||||
import java.io.Serializable;
|
||||
|
||||
/**
|
||||
* 个人中介黑名单新增 DTO
|
||||
* 个人中介新增 DTO
|
||||
*
|
||||
* @author ruoyi
|
||||
* @date 2026-01-29
|
||||
*/
|
||||
@Data
|
||||
public class DpcIntermediaryPersonAddDTO implements Serializable {
|
||||
|
||||
@Serial
|
||||
@@ -22,31 +24,20 @@ public class DpcIntermediaryPersonAddDTO implements Serializable {
|
||||
@Size(min = 1, max = 100, message = "姓名长度不能超过100个字符")
|
||||
private String name;
|
||||
|
||||
/** 证件号码 */
|
||||
@NotBlank(message = "证件号码不能为空")
|
||||
@Size(max = 50, message = "证件号码长度不能超过50个字符")
|
||||
/** 证件号 */
|
||||
@NotBlank(message = "证件号不能为空")
|
||||
@Size(max = 50, message = "证件号长度不能超过50个字符")
|
||||
private String certificateNo;
|
||||
|
||||
/** 状态 */
|
||||
@NotBlank(message = "状态不能为空")
|
||||
private String status;
|
||||
|
||||
/** 备注 */
|
||||
@Size(max = 500, message = "备注长度不能超过500个字符")
|
||||
private String remark;
|
||||
|
||||
// ============================================================
|
||||
// 个人专属字段
|
||||
// ============================================================
|
||||
/** 人员类型 */
|
||||
/** 人员类型(中介、职业背债人、房产中介等) */
|
||||
@Size(max = 30, message = "人员类型长度不能超过30个字符")
|
||||
private String indivType;
|
||||
|
||||
/** 人员子类型 */
|
||||
/** 人员子类型(本人、配偶等) */
|
||||
@Size(max = 50, message = "人员子类型长度不能超过50个字符")
|
||||
private String indivSubType;
|
||||
|
||||
/** 性别 */
|
||||
/** 性别(M男 F女 O其他) */
|
||||
@Size(max = 1, message = "性别长度不能超过1个字符")
|
||||
private String indivGender;
|
||||
|
||||
@@ -54,7 +45,7 @@ public class DpcIntermediaryPersonAddDTO implements Serializable {
|
||||
@Size(max = 30, message = "证件类型长度不能超过30个字符")
|
||||
private String indivCertType;
|
||||
|
||||
/** 手机号码 */
|
||||
/** 手机号码(加密存储) */
|
||||
@Size(max = 20, message = "手机号码长度不能超过20个字符")
|
||||
private String indivPhone;
|
||||
|
||||
@@ -82,123 +73,11 @@ public class DpcIntermediaryPersonAddDTO implements Serializable {
|
||||
@Size(max = 50, message = "关联关系长度不能超过50个字符")
|
||||
private String indivRelation;
|
||||
|
||||
public String getName() {
|
||||
return name;
|
||||
}
|
||||
/** 状态 */
|
||||
@NotBlank(message = "状态不能为空")
|
||||
private String status;
|
||||
|
||||
public void setName(String name) {
|
||||
this.name = name;
|
||||
}
|
||||
|
||||
public String getCertificateNo() {
|
||||
return certificateNo;
|
||||
}
|
||||
|
||||
public void setCertificateNo(String certificateNo) {
|
||||
this.certificateNo = certificateNo;
|
||||
}
|
||||
|
||||
public String getStatus() {
|
||||
return status;
|
||||
}
|
||||
|
||||
public void setStatus(String status) {
|
||||
this.status = status;
|
||||
}
|
||||
|
||||
public String getRemark() {
|
||||
return remark;
|
||||
}
|
||||
|
||||
public void setRemark(String remark) {
|
||||
this.remark = remark;
|
||||
}
|
||||
|
||||
public String getIndivType() {
|
||||
return indivType;
|
||||
}
|
||||
|
||||
public void setIndivType(String indivType) {
|
||||
this.indivType = indivType;
|
||||
}
|
||||
|
||||
public String getIndivSubType() {
|
||||
return indivSubType;
|
||||
}
|
||||
|
||||
public void setIndivSubType(String indivSubType) {
|
||||
this.indivSubType = indivSubType;
|
||||
}
|
||||
|
||||
public String getIndivGender() {
|
||||
return indivGender;
|
||||
}
|
||||
|
||||
public void setIndivGender(String indivGender) {
|
||||
this.indivGender = indivGender;
|
||||
}
|
||||
|
||||
public String getIndivCertType() {
|
||||
return indivCertType;
|
||||
}
|
||||
|
||||
public void setIndivCertType(String indivCertType) {
|
||||
this.indivCertType = indivCertType;
|
||||
}
|
||||
|
||||
public String getIndivPhone() {
|
||||
return indivPhone;
|
||||
}
|
||||
|
||||
public void setIndivPhone(String indivPhone) {
|
||||
this.indivPhone = indivPhone;
|
||||
}
|
||||
|
||||
public String getIndivWechat() {
|
||||
return indivWechat;
|
||||
}
|
||||
|
||||
public void setIndivWechat(String indivWechat) {
|
||||
this.indivWechat = indivWechat;
|
||||
}
|
||||
|
||||
public String getIndivAddress() {
|
||||
return indivAddress;
|
||||
}
|
||||
|
||||
public void setIndivAddress(String indivAddress) {
|
||||
this.indivAddress = indivAddress;
|
||||
}
|
||||
|
||||
public String getIndivCompany() {
|
||||
return indivCompany;
|
||||
}
|
||||
|
||||
public void setIndivCompany(String indivCompany) {
|
||||
this.indivCompany = indivCompany;
|
||||
}
|
||||
|
||||
public String getIndivPosition() {
|
||||
return indivPosition;
|
||||
}
|
||||
|
||||
public void setIndivPosition(String indivPosition) {
|
||||
this.indivPosition = indivPosition;
|
||||
}
|
||||
|
||||
public String getIndivRelatedId() {
|
||||
return indivRelatedId;
|
||||
}
|
||||
|
||||
public void setIndivRelatedId(String indivRelatedId) {
|
||||
this.indivRelatedId = indivRelatedId;
|
||||
}
|
||||
|
||||
public String getIndivRelation() {
|
||||
return indivRelation;
|
||||
}
|
||||
|
||||
public void setIndivRelation(String indivRelation) {
|
||||
this.indivRelation = indivRelation;
|
||||
}
|
||||
/** 备注 */
|
||||
@Size(max = 500, message = "备注长度不能超过500个字符")
|
||||
private String remark;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,76 @@
|
||||
package com.ruoyi.dpc.domain.dto;
|
||||
|
||||
import jakarta.validation.constraints.NotBlank;
|
||||
import jakarta.validation.constraints.NotNull;
|
||||
import jakarta.validation.constraints.Size;
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serial;
|
||||
import java.io.Serializable;
|
||||
|
||||
/**
|
||||
* 个人中介编辑 DTO
|
||||
*
|
||||
* @author ruoyi
|
||||
* @date 2026-01-29
|
||||
*/
|
||||
@Data
|
||||
public class DpcIntermediaryPersonEditDTO implements Serializable {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** 中介ID */
|
||||
@NotNull(message = "中介ID不能为空")
|
||||
private Long intermediaryId;
|
||||
|
||||
/** 姓名 */
|
||||
@NotBlank(message = "姓名不能为空")
|
||||
@Size(min = 1, max = 100, message = "姓名长度不能超过100个字符")
|
||||
private String name;
|
||||
|
||||
/** 证件号 */
|
||||
@Size(max = 50, message = "证件号长度不能超过50个字符")
|
||||
private String certificateNo;
|
||||
|
||||
/** 人员类型(中介、职业背债人、房产中介等) */
|
||||
private String indivType;
|
||||
|
||||
/** 人员子类型(本人、配偶等) */
|
||||
private String indivSubType;
|
||||
|
||||
/** 性别(M男 F女 O其他) */
|
||||
private String indivGender;
|
||||
|
||||
/** 证件类型 */
|
||||
private String indivCertType;
|
||||
|
||||
/** 手机号码(加密存储) */
|
||||
private String indivPhone;
|
||||
|
||||
/** 微信号 */
|
||||
private String indivWechat;
|
||||
|
||||
/** 联系地址 */
|
||||
private String indivAddress;
|
||||
|
||||
/** 所在公司 */
|
||||
private String indivCompany;
|
||||
|
||||
/** 职位/职务 */
|
||||
private String indivPosition;
|
||||
|
||||
/** 关联人员ID */
|
||||
private String indivRelatedId;
|
||||
|
||||
/** 关联关系 */
|
||||
private String indivRelation;
|
||||
|
||||
/** 状态 */
|
||||
@NotBlank(message = "状态不能为空")
|
||||
private String status;
|
||||
|
||||
/** 备注 */
|
||||
@Size(max = 500, message = "备注长度不能超过500个字符")
|
||||
private String remark;
|
||||
}
|
||||
@@ -0,0 +1,28 @@
|
||||
package com.ruoyi.dpc.domain.vo;
|
||||
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
import java.io.Serial;
|
||||
import java.io.Serializable;
|
||||
|
||||
/**
|
||||
* 枚举选项VO
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
@Data
|
||||
@NoArgsConstructor
|
||||
@AllArgsConstructor
|
||||
public class EnumOptionVO implements Serializable {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** 选项值 */
|
||||
private String value;
|
||||
|
||||
/** 选项标签 */
|
||||
private String label;
|
||||
}
|
||||
41
ruoyi-dpc/src/main/java/com/ruoyi/dpc/enums/CertType.java
Normal file
41
ruoyi-dpc/src/main/java/com/ruoyi/dpc/enums/CertType.java
Normal file
@@ -0,0 +1,41 @@
|
||||
package com.ruoyi.dpc.enums;
|
||||
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Getter;
|
||||
|
||||
/**
|
||||
* 证件类型枚举
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
@Getter
|
||||
@AllArgsConstructor
|
||||
public enum CertType {
|
||||
|
||||
/** 身份证 */
|
||||
ID_CARD("身份证", "身份证"),
|
||||
|
||||
/** 护照 */
|
||||
PASSPORT("护照", "护照"),
|
||||
|
||||
/** 港澳通行证 */
|
||||
HK_MACAU_PASS("港澳通行证", "港澳通行证"),
|
||||
|
||||
/** 台湾通行证 */
|
||||
TAIWAN_PASS("台湾通行证", "台湾通行证");
|
||||
|
||||
private final String code;
|
||||
private final String desc;
|
||||
|
||||
/**
|
||||
* 根据编码获取描述
|
||||
*/
|
||||
public static String getDescByCode(String code) {
|
||||
for (CertType type : values()) {
|
||||
if (type.getCode().equals(code)) {
|
||||
return type.getDesc();
|
||||
}
|
||||
}
|
||||
return null;
|
||||
}
|
||||
}
|
||||
53
ruoyi-dpc/src/main/java/com/ruoyi/dpc/enums/CorpNature.java
Normal file
53
ruoyi-dpc/src/main/java/com/ruoyi/dpc/enums/CorpNature.java
Normal file
@@ -0,0 +1,53 @@
|
||||
package com.ruoyi.dpc.enums;
|
||||
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Getter;
|
||||
|
||||
/**
|
||||
* 企业性质枚举
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
@Getter
|
||||
@AllArgsConstructor
|
||||
public enum CorpNature {
|
||||
|
||||
/** 国有企业 */
|
||||
STATE_OWNED("国有企业", "国有企业"),
|
||||
|
||||
/** 民营企业 */
|
||||
PRIVATE("民营企业", "民营企业"),
|
||||
|
||||
/** 外资企业 */
|
||||
FOREIGN("外资企业", "外资企业"),
|
||||
|
||||
/** 合资企业 */
|
||||
JOINT_VENTURE("合资企业", "合资企业"),
|
||||
|
||||
/** 港澳台企业 */
|
||||
HONG_KONG_MACAO_TAIWAN("港澳台企业", "港澳台企业"),
|
||||
|
||||
/** 集体企业 */
|
||||
COLLECTIVE("集体企业", "集体企业"),
|
||||
|
||||
/** 个体工商户 */
|
||||
INDIVIDUAL("个体工商户", "个体工商户"),
|
||||
|
||||
/** 其他 */
|
||||
OTHER("其他", "其他");
|
||||
|
||||
private final String code;
|
||||
private final String desc;
|
||||
|
||||
/**
|
||||
* 根据编码获取描述
|
||||
*/
|
||||
public static String getDescByCode(String code) {
|
||||
for (CorpNature nature : values()) {
|
||||
if (nature.getCode().equals(code)) {
|
||||
return nature.getDesc();
|
||||
}
|
||||
}
|
||||
return null;
|
||||
}
|
||||
}
|
||||
56
ruoyi-dpc/src/main/java/com/ruoyi/dpc/enums/CorpType.java
Normal file
56
ruoyi-dpc/src/main/java/com/ruoyi/dpc/enums/CorpType.java
Normal file
@@ -0,0 +1,56 @@
|
||||
package com.ruoyi.dpc.enums;
|
||||
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Getter;
|
||||
|
||||
/**
|
||||
* 主体类型枚举
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
@Getter
|
||||
@AllArgsConstructor
|
||||
public enum CorpType {
|
||||
|
||||
/** 有限责任公司 */
|
||||
LIMITED_LIABILITY("有限责任公司", "有限责任公司"),
|
||||
|
||||
/** 股份有限公司 */
|
||||
JOINT_STOCK("股份有限公司", "股份有限公司"),
|
||||
|
||||
/** 个体工商户 */
|
||||
INDIVIDUAL("个体工商户", "个体工商户"),
|
||||
|
||||
/** 合伙企业 */
|
||||
PARTNERSHIP("合伙企业", "合伙企业"),
|
||||
|
||||
/** 个人独资企业 */
|
||||
SOLE_PROPRIETORSHIP("个人独资企业", "个人独资企业"),
|
||||
|
||||
/** 国有企业 */
|
||||
STATE_OWNED("国有企业", "国有企业"),
|
||||
|
||||
/** 集体企业 */
|
||||
COLLECTIVE("集体企业", "集体企业"),
|
||||
|
||||
/** 外商投资企业 */
|
||||
FOREIGN_INVESTED("外商投资企业", "外商投资企业"),
|
||||
|
||||
/** 港澳台投资企业 */
|
||||
HONG_KONG_MACAO_TAIWAN("港澳台投资企业", "港澳台投资企业");
|
||||
|
||||
private final String code;
|
||||
private final String desc;
|
||||
|
||||
/**
|
||||
* 根据编码获取描述
|
||||
*/
|
||||
public static String getDescByCode(String code) {
|
||||
for (CorpType type : values()) {
|
||||
if (type.getCode().equals(code)) {
|
||||
return type.getDesc();
|
||||
}
|
||||
}
|
||||
return null;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,50 @@
|
||||
package com.ruoyi.dpc.enums;
|
||||
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Getter;
|
||||
|
||||
/**
|
||||
* 人员子类型枚举
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
@Getter
|
||||
@AllArgsConstructor
|
||||
public enum IndivSubType {
|
||||
|
||||
/** 本人 */
|
||||
SELF("本人", "本人"),
|
||||
|
||||
/** 配偶 */
|
||||
SPOUSE("配偶", "配偶"),
|
||||
|
||||
/** 父亲 */
|
||||
FATHER("父亲", "父亲"),
|
||||
|
||||
/** 母亲 */
|
||||
MOTHER("母亲", "母亲"),
|
||||
|
||||
/** 兄弟 */
|
||||
BROTHER("兄弟", "兄弟"),
|
||||
|
||||
/** 姐妹 */
|
||||
SISTER("姐妹", "姐妹"),
|
||||
|
||||
/** 子女 */
|
||||
CHILD("子女", "子女");
|
||||
|
||||
private final String code;
|
||||
private final String desc;
|
||||
|
||||
/**
|
||||
* 根据编码获取描述
|
||||
*/
|
||||
public static String getDescByCode(String code) {
|
||||
for (IndivSubType type : values()) {
|
||||
if (type.getCode().equals(code)) {
|
||||
return type.getDesc();
|
||||
}
|
||||
}
|
||||
return null;
|
||||
}
|
||||
}
|
||||
44
ruoyi-dpc/src/main/java/com/ruoyi/dpc/enums/IndivType.java
Normal file
44
ruoyi-dpc/src/main/java/com/ruoyi/dpc/enums/IndivType.java
Normal file
@@ -0,0 +1,44 @@
|
||||
package com.ruoyi.dpc.enums;
|
||||
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Getter;
|
||||
|
||||
/**
|
||||
* 人员类型枚举
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
@Getter
|
||||
@AllArgsConstructor
|
||||
public enum IndivType {
|
||||
|
||||
/** 房产中介 */
|
||||
REAL_ESTATE_AGENT("房产中介", "房产中介"),
|
||||
|
||||
/** 贷款中介 */
|
||||
LOAN_AGENT("贷款中介", "贷款中介"),
|
||||
|
||||
/** 职业背债人 */
|
||||
PROFESSIONAL_DEBTOR("职业背债人", "职业背债人"),
|
||||
|
||||
/** 担保中介 */
|
||||
GUARANTEE_AGENT("担保中介", "担保中介"),
|
||||
|
||||
/** 评估中介 */
|
||||
EVALUATION_AGENT("评估中介", "评估中介");
|
||||
|
||||
private final String code;
|
||||
private final String desc;
|
||||
|
||||
/**
|
||||
* 根据编码获取描述
|
||||
*/
|
||||
public static String getDescByCode(String code) {
|
||||
for (IndivType type : values()) {
|
||||
if (type.getCode().equals(code)) {
|
||||
return type.getDesc();
|
||||
}
|
||||
}
|
||||
return null;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,53 @@
|
||||
package com.ruoyi.dpc.enums;
|
||||
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Getter;
|
||||
|
||||
/**
|
||||
* 关联关系枚举
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
@Getter
|
||||
@AllArgsConstructor
|
||||
public enum RelationType {
|
||||
|
||||
/** 配偶 */
|
||||
SPOUSE("配偶", "配偶"),
|
||||
|
||||
/** 父子 */
|
||||
FATHER_SON("父子", "父子"),
|
||||
|
||||
/** 母女 */
|
||||
MOTHER_DAUGHTER("母女", "母女"),
|
||||
|
||||
/** 兄弟 */
|
||||
BROTHER("兄弟", "兄弟"),
|
||||
|
||||
/** 姐妹 */
|
||||
SISTER("姐妹", "姐妹"),
|
||||
|
||||
/** 亲属 */
|
||||
RELATIVE("亲属", "亲属"),
|
||||
|
||||
/** 朋友 */
|
||||
FRIEND("朋友", "朋友"),
|
||||
|
||||
/** 同事 */
|
||||
COLLEAGUE("同事", "同事");
|
||||
|
||||
private final String code;
|
||||
private final String desc;
|
||||
|
||||
/**
|
||||
* 根据编码获取描述
|
||||
*/
|
||||
public static String getDescByCode(String code) {
|
||||
for (RelationType type : values()) {
|
||||
if (type.getCode().equals(code)) {
|
||||
return type.getDesc();
|
||||
}
|
||||
}
|
||||
return null;
|
||||
}
|
||||
}
|
||||
@@ -2,6 +2,9 @@ package com.ruoyi.dpc.mapper;
|
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import com.ruoyi.dpc.domain.DpcIntermediaryBlacklist;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 中介人员黑名单 数据层
|
||||
@@ -10,4 +13,20 @@ import com.ruoyi.dpc.domain.DpcIntermediaryBlacklist;
|
||||
* @date 2026-01-27
|
||||
*/
|
||||
public interface DpcIntermediaryBlacklistMapper extends BaseMapper<DpcIntermediaryBlacklist> {
|
||||
|
||||
/**
|
||||
* 批量插入中介黑名单数据
|
||||
*
|
||||
* @param list 中介黑名单列表
|
||||
* @return 插入行数
|
||||
*/
|
||||
int batchInsert(@Param("list") List<DpcIntermediaryBlacklist> list);
|
||||
|
||||
/**
|
||||
* 批量更新中介黑名单数据
|
||||
*
|
||||
* @param list 中介黑名单列表
|
||||
* @return 更新行数
|
||||
*/
|
||||
int batchUpdate(@Param("list") List<DpcIntermediaryBlacklist> list);
|
||||
}
|
||||
|
||||
@@ -2,9 +2,7 @@ package com.ruoyi.dpc.service;
|
||||
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import com.ruoyi.dpc.domain.DpcIntermediaryBlacklist;
|
||||
import com.ruoyi.dpc.domain.dto.DpcIntermediaryBlacklistAddDTO;
|
||||
import com.ruoyi.dpc.domain.dto.DpcIntermediaryBlacklistEditDTO;
|
||||
import com.ruoyi.dpc.domain.dto.DpcIntermediaryBlacklistQueryDTO;
|
||||
import com.ruoyi.dpc.domain.dto.*;
|
||||
import com.ruoyi.dpc.domain.excel.DpcIntermediaryBlacklistExcel;
|
||||
import com.ruoyi.dpc.domain.excel.DpcIntermediaryEntityExcel;
|
||||
import com.ruoyi.dpc.domain.excel.DpcIntermediaryPersonExcel;
|
||||
@@ -54,21 +52,57 @@ public interface IDpcIntermediaryBlacklistService {
|
||||
DpcIntermediaryBlacklistVO selectIntermediaryById(Long intermediaryId);
|
||||
|
||||
/**
|
||||
* 新增中介黑名单
|
||||
* 新增中介黑名单(通用接口,不推荐使用)
|
||||
*
|
||||
* @param addDTO 新增DTO
|
||||
* @return 结果
|
||||
* @deprecated 请使用 insertPersonIntermediary 或 insertEntityIntermediary 代替
|
||||
*/
|
||||
@Deprecated
|
||||
int insertIntermediary(DpcIntermediaryBlacklistAddDTO addDTO);
|
||||
|
||||
/**
|
||||
* 修改中介黑名单
|
||||
* 新增个人中介黑名单
|
||||
*
|
||||
* @param addDTO 个人中介新增DTO
|
||||
* @return 结果
|
||||
*/
|
||||
int insertPersonIntermediary(DpcIntermediaryPersonAddDTO addDTO);
|
||||
|
||||
/**
|
||||
* 新增机构中介黑名单
|
||||
*
|
||||
* @param addDTO 机构中介新增DTO
|
||||
* @return 结果
|
||||
*/
|
||||
int insertEntityIntermediary(DpcIntermediaryEntityAddDTO addDTO);
|
||||
|
||||
/**
|
||||
* 修改中介黑名单(通用接口,不推荐使用)
|
||||
*
|
||||
* @param editDTO 编辑DTO
|
||||
* @return 结果
|
||||
* @deprecated 请使用 updatePersonIntermediary 或 updateEntityIntermediary 代替
|
||||
*/
|
||||
@Deprecated
|
||||
int updateIntermediary(DpcIntermediaryBlacklistEditDTO editDTO);
|
||||
|
||||
/**
|
||||
* 修改个人中介黑名单
|
||||
*
|
||||
* @param editDTO 个人中介编辑DTO
|
||||
* @return 结果
|
||||
*/
|
||||
int updatePersonIntermediary(DpcIntermediaryPersonEditDTO editDTO);
|
||||
|
||||
/**
|
||||
* 修改机构中介黑名单
|
||||
*
|
||||
* @param editDTO 机构中介编辑DTO
|
||||
* @return 结果
|
||||
*/
|
||||
int updateEntityIntermediary(DpcIntermediaryEntityEditDTO editDTO);
|
||||
|
||||
/**
|
||||
* 批量删除中介黑名单
|
||||
*
|
||||
|
||||
@@ -4,9 +4,7 @@ import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import com.ruoyi.common.utils.StringUtils;
|
||||
import com.ruoyi.dpc.domain.DpcIntermediaryBlacklist;
|
||||
import com.ruoyi.dpc.domain.dto.DpcIntermediaryBlacklistAddDTO;
|
||||
import com.ruoyi.dpc.domain.dto.DpcIntermediaryBlacklistEditDTO;
|
||||
import com.ruoyi.dpc.domain.dto.DpcIntermediaryBlacklistQueryDTO;
|
||||
import com.ruoyi.dpc.domain.dto.*;
|
||||
import com.ruoyi.dpc.domain.excel.DpcIntermediaryBlacklistExcel;
|
||||
import com.ruoyi.dpc.domain.excel.DpcIntermediaryEntityExcel;
|
||||
import com.ruoyi.dpc.domain.excel.DpcIntermediaryPersonExcel;
|
||||
@@ -24,7 +22,7 @@ import org.springframework.beans.BeanUtils;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.text.SimpleDateFormat;
|
||||
import java.util.List;
|
||||
import java.util.*;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
/**
|
||||
@@ -108,9 +106,50 @@ public class DpcIntermediaryBlacklistServiceImpl implements IDpcIntermediaryBlac
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
@Deprecated
|
||||
public int insertIntermediary(DpcIntermediaryBlacklistAddDTO addDTO) {
|
||||
DpcIntermediaryBlacklist intermediary = new DpcIntermediaryBlacklist();
|
||||
BeanUtils.copyProperties(addDTO, intermediary);
|
||||
// 手动新增时,数据来源设置为 MANUAL
|
||||
intermediary.setDataSource("MANUAL");
|
||||
// 默认状态设置为正常
|
||||
intermediary.setStatus("0");
|
||||
return intermediaryMapper.insert(intermediary);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增个人中介黑名单
|
||||
*
|
||||
* @param addDTO 个人中介新增DTO
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int insertPersonIntermediary(DpcIntermediaryPersonAddDTO addDTO) {
|
||||
DpcIntermediaryBlacklist intermediary = new DpcIntermediaryBlacklist();
|
||||
BeanUtils.copyProperties(addDTO, intermediary);
|
||||
// 设置中介类型为个人
|
||||
intermediary.setIntermediaryType("1");
|
||||
// 手动新增时,数据来源设置为 MANUAL
|
||||
intermediary.setDataSource("MANUAL");
|
||||
return intermediaryMapper.insert(intermediary);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增机构中介黑名单
|
||||
*
|
||||
* @param addDTO 机构中介新增DTO
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int insertEntityIntermediary(DpcIntermediaryEntityAddDTO addDTO) {
|
||||
DpcIntermediaryBlacklist intermediary = new DpcIntermediaryBlacklist();
|
||||
BeanUtils.copyProperties(addDTO, intermediary);
|
||||
// 设置中介类型为机构
|
||||
intermediary.setIntermediaryType("2");
|
||||
// 证件号使用统一社会信用代码
|
||||
intermediary.setCertificateNo(addDTO.getCorpCreditCode());
|
||||
// 手动新增时,数据来源设置为 MANUAL
|
||||
intermediary.setDataSource("MANUAL");
|
||||
return intermediaryMapper.insert(intermediary);
|
||||
}
|
||||
|
||||
@@ -121,12 +160,85 @@ public class DpcIntermediaryBlacklistServiceImpl implements IDpcIntermediaryBlac
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
@Deprecated
|
||||
public int updateIntermediary(DpcIntermediaryBlacklistEditDTO editDTO) {
|
||||
DpcIntermediaryBlacklist intermediary = new DpcIntermediaryBlacklist();
|
||||
BeanUtils.copyProperties(editDTO, intermediary);
|
||||
return intermediaryMapper.updateById(intermediary);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改个人中介黑名单
|
||||
*
|
||||
* @param editDTO 个人中介编辑DTO
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int updatePersonIntermediary(DpcIntermediaryPersonEditDTO editDTO) {
|
||||
DpcIntermediaryBlacklist intermediary = new DpcIntermediaryBlacklist();
|
||||
BeanUtils.copyProperties(editDTO, intermediary);
|
||||
// 设置中介类型为个人
|
||||
intermediary.setIntermediaryType("1");
|
||||
// 清空机构专属字段
|
||||
clearEntityFields(intermediary);
|
||||
return intermediaryMapper.updateById(intermediary);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改机构中介黑名单
|
||||
*
|
||||
* @param editDTO 机构中介编辑DTO
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int updateEntityIntermediary(DpcIntermediaryEntityEditDTO editDTO) {
|
||||
DpcIntermediaryBlacklist intermediary = new DpcIntermediaryBlacklist();
|
||||
BeanUtils.copyProperties(editDTO, intermediary);
|
||||
// 设置中介类型为机构
|
||||
intermediary.setIntermediaryType("2");
|
||||
// 清空个人专属字段
|
||||
clearPersonFields(intermediary);
|
||||
return intermediaryMapper.updateById(intermediary);
|
||||
}
|
||||
|
||||
/**
|
||||
* 清空个人专属字段
|
||||
*/
|
||||
private void clearPersonFields(DpcIntermediaryBlacklist intermediary) {
|
||||
intermediary.setIndivType(null);
|
||||
intermediary.setIndivSubType(null);
|
||||
intermediary.setIndivGender(null);
|
||||
intermediary.setIndivCertType(null);
|
||||
intermediary.setIndivPhone(null);
|
||||
intermediary.setIndivWechat(null);
|
||||
intermediary.setIndivAddress(null);
|
||||
intermediary.setIndivCompany(null);
|
||||
intermediary.setIndivPosition(null);
|
||||
intermediary.setIndivRelatedId(null);
|
||||
intermediary.setIndivRelation(null);
|
||||
}
|
||||
|
||||
/**
|
||||
* 清空机构专属字段
|
||||
*/
|
||||
private void clearEntityFields(DpcIntermediaryBlacklist intermediary) {
|
||||
intermediary.setCorpCreditCode(null);
|
||||
intermediary.setCorpType(null);
|
||||
intermediary.setCorpNature(null);
|
||||
intermediary.setCorpIndustryCategory(null);
|
||||
intermediary.setCorpIndustry(null);
|
||||
intermediary.setCorpEstablishDate(null);
|
||||
intermediary.setCorpAddress(null);
|
||||
intermediary.setCorpLegalRep(null);
|
||||
intermediary.setCorpLegalCertType(null);
|
||||
intermediary.setCorpLegalCertNo(null);
|
||||
intermediary.setCorpShareholder1(null);
|
||||
intermediary.setCorpShareholder2(null);
|
||||
intermediary.setCorpShareholder3(null);
|
||||
intermediary.setCorpShareholder4(null);
|
||||
intermediary.setCorpShareholder5(null);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除中介黑名单
|
||||
*
|
||||
@@ -211,7 +323,7 @@ public class DpcIntermediaryBlacklistServiceImpl implements IDpcIntermediaryBlac
|
||||
}
|
||||
|
||||
/**
|
||||
* 导入个人中介数据
|
||||
* 导入个人中介数据(批量插入优化版)
|
||||
*
|
||||
* @param excelList Excel实体列表
|
||||
* @param isUpdateSupport 是否更新支持
|
||||
@@ -223,11 +335,40 @@ public class DpcIntermediaryBlacklistServiceImpl implements IDpcIntermediaryBlac
|
||||
return "至少需要一条数据";
|
||||
}
|
||||
|
||||
int successNum = 0;
|
||||
int failureNum = 0;
|
||||
StringBuilder successMsg = new StringBuilder();
|
||||
StringBuilder failureMsg = new StringBuilder();
|
||||
// 批量处理:先验证所有数据
|
||||
List<DpcIntermediaryBlacklist> toInsertList = new ArrayList<>();
|
||||
List<DpcIntermediaryBlacklist> toUpdateList = new ArrayList<>();
|
||||
List<String> errorMessages = new ArrayList<>();
|
||||
|
||||
// 批量查询已存在的记录(用于唯一性校验或更新支持)
|
||||
Set<String> existingCertNos = new HashSet<>();
|
||||
Map<String, Long> certNoToIdMap = new HashMap<>();
|
||||
for (DpcIntermediaryPersonExcel excel : excelList) {
|
||||
if (StringUtils.isNotEmpty(excel.getCertificateNo())) {
|
||||
existingCertNos.add(excel.getCertificateNo());
|
||||
}
|
||||
}
|
||||
if (!existingCertNos.isEmpty()) {
|
||||
LambdaQueryWrapper<DpcIntermediaryBlacklist> wrapper = new LambdaQueryWrapper<>();
|
||||
wrapper.eq(DpcIntermediaryBlacklist::getIntermediaryType, "1")
|
||||
.in(DpcIntermediaryBlacklist::getCertificateNo, existingCertNos)
|
||||
.select(DpcIntermediaryBlacklist::getIntermediaryId, DpcIntermediaryBlacklist::getCertificateNo);
|
||||
List<DpcIntermediaryBlacklist> existingList = intermediaryMapper.selectList(wrapper);
|
||||
for (DpcIntermediaryBlacklist existing : existingList) {
|
||||
certNoToIdMap.put(existing.getCertificateNo(), existing.getIntermediaryId());
|
||||
}
|
||||
}
|
||||
|
||||
// 如果不是更新模式,先进行唯一性校验
|
||||
if (!isUpdateSupport) {
|
||||
for (DpcIntermediaryPersonExcel excel : excelList) {
|
||||
if (StringUtils.isNotEmpty(excel.getCertificateNo()) && certNoToIdMap.containsKey(excel.getCertificateNo())) {
|
||||
throw new RuntimeException("证件号 " + excel.getCertificateNo() + " 已存在,请勿重复导入");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// 处理每条数据
|
||||
for (int i = 0; i < excelList.size(); i++) {
|
||||
DpcIntermediaryPersonExcel excel = excelList.get(i);
|
||||
try {
|
||||
@@ -238,16 +379,16 @@ public class DpcIntermediaryBlacklistServiceImpl implements IDpcIntermediaryBlac
|
||||
DpcIntermediaryBlacklist intermediary = new DpcIntermediaryBlacklist();
|
||||
intermediary.setName(excel.getName());
|
||||
intermediary.setCertificateNo(excel.getCertificateNo());
|
||||
intermediary.setIntermediaryType("1"); // 个人类型
|
||||
intermediary.setStatus("0"); // 默认正常
|
||||
intermediary.setDataSource("IMPORT"); // 批量导入
|
||||
intermediary.setIntermediaryType("1");
|
||||
intermediary.setStatus("0");
|
||||
intermediary.setDataSource("IMPORT");
|
||||
intermediary.setRemark(excel.getRemark());
|
||||
|
||||
// 个人专属字段
|
||||
intermediary.setIndivType(excel.getIndivType());
|
||||
intermediary.setIndivSubType(excel.getIndivSubType());
|
||||
intermediary.setIndivGender(excel.getIndivGender());
|
||||
intermediary.setIndivCertType(excel.getIndivCertType());
|
||||
intermediary.setIndivCertType(StringUtils.isNotEmpty(excel.getIndivCertType()) ? excel.getIndivCertType() : "身份证");
|
||||
intermediary.setIndivPhone(excel.getIndivPhone());
|
||||
intermediary.setIndivWechat(excel.getIndivWechat());
|
||||
intermediary.setIndivAddress(excel.getIndivAddress());
|
||||
@@ -256,47 +397,51 @@ public class DpcIntermediaryBlacklistServiceImpl implements IDpcIntermediaryBlac
|
||||
intermediary.setIndivRelatedId(excel.getIndivRelatedId());
|
||||
intermediary.setIndivRelation(excel.getIndivRelation());
|
||||
|
||||
// 设置默认证件类型
|
||||
if (StringUtils.isEmpty(intermediary.getIndivCertType())) {
|
||||
intermediary.setIndivCertType("身份证");
|
||||
// 检查是否需要更新
|
||||
if (isUpdateSupport && StringUtils.isNotEmpty(excel.getCertificateNo()) && certNoToIdMap.containsKey(excel.getCertificateNo())) {
|
||||
intermediary.setIntermediaryId(certNoToIdMap.get(excel.getCertificateNo()));
|
||||
toUpdateList.add(intermediary);
|
||||
} else {
|
||||
toInsertList.add(intermediary);
|
||||
}
|
||||
|
||||
// 检查是否已存在(通过证件号判断)
|
||||
if (isUpdateSupport && StringUtils.isNotEmpty(excel.getCertificateNo())) {
|
||||
LambdaQueryWrapper<DpcIntermediaryBlacklist> wrapper = new LambdaQueryWrapper<>();
|
||||
wrapper.eq(DpcIntermediaryBlacklist::getCertificateNo, excel.getCertificateNo())
|
||||
.eq(DpcIntermediaryBlacklist::getIntermediaryType, "1");
|
||||
DpcIntermediaryBlacklist existing = intermediaryMapper.selectOne(wrapper);
|
||||
if (existing != null) {
|
||||
intermediary.setIntermediaryId(existing.getIntermediaryId());
|
||||
intermediaryMapper.updateById(intermediary);
|
||||
successNum++;
|
||||
successMsg.append("<br/>").append(successNum).append("、").append(excel.getName()).append(" 更新成功");
|
||||
continue;
|
||||
}
|
||||
}
|
||||
|
||||
intermediaryMapper.insert(intermediary);
|
||||
successNum++;
|
||||
successMsg.append("<br/>").append(successNum).append("、").append(excel.getName()).append(" 导入成功");
|
||||
} catch (Exception e) {
|
||||
failureNum++;
|
||||
failureMsg.append("<br/>").append(failureNum).append("、第").append(i + 1).append("行导入失败:");
|
||||
failureMsg.append(e.getMessage());
|
||||
errorMessages.add("第" + (i + 1) + "行导入失败:" + e.getMessage());
|
||||
}
|
||||
}
|
||||
|
||||
// 批量执行数据库操作
|
||||
int successNum = 0;
|
||||
int failureNum = errorMessages.size();
|
||||
|
||||
// 批量插入
|
||||
if (!toInsertList.isEmpty()) {
|
||||
intermediaryMapper.batchInsert(toInsertList);
|
||||
successNum += toInsertList.size();
|
||||
}
|
||||
|
||||
// 批量更新
|
||||
if (!toUpdateList.isEmpty()) {
|
||||
intermediaryMapper.batchUpdate(toUpdateList);
|
||||
successNum += toUpdateList.size();
|
||||
}
|
||||
|
||||
// 构建失败消息
|
||||
StringBuilder failureMsg = new StringBuilder();
|
||||
for (String error : errorMessages) {
|
||||
failureMsg.append("<br/>").append(error);
|
||||
}
|
||||
|
||||
// 返回结果
|
||||
if (failureNum > 0) {
|
||||
failureMsg.insert(0, "很抱歉,导入失败!共 " + failureNum + " 条数据格式不正确,错误如下:");
|
||||
throw new RuntimeException(failureMsg.toString());
|
||||
} else {
|
||||
successMsg.insert(0, "恭喜您,数据已全部导入成功!共 " + successNum + " 条");
|
||||
return successMsg.toString();
|
||||
return "恭喜您,数据已全部导入成功!共 " + successNum + " 条";
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 导入机构中介数据
|
||||
* 导入机构中介数据(批量插入优化版)
|
||||
*
|
||||
* @param excelList Excel实体列表
|
||||
* @param isUpdateSupport 是否更新支持
|
||||
@@ -308,11 +453,42 @@ public class DpcIntermediaryBlacklistServiceImpl implements IDpcIntermediaryBlac
|
||||
return "至少需要一条数据";
|
||||
}
|
||||
|
||||
int successNum = 0;
|
||||
int failureNum = 0;
|
||||
StringBuilder successMsg = new StringBuilder();
|
||||
StringBuilder failureMsg = new StringBuilder();
|
||||
// 批量处理:先验证所有数据
|
||||
List<DpcIntermediaryBlacklist> toInsertList = new ArrayList<>();
|
||||
List<DpcIntermediaryBlacklist> toUpdateList = new ArrayList<>();
|
||||
List<String> errorMessages = new ArrayList<>();
|
||||
|
||||
// 批量查询已存在的记录(用于唯一性校验或更新支持)
|
||||
Set<String> existingCreditCodes = new HashSet<>();
|
||||
Map<String, Long> creditCodeToIdMap = new HashMap<>();
|
||||
for (DpcIntermediaryEntityExcel excel : excelList) {
|
||||
if (StringUtils.isNotEmpty(excel.getCorpCreditCode())) {
|
||||
existingCreditCodes.add(excel.getCorpCreditCode());
|
||||
}
|
||||
}
|
||||
if (!existingCreditCodes.isEmpty()) {
|
||||
LambdaQueryWrapper<DpcIntermediaryBlacklist> wrapper = new LambdaQueryWrapper<>();
|
||||
wrapper.eq(DpcIntermediaryBlacklist::getIntermediaryType, "2")
|
||||
.in(DpcIntermediaryBlacklist::getCorpCreditCode, existingCreditCodes)
|
||||
.select(DpcIntermediaryBlacklist::getIntermediaryId, DpcIntermediaryBlacklist::getCorpCreditCode);
|
||||
List<DpcIntermediaryBlacklist> existingList = intermediaryMapper.selectList(wrapper);
|
||||
for (DpcIntermediaryBlacklist existing : existingList) {
|
||||
creditCodeToIdMap.put(existing.getCorpCreditCode(), existing.getIntermediaryId());
|
||||
}
|
||||
}
|
||||
|
||||
// 如果不是更新模式,先进行唯一性校验
|
||||
if (!isUpdateSupport) {
|
||||
for (DpcIntermediaryEntityExcel excel : excelList) {
|
||||
if (StringUtils.isNotEmpty(excel.getCorpCreditCode()) && creditCodeToIdMap.containsKey(excel.getCorpCreditCode())) {
|
||||
throw new RuntimeException("统一社会信用代码 " + excel.getCorpCreditCode() + " 已存在,请勿重复导入");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd");
|
||||
|
||||
// 处理每条数据
|
||||
for (int i = 0; i < excelList.size(); i++) {
|
||||
DpcIntermediaryEntityExcel excel = excelList.get(i);
|
||||
try {
|
||||
@@ -322,9 +498,11 @@ public class DpcIntermediaryBlacklistServiceImpl implements IDpcIntermediaryBlac
|
||||
// 转换为实体
|
||||
DpcIntermediaryBlacklist intermediary = new DpcIntermediaryBlacklist();
|
||||
intermediary.setName(excel.getName());
|
||||
intermediary.setIntermediaryType("2"); // 机构类型
|
||||
intermediary.setStatus("0"); // 默认正常
|
||||
intermediary.setDataSource("IMPORT"); // 批量导入
|
||||
// 对于机构中介,使用统一社会信用代码作为证件号
|
||||
intermediary.setCertificateNo(excel.getCorpCreditCode());
|
||||
intermediary.setIntermediaryType("2");
|
||||
intermediary.setStatus("0");
|
||||
intermediary.setDataSource("IMPORT");
|
||||
intermediary.setRemark(excel.getRemark());
|
||||
|
||||
// 机构专属字段
|
||||
@@ -337,7 +515,6 @@ public class DpcIntermediaryBlacklistServiceImpl implements IDpcIntermediaryBlac
|
||||
// 解析成立日期
|
||||
if (StringUtils.isNotEmpty(excel.getCorpEstablishDate())) {
|
||||
try {
|
||||
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd");
|
||||
intermediary.setCorpEstablishDate(sdf.parse(excel.getCorpEstablishDate()));
|
||||
} catch (Exception e) {
|
||||
// 忽略日期解析错误
|
||||
@@ -354,37 +531,46 @@ public class DpcIntermediaryBlacklistServiceImpl implements IDpcIntermediaryBlac
|
||||
intermediary.setCorpShareholder4(excel.getCorpShareholder4());
|
||||
intermediary.setCorpShareholder5(excel.getCorpShareholder5());
|
||||
|
||||
// 检查是否已存在(通过统一社会信用代码判断)
|
||||
if (isUpdateSupport && StringUtils.isNotEmpty(excel.getCorpCreditCode())) {
|
||||
LambdaQueryWrapper<DpcIntermediaryBlacklist> wrapper = new LambdaQueryWrapper<>();
|
||||
wrapper.eq(DpcIntermediaryBlacklist::getCorpCreditCode, excel.getCorpCreditCode())
|
||||
.eq(DpcIntermediaryBlacklist::getIntermediaryType, "2");
|
||||
DpcIntermediaryBlacklist existing = intermediaryMapper.selectOne(wrapper);
|
||||
if (existing != null) {
|
||||
intermediary.setIntermediaryId(existing.getIntermediaryId());
|
||||
intermediaryMapper.updateById(intermediary);
|
||||
successNum++;
|
||||
successMsg.append("<br/>").append(successNum).append("、").append(excel.getName()).append(" 更新成功");
|
||||
continue;
|
||||
}
|
||||
// 检查是否需要更新
|
||||
if (isUpdateSupport && StringUtils.isNotEmpty(excel.getCorpCreditCode()) && creditCodeToIdMap.containsKey(excel.getCorpCreditCode())) {
|
||||
intermediary.setIntermediaryId(creditCodeToIdMap.get(excel.getCorpCreditCode()));
|
||||
toUpdateList.add(intermediary);
|
||||
} else {
|
||||
toInsertList.add(intermediary);
|
||||
}
|
||||
|
||||
intermediaryMapper.insert(intermediary);
|
||||
successNum++;
|
||||
successMsg.append("<br/>").append(successNum).append("、").append(excel.getName()).append(" 导入成功");
|
||||
} catch (Exception e) {
|
||||
failureNum++;
|
||||
failureMsg.append("<br/>").append(failureNum).append("、第").append(i + 1).append("行导入失败:");
|
||||
failureMsg.append(e.getMessage());
|
||||
errorMessages.add("第" + (i + 1) + "行导入失败:" + e.getMessage());
|
||||
}
|
||||
}
|
||||
|
||||
// 批量执行数据库操作
|
||||
int successNum = 0;
|
||||
int failureNum = errorMessages.size();
|
||||
|
||||
// 批量插入
|
||||
if (!toInsertList.isEmpty()) {
|
||||
intermediaryMapper.batchInsert(toInsertList);
|
||||
successNum += toInsertList.size();
|
||||
}
|
||||
|
||||
// 批量更新
|
||||
if (!toUpdateList.isEmpty()) {
|
||||
intermediaryMapper.batchUpdate(toUpdateList);
|
||||
successNum += toUpdateList.size();
|
||||
}
|
||||
|
||||
// 构建失败消息
|
||||
StringBuilder failureMsg = new StringBuilder();
|
||||
for (String error : errorMessages) {
|
||||
failureMsg.append("<br/>").append(error);
|
||||
}
|
||||
|
||||
// 返回结果
|
||||
if (failureNum > 0) {
|
||||
failureMsg.insert(0, "很抱歉,导入失败!共 " + failureNum + " 条数据格式不正确,错误如下:");
|
||||
throw new RuntimeException(failureMsg.toString());
|
||||
} else {
|
||||
successMsg.insert(0, "恭喜您,数据已全部导入成功!共 " + successNum + " 条");
|
||||
return successMsg.toString();
|
||||
return "恭喜您,数据已全部导入成功!共 " + successNum + " 条";
|
||||
}
|
||||
}
|
||||
|
||||
@@ -407,6 +593,10 @@ public class DpcIntermediaryBlacklistServiceImpl implements IDpcIntermediaryBlac
|
||||
if (StringUtils.isEmpty(excel.getName())) {
|
||||
throw new RuntimeException("机构名称不能为空");
|
||||
}
|
||||
// 验证统一社会信用代码不能为空(因为会用作 certificate_no 字段)
|
||||
if (StringUtils.isEmpty(excel.getCorpCreditCode())) {
|
||||
throw new RuntimeException("统一社会信用代码不能为空");
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -418,8 +608,33 @@ public class DpcIntermediaryBlacklistServiceImpl implements IDpcIntermediaryBlac
|
||||
}
|
||||
|
||||
DpcIntermediaryPersonDetailVO vo = new DpcIntermediaryPersonDetailVO();
|
||||
BeanUtils.copyProperties(intermediary, vo);
|
||||
// 复制基础字段
|
||||
vo.setIntermediaryId(intermediary.getIntermediaryId());
|
||||
vo.setName(intermediary.getName());
|
||||
vo.setCertificateNo(intermediary.getCertificateNo());
|
||||
vo.setIntermediaryType(intermediary.getIntermediaryType());
|
||||
vo.setStatus(intermediary.getStatus());
|
||||
vo.setRemark(intermediary.getRemark());
|
||||
vo.setDataSource(intermediary.getDataSource());
|
||||
vo.setCreateBy(intermediary.getCreateBy());
|
||||
vo.setCreateTime(intermediary.getCreateTime());
|
||||
vo.setUpdateBy(intermediary.getUpdateBy());
|
||||
vo.setUpdateTime(intermediary.getUpdateTime());
|
||||
|
||||
// 复制个人专属字段
|
||||
vo.setIndivType(intermediary.getIndivType());
|
||||
vo.setIndivSubType(intermediary.getIndivSubType());
|
||||
vo.setIndivGender(intermediary.getIndivGender());
|
||||
vo.setIndivCertType(intermediary.getIndivCertType());
|
||||
vo.setIndivPhone(intermediary.getIndivPhone());
|
||||
vo.setIndivWechat(intermediary.getIndivWechat());
|
||||
vo.setIndivAddress(intermediary.getIndivAddress());
|
||||
vo.setIndivCompany(intermediary.getIndivCompany());
|
||||
vo.setIndivPosition(intermediary.getIndivPosition());
|
||||
vo.setIndivRelatedId(intermediary.getIndivRelatedId());
|
||||
vo.setIndivRelation(intermediary.getIndivRelation());
|
||||
|
||||
// 设置枚举类型的名称
|
||||
vo.setIntermediaryTypeName(IntermediaryType.PERSON.getDesc());
|
||||
vo.setStatusName(IntermediaryStatus.getDescByCode(intermediary.getStatus()));
|
||||
vo.setDataSourceName(DataSource.getDescByCode(intermediary.getDataSource()));
|
||||
@@ -437,8 +652,37 @@ public class DpcIntermediaryBlacklistServiceImpl implements IDpcIntermediaryBlac
|
||||
}
|
||||
|
||||
DpcIntermediaryEntityDetailVO vo = new DpcIntermediaryEntityDetailVO();
|
||||
BeanUtils.copyProperties(intermediary, vo);
|
||||
// 复制基础字段
|
||||
vo.setIntermediaryId(intermediary.getIntermediaryId());
|
||||
vo.setName(intermediary.getName());
|
||||
vo.setCertificateNo(intermediary.getCertificateNo());
|
||||
vo.setIntermediaryType(intermediary.getIntermediaryType());
|
||||
vo.setStatus(intermediary.getStatus());
|
||||
vo.setRemark(intermediary.getRemark());
|
||||
vo.setDataSource(intermediary.getDataSource());
|
||||
vo.setCreateBy(intermediary.getCreateBy());
|
||||
vo.setCreateTime(intermediary.getCreateTime());
|
||||
vo.setUpdateBy(intermediary.getUpdateBy());
|
||||
vo.setUpdateTime(intermediary.getUpdateTime());
|
||||
|
||||
// 复制机构专属字段
|
||||
vo.setCorpCreditCode(intermediary.getCorpCreditCode());
|
||||
vo.setCorpType(intermediary.getCorpType());
|
||||
vo.setCorpNature(intermediary.getCorpNature());
|
||||
vo.setCorpIndustryCategory(intermediary.getCorpIndustryCategory());
|
||||
vo.setCorpIndustry(intermediary.getCorpIndustry());
|
||||
vo.setCorpEstablishDate(intermediary.getCorpEstablishDate());
|
||||
vo.setCorpAddress(intermediary.getCorpAddress());
|
||||
vo.setCorpLegalRep(intermediary.getCorpLegalRep());
|
||||
vo.setCorpLegalCertType(intermediary.getCorpLegalCertType());
|
||||
vo.setCorpLegalCertNo(intermediary.getCorpLegalCertNo());
|
||||
vo.setCorpShareholder1(intermediary.getCorpShareholder1());
|
||||
vo.setCorpShareholder2(intermediary.getCorpShareholder2());
|
||||
vo.setCorpShareholder3(intermediary.getCorpShareholder3());
|
||||
vo.setCorpShareholder4(intermediary.getCorpShareholder4());
|
||||
vo.setCorpShareholder5(intermediary.getCorpShareholder5());
|
||||
|
||||
// 设置枚举类型的名称
|
||||
vo.setIntermediaryTypeName(IntermediaryType.ENTITY.getDesc());
|
||||
vo.setStatusName(IntermediaryStatus.getDescByCode(intermediary.getStatus()));
|
||||
vo.setDataSourceName(DataSource.getDescByCode(intermediary.getDataSource()));
|
||||
@@ -470,19 +714,12 @@ public class DpcIntermediaryBlacklistServiceImpl implements IDpcIntermediaryBlac
|
||||
if (StringUtils.isEmpty(addDTO.getIntermediaryType())) {
|
||||
throw new RuntimeException("中介类型不能为空");
|
||||
}
|
||||
if (StringUtils.isEmpty(addDTO.getStatus())) {
|
||||
throw new RuntimeException("状态不能为空");
|
||||
}
|
||||
|
||||
// 验证中介类型
|
||||
if (!"1".equals(addDTO.getIntermediaryType()) && !"2".equals(addDTO.getIntermediaryType())) {
|
||||
throw new RuntimeException("中介类型只能填写'个人'或'机构'");
|
||||
}
|
||||
|
||||
// 验证状态
|
||||
if (!"0".equals(addDTO.getStatus()) && !"1".equals(addDTO.getStatus())) {
|
||||
throw new RuntimeException("状态只能填写'正常'或'停用'");
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -0,0 +1,134 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE mapper
|
||||
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.ruoyi.dpc.mapper.DpcIntermediaryBlacklistMapper">
|
||||
|
||||
<!-- 批量插入中介黑名单数据 -->
|
||||
<insert id="batchInsert" parameterType="java.util.List">
|
||||
INSERT INTO dpc_intermediary_blacklist (
|
||||
name,
|
||||
certificate_no,
|
||||
intermediary_type,
|
||||
status,
|
||||
remark,
|
||||
indiv_type,
|
||||
indiv_sub_type,
|
||||
indiv_gender,
|
||||
indiv_cert_type,
|
||||
indiv_phone,
|
||||
indiv_wechat,
|
||||
indiv_address,
|
||||
indiv_company,
|
||||
indiv_position,
|
||||
indiv_related_id,
|
||||
indiv_relation,
|
||||
corp_credit_code,
|
||||
corp_type,
|
||||
corp_nature,
|
||||
corp_industry_category,
|
||||
corp_industry,
|
||||
corp_establish_date,
|
||||
corp_address,
|
||||
corp_legal_rep,
|
||||
corp_legal_cert_type,
|
||||
corp_legal_cert_no,
|
||||
corp_shareholder_1,
|
||||
corp_shareholder_2,
|
||||
corp_shareholder_3,
|
||||
corp_shareholder_4,
|
||||
corp_shareholder_5,
|
||||
data_source,
|
||||
create_by,
|
||||
create_time,
|
||||
update_by,
|
||||
update_time
|
||||
) VALUES
|
||||
<foreach collection="list" item="item" separator=",">
|
||||
(
|
||||
#{item.name},
|
||||
#{item.certificateNo},
|
||||
#{item.intermediaryType},
|
||||
#{item.status},
|
||||
#{item.remark},
|
||||
#{item.indivType},
|
||||
#{item.indivSubType},
|
||||
#{item.indivGender},
|
||||
#{item.indivCertType},
|
||||
#{item.indivPhone},
|
||||
#{item.indivWechat},
|
||||
#{item.indivAddress},
|
||||
#{item.indivCompany},
|
||||
#{item.indivPosition},
|
||||
#{item.indivRelatedId},
|
||||
#{item.indivRelation},
|
||||
#{item.corpCreditCode},
|
||||
#{item.corpType},
|
||||
#{item.corpNature},
|
||||
#{item.corpIndustryCategory},
|
||||
#{item.corpIndustry},
|
||||
#{item.corpEstablishDate},
|
||||
#{item.corpAddress},
|
||||
#{item.corpLegalRep},
|
||||
#{item.corpLegalCertType},
|
||||
#{item.corpLegalCertNo},
|
||||
#{item.corpShareholder1},
|
||||
#{item.corpShareholder2},
|
||||
#{item.corpShareholder3},
|
||||
#{item.corpShareholder4},
|
||||
#{item.corpShareholder5},
|
||||
#{item.dataSource},
|
||||
#{item.createBy},
|
||||
#{item.createTime},
|
||||
#{item.updateBy},
|
||||
#{item.updateTime}
|
||||
)
|
||||
</foreach>
|
||||
</insert>
|
||||
|
||||
<!-- 批量更新中介黑名单数据 -->
|
||||
<update id="batchUpdate" parameterType="java.util.List">
|
||||
<foreach collection="list" item="item" separator=";">
|
||||
UPDATE dpc_intermediary_blacklist
|
||||
<set>
|
||||
<if test="item.name != null">name = #{item.name},</if>
|
||||
<if test="item.certificateNo != null">certificate_no = #{item.certificateNo},</if>
|
||||
<if test="item.intermediaryType != null">intermediary_type = #{item.intermediaryType},</if>
|
||||
<if test="item.status != null">status = #{item.status},</if>
|
||||
<if test="item.remark != null">remark = #{item.remark},</if>
|
||||
<if test="item.indivType != null">indiv_type = #{item.indivType},</if>
|
||||
<if test="item.indivSubType != null">indiv_sub_type = #{item.indivSubType},</if>
|
||||
<if test="item.indivGender != null">indiv_gender = #{item.indivGender},</if>
|
||||
<if test="item.indivCertType != null">indiv_cert_type = #{item.indivCertType},</if>
|
||||
<if test="item.indivPhone != null">indiv_phone = #{item.indivPhone},</if>
|
||||
<if test="item.indivWechat != null">indiv_wechat = #{item.indivWechat},</if>
|
||||
<if test="item.indivAddress != null">indiv_address = #{item.indivAddress},</if>
|
||||
<if test="item.indivCompany != null">indiv_company = #{item.indivCompany},</if>
|
||||
<if test="item.indivPosition != null">indiv_position = #{item.indivPosition},</if>
|
||||
<if test="item.indivRelatedId != null">indiv_related_id = #{item.indivRelatedId},</if>
|
||||
<if test="item.indivRelation != null">indiv_relation = #{item.indivRelation},</if>
|
||||
<if test="item.corpCreditCode != null">corp_credit_code = #{item.corpCreditCode},</if>
|
||||
<if test="item.corpType != null">corp_type = #{item.corpType},</if>
|
||||
<if test="item.corpNature != null">corp_nature = #{item.corpNature},</if>
|
||||
<if test="item.corpIndustryCategory != null">corp_industry_category = #{item.corpIndustryCategory},</if>
|
||||
<if test="item.corpIndustry != null">corp_industry = #{item.corpIndustry},</if>
|
||||
<if test="item.corpEstablishDate != null">corp_establish_date = #{item.corpEstablishDate},</if>
|
||||
<if test="item.corpAddress != null">corp_address = #{item.corpAddress},</if>
|
||||
<if test="item.corpLegalRep != null">corp_legal_rep = #{item.corpLegalRep},</if>
|
||||
<if test="item.corpLegalCertType != null">corp_legal_cert_type = #{item.corpLegalCertType},</if>
|
||||
<if test="item.corpLegalCertNo != null">corp_legal_cert_no = #{item.corpLegalCertNo},</if>
|
||||
<if test="item.corpShareholder1 != null">corp_shareholder_1 = #{item.corpShareholder1},</if>
|
||||
<if test="item.corpShareholder2 != null">corp_shareholder_2 = #{item.corpShareholder2},</if>
|
||||
<if test="item.corpShareholder3 != null">corp_shareholder_3 = #{item.corpShareholder3},</if>
|
||||
<if test="item.corpShareholder4 != null">corp_shareholder_4 = #{item.corpShareholder4},</if>
|
||||
<if test="item.corpShareholder5 != null">corp_shareholder_5 = #{item.corpShareholder5},</if>
|
||||
<if test="item.dataSource != null">data_source = #{item.dataSource},</if>
|
||||
<if test="item.certificateNo != null">certificate_no = #{item.certificateNo},</if>
|
||||
update_by = #{item.updateBy},
|
||||
update_time = #{item.updateTime}
|
||||
</set>
|
||||
WHERE intermediary_id = #{item.intermediaryId}
|
||||
</foreach>
|
||||
</update>
|
||||
|
||||
</mapper>
|
||||
Reference in New Issue
Block a user