项目管理
This commit is contained in:
parent
ac83369cdb
commit
18e6cf813e
|
|
@ -0,0 +1,32 @@
|
|||
package com.securitycontrol.entity.background.vo;
|
||||
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* @author:cwchen
|
||||
* @date:2024-04-01-19:56
|
||||
* @version:1.0
|
||||
* @description:工程项目-vo
|
||||
*/
|
||||
@Data
|
||||
public class ProjectVo {
|
||||
|
||||
@ApiModelProperty("项目ID")
|
||||
private String id;
|
||||
|
||||
@ApiModelProperty("项目名称")
|
||||
private String proName;
|
||||
|
||||
@ApiModelProperty("项目编码")
|
||||
private String proNo;
|
||||
|
||||
@ApiModelProperty("建管单位ID")
|
||||
private String orgId;
|
||||
|
||||
@ApiModelProperty("电压等级")
|
||||
private String vlotage;
|
||||
|
||||
@ApiModelProperty("工程类型")
|
||||
private String proType;
|
||||
}
|
||||
|
|
@ -95,9 +95,9 @@ public class HumanManageController extends BaseController {
|
|||
}
|
||||
|
||||
@ApiOperation(value = "绑定安全帽")
|
||||
@GetMapping("bindDev")
|
||||
@PostMapping("bindDev")
|
||||
@Log(title = "人员管理", menu = "人车管理->人员管理", grade = OperationType.ADD_BUSINESS, details = "绑定安全膜", type = "业务日志")
|
||||
public AjaxResult bindDev(ParamDto dto) {
|
||||
public AjaxResult bindDev(@RequestBody ParamDto dto) {
|
||||
return service.bindDev(dto);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -0,0 +1,41 @@
|
|||
package com.securitycontrol.background.controller;
|
||||
|
||||
import com.securitycontrol.background.service.ISignProService;
|
||||
import com.securitycontrol.common.core.web.controller.BaseController;
|
||||
import com.securitycontrol.common.core.web.page.TableDataInfo;
|
||||
import com.securitycontrol.common.log.annotation.Log;
|
||||
import com.securitycontrol.common.log.enums.OperationType;
|
||||
import com.securitycontrol.entity.background.dto.ParamDto;
|
||||
import com.securitycontrol.entity.background.vo.ProjectVo;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @author:cwchen
|
||||
* @date:2024-04-01-19:23
|
||||
* @version:1.0
|
||||
* @description:项目工程/单项工程-web层
|
||||
*/
|
||||
@RequestMapping(value = "/back/signPro/")
|
||||
@RestController
|
||||
public class SignProController extends BaseController {
|
||||
|
||||
@Resource(name = "ISignProService")
|
||||
private ISignProService service;
|
||||
|
||||
@ApiOperation(value = "获取项目列表")
|
||||
@GetMapping("getProLists")
|
||||
@Log(title = "工程管理", menu = "工程管理->项目管理", grade = OperationType.QUERY_BUSINESS, details = "查询项目列表", type = "业务日志")
|
||||
public TableDataInfo getProLists(ParamDto dto) {
|
||||
startPage();
|
||||
List<ProjectVo> list = new ArrayList<>();
|
||||
list = service.getProLists(dto);
|
||||
return getDataTable(list);
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,28 @@
|
|||
package com.securitycontrol.background.mapper;
|
||||
|
||||
import com.securitycontrol.entity.background.dto.ParamDto;
|
||||
import com.securitycontrol.entity.background.vo.ProjectVo;
|
||||
import org.springframework.stereotype.Repository;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @author:cwchen
|
||||
* @date:2024-04-01-19:26
|
||||
* @version:1.0
|
||||
* @description:项目工程/单项工程-数据库访问层
|
||||
*/
|
||||
@Repository(value = "ISignProMapper")
|
||||
public interface ISignProMapper {
|
||||
|
||||
|
||||
/**
|
||||
* 获取项目列表
|
||||
* @param dto
|
||||
* @return List<ProjectVo>
|
||||
* @description
|
||||
* @author cwchen
|
||||
* @date 2024/4/1 20:02
|
||||
*/
|
||||
List<ProjectVo> getProLists(ParamDto dto);
|
||||
}
|
||||
|
|
@ -0,0 +1,24 @@
|
|||
package com.securitycontrol.background.service;
|
||||
|
||||
import com.securitycontrol.entity.background.dto.ParamDto;
|
||||
import com.securitycontrol.entity.background.vo.ProjectVo;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @author:cwchen
|
||||
* @date:2024-04-01-19:24
|
||||
* @version:1.0
|
||||
* @description:项目工程/单项工程-业务层
|
||||
*/
|
||||
public interface ISignProService {
|
||||
/**
|
||||
* 获取项目列表
|
||||
* @param dto
|
||||
* @return List<ProjectVo>
|
||||
* @description
|
||||
* @author cwchen
|
||||
* @date 2024/4/1 19:59
|
||||
*/
|
||||
List<ProjectVo> getProLists(ParamDto dto);
|
||||
}
|
||||
|
|
@ -0,0 +1,38 @@
|
|||
package com.securitycontrol.background.service.impl;
|
||||
|
||||
import com.securitycontrol.background.mapper.ISignProMapper;
|
||||
import com.securitycontrol.background.service.ISignProService;
|
||||
import com.securitycontrol.common.core.web.domain.AjaxResult;
|
||||
import com.securitycontrol.entity.background.dto.ParamDto;
|
||||
import com.securitycontrol.entity.background.vo.ProjectVo;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @author:cwchen
|
||||
* @date:2024-04-01-19:25
|
||||
* @version:1.0
|
||||
* @description:项目工程/单项工程-业务逻辑层
|
||||
*/
|
||||
@Service(value = "ISignProService")
|
||||
@Slf4j
|
||||
public class SignProServiceImpl implements ISignProService {
|
||||
|
||||
@Resource(name = "ISignProMapper")
|
||||
private ISignProMapper mapper;
|
||||
|
||||
@Override
|
||||
public List<ProjectVo> getProLists(ParamDto dto) {
|
||||
List<ProjectVo> list = new ArrayList<>();
|
||||
try {
|
||||
list = mapper.getProLists(dto);
|
||||
} catch (Exception e) {
|
||||
log.error("工程列表");
|
||||
}
|
||||
return list;
|
||||
}
|
||||
}
|
||||
|
|
@ -88,7 +88,7 @@
|
|||
<select id="getDeviceListByType" resultType="com.securitycontrol.entity.background.vo.DeviceVo">
|
||||
select td.device_id deviceId,device_name deviceName
|
||||
from tb_device td
|
||||
left join tb_user_bind_cap ubc on td.device_id=td.device_id and ubc.bind_status=1
|
||||
left join tb_user_bind_cap ubc on ubc.device_id=td.device_id and ubc.bind_status=1
|
||||
WHERE ubc.id is null and td.device_type =#{code} and td.del_flag=0
|
||||
</select>
|
||||
|
||||
|
|
|
|||
|
|
@ -0,0 +1,9 @@
|
|||
<?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.securitycontrol.background.mapper.ISignProMapper">
|
||||
|
||||
<!--获取项目列表-->
|
||||
<select id="getProLists" resultType="com.securitycontrol.entity.background.vo.ProjectVo">
|
||||
|
||||
</select>
|
||||
</mapper>
|
||||
Loading…
Reference in New Issue