Commit 9308f482 authored by srx's avatar srx

项目焊工管理详情,删除

parent b85ed9ad
...@@ -2,9 +2,7 @@ package com.yeejoin.amos.boot.module.ugp.api.mapper; ...@@ -2,9 +2,7 @@ package com.yeejoin.amos.boot.module.ugp.api.mapper;
import com.baomidou.mybatisplus.core.metadata.IPage; import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page; import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.yeejoin.amos.boot.module.ugp.api.dto.InstallNoticeMsgPageDto; import com.yeejoin.amos.boot.module.ugp.api.dto.*;
import com.yeejoin.amos.boot.module.ugp.api.dto.MaterialDto;
import com.yeejoin.amos.boot.module.ugp.api.dto.WelderEquipmentDto;
import com.yeejoin.amos.boot.module.ugp.api.entity.Material; import com.yeejoin.amos.boot.module.ugp.api.entity.Material;
import com.yeejoin.amos.boot.module.ugp.api.entity.ProjectResource; import com.yeejoin.amos.boot.module.ugp.api.entity.ProjectResource;
import com.baomidou.mybatisplus.core.mapper.BaseMapper; import com.baomidou.mybatisplus.core.mapper.BaseMapper;
...@@ -33,4 +31,6 @@ public interface ProjectResourceMapper extends BaseMapper<ProjectResource> { ...@@ -33,4 +31,6 @@ public interface ProjectResourceMapper extends BaseMapper<ProjectResource> {
//管材页面分页,根据名称、编号筛选 //管材页面分页,根据名称、编号筛选
Page<MaterialDto> MaterialPage(IPage<MaterialDto> page ,@Param("name") String name, @Param("code") String code); Page<MaterialDto> MaterialPage(IPage<MaterialDto> page ,@Param("name") String name, @Param("code") String code);
//根据resource_id删除项目焊工人员信息
Boolean deleteByResourceId(Long resourceId);
} }
...@@ -105,4 +105,10 @@ ...@@ -105,4 +105,10 @@
AND tz_ugp_project_resource.type="material" AND tz_ugp_project_resource.type="material"
AND tz_ugp_material.name LIKE '%${name}%' AND tz_ugp_material.code LIKE '%${code}%' AND tz_ugp_material.name LIKE '%${name}%' AND tz_ugp_material.code LIKE '%${code}%'
</select> </select>
<!-- //根据resource_id删除项目焊工人员信息-->
<delete id="deleteByResourceId" >
delete FROM tz_ugp_project_resource where resource_id=#{resourceId}
</delete>
</mapper> </mapper>
package com.yeejoin.amos.boot.module.ugp.biz.controller; package com.yeejoin.amos.boot.module.ugp.biz.controller;
import com.alibaba.fastjson.JSON;
import com.alibaba.fastjson.JSONObject; import com.alibaba.fastjson.JSONObject;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.core.metadata.IPage; import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page; import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.yeejoin.amos.boot.biz.common.controller.BaseController; import com.yeejoin.amos.boot.biz.common.controller.BaseController;
import com.yeejoin.amos.boot.module.common.api.dto.OrgUsrDto; import com.yeejoin.amos.boot.module.common.api.dto.OrgUsrDto;
import com.yeejoin.amos.boot.module.ugp.api.dto.InstallNoticeDto;
import com.yeejoin.amos.boot.module.ugp.api.dto.ProjectDto;
import com.yeejoin.amos.boot.module.ugp.api.dto.WelderDto; import com.yeejoin.amos.boot.module.ugp.api.dto.WelderDto;
import com.yeejoin.amos.boot.module.ugp.api.dto.WelderEquipmentDto;
import com.yeejoin.amos.boot.module.ugp.api.entity.Project; import com.yeejoin.amos.boot.module.ugp.api.entity.Project;
import com.yeejoin.amos.boot.module.ugp.api.mapper.ProjectMapper; import com.yeejoin.amos.boot.module.ugp.api.mapper.ProjectMapper;
import com.yeejoin.amos.boot.module.ugp.api.mapper.ProjectResourceMapper;
import com.yeejoin.amos.boot.module.ugp.biz.service.impl.OrgServiceImpl; import com.yeejoin.amos.boot.module.ugp.biz.service.impl.OrgServiceImpl;
import com.yeejoin.amos.boot.module.ugp.biz.service.impl.ProjectResourceServiceImpl;
import com.yeejoin.amos.boot.module.ugp.biz.service.impl.ProjectServiceImpl; import com.yeejoin.amos.boot.module.ugp.biz.service.impl.ProjectServiceImpl;
import com.yeejoin.amos.boot.module.ugp.biz.service.impl.WelderServiceImpl; import com.yeejoin.amos.boot.module.ugp.biz.service.impl.WelderServiceImpl;
import io.swagger.annotations.Api; import io.swagger.annotations.Api;
...@@ -22,6 +28,7 @@ import org.typroject.tyboot.core.restful.doc.TycloudOperation; ...@@ -22,6 +28,7 @@ import org.typroject.tyboot.core.restful.doc.TycloudOperation;
import org.typroject.tyboot.core.restful.utils.ResponseHelper; import org.typroject.tyboot.core.restful.utils.ResponseHelper;
import org.typroject.tyboot.core.restful.utils.ResponseModel; import org.typroject.tyboot.core.restful.utils.ResponseModel;
import javax.servlet.http.HttpServletRequest;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.List; import java.util.List;
import java.util.Map; import java.util.Map;
...@@ -44,6 +51,12 @@ public class WelderController extends BaseController { ...@@ -44,6 +51,12 @@ public class WelderController extends BaseController {
@Autowired @Autowired
OrgServiceImpl orgServiceImpl; OrgServiceImpl orgServiceImpl;
@Autowired
ProjectResourceMapper projectResourceMapper;
@Autowired
ProjectResourceServiceImpl projectResourceServiceImpl;
/** /**
* 新增/修改焊工信息 * 新增/修改焊工信息
* *
...@@ -93,6 +106,16 @@ public class WelderController extends BaseController { ...@@ -93,6 +106,16 @@ public class WelderController extends BaseController {
} }
/** /**
* 项目焊工人员删除
*/
@TycloudOperation(ApiLevel = UserType.AGENCY, needAuth = false)
@DeleteMapping(value = "/delWelder/{sequenceNbr}")
@ApiOperation(httpMethod = "Delete", value = "项目焊工人员删除", notes = "项目焊工人员删除")
public ResponseModel<Boolean> deleteByResourceId(HttpServletRequest request, @PathVariable(value = "sequenceNbr") Long sequenceNbr){
return ResponseHelper.buildResponse(projectResourceMapper.deleteByResourceId(sequenceNbr));
}
/**
* 当前登陆人所在公司/单位/企业 下的 所有焊工人员分页查询 * 当前登陆人所在公司/单位/企业 下的 所有焊工人员分页查询
* @param current 当前页 * @param current 当前页
* @param current 每页大小 * @param current 每页大小
...@@ -136,4 +159,5 @@ public class WelderController extends BaseController { ...@@ -136,4 +159,5 @@ public class WelderController extends BaseController {
public void deleteOneById(@PathVariable String sequenceNbr) throws Exception { public void deleteOneById(@PathVariable String sequenceNbr) throws Exception {
orgServiceImpl.delectInfo(sequenceNbr); orgServiceImpl.delectInfo(sequenceNbr);
} }
} }
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment