This commit is contained in:
linfso 2024-06-14 06:16:48 +08:00
parent 1003fae84c
commit 37657db1af
12 changed files with 1477 additions and 0 deletions

View File

@ -0,0 +1,134 @@
/**
* @Project: emis
* @Title: EmisTmsCarController.java
* @author linfso
* @date 2024-06-13 22:00:25
* @Copyright: ShangHai Duta 2022 All rights reserved.
* @version v1.0
* @Description: <p> 卡车信息 控制器 </p>
*/
package com.xdadan.erp.web.emis;
import java.util.List;
import javax.servlet.http.HttpServletResponse;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.security.access.prepost.PreAuthorize;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.PutMapping;
import org.springframework.web.bind.annotation.DeleteMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import com.xdadan.erp.common.annotation.Log;
import com.xdadan.erp.common.core.controller.BaseController;
import com.xdadan.erp.common.core.domain.AjaxResult;
import com.xdadan.erp.common.core.page.TableDataInfo;
import com.xdadan.erp.common.enums.BusinessType;
import com.xdadan.erp.common.utils.StringUtils;
import com.xdadan.erp.common.utils.poi.ExcelUtil;
import com.xdadan.erp.emis.domain.EmisTmsCar;
import com.xdadan.erp.emis.service.IEmisTmsCarService;
/**
* 卡车信息Controller
*
* @author linfso
* @date 2024-06-13 22:00:25
*/
@RestController
@RequestMapping("/emis/emisTmsCar")
public class EmisTmsCarController extends BaseController
{
@Autowired
private IEmisTmsCarService emisTmsCarService;
/**
* 查询卡车信息列表
*/
@PreAuthorize("@ss.hasPermi('emis:emisTmsCar:list')")
@GetMapping("/list")
public TableDataInfo list(EmisTmsCar emisTmsCar)
{
startPage();
List<EmisTmsCar> list = emisTmsCarService.selectEmisTmsCarList(emisTmsCar);
return getDataTable(list);
}
/**
* 检查是否重复
*
* @param emisTmsCar
* @return 数量
*/
@PreAuthorize("@ss.hasPermi('emis:emisTmsCar:list')")
@GetMapping("/checkUnique")
public AjaxResult checkUnique(EmisTmsCar emisTmsCar)
{
int cnt=emisTmsCarService.checkUnique(emisTmsCar);
return AjaxResult.success("检查成功",cnt);
}
/**
* 导出卡车信息列表
*/
@PreAuthorize("@ss.hasPermi('emis:emisTmsCar:export')")
@Log(title = "卡车信息", businessType = BusinessType.EXPORT)
@PostMapping("/export")
public void export(HttpServletResponse response, EmisTmsCar emisTmsCar)
{
List<EmisTmsCar> list = emisTmsCarService.selectEmisTmsCarList(emisTmsCar);
ExcelUtil<EmisTmsCar> util = new ExcelUtil<EmisTmsCar>(EmisTmsCar.class);
util.exportExcel(response, list, "卡车信息数据");
}
/**
* 获取卡车信息详细信息
*/
@PreAuthorize("@ss.hasPermi('emis:emisTmsCar:query')")
@GetMapping(value = "/{id}")
public AjaxResult getInfo(@PathVariable("id") Long id)
{
return AjaxResult.success(emisTmsCarService.selectEmisTmsCarById(id));
}
/**
* 新增卡车信息
*/
@PreAuthorize("@ss.hasPermi('emis:emisTmsCar:add')")
@Log(title = "卡车信息", businessType = BusinessType.INSERT)
@PostMapping
public AjaxResult add(@RequestBody EmisTmsCar emisTmsCar)
{
return toAjax(emisTmsCarService.insertEmisTmsCar(emisTmsCar));
}
/**
* 修改卡车信息
*/
@PreAuthorize("@ss.hasPermi('emis:emisTmsCar:edit')")
@Log(title = "卡车信息", businessType = BusinessType.UPDATE)
@PutMapping
public AjaxResult edit(@RequestBody EmisTmsCar emisTmsCar)
{
return toAjax(emisTmsCarService.updateEmisTmsCar(emisTmsCar));
}
/**
* 删除卡车信息
*/
@PreAuthorize("@ss.hasPermi('emis:emisTmsCar:remove')")
@Log(title = "卡车信息", businessType = BusinessType.DELETE)
@DeleteMapping("/{ids}")
public AjaxResult remove(@PathVariable Long[] ids)
{
return toAjax(emisTmsCarService.deleteEmisTmsCarByIds(ids));
}
}

View File

@ -0,0 +1,134 @@
/**
* @Project: emis
* @Title: EmisTmsDriverController.java
* @author linfso
* @date 2024-06-13 22:00:26
* @Copyright: ShangHai Duta 2022 All rights reserved.
* @version v1.0
* @Description: <p> 司机 控制器 </p>
*/
package com.xdadan.erp.web.emis;
import java.util.List;
import javax.servlet.http.HttpServletResponse;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.security.access.prepost.PreAuthorize;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.PutMapping;
import org.springframework.web.bind.annotation.DeleteMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import com.xdadan.erp.common.annotation.Log;
import com.xdadan.erp.common.core.controller.BaseController;
import com.xdadan.erp.common.core.domain.AjaxResult;
import com.xdadan.erp.common.core.page.TableDataInfo;
import com.xdadan.erp.common.enums.BusinessType;
import com.xdadan.erp.common.utils.StringUtils;
import com.xdadan.erp.common.utils.poi.ExcelUtil;
import com.xdadan.erp.emis.domain.EmisTmsDriver;
import com.xdadan.erp.emis.service.IEmisTmsDriverService;
/**
* 司机Controller
*
* @author linfso
* @date 2024-06-13 22:00:26
*/
@RestController
@RequestMapping("/emis/emisTmsDriver")
public class EmisTmsDriverController extends BaseController
{
@Autowired
private IEmisTmsDriverService emisTmsDriverService;
/**
* 查询司机列表
*/
@PreAuthorize("@ss.hasPermi('emis:emisTmsDriver:list')")
@GetMapping("/list")
public TableDataInfo list(EmisTmsDriver emisTmsDriver)
{
startPage();
List<EmisTmsDriver> list = emisTmsDriverService.selectEmisTmsDriverList(emisTmsDriver);
return getDataTable(list);
}
/**
* 检查是否重复
*
* @param emisTmsDriver
* @return 数量
*/
@PreAuthorize("@ss.hasPermi('emis:emisTmsDriver:list')")
@GetMapping("/checkUnique")
public AjaxResult checkUnique(EmisTmsDriver emisTmsDriver)
{
int cnt=emisTmsDriverService.checkUnique(emisTmsDriver);
return AjaxResult.success("检查成功",cnt);
}
/**
* 导出司机列表
*/
@PreAuthorize("@ss.hasPermi('emis:emisTmsDriver:export')")
@Log(title = "司机", businessType = BusinessType.EXPORT)
@PostMapping("/export")
public void export(HttpServletResponse response, EmisTmsDriver emisTmsDriver)
{
List<EmisTmsDriver> list = emisTmsDriverService.selectEmisTmsDriverList(emisTmsDriver);
ExcelUtil<EmisTmsDriver> util = new ExcelUtil<EmisTmsDriver>(EmisTmsDriver.class);
util.exportExcel(response, list, "司机数据");
}
/**
* 获取司机详细信息
*/
@PreAuthorize("@ss.hasPermi('emis:emisTmsDriver:query')")
@GetMapping(value = "/{id}")
public AjaxResult getInfo(@PathVariable("id") Long id)
{
return AjaxResult.success(emisTmsDriverService.selectEmisTmsDriverById(id));
}
/**
* 新增司机
*/
@PreAuthorize("@ss.hasPermi('emis:emisTmsDriver:add')")
@Log(title = "司机", businessType = BusinessType.INSERT)
@PostMapping
public AjaxResult add(@RequestBody EmisTmsDriver emisTmsDriver)
{
return toAjax(emisTmsDriverService.insertEmisTmsDriver(emisTmsDriver));
}
/**
* 修改司机
*/
@PreAuthorize("@ss.hasPermi('emis:emisTmsDriver:edit')")
@Log(title = "司机", businessType = BusinessType.UPDATE)
@PutMapping
public AjaxResult edit(@RequestBody EmisTmsDriver emisTmsDriver)
{
return toAjax(emisTmsDriverService.updateEmisTmsDriver(emisTmsDriver));
}
/**
* 删除司机
*/
@PreAuthorize("@ss.hasPermi('emis:emisTmsDriver:remove')")
@Log(title = "司机", businessType = BusinessType.DELETE)
@DeleteMapping("/{ids}")
public AjaxResult remove(@PathVariable Long[] ids)
{
return toAjax(emisTmsDriverService.deleteEmisTmsDriverByIds(ids));
}
}

