Commit 12689630f827bb4db6a7a8c03459b5ca39e03984

Authored by 房远帅
1 parent 47a320ec

楚江ERP:客户资信-资信、核心人员历史记录实体构建

Showing 18 changed files with 2488 additions and 0 deletions
  1 +package com.lframework.xingyun.sc.bo.customer.credit;
  2 +
  3 +import com.fasterxml.jackson.annotation.JsonFormat;
  4 +import com.lframework.starter.common.constants.StringPool;
  5 +import java.time.LocalDateTime;
  6 +import com.lframework.starter.web.core.bo.BaseBo;
  7 +import com.lframework.xingyun.sc.entity.CorePersonnelHistory;
  8 +import io.swagger.annotations.ApiModelProperty;
  9 +
  10 +import lombok.Data;
  11 +
  12 +/**
  13 + * <p>
  14 + * 核心人员历史记录表 GetBo
  15 + * </p>
  16 + *
  17 + */
  18 +@Data
  19 +public class GetCorePersonnelHistoryBo extends BaseBo<CorePersonnelHistory> {
  20 +
  21 + /**
  22 + * ID
  23 + */
  24 + @ApiModelProperty("ID")
  25 + private String id;
  26 +
  27 + /**
  28 + * 核心人员ID
  29 + */
  30 + @ApiModelProperty("核心人员ID")
  31 + private String personnelId;
  32 +
  33 + /**
  34 + * 第几次变更
  35 + */
  36 + @ApiModelProperty("第几次变更")
  37 + private String sort;
  38 +
  39 + /**
  40 + * 客户资信
  41 + */
  42 + @ApiModelProperty("客户资信")
  43 + private String creditId;
  44 +
  45 + /**
  46 + * 姓名
  47 + */
  48 + @ApiModelProperty("姓名")
  49 + private String name;
  50 +
  51 + /**
  52 + * 性别
  53 + */
  54 + @ApiModelProperty("性别")
  55 + private String sex;
  56 +
  57 + /**
  58 + * 籍贯
  59 + */
  60 + @ApiModelProperty("籍贯")
  61 + private String nativePlace;
  62 +
  63 + /**
  64 + * 年龄
  65 + */
  66 + @ApiModelProperty("年龄")
  67 + private String age;
  68 +
  69 + /**
  70 + * 职务
  71 + */
  72 + @ApiModelProperty("职务")
  73 + private String position;
  74 +
  75 + /**
  76 + * 手机
  77 + */
  78 + @ApiModelProperty("手机")
  79 + private String mobile;
  80 +
  81 + /**
  82 + * 固定电话
  83 + */
  84 + @ApiModelProperty("固定电话")
  85 + private String phone;
  86 +
  87 + /**
  88 + * 邮箱地址
  89 + */
  90 + @ApiModelProperty("邮箱地址")
  91 + private String email;
  92 +
  93 + /**
  94 + * 现住址
  95 + */
  96 + @ApiModelProperty("现住址")
  97 + private String address;
  98 +
  99 + /**
  100 + * 创建时间
  101 + */
  102 + @ApiModelProperty("创建时间")
  103 + @JsonFormat(pattern = StringPool.DATE_TIME_PATTERN)
  104 + private LocalDateTime createTime;
  105 +
  106 + /**
  107 + * 前端自用id
  108 + */
  109 + @ApiModelProperty("前端自用id")
  110 + private String personId;
  111 +
  112 + public GetCorePersonnelHistoryBo() {
  113 +
  114 + }
  115 +
  116 + public GetCorePersonnelHistoryBo(CorePersonnelHistory dto) {
  117 +
  118 + super(dto);
  119 + }
  120 +
  121 + @Override
  122 + public BaseBo<CorePersonnelHistory> convert(CorePersonnelHistory dto) {
  123 + return super.convert(dto);
  124 + }
  125 +
  126 + @Override
  127 + protected void afterInit(CorePersonnelHistory dto) {
  128 +
  129 + }
  130 +}
... ...
  1 +package com.lframework.xingyun.sc.bo.customer.credit;
  2 +
  3 +import com.fasterxml.jackson.annotation.JsonFormat;
  4 +import java.math.BigDecimal;
  5 +import com.lframework.starter.common.constants.StringPool;
  6 +import java.time.LocalDate;
  7 +import java.time.LocalDateTime;
  8 +
  9 +import com.lframework.starter.web.core.bo.BaseBo;
  10 +import com.lframework.xingyun.sc.entity.CustomerCreditHistory;
  11 +import io.swagger.annotations.ApiModelProperty;
  12 +
  13 +import lombok.Data;
  14 +
  15 +/**
  16 + * <p>
  17 + * 客户资信历史记录表 GetBo
  18 + * </p>
  19 + *
  20 + */
  21 +@Data
  22 +public class GetCustomerCreditHistoryBo extends BaseBo<CustomerCreditHistory> {
  23 +
  24 + /**
  25 + * ID
  26 + */
  27 + @ApiModelProperty("ID")
  28 + private String id;
  29 +
  30 + /**
  31 + * 客户资信ID
  32 + */
  33 + @ApiModelProperty("客户资信ID")
  34 + private String creditId;
  35 +
  36 + /**
  37 + * 第几次变更
  38 + */
  39 + @ApiModelProperty("第几次变更")
  40 + private String sort;
  41 +
  42 + /**
  43 + * 编号
  44 + */
  45 + @ApiModelProperty("编号")
  46 + private String serialNumber;
  47 +
  48 + /**
  49 + * 区域
  50 + */
  51 + @ApiModelProperty("区域")
  52 + private String region;
  53 +
  54 + /**
  55 + * 登记日期
  56 + */
  57 + @ApiModelProperty("登记日期")
  58 + @JsonFormat(pattern = StringPool.DATE_PATTERN)
  59 + private LocalDate registerDate;
  60 +
  61 + /**
  62 + * 客户简称
  63 + */
  64 + @ApiModelProperty("客户简称")
  65 + private String customerShortName;
  66 +
  67 + /**
  68 + * 企业类型:经销商(distributor)、终端(terminal)
  69 + */
  70 + @ApiModelProperty("企业类型:经销商(distributor)、终端(terminal)")
  71 + private String enterpriseType;
  72 +
  73 + /**
  74 + * 单位名称
  75 + */
  76 + @ApiModelProperty("单位名称")
  77 + private String companyId;
  78 +
  79 + /**
  80 + * 企业性质
  81 + */
  82 + @ApiModelProperty("企业性质")
  83 + private String companyNature;
  84 +
  85 + /**
  86 + * 单位地址
  87 + */
  88 + @ApiModelProperty("单位地址")
  89 + private String companyAddress;
  90 +
  91 + /**
  92 + * 注册资本(单位:万元)
  93 + */
  94 + @ApiModelProperty("注册资本(单位:万元)")
  95 + private BigDecimal registeredCapital;
  96 +
  97 + /**
  98 + * 账号
  99 + */
  100 + @ApiModelProperty("账号")
  101 + private String bankAccount;
  102 +
  103 + /**
  104 + * 开户行
  105 + */
  106 + @ApiModelProperty("开户行")
  107 + private String bankName;
  108 +
  109 + /**
  110 + * 税号
  111 + */
  112 + @ApiModelProperty("税号")
  113 + private String taxNumber;
  114 +
  115 + /**
  116 + * 注册时间
  117 + */
  118 + @ApiModelProperty("注册时间")
  119 + @JsonFormat(pattern = StringPool.DATE_PATTERN)
  120 + private LocalDate registrationTime;
  121 +
  122 + /**
  123 + * 经营年限(年)
  124 + */
  125 + @ApiModelProperty("经营年限(年)")
  126 + private String businessYears;
  127 +
  128 + /**
  129 + * 经营范围
  130 + */
  131 + @ApiModelProperty("经营范围")
  132 + private String businessScope;
  133 +
  134 + /**
  135 + * 经营场地属性
  136 + */
  137 + @ApiModelProperty("经营场地属性")
  138 + private String businessProperty;
  139 +
  140 + /**
  141 + * 占地面积(平方米)
  142 + */
  143 + @ApiModelProperty("占地面积(平方米)")
  144 + private String landArea;
  145 +
  146 + /**
  147 + * 仓储条件
  148 + */
  149 + @ApiModelProperty("仓储条件")
  150 + private String storageConditions;
  151 +
  152 + /**
  153 + * 员工人数
  154 + */
  155 + @ApiModelProperty("员工人数")
  156 + private Integer employeeCount;
  157 +
  158 + /**
  159 + * 设备属性
  160 + */
  161 + @ApiModelProperty("设备属性")
  162 + private String equipmentAttributes;
  163 +
  164 + /**
  165 + * 资产评估
  166 + */
  167 + @ApiModelProperty("资产评估")
  168 + private String assetEvaluation;
  169 +
  170 + /**
  171 + * 上年度销售额(万元)
  172 + */
  173 + @ApiModelProperty("上年度销售额(万元)")
  174 + private String lastYearSales;
  175 +
  176 + /**
  177 + * 月均销量(万元)
  178 + */
  179 + @ApiModelProperty("月均销量(万元)")
  180 + private String monthlyAvgSales;
  181 +
  182 + /**
  183 + * 销项发票所开品名与计量单位
  184 + */
  185 + @ApiModelProperty("销项发票所开品名与计量单位")
  186 + private String invoiceItemUnit;
  187 +
  188 + /**
  189 + * 认证证书我司售于产品与经营范围是否匹配
  190 + */
  191 + @ApiModelProperty("认证证书我司售于产品与经营范围是否匹配")
  192 + private String productMatch;
  193 +
  194 + /**
  195 + * 主要客户
  196 + */
  197 + @ApiModelProperty("主要客户")
  198 + private String majorCustomers;
  199 +
  200 + /**
  201 + * 主营项目
  202 + */
  203 + @ApiModelProperty("主营项目")
  204 + private String mainProjects;
  205 +
  206 + /**
  207 + * 从事行业
  208 + */
  209 + @ApiModelProperty("从事行业")
  210 + private String industryInvolved;
  211 +
  212 + /**
  213 + * 在该行业中的经验
  214 + */
  215 + @ApiModelProperty("在该行业中的经验")
  216 + private String industryExperience;
  217 +
  218 + /**
  219 + * 是否与其他企业有经济纠纷 违规信息 拖欠员工薪资等
  220 + */
  221 + @ApiModelProperty("是否与其他企业有经济纠纷 违规信息 拖欠员工薪资等")
  222 + private String hasDispute;
  223 +
  224 + /**
  225 + * 与我司合作时间
  226 + */
  227 + @ApiModelProperty("与我司合作时间")
  228 + private String cooperationStartDate;
  229 +
  230 + /**
  231 + * 月均操作量
  232 + */
  233 + @ApiModelProperty("月均操作量")
  234 + private String monthlyAvgVolume;
  235 +
  236 + /**
  237 + * 是否口头协议操作
  238 + */
  239 + @ApiModelProperty("是否口头协议操作")
  240 + private String isVerbalAgreement;
  241 +
  242 + /**
  243 + * 是否签订其他协议(列举)
  244 + */
  245 + @ApiModelProperty("是否签订其他协议(列举)")
  246 + private String otherAgreements;
  247 +
  248 + /**
  249 + * 与我司操作是否签订长年合同
  250 + */
  251 + @ApiModelProperty("与我司操作是否签订长年合同")
  252 + private String hasLongTermContract;
  253 +
  254 + /**
  255 + * 合同类型
  256 + */
  257 + @ApiModelProperty("合同类型")
  258 + private String contractType;
  259 +
  260 + /**
  261 + * 是否有过中断及中断原因
  262 + */
  263 + @ApiModelProperty("是否有过中断及中断原因")
  264 + private String hasInterruption;
  265 +
  266 + /**
  267 + * 结算期限
  268 + */
  269 + @ApiModelProperty("结算期限")
  270 + private String settlementPeriod;
  271 +
  272 + /**
  273 + * 加工料提供时间
  274 + */
  275 + @ApiModelProperty("加工料提供时间")
  276 + private String materialSupplyPlan;
  277 +
  278 + /**
  279 + * 建议客户分类:AAA、AA、A、BBB、BB、B、C、D
  280 + */
  281 + @ApiModelProperty("建议客户分类:AAA、AA、A、BBB、BB、B、C、D")
  282 + private String suggestedCategory;
  283 +
  284 + /**
  285 + * 授信额度(万元)
  286 + */
  287 + @ApiModelProperty("授信额度(万元)")
  288 + private String creditLimit;
  289 +
  290 + /**
  291 + * 调查人
  292 + */
  293 + @ApiModelProperty("调查人")
  294 + private String investigator;
  295 +
  296 + /**
  297 + * 主管审核
  298 + */
  299 + @ApiModelProperty("主管审核")
  300 + private String supervisorReview;
  301 +
  302 + /**
  303 + * 年度总销量(万元)
  304 + */
  305 + @ApiModelProperty("年度总销量(万元)")
  306 + private String annualTotalSales;
  307 +
  308 + /**
  309 + * 主要行业
  310 + */
  311 + @ApiModelProperty("主要行业")
  312 + private String mainIndustry;
  313 +
  314 + /**
  315 + * 年度款料概况
  316 + */
  317 + @ApiModelProperty("年度款料概况")
  318 + private String annualMaterialOverview;
  319 +
  320 + /**
  321 + * 结算期限
  322 + */
  323 + @ApiModelProperty("结算期限")
  324 + private String companySettlementPeriod;
  325 +
  326 + /**
  327 + * 授信额度(万元)
  328 + */
  329 + @ApiModelProperty("授信额度(万元)")
  330 + private String companyCreditLimit;
  331 +
  332 + /**
  333 + * 加工料提供时间
  334 + */
  335 + @ApiModelProperty("加工料提供时间")
  336 + private String companyMaterialSupplyPlan;
  337 +
  338 + /**
  339 + * 建议客户分类:AAA、AA、A、BBB、BB、B、C、D
  340 + */
  341 + @ApiModelProperty("建议客户分类:AAA、AA、A、BBB、BB、B、C、D")
  342 + private String companySuggestedCategory;
  343 +
  344 + /**
  345 + * 创建时间
  346 + */
  347 + @ApiModelProperty("创建时间")
  348 + @JsonFormat(pattern = StringPool.DATE_TIME_PATTERN)
  349 + private LocalDateTime createTime;
  350 +
  351 + /**
  352 + * 审核状态
  353 + */
  354 + @ApiModelProperty("审核状态")
  355 + private String status;
  356 +
  357 + /**
  358 + * 认证证书
  359 + */
  360 + @ApiModelProperty("认证证书")
  361 + private String certificationCertificate;
  362 +
  363 + public GetCustomerCreditHistoryBo() {
  364 +
  365 + }
  366 +
  367 + public GetCustomerCreditHistoryBo(CustomerCreditHistory dto) {
  368 +
  369 + super(dto);
  370 + }
  371 +
  372 + @Override
  373 + public BaseBo<CustomerCreditHistory> convert(CustomerCreditHistory dto) {
  374 + return super.convert(dto);
  375 + }
  376 +
  377 + @Override
  378 + protected void afterInit(CustomerCreditHistory dto) {
  379 +
  380 + }
  381 +}
