人员管理

This commit is contained in:
zhulongchuan 2025-09-15 18:40:37 +08:00
parent 62b8ecade7
commit 93f0226c8e
5 changed files with 51 additions and 85 deletions

View File

@ -116,7 +116,7 @@ public class UavOperator extends BaseEntity
private String appId; private String appId;
/** 组织id */ /** 组织id */
private Long orgId; private Long deptId;
/** 圖片url */ /** 圖片url */
private String picUrl; private String picUrl;

View File

@ -471,7 +471,7 @@ public class AirplaneImpl implements AirplaneService {
// SysUser sysUser = userService.getUserInfoByUserId(SecurityUtils.getUserId(), SecurityConstants.INNER).getData(); // SysUser sysUser = userService.getUserInfoByUserId(SecurityUtils.getUserId(), SecurityConstants.INNER).getData();
// Long deptId = sysUser.getDeptId(); // Long deptId = sysUser.getDeptId();
Long deptId = SecurityUtils.getDeptId(); Long deptId = SecurityUtils.getDeptId();
uavOperator.setOrgId(deptId); uavOperator.setDeptId(deptId);
uavOperator.setUserName(uavOperatorName); uavOperator.setUserName(uavOperatorName);
List<UavOperator> list = uavOperatorService.selectUavOperatorList(uavOperator); List<UavOperator> list = uavOperatorService.selectUavOperatorList(uavOperator);
AirplaneApplyOperator airplaneApplyOperator = new AirplaneApplyOperator(); AirplaneApplyOperator airplaneApplyOperator = new AirplaneApplyOperator();
@ -560,7 +560,7 @@ public class AirplaneImpl implements AirplaneService {
// SysUser sysUser = userService.getUserInfoByUserId(SecurityUtils.getUserId(), SecurityConstants.INNER).getData(); // SysUser sysUser = userService.getUserInfoByUserId(SecurityUtils.getUserId(), SecurityConstants.INNER).getData();
// Long deptId = sysUser.getDeptId(); // Long deptId = sysUser.getDeptId();
Long deptId = SecurityUtils.getDeptId(); Long deptId = SecurityUtils.getDeptId();
uavOperator.setOrgId(deptId); uavOperator.setDeptId(deptId);
uavOperator.setUserName(uavOperatorName); uavOperator.setUserName(uavOperatorName);
List<UavOperator> list = uavOperatorService.selectUavOperatorList(uavOperator); List<UavOperator> list = uavOperatorService.selectUavOperatorList(uavOperator);
AirplaneApplyOperator airplaneApplyOperator = new AirplaneApplyOperator(); AirplaneApplyOperator airplaneApplyOperator = new AirplaneApplyOperator();

View File

@ -42,8 +42,8 @@ public class UavOperatorController extends BaseController
{ {
SysUser sysUser = userService.selectUserById(SecurityUtils.getUserId()); SysUser sysUser = userService.selectUserById(SecurityUtils.getUserId());
Long deptId = sysUser.getDeptId(); Long deptId = sysUser.getDeptId();
if (uavOperator.getOrgId() == null){ if (uavOperator.getDeptId() == null){
uavOperator.setOrgId(deptId); uavOperator.setDeptId(deptId);
} }
startPage(); startPage();
List<UavOperator> list = uavOperatorService.selectUavOperatorList(uavOperator); List<UavOperator> list = uavOperatorService.selectUavOperatorList(uavOperator);
@ -78,13 +78,13 @@ public class UavOperatorController extends BaseController
* 导出飞手管理列表 * 导出飞手管理列表
*/ */
// @RequiresPermissions("uav:operator:export") // @RequiresPermissions("uav:operator:export")
@Log(title = "飞手管理", businessType = BusinessType.EXPORT) // @Log(title = "飞手管理", businessType = BusinessType.EXPORT)
@PostMapping("/export") @PostMapping("/export")
public void export(HttpServletResponse response, UavOperator uavOperator) public void export(HttpServletResponse response, UavOperator uavOperator)
{ {
SysUser sysUser = userService.selectUserById(SecurityUtils.getUserId()); SysUser sysUser = userService.selectUserById(SecurityUtils.getUserId());
Long deptId = sysUser.getDeptId(); Long deptId = sysUser.getDeptId();
uavOperator.setOrgId(deptId); uavOperator.setDeptId(deptId);
List<UavOperator> list = uavOperatorService.selectUavOperatorList(uavOperator); List<UavOperator> list = uavOperatorService.selectUavOperatorList(uavOperator);
ExcelUtil<UavOperator> util = new ExcelUtil<UavOperator>(UavOperator.class); ExcelUtil<UavOperator> util = new ExcelUtil<UavOperator>(UavOperator.class);
util.exportExcel(response, list, "飞手数据"); util.exportExcel(response, list, "飞手数据");
@ -104,14 +104,14 @@ public class UavOperatorController extends BaseController
* 新增飞手管理 * 新增飞手管理
*/ */
// @RequiresPermissions("uav:operator:add") // @RequiresPermissions("uav:operator:add")
@Log(title = "飞手管理", businessType = BusinessType.INSERT) // @Log(title = "飞手管理", businessType = BusinessType.INSERT)
@PostMapping @PostMapping
public AjaxResult add(@RequestBody UavOperator uavOperator) public AjaxResult add(@RequestBody UavOperator uavOperator)
{ {
SysUser sysUser = userService.selectUserById(SecurityUtils.getUserId()); SysUser sysUser = userService.selectUserById(SecurityUtils.getUserId());
Long deptId = sysUser.getDeptId(); Long deptId = sysUser.getDeptId();
if(null == uavOperator.getOrgId()){ if(null == uavOperator.getDeptId()){
uavOperator.setOrgId(deptId); uavOperator.setDeptId(deptId);
} }
int result = uavOperatorService.insertUavOperator(uavOperator); int result = uavOperatorService.insertUavOperator(uavOperator);
if(result == 1){ if(result == 1){
@ -125,7 +125,7 @@ public class UavOperatorController extends BaseController
* 修改飞手管理 * 修改飞手管理
*/ */
// @RequiresPermissions("uav:operator:edit") // @RequiresPermissions("uav:operator:edit")
@Log(title = "飞手管理", businessType = BusinessType.UPDATE) // @Log(title = "飞手管理", businessType = BusinessType.UPDATE)
@PutMapping @PutMapping
public AjaxResult edit(@RequestBody UavOperator uavOperator) public AjaxResult edit(@RequestBody UavOperator uavOperator)
{ {
@ -141,7 +141,7 @@ public class UavOperatorController extends BaseController
* 删除飞手管理 * 删除飞手管理
*/ */
// @RequiresPermissions("uav:operator:remove") // @RequiresPermissions("uav:operator:remove")
@Log(title = "飞手管理", businessType = BusinessType.DELETE) // @Log(title = "飞手管理", businessType = BusinessType.DELETE)
@DeleteMapping("/{ids}") @DeleteMapping("/{ids}")
public AjaxResult remove(@PathVariable Long[] ids) public AjaxResult remove(@PathVariable Long[] ids)
{ {

View File

@ -67,12 +67,12 @@ public class UavOperatorServiceImpl extends ServiceImpl<UavOperatorMapper, UavOp
public UavOperator selectUavOperatorById(Long id) public UavOperator selectUavOperatorById(Long id)
{ {
UavOperator uavOperator = uavOperatorMapper.selectUavOperatorById(id); UavOperator uavOperator = uavOperatorMapper.selectUavOperatorById(id);
List<UavOperatorAbility> operatorAbilityList = uavOperator.getOperatorAbilityList(); // List<UavOperatorAbility> operatorAbilityList = uavOperator.getOperatorAbilityList();
List<String> abilityNameList = new ArrayList<>(); // List<String> abilityNameList = new ArrayList<>();
operatorAbilityList.forEach(x -> { // operatorAbilityList.forEach(x -> {
abilityNameList.add(x.getAbilityName()); // abilityNameList.add(x.getAbilityName());
}); // });
uavOperator.setAbilityNameList(abilityNameList); // uavOperator.setAbilityNameList(abilityNameList);
List<Long> idList = new ArrayList<>(); List<Long> idList = new ArrayList<>();
if(StringUtils.isNotEmpty(uavOperator.getCertificateFileId())){ if(StringUtils.isNotEmpty(uavOperator.getCertificateFileId())){
@ -99,12 +99,12 @@ public class UavOperatorServiceImpl extends ServiceImpl<UavOperatorMapper, UavOp
public UavOperator selectOperatorById(Long id) public UavOperator selectOperatorById(Long id)
{ {
UavOperator uavOperator = uavOperatorMapper.selectUavOperatorById(id); UavOperator uavOperator = uavOperatorMapper.selectUavOperatorById(id);
List<UavOperatorAbility> operatorAbilityList = uavOperator.getOperatorAbilityList(); // List<UavOperatorAbility> operatorAbilityList = uavOperator.getOperatorAbilityList();
List<String> abilityNameList = new ArrayList<>(); // List<String> abilityNameList = new ArrayList<>();
operatorAbilityList.forEach(x -> { // operatorAbilityList.forEach(x -> {
abilityNameList.add(x.getAbilityName()); // abilityNameList.add(x.getAbilityName());
}); // });
uavOperator.setAbilityNameList(abilityNameList); // uavOperator.setAbilityNameList(abilityNameList);
// List<Long> idList = new ArrayList<>(); // List<Long> idList = new ArrayList<>();
// if(StringUtils.isNotEmpty(uavOperator.getCertificateFileId())){ // if(StringUtils.isNotEmpty(uavOperator.getCertificateFileId())){
@ -198,39 +198,6 @@ public class UavOperatorServiceImpl extends ServiceImpl<UavOperatorMapper, UavOp
@Override @Override
public int updateUavOperator(UavOperator uavOperator) public int updateUavOperator(UavOperator uavOperator)
{ {
UavOperator operator = uavOperatorMapper.selectUavOperatorById(uavOperator.getId());
List<UavOperator> operatorList = new ArrayList<>();
// if(!operator.getUserId().equals(uavOperator.getUserId())){
// QueryWrapper<UavOperator> wrapper = new QueryWrapper<>();
// wrapper.eq("user_id",uavOperator.getUserId());
// wrapper.eq("del_flag","0");
// operatorList = uavOperatorMapper.selectList(wrapper);
// }
// if(operatorList.size() > 0){
// return -1;
// }
Long uavOperatorId = uavOperator.getId();
UpdateWrapper<UavOperatorAbility> abilityUpdateWrapper = new UpdateWrapper<>();
UavOperatorAbility operatorAbility = new UavOperatorAbility();
abilityUpdateWrapper.eq("uav_operator_id",uavOperatorId);
operatorAbility.setDelFlag("2");
uavOperatorAbilityService.update(operatorAbility,abilityUpdateWrapper);
//新增飞手特长表
String abilityName = uavOperator.getAbilityName();
if(StringUtils.isNotEmpty(abilityName)){
String[] abilityNameArray = abilityName.trim().split(",");
List<UavOperatorAbility> abilityList = new ArrayList<>();
for(int i = 0;i < abilityNameArray.length; i++){
UavOperatorAbility ability = new UavOperatorAbility();
ability.setUavOperatorId(uavOperatorId);
ability.setAbilityName(abilityNameArray[i]);
ability.setCreateBy(SecurityUtils.getUsername());
ability.setCreateTime(DateUtils.getNowDate());
ability.setDelFlag("0");
abilityList.add(ability);
}
uavOperatorAbilityService.insertUavOperatorAbilityList(abilityList);
}
uavOperator.setUpdateTime(DateUtils.getNowDate()); uavOperator.setUpdateTime(DateUtils.getNowDate());
uavOperator.setUpdateBy(SecurityUtils.getUsername()); uavOperator.setUpdateBy(SecurityUtils.getUsername());
return uavOperatorMapper.updateUavOperator(uavOperator); return uavOperatorMapper.updateUavOperator(uavOperator);

View File

@ -29,7 +29,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<result property="sceneType" column="scene_type" /> <result property="sceneType" column="scene_type" />
<result property="sceneName" column="scene_name" /> <result property="sceneName" column="scene_name" />
<result property="appId" column="app_id" /> <result property="appId" column="app_id" />
<result property="orgId" column="org_id" /> <result property="deptId" column="dept_id" />
<result property="deptName" column="dept_name" />
<result property="picUrl" column="pic_url" /> <result property="picUrl" column="pic_url" />
<result property="celebrateDate" column="celebrate_date" /> <result property="celebrateDate" column="celebrate_date" />
<result property="jobType" column="job_type" /> <result property="jobType" column="job_type" />
@ -43,14 +44,14 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<sql id="selectUavOperatorVo"> <sql id="selectUavOperatorVo">
select id, pic_url, celebrate_date, user_id, user_name, police_no, police_type, tel,status, email, del_flag,sex, operator_type, certificate_type, select id, pic_url, celebrate_date, user_id, user_name, police_no, police_type, tel,status, email, del_flag,sex, operator_type, certificate_type,
certificate_name, certificate_no, certificate_file_id, scene_type, scene_name , create_by, certificate_name, certificate_no, certificate_file_id, scene_type, scene_name , create_by,
create_time, update_by, update_time, remark, plan_time, app_id, org_id create_time, update_by, update_time, remark, plan_time, app_id, dept_id
from uav_operator from uav_operator
</sql> </sql>
<!-- <select id="selectUavOperatorList" parameterType="com.djhk.uav.airspace.domain.UavOperator" resultMap="UavOperatorResult">--> <!-- <select id="selectUavOperatorList" parameterType="com.djhk.uav.airspace.domain.UavOperator" resultMap="UavOperatorResult">-->
<!-- select o.id, user_id, user_name, police_no, police_type,tel,o.status, email,sex, operator_type, certificate_type,--> <!-- select o.id, user_id, user_name, police_no, police_type,tel,o.status, email,sex, operator_type, certificate_type,-->
<!-- certificate_name, certificate_no, certificate_file_id, scene_type, scene_name , o.create_by,--> <!-- certificate_name, certificate_no, certificate_file_id, scene_type, scene_name , o.create_by,-->
<!-- o.create_time, o.update_by, o.update_time, o.remark, plan_time, o.app_id, o.org_id--> <!-- o.create_time, o.update_by, o.update_time, o.remark, plan_time, o.app_id, o.dept_id-->
<!-- from uav_operator o--> <!-- from uav_operator o-->
<!-- <where>--> <!-- <where>-->
<!-- and o.del_flag = "0"--> <!-- and o.del_flag = "0"-->
@ -68,9 +69,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<!-- <if test="certificateFileId != null "> and certificate_file_id = #{certificateFileId}</if>--> <!-- <if test="certificateFileId != null "> and certificate_file_id = #{certificateFileId}</if>-->
<!-- <if test="sceneType != null and sceneType != ''"> and scene_type = #{sceneType}</if>--> <!-- <if test="sceneType != null and sceneType != ''"> and scene_type = #{sceneType}</if>-->
<!-- <if test="appId != null and appId != ''"> and o.app_id = #{appId}</if>--> <!-- <if test="appId != null and appId != ''"> and o.app_id = #{appId}</if>-->
<!-- <if test="orgId != null and orgId != '' ">--> <!-- <if test="deptId != null and deptId != '' ">-->
<!-- AND (o.org_id = #{orgId} OR o.org_id IN ( SELECT t.dept_id FROM sys_dept t WHERE--> <!-- AND (o.dept_id = #{deptId} OR o.dept_id IN ( SELECT t.dept_id FROM sys_dept t WHERE-->
<!-- find_in_set(#{orgId}, ancestors) ))--> <!-- find_in_set(#{deptId}, ancestors) ))-->
<!-- </if>--> <!-- </if>-->
<!-- </where>--> <!-- </where>-->
<!-- order by o.create_Time desc--> <!-- order by o.create_Time desc-->
@ -78,8 +79,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<select id="selectUavOperatorList" parameterType="com.djhk.uav.airspace.domain.UavOperator" resultMap="UavOperatorResult"> <select id="selectUavOperatorList" parameterType="com.djhk.uav.airspace.domain.UavOperator" resultMap="UavOperatorResult">
select o.id, o.pic_url, o.job_type, o.celebrate_date, o.user_id, o.user_name, o.police_no, o.police_type,o.tel,o.status, o.email,o.sex, o.operator_type, o.certificate_type, select o.id, o.pic_url, o.job_type, o.celebrate_date, o.user_id, o.user_name, o.police_no, o.police_type,o.tel,o.status, o.email,o.sex, o.operator_type, o.certificate_type,
o.certificate_name, o.certificate_no, o.certificate_file_id, o.scene_type, o.scene_name , o.create_by, o.certificate_name, o.certificate_no, o.certificate_file_id, o.scene_type, o.scene_name , o.create_by,
o.create_time, o.update_by, o.update_time, o.remark, plan_time, o.app_id, o.org_id,t.dept_name o.create_time, o.update_by, o.update_time, o.remark, plan_time, o.app_id, o.dept_id,t.dept_name
from uav_operator o LEFT JOIN sys_dept t ON o.org_id=t.dept_id from uav_operator o LEFT JOIN sys_dept t ON o.dept_id=t.dept_id
<where> <where>
and o.del_flag = "0" and o.del_flag = "0"
<if test="userId != null "> and user_id = #{userId}</if> <if test="userId != null "> and user_id = #{userId}</if>
@ -103,9 +104,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
AND date_format(o.celebrate_date,'%y%m%d') &lt;= date_format(#{ celebrateDateRage[1]},'%y%m%d') AND date_format(o.celebrate_date,'%y%m%d') &lt;= date_format(#{ celebrateDateRage[1]},'%y%m%d')
</if> </if>
<if test="appId != null and appId != ''"> and o.app_id = #{appId}</if> <if test="appId != null and appId != ''"> and o.app_id = #{appId}</if>
<if test="orgId != null and orgId != '' "> <if test="deptId != null and deptId != '' ">
AND (o.org_id = #{orgId} OR o.org_id IN ( SELECT t.dept_id FROM sys_dept t WHERE AND (o.dept_id = #{deptId} OR o.dept_id IN ( SELECT t.dept_id FROM sys_dept t WHERE
find_in_set(#{orgId}, ancestors) )) find_in_set(#{deptId}, ancestors) ))
</if> </if>
</where> </where>
order by o.create_Time desc order by o.create_Time desc
@ -114,7 +115,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<select id="selectLists" parameterType="com.djhk.uav.airspace.domain.UavOperator" resultMap="UavOperatorResult"> <select id="selectLists" parameterType="com.djhk.uav.airspace.domain.UavOperator" resultMap="UavOperatorResult">
select o.id, o.pic_url, o.job_type, o.celebrate_date, o.user_id, o.user_name, o.police_no, o.police_type,o.tel,o.status, o.email,o.sex, o.operator_type, o.certificate_type, select o.id, o.pic_url, o.job_type, o.celebrate_date, o.user_id, o.user_name, o.police_no, o.police_type,o.tel,o.status, o.email,o.sex, o.operator_type, o.certificate_type,
o.certificate_name, o.certificate_no, o.certificate_file_id, o.scene_type, o.scene_name , o.create_by, o.certificate_name, o.certificate_no, o.certificate_file_id, o.scene_type, o.scene_name , o.create_by,
o.create_time, o.update_by, o.update_time, o.remark, plan_time, o.app_id, o.org_id o.create_time, o.update_by, o.update_time, o.remark, plan_time, o.app_id, o.dept_id
from uav_operator o from uav_operator o
<where> <where>
and o.del_flag = "0" and o.del_flag = "0"
@ -127,9 +128,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<select id="selectUavOperatorById" parameterType="Long" resultMap="UavOperatorResult"> <select id="selectUavOperatorById" parameterType="Long" resultMap="UavOperatorResult">
select o.id, o.pic_url, o.job_type,o.celebrate_date,o.user_id, o.user_name, o.police_no, o.police_type,o.tel,o.status, o.email,o.sex, o.operator_type, o.certificate_type, select o.id, o.pic_url, o.job_type,o.celebrate_date,o.user_id, o.user_name, o.police_no, o.police_type,o.tel,o.status, o.email,o.sex, o.operator_type, o.certificate_type,
o.certificate_name, o.certificate_no, o.certificate_file_id, o.scene_type, o.scene_name , o.create_by, o.certificate_name, o.certificate_no, o.certificate_file_id, o.scene_type, o.scene_name , o.create_by,
o.create_time, o.update_by, o.update_time, o.remark, plan_time, o.app_id, o.org_id,t.dept_name o.create_time, o.update_by, o.update_time, o.remark, plan_time, o.app_id, o.dept_id,t.dept_name
from uav_operator o LEFT JOIN sys_dept t ON o.org_id=t.dept_id from uav_operator o LEFT JOIN sys_dept t ON o.dept_id=t.dept_id
where id = #{id} where user_id = #{id}
</select> </select>
<select id="selectOperatorCount" resultType="int"> <select id="selectOperatorCount" resultType="int">
@ -143,7 +144,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<select id="selectUavOperatorExportList" resultType="com.djhk.uav.airspace.domain.UavOperator"> <select id="selectUavOperatorExportList" resultType="com.djhk.uav.airspace.domain.UavOperator">
select o.id, o.job_type, o.celebrate_date, user_id, user_name,tel,o.status, email,sex, operator_type, certificate_type, select o.id, o.job_type, o.celebrate_date, user_id, user_name,tel,o.status, email,sex, operator_type, certificate_type,
certificate_name, certificate_no, certificate_file_id, scene_type, scene_name , o.create_by, certificate_name, certificate_no, certificate_file_id, scene_type, scene_name , o.create_by,
o.create_time, o.update_by, o.update_time, o.remark, plan_time, o.app_id, o.org_id o.create_time, o.update_by, o.update_time, o.remark, plan_time, o.app_id, o.dept_id
from uav_operator o from uav_operator o
<where> <where>
and o.del_flag = "0" and o.del_flag = "0"
@ -159,9 +160,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="userName != null and userName != '' "> <if test="userName != null and userName != '' ">
AND o.user_name like concat('%',#{userName},'%') AND o.user_name like concat('%',#{userName},'%')
</if> </if>
<if test="orgIds != null and orgIds.size() > 0"> <if test="deptIds != null and deptIds.size() > 0">
and org_id in and dept_id in
<foreach collection="orgIds" item="item" open="(" separator="," close=")"> <foreach collection="deptIds" item="item" open="(" separator="," close=")">
#{item} #{item}
</foreach> </foreach>
</if> </if>
@ -199,7 +200,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="sceneType != null">scene_type,</if> <if test="sceneType != null">scene_type,</if>
<if test="sceneName != null">scene_name,</if> <if test="sceneName != null">scene_name,</if>
<if test="appId != null and appId != ''">app_id,</if> <if test="appId != null and appId != ''">app_id,</if>
<if test="orgId != null">org_id,</if> <if test="deptId != null">dept_id,</if>
<if test="picUrl != null">pic_url,</if> <if test="picUrl != null">pic_url,</if>
<if test="celebrateDate != null">celebrate_date,</if> <if test="celebrateDate != null">celebrate_date,</if>
<if test="jobType != null">job_type,</if> <if test="jobType != null">job_type,</if>
@ -228,7 +229,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="sceneType != null">#{sceneType},</if> <if test="sceneType != null">#{sceneType},</if>
<if test="sceneName != null">#{sceneName},</if> <if test="sceneName != null">#{sceneName},</if>
<if test="appId != null and appId != ''">#{appId},</if> <if test="appId != null and appId != ''">#{appId},</if>
<if test="orgId != null">#{orgId},</if> <if test="deptId != null">#{deptId},</if>
<if test="picUrl != null">#{picUrl},</if> <if test="picUrl != null">#{picUrl},</if>
<if test="celebrateDate != null">#{celebrateDate},</if> <if test="celebrateDate != null">#{celebrateDate},</if>
<if test="jobType != null">#{jobType},</if> <if test="jobType != null">#{jobType},</if>
@ -248,8 +249,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="createTime != null">create_time = #{createTime},</if> <if test="createTime != null">create_time = #{createTime},</if>
<if test="updateBy != null">update_by = #{updateBy},</if> <if test="updateBy != null">update_by = #{updateBy},</if>
<if test="updateTime != null">update_time = #{updateTime},</if> <if test="updateTime != null">update_time = #{updateTime},</if>
<if test="deleteBy != null">delete_by = #{deleteBy},</if>
<if test="deleteTime != null">delete_time = #{deleteTime},</if>
<if test="remark != null">remark = #{remark},</if> <if test="remark != null">remark = #{remark},</if>
<if test="planTime != null">plan_time = #{planTime},</if> <if test="planTime != null">plan_time = #{planTime},</if>
<if test="status != null">status = #{status},</if> <if test="status != null">status = #{status},</if>
@ -263,20 +262,20 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="sceneType != null">scene_type = #{sceneType},</if> <if test="sceneType != null">scene_type = #{sceneType},</if>
<if test="sceneName != null">scene_name = #{sceneName},</if> <if test="sceneName != null">scene_name = #{sceneName},</if>
<if test="appId != null and appId != ''">app_id = #{appId},</if> <if test="appId != null and appId != ''">app_id = #{appId},</if>
<if test="orgId != null">org_id = #{orgId},</if> <if test="deptId != null">dept_id = #{deptId},</if>
<if test="picUrl != null">pic_url = #{picUrl},</if> <if test="picUrl != null">pic_url = #{picUrl},</if>
<if test="celebrateDate != null">celebrate_date = #{celebrateDate},</if> <if test="celebrateDate != null">celebrate_date = #{celebrateDate},</if>
<if test="jobType != null">job_type = #{jobType},</if> <if test="jobType != null">job_type = #{jobType},</if>
</trim> </trim>
where id = #{id} where user_id = #{userId}
</update> </update>
<delete id="deleteUavOperatorById" parameterType="Long"> <delete id="deleteUavOperatorById" parameterType="Long">
delete from uav_operator where id = #{id} delete from uav_operator where user_id = #{id}
</delete> </delete>
<delete id="deleteUavOperatorByIds" parameterType="String"> <delete id="deleteUavOperatorByIds" parameterType="String">
delete from uav_operator where id in delete from uav_operator where user_id in
<foreach item="id" collection="array" open="(" separator="," close=")"> <foreach item="id" collection="array" open="(" separator="," close=")">
#{id} #{id}
</foreach> </foreach>