View File

@ -0,0 +1,81 @@
/**
* @Project: emis
* @Title: EmisTmsCar.java
* @author linfso
* @date 2024-06-13 22:00:25
* @Copyright: ShangHai Duta 2022 All rights reserved.
* @version v1.0
* @Description: <p> 卡车信息 实体类 </p>
*/
package com.xdadan.erp.emis.domain;
import com.fasterxml.jackson.annotation.JsonFormat;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.xdadan.erp.common.annotation.Excel;
import com.xdadan.erp.common.core.domain.BaseEntity;
import com.xdadan.erp.common.core.domain.TreeEntity;
import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;
import lombok.Data;
/**
* @ClassName EmisTmsCar
* @Description 卡车信息
* @author linfso
* @date 2024-06-13 22:00:25
*/
@Data
public class EmisTmsCar extends BaseEntity
{
private static final long serialVersionUID = 1L;
/* id */
private Long id;
/* 车牌号 */
private String carNo;
/* 品牌 */
private String carBrand;
/* 车身色 */
private String carBodyColor;
/* 车牌颜色 */
private String carPlateColor;
/* 车辆归属用途 */
private String carBelong;
/* 燃料类型 */
private String fuelType;
/* 额定百公里油耗 */
private BigDecimal oilWear;
/* 油卡号 */
private String oilCard;
/* 司机编号 */
private String driverCode;
/* 司机名称 */
private String driverName;
/* 车辆类型 */
private String carType;
/* 额定重 */
private Long ratedWeight;
/* 额定体积 */
private Long ratedVolume;
/* 额定载人 */
private Long ratedManned;
/* 车厢长 */
private BigDecimal carriageLong;
/* 车厢宽 */
private BigDecimal carriageWidth;
/* 车厢高 */
private BigDecimal carriageHigh;
/* 车厢重 */
private BigDecimal carriageWeight;
/* 是否有效 1-有效 */
private String blValid;
/* 显示顺序 */
private Integer orderNum;
/* 所属国家 */
private String country;
}

View File

@ -0,0 +1,90 @@
/**
* @Project: emis
* @Title: EmisTmsDriver.java
* @author linfso
* @date 2024-06-13 22:00:26
* @Copyright: ShangHai Duta 2022 All rights reserved.
* @version v1.0
* @Description: <p> 司机 实体类 </p>
*/
package com.xdadan.erp.emis.domain;
import com.fasterxml.jackson.annotation.JsonFormat;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.xdadan.erp.common.annotation.Excel;
import com.xdadan.erp.common.core.domain.BaseEntity;
import com.xdadan.erp.common.core.domain.TreeEntity;
import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;
import lombok.Data;
/**
* @ClassName EmisTmsDriver
* @Description 司机
* @author linfso
* @date 2024-06-13 22:00:26
*/
@Data
public class EmisTmsDriver extends BaseEntity
{
private static final long serialVersionUID = 1L;
/* id */
private Long id;
/* 司机名 */
private String driverName;
/* 所属国家 */
private String country;
/* 婚姻状态 */
private String maritalStatus;
/* 生日 */
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
private Date birthDate;
/* 健康状态 */
private String healthStatus;
/* 教育背景 */
private String eduBack;
/* 身高 */
private String height;
/* 体重 */
private String weight;
/* 政治面貌 */
private String politicsStatus;
/* 所属网点 */
private String ownerSiteCode;
/* 司机类型 */
private String driverOwnerType;
/* 证件类型 */
private String idType;
/* 证件号 */
private String idNo;
/* 工号 */
private String empNo;
/* 驾龄 */
private String drivingYears;
/* 是否启用1-启用 */
private String blStatus;
/* 是否服兵役 1-是 */
private String blMilitaryService;
/* 电话号码 */
private String driverPhone;
/* 从业证号 */
private String driverCod;
/* 1档票数 */
private String firstNum;
/* 2档票数 */
private String secondNum;
/* 入职日期 */
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
private Date entryTime;
/* 登记日期 */
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
private Date registerDate;
/* 显示顺序 */
private Integer orderNum;
}

View File