... ...
  1 +package com.lframework.xingyun.sc.controller.customer;
  2 +
  3 +import com.lframework.starter.web.core.annotations.security.HasPermission;
  4 +import com.lframework.starter.web.core.controller.DefaultBaseController;
  5 +import com.lframework.starter.web.core.utils.PageResultUtil;
  6 +import com.lframework.starter.web.core.components.resp.PageResult;
  7 +import com.lframework.starter.web.core.components.resp.InvokeResult;
  8 +import javax.validation.constraints.NotBlank;
  9 +import com.lframework.xingyun.sc.bo.customer.credit.GetCorePersonnelHistoryBo;
  10 +import com.lframework.xingyun.sc.entity.CorePersonnelHistory;
  11 +import com.lframework.xingyun.sc.service.customer.CorePersonnelHistoryService;
  12 +import com.lframework.xingyun.sc.vo.customer.credit.CreateCorePersonnelHistoryVo;
  13 +import com.lframework.xingyun.sc.vo.customer.credit.QueryCorePersonnelHistoryVo;
  14 +import io.swagger.annotations.ApiImplicitParam;
  15 +import com.lframework.starter.web.core.components.resp.InvokeResultBuilder;
  16 +import com.lframework.starter.common.exceptions.impl.DefaultClientException;
  17 +import io.swagger.annotations.ApiOperation;
  18 +import com.lframework.starter.common.utils.CollectionUtil;
  19 +import io.swagger.annotations.Api;
  20 +import org.springframework.web.bind.annotation.DeleteMapping;
  21 +import org.springframework.beans.factory.annotation.Autowired;
  22 +import org.springframework.validation.annotation.Validated;
  23 +import org.springframework.web.bind.annotation.*;
  24 +
  25 +import javax.validation.Valid;
  26 +import java.util.List;
  27 +import java.util.stream.Collectors;
  28 +
  29 +/**
  30 + * 核心人员历史记录表 Controller
  31 + *
  32 + */
  33 +@Api(tags = "核心人员历史记录表")
  34 +@Validated
  35 +@RestController
  36 +@RequestMapping("/personnelHistory/corepersonnelhistory")
  37 +public class CorePersonnelHistoryController extends DefaultBaseController {
  38 +
  39 + @Autowired
  40 + private CorePersonnelHistoryService corePersonnelHistoryService;
  41 +
  42 + /**
  43 + * 查询列表
  44 + */
  45 + @ApiOperation("查询列表")
  46 + @HasPermission({"personnelHistory:corepersonnelhistory:query"})
  47 + @GetMapping("/query")
  48 + public InvokeResult<PageResult<GetCorePersonnelHistoryBo>> query(@Valid QueryCorePersonnelHistoryVo vo) {
  49 +
  50 + PageResult<CorePersonnelHistory> pageResult = corePersonnelHistoryService.query(getPageIndex(vo), getPageSize(vo), vo);
  51 +
  52 + List<CorePersonnelHistory> datas = pageResult.getDatas();
  53 + List<GetCorePersonnelHistoryBo> results = null;
  54 +
  55 + if (!CollectionUtil.isEmpty(datas)) {
  56 + results = datas.stream().map(GetCorePersonnelHistoryBo::new).collect(Collectors.toList());
  57 + }
  58 +
  59 + return InvokeResultBuilder.success(PageResultUtil.rebuild(pageResult, results));
  60 + }
  61 +
  62 + /**
  63 + * 根据ID查询
  64 + */
  65 + @ApiOperation("根据ID查询")
  66 + @ApiImplicitParam(value = "id", name = "id", paramType = "query", required = true)
  67 + @HasPermission({"personnelHistory:corepersonnelhistory:query"})
  68 + @GetMapping
  69 + public InvokeResult<GetCorePersonnelHistoryBo> get(@NotBlank(message = "id不能为空!") String id) {
  70 +
  71 + CorePersonnelHistory data = corePersonnelHistoryService.findById(id);
  72 + if (data == null) {
  73 + throw new DefaultClientException("核心人员历史记录表不存在!");
  74 + }
  75 +
  76 + GetCorePersonnelHistoryBo result = new GetCorePersonnelHistoryBo(data);
  77 +
  78 + return InvokeResultBuilder.success(result);
  79 + }
  80 +
  81 + /**
  82 + * 新增
  83 + */
  84 + @ApiOperation("新增")
  85 + @HasPermission({"personnelHistory:corepersonnelhistory:add"})
  86 + @PostMapping
  87 + public InvokeResult<Void> create(@Valid CreateCorePersonnelHistoryVo vo) {
  88 +
  89 + corePersonnelHistoryService.create(vo);
  90 +
  91 + return InvokeResultBuilder.success();
  92 + }
  93 +
  94 + /**
  95 + * 根据ID删除
  96 + */
  97 + @ApiOperation("根据ID删除")
  98 + @ApiImplicitParam(value = "id", name = "id", paramType = "query", required = true)
  99 + @HasPermission({"personnelHistory:corepersonnelhistory:delete"})
  100 + @DeleteMapping
  101 + public InvokeResult<Void> deleteById(@NotBlank(message = "id不能为空!") String id) {
  102 +
  103 + corePersonnelHistoryService.deleteById(id);
  104 +
  105 + corePersonnelHistoryService.cleanCacheByKey(id);
  106 +
  107 + return InvokeResultBuilder.success();
  108 + }
  109 +}
... ...
  1 +package com.lframework.xingyun.sc.controller.customer;
  2 +
  3 +import com.lframework.starter.web.core.annotations.security.HasPermission;
  4 +import com.lframework.starter.web.core.controller.DefaultBaseController;
  5 +import com.lframework.starter.web.core.utils.PageResultUtil;
  6 +import com.lframework.starter.web.core.components.resp.PageResult;
  7 +import com.lframework.starter.web.core.components.resp.InvokeResult;
  8 +import javax.validation.constraints.NotBlank;
  9 +import com.lframework.xingyun.sc.bo.customer.credit.GetCustomerCreditHistoryBo;
  10 +import com.lframework.xingyun.sc.entity.CustomerCreditHistory;
  11 +import com.lframework.xingyun.sc.service.customer.CustomerCreditHistoryService;
  12 +import com.lframework.xingyun.sc.vo.customer.credit.CreateCustomerCreditHistoryVo;
  13 +import com.lframework.xingyun.sc.vo.customer.credit.QueryCustomerCreditHistoryVo;
  14 +import io.swagger.annotations.ApiImplicitParam;
  15 +import com.lframework.starter.web.core.components.resp.InvokeResultBuilder;
  16 +import com.lframework.starter.common.exceptions.impl.DefaultClientException;
  17 +import io.swagger.annotations.ApiOperation;
  18 +import com.lframework.starter.common.utils.CollectionUtil;
  19 +import io.swagger.annotations.Api;
  20 +import org.springframework.web.bind.annotation.DeleteMapping;
  21 +import org.springframework.beans.factory.annotation.Autowired;
  22 +import org.springframework.validation.annotation.Validated;
  23 +import org.springframework.web.bind.annotation.*;
  24 +
  25 +import javax.validation.Valid;
  26 +import java.util.List;
  27 +import java.util.stream.Collectors;
  28 +
  29 +/**
  30 + * 客户资信历史记录表 Controller
  31 + *
  32 + */
  33 +@Api(tags = "客户资信历史记录表")
  34 +@Validated
  35 +@RestController
  36 +@RequestMapping("/customerCreditHistory/customercredithistory")
  37 +public class CustomerCreditHistoryController extends DefaultBaseController {
  38 +
  39 + @Autowired
  40 + private CustomerCreditHistoryService customerCreditHistoryService;
  41 +
  42 + /**
  43 + * 查询列表
  44 + */
  45 + @ApiOperation("查询列表")
  46 + @HasPermission({"customerCreditHistory:customercredithistory:query"})
  47 + @GetMapping("/query")
  48 + public InvokeResult<PageResult<GetCustomerCreditHistoryBo>> query(@Valid QueryCustomerCreditHistoryVo vo) {
  49 +
  50 + PageResult<CustomerCreditHistory> pageResult = customerCreditHistoryService.query(getPageIndex(vo), getPageSize(vo), vo);
  51 +
  52 + List<CustomerCreditHistory> datas = pageResult.getDatas();
  53 + List<GetCustomerCreditHistoryBo> results = null;
  54 +
  55 + if (!CollectionUtil.isEmpty(datas)) {
  56 + results = datas.stream().map(GetCustomerCreditHistoryBo::new).collect(Collectors.toList());
  57 + }
  58 +
  59 + return InvokeResultBuilder.success(PageResultUtil.rebuild(pageResult, results));
  60 + }
  61 +
  62 + /**
  63 + * 根据ID查询
  64 + */
  65 + @ApiOperation("根据ID查询")
  66 + @ApiImplicitParam(value = "id", name = "id", paramType = "query", required = true)
  67 + @HasPermission({"customerCreditHistory:customercredithistory:query"})
  68 + @GetMapping
  69 + public InvokeResult<GetCustomerCreditHistoryBo> get(@NotBlank(message = "id不能为空!") String id) {
  70 +
  71 + CustomerCreditHistory data = customerCreditHistoryService.findById(id);
  72 + if (data == null) {
  73 + throw new DefaultClientException("客户资信历史记录表不存在!");
  74 + }
  75 +
  76 + GetCustomerCreditHistoryBo result = new GetCustomerCreditHistoryBo(data);
  77 +
  78 + return InvokeResultBuilder.success(result);
  79 + }
  80 +
  81 + /**
  82 + * 新增
  83 + */
  84 + @ApiOperation("新增")
  85 + @HasPermission({"customerCreditHistory:customercredithistory:add"})
  86 + @PostMapping
  87 + public InvokeResult<Void> create(@Valid CreateCustomerCreditHistoryVo vo) {
  88 +
  89 + customerCreditHistoryService.create(vo);
  90 +
  91 + return InvokeResultBuilder.success();
  92 + }
  93 +
  94 + /**
  95 + * 根据ID删除
  96 + */
  97 + @ApiOperation("根据ID删除")
  98 + @ApiImplicitParam(value = "id", name = "id", paramType = "query", required = true)
  99 + @HasPermission({"customerCreditHistory:customercredithistory:delete"})
  100 + @DeleteMapping
  101 + public InvokeResult<Void> deleteById(@NotBlank(message = "id不能为空!") String id) {
  102 +
  103 + customerCreditHistoryService.deleteById(id);
  104 +
  105 + customerCreditHistoryService.cleanCacheByKey(id);
  106 +
  107 + return InvokeResultBuilder.success();
  108 + }
  109 +}
... ...
  1 +package com.lframework.xingyun.sc.entity;
  2 +
  3 +import com.baomidou.mybatisplus.annotation.TableName;
  4 +import com.lframework.starter.web.core.dto.BaseDto;
  5 +import java.time.LocalDateTime;
  6 +import com.baomidou.mybatisplus.annotation.FieldFill;
  7 +import com.lframework.starter.web.core.entity.BaseEntity;
  8 +import com.baomidou.mybatisplus.annotation.TableField;
  9 +import lombok.Data;
  10 +
  11 +/**
  12 + * <p>
  13 + * 核心人员历史记录表
  14 + * </p>
  15 + *
  16 + */
  17 +@Data
  18 +@TableName("core_personnel_history")
  19 +public class CorePersonnelHistory extends BaseEntity implements BaseDto {
  20 +
  21 + private static final long serialVersionUID = 1L;
  22 +
  23 + public static final String CACHE_NAME = "CorePersonnelHistory";
  24 +
  25 + /**
  26 + * ID
  27 + */
  28 + private String id;
  29 +
  30 + /**
  31 + * 核心人员ID
  32 + */
  33 + private String personnelId;
  34 +
  35 + /**
  36 + * 第几次变更
  37 + */
  38 + private String sort;
  39 +
  40 + /**
  41 + * 客户资信
  42 + */
  43 + private String creditId;
  44 +
  45 + /**
  46 + * 姓名
  47 + */
  48 + private String name;
  49 +
  50 + /**
  51 + * 性别
  52 + */
  53 + private String sex;
  54 +
  55 + /**
  56 + * 籍贯
  57 + */
  58 + private String nativePlace;
  59 +
  60 + /**
  61 + * 年龄
  62 + */
  63 + private String age;
  64 +
  65 + /**
  66 + * 职务
  67 + */
  68 + private String position;
  69 +
  70 + /**
  71 + * 手机
  72 + */
  73 + private String mobile;
  74 +
  75 + /**
  76 + * 固定电话
  77 + */
  78 + private String phone;
  79 +
  80 + /**
  81 + * 邮箱地址
  82 + */
  83 + private String email;
  84 +
  85 + /**
  86 + * 现住址
  87 + */
  88 + private String address;
  89 +
  90 + /**
  91 + * 创建人ID
  92 + */
  93 + @TableField(fill = FieldFill.INSERT)
  94 + private String createById;
  95 +
  96 + /**
  97 + * 创建人
  98 + */
  99 + @TableField(fill = FieldFill.INSERT)
  100 + private String createBy;
  101 +
  102 + /**
  103 + * 更新人ID
  104 + */
  105 + @TableField(fill = FieldFill.INSERT_UPDATE)
  106 + private String updateById;
  107 +
  108 + /**
  109 + * 更新人
  110 + */
  111 + @TableField(fill = FieldFill.INSERT_UPDATE)
  112 + private String updateBy;
  113 +
  114 + /**
  115 + * 创建时间
  116 + */
  117 + @TableField(fill = FieldFill.INSERT)
  118 + private LocalDateTime createTime;
  119 +
  120 + /**
  121 + * 更新时间
  122 + */
  123 + @TableField(fill = FieldFill.INSERT_UPDATE)
  124 + private LocalDateTime updateTime;
  125 +
  126 + /**
  127 + * 前端自用id
  128 + */
  129 + private String personId;
  130 +
  131 +}
... ...
  1 +package com.lframework.xingyun.sc.entity;
  2 +
  3 +import com.baomidou.mybatisplus.annotation.TableName;
  4 +import java.math.BigDecimal;
  5 +import com.lframework.starter.web.core.dto.BaseDto;
  6 +import java.time.LocalDate;
  7 +import java.time.LocalDateTime;
  8 +import com.baomidou.mybatisplus.annotation.FieldFill;
  9 +import com.lframework.starter.web.core.entity.BaseEntity;
  10 +import com.baomidou.mybatisplus.annotation.TableField;
  11 +import lombok.Data;
  12 +
  13 +/**
  14 + * <p>
  15 + * 客户资信历史记录表
  16 + * </p>
  17 + *
  18 + */
  19 +@Data
  20 +@TableName("customer_credit_history")
  21 +public class CustomerCreditHistory extends BaseEntity implements BaseDto {
  22 +
  23 + private static final long serialVersionUID = 1L;
  24 +
  25 + public static final String CACHE_NAME = "CustomerCreditHistory";
  26 +
  27 + /**
  28 + * ID
  29 + */
  30 + private String id;
  31 +
  32 + /**
  33 + * 客户资信ID
  34 + */
  35 + private String creditId;
  36 +
  37 + /**
  38 + * 第几次变更
  39 + */
  40 + private String sort;
  41 +
  42 + /**
  43 + * 编号
  44 + */
  45 + private String serialNumber;
  46 +
  47 + /**
  48 + * 区域
  49 + */
  50 + private String region;
  51 +
  52 + /**
  53 + * 登记日期
  54 + */
  55 + private LocalDate registerDate;
  56 +
  57 + /**
  58 + * 客户简称
  59 + */
  60 + private String customerShortName;
  61 +
  62 + /**
  63 + * 企业类型:经销商(distributor)、终端(terminal)
  64 + */
  65 + private String enterpriseType;
  66 +
  67 + /**
  68 + * 单位名称
  69 + */
  70 + private String companyId;
  71 +
  72 + /**
  73 + * 企业性质
  74 + */
  75 + private String companyNature;
  76 +
  77 + /**
  78 + * 单位地址
  79 + */
  80 + private String companyAddress;
  81 +
  82 + /**
  83 + * 注册资本(单位:万元)
  84 + */
  85 + private BigDecimal registeredCapital;
  86 +
  87 + /**
  88 + * 账号
  89 + */
  90 + private String bankAccount;
  91 +
  92 + /**
  93 + * 开户行
  94 + */
  95 + private String bankName;
  96 +
  97 + /**
  98 + * 税号
  99 + */
  100 + private String taxNumber;
  101 +
  102 + /**
  103 + * 注册时间
  104 + */
  105 + private LocalDate registrationTime;
  106 +
  107 + /**
  108 + * 经营年限(年)
  109 + */
  110 + private String businessYears;
  111 +
  112 + /**
  113 + * 经营范围
  114 + */
  115 + private String businessScope;
  116 +
  117 + /**
  118 + * 经营场地属性
  119 + */
  120 + private String businessProperty;
  121 +
  122 + /**
  123 + * 占地面积(平方米)
  124 + */
  125 + private String landArea;
  126 +
  127 + /**
  128 + * 仓储条件
  129 + */
  130 + private String storageConditions;
  131 +
  132 + /**
  133 + * 员工人数
  134 + */
  135 + private Integer employeeCount;
  136 +
  137 + /**
  138 + * 设备属性
  139 + */
  140 + private String equipmentAttributes;
  141 +
  142 + /**
  143 + * 资产评估
  144 + */
  145 + private String assetEvaluation;
  146 +
  147 + /**
  148 + * 上年度销售额(万元)
  149 + */
  150 + private String lastYearSales;
  151 +
  152 + /**
  153 + * 月均销量(万元)
  154 + */
  155 + private String monthlyAvgSales;
  156 +
  157 + /**
  158 + * 销项发票所开品名与计量单位
  159 + */
  160 + private String invoiceItemUnit;
  161 +
  162 + /**
  163 + * 认证证书我司售于产品与经营范围是否匹配
  164 + */
  165 + private String productMatch;
  166 +
  167 + /**
  168 + * 主要客户
  169 + */
  170 + private String majorCustomers;
  171 +
  172 + /**
  173 + * 主营项目
  174 + */
  175 + private String mainProjects;
  176 +
  177 + /**
  178 + * 从事行业
  179 + */
  180 + private String industryInvolved;
  181 +
  182 + /**
  183 + * 在该行业中的经验
  184 + */
  185 + private String industryExperience;
  186 +
  187 + /**
  188 + * 是否与其他企业有经济纠纷 违规信息 拖欠员工薪资等
  189 + */
  190 + private String hasDispute;
  191 +
  192 + /**
  193 + * 与我司合作时间
  194 + */
  195 + private String cooperationStartDate;
  196 +
  197 + /**
  198 + * 月均操作量
  199 + */
  200 + private String monthlyAvgVolume;
  201 +
  202 + /**
  203 + * 是否口头协议操作
  204 + */
  205 + private String isVerbalAgreement;
  206 +
  207 + /**
  208 + * 是否签订其他协议(列举)
  209 + */
  210 + private String otherAgreements;
  211 +
  212 + /**
  213 + * 与我司操作是否签订长年合同
  214 + */
  215 + private String hasLongTermContract;
  216 +
  217 + /**
  218 + * 合同类型
  219 + */
  220 + private String contractType;
  221 +
  222 + /**
  223 + * 是否有过中断及中断原因
  224 + */
  225 + private String hasInterruption;
  226 +
  227 + /**
  228 + * 结算期限
  229 + */
  230 + private String settlementPeriod;
  231 +
  232 + /**
  233 + * 加工料提供时间
  234 + */
  235 + private String materialSupplyPlan;
  236 +
  237 + /**
  238 + * 建议客户分类:AAA、AA、A、BBB、BB、B、C、D
  239 + */
  240 + private String suggestedCategory;
  241 +
  242 + /**
  243 + * 授信额度(万元)
  244 + */
  245 + private String creditLimit;
  246 +
  247 + /**
  248 + * 调查人
  249 + */
  250 + private String investigator;
  251 +
  252 + /**
  253 + * 主管审核
  254 + */
  255 + private String supervisorReview;
  256 +
  257 + /**
  258 + * 年度总销量(万元)
  259 + */
  260 + private String annualTotalSales;
  261 +
  262 + /**
  263 + * 主要行业
  264 + */
  265 + private String mainIndustry;
  266 +
  267 + /**
  268 + * 年度款料概况
  269 + */
  270 + private String annualMaterialOverview;
  271 +
  272 + /**
  273 + * 结算期限
  274 + */
  275 + private String companySettlementPeriod;
  276 +
  277 + /**
  278 + * 授信额度(万元)
  279 + */
  280 + private String companyCreditLimit;
  281 +
  282 + /**
  283 + * 加工料提供时间
  284 + */
  285 + private String companyMaterialSupplyPlan;
  286 +
  287 + /**
  288 + * 建议客户分类:AAA、AA、A、BBB、BB、B、C、D
  289 + */
  290 + private String companySuggestedCategory;
  291 +
  292 + /**
  293 + * 创建人ID
  294 + */
  295 + @TableField(fill = FieldFill.INSERT)
  296 + private String createById;
  297 +
  298 + /**
  299 + * 创建人
  300 + */
  301 + @TableField(fill = FieldFill.INSERT)
  302 + private String createBy;
  303 +
  304 + /**
  305 + * 更新人ID
  306 + */
  307 + @TableField(fill = FieldFill.INSERT_UPDATE)
  308 + private String updateById;
  309 +
  310 + /**
  311 + * 更新人
  312 + */
  313 + @TableField(fill = FieldFill.INSERT_UPDATE)
  314 + private String updateBy;
  315 +
  316 + /**
  317 + * 创建时间
  318 + */
  319 + @TableField(fill = FieldFill.INSERT)
  320 + private LocalDateTime createTime;
  321 +
  322 + /**
  323 + * 更新时间
  324 + */
  325 + @TableField(fill = FieldFill.INSERT_UPDATE)
  326 + private LocalDateTime updateTime;
  327 +
  328 + /**
  329 + * 审核状态
  330 + */
  331 + private String status;
  332 +
  333 + /**
  334 + * 认证证书
  335 + */
  336 + private String certificationCertificate;
  337 +
  338 +}
... ...
  1 +package com.lframework.xingyun.sc.impl.customer;
  2 +
  3 +import com.github.pagehelper.PageInfo;
  4 +import com.lframework.starter.web.core.impl.BaseMpServiceImpl;
  5 +import com.lframework.starter.web.core.utils.PageResultUtil;
  6 +import com.lframework.starter.web.core.components.resp.PageResult;
  7 +import com.lframework.starter.web.core.utils.OpLogUtil;
  8 +import com.lframework.starter.common.utils.StringUtil;
  9 +import java.io.Serializable;
  10 +import com.lframework.starter.web.core.utils.IdUtil;
  11 +import com.lframework.starter.web.core.annotations.oplog.OpLog;
  12 +import com.lframework.starter.web.core.utils.PageHelperUtil;
  13 +import com.lframework.starter.common.utils.Assert;
  14 +import com.lframework.starter.web.inner.components.oplog.OtherOpLogType;
  15 +import com.lframework.xingyun.sc.entity.CorePersonnelHistory;
  16 +import com.lframework.xingyun.sc.mappers.CorePersonnelHistoryMapper;
  17 +import com.lframework.xingyun.sc.service.customer.CorePersonnelHistoryService;
  18 +import com.lframework.xingyun.sc.vo.customer.credit.CreateCorePersonnelHistoryVo;
  19 +import com.lframework.xingyun.sc.vo.customer.credit.QueryCorePersonnelHistoryVo;
  20 +import org.springframework.transaction.annotation.Transactional;
  21 +import org.springframework.cache.annotation.CacheEvict;
  22 +import org.springframework.cache.annotation.Cacheable;
  23 +import org.springframework.stereotype.Service;
  24 +
  25 +import java.util.List;
  26 +
  27 +@Service
  28 +public class CorePersonnelHistoryServiceImpl extends BaseMpServiceImpl<CorePersonnelHistoryMapper, CorePersonnelHistory> implements CorePersonnelHistoryService {
  29 +
  30 + @Override
  31 + public PageResult<CorePersonnelHistory> query(Integer pageIndex, Integer pageSize, QueryCorePersonnelHistoryVo vo) {
  32 +
  33 + Assert.greaterThanZero(pageIndex);
  34 + Assert.greaterThanZero(pageSize);
  35 +
  36 + PageHelperUtil.startPage(pageIndex, pageSize);
  37 + List<CorePersonnelHistory> datas = this.query(vo);
  38 +
  39 + return PageResultUtil.convert(new PageInfo<>(datas));
  40 + }
  41 +
  42 + @Override
  43 + public List<CorePersonnelHistory> query(QueryCorePersonnelHistoryVo vo) {
  44 +
  45 + return getBaseMapper().query(vo);
  46 + }
  47 +
  48 + @Cacheable(value = CorePersonnelHistory.CACHE_NAME, key = "@cacheVariables.tenantId() + #id", unless = "#result == null")
  49 + @Override
  50 + public CorePersonnelHistory findById(String id) {
  51 +
  52 + return getBaseMapper().selectById(id);
  53 + }
  54 +
  55 + @OpLog(type = OtherOpLogType.class, name = "新增核心人员历史记录表,ID:{}", params = {"#id"})
  56 + @Transactional(rollbackFor = Exception.class)
  57 + @Override
  58 + public String create(CreateCorePersonnelHistoryVo vo) {
  59 +
  60 + CorePersonnelHistory data = new CorePersonnelHistory();
  61 + data.setId(IdUtil.getId());
  62 + data.setPersonnelId(vo.getPersonnelId());
  63 + data.setSort(vo.getSort());
  64 + data.setCreditId(vo.getCreditId());
  65 + data.setName(vo.getName());
  66 + if (!StringUtil.isBlank(vo.getSex())) {
  67 + data.setSex(vo.getSex());
  68 + }
  69 + if (!StringUtil.isBlank(vo.getNativePlace())) {
  70 + data.setNativePlace(vo.getNativePlace());
  71 + }
  72 + if (!StringUtil.isBlank(vo.getAge())) {
  73 + data.setAge(vo.getAge());
  74 + }
  75 + if (!StringUtil.isBlank(vo.getPosition())) {
  76 + data.setPosition(vo.getPosition());
  77 + }
  78 + if (!StringUtil.isBlank(vo.getMobile())) {
  79 + data.setMobile(vo.getMobile());
  80 + }
  81 + if (!StringUtil.isBlank(vo.getPhone())) {
  82 + data.setPhone(vo.getPhone());
  83 + }
  84 + if (!StringUtil.isBlank(vo.getEmail())) {
  85 + data.setEmail(vo.getEmail());
  86 + }
  87 + if (!StringUtil.isBlank(vo.getAddress())) {
  88 + data.setAddress(vo.getAddress());
  89 + }
  90 + if (!StringUtil.isBlank(vo.getPersonId())) {
  91 + data.setPersonId(vo.getPersonId());
  92 + }
  93 +
  94 + getBaseMapper().insert(data);
  95 +
  96 + OpLogUtil.setVariable("id", data.getId());
  97 + OpLogUtil.setExtra(vo);
  98 +
  99 + return data.getId();
  100 + }
  101 +
  102 + @OpLog(type = OtherOpLogType.class, name = "删除核心人员历史记录表,ID:{}", params = {"#id"})
  103 + @Transactional(rollbackFor = Exception.class)
  104 + @Override
  105 + public void deleteById(String id) {
  106 +
  107 + getBaseMapper().deleteById(id);
  108 + }
  109 +
  110 + @CacheEvict(value = CorePersonnelHistory.CACHE_NAME, key = "@cacheVariables.tenantId() + #key")
  111 + @Override
  112 + public void cleanCacheByKey(Serializable key) {
  113 +
  114 + }
  115 +}
