浏览代码

20230217 11:57

wangzhuo 2 年之前
父节点
当前提交
e058af8323
共有 22 个文件被更改,包括 1673 次插入10 次删除
  1. 6 0
      blade-service-api/blade-client-api/src/main/java/org/springblade/client/entity/LandVehicle.java
  2. 2 0
      blade-service-api/blade-land-api/src/main/java/org/springblade/land/constant/LandConst.java
  3. 34 0
      blade-service-api/blade-land-api/src/main/java/org/springblade/land/insurance/dto/InsuranceDTO.java
  4. 34 0
      blade-service-api/blade-land-api/src/main/java/org/springblade/land/insurance/dto/InsuranceFilesDTO.java
  5. 310 0
      blade-service-api/blade-land-api/src/main/java/org/springblade/land/insurance/entity/Insurance.java
  6. 128 0
      blade-service-api/blade-land-api/src/main/java/org/springblade/land/insurance/entity/InsuranceFiles.java
  7. 36 0
      blade-service-api/blade-land-api/src/main/java/org/springblade/land/insurance/vo/InsuranceFilesVO.java
  8. 36 0
      blade-service-api/blade-land-api/src/main/java/org/springblade/land/insurance/vo/InsuranceVO.java
  9. 18 3
      blade-service/blade-client/src/main/java/org/springblade/client/corps/controller/CorpsDescController.java
  10. 11 6
      blade-service/blade-client/src/main/java/org/springblade/client/land/excel/VehicleExcel.java
  11. 21 0
      blade-service/blade-client/src/main/java/org/springblade/client/land/service/impl/LandVehicleServiceImpl.java
  12. 134 0
      blade-service/blade-land/src/main/java/org/springblade/land/insurance/controller/InsuranceController.java
  13. 126 0
      blade-service/blade-land/src/main/java/org/springblade/land/insurance/controller/InsuranceFilesController.java
  14. 42 0
      blade-service/blade-land/src/main/java/org/springblade/land/insurance/mapper/InsuranceFilesMapper.java
  15. 29 0
      blade-service/blade-land/src/main/java/org/springblade/land/insurance/mapper/InsuranceFilesMapper.xml
  16. 42 0
      blade-service/blade-land/src/main/java/org/springblade/land/insurance/mapper/InsuranceMapper.java
  17. 57 0
      blade-service/blade-land/src/main/java/org/springblade/land/insurance/mapper/InsuranceMapper.xml
  18. 41 0
      blade-service/blade-land/src/main/java/org/springblade/land/insurance/service/IInsuranceFilesService.java
  19. 77 0
      blade-service/blade-land/src/main/java/org/springblade/land/insurance/service/IInsuranceService.java
  20. 41 0
      blade-service/blade-land/src/main/java/org/springblade/land/insurance/service/impl/InsuranceFilesServiceImpl.java
  21. 446 0
      blade-service/blade-land/src/main/java/org/springblade/land/insurance/service/impl/InsuranceServiceImpl.java
  22. 2 1
      blade-service/blade-land/src/main/java/org/springblade/land/service/impl/OrderServiceImpl.java

+ 6 - 0
blade-service-api/blade-client-api/src/main/java/org/springblade/client/entity/LandVehicle.java