@ -0,0 +1,80 @@
/**
* @Project: emis
* @Title: EmisTmsCarMapper.java
* @author linfso
* @date 2024-06-13 22:00:25
* @Copyright: ShangHai Doitinfo 2022 All rights reserved.
* @version v1.0
* @Description: <p> 卡车信息 Mapper 接口 </p>
* <span style='color:red'> Warning : This file is generate by ai tools,don't edit!!! </span>
*/
package com.xdadan.erp.emis.mapper;
import java.util.List;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.xdadan.erp.emis.domain.EmisTmsCar;
/**
* @ClassName EmisTmsCarMapper
* @Description <p> 卡车信息 Mapper 接口 </p>
* @author linfso
* @date 2024-06-13 22:00:25
*/
public interface EmisTmsCarMapper extends BaseMapper<EmisTmsCar>
{
/**
* 主键查询
* @param id
* @return
*/
public EmisTmsCar selectEmisTmsCarById(Long id);
/**
* 查询列表
*
* @param emisTmsCar
* @return 集合
*/
public List<EmisTmsCar> selectEmisTmsCarList(EmisTmsCar emisTmsCar);
/**
* 检查是否重复
*
* @param emisTmsCar
* @return 数量
*/
public int checkUnique(EmisTmsCar emisTmsCar);
/**
* 新增
*
* @param emisTmsCar
* @return
*/
public int insertEmisTmsCar(EmisTmsCar emisTmsCar);
/**
* 修改
*
* @param emisTmsCar
* @return
*/
public int updateEmisTmsCar(EmisTmsCar emisTmsCar);
/**
* 删除
*
* @param id 主键
* @return 结果
*/
public int deleteEmisTmsCarById(Long id);
/**
* 批量删除
*
* @param ids 需要删除的数据主键集合
* @return 结果
*/
public int deleteEmisTmsCarByIds(Long[] ids);
}

View File

@ -0,0 +1,80 @@
/**
* @Project: emis
* @Title: EmisTmsDriverMapper.java
* @author linfso
* @date 2024-06-13 22:00:26
* @Copyright: ShangHai Doitinfo 2022 All rights reserved.
* @version v1.0
* @Description: <p> 司机 Mapper 接口 </p>
* <span style='color:red'> Warning : This file is generate by ai tools,don't edit!!! </span>
*/
package com.xdadan.erp.emis.mapper;
import java.util.List;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.xdadan.erp.emis.domain.EmisTmsDriver;
/**
* @ClassName EmisTmsDriverMapper
* @Description <p> 司机 Mapper 接口 </p>
* @author linfso
* @date 2024-06-13 22:00:26
*/
public interface EmisTmsDriverMapper extends BaseMapper<EmisTmsDriver>
{
/**
* 主键查询
* @param id
* @return
*/
public EmisTmsDriver selectEmisTmsDriverById(Long id);
/**
* 查询列表
*
* @param emisTmsDriver
* @return 集合
*/
public List<EmisTmsDriver> selectEmisTmsDriverList(EmisTmsDriver emisTmsDriver);
/**
* 检查是否重复
*
* @param emisTmsDriver
* @return 数量
*/
public int checkUnique(EmisTmsDriver emisTmsDriver);
/**
* 新增
*
* @param emisTmsDriver
* @return
*/
public int insertEmisTmsDriver(EmisTmsDriver emisTmsDriver);
/**
* 修改
*
* @param emisTmsDriver
* @return
*/
public int updateEmisTmsDriver(EmisTmsDriver emisTmsDriver);
/**
* 删除
*
* @param id 主键
* @return 结果
*/
public int deleteEmisTmsDriverById(Long id);
/**
* 批量删除
*
* @param ids 需要删除的数据主键集合
* @return 结果
*/
public int deleteEmisTmsDriverByIds(Long[] ids);
}

View File

@ -0,0 +1,78 @@
/**
* @Project: emis
* @Title: EmisTmsCarService.java
* @author linfso
* @date 2024-06-13 22:00:25
* @Copyright: ShangHai Duta 2022 All rights reserved.
* @version v1.0
* @Description: <p> 卡车信息 服务类接口 </p>
*/
package com.xdadan.erp.emis.service;
import java.util.List;
import com.xdadan.erp.emis.domain.EmisTmsCar;
/**
* @ClassName EmisTmsCarService
* @Description 卡车信息
* @author linfso
* @date 2024-06-13 22:00:25
*/
public interface IEmisTmsCarService
{
/**
* 主键查询
* @param id
* @return
*/
public EmisTmsCar selectEmisTmsCarById(Long id);
/**
* 查询卡车信息列表
*
* @param emisTmsCar 卡车信息
* @return 卡车信息集合
*/
public List<EmisTmsCar> selectEmisTmsCarList(EmisTmsCar emisTmsCar);
/**
* 检查是否重复
*
* @param emisTmsCar
* @return 数量
*/
public int checkUnique(EmisTmsCar emisTmsCar);
/**
* 新增卡车信息
*
* @param emisTmsCar 卡车信息
* @return 结果
*/
public int insertEmisTmsCar(EmisTmsCar emisTmsCar);
/**
* 修改卡车信息
*
* @param emisTmsCar 卡车信息
* @return 结果
*/
public int updateEmisTmsCar(EmisTmsCar emisTmsCar);
/**
* 批量删除卡车信息
*
* @param ids 需要删除的卡车信息主键集合
* @return 结果
*/
public int deleteEmisTmsCarByIds(Long[] ids);
/**
* 删除卡车信息信息
*
* @param id 卡车信息主键
* @return 结果
*/
public int deleteEmisTmsCarById(Long id);
}

View File

@ -0,0 +1,78 @@
/**
* @Project: emis
* @Title: EmisTmsDriverService.java
* @author linfso
* @date 2024-06-13 22:00:26
* @Copyright: ShangHai Duta 2022 All rights reserved.
* @version v1.0
* @Description: <p> 司机 服务类接口 </p>
*/
package com.xdadan.erp.emis.service;
import java.util.List;
import com.xdadan.erp.emis.domain.EmisTmsDriver;
/**
* @ClassName EmisTmsDriverService
* @Description 司机
* @author linfso
* @date 2024-06-13 22:00:26
*/
public interface IEmisTmsDriverService
{
/**
* 主键查询
* @param id
* @return
*/
public EmisTmsDriver selectEmisTmsDriverById(Long id);
/**
* 查询司机列表
*
* @param emisTmsDriver 司机
* @return 司机集合
*/
public List<EmisTmsDriver> selectEmisTmsDriverList(EmisTmsDriver emisTmsDriver);
/**
* 检查是否重复
*
* @param emisTmsDriver
* @return 数量
*/
public int checkUnique(EmisTmsDriver emisTmsDriver);
/**
* 新增司机
*
* @param emisTmsDriver 司机
* @return 结果
*/
public int insertEmisTmsDriver(EmisTmsDriver emisTmsDriver);
/**
* 修改司机
*
* @param emisTmsDriver 司机
* @return 结果
*/
public int updateEmisTmsDriver(EmisTmsDriver emisTmsDriver);
/**
* 批量删除司机
*
* @param ids 需要删除的司机主键集合
* @return 结果
*/
public int deleteEmisTmsDriverByIds(Long[] ids);
/**
* 删除司机信息
*
* @param id 司机主键
* @return 结果
*/
public int deleteEmisTmsDriverById(Long id);
}

View File