... ...
  1 +package com.lframework.xingyun.sc.impl.customer;
  2 +
  3 +import com.github.pagehelper.PageInfo;
  4 +import com.lframework.starter.web.core.impl.BaseMpServiceImpl;
  5 +import com.lframework.starter.web.core.utils.PageResultUtil;
  6 +import com.lframework.starter.web.core.utils.OpLogUtil;
  7 +import com.lframework.starter.web.core.utils.IdUtil;
  8 +import com.lframework.starter.web.core.annotations.oplog.OpLog;
  9 +import com.lframework.starter.web.core.utils.PageHelperUtil;
  10 +import com.lframework.starter.web.inner.components.oplog.OtherOpLogType;
  11 +import com.lframework.starter.web.core.components.resp.PageResult;
  12 +import com.lframework.starter.common.utils.StringUtil;
  13 +import java.io.Serializable;
  14 +import com.lframework.starter.common.utils.Assert;
  15 +import com.lframework.xingyun.sc.entity.CustomerCreditHistory;
  16 +import com.lframework.xingyun.sc.mappers.CustomerCreditHistoryMapper;
  17 +import com.lframework.xingyun.sc.service.customer.CustomerCreditHistoryService;
  18 +import com.lframework.xingyun.sc.vo.customer.credit.CreateCustomerCreditHistoryVo;
  19 +import com.lframework.xingyun.sc.vo.customer.credit.QueryCustomerCreditHistoryVo;
  20 +import org.springframework.transaction.annotation.Transactional;
  21 +import org.springframework.cache.annotation.CacheEvict;
  22 +import org.springframework.cache.annotation.Cacheable;
  23 +import org.springframework.stereotype.Service;
  24 +
  25 +import java.util.List;
  26 +
  27 +@Service
  28 +public class CustomerCreditHistoryServiceImpl extends BaseMpServiceImpl<CustomerCreditHistoryMapper, CustomerCreditHistory> implements CustomerCreditHistoryService {
  29 +
  30 + @Override
  31 + public PageResult<CustomerCreditHistory> query(Integer pageIndex, Integer pageSize, QueryCustomerCreditHistoryVo vo) {
  32 +
  33 + Assert.greaterThanZero(pageIndex);
  34 + Assert.greaterThanZero(pageSize);
  35 +
  36 + PageHelperUtil.startPage(pageIndex, pageSize);
  37 + List<CustomerCreditHistory> datas = this.query(vo);
  38 +
  39 + return PageResultUtil.convert(new PageInfo<>(datas));
  40 + }
  41 +
  42 + @Override
  43 + public List<CustomerCreditHistory> query(QueryCustomerCreditHistoryVo vo) {
  44 +
  45 + return getBaseMapper().query(vo);
  46 + }
  47 +
  48 + @Cacheable(value = CustomerCreditHistory.CACHE_NAME, key = "@cacheVariables.tenantId() + #id", unless = "#result == null")
  49 + @Override
  50 + public CustomerCreditHistory findById(String id) {
  51 +
  52 + return getBaseMapper().selectById(id);
  53 + }
  54 +
  55 + @OpLog(type = OtherOpLogType.class, name = "新增客户资信历史记录表,ID:{}", params = {"#id"})
  56 + @Transactional(rollbackFor = Exception.class)
  57 + @Override
  58 + public String create(CreateCustomerCreditHistoryVo vo) {
  59 +
  60 + CustomerCreditHistory data = new CustomerCreditHistory();
  61 + data.setId(IdUtil.getId());
  62 + data.setCreditId(vo.getCreditId());
  63 + data.setSort(vo.getSort());
  64 + data.setSerialNumber(vo.getSerialNumber());
  65 + if (!StringUtil.isBlank(vo.getRegion())) {
  66 + data.setRegion(vo.getRegion());
  67 + }
  68 + if (vo.getRegisterDate() != null) {
  69 + data.setRegisterDate(vo.getRegisterDate());
  70 + }
  71 + if (!StringUtil.isBlank(vo.getCustomerShortName())) {
  72 + data.setCustomerShortName(vo.getCustomerShortName());
  73 + }
  74 + if (!StringUtil.isBlank(vo.getEnterpriseType())) {
  75 + data.setEnterpriseType(vo.getEnterpriseType());
  76 + }
  77 + if (!StringUtil.isBlank(vo.getCompanyId())) {
  78 + data.setCompanyId(vo.getCompanyId());
  79 + }
  80 + if (!StringUtil.isBlank(vo.getCompanyNature())) {
  81 + data.setCompanyNature(vo.getCompanyNature());
  82 + }
  83 + if (!StringUtil.isBlank(vo.getCompanyAddress())) {
  84 + data.setCompanyAddress(vo.getCompanyAddress());
  85 + }
  86 + if (vo.getRegisteredCapital() != null) {
  87 + data.setRegisteredCapital(vo.getRegisteredCapital());
  88 + }
  89 + if (!StringUtil.isBlank(vo.getBankAccount())) {
  90 + data.setBankAccount(vo.getBankAccount());
  91 + }
  92 + if (!StringUtil.isBlank(vo.getBankName())) {
  93 + data.setBankName(vo.getBankName());
  94 + }
  95 + if (!StringUtil.isBlank(vo.getTaxNumber())) {
  96 + data.setTaxNumber(vo.getTaxNumber());
  97 + }
  98 + if (vo.getRegistrationTime() != null) {
  99 + data.setRegistrationTime(vo.getRegistrationTime());
  100 + }
  101 + if (!StringUtil.isBlank(vo.getBusinessYears())) {
  102 + data.setBusinessYears(vo.getBusinessYears());
  103 + }
  104 + if (!StringUtil.isBlank(vo.getBusinessScope())) {
  105 + data.setBusinessScope(vo.getBusinessScope());
  106 + }
  107 + if (!StringUtil.isBlank(vo.getBusinessProperty())) {
  108 + data.setBusinessProperty(vo.getBusinessProperty());
  109 + }
  110 + if (!StringUtil.isBlank(vo.getLandArea())) {
  111 + data.setLandArea(vo.getLandArea());
  112 + }
  113 + if (!StringUtil.isBlank(vo.getStorageConditions())) {
  114 + data.setStorageConditions(vo.getStorageConditions());
  115 + }
  116 + if (vo.getEmployeeCount() != null) {
  117 + data.setEmployeeCount(vo.getEmployeeCount());
  118 + }
  119 + if (!StringUtil.isBlank(vo.getEquipmentAttributes())) {
  120 + data.setEquipmentAttributes(vo.getEquipmentAttributes());
  121 + }
  122 + if (!StringUtil.isBlank(vo.getAssetEvaluation())) {
  123 + data.setAssetEvaluation(vo.getAssetEvaluation());
  124 + }
  125 + if (!StringUtil.isBlank(vo.getLastYearSales())) {
  126 + data.setLastYearSales(vo.getLastYearSales());
  127 + }
  128 + if (!StringUtil.isBlank(vo.getMonthlyAvgSales())) {
  129 + data.setMonthlyAvgSales(vo.getMonthlyAvgSales());
  130 + }
  131 + if (!StringUtil.isBlank(vo.getInvoiceItemUnit())) {
  132 + data.setInvoiceItemUnit(vo.getInvoiceItemUnit());
  133 + }
  134 + if (!StringUtil.isBlank(vo.getProductMatch())) {
  135 + data.setProductMatch(vo.getProductMatch());
  136 + }
  137 + if (!StringUtil.isBlank(vo.getMajorCustomers())) {
  138 + data.setMajorCustomers(vo.getMajorCustomers());
  139 + }
  140 + if (!StringUtil.isBlank(vo.getMainProjects())) {
  141 + data.setMainProjects(vo.getMainProjects());
  142 + }
  143 + if (!StringUtil.isBlank(vo.getIndustryInvolved())) {
  144 + data.setIndustryInvolved(vo.getIndustryInvolved());
  145 + }
  146 + if (!StringUtil.isBlank(vo.getIndustryExperience())) {
  147 + data.setIndustryExperience(vo.getIndustryExperience());
  148 + }
  149 + if (!StringUtil.isBlank(vo.getHasDispute())) {
  150 + data.setHasDispute(vo.getHasDispute());
  151 + }
  152 + if (!StringUtil.isBlank(vo.getCooperationStartDate())) {
  153 + data.setCooperationStartDate(vo.getCooperationStartDate());
  154 + }
  155 + if (!StringUtil.isBlank(vo.getMonthlyAvgVolume())) {
  156 + data.setMonthlyAvgVolume(vo.getMonthlyAvgVolume());
  157 + }
  158 + if (!StringUtil.isBlank(vo.getIsVerbalAgreement())) {
  159 + data.setIsVerbalAgreement(vo.getIsVerbalAgreement());
  160 + }
  161 + if (!StringUtil.isBlank(vo.getOtherAgreements())) {
  162 + data.setOtherAgreements(vo.getOtherAgreements());
  163 + }
  164 + if (!StringUtil.isBlank(vo.getHasLongTermContract())) {
  165 + data.setHasLongTermContract(vo.getHasLongTermContract());
  166 + }
  167 + if (!StringUtil.isBlank(vo.getContractType())) {
  168 + data.setContractType(vo.getContractType());
  169 + }
  170 + if (!StringUtil.isBlank(vo.getHasInterruption())) {
  171 + data.setHasInterruption(vo.getHasInterruption());
  172 + }
  173 + if (!StringUtil.isBlank(vo.getSettlementPeriod())) {
  174 + data.setSettlementPeriod(vo.getSettlementPeriod());
  175 + }
  176 + if (!StringUtil.isBlank(vo.getMaterialSupplyPlan())) {
  177 + data.setMaterialSupplyPlan(vo.getMaterialSupplyPlan());
  178 + }
  179 + if (!StringUtil.isBlank(vo.getSuggestedCategory())) {
  180 + data.setSuggestedCategory(vo.getSuggestedCategory());
  181 + }
  182 + if (!StringUtil.isBlank(vo.getCreditLimit())) {
  183 + data.setCreditLimit(vo.getCreditLimit());
  184 + }
  185 + if (!StringUtil.isBlank(vo.getInvestigator())) {
  186 + data.setInvestigator(vo.getInvestigator());
  187 + }
  188 + if (!StringUtil.isBlank(vo.getSupervisorReview())) {
  189 + data.setSupervisorReview(vo.getSupervisorReview());
  190 + }
  191 + if (!StringUtil.isBlank(vo.getAnnualTotalSales())) {
  192 + data.setAnnualTotalSales(vo.getAnnualTotalSales());
  193 + }
  194 + if (!StringUtil.isBlank(vo.getMainIndustry())) {
  195 + data.setMainIndustry(vo.getMainIndustry());
  196 + }
  197 + if (!StringUtil.isBlank(vo.getAnnualMaterialOverview())) {
  198 + data.setAnnualMaterialOverview(vo.getAnnualMaterialOverview());
  199 + }
  200 + if (!StringUtil.isBlank(vo.getCompanySettlementPeriod())) {
  201 + data.setCompanySettlementPeriod(vo.getCompanySettlementPeriod());
  202 + }
  203 + if (!StringUtil.isBlank(vo.getCompanyCreditLimit())) {
  204 + data.setCompanyCreditLimit(vo.getCompanyCreditLimit());
  205 + }
  206 + if (!StringUtil.isBlank(vo.getCompanyMaterialSupplyPlan())) {
  207 + data.setCompanyMaterialSupplyPlan(vo.getCompanyMaterialSupplyPlan());
  208 + }
  209 + if (!StringUtil.isBlank(vo.getCompanySuggestedCategory())) {
  210 + data.setCompanySuggestedCategory(vo.getCompanySuggestedCategory());
  211 + }
  212 + if (!StringUtil.isBlank(vo.getStatus())) {
  213 + data.setStatus(vo.getStatus());
  214 + }
  215 + if (!StringUtil.isBlank(vo.getCertificationCertificate())) {
  216 + data.setCertificationCertificate(vo.getCertificationCertificate());
  217 + }
  218 +
  219 + getBaseMapper().insert(data);
  220 +
  221 + OpLogUtil.setVariable("id", data.getId());
  222 + OpLogUtil.setExtra(vo);
  223 +
  224 + return data.getId();
  225 + }
  226 +
  227 + @OpLog(type = OtherOpLogType.class, name = "删除客户资信历史记录表,ID:{}", params = {"#id"})
  228 + @Transactional(rollbackFor = Exception.class)
  229 + @Override
  230 + public void deleteById(String id) {
  231 +
  232 + getBaseMapper().deleteById(id);
  233 + }
  234 +
  235 + @CacheEvict(value = CustomerCreditHistory.CACHE_NAME, key = "@cacheVariables.tenantId() + #key")
  236 + @Override
  237 + public void cleanCacheByKey(Serializable key) {
  238 +
  239 + }
  240 +}
... ...
  1 +package com.lframework.xingyun.sc.mappers;
  2 +
  3 +import com.lframework.starter.web.core.mapper.BaseMapper;
  4 +import com.lframework.xingyun.sc.entity.CorePersonnelHistory;
  5 +import com.lframework.xingyun.sc.vo.customer.credit.QueryCorePersonnelHistoryVo;
  6 +import org.apache.ibatis.annotations.Param;
  7 +
  8 +import java.util.List;
  9 +
  10 +/**
  11 + * <p>
  12 + * 核心人员历史记录表 Mapper 接口
  13 + * </p>
  14 + *
  15 + */
  16 +public interface CorePersonnelHistoryMapper extends BaseMapper<CorePersonnelHistory> {
  17 +
  18 + /**
  19 + * 查询列表
  20 + * @param vo
  21 + * @return
  22 + */
  23 + List<CorePersonnelHistory> query(@Param("vo") QueryCorePersonnelHistoryVo vo);
  24 +}