@@ -234,6 +234,12 @@ public class LandVehicle implements Serializable {
 	@ApiModelProperty(value = "gpsId")
 	private String gpsId;
 
+	/**
+	 * 过户日期
+	 */
+	@ApiModelProperty(value = "过户日期")
+	private Date transferDate;
+
 	@TableField(exist = false)
 	private List<CommonFile> fileList;
 

+ 2 - 0
blade-service-api/blade-land-api/src/main/java/org/springblade/land/constant/LandConst.java

@@ -55,6 +55,8 @@ public interface LandConst {
 
 	String ROLE_ZDD = "总调度";
 
+	String ROLE_BXGS = "保险公司";
+
 	/**
 	 * 权限标识
 	 */

+ 34 - 0
blade-service-api/blade-land-api/src/main/java/org/springblade/land/insurance/dto/InsuranceDTO.java

@@ -0,0 +1,34 @@
+/*
+ *      Copyright (c) 2018-2028, Chill Zhuang All rights reserved.
+ *
+ *  Redistribution and use in source and binary forms, with or without
+ *  modification, are permitted provided that the following conditions are met:
+ *
+ *  Redistributions of source code must retain the above copyright notice,
+ *  this list of conditions and the following disclaimer.
+ *  Redistributions in binary form must reproduce the above copyright
+ *  notice, this list of conditions and the following disclaimer in the
+ *  documentation and/or other materials provided with the distribution.
+ *  Neither the name of the dreamlu.net developer nor the names of its
+ *  contributors may be used to endorse or promote products derived from
+ *  this software without specific prior written permission.
+ *  Author: Chill 庄骞 (smallchill@163.com)
+ */
+package org.springblade.land.insurance.dto;
+
+import org.springblade.land.insurance.entity.Insurance;
+import lombok.Data;
+import lombok.EqualsAndHashCode;
+
+/**
+ * 陆运保险主表数据传输对象实体类
+ *
+ * @author BladeX
+ * @since 2023-02-15
+ */
+@Data
+@EqualsAndHashCode(callSuper = true)
+public class InsuranceDTO extends Insurance {
+	private static final long serialVersionUID = 1L;
+
+}

+ 34 - 0
blade-service-api/blade-land-api/src/main/java/org/springblade/land/insurance/dto/InsuranceFilesDTO.java

@@ -0,0 +1,34 @@
+/*
+ *      Copyright (c) 2018-2028, Chill Zhuang All rights reserved.
+ *
+ *  Redistribution and use in source and binary forms, with or without
+ *  modification, are permitted provided that the following conditions are met:
+ *
+ *  Redistributions of source code must retain the above copyright notice,
+ *  this list of conditions and the following disclaimer.
+ *  Redistributions in binary form must reproduce the above copyright
+ *  notice, this list of conditions and the following disclaimer in the
+ *  documentation and/or other materials provided with the distribution.
+ *  Neither the name of the dreamlu.net developer nor the names of its
+ *  contributors may be used to endorse or promote products derived from
+ *  this software without specific prior written permission.
+ *  Author: Chill 庄骞 (smallchill@163.com)
+ */
+package org.springblade.land.insurance.dto;
+
+import org.springblade.land.insurance.entity.InsuranceFiles;
+import lombok.Data;
+import lombok.EqualsAndHashCode;
+
+/**
+ * 数据传输对象实体类
+ *
+ * @author BladeX
+ * @since 2023-02-15
+ */
+@Data
+@EqualsAndHashCode(callSuper = true)
+public class InsuranceFilesDTO extends InsuranceFiles {
+	private static final long serialVersionUID = 1L;
+
+}

+ 310 - 0
blade-service-api/blade-land-api/src/main/java/org/springblade/land/insurance/entity/Insurance.java

@@ -0,0 +1,310 @@
+/*
+ *      Copyright (c) 2018-2028, Chill Zhuang All rights reserved.
+ *
+ *  Redistribution and use in source and binary forms, with or without
+ *  modification, are permitted provided that the following conditions are met:
+ *
+ *  Redistributions of source code must retain the above copyright notice,
+ *  this list of conditions and the following disclaimer.
+ *  Redistributions in binary form must reproduce the above copyright
+ *  notice, this list of conditions and the following disclaimer in the
+ *  documentation and/or other materials provided with the distribution.
+ *  Neither the name of the dreamlu.net developer nor the names of its
+ *  contributors may be used to endorse or promote products derived from
+ *  this software without specific prior written permission.
+ *  Author: Chill 庄骞 (smallchill@163.com)
+ */
+package org.springblade.land.insurance.entity;
+
+import java.math.BigDecimal;
+
+import com.baomidou.mybatisplus.annotation.FieldStrategy;
+import com.baomidou.mybatisplus.annotation.TableField;
+import com.baomidou.mybatisplus.annotation.TableName;
+import java.io.Serializable;
+import java.util.Date;
+import java.util.List;
+
+import com.fasterxml.jackson.annotation.JsonFormat;
+import lombok.Data;
+import io.swagger.annotations.ApiModel;
+import io.swagger.annotations.ApiModelProperty;
+import org.springframework.format.annotation.DateTimeFormat;
+
+/**
+ * 陆运保险主表实体类
+ *
+ * @author BladeX
+ * @since 2023-02-15
+ */
+@Data
+@TableName("land_insurance")
+@ApiModel(value = "Insurance对象", description = "陆运保险主表")
+public class Insurance implements Serializable {
+
+	private static final long serialVersionUID = 1L;
+
+	/**
+	* 主键
+	*/
+		@ApiModelProperty(value = "主键")
+		private Long id;
+	/**
+	* 系统编号
+	*/
+		@ApiModelProperty(value = "系统编号")
+		private String sysNo;
+	/**
+	* 创建人
+	*/
+		@ApiModelProperty(value = "创建人")
+		private Long createUser;
+	/**
+	* 创建部门
+	*/
+		@ApiModelProperty(value = "创建部门")
+		private Long createDept;
+	/**
+	* 创建时间
+	*/
+		@ApiModelProperty(value = "创建时间")
+		@TableField(updateStrategy = FieldStrategy.IGNORED)
+		private Date createTime;
+	/**
+	* 修改人
+	*/
+		@ApiModelProperty(value = "修改人")
+		private Long updateUser;
+	/**
+	* 修改时间
+	*/
+		@ApiModelProperty(value = "修改时间")
+		@TableField(updateStrategy = FieldStrategy.IGNORED)
+		private Date updateTime;
+	/**
+	* 0录入(未获取),1 获取报价(未确认),2平台确认(已确认),3保费提交(未受理),4保费受理(已受理),5投保确认(未签单),
+	 * 6签单完成(已完成),7弃保(只能删除)
+	*/
+		@ApiModelProperty(value = "状态")
+		private Integer status;
+	/**
+	* 是否已删除(0 否 1是)
+	*/
+		@ApiModelProperty(value = "是否已删除(0 否 1是)")
+		private Integer isDeleted;
+
+	/**
+	 * 租户
+	 */
+	@ApiModelProperty(value = "租户")
+	private String tenantId;
+
+	/**
+	* 备注
+	*/
+		@ApiModelProperty(value = "备注")
+		private String remark;
+	/**
+	* 保险公司id
+	*/
+		@ApiModelProperty(value = "保险公司id")
+		private Long insuranceCompanyId;
+	/**
+	* 保险公司名称
+	*/
+		@ApiModelProperty(value = "保险公司名称")
+		private String insuranceCompanyName;
+	/**
+	* 车队id
+	*/
+		@ApiModelProperty(value = "车队id")
+		private Long fleetId;
+	/**
+	* 车队名称
+	*/
+		@ApiModelProperty(value = "车队名称")
+		private String fleetName;
+	/**
+	* 投保人id
+	*/
+		@ApiModelProperty(value = "投保人id")
+		private Long policyHolderId;
+	/**
+	* 投保人名称
+	*/
+		@ApiModelProperty(value = "投保人名称")
+		private String policyHolderName;
+	/**
+	* 被保险人id
+	*/
+		@ApiModelProperty(value = "被保险人id")
+		private Long insuredId;
+	/**
+	* 被保险人名称
+	*/
+		@ApiModelProperty(value = "被保险人名称")
+		private String insuredName;
+	/**
+	* 联系电话
+	*/
+		@ApiModelProperty(value = "联系电话")
+		private String contactNumber;
+	/**
+	* 车牌号id
+	*/
+		@ApiModelProperty(value = "车牌号id")
+		private Long carNumberId;
+	/**
+	* 车牌号名称
+	*/
+		@ApiModelProperty(value = "车牌号名称")
+		private String carNumberName;
+	/**
+	* 车辆型号
+	*/
+		@ApiModelProperty(value = "车辆型号")
+		private String towModel;
+	/**
+	* 注册日期
+	*/
+		@ApiModelProperty(value = "注册日期")
+		@JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd")
+		@DateTimeFormat(pattern = "yyyy-MM-dd")
+		@TableField(updateStrategy = FieldStrategy.IGNORED)
+		private Date registerDate;
+	/**
+	* 发动机型号
+	*/
+		@ApiModelProperty(value = "发动机型号")
+		private String engineModel;
+	/**
+	* 牵引车车架号
+	*/
+		@ApiModelProperty(value = "牵引车车架号")
+		private String towVin;
+	/**
+	* 过户日期
+	*/
+		@ApiModelProperty(value = "过户日期")
+		@JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd")
+		@DateTimeFormat(pattern = "yyyy-MM-dd")
+		@TableField(updateStrategy = FieldStrategy.IGNORED)
+		private Date transferDate;
+	/**
+	* 核定重量(kg)
+	*/
+		@ApiModelProperty(value = "核定重量(kg)")
+		private BigDecimal approvedWeight;
+	/**
+	* 装备重量(kg)
+	*/
+		@ApiModelProperty(value = "装备重量(kg)")
+		private BigDecimal equipmentWeight;
+	/**
+	* 机动车损失保险保额
+	*/
+		@ApiModelProperty(value = "机动车损失保险保额")
+		private String lossInsurance;
+	/**
+
+	/**
+	* 第三者责任保险保额
+	*/
+		@ApiModelProperty(value = "第三者责任保险保额")
+		private String liabilityInsurance;
+	/**
+
+	/**
+	* 车上人员责任险(司机)保额
+	*/
+		@ApiModelProperty(value = "车上人员责任险(司机)保额")
+		private String driverLiabilityInsurance;
+
+	/**
+	* 车上人员责任险(乘客)保额
+	*/
+		@ApiModelProperty(value = "车上人员责任险(乘客)保额")
+		private String passengerLiabilityInsurance;
+	/**
+
+	/**
+	* 交事故强制责任保险保额
+	*/
+		@ApiModelProperty(value = "交事故强制责任保险保额")
+		private String forceLiabilityInsurance;
+	/**
+
+	/**
+	* 车船税保额
+	*/
+		@ApiModelProperty(value = "车船税保额")
+		private String vehicleVesselTax;
+	/**
+
+	/**
+	* 实际保费1
+	*/
+		@ApiModelProperty(value = "实际保费1")
+		private BigDecimal actualPremiumOne;
+	/**
+	 * 实际保费2
+	 */
+		@ApiModelProperty(value = "实际保费2")
+		private BigDecimal actualPremiumTwo;
+
+	/**
+	 * 实际保费3
+	 */
+		@ApiModelProperty(value = "实际保费3")
+		private BigDecimal actualPremiumThree;
+
+	/**
+	* 订单状态名称
+	*/
+		@ApiModelProperty(value = "订单状态名称")
+		private String statusName;
+
+	/**
+	 * 业务日期
+	 */
+		@ApiModelProperty(value = "业务日期")
+		@JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd")
+		@DateTimeFormat(pattern = "yyyy-MM-dd")
+		@TableField(updateStrategy = FieldStrategy.IGNORED)
+		private Date businessDate;
+
+	/**
+	 * 显示附件(1,2,3)
+	 */
+		@ApiModelProperty(value = "显示附件(1,2,3)")
+		private Integer display;
+
+	/**
+	 * 车队附件集合
+	 */
+	@TableField(exist = false)
+	private List<InsuranceFiles> fleetList;
+
+	/**
+	 * 保费附件集合1
+	 */
+	@TableField(exist = false)
+	private List<InsuranceFiles> filesOneList;
+
+	/**
+	 * 保费附件集合2
+	 */
+	@TableField(exist = false)
+	private List<InsuranceFiles> filesTwoList;
+
+	/**
+	 * 保费附件集合3
+	 */
+	@TableField(exist = false)
+	private List<InsuranceFiles> filesThreeList;
+
+	//请核标识  1通过 2驳回 3弃保
+	@TableField(exist = false)
+	private Integer checkFlag;
+
+}

+ 128 - 0
blade-service-api/blade-land-api/src/main/java/org/springblade/land/insurance/entity/InsuranceFiles.java

@@ -0,0 +1,128 @@
+/*
+ *      Copyright (c) 2018-2028, Chill Zhuang All rights reserved.
+ *
+ *  Redistribution and use in source and binary forms, with or without
+ *  modification, are permitted provided that the following conditions are met:
+ *
+ *  Redistributions of source code must retain the above copyright notice,
+ *  this list of conditions and the following disclaimer.
+ *  Redistributions in binary form must reproduce the above copyright
+ *  notice, this list of conditions and the following disclaimer in the
+ *  documentation and/or other materials provided with the distribution.
+ *  Neither the name of the dreamlu.net developer nor the names of its
+ *  contributors may be used to endorse or promote products derived from
+ *  this software without specific prior written permission.
+ *  Author: Chill 庄骞 (smallchill@163.com)
+ */
+package org.springblade.land.insurance.entity;
+
+import com.baomidou.mybatisplus.annotation.TableName;
+import java.time.LocalDateTime;
+import java.io.Serializable;
+import java.util.Date;
+
+import lombok.Data;
+import lombok.EqualsAndHashCode;
+import io.swagger.annotations.ApiModel;
+import io.swagger.annotations.ApiModelProperty;
+
+/**
+ * 实体类
+ *
+ * @author BladeX
+ * @since 2023-02-15
+ */
+@Data
+@TableName("land_insurance_files")
+@ApiModel(value = "InsuranceFiles对象", description = "InsuranceFiles对象")
+public class InsuranceFiles implements Serializable {
+
+	private static final long serialVersionUID = 1L;
+
+	/**
+	* 主键
+	*/
+		@ApiModelProperty(value = "主键")
+		private Long id;
+	/**
+	* 主表id
+	*/
+		@ApiModelProperty(value = "主表id")
+		private Long pid;
+	/**
+	* 排序
+	*/
+		@ApiModelProperty(value = "排序")
+		private Integer sort;
+	/**
+	* 文件名
+	*/
+		@ApiModelProperty(value = "文件名")
+		private String fileName;
+	/**
+	* 文件地址
+	*/
+		@ApiModelProperty(value = "文件地址")
+		private String url;
+	/**
+	* 备注
+	*/
+		@ApiModelProperty(value = "备注")
+		private String remark;
+	/**
+	* 版本
+	*/
+		@ApiModelProperty(value = "版本")
+		private String version;
+	/**
+	 * 租户
+	 */
+		@ApiModelProperty(value = "租户")
+		private String tenantId;
+	/**
+	* 创建人
+	*/
+		@ApiModelProperty(value = "创建人")
+		private Long createUser;
+	/**
+	* 创建部门
+	*/
+		@ApiModelProperty(value = "创建部门")
+		private Long createDept;
+	/**
+	* 创建时间
+	*/
+		@ApiModelProperty(value = "创建时间")
+		private Date createTime;
+	/**
+	* 修改人
+	*/
+		@ApiModelProperty(value = "修改人")
+		private Long updateUser;
+	/**
+	* 修改时间
+	*/
+		@ApiModelProperty(value = "修改时间")
+		private Date updateTime;
+	/**
+	* 状态(0 正常 1停用)
+	*/
+		@ApiModelProperty(value = "状态(0 正常 1停用)")
+		private Integer filesStatus;
+	/**
+	* 是否已删除(0 否 1是)
+	*/
+		@ApiModelProperty(value = "是否已删除(0 否 1是)")
+		private Integer isDeleted;
+	/**
+	* 分类(1 主表  2 明细)
+	*/
+		@ApiModelProperty(value = "分类(1 主表  2 明细)")
+		private String filesType;
+	/**
+	 * 附件提示
+	 */
+		@ApiModelProperty(value = "附件提示")
+		private String message;
+
+}

+ 36 - 0
blade-service-api/blade-land-api/src/main/java/org/springblade/land/insurance/vo/InsuranceFilesVO.java

@@ -0,0 +1,36 @@
+/*
+ *      Copyright (c) 2018-2028, Chill Zhuang All rights reserved.
+ *
+ *  Redistribution and use in source and binary forms, with or without
+ *  modification, are permitted provided that the following conditions are met:
+ *
+ *  Redistributions of source code must retain the above copyright notice,
+ *  this list of conditions and the following disclaimer.
+ *  Redistributions in binary form must reproduce the above copyright
+ *  notice, this list of conditions and the following disclaimer in the
+ *  documentation and/or other materials provided with the distribution.
+ *  Neither the name of the dreamlu.net developer nor the names of its
+ *  contributors may be used to endorse or promote products derived from
+ *  this software without specific prior written permission.
+ *  Author: Chill 庄骞 (smallchill@163.com)
+ */
+package org.springblade.land.insurance.vo;
+
+import org.springblade.land.insurance.entity.InsuranceFiles;
+import lombok.Data;
+import lombok.EqualsAndHashCode;
+import io.swagger.annotations.ApiModel;
+
+/**
+ * 视图实体类
+ *
+ * @author BladeX
+ * @since 2023-02-15
+ */
+@Data
+@EqualsAndHashCode(callSuper = true)
+@ApiModel(value = "InsuranceFilesVO对象", description = "InsuranceFilesVO对象")
+public class InsuranceFilesVO extends InsuranceFiles {
+	private static final long serialVersionUID = 1L;
+
+}

+ 36 - 0
blade-service-api/blade-land-api/src/main/java/org/springblade/land/insurance/vo/InsuranceVO.java

@@ -0,0 +1,36 @@
+/*
+ *      Copyright (c) 2018-2028, Chill Zhuang All rights reserved.
+ *
+ *  Redistribution and use in source and binary forms, with or without
+ *  modification, are permitted provided that the following conditions are met:
+ *
+ *  Redistributions of source code must retain the above copyright notice,
+ *  this list of conditions and the following disclaimer.
+ *  Redistributions in binary form must reproduce the above copyright
+ *  notice, this list of conditions and the following disclaimer in the
+ *  documentation and/or other materials provided with the distribution.
+ *  Neither the name of the dreamlu.net developer nor the names of its
+ *  contributors may be used to endorse or promote products derived from
+ *  this software without specific prior written permission.
+ *  Author: Chill 庄骞 (smallchill@163.com)
+ */
+package org.springblade.land.insurance.vo;
+
+import org.springblade.land.insurance.entity.Insurance;
+import lombok.Data;
+import lombok.EqualsAndHashCode;
+import io.swagger.annotations.ApiModel;
+
+/**
+ * 陆运保险主表视图实体类
+ *
+ * @author BladeX
+ * @since 2023-02-15
+ */
+@Data
+@EqualsAndHashCode(callSuper = true)
+@ApiModel(value = "InsuranceVO对象", description = "陆运保险主表")
+public class InsuranceVO extends Insurance {
+	private static final long serialVersionUID = 1L;
+
+}

+ 18 - 3
blade-service/blade-client/src/main/java/org/springblade/client/corps/controller/CorpsDescController.java

@@ -642,9 +642,10 @@ public class CorpsDescController extends BladeController {
 			LambdaQueryWrapper<CorpsDesc> lambdaQueryWrapper = new LambdaQueryWrapper<>();
 			lambdaQueryWrapper.eq(CorpsDesc::getIsDeleted, 0);
 			lambdaQueryWrapper.eq(CorpsDesc::getTenantId, SecureUtil.getTenantId());
-			lambdaQueryWrapper.eq(CorpsDesc::getCorpType, "KH");
-
-			if (!"234557".equals(AuthUtil.getTenantId())){
+			if ("234557".equals(AuthUtil.getTenantId())){
+				lambdaQueryWrapper.eq(CorpsDesc::getCorpType, "CD");
+			}else {
+				lambdaQueryWrapper.eq(CorpsDesc::getCorpType, "KH");
 				lambdaQueryWrapper.orderByAsc(CorpsDesc::getCname);
 			}
 
@@ -884,4 +885,18 @@ public class CorpsDescController extends BladeController {
 		}
 	}
 
+	/**
+	 * 根据类别查所属公司
+	 */
+	@GetMapping("/getCorpsType")
+	@ApiOperationSupport(order = 13)
+	@ApiOperation(value = "根据类别查所属公司", notes = "传入corpsDesc")
+	public R<List<CorpsDesc>> getCorpsType(CorpsDesc corpsDesc) {
+		LambdaQueryWrapper<CorpsDesc> lambdaQueryWrapper = new LambdaQueryWrapper<>();
+		lambdaQueryWrapper.eq(CorpsDesc::getIsDeleted,0);
+		lambdaQueryWrapper.eq(CorpsDesc::getCorpType,corpsDesc.getCorpType());
+		lambdaQueryWrapper.eq(CorpsDesc::getTenantId,SecureUtil.getTenantId());
+		return R.data(corpsDescService.list(lambdaQueryWrapper));
+	}
+
 }

+ 11 - 6
blade-service/blade-client/src/main/java/org/springblade/client/land/excel/VehicleExcel.java

@@ -88,12 +88,12 @@ public class VehicleExcel implements Serializable {
 	/**
 	 * 牵引车辆型号
 	 */
-	@ExcelProperty(value = "牵引车辆型号")
+	@ExcelProperty(value = "牵引车辆型号(必填)")
 	private String towModel;
 	/**
 	 * 牵引车车架号
 	 */
-	@ExcelProperty(value = "牵引车车架号")
+	@ExcelProperty(value = "牵引车车架号(必填)")
 	private String towVin;
 	/**
 	 * 挂车型号
@@ -108,7 +108,7 @@ public class VehicleExcel implements Serializable {
 	/**
 	 * 发动机型号
 	 */
-	@ExcelProperty(value = "发动机型号")
+	@ExcelProperty(value = "发动机型号(必填)")
 	private String engineModel;
 	/**
 	 * 核载人数
@@ -123,7 +123,7 @@ public class VehicleExcel implements Serializable {
 	/**
 	 * 注册日期
 	 */
-	@ExcelProperty(value = "注册日期")
+	@ExcelProperty(value = "注册日期(必填)")
 	private Date registerDate;
 	/**
 	 * 报废日期
@@ -131,6 +131,11 @@ public class VehicleExcel implements Serializable {
 	@ExcelProperty(value = "报废日期")
 	private Date scrapDate;
 	/**
+	 * 过户日期
+	 */
+	@ExcelProperty(value = "过户日期(必填)")
+	private Date transferDate;
+	/**
 	 * 外廓尺寸(mm)
 	 */
 	@ExcelProperty(value = "外廓尺寸(mm)")
@@ -143,12 +148,12 @@ public class VehicleExcel implements Serializable {
 	/**
 	 * 核定重量(kg)
 	 */
-	@ExcelProperty(value = "核定重量(kg)")
+	@ExcelProperty(value = "核定重量(kg)(必填)")
 	private BigDecimal approvedWeight;
 	/**
 	 * 装备重量(kg)
 	 */
-	@ExcelProperty(value = "装备重量(kg)")
+	@ExcelProperty(value = "装备重量(kg)(必填)")
 	private BigDecimal equipmentWeight;
 	/**
 	 * 备注

+ 21 - 0
blade-service/blade-client/src/main/java/org/springblade/client/land/service/impl/LandVehicleServiceImpl.java

@@ -188,6 +188,27 @@ public class LandVehicleServiceImpl extends ServiceImpl<LandVehicleMapper, LandV
 			if (StringUtil.isBlank(excel.getPlateNo())) {
 				throw new SecurityException("第" + (i + 1) + "行数据异常,车号不能为空");
 			}
+			if (StringUtil.isBlank(excel.getTowModel())){
+				throw new SecurityException("第" + (i + 1) + "行数据异常,牵引车辆型号不能为空");
+			}
+			if (ObjectUtil.isEmpty(excel.getRegisterDate())){
+				throw new SecurityException("第" + (i + 1) + "行数据异常,注册日期不能为空");
+			}
+			if (StringUtil.isBlank(excel.getEngineModel())){
+				throw new SecurityException("第" + (i + 1) + "行数据异常,发动机型号不能为空");
+			}
+			if (StringUtil.isBlank(excel.getTowVin())){
+				throw new SecurityException("第" + (i + 1) + "行数据异常,牵引车车架号不能为空");
+			}
+			if (ObjectUtil.isEmpty(excel.getTransferDate())){
+				throw new SecurityException("第" + (i + 1) + "行数据异常,过户日期不能为空");
+			}
+			if (ObjectUtil.isEmpty(excel.getApprovedWeight())){
+				throw new SecurityException("第" + (i + 1) + "行数据异常,核定重量不能为空");
+			}
+			if (ObjectUtil.isEmpty(excel.getEquipmentWeight())){
+				throw new SecurityException("第" + (i + 1) + "行数据异常,装备重量不能为空");
+			}
 
 			/*Integer count = baseMapper.selectCount(new LambdaQueryWrapper<LandVehicle>()
 				.eq(LandVehicle::getPlateNo, excel.getPlateNo())

+ 134 - 0
blade-service/blade-land/src/main/java/org/springblade/land/insurance/controller/InsuranceController.java

@@ -0,0 +1,134 @@
+/*
+ *      Copyright (c) 2018-2028, Chill Zhuang All rights reserved.
+ *
+ *  Redistribution and use in source and binary forms, with or without
+ *  modification, are permitted provided that the following conditions are met:
+ *
+ *  Redistributions of source code must retain the above copyright notice,
+ *  this list of conditions and the following disclaimer.
+ *  Redistributions in binary form must reproduce the above copyright
+ *  notice, this list of conditions and the following disclaimer in the
+ *  documentation and/or other materials provided with the distribution.
+ *  Neither the name of the dreamlu.net developer nor the names of its
+ *  contributors may be used to endorse or promote products derived from
+ *  this software without specific prior written permission.
+ *  Author: Chill 庄骞 (smallchill@163.com)
+ */
+package org.springblade.land.insurance.controller;
+
+import io.swagger.annotations.Api;
+import io.swagger.annotations.ApiOperation;
+import io.swagger.annotations.ApiParam;
+import com.github.xiaoymin.knife4j.annotations.ApiOperationSupport;
+import lombok.AllArgsConstructor;
+import javax.validation.Valid;
+import org.springblade.core.mp.support.Condition;
+import org.springblade.core.mp.support.Query;
+import org.springblade.core.tool.api.R;
+import org.springblade.core.tool.utils.Func;
+import org.springframework.web.bind.annotation.*;
+import com.baomidou.mybatisplus.core.metadata.IPage;
+import org.springblade.land.insurance.entity.Insurance;
+import org.springblade.land.insurance.vo.InsuranceVO;
+import org.springblade.land.insurance.service.IInsuranceService;
+import org.springblade.core.boot.ctrl.BladeController;
+
+/**
+ * 陆运保险主表 控制器
+ *
+ * @author BladeX
+ * @since 2023-02-15
+ */
+@RestController
+@AllArgsConstructor
+@RequestMapping("/insurance")
+@Api(value = "陆运保险主表", tags = "陆运保险主表接口")
+public class InsuranceController extends BladeController {
+
+	private final IInsuranceService insuranceService;
+
+	/**
+	 * 详情
+	 */
+	@GetMapping("/detail")
+	@ApiOperationSupport(order = 1)
+	@ApiOperation(value = "详情", notes = "传入insurance")
+	public R<Insurance> detail(Insurance insurance) {
+		Insurance detail = insuranceService.getDetail(insurance);
+		return R.data(detail);
+	}
+
+	/**
+	 * 分页 陆运保险主表
+	 */
+	@GetMapping("/list")
+	@ApiOperationSupport(order = 2)
+	@ApiOperation(value = "分页", notes = "传入insurance")
+	public R<IPage<Insurance>> list(Insurance insurance, Query query) {
+		return R.data(insuranceService.getList(insurance, query));
+	}
+
+	/**
+	 * 自定义分页 陆运保险主表
+	 */
+	@GetMapping("/page")
+	@ApiOperationSupport(order = 3)
+	@ApiOperation(value = "分页", notes = "传入insurance")
+	public R<IPage<InsuranceVO>> page(InsuranceVO insurance, Query query) {
+		IPage<InsuranceVO> pages = insuranceService.selectInsurancePage(Condition.getPage(query), insurance);
+		return R.data(pages);
+	}
+
+	/**
+	 * 新增 陆运保险主表
+	 */
+	@PostMapping("/save")
+	@ApiOperationSupport(order = 4)
+	@ApiOperation(value = "新增", notes = "传入insurance")
+	public R save(@Valid @RequestBody Insurance insurance) {
+		return R.status(insuranceService.save(insurance));
+	}
+
+	/**
+	 * 修改 陆运保险主表
+	 */
+	@PostMapping("/update")
+	@ApiOperationSupport(order = 5)
+	@ApiOperation(value = "修改", notes = "传入insurance")
+	public R update(@Valid @RequestBody Insurance insurance) {
+		return R.status(insuranceService.updateById(insurance));
+	}
+
+	/**
+	 * 新增或修改 陆运保险主表
+	 */
+	@PostMapping("/submit")
+	@ApiOperationSupport(order = 6)
+	@ApiOperation(value = "新增或修改", notes = "传入insurance")
+	public R submit(@Valid @RequestBody Insurance insurance) {
+		return R.data(insuranceService.add(insurance));
+	}
+
+
+	/**
+	 * 删除 陆运保险主表
+	 */
+	@PostMapping("/remove")
+	@ApiOperationSupport(order = 8)
+	@ApiOperation(value = "删除", notes = "传入ids")
+	public R remove(@ApiParam(value = "主键集合", required = true) @RequestParam String ids) {
+		return R.status(insuranceService.removeByIds(Func.toLongList(ids)));
+	}
+
+	/**
+	 * 申请通过或驳回
+	 */
+	@PostMapping("passCheck")
+	@ApiOperationSupport(order = 9)
+	@ApiOperation(value = "申请通过或驳回", notes = "传入insurance")
+	public R<Insurance> passCheck(@Valid @RequestBody Insurance insurance) {
+		Insurance detail = insuranceService.passCheck(insurance);
+		return R.data(detail);
+	}
+
+}

+ 126 - 0
blade-service/blade-land/src/main/java/org/springblade/land/insurance/controller/InsuranceFilesController.java

@@ -0,0 +1,126 @@
+/*
+ *      Copyright (c) 2018-2028, Chill Zhuang All rights reserved.
+ *
+ *  Redistribution and use in source and binary forms, with or without
+ *  modification, are permitted provided that the following conditions are met:
+ *
+ *  Redistributions of source code must retain the above copyright notice,
+ *  this list of conditions and the following disclaimer.
+ *  Redistributions in binary form must reproduce the above copyright
+ *  notice, this list of conditions and the following disclaimer in the
+ *  documentation and/or other materials provided with the distribution.
+ *  Neither the name of the dreamlu.net developer nor the names of its
+ *  contributors may be used to endorse or promote products derived from
+ *  this software without specific prior written permission.
+ *  Author: Chill 庄骞 (smallchill@163.com)
+ */
+package org.springblade.land.insurance.controller;
+
+import io.swagger.annotations.Api;
+import io.swagger.annotations.ApiOperation;
+import io.swagger.annotations.ApiParam;
+import com.github.xiaoymin.knife4j.annotations.ApiOperationSupport;
+import lombok.AllArgsConstructor;
+import javax.validation.Valid;
+
+import org.springblade.core.mp.support.Condition;
+import org.springblade.core.mp.support.Query;
+import org.springblade.core.tool.api.R;
+import org.springblade.core.tool.utils.Func;
+import org.springframework.web.bind.annotation.*;
+import com.baomidou.mybatisplus.core.metadata.IPage;
+import org.springblade.land.insurance.entity.InsuranceFiles;
+import org.springblade.land.insurance.vo.InsuranceFilesVO;
+import org.springblade.land.insurance.service.IInsuranceFilesService;
+import org.springblade.core.boot.ctrl.BladeController;
+
+/**
+ *  控制器
+ *
+ * @author BladeX
+ * @since 2023-02-15
+ */
+@RestController
+@AllArgsConstructor
+@RequestMapping("/insurancefiles")
+@Api(value = "", tags = "接口")
+public class InsuranceFilesController extends BladeController {
+
+	private final IInsuranceFilesService insuranceFilesService;
+
+	/**
+	 * 详情
+	 */
+	@GetMapping("/detail")
+	@ApiOperationSupport(order = 1)
+	@ApiOperation(value = "详情", notes = "传入insuranceFiles")
+	public R<InsuranceFiles> detail(InsuranceFiles insuranceFiles) {
+		InsuranceFiles detail = insuranceFilesService.getOne(Condition.getQueryWrapper(insuranceFiles));
+		return R.data(detail);
+	}
+
+	/**
+	 * 分页
+	 */
+	@GetMapping("/list")
+	@ApiOperationSupport(order = 2)
+	@ApiOperation(value = "分页", notes = "传入insuranceFiles")
+	public R<IPage<InsuranceFiles>> list(InsuranceFiles insuranceFiles, Query query) {
+		IPage<InsuranceFiles> pages = insuranceFilesService.page(Condition.getPage(query), Condition.getQueryWrapper(insuranceFiles));
+		return R.data(pages);
+	}
+
+	/**
+	 * 自定义分页
+	 */
+	@GetMapping("/page")
+	@ApiOperationSupport(order = 3)
+	@ApiOperation(value = "分页", notes = "传入insuranceFiles")
+	public R<IPage<InsuranceFilesVO>> page(InsuranceFilesVO insuranceFiles, Query query) {
+		IPage<InsuranceFilesVO> pages = insuranceFilesService.selectInsuranceFilesPage(Condition.getPage(query), insuranceFiles);
+		return R.data(pages);
+	}
+
+	/**
+	 * 新增
+	 */
+	@PostMapping("/save")
+	@ApiOperationSupport(order = 4)
+	@ApiOperation(value = "新增", notes = "传入insuranceFiles")
+	public R save(@Valid @RequestBody InsuranceFiles insuranceFiles) {
+		return R.status(insuranceFilesService.save(insuranceFiles));
+	}
+
+	/**
+	 * 修改
+	 */
+	@PostMapping("/update")
+	@ApiOperationSupport(order = 5)
+	@ApiOperation(value = "修改", notes = "传入insuranceFiles")
+	public R update(@Valid @RequestBody InsuranceFiles insuranceFiles) {
+		return R.status(insuranceFilesService.updateById(insuranceFiles));
+	}
+
+	/**
+	 * 新增或修改
+	 */
+	@PostMapping("/submit")
+	@ApiOperationSupport(order = 6)
+	@ApiOperation(value = "新增或修改", notes = "传入insuranceFiles")
+	public R submit(@Valid @RequestBody InsuranceFiles insuranceFiles) {
+		return R.status(insuranceFilesService.saveOrUpdate(insuranceFiles));
+	}
+
+
+	/**
+	 * 删除
+	 */
+	@PostMapping("/remove")
+	@ApiOperationSupport(order = 8)
+	@ApiOperation(value = "删除", notes = "传入ids")
+	public R remove(@ApiParam(value = "主键集合", required = true) @RequestParam String ids) {
+		return R.status(insuranceFilesService.removeByIds(Func.toLongList(ids)));
+	}
+
+
+}

+ 42 - 0
blade-service/blade-land/src/main/java/org/springblade/land/insurance/mapper/InsuranceFilesMapper.java

@@ -0,0 +1,42 @@
+/*
+ *      Copyright (c) 2018-2028, Chill Zhuang All rights reserved.
+ *
+ *  Redistribution and use in source and binary forms, with or without
+ *  modification, are permitted provided that the following conditions are met:
+ *
+ *  Redistributions of source code must retain the above copyright notice,
+ *  this list of conditions and the following disclaimer.
+ *  Redistributions in binary form must reproduce the above copyright
+ *  notice, this list of conditions and the following disclaimer in the
+ *  documentation and/or other materials provided with the distribution.
+ *  Neither the name of the dreamlu.net developer nor the names of its
+ *  contributors may be used to endorse or promote products derived from
+ *  this software without specific prior written permission.
+ *  Author: Chill 庄骞 (smallchill@163.com)
+ */
+package org.springblade.land.insurance.mapper;
+
+import org.springblade.land.insurance.entity.InsuranceFiles;
+import org.springblade.land.insurance.vo.InsuranceFilesVO;
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+import com.baomidou.mybatisplus.core.metadata.IPage;
+import java.util.List;
+
+/**
+ *  Mapper 接口
+ *
+ * @author BladeX
+ * @since 2023-02-15
+ */
+public interface InsuranceFilesMapper extends BaseMapper<InsuranceFiles> {
+
+	/**
+	 * 自定义分页
+	 *
+	 * @param page
+	 * @param insuranceFiles
+	 * @return
+	 */
+	List<InsuranceFilesVO> selectInsuranceFilesPage(IPage page, InsuranceFilesVO insuranceFiles);
+
+}

+ 29 - 0
blade-service/blade-land/src/main/java/org/springblade/land/insurance/mapper/InsuranceFilesMapper.xml

@@ -0,0 +1,29 @@
+<?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="org.springblade.land.insurance.mapper.InsuranceFilesMapper">
+
+    <!-- 通用查询映射结果 -->
+    <resultMap id="insuranceFilesResultMap" type="org.springblade.land.insurance.entity.InsuranceFiles">
+        <id column="id" property="id"/>
+        <result column="pid" property="pid"/>
+        <result column="sort" property="sort"/>
+        <result column="file_name" property="fileName"/>
+        <result column="url" property="url"/>
+        <result column="remark" property="remark"/>
+        <result column="version" property="version"/>
+        <result column="create_user" property="createUser"/>
+        <result column="create_dept" property="createDept"/>
+        <result column="create_time" property="createTime"/>
+        <result column="update_user" property="updateUser"/>
+        <result column="update_time" property="updateTime"/>
+        <result column="status" property="status"/>
+        <result column="is_deleted" property="isDeleted"/>
+        <result column="type" property="type"/>
+    </resultMap>
+
+
+    <select id="selectInsuranceFilesPage" resultMap="insuranceFilesResultMap">
+        select * from land_insurance_files where is_deleted = 0
+    </select>
+
+</mapper>

+ 42 - 0
blade-service/blade-land/src/main/java/org/springblade/land/insurance/mapper/InsuranceMapper.java

@@ -0,0 +1,42 @@
+/*
+ *      Copyright (c) 2018-2028, Chill Zhuang All rights reserved.
+ *
+ *  Redistribution and use in source and binary forms, with or without
+ *  modification, are permitted provided that the following conditions are met:
+ *
+ *  Redistributions of source code must retain the above copyright notice,
+ *  this list of conditions and the following disclaimer.
+ *  Redistributions in binary form must reproduce the above copyright
+ *  notice, this list of conditions and the following disclaimer in the
+ *  documentation and/or other materials provided with the distribution.
+ *  Neither the name of the dreamlu.net developer nor the names of its
+ *  contributors may be used to endorse or promote products derived from
+ *  this software without specific prior written permission.
+ *  Author: Chill 庄骞 (smallchill@163.com)
+ */
+package org.springblade.land.insurance.mapper;
+
+import org.springblade.land.insurance.entity.Insurance;
+import org.springblade.land.insurance.vo.InsuranceVO;
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+import com.baomidou.mybatisplus.core.metadata.IPage;
+import java.util.List;
+
+/**
+ * 陆运保险主表 Mapper 接口
+ *
+ * @author BladeX
+ * @since 2023-02-15
+ */
+public interface InsuranceMapper extends BaseMapper<Insurance> {
+
+	/**
+	 * 自定义分页
+	 *
+	 * @param page
+	 * @param insurance
+	 * @return
+	 */
+	List<InsuranceVO> selectInsurancePage(IPage page, InsuranceVO insurance);
+
+}

+ 57 - 0
blade-service/blade-land/src/main/java/org/springblade/land/insurance/mapper/InsuranceMapper.xml

@@ -0,0 +1,57 @@
+<?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="org.springblade.land.insurance.mapper.InsuranceMapper">
+
+    <!-- 通用查询映射结果 -->
+    <resultMap id="insuranceResultMap" type="org.springblade.land.insurance.entity.Insurance">
+        <id column="id" property="id"/>
+        <result column="sys_no" property="sysNo"/>
+        <result column="create_user" property="createUser"/>
+        <result column="create_dept" property="createDept"/>
+        <result column="create_time" property="createTime"/>
+        <result column="update_user" property="updateUser"/>
+        <result column="update_time" property="updateTime"/>
+        <result column="status" property="status"/>
+        <result column="is_deleted" property="isDeleted"/>
+        <result column="remark" property="remark"/>
+        <result column="insurance_company_id" property="insuranceCompanyId"/>
+        <result column="insurance_company_name" property="insuranceCompanyName"/>
+        <result column="fleet_id" property="fleetId"/>
+        <result column="fleet_name" property="fleetName"/>
+        <result column="policy_holder_id" property="policyHolderId"/>
+        <result column="policy_holder_name" property="policyHolderName"/>
+        <result column="insured_id" property="insuredId"/>
+        <result column="insured_name" property="insuredName"/>
+        <result column="contact_number" property="contactNumber"/>
+        <result column="car_number_id" property="carNumberId"/>
+        <result column="car_number_name" property="carNumberName"/>
+        <result column="tow_model" property="towModel"/>
+        <result column="register_date" property="registerDate"/>
+        <result column="engine_model" property="engineModel"/>
+        <result column="tow_vin" property="towVin"/>
+        <result column="transfer_date" property="transferDate"/>
+        <result column="approved_weight" property="approvedWeight"/>
+        <result column="equipment_weight" property="equipmentWeight"/>
+        <result column="loss_insurance_key" property="lossInsuranceKey"/>
+        <result column="loss_insurance_value" property="lossInsuranceValue"/>
+        <result column="liability_insurance_key" property="liabilityInsuranceKey"/>
+        <result column="liability_insurance_value" property="liabilityInsuranceValue"/>
+        <result column="driver_liability_insurance_key" property="driverLiabilityInsuranceKey"/>
+        <result column="driver_liability_insurance_value" property="driverLiabilityInsuranceValue"/>
+        <result column="passenger_liability_insurance_key" property="passengerLiabilityInsuranceKey"/>
+        <result column="passenger_liability_insurance_value" property="passengerLiabilityInsuranceValue"/>
+        <result column="force_liability_insurance_key" property="forceLiabilityInsuranceKey"/>
+        <result column="force_liability_insurance_value" property="forceLiabilityInsuranceValue"/>
+        <result column="vehicle_vessel_tax_key" property="vehicleVesselTaxKey"/>
+        <result column="vehicle_vessel_tax_vaue" property="vehicleVesselTaxVaue"/>
+        <result column="estimated_premium" property="estimatedPremium"/>
+        <result column="actual_premium" property="actualPremium"/>
+        <result column="status_name" property="statusName"/>
+    </resultMap>
+
+
+    <select id="selectInsurancePage" resultMap="insuranceResultMap">
+        select * from land_insurance where is_deleted = 0
+    </select>
+
+</mapper>

+ 41 - 0
blade-service/blade-land/src/main/java/org/springblade/land/insurance/service/IInsuranceFilesService.java

@@ -0,0 +1,41 @@
+/*
+ *      Copyright (c) 2018-2028, Chill Zhuang All rights reserved.
+ *
+ *  Redistribution and use in source and binary forms, with or without
+ *  modification, are permitted provided that the following conditions are met:
+ *
+ *  Redistributions of source code must retain the above copyright notice,
+ *  this list of conditions and the following disclaimer.
+ *  Redistributions in binary form must reproduce the above copyright
+ *  notice, this list of conditions and the following disclaimer in the
+ *  documentation and/or other materials provided with the distribution.
+ *  Neither the name of the dreamlu.net developer nor the names of its
+ *  contributors may be used to endorse or promote products derived from
+ *  this software without specific prior written permission.
+ *  Author: Chill 庄骞 (smallchill@163.com)
+ */
+package org.springblade.land.insurance.service;
+
+import org.springblade.land.insurance.entity.InsuranceFiles;
+import org.springblade.land.insurance.vo.InsuranceFilesVO;
+import com.baomidou.mybatisplus.extension.service.IService;
+import com.baomidou.mybatisplus.core.metadata.IPage;
+
+/**
+ *  服务类
+ *
+ * @author BladeX
+ * @since 2023-02-15
+ */
+public interface IInsuranceFilesService extends IService<InsuranceFiles> {
+
+	/**
+	 * 自定义分页
+	 *
+	 * @param page
+	 * @param insuranceFiles
+	 * @return
+	 */
+	IPage<InsuranceFilesVO> selectInsuranceFilesPage(IPage<InsuranceFilesVO> page, InsuranceFilesVO insuranceFiles);
+
+}

+ 77 - 0
blade-service/blade-land/src/main/java/org/springblade/land/insurance/service/IInsuranceService.java

@@ -0,0 +1,77 @@
+/*
+ *      Copyright (c) 2018-2028, Chill Zhuang All rights reserved.
+ *
+ *  Redistribution and use in source and binary forms, with or without
+ *  modification, are permitted provided that the following conditions are met:
+ *
+ *  Redistributions of source code must retain the above copyright notice,
+ *  this list of conditions and the following disclaimer.
+ *  Redistributions in binary form must reproduce the above copyright
+ *  notice, this list of conditions and the following disclaimer in the
+ *  documentation and/or other materials provided with the distribution.
+ *  Neither the name of the dreamlu.net developer nor the names of its
+ *  contributors may be used to endorse or promote products derived from
+ *  this software without specific prior written permission.
+ *  Author: Chill 庄骞 (smallchill@163.com)
+ */
+package org.springblade.land.insurance.service;
+
+import org.springblade.core.mp.support.Query;
+import org.springblade.core.tool.api.R;
+import org.springblade.land.insurance.entity.Insurance;
+import org.springblade.land.insurance.vo.InsuranceVO;
+import com.baomidou.mybatisplus.extension.service.IService;
+import com.baomidou.mybatisplus.core.metadata.IPage;
+
+
+/**
+ * 陆运保险主表 服务类
+ *
+ * @author BladeX
+ * @since 2023-02-15
+ */
+public interface IInsuranceService extends IService<Insurance> {
+
+	/**
+	 * 详情
+	 *
+	 * @param insurance
+	 * @return
+	 */
+	Insurance getDetail(Insurance insurance);
+
+	/**
+	 * 分页
+	 *
+	 * @param insurance
+	 * @param query
+	 * @return
+	 */
+	IPage<Insurance> getList(Insurance insurance, Query query);
+
+	/**
+	 * 自定义分页
+	 *
+	 * @param page
+	 * @param insurance
+	 * @return
+	 */
+	IPage<InsuranceVO> selectInsurancePage(IPage<InsuranceVO> page, InsuranceVO insurance);
+
+	/**
+	 * 新增或修改
+	 *
+	 * @param insurance
+	 * @return
+	 */
+	Insurance add(Insurance insurance);
+
+	/**
+	 * 申请通过或驳回
+	 *
+	 * @param insurance
+	 * @return
+	 */
+	Insurance passCheck(Insurance insurance);
+
+}

+ 41 - 0
blade-service/blade-land/src/main/java/org/springblade/land/insurance/service/impl/InsuranceFilesServiceImpl.java

@@ -0,0 +1,41 @@
+/*
+ *      Copyright (c) 2018-2028, Chill Zhuang All rights reserved.
+ *
+ *  Redistribution and use in source and binary forms, with or without
+ *  modification, are permitted provided that the following conditions are met:
+ *
+ *  Redistributions of source code must retain the above copyright notice,
+ *  this list of conditions and the following disclaimer.
+ *  Redistributions in binary form must reproduce the above copyright
+ *  notice, this list of conditions and the following disclaimer in the
+ *  documentation and/or other materials provided with the distribution.
+ *  Neither the name of the dreamlu.net developer nor the names of its
+ *  contributors may be used to endorse or promote products derived from
+ *  this software without specific prior written permission.
+ *  Author: Chill 庄骞 (smallchill@163.com)
+ */
+package org.springblade.land.insurance.service.impl;
+
+import org.springblade.land.insurance.entity.InsuranceFiles;
+import org.springblade.land.insurance.vo.InsuranceFilesVO;
+import org.springblade.land.insurance.mapper.InsuranceFilesMapper;
+import org.springblade.land.insurance.service.IInsuranceFilesService;
+import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
+import org.springframework.stereotype.Service;
+import com.baomidou.mybatisplus.core.metadata.IPage;
+
+/**
+ *  服务实现类
+ *
+ * @author BladeX
+ * @since 2023-02-15
+ */
+@Service
+public class InsuranceFilesServiceImpl extends ServiceImpl<InsuranceFilesMapper, InsuranceFiles> implements IInsuranceFilesService {
+
+	@Override
+	public IPage<InsuranceFilesVO> selectInsuranceFilesPage(IPage<InsuranceFilesVO> page, InsuranceFilesVO insuranceFiles) {
+		return page.setRecords(baseMapper.selectInsuranceFilesPage(page, insuranceFiles));
+	}
+
+}

+ 446 - 0
blade-service/blade-land/src/main/java/org/springblade/land/insurance/service/impl/InsuranceServiceImpl.java

@@ -0,0 +1,446 @@
+/*
+ *      Copyright (c) 2018-2028, Chill Zhuang All rights reserved.
+ *
+ *  Redistribution and use in source and binary forms, with or without
+ *  modification, are permitted provided that the following conditions are met:
+ *
+ *  Redistributions of source code must retain the above copyright notice,
+ *  this list of conditions and the following disclaimer.
+ *  Redistributions in binary form must reproduce the above copyright
+ *  notice, this list of conditions and the following disclaimer in the
+ *  documentation and/or other materials provided with the distribution.
+ *  Neither the name of the dreamlu.net developer nor the names of its
+ *  contributors may be used to endorse or promote products derived from
+ *  this software without specific prior written permission.
+ *  Author: Chill 庄骞 (smallchill@163.com)
+ */
+package org.springblade.land.insurance.service.impl;
+
+import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
+import com.baomidou.mybatisplus.core.toolkit.CollectionUtils;
+import com.baomidou.mybatisplus.core.toolkit.ObjectUtils;
+import com.baomidou.mybatisplus.core.toolkit.StringUtils;
+import io.seata.spring.annotation.GlobalTransactional;
+import lombok.AllArgsConstructor;
+import org.springblade.client.entity.CorpsAttn;
+import org.springblade.client.entity.CorpsDesc;
+import org.springblade.client.entity.Message;
+import org.springblade.client.feign.ICorpsAttnClient;
+import org.springblade.client.feign.ICorpsDescClient;
+import org.springblade.client.feign.IMessageClient;
+import org.springblade.client.feign.ISerialClient;
+import org.springblade.core.mp.support.Condition;
+import org.springblade.core.mp.support.Query;
+import org.springblade.core.secure.utils.AuthUtil;
+import org.springblade.core.secure.utils.SecureUtil;
+import org.springblade.core.tool.api.R;
+import org.springblade.core.tool.utils.ObjectUtil;
+import org.springblade.finance.dto.ApplyDTO;
+import org.springblade.finance.feign.IFinanceClient;
+import org.springblade.finance.vojo.Acc;
+import org.springblade.finance.vojo.Items;
+import org.springblade.land.constant.LandConst;
+import org.springblade.land.insurance.entity.Insurance;
+import org.springblade.land.insurance.entity.InsuranceFiles;
+import org.springblade.land.insurance.mapper.InsuranceFilesMapper;
+import org.springblade.land.insurance.vo.InsuranceVO;
+import org.springblade.land.insurance.mapper.InsuranceMapper;
+import org.springblade.land.insurance.service.IInsuranceService;
+import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
+import org.springblade.system.feign.ISysClient;
+import org.springblade.system.user.entity.User;
+import org.springblade.system.user.feign.IUserClient;
+import org.springframework.stereotype.Service;
+import com.baomidou.mybatisplus.core.metadata.IPage;
+import org.springframework.transaction.annotation.Transactional;
+import org.springframework.transaction.interceptor.TransactionAspectSupport;
+
+import java.math.BigDecimal;
+import java.math.BigInteger;
+import java.util.ArrayList;
+import java.util.Date;
+import java.util.List;
+
+/**
+ * 陆运保险主表 服务实现类
+ *
+ * @author BladeX
+ * @since 2023-02-15
+ */
+@Service
+@AllArgsConstructor
+public class InsuranceServiceImpl extends ServiceImpl<InsuranceMapper, Insurance> implements IInsuranceService {
+
+	private ISerialClient serialClient;//生成系统编号
+	private final InsuranceFilesMapper filesMapper;//附件明细
+
+	private final ICorpsDescClient corpsDescClient;//客户
+	private final ICorpsAttnClient corpsAttnClient;//客户联系人
+	private final IFinanceClient financeClient;//财务
+	private final ISysClient sysClient;
+	private IUserClient userClient;//获取用户信息
+	private final IMessageClient messageClient;//消息
+
+	/**
+	 * 详情
+	 *
+	 * @param insurance
+	 * @return
+	 */
+	@Override
+	public Insurance getDetail(Insurance insurance){
+		if (insurance.getId() == null){
+			throw new SecurityException("缺少必要参数");
+		}
+		//获得保险详情
+		Insurance detail = baseMapper.selectById(insurance.getId());
+
+		if (ObjectUtil.isNotEmpty(detail)){
+			//获得附件信息
+			LambdaQueryWrapper<InsuranceFiles> filesLambdaQueryWrapper = new LambdaQueryWrapper<>();
+			filesLambdaQueryWrapper.eq(InsuranceFiles::getIsDeleted, 0)
+				.eq(InsuranceFiles::getTenantId, AuthUtil.getTenantId())
+				.eq(InsuranceFiles::getPid, detail.getId());
+			List<InsuranceFiles> filesList = filesMapper.selectList(filesLambdaQueryWrapper);
+
+			List<InsuranceFiles> fleetList = new ArrayList<>();
+			List<InsuranceFiles> filesOneList = new ArrayList<>();
+			List<InsuranceFiles> filesTwoList = new ArrayList<>();
+			List<InsuranceFiles> filesThreeList = new ArrayList<>();
+			if (ObjectUtil.isNotEmpty(filesList)){
+				filesList.forEach(e -> {
+					if (ObjectUtil.isNotEmpty(e.getFilesType())){
+						if ("0".equals(e.getFilesType())){//车队附件
+							fleetList.add(e);
+						} else if ("1".equals(e.getFilesType())){//保费1
+							filesOneList.add(e);
+						} else if ("2".equals(e.getFilesType())){//保费2
+							filesTwoList.add(e);
+						} else if ("3".equals(e.getFilesType())){//保费3
+							filesThreeList.add(e);
+						}
+					}
+				});
+			}
+			detail.setFleetList(fleetList);
+			detail.setFilesOneList(filesOneList);
+			detail.setFilesTwoList(filesTwoList);
+			detail.setFilesThreeList(filesThreeList);
+		}
+
+		return detail;
+	}
+
+	/**
+	 * 分页
+	 *
+	 * @param insurance
+	 * @param query
+	 * @return
+	 */
+	public IPage<Insurance> getList(Insurance insurance, Query query){
+		LambdaQueryWrapper<Insurance> lambdaQueryWrapper = new LambdaQueryWrapper<>();
+		lambdaQueryWrapper.like(ObjectUtil.isNotEmpty(insurance.getCarNumberName()), Insurance::getCarNumberId, insurance.getCarNumberName())//车号
+			.eq(ObjectUtil.isNotEmpty(insurance.getStatus()), Insurance::getStatus, insurance.getStatus());//状态
+
+		//根据当前登录人获得客户联系人
+		CorpsAttn corpsAttn = corpsAttnClient.getUser(AuthUtil.getUserId());
+		if (ObjectUtil.isNotEmpty(corpsAttn)){
+			//根据客户联系人获得客户
+			CorpsDesc corpsDesc = corpsDescClient.getCorpId(corpsAttn.getPid());
+			if (ObjectUtil.isNotEmpty(corpsDesc)){
+				String role = AuthUtil.getUserRole();
+				if (role.contains(LandConst.ROLE_CD)){//车队只能看自己车队
+					lambdaQueryWrapper.eq(Insurance::getFleetId, corpsDesc.getId());//车队
+				}else if (role.contains(LandConst.ROLE_BXGS)){//保险公司只能看自己公司
+					lambdaQueryWrapper.eq(Insurance::getInsuranceCompanyId, corpsDesc.getId());
+				}
+			}
+		}
+
+		IPage<Insurance> pages = baseMapper.selectPage(Condition.getPage(query), lambdaQueryWrapper);
+
+		return pages;
+	}
+
+	/**
+	 * 自定义分页
+	 *
+	 * @param insurance
+	 * @return
+	 */
+	@Override
+	public IPage<InsuranceVO> selectInsurancePage(IPage<InsuranceVO> page, InsuranceVO insurance) {
+		return page.setRecords(baseMapper.selectInsurancePage(page, insurance));
+	}
+
+	/**
+	 * 新增或修改
+	 *
+	 * @param insurance
+	 * @return
+	 */
+	@Override
+	@Transactional(rollbackFor = Exception.class)
+	@GlobalTransactional(rollbackFor = Exception.class, timeoutMills = 12000000)
+	public Insurance add(Insurance insurance){
+		if (insurance.getId() == null){
+			//获取系统编号
+			R billNo = new R();
+
+			billNo = serialClient.getBillNo("LYBX", "LYBX", "LYBX");
+			if (!billNo.isSuccess()) {
+				TransactionAspectSupport.currentTransactionStatus().setRollbackOnly();
+				throw new Error("生成系统编号失败");
+			}
+
+			insurance.setSysNo(billNo.getData().toString());
+			insurance.setTenantId(AuthUtil.getTenantId());
+			insurance.setCreateUser(AuthUtil.getUserId());
+			insurance.setCreateDept(Long.valueOf(AuthUtil.getDeptId()));
+			insurance.setCreateTime(new Date());
+			insurance.setStatus(0);
+			insurance.setStatusName("未获取");
+			baseMapper.insert(insurance);
+		}else {
+			insurance.setUpdateTime(new Date());
+			insurance.setUpdateUser(AuthUtil.getUserId());
+			baseMapper.updateById(insurance);
+		}
+
+		//车队附件
+		List<InsuranceFiles> fleetList = insurance.getFleetList();
+		saveFile(fleetList, insurance.getId());
+		insurance.setFleetList(fleetList);
+		//保费1附件
+		List<InsuranceFiles> filesOneList = insurance.getFilesOneList();
+		saveFile(filesOneList, insurance.getId());
+		insurance.setFilesOneList(filesOneList);
+		//保费2附件
+		List<InsuranceFiles> filesTwoList = insurance.getFilesTwoList();
+		saveFile(filesTwoList, insurance.getId());
+		insurance.setFleetList(filesTwoList);
+		//保费3附件
+		List<InsuranceFiles> filesThreeList = insurance.getFilesThreeList();
+		saveFile(filesThreeList, insurance.getId());
+		insurance.setFleetList(filesThreeList);
+
+		return insurance;
+	}
+
+	/**
+	 * 申请通过或驳回
+	 *
+	 * @param insurance
+	 * @return
+	 */
+	@Override
+	public Insurance passCheck(Insurance insurance){
+		if (insurance.getCheckFlag() == null || insurance.getId() == null){
+			throw new SecurityException("缺少必要参数");
+		}
+		//获得保险详情
+		Insurance detail = baseMapper.selectById(insurance.getId());
+
+		if (ObjectUtil.isNotEmpty(detail)){
+			if (insurance.getCheckFlag() == 1){//通过
+				if (insurance.getStatus() == 0){
+					insurance.setStatus(1);
+					insurance.setStatusName("未确认");
+				}else if (insurance.getStatus() == 1){
+					insurance.setStatus(2);
+					insurance.setStatusName("已确认");
+				}else if (insurance.getStatus() == 2){//保费提交重新保存附件
+					//保费1附件
+					List<InsuranceFiles> filesOne = insurance.getFilesOneList();
+					saveFile(filesOne, insurance.getId());
+					//保费2附件
+					List<InsuranceFiles> filesTwo = insurance.getFilesTwoList();
+					saveFile(filesTwo, insurance.getId());
+					//保费3附件
+					List<InsuranceFiles> filesThree = insurance.getFilesThreeList();
+					saveFile(filesThree, insurance.getId());
+
+					insurance.setStatus(3);
+					insurance.setStatusName("未受理");
+				}else if (insurance.getStatus() == 3){
+					insurance.setStatus(4);
+					insurance.setStatusName("已受理");
+				}else if (insurance.getStatus() == 4){
+					//生成对账明细
+					paymentApply(insurance);
+					insurance.setStatus(5);
+					insurance.setStatusName("未签单");
+				}else if (insurance.getStatus() == 5){
+					insurance.setStatus(6);
+					insurance.setStatusName("已完成");
+				}
+			}else if (insurance.getCheckFlag() == 2){//驳回
+				if (insurance.getStatus() == 0){
+					throw new SecurityException("订单未获取报价撤销失败");
+				}else if (insurance.getStatus() == 1){
+					insurance.setStatus(0);
+					insurance.setStatusName("未获取");
+				}else if (insurance.getStatus() == 2){
+					insurance.setStatus(1);
+					insurance.setStatusName("未确认");
+				}else if (insurance.getStatus() == 3){
+					insurance.setStatus(2);
+					insurance.setStatusName("已确认");
+				}else if (insurance.getStatus() == 4){
+					//撤销验证账单是否已结算
+					revoke(insurance);
+					insurance.setStatus(3);
+					insurance.setStatusName("未受理");
+				}else if (insurance.getStatus() == 5){
+					insurance.setStatus(4);
+					insurance.setStatusName("已受理");
+				}else if (insurance.getStatus() == 6){
+					insurance.setStatus(5);
+					insurance.setStatusName("未签单");
+				}
+			}else if (insurance.getCheckFlag() == 3){
+				insurance.setStatus(7);
+				insurance.setStatusName("弃保");
+			}
+		}
+
+		baseMapper.updateById(insurance);
+
+		return insurance;
+	}
+
+	/**
+	 * 生成账单明细
+	 */
+	public void paymentApply(Insurance detail){
+
+		//账单数据
+		ApplyDTO applyDTO = new ApplyDTO();
+		applyDTO.setBillType("申请");
+		applyDTO.setTradeType("LYBX");
+		applyDTO.setBelongCompany(detail.getFleetName());
+
+		List<Items> itemsList = new ArrayList<>();
+
+		Items items = new Items();
+		items.setSrcFeesType("申请");
+		items.setItemName("保险");
+		items.setItemType("LYBX");
+		//账单数据
+		if (ObjectUtil.isNotEmpty(detail.getDisplay())){
+			if (detail.getDisplay() == 1){
+				if (ObjectUtil.isNotEmpty(detail.getActualPremiumOne())){
+					items.setAmount(detail.getActualPremiumOne());
+				}else {
+					items.setAmount(new BigDecimal(BigInteger.ZERO));
+				}
+			}else if (detail.getDisplay() == 2){
+				if (ObjectUtil.isNotEmpty(detail.getActualPremiumTwo())){
+					items.setAmount(detail.getActualPremiumTwo());
+				}else {
+					items.setAmount(new BigDecimal(BigInteger.ZERO));
+				}
+			}else if (detail.getDisplay() == 3){
+				if (ObjectUtil.isNotEmpty(detail.getActualPremiumThree())){
+					items.setAmount(detail.getActualPremiumThree());
+				}else {
+					items.setAmount(new BigDecimal(BigInteger.ZERO));
+				}
+			}
+		}else {
+			items.setAmount(new BigDecimal(BigInteger.ZERO));
+		}
+		items.setSrcOrderno(detail.getSysNo());//来源订单号
+		items.setSrcParentId(detail.getId());//来源主表id
+		items.setSrcType(12);//结算标识
+		items.setTradeType("LYBX");//系统类别
+		items.setPlateNo(detail.getCarNumberName());//车号
+		items.setCorpId(detail.getInsuranceCompanyId());//保险公司
+		items.setRemarks(detail.getRemark());//备注
+		items.setStockTime(detail.getBusinessDate());//业务日期
+		itemsList.add(items);
+		applyDTO.setItemsList(itemsList);
+
+		if (CollectionUtils.isNotEmpty(itemsList)) {
+			//生成账单
+			R paymentApply = financeClient.paymentApplyBoxTube(applyDTO);
+			if (!paymentApply.isSuccess()) {
+				throw new RuntimeException(paymentApply.getMsg());
+			}
+			//给角色为财务的人发送消息
+			R<String> clientDeptIds = sysClient.getRoleIds(SecureUtil.getTenantId(), "财务");
+			if (clientDeptIds.isSuccess() && StringUtils.isNotBlank(clientDeptIds.getData())) {
+				R<List<User>> userList = userClient.listUserByRoleId(Long.valueOf(clientDeptIds.getData()));
+				if (userList.isSuccess() && CollectionUtils.isNotEmpty(userList.getData())) {
+					for (User datum : userList.getData()) {
+						//循环发送消息
+						Message sendMessage = new Message();
+						sendMessage.setParameter(String.valueOf(detail.getId()));
+						sendMessage.setUserName(AuthUtil.getUserName());
+						sendMessage.setUserId(AuthUtil.getUserId());
+						sendMessage.setToUserId(datum.getId());
+						sendMessage.setToUserName(datum.getName());
+						sendMessage.setMessageType(1);
+						sendMessage.setTenantId(AuthUtil.getTenantId());
+						sendMessage.setCreateUser(AuthUtil.getUserId());
+						sendMessage.setCreateTime(new Date());
+						sendMessage.setMessageBody("保险业务" + detail.getSysNo() + "车队确认投保,请查看");
+						R save = messageClient.save(sendMessage);
+						if (!save.isSuccess()) {
+							throw new SecurityException("发送消息失败");
+						}
+					}
+				}
+			}
+		}
+	}
+
+	/**
+	 * 撤销账单
+	 */
+	public void revoke(Insurance insurance){
+		//获取账单信息
+		Acc acc = new Acc();
+		acc.setSrcParentId(insurance.getId());
+		acc.setBillType("申请");
+		acc.setTradeType("LYBX");
+		acc.setSrcType(12);
+		R<List<Acc>> r = financeClient.getAccListByCondition(acc);
+		if (r.isSuccess() && ObjectUtils.isNotNull(r.getData())) {
+			for (Acc acc_ : r.getData()) {
+				//判断是否有结算 true 不允许撤销审核  false 删除账单信息并撤销审核
+				if (!acc_.getSettlementAmount().equals(new BigDecimal("0.00"))) {
+					throw new SecurityException("保险已结算,不允许撤销");
+				} else {
+					financeClient.remove(acc_.getId() + "");
+				}
+			}
+		}
+	}
+
+
+
+
+	/**
+	 * 保存附件明细
+	 */
+	private void saveFile(List<InsuranceFiles> filesList, Long id){
+		if (ObjectUtils.isNotNull(filesList) && filesList.size() > 0) {
+			for (InsuranceFiles item : filesList) {
+				if (item.getId() == null) {
+					item.setCreateUser(AuthUtil.getUserId());
+					item.setCreateTime(new Date());
+					item.setTenantId(AuthUtil.getTenantId());
+					item.setPid(id);
+					filesMapper.insert(item);
+				} else {
+					item.setUpdateUser(AuthUtil.getUserId());
+					item.setUpdateTime(new Date());
+					item.setPid(id);
+					filesMapper.updateById(item);
+				}
+			}
+		}
+	}
+}

+ 2 - 1
blade-service/blade-land/src/main/java/org/springblade/land/service/impl/OrderServiceImpl.java

@@ -1647,7 +1647,8 @@ public class OrderServiceImpl extends ServiceImpl<OrderMapper, LandOrder> implem
 			LambdaQueryWrapper<OrderAddress> addressLambdaQueryWrapper = new LambdaQueryWrapper<>();
 			addressLambdaQueryWrapper.eq(OrderAddress::getOrderId, acct.getOrderId())
 				.eq(OrderAddress::getTenantId, AuthUtil.getTenantId())
-				.eq(OrderAddress::getIsDeleted, 0);
+				.eq(OrderAddress::getIsDeleted, 0)
+				.orderByAsc(OrderAddress::getSort);
 
 			List<OrderAddress> addressList = orderAddressMapper.selectList(addressLambdaQueryWrapper);
 			int i = 1;