@ -0,0 +1,117 @@
/**
* @Project: emis
* @Title: EmisTmsCarServiceImpl.java
* @author linfso
* @date 2024-06-13 22:00:25
* @Copyright: ShangHai Duta 2022 All rights reserved.
* @version v1.0
* @Description: <p> 卡车信息 实体类 </p>
*/
package com.xdadan.erp.emis.service.impl;
import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.xdadan.erp.emis.domain.EmisTmsCar;
import com.xdadan.erp.emis.mapper.EmisTmsCarMapper;
import com.xdadan.erp.emis.service.IEmisTmsCarService;
/**
* 卡车信息Service业务层处理
*
* @author linfso
* @date 2024-06-13 22:00:25
*/
@Service
public class EmisTmsCarServiceImpl implements IEmisTmsCarService
{
@Autowired
private EmisTmsCarMapper emisTmsCarMapper;
/**
* 查询卡车信息
*
* @param id 卡车信息主键
* @return 卡车信息
*/
@Override
public EmisTmsCar selectEmisTmsCarById(Long id)
{
return emisTmsCarMapper.selectEmisTmsCarById(id);
}
/**
* 查询卡车信息列表
*
* @param emisTmsCar 卡车信息
* @return 卡车信息
*/
@Override
public List<EmisTmsCar> selectEmisTmsCarList(EmisTmsCar emisTmsCar)
{
return emisTmsCarMapper.selectEmisTmsCarList(emisTmsCar);
}
/**
* 检查是否重复
*
* @param emisTmsCar
* @return 数量
*/
@Override
public int checkUnique(EmisTmsCar emisTmsCar)
{
return emisTmsCarMapper.checkUnique(emisTmsCar);
}
/**
* 新增卡车信息
*
* @param emisTmsCar 卡车信息
* @return 结果
*/
@Override
public int insertEmisTmsCar(EmisTmsCar emisTmsCar)
{
return emisTmsCarMapper.insertEmisTmsCar(emisTmsCar);
}
/**
* 修改卡车信息
*
* @param emisTmsCar 卡车信息
* @return 结果
*/
@Override
public int updateEmisTmsCar(EmisTmsCar emisTmsCar)
{
return emisTmsCarMapper.updateEmisTmsCar(emisTmsCar);
}
/**
* 批量删除卡车信息
*
* @param ids 需要删除的卡车信息主键
* @return 结果
*/
@Override
public int deleteEmisTmsCarByIds(Long[] ids)
{
return emisTmsCarMapper.deleteEmisTmsCarByIds(ids);
}
/**
* 删除卡车信息信息
*
* @param id 卡车信息主键
* @return 结果
*/
@Override
public int deleteEmisTmsCarById(Long id)
{
return emisTmsCarMapper.deleteEmisTmsCarById(id);
}
}

View File

@ -0,0 +1,117 @@
/**
* @Project: emis
* @Title: EmisTmsDriverServiceImpl.java
* @author linfso
* @date 2024-06-13 22:00:26
* @Copyright: ShangHai Duta 2022 All rights reserved.
* @version v1.0
* @Description: <p> 司机 实体类 </p>
*/
package com.xdadan.erp.emis.service.impl;
import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.xdadan.erp.emis.domain.EmisTmsDriver;
import com.xdadan.erp.emis.mapper.EmisTmsDriverMapper;
import com.xdadan.erp.emis.service.IEmisTmsDriverService;
/**
* 司机Service业务层处理
*
* @author linfso
* @date 2024-06-13 22:00:26
*/
@Service
public class EmisTmsDriverServiceImpl implements IEmisTmsDriverService
{
@Autowired
private EmisTmsDriverMapper emisTmsDriverMapper;
/**
* 查询司机
*
* @param id 司机主键
* @return 司机
*/
@Override
public EmisTmsDriver selectEmisTmsDriverById(Long id)
{
return emisTmsDriverMapper.selectEmisTmsDriverById(id);
}
/**
* 查询司机列表
*
* @param emisTmsDriver 司机
* @return 司机
*/
@Override
public List<EmisTmsDriver> selectEmisTmsDriverList(EmisTmsDriver emisTmsDriver)
{
return emisTmsDriverMapper.selectEmisTmsDriverList(emisTmsDriver);
}
/**
* 检查是否重复
*
* @param emisTmsDriver
* @return 数量
*/
@Override
public int checkUnique(EmisTmsDriver emisTmsDriver)
{
return emisTmsDriverMapper.checkUnique(emisTmsDriver);
}
/**
* 新增司机
*
* @param emisTmsDriver 司机
* @return 结果
*/
@Override
public int insertEmisTmsDriver(EmisTmsDriver emisTmsDriver)
{
return emisTmsDriverMapper.insertEmisTmsDriver(emisTmsDriver);
}
/**
* 修改司机
*
* @param emisTmsDriver 司机
* @return 结果
*/
@Override
public int updateEmisTmsDriver(EmisTmsDriver emisTmsDriver)
{
return emisTmsDriverMapper.updateEmisTmsDriver(emisTmsDriver);
}
/**
* 批量删除司机
*
* @param ids 需要删除的司机主键
* @return 结果
*/
@Override
public int deleteEmisTmsDriverByIds(Long[] ids)
{
return emisTmsDriverMapper.deleteEmisTmsDriverByIds(ids);
}
/**
* 删除司机信息
*
* @param id 司机主键
* @return 结果
*/
@Override
public int deleteEmisTmsDriverById(Long id)
{
return emisTmsDriverMapper.deleteEmisTmsDriverById(id);
}
}

View File