... ...
  1 +package com.lframework.xingyun.sc.mappers;
  2 +
  3 +import com.lframework.starter.web.core.mapper.BaseMapper;
  4 +import com.lframework.xingyun.sc.entity.CustomerCreditHistory;
  5 +import com.lframework.xingyun.sc.vo.customer.credit.QueryCustomerCreditHistoryVo;
  6 +import org.apache.ibatis.annotations.Param;
  7 +
  8 +import java.util.List;
  9 +
  10 +/**
  11 + * <p>
  12 + * 客户资信历史记录表 Mapper 接口
  13 + * </p>
  14 + *
  15 + */
  16 +public interface CustomerCreditHistoryMapper extends BaseMapper<CustomerCreditHistory> {
  17 +
  18 + /**
  19 + * 查询列表
  20 + * @param vo
  21 + * @return
  22 + */
  23 + List<CustomerCreditHistory> query(@Param("vo") QueryCustomerCreditHistoryVo vo);
  24 +}
... ...
  1 +package com.lframework.xingyun.sc.service.customer;
  2 +
  3 +import com.lframework.starter.web.core.service.BaseMpService;
  4 +import com.lframework.starter.web.core.components.resp.PageResult;
  5 +import com.lframework.xingyun.sc.entity.CorePersonnelHistory;
  6 +import com.lframework.xingyun.sc.vo.customer.credit.CreateCorePersonnelHistoryVo;
  7 +import com.lframework.xingyun.sc.vo.customer.credit.QueryCorePersonnelHistoryVo;
  8 +import java.util.List;
  9 +
  10 +/**
  11 + * 核心人员历史记录表 Service
  12 + */
  13 +public interface CorePersonnelHistoryService extends BaseMpService<CorePersonnelHistory> {
  14 +
  15 + /**
  16 + * 查询列表
  17 + * @return
  18 + */
  19 + PageResult<CorePersonnelHistory> query(Integer pageIndex, Integer pageSize, QueryCorePersonnelHistoryVo vo);
  20 +
  21 + /**
  22 + * 查询列表
  23 + * @param vo
  24 + * @return
  25 + */
  26 + List<CorePersonnelHistory> query(QueryCorePersonnelHistoryVo vo);
  27 +
  28 + /**
  29 + * 根据ID查询
  30 + * @param id
  31 + * @return
  32 + */
  33 + CorePersonnelHistory findById(String id);
  34 +
  35 + /**
  36 + * 创建
  37 + * @param vo
  38 + * @return
  39 + */
  40 + String create(CreateCorePersonnelHistoryVo vo);
  41 +
  42 +
  43 + /**
  44 + * 根据ID删除
  45 + * @param id
  46 + * @return
  47 + */
  48 + void deleteById(String id);
  49 +}
... ...
  1 +package com.lframework.xingyun.sc.service.customer;
  2 +
  3 +import com.lframework.starter.web.core.service.BaseMpService;
  4 +import com.lframework.starter.web.core.components.resp.PageResult;
  5 +import com.lframework.xingyun.sc.entity.CustomerCreditHistory;
  6 +import com.lframework.xingyun.sc.vo.customer.credit.CreateCustomerCreditHistoryVo;
  7 +import com.lframework.xingyun.sc.vo.customer.credit.QueryCustomerCreditHistoryVo;
  8 +import java.util.List;
  9 +
  10 +/**
  11 + * 客户资信历史记录表 Service
  12 + */
  13 +public interface CustomerCreditHistoryService extends BaseMpService<CustomerCreditHistory> {
  14 +
  15 + /**
  16 + * 查询列表
  17 + * @return
  18 + */
  19 + PageResult<CustomerCreditHistory> query(Integer pageIndex, Integer pageSize, QueryCustomerCreditHistoryVo vo);
  20 +
  21 + /**
  22 + * 查询列表
  23 + * @param vo
  24 + * @return
  25 + */
  26 + List<CustomerCreditHistory> query(QueryCustomerCreditHistoryVo vo);
  27 +
  28 + /**
  29 + * 根据ID查询
  30 + * @param id
  31 + * @return
  32 + */
  33 + CustomerCreditHistory findById(String id);
  34 +
  35 + /**
  36 + * 创建
  37 + * @param vo
  38 + * @return
  39 + */
  40 + String create(CreateCustomerCreditHistoryVo vo);
  41 +
  42 +
  43 + /**
  44 + * 根据ID删除
  45 + * @param id
  46 + * @return
  47 + */
  48 + void deleteById(String id);
  49 +}
... ...
  1 +package com.lframework.xingyun.sc.vo.customer.credit;
  2 +
  3 +import javax.validation.constraints.NotBlank;
  4 +import com.lframework.starter.web.core.vo.BaseVo;
  5 +import io.swagger.annotations.ApiModelProperty;
  6 +import org.hibernate.validator.constraints.Length;
  7 +import java.io.Serializable;
  8 +import lombok.Data;
  9 +
  10 +@Data
  11 +public class CreateCorePersonnelHistoryVo implements BaseVo, Serializable {
  12 +
  13 + private static final long serialVersionUID = 1L;
  14 +
  15 + /**
  16 + * 核心人员ID
  17 + */
  18 + @ApiModelProperty(value = "核心人员ID", required = true)
  19 + @NotBlank(message = "请输入核心人员ID!")
  20 + @Length(message = "核心人员ID最多允许32个字符!")
  21 + private String personnelId;
  22 +
  23 + /**
  24 + * 第几次变更
  25 + */
  26 + @ApiModelProperty(value = "第几次变更", required = true)
  27 + @NotBlank(message = "请输入第几次变更!")
  28 + @Length(message = "第几次变更最多允许20个字符!")
  29 + private String sort;
  30 +
  31 + /**
  32 + * 客户资信
  33 + */
  34 + @ApiModelProperty(value = "客户资信", required = true)
  35 + @NotBlank(message = "请输入客户资信!")
  36 + @Length(message = "客户资信最多允许32个字符!")
  37 + private String creditId;
  38 +
  39 + /**
  40 + * 姓名
  41 + */
  42 + @ApiModelProperty(value = "姓名", required = true)
  43 + @NotBlank(message = "请输入姓名!")
  44 + @Length(message = "姓名最多允许50个字符!")
  45 + private String name;
  46 +
  47 + /**
  48 + * 性别
  49 + */
  50 + @ApiModelProperty("性别")
  51 + @Length(message = "性别最多允许20个字符!")
  52 + private String sex;
  53 +
  54 + /**
  55 + * 籍贯
  56 + */
  57 + @ApiModelProperty("籍贯")
  58 + @Length(message = "籍贯最多允许100个字符!")
  59 + private String nativePlace;
  60 +
  61 + /**
  62 + * 年龄
  63 + */
  64 + @ApiModelProperty("年龄")
  65 + @Length(message = "年龄最多允许10个字符!")
  66 + private String age;
  67 +
  68 + /**
  69 + * 职务
  70 + */
  71 + @ApiModelProperty("职务")
  72 + @Length(message = "职务最多允许50个字符!")
  73 + private String position;
  74 +
  75 + /**
  76 + * 手机
  77 + */
  78 + @ApiModelProperty("手机")
  79 + @Length(message = "手机最多允许11个字符!")
  80 + private String mobile;
  81 +
  82 + /**
  83 + * 固定电话
  84 + */
  85 + @ApiModelProperty("固定电话")
  86 + @Length(message = "固定电话最多允许20个字符!")
  87 + private String phone;
  88 +
  89 + /**
  90 + * 邮箱地址
  91 + */
  92 + @ApiModelProperty("邮箱地址")
  93 + @Length(message = "邮箱地址最多允许50个字符!")
  94 + private String email;
  95 +
  96 + /**
  97 + * 现住址
  98 + */
  99 + @ApiModelProperty("现住址")
  100 + @Length(message = "现住址最多允许100个字符!")
  101 + private String address;
  102 +
  103 + /**
  104 + * 前端自用id
  105 + */
  106 + @ApiModelProperty("前端自用id")
  107 + @Length(message = "前端自用id最多允许50个字符!")
  108 + private String personId;
  109 +
  110 +}
... ...
  1 +package com.lframework.xingyun.sc.vo.customer.credit;
  2 +
  3 +import java.math.BigDecimal;
  4 +import javax.validation.constraints.NotBlank;
  5 +import java.time.LocalDate;
  6 +import com.lframework.starter.web.core.vo.BaseVo;
  7 +import io.swagger.annotations.ApiModelProperty;
  8 +import com.lframework.starter.web.core.components.validation.TypeMismatch;
  9 +import org.hibernate.validator.constraints.Length;
  10 +import java.io.Serializable;
  11 +import lombok.Data;
  12 +
  13 +@Data
  14 +public class CreateCustomerCreditHistoryVo implements BaseVo, Serializable {
  15 +
  16 + private static final long serialVersionUID = 1L;
  17 +
  18 + /**
  19 + * 客户资信ID
  20 + */
  21 + @ApiModelProperty(value = "客户资信ID", required = true)
  22 + @NotBlank(message = "请输入客户资信ID!")
  23 + @Length(message = "客户资信ID最多允许32个字符!")
  24 + private String creditId;
  25 +
  26 + /**
  27 + * 第几次变更
  28 + */
  29 + @ApiModelProperty(value = "第几次变更", required = true)
  30 + @NotBlank(message = "请输入第几次变更!")
  31 + @Length(message = "第几次变更最多允许20个字符!")
  32 + private String sort;
  33 +
  34 + /**
  35 + * 编号
  36 + */
  37 + @ApiModelProperty(value = "编号", required = true)
  38 + @NotBlank(message = "请输入编号!")
  39 + @Length(message = "编号最多允许20个字符!")
  40 + private String serialNumber;
  41 +
  42 + /**
  43 + * 区域
  44 + */
  45 + @ApiModelProperty("区域")
  46 + @Length(message = "区域最多允许100个字符!")
  47 + private String region;
  48 +
  49 + /**
  50 + * 登记日期
  51 + */
  52 + @ApiModelProperty("登记日期")
  53 + @TypeMismatch(message = "登记日期格式有误!")
  54 + private LocalDate registerDate;
  55 +
  56 + /**
  57 + * 客户简称
  58 + */
  59 + @ApiModelProperty("客户简称")
  60 + @Length(message = "客户简称最多允许100个字符!")
  61 + private String customerShortName;
  62 +
  63 + /**
  64 + * 企业类型:经销商(distributor)、终端(terminal)
  65 + */
  66 + @ApiModelProperty("企业类型:经销商(distributor)、终端(terminal)")
  67 + @Length(message = "企业类型:经销商(distributor)、终端(terminal)最多允许100个字符!")
  68 + private String enterpriseType;
  69 +
  70 + /**
  71 + * 单位名称
  72 + */
  73 + @ApiModelProperty("单位名称")
  74 + @Length(message = "单位名称最多允许32个字符!")
  75 + private String companyId;
  76 +
  77 + /**
  78 + * 企业性质
  79 + */
  80 + @ApiModelProperty("企业性质")
  81 + @Length(message = "企业性质最多允许100个字符!")
  82 + private String companyNature;
  83 +
  84 + /**
  85 + * 单位地址
  86 + */
  87 + @ApiModelProperty("单位地址")
  88 + @Length(message = "单位地址最多允许100个字符!")
  89 + private String companyAddress;
  90 +
  91 + /**
  92 + * 注册资本(单位:万元)
  93 + */
  94 + @ApiModelProperty("注册资本(单位:万元)")
  95 + @TypeMismatch(message = "注册资本(单位:万元)格式有误!")
  96 + private BigDecimal registeredCapital;
  97 +
  98 + /**
  99 + * 账号
  100 + */
  101 + @ApiModelProperty("账号")
  102 + @Length(message = "账号最多允许50个字符!")
  103 + private String bankAccount;
  104 +
  105 + /**
  106 + * 开户行
  107 + */
  108 + @ApiModelProperty("开户行")
  109 + @Length(message = "开户行最多允许100个字符!")
  110 + private String bankName;
  111 +
  112 + /**
  113 + * 税号
  114 + */
  115 + @ApiModelProperty("税号")
  116 + @Length(message = "税号最多允许50个字符!")
  117 + private String taxNumber;
  118 +
  119 + /**
  120 + * 注册时间
  121 + */
  122 + @ApiModelProperty("注册时间")
  123 + @TypeMismatch(message = "注册时间格式有误!")
  124 + private LocalDate registrationTime;
  125 +
  126 + /**
  127 + * 经营年限(年)
  128 + */
  129 + @ApiModelProperty("经营年限(年)")
  130 + @Length(message = "经营年限(年)最多允许10个字符!")
  131 + private String businessYears;
  132 +
  133 + /**
  134 + * 经营范围
  135 + */
  136 + @ApiModelProperty("经营范围")
  137 + @Length(message = "经营范围最多允许65,535个字符!")
  138 + private String businessScope;
  139 +
  140 + /**
  141 + * 经营场地属性
  142 + */
  143 + @ApiModelProperty("经营场地属性")
  144 + @Length(message = "经营场地属性最多允许50个字符!")
  145 + private String businessProperty;
  146 +
  147 + /**
  148 + * 占地面积(平方米)
  149 + */
  150 + @ApiModelProperty("占地面积(平方米)")
  151 + @Length(message = "占地面积(平方米)最多允许200个字符!")
  152 + private String landArea;
  153 +
  154 + /**
  155 + * 仓储条件
  156 + */
  157 + @ApiModelProperty("仓储条件")
  158 + @Length(message = "仓储条件最多允许100个字符!")
  159 + private String storageConditions;
  160 +
  161 + /**
  162 + * 员工人数
  163 + */
  164 + @ApiModelProperty("员工人数")
  165 + @TypeMismatch(message = "员工人数格式有误!")
  166 + private Integer employeeCount;
  167 +
  168 + /**
  169 + * 设备属性
  170 + */
  171 + @ApiModelProperty("设备属性")
  172 + @Length(message = "设备属性最多允许100个字符!")
  173 + private String equipmentAttributes;
  174 +
  175 + /**
  176 + * 资产评估
  177 + */
  178 + @ApiModelProperty("资产评估")
  179 + @Length(message = "资产评估最多允许200个字符!")
  180 + private String assetEvaluation;
  181 +
  182 + /**
  183 + * 上年度销售额(万元)
  184 + */
  185 + @ApiModelProperty("上年度销售额(万元)")
  186 + @Length(message = "上年度销售额(万元)最多允许50个字符!")
  187 + private String lastYearSales;
  188 +
  189 + /**
  190 + * 月均销量(万元)
  191 + */
  192 + @ApiModelProperty("月均销量(万元)")
  193 + @Length(message = "月均销量(万元)最多允许50个字符!")
  194 + private String monthlyAvgSales;
  195 +
  196 + /**
  197 + * 销项发票所开品名与计量单位
  198 + */
  199 + @ApiModelProperty("销项发票所开品名与计量单位")
  200 + @Length(message = "销项发票所开品名与计量单位最多允许50个字符!")
  201 + private String invoiceItemUnit;
  202 +
  203 + /**
  204 + * 认证证书我司售于产品与经营范围是否匹配
  205 + */
  206 + @ApiModelProperty("认证证书我司售于产品与经营范围是否匹配")
  207 + @Length(message = "认证证书我司售于产品与经营范围是否匹配最多允许50个字符!")
  208 + private String productMatch;
  209 +
  210 + /**
  211 + * 主要客户
  212 + */
  213 + @ApiModelProperty("主要客户")
  214 + @Length(message = "主要客户最多允许200个字符!")
  215 + private String majorCustomers;
  216 +
  217 + /**
  218 + * 主营项目
  219 + */
  220 + @ApiModelProperty("主营项目")
  221 + @Length(message = "主营项目最多允许65,535个字符!")
  222 + private String mainProjects;
  223 +
  224 + /**
  225 + * 从事行业
  226 + */
  227 + @ApiModelProperty("从事行业")
  228 + @Length(message = "从事行业最多允许50个字符!")
  229 + private String industryInvolved;
  230 +
  231 + /**
  232 + * 在该行业中的经验
  233 + */
  234 + @ApiModelProperty("在该行业中的经验")
  235 + @Length(message = "在该行业中的经验最多允许200个字符!")
  236 + private String industryExperience;
  237 +
  238 + /**
  239 + * 是否与其他企业有经济纠纷 违规信息 拖欠员工薪资等
  240 + */
  241 + @ApiModelProperty("是否与其他企业有经济纠纷 违规信息 拖欠员工薪资等")
  242 + @Length(message = "是否与其他企业有经济纠纷 违规信息 拖欠员工薪资等最多允许200个字符!")
  243 + private String hasDispute;
  244 +
  245 + /**
  246 + * 与我司合作时间
  247 + */
  248 + @ApiModelProperty("与我司合作时间")
  249 + @Length(message = "与我司合作时间最多允许50个字符!")
  250 + private String cooperationStartDate;
  251 +
  252 + /**
  253 + * 月均操作量
  254 + */
  255 + @ApiModelProperty("月均操作量")
  256 + @Length(message = "月均操作量最多允许50个字符!")
  257 + private String monthlyAvgVolume;
  258 +
  259 + /**
  260 + * 是否口头协议操作
  261 + */
  262 + @ApiModelProperty("是否口头协议操作")
  263 + @Length(message = "是否口头协议操作最多允许100个字符!")
  264 + private String isVerbalAgreement;
  265 +
  266 + /**
  267 + * 是否签订其他协议(列举)
  268 + */
  269 + @ApiModelProperty("是否签订其他协议(列举)")
  270 + @Length(message = "是否签订其他协议(列举)最多允许65,535个字符!")
  271 + private String otherAgreements;
  272 +
  273 + /**
  274 + * 与我司操作是否签订长年合同
  275 + */
  276 + @ApiModelProperty("与我司操作是否签订长年合同")
  277 + @Length(message = "与我司操作是否签订长年合同最多允许100个字符!")
  278 + private String hasLongTermContract;
  279 +
  280 + /**
  281 + * 合同类型
  282 + */
  283 + @ApiModelProperty("合同类型")
  284 + @Length(message = "合同类型最多允许100个字符!")
  285 + private String contractType;
  286 +
  287 + /**
  288 + * 是否有过中断及中断原因
  289 + */
  290 + @ApiModelProperty("是否有过中断及中断原因")
  291 + @Length(message = "是否有过中断及中断原因最多允许65,535个字符!")
  292 + private String hasInterruption;
  293 +
  294 + /**
  295 + * 结算期限
  296 + */
  297 + @ApiModelProperty("结算期限")
  298 + @Length(message = "结算期限最多允许100个字符!")
  299 + private String settlementPeriod;
  300 +
  301 + /**
  302 + * 加工料提供时间
  303 + */
  304 + @ApiModelProperty("加工料提供时间")
  305 + @Length(message = "加工料提供时间最多允许100个字符!")
  306 + private String materialSupplyPlan;
  307 +
  308 + /**
  309 + * 建议客户分类:AAA、AA、A、BBB、BB、B、C、D
  310 + */
  311 + @ApiModelProperty("建议客户分类:AAA、AA、A、BBB、BB、B、C、D")
  312 + @Length(message = "建议客户分类:AAA、AA、A、BBB、BB、B、C、D最多允许50个字符!")
  313 + private String suggestedCategory;
  314 +
  315 + /**
  316 + * 授信额度(万元)
  317 + */
  318 + @ApiModelProperty("授信额度(万元)")
  319 + @Length(message = "授信额度(万元)最多允许20个字符!")
  320 + private String creditLimit;
  321 +
  322 + /**
  323 + * 调查人
  324 + */
  325 + @ApiModelProperty("调查人")
  326 + @Length(message = "调查人最多允许50个字符!")
  327 + private String investigator;
  328 +
  329 + /**
  330 + * 主管审核
  331 + */
  332 + @ApiModelProperty("主管审核")
  333 + @Length(message = "主管审核最多允许50个字符!")
  334 + private String supervisorReview;
  335 +
  336 + /**
  337 + * 年度总销量(万元)
  338 + */
  339 + @ApiModelProperty("年度总销量(万元)")
  340 + @Length(message = "年度总销量(万元)最多允许20个字符!")
  341 + private String annualTotalSales;
  342 +
  343 + /**
  344 + * 主要行业
  345 + */
  346 + @ApiModelProperty("主要行业")
  347 + @Length(message = "主要行业最多允许100个字符!")
  348 + private String mainIndustry;
  349 +
  350 + /**
  351 + * 年度款料概况
  352 + */
  353 + @ApiModelProperty("年度款料概况")
  354 + @Length(message = "年度款料概况最多允许65,535个字符!")
  355 + private String annualMaterialOverview;
  356 +
  357 + /**
  358 + * 结算期限
  359 + */
  360 + @ApiModelProperty("结算期限")
  361 + @Length(message = "结算期限最多允许100个字符!")
  362 + private String companySettlementPeriod;
  363 +
  364 + /**
  365 + * 授信额度(万元)
  366 + */
  367 + @ApiModelProperty("授信额度(万元)")
  368 + @Length(message = "授信额度(万元)最多允许20个字符!")
  369 + private String companyCreditLimit;
  370 +
  371 + /**
  372 + * 加工料提供时间
  373 + */
  374 + @ApiModelProperty("加工料提供时间")
  375 + @Length(message = "加工料提供时间最多允许100个字符!")
  376 + private String companyMaterialSupplyPlan;
  377 +
  378 + /**
  379 + * 建议客户分类:AAA、AA、A、BBB、BB、B、C、D
  380 + */
  381 + @ApiModelProperty("建议客户分类:AAA、AA、A、BBB、BB、B、C、D")
  382 + @Length(message = "建议客户分类:AAA、AA、A、BBB、BB、B、C、D最多允许50个字符!")
  383 + private String companySuggestedCategory;
  384 +
  385 + /**
  386 + * 审核状态
  387 + */
  388 + @ApiModelProperty("审核状态")
  389 + @Length(message = "审核状态最多允许20个字符!")
  390 + private String status;
  391 +
  392 + /**
  393 + * 认证证书
  394 + */
  395 + @ApiModelProperty("认证证书")
  396 + @Length(message = "认证证书最多允许100个字符!")
  397 + private String certificationCertificate;
  398 +
  399 +}
... ...
  1 +package com.lframework.xingyun.sc.vo.customer.credit;
  2 +
  3 +import lombok.Data;
  4 +import com.lframework.starter.web.core.vo.PageVo;
  5 +import com.lframework.starter.web.core.vo.BaseVo;
  6 +import io.swagger.annotations.ApiModelProperty;
  7 +import java.io.Serializable;
  8 +
  9 +@Data
  10 +public class QueryCorePersonnelHistoryVo extends PageVo implements BaseVo, Serializable {
  11 +
  12 + private static final long serialVersionUID = 1L;
  13 +
  14 + /**
  15 + * 核心人员ID
  16 + */
  17 + @ApiModelProperty("核心人员ID")
  18 + private String personnelId;
  19 +
  20 + /**
  21 + * 第几次变更
  22 + */
  23 + @ApiModelProperty("第几次变更")
  24 + private String sort;
  25 +
  26 + /**
  27 + * 客户资信
  28 + */
  29 + @ApiModelProperty("客户资信")
  30 + private String creditId;
  31 +
  32 +}