@ -0,0 +1,235 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.xdadan.erp.emis.mapper.EmisTmsCarMapper">
<resultMap type="EmisTmsCar" id="EmisTmsCarResult">
<result property="id" column="id" />
<result property="carNo" column="car_no" />
<result property="carBrand" column="car_brand" />
<result property="carBodyColor" column="car_body_color" />
<result property="carPlateColor" column="car_plate_color" />
<result property="carBelong" column="car_belong" />
<result property="fuelType" column="fuel_type" />
<result property="oilWear" column="oil_wear" />
<result property="oilCard" column="oil_card" />
<result property="driverCode" column="driver_code" />
<result property="driverName" column="driver_name" />
<result property="carType" column="car_type" />
<result property="ratedWeight" column="rated_weight" />
<result property="ratedVolume" column="rated_volume" />
<result property="ratedManned" column="rated_manned" />
<result property="carriageLong" column="carriage_long" />
<result property="carriageWidth" column="carriage_width" />
<result property="carriageHigh" column="carriage_high" />
<result property="carriageWeight" column="carriage_weight" />
<result property="blValid" column="bl_valid" />
<result property="orderNum" column="order_num" />
<result property="country" column="country" />
</resultMap>
<sql id="selectEmisTmsCarVo">
select id, car_no, car_brand, car_body_color, car_plate_color, car_belong, fuel_type, oil_wear, oil_card, driver_code, driver_name, car_type, rated_weight, rated_volume, rated_manned, carriage_long, carriage_width, carriage_high, carriage_weight, bl_valid, order_num, remark, tenant_id, del_flag, create_by, create_time, update_by, update_time, create_site, update_site, country from emis_tms_car
</sql>
<select id="selectEmisTmsCarList" parameterType="EmisTmsCar" resultMap="EmisTmsCarResult">
<include refid="selectEmisTmsCarVo"/>
<where>
del_flag='0'
<if test="id != null "> and id = #{id}</if>
<if test="carNo != null and carNo != ''"> and car_no like concat('%', #{carNo}, '%')</if>
<if test="carBrand != null and carBrand != ''"> and car_brand like concat('%', #{carBrand}, '%')</if>
<if test="carBodyColor != null and carBodyColor != ''"> and car_body_color like concat('%', #{carBodyColor}, '%')</if>
<if test="carPlateColor != null and carPlateColor != ''"> and car_plate_color like concat('%', #{carPlateColor}, '%')</if>
<if test="carBelong != null and carBelong != ''"> and car_belong like concat('%', #{carBelong}, '%')</if>
<if test="fuelType != null and fuelType != ''"> and fuel_type like concat('%', #{fuelType}, '%')</if>
<if test="oilWear != null "> and oil_wear = #{oilWear}</if>
<if test="oilCard != null and oilCard != ''"> and oil_card like concat('%', #{oilCard}, '%')</if>
<if test="driverCode != null and driverCode != ''"> and driver_code like concat('%', #{driverCode}, '%')</if>
<if test="driverName != null and driverName != ''"> and driver_name like concat('%', #{driverName}, '%')</if>
<if test="carType != null and carType != ''"> and car_type like concat('%', #{carType}, '%')</if>
<if test="ratedWeight != null "> and rated_weight = #{ratedWeight}</if>
<if test="ratedVolume != null "> and rated_volume = #{ratedVolume}</if>
<if test="ratedManned != null "> and rated_manned = #{ratedManned}</if>
<if test="carriageLong != null "> and carriage_long = #{carriageLong}</if>
<if test="carriageWidth != null "> and carriage_width = #{carriageWidth}</if>
<if test="carriageHigh != null "> and carriage_high = #{carriageHigh}</if>
<if test="carriageWeight != null "> and carriage_weight = #{carriageWeight}</if>
<if test="blValid != null and blValid != ''"> and bl_valid like concat('%', #{blValid}, '%')</if>
<if test="orderNum != null "> and order_num = #{orderNum}</if>
<if test="remark != null and remark != ''"> and remark like concat('%', #{remark}, '%')</if>
<if test="tenantId != null and tenantId != ''"> and tenant_id like concat('%', #{tenantId}, '%')</if>
<if test="delFlag != null and delFlag != ''"> and del_flag like concat('%', #{delFlag}, '%')</if>
<if test="createBy != null and createBy != ''"> and create_by like concat('%', #{createBy}, '%')</if>
<if test="createTime != null "> and create_time = #{createTime}</if>
<if test="updateBy != null and updateBy != ''"> and update_by like concat('%', #{updateBy}, '%')</if>
<if test="updateTime != null "> and update_time = #{updateTime}</if>
<if test="createSite != null and createSite != ''"> and create_site like concat('%', #{createSite}, '%')</if>
<if test="updateSite != null and updateSite != ''"> and update_site like concat('%', #{updateSite}, '%')</if>
<if test="country != null and country != ''"> and country like concat('%', #{country}, '%')</if>
</where>
order by create_time desc
</select>
<select id="checkUnique" parameterType="EmisTmsCar" resultType="int">
select count(1) from emis_tms_car
where del_flag='0'
and id = #{id}
and car_no = #{carNo}
and car_brand = #{carBrand}
and car_body_color = #{carBodyColor}
and car_plate_color = #{carPlateColor}
and car_belong = #{carBelong}
and fuel_type = #{fuelType}
and oil_wear = #{oilWear}
and oil_card = #{oilCard}
and driver_code = #{driverCode}
and driver_name = #{driverName}
and car_type = #{carType}
and rated_weight = #{ratedWeight}
and rated_volume = #{ratedVolume}
and rated_manned = #{ratedManned}
and carriage_long = #{carriageLong}
and carriage_width = #{carriageWidth}
and carriage_high = #{carriageHigh}
and carriage_weight = #{carriageWeight}
and bl_valid = #{blValid}
and order_num = #{orderNum}
and remark = #{remark}
and tenant_id = #{tenantId}
and del_flag = #{delFlag}
and create_by = #{createBy}
and create_time = #{createTime}
and update_by = #{updateBy}
and update_time = #{updateTime}
and create_site = #{createSite}
and update_site = #{updateSite}
and country = #{country}
limit 1
</select>
<select id="selectEmisTmsCarById" parameterType="Long" resultMap="EmisTmsCarResult">
select id, car_no, car_brand, car_body_color, car_plate_color, car_belong, fuel_type, oil_wear, oil_card, driver_code, driver_name, car_type, rated_weight, rated_volume, rated_manned, carriage_long, carriage_width, carriage_high, carriage_weight, bl_valid, order_num, remark, tenant_id, del_flag, create_by, create_time, update_by, update_time, create_site, update_site, country
from emis_tms_car a
where a.id = #{id}
</select>
<insert id="insertEmisTmsCar" parameterType="EmisTmsCar" useGeneratedKeys="true" keyProperty="id">
insert into emis_tms_car
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="id != null">id,</if>
<if test="carNo != null and carNo != ''">car_no,</if>
<if test="carBrand != null and carBrand != ''">car_brand,</if>
<if test="carBodyColor != null and carBodyColor != ''">car_body_color,</if>
<if test="carPlateColor != null and carPlateColor != ''">car_plate_color,</if>
<if test="carBelong != null and carBelong != ''">car_belong,</if>
<if test="fuelType != null and fuelType != ''">fuel_type,</if>
<if test="oilWear != null">oil_wear,</if>
<if test="oilCard != null and oilCard != ''">oil_card,</if>
<if test="driverCode != null and driverCode != ''">driver_code,</if>
<if test="driverName != null and driverName != ''">driver_name,</if>
<if test="carType != null and carType != ''">car_type,</if>
<if test="ratedWeight != null">rated_weight,</if>
<if test="ratedVolume != null">rated_volume,</if>
<if test="ratedManned != null">rated_manned,</if>
<if test="carriageLong != null">carriage_long,</if>
<if test="carriageWidth != null">carriage_width,</if>
<if test="carriageHigh != null">carriage_high,</if>
<if test="carriageWeight != null">carriage_weight,</if>
<if test="blValid != null and blValid != ''">bl_valid,</if>
<if test="orderNum != null">order_num,</if>
<if test="remark != null and remark != ''">remark,</if>
<if test="tenantId != null and tenantId != ''">tenant_id,</if>
<if test="delFlag != null and delFlag != ''">del_flag,</if>
<if test="createBy != null and createBy != ''">create_by,</if>
<if test="createTime != null">create_time,</if>
<if test="updateBy != null and updateBy != ''">update_by,</if>
<if test="updateTime != null">update_time,</if>
<if test="createSite != null and createSite != ''">create_site,</if>
<if test="updateSite != null and updateSite != ''">update_site,</if>
<if test="country != null and country != ''">country,</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="id != null">#{id},</if>
<if test="carNo != null and carNo != ''">#{carNo},</if>
<if test="carBrand != null and carBrand != ''">#{carBrand},</if>
<if test="carBodyColor != null and carBodyColor != ''">#{carBodyColor},</if>
<if test="carPlateColor != null and carPlateColor != ''">#{carPlateColor},</if>
<if test="carBelong != null and carBelong != ''">#{carBelong},</if>
<if test="fuelType != null and fuelType != ''">#{fuelType},</if>
<if test="oilWear != null">#{oilWear},</if>
<if test="oilCard != null and oilCard != ''">#{oilCard},</if>
<if test="driverCode != null and driverCode != ''">#{driverCode},</if>
<if test="driverName != null and driverName != ''">#{driverName},</if>
<if test="carType != null and carType != ''">#{carType},</if>
<if test="ratedWeight != null">#{ratedWeight},</if>
<if test="ratedVolume != null">#{ratedVolume},</if>
<if test="ratedManned != null">#{ratedManned},</if>
<if test="carriageLong != null">#{carriageLong},</if>
<if test="carriageWidth != null">#{carriageWidth},</if>
<if test="carriageHigh != null">#{carriageHigh},</if>
<if test="carriageWeight != null">#{carriageWeight},</if>
<if test="blValid != null and blValid != ''">#{blValid},</if>
<if test="orderNum != null">#{orderNum},</if>
<if test="remark != null and remark != ''">#{remark},</if>
<if test="tenantId != null and tenantId != ''">#{tenantId},</if>
<if test="delFlag != null and delFlag != ''">#{delFlag},</if>
<if test="createBy != null and createBy != ''">#{createBy},</if>
<if test="createTime != null">#{createTime},</if>
<if test="updateBy != null and updateBy != ''">#{updateBy},</if>
<if test="updateTime != null">#{updateTime},</if>
<if test="createSite != null and createSite != ''">#{createSite},</if>
<if test="updateSite != null and updateSite != ''">#{updateSite},</if>
<if test="country != null and country != ''">#{country},</if>
</trim>
</insert>
<update id="updateEmisTmsCar" parameterType="EmisTmsCar">
update emis_tms_car
<trim prefix="SET" suffixOverrides=",">
<if test="carNo != null and carNo != ''">car_no = #{carNo},</if>
<if test="carBrand != null and carBrand != ''">car_brand = #{carBrand},</if>
<if test="carBodyColor != null and carBodyColor != ''">car_body_color = #{carBodyColor},</if>
<if test="carPlateColor != null and carPlateColor != ''">car_plate_color = #{carPlateColor},</if>
<if test="carBelong != null and carBelong != ''">car_belong = #{carBelong},</if>
<if test="fuelType != null and fuelType != ''">fuel_type = #{fuelType},</if>
<if test="oilWear != null">oil_wear = #{oilWear},</if>
<if test="oilCard != null and oilCard != ''">oil_card = #{oilCard},</if>
<if test="driverCode != null and driverCode != ''">driver_code = #{driverCode},</if>
<if test="driverName != null and driverName != ''">driver_name = #{driverName},</if>
<if test="carType != null and carType != ''">car_type = #{carType},</if>
<if test="ratedWeight != null">rated_weight = #{ratedWeight},</if>
<if test="ratedVolume != null">rated_volume = #{ratedVolume},</if>
<if test="ratedManned != null">rated_manned = #{ratedManned},</if>
<if test="carriageLong != null">carriage_long = #{carriageLong},</if>
<if test="carriageWidth != null">carriage_width = #{carriageWidth},</if>
<if test="carriageHigh != null">carriage_high = #{carriageHigh},</if>
<if test="carriageWeight != null">carriage_weight = #{carriageWeight},</if>
<if test="blValid != null and blValid != ''">bl_valid = #{blValid},</if>
<if test="orderNum != null">order_num = #{orderNum},</if>
<if test="remark != null and remark != ''">remark = #{remark},</if>
<if test="tenantId != null and tenantId != ''">tenant_id = #{tenantId},</if>
<if test="delFlag != null and delFlag != ''">del_flag = #{delFlag},</if>
<if test="createBy != null and createBy != ''">create_by = #{createBy},</if>
<if test="createTime != null">create_time = #{createTime},</if>
<if test="updateBy != null and updateBy != ''">update_by = #{updateBy},</if>
<if test="updateTime != null">update_time = #{updateTime},</if>
<if test="createSite != null and createSite != ''">create_site = #{createSite},</if>
<if test="updateSite != null and updateSite != ''">update_site = #{updateSite},</if>
<if test="country != null and country != ''">country = #{country},</if>
</trim>
where id = #{id}
</update>
<delete id="deleteEmisTmsCarById" parameterType="Long">
delete from emis_tms_car where id = #{id}
</delete>
<delete id="deleteEmisTmsCarByIds" parameterType="String">
delete from emis_tms_car where id in
<foreach item="id" collection="array" open="(" separator="," close=")">
#{id}
</foreach>
</delete>
</mapper>

View File

@ -0,0 +1,253 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.xdadan.erp.emis.mapper.EmisTmsDriverMapper">
<resultMap type="EmisTmsDriver" id="EmisTmsDriverResult">
<result property="id" column="id" />
<result property="driverName" column="driver_name" />
<result property="country" column="country" />
<result property="maritalStatus" column="marital_status" />
<result property="birthDate" column="birth_date" />
<result property="healthStatus" column="health_status" />
<result property="eduBack" column="edu_back" />
<result property="height" column="height" />
<result property="weight" column="weight" />
<result property="politicsStatus" column="politics_status" />
<result property="ownerSiteCode" column="owner_site_code" />
<result property="driverOwnerType" column="driver_owner_type" />
<result property="idType" column="id_type" />
<result property="idNo" column="id_no" />
<result property="empNo" column="emp_no" />
<result property="drivingYears" column="driving_years" />
<result property="blStatus" column="bl_status" />
<result property="blMilitaryService" column="bl_military_service" />
<result property="driverPhone" column="driver_phone" />
<result property="driverCod" column="driver_cod" />
<result property="firstNum" column="first_num" />
<result property="secondNum" column="second_num" />
<result property="entryTime" column="entry_time" />
<result property="registerDate" column="register_date" />
<result property="orderNum" column="order_num" />
</resultMap>
<sql id="selectEmisTmsDriverVo">
select id, driver_name, country, marital_status, birth_date, health_status, edu_back, height, weight, politics_status, owner_site_code, driver_owner_type, id_type, id_no, emp_no, driving_years, bl_status, bl_military_service, driver_phone, driver_cod, first_num, second_num, entry_time, register_date, order_num, remark, tenant_id, del_flag, create_by, create_time, update_by, update_time, create_site, update_site from emis_tms_driver
</sql>
<select id="selectEmisTmsDriverList" parameterType="EmisTmsDriver" resultMap="EmisTmsDriverResult">
<include refid="selectEmisTmsDriverVo"/>
<where>
del_flag='0'
<if test="id != null "> and id = #{id}</if>
<if test="driverName != null and driverName != ''"> and driver_name like concat('%', #{driverName}, '%')</if>
<if test="country != null and country != ''"> and country like concat('%', #{country}, '%')</if>
<if test="maritalStatus != null and maritalStatus != ''"> and marital_status like concat('%', #{maritalStatus}, '%')</if>
<if test="birthDate != null "> and birth_date = #{birthDate}</if>
<if test="healthStatus != null and healthStatus != ''"> and health_status like concat('%', #{healthStatus}, '%')</if>
<if test="eduBack != null and eduBack != ''"> and edu_back like concat('%', #{eduBack}, '%')</if>
<if test="height != null and height != ''"> and height like concat('%', #{height}, '%')</if>
<if test="weight != null and weight != ''"> and weight like concat('%', #{weight}, '%')</if>
<if test="politicsStatus != null and politicsStatus != ''"> and politics_status like concat('%', #{politicsStatus}, '%')</if>
<if test="ownerSiteCode != null and ownerSiteCode != ''"> and owner_site_code like concat('%', #{ownerSiteCode}, '%')</if>
<if test="driverOwnerType != null and driverOwnerType != ''"> and driver_owner_type like concat('%', #{driverOwnerType}, '%')</if>
<if test="idType != null and idType != ''"> and id_type like concat('%', #{idType}, '%')</if>
<if test="idNo != null and idNo != ''"> and id_no like concat('%', #{idNo}, '%')</if>
<if test="empNo != null and empNo != ''"> and emp_no like concat('%', #{empNo}, '%')</if>
<if test="drivingYears != null and drivingYears != ''"> and driving_years like concat('%', #{drivingYears}, '%')</if>
<if test="blStatus != null and blStatus != ''"> and bl_status like concat('%', #{blStatus}, '%')</if>
<if test="blMilitaryService != null and blMilitaryService != ''"> and bl_military_service like concat('%', #{blMilitaryService}, '%')</if>
<if test="driverPhone != null and driverPhone != ''"> and driver_phone like concat('%', #{driverPhone}, '%')</if>
<if test="driverCod != null and driverCod != ''"> and driver_cod like concat('%', #{driverCod}, '%')</if>
<if test="firstNum != null and firstNum != ''"> and first_num like concat('%', #{firstNum}, '%')</if>
<if test="secondNum != null and secondNum != ''"> and second_num like concat('%', #{secondNum}, '%')</if>
<if test="entryTime != null "> and entry_time = #{entryTime}</if>
<if test="registerDate != null "> and register_date = #{registerDate}</if>
<if test="orderNum != null "> and order_num = #{orderNum}</if>
<if test="remark != null and remark != ''"> and remark like concat('%', #{remark}, '%')</if>
<if test="tenantId != null and tenantId != ''"> and tenant_id like concat('%', #{tenantId}, '%')</if>
<if test="delFlag != null and delFlag != ''"> and del_flag like concat('%', #{delFlag}, '%')</if>
<if test="createBy != null and createBy != ''"> and create_by like concat('%', #{createBy}, '%')</if>
<if test="createTime != null "> and create_time = #{createTime}</if>
<if test="updateBy != null and updateBy != ''"> and update_by like concat('%', #{updateBy}, '%')</if>
<if test="updateTime != null "> and update_time = #{updateTime}</if>
<if test="createSite != null and createSite != ''"> and create_site like concat('%', #{createSite}, '%')</if>
<if test="updateSite != null and updateSite != ''"> and update_site like concat('%', #{updateSite}, '%')</if>
</where>
order by create_time desc
</select>
<select id="checkUnique" parameterType="EmisTmsDriver" resultType="int">
select count(1) from emis_tms_driver
where del_flag='0'
and id = #{id}
and driver_name = #{driverName}
and country = #{country}
and marital_status = #{maritalStatus}
and birth_date = #{birthDate}
and health_status = #{healthStatus}
and edu_back = #{eduBack}
and height = #{height}
and weight = #{weight}
and politics_status = #{politicsStatus}
and owner_site_code = #{ownerSiteCode}
and driver_owner_type = #{driverOwnerType}
and id_type = #{idType}
and id_no = #{idNo}
and emp_no = #{empNo}
and driving_years = #{drivingYears}
and bl_status = #{blStatus}
and bl_military_service = #{blMilitaryService}
and driver_phone = #{driverPhone}
and driver_cod = #{driverCod}
and first_num = #{firstNum}
and second_num = #{secondNum}
and entry_time = #{entryTime}
and register_date = #{registerDate}
and order_num = #{orderNum}
and remark = #{remark}
and tenant_id = #{tenantId}
and del_flag = #{delFlag}
and create_by = #{createBy}
and create_time = #{createTime}
and update_by = #{updateBy}
and update_time = #{updateTime}
and create_site = #{createSite}
and update_site = #{updateSite}
limit 1
</select>
<select id="selectEmisTmsDriverById" parameterType="Long" resultMap="EmisTmsDriverResult">
select id, driver_name, country, marital_status, birth_date, health_status, edu_back, height, weight, politics_status, owner_site_code, driver_owner_type, id_type, id_no, emp_no, driving_years, bl_status, bl_military_service, driver_phone, driver_cod, first_num, second_num, entry_time, register_date, order_num, remark, tenant_id, del_flag, create_by, create_time, update_by, update_time, create_site, update_site
from emis_tms_driver a
where a.id = #{id}
</select>
<insert id="insertEmisTmsDriver" parameterType="EmisTmsDriver" useGeneratedKeys="true" keyProperty="id">
insert into emis_tms_driver
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="id != null">id,</if>
<if test="driverName != null and driverName != ''">driver_name,</if>
<if test="country != null and country != ''">country,</if>
<if test="maritalStatus != null and maritalStatus != ''">marital_status,</if>
<if test="birthDate != null">birth_date,</if>
<if test="healthStatus != null and healthStatus != ''">health_status,</if>
<if test="eduBack != null and eduBack != ''">edu_back,</if>
<if test="height != null and height != ''">height,</if>
<if test="weight != null and weight != ''">weight,</if>
<if test="politicsStatus != null and politicsStatus != ''">politics_status,</if>
<if test="ownerSiteCode != null and ownerSiteCode != ''">owner_site_code,</if>
<if test="driverOwnerType != null and driverOwnerType != ''">driver_owner_type,</if>
<if test="idType != null and idType != ''">id_type,</if>
<if test="idNo != null and idNo != ''">id_no,</if>
<if test="empNo != null and empNo != ''">emp_no,</if>
<if test="drivingYears != null and drivingYears != ''">driving_years,</if>
<if test="blStatus != null and blStatus != ''">bl_status,</if>
<if test="blMilitaryService != null and blMilitaryService != ''">bl_military_service,</if>
<if test="driverPhone != null and driverPhone != ''">driver_phone,</if>
<if test="driverCod != null and driverCod != ''">driver_cod,</if>
<if test="firstNum != null and firstNum != ''">first_num,</if>
<if test="secondNum != null and secondNum != ''">second_num,</if>
<if test="entryTime != null">entry_time,</if>
<if test="registerDate != null">register_date,</if>
<if test="orderNum != null">order_num,</if>
<if test="remark != null and remark != ''">remark,</if>
<if test="tenantId != null and tenantId != ''">tenant_id,</if>
<if test="delFlag != null and delFlag != ''">del_flag,</if>
<if test="createBy != null and createBy != ''">create_by,</if>
<if test="createTime != null">create_time,</if>
<if test="updateBy != null and updateBy != ''">update_by,</if>
<if test="updateTime != null">update_time,</if>
<if test="createSite != null and createSite != ''">create_site,</if>
<if test="updateSite != null and updateSite != ''">update_site,</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="id != null">#{id},</if>
<if test="driverName != null and driverName != ''">#{driverName},</if>
<if test="country != null and country != ''">#{country},</if>
<if test="maritalStatus != null and maritalStatus != ''">#{maritalStatus},</if>
<if test="birthDate != null">#{birthDate},</if>
<if test="healthStatus != null and healthStatus != ''">#{healthStatus},</if>
<if test="eduBack != null and eduBack != ''">#{eduBack},</if>
<if test="height != null and height != ''">#{height},</if>
<if test="weight != null and weight != ''">#{weight},</if>
<if test="politicsStatus != null and politicsStatus != ''">#{politicsStatus},</if>
<if test="ownerSiteCode != null and ownerSiteCode != ''">#{ownerSiteCode},</if>
<if test="driverOwnerType != null and driverOwnerType != ''">#{driverOwnerType},</if>
<if test="idType != null and idType != ''">#{idType},</if>
<if test="idNo != null and idNo != ''">#{idNo},</if>
<if test="empNo != null and empNo != ''">#{empNo},</if>
<if test="drivingYears != null and drivingYears != ''">#{drivingYears},</if>
<if test="blStatus != null and blStatus != ''">#{blStatus},</if>
<if test="blMilitaryService != null and blMilitaryService != ''">#{blMilitaryService},</if>
<if test="driverPhone != null and driverPhone != ''">#{driverPhone},</if>
<if test="driverCod != null and driverCod != ''">#{driverCod},</if>
<if test="firstNum != null and firstNum != ''">#{firstNum},</if>
<if test="secondNum != null and secondNum != ''">#{secondNum},</if>
<if test="entryTime != null">#{entryTime},</if>
<if test="registerDate != null">#{registerDate},</if>
<if test="orderNum != null">#{orderNum},</if>
<if test="remark != null and remark != ''">#{remark},</if>
<if test="tenantId != null and tenantId != ''">#{tenantId},</if>
<if test="delFlag != null and delFlag != ''">#{delFlag},</if>
<if test="createBy != null and createBy != ''">#{createBy},</if>
<if test="createTime != null">#{createTime},</if>
<if test="updateBy != null and updateBy != ''">#{updateBy},</if>
<if test="updateTime != null">#{updateTime},</if>
<if test="createSite != null and createSite != ''">#{createSite},</if>
<if test="updateSite != null and updateSite != ''">#{updateSite},</if>
</trim>
</insert>
<update id="updateEmisTmsDriver" parameterType="EmisTmsDriver">
update emis_tms_driver
<trim prefix="SET" suffixOverrides=",">
<if test="driverName != null and driverName != ''">driver_name = #{driverName},</if>
<if test="country != null and country != ''">country = #{country},</if>
<if test="maritalStatus != null and maritalStatus != ''">marital_status = #{maritalStatus},</if>
<if test="birthDate != null">birth_date = #{birthDate},</if>
<if test="healthStatus != null and healthStatus != ''">health_status = #{healthStatus},</if>
<if test="eduBack != null and eduBack != ''">edu_back = #{eduBack},</if>
<if test="height != null and height != ''">height = #{height},</if>
<if test="weight != null and weight != ''">weight = #{weight},</if>
<if test="politicsStatus != null and politicsStatus != ''">politics_status = #{politicsStatus},</if>
<if test="ownerSiteCode != null and ownerSiteCode != ''">owner_site_code = #{ownerSiteCode},</if>
<if test="driverOwnerType != null and driverOwnerType != ''">driver_owner_type = #{driverOwnerType},</if>
<if test="idType != null and idType != ''">id_type = #{idType},</if>
<if test="idNo != null and idNo != ''">id_no = #{idNo},</if>
<if test="empNo != null and empNo != ''">emp_no = #{empNo},</if>
<if test="drivingYears != null and drivingYears != ''">driving_years = #{drivingYears},</if>
<if test="blStatus != null and blStatus != ''">bl_status = #{blStatus},</if>
<if test="blMilitaryService != null and blMilitaryService != ''">bl_military_service = #{blMilitaryService},</if>
<if test="driverPhone != null and driverPhone != ''">driver_phone = #{driverPhone},</if>
<if test="driverCod != null and driverCod != ''">driver_cod = #{driverCod},</if>
<if test="firstNum != null and firstNum != ''">first_num = #{firstNum},</if>
<if test="secondNum != null and secondNum != ''">second_num = #{secondNum},</if>
<if test="entryTime != null">entry_time = #{entryTime},</if>
<if test="registerDate != null">register_date = #{registerDate},</if>
<if test="orderNum != null">order_num = #{orderNum},</if>
<if test="remark != null and remark != ''">remark = #{remark},</if>
<if test="tenantId != null and tenantId != ''">tenant_id = #{tenantId},</if>
<if test="delFlag != null and delFlag != ''">del_flag = #{delFlag},</if>
<if test="createBy != null and createBy != ''">create_by = #{createBy},</if>
<if test="createTime != null">create_time = #{createTime},</if>
<if test="updateBy != null and updateBy != ''">update_by = #{updateBy},</if>
<if test="updateTime != null">update_time = #{updateTime},</if>
<if test="createSite != null and createSite != ''">create_site = #{createSite},</if>
<if test="updateSite != null and updateSite != ''">update_site = #{updateSite},</if>
</trim>
where id = #{id}
</update>
<delete id="deleteEmisTmsDriverById" parameterType="Long">
delete from emis_tms_driver where id = #{id}
</delete>
<delete id="deleteEmisTmsDriverByIds" parameterType="String">
delete from emis_tms_driver where id in
<foreach item="id" collection="array" open="(" separator="," close=")">
#{id}
</foreach>
</delete>
</mapper>