... ...
  1 +package com.lframework.xingyun.sc.vo.customer.credit;
  2 +
  3 +import lombok.Data;
  4 +import com.lframework.starter.web.core.vo.PageVo;
  5 +import com.lframework.starter.web.core.vo.BaseVo;
  6 +import io.swagger.annotations.ApiModelProperty;
  7 +import java.io.Serializable;
  8 +
  9 +@Data
  10 +public class QueryCustomerCreditHistoryVo extends PageVo implements BaseVo, Serializable {
  11 +
  12 + private static final long serialVersionUID = 1L;
  13 +
  14 + /**
  15 + * 客户资信ID
  16 + */
  17 + @ApiModelProperty("客户资信ID")
  18 + private String creditId;
  19 +
  20 + /**
  21 + * 第几次变更
  22 + */
  23 + @ApiModelProperty("第几次变更")
  24 + private String sort;
  25 +
  26 + /**
  27 + * 编号
  28 + */
  29 + @ApiModelProperty("编号")
  30 + private String serialNumber;
  31 +
  32 +}
... ...
  1 +<?xml version="1.0" encoding="UTF-8"?>
  2 +<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
  3 +<mapper namespace="com.lframework.xingyun.sc.mappers.CorePersonnelHistoryMapper">
  4 +
  5 + <resultMap id="CorePersonnelHistory" type="com.lframework.xingyun.sc.entity.CorePersonnelHistory">
  6 + <id column="id" property="id"/>
  7 + <result column="personnel_id" property="personnelId"/>
  8 + <result column="sort" property="sort"/>
  9 + <result column="credit_id" property="creditId"/>
  10 + <result column="name" property="name"/>
  11 + <result column="sex" property="sex"/>
  12 + <result column="native_place" property="nativePlace"/>
  13 + <result column="age" property="age"/>
  14 + <result column="position" property="position"/>
  15 + <result column="mobile" property="mobile"/>
  16 + <result column="phone" property="phone"/>
  17 + <result column="email" property="email"/>
  18 + <result column="address" property="address"/>
  19 + <result column="create_by_id" property="createById"/>
  20 + <result column="create_by" property="createBy"/>
  21 + <result column="update_by_id" property="updateById"/>
  22 + <result column="update_by" property="updateBy"/>
  23 + <result column="create_time" property="createTime"/>
  24 + <result column="update_time" property="updateTime"/>
  25 + <result column="person_id" property="personId"/>
  26 + </resultMap>
  27 +
  28 + <sql id="CorePersonnelHistory_sql">
  29 + SELECT
  30 + tb.id,
  31 + tb.personnel_id,
  32 + tb.sort,
  33 + tb.credit_id,
  34 + tb.name,
  35 + tb.sex,
  36 + tb.native_place,
  37 + tb.age,
  38 + tb.position,
  39 + tb.mobile,
  40 + tb.phone,
  41 + tb.email,
  42 + tb.address,
  43 + tb.create_by_id,
  44 + tb.create_by,
  45 + tb.update_by_id,
  46 + tb.update_by,
  47 + tb.create_time,
  48 + tb.update_time,
  49 + tb.person_id
  50 + FROM core_personnel_history AS tb
  51 + </sql>
  52 +
  53 + <select id="query" resultMap="CorePersonnelHistory">
  54 + <include refid="CorePersonnelHistory_sql"/>
  55 + <where>
  56 + <if test="vo.personnelId != null and vo.personnelId != ''">
  57 + AND tb.personnel_id = #{vo.personnelId}
  58 + </if>
  59 + <if test="vo.sort != null and vo.sort != ''">
  60 + AND tb.sort = #{vo.sort}
  61 + </if>
  62 + <if test="vo.creditId != null and vo.creditId != ''">
  63 + AND tb.credit_id = #{vo.creditId}
  64 + </if>
  65 + </where>
  66 + </select>
  67 +</mapper>
... ...
  1 +<?xml version="1.0" encoding="UTF-8"?>
  2 +<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
  3 +<mapper namespace="com.lframework.xingyun.sc.mappers.CustomerCreditHistoryMapper">
  4 +
  5 + <resultMap id="CustomerCreditHistory" type="com.lframework.xingyun.sc.entity.CustomerCreditHistory">
  6 + <id column="id" property="id"/>
  7 + <result column="credit_id" property="creditId"/>
  8 + <result column="sort" property="sort"/>
  9 + <result column="serial_number" property="serialNumber"/>
  10 + <result column="region" property="region"/>
  11 + <result column="register_date" property="registerDate"/>
  12 + <result column="customer_short_name" property="customerShortName"/>
  13 + <result column="enterprise_type" property="enterpriseType"/>
  14 + <result column="company_id" property="companyId"/>
  15 + <result column="company_nature" property="companyNature"/>
  16 + <result column="company_address" property="companyAddress"/>
  17 + <result column="registered_capital" property="registeredCapital"/>
  18 + <result column="bank_account" property="bankAccount"/>
  19 + <result column="bank_name" property="bankName"/>
  20 + <result column="tax_number" property="taxNumber"/>
  21 + <result column="registration_time" property="registrationTime"/>
  22 + <result column="business_years" property="businessYears"/>
  23 + <result column="business_scope" property="businessScope"/>
  24 + <result column="business_property" property="businessProperty"/>
  25 + <result column="land_area" property="landArea"/>
  26 + <result column="storage_conditions" property="storageConditions"/>
  27 + <result column="employee_count" property="employeeCount"/>
  28 + <result column="equipment_attributes" property="equipmentAttributes"/>
  29 + <result column="asset_evaluation" property="assetEvaluation"/>
  30 + <result column="last_year_sales" property="lastYearSales"/>
  31 + <result column="monthly_avg_sales" property="monthlyAvgSales"/>
  32 + <result column="invoice_item_unit" property="invoiceItemUnit"/>
  33 + <result column="product_match" property="productMatch"/>
  34 + <result column="major_customers" property="majorCustomers"/>
  35 + <result column="main_projects" property="mainProjects"/>
  36 + <result column="industry_involved" property="industryInvolved"/>
  37 + <result column="industry_experience" property="industryExperience"/>
  38 + <result column="has_dispute" property="hasDispute"/>
  39 + <result column="cooperation_start_date" property="cooperationStartDate"/>
  40 + <result column="monthly_avg_volume" property="monthlyAvgVolume"/>
  41 + <result column="is_verbal_agreement" property="isVerbalAgreement"/>
  42 + <result column="other_agreements" property="otherAgreements"/>
  43 + <result column="has_long_term_contract" property="hasLongTermContract"/>
  44 + <result column="contract_type" property="contractType"/>
  45 + <result column="has_interruption" property="hasInterruption"/>
  46 + <result column="settlement_period" property="settlementPeriod"/>
  47 + <result column="material_supply_plan" property="materialSupplyPlan"/>
  48 + <result column="suggested_category" property="suggestedCategory"/>
  49 + <result column="credit_limit" property="creditLimit"/>
  50 + <result column="investigator" property="investigator"/>
  51 + <result column="supervisor_review" property="supervisorReview"/>
  52 + <result column="annual_total_sales" property="annualTotalSales"/>
  53 + <result column="main_industry" property="mainIndustry"/>
  54 + <result column="annual_material_overview" property="annualMaterialOverview"/>
  55 + <result column="company_settlement_period" property="companySettlementPeriod"/>
  56 + <result column="company_credit_limit" property="companyCreditLimit"/>
  57 + <result column="company_material_supply_plan" property="companyMaterialSupplyPlan"/>
  58 + <result column="company_suggested_category" property="companySuggestedCategory"/>
  59 + <result column="create_by_id" property="createById"/>
  60 + <result column="create_by" property="createBy"/>
  61 + <result column="update_by_id" property="updateById"/>
  62 + <result column="update_by" property="updateBy"/>
  63 + <result column="create_time" property="createTime"/>
  64 + <result column="update_time" property="updateTime"/>
  65 + <result column="status" property="status"/>
  66 + <result column="certification_certificate" property="certificationCertificate"/>
  67 + </resultMap>
  68 +
  69 + <sql id="CustomerCreditHistory_sql">
  70 + SELECT
  71 + tb.id,
  72 + tb.credit_id,
  73 + tb.sort,
  74 + tb.serial_number,
  75 + tb.region,
  76 + tb.register_date,
  77 + tb.customer_short_name,
  78 + tb.enterprise_type,
  79 + tb.company_id,
  80 + tb.company_nature,
  81 + tb.company_address,
  82 + tb.registered_capital,
  83 + tb.bank_account,
  84 + tb.bank_name,
  85 + tb.tax_number,
  86 + tb.registration_time,
  87 + tb.business_years,
  88 + tb.business_scope,
  89 + tb.business_property,
  90 + tb.land_area,
  91 + tb.storage_conditions,
  92 + tb.employee_count,
  93 + tb.equipment_attributes,
  94 + tb.asset_evaluation,
  95 + tb.last_year_sales,
  96 + tb.monthly_avg_sales,
  97 + tb.invoice_item_unit,
  98 + tb.product_match,
  99 + tb.major_customers,
  100 + tb.main_projects,
  101 + tb.industry_involved,
  102 + tb.industry_experience,
  103 + tb.has_dispute,
  104 + tb.cooperation_start_date,
  105 + tb.monthly_avg_volume,
  106 + tb.is_verbal_agreement,
  107 + tb.other_agreements,
  108 + tb.has_long_term_contract,
  109 + tb.contract_type,
  110 + tb.has_interruption,
  111 + tb.settlement_period,
  112 + tb.material_supply_plan,
  113 + tb.suggested_category,
  114 + tb.credit_limit,
  115 + tb.investigator,
  116 + tb.supervisor_review,
  117 + tb.annual_total_sales,
  118 + tb.main_industry,
  119 + tb.annual_material_overview,
  120 + tb.company_settlement_period,
  121 + tb.company_credit_limit,
  122 + tb.company_material_supply_plan,
  123 + tb.company_suggested_category,
  124 + tb.create_by_id,
  125 + tb.create_by,
  126 + tb.update_by_id,
  127 + tb.update_by,
  128 + tb.create_time,
  129 + tb.update_time,
  130 + tb.status,
  131 + tb.certification_certificate
  132 + FROM customer_credit_history AS tb
  133 + </sql>
  134 +
  135 + <select id="query" resultMap="CustomerCreditHistory">
  136 + <include refid="CustomerCreditHistory_sql"/>
  137 + <where>
  138 + <if test="vo.creditId != null and vo.creditId != ''">
  139 + AND tb.credit_id = #{vo.creditId}
  140 + </if>
  141 + <if test="vo.sort != null and vo.sort != ''">
  142 + AND tb.sort = #{vo.sort}
  143 + </if>
  144 + <if test="vo.serialNumber != null and vo.serialNumber != ''">
  145 + AND tb.serial_number = #{vo.serialNumber}
  146 + </if>
  147 + </where>
  148 + </select>
  149 +</mapper>
... ...