| | |
| | | package com.dy.pipIrrProject.intakeController; |
| | | |
| | | import com.dy.pipIrrGlobal.daoPr.PrControllerTrampMapper; |
| | | import com.dy.pipIrrGlobal.daoPr.PrIntakeControllerMapper; |
| | | import com.dy.pipIrrGlobal.pojoPr.PrControllerTramp; |
| | | import com.dy.pipIrrGlobal.pojoPr.PrIntakeController; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | |
| | | public class IntakeControllerSv { |
| | | @Autowired |
| | | private PrIntakeControllerMapper prIntakeControllerMapper; |
| | | |
| | | @Autowired |
| | | private PrControllerTrampMapper prControllerTrampMapper; |
| | | |
| | | /** |
| | | * 根据取水口编号、控制器编号、操作类别获取记录数量 |
| | |
| | | List<Map<String, Object>> getBindsByControllerId(Long controllerId) { |
| | | return prIntakeControllerMapper.getBindsByControllerId(controllerId); |
| | | } |
| | | |
| | | /** |
| | | * 根据控制器编号获取流浪控制器地址 |
| | | * @param controllerId 流浪控制器编号 |
| | | * @return 流浪控制器地址 |
| | | */ |
| | | //public String getTrampRtuAddr(Long controllerId) { |
| | | // return prControllerTrampMapper.getTrampRtuAddr(controllerId); |
| | | //} |
| | | |
| | | /** |
| | | * 根据控制器编号获取流浪控制器信息 |
| | | * @param controllerId |
| | | * @return |
| | | */ |
| | | public PrControllerTramp getTrampControllerInfo(Long controllerId) { |
| | | return prControllerTrampMapper.getTrampControllerInfo(controllerId); |
| | | } |
| | | |
| | | /** |
| | | * 根据流浪控制器编号删除流浪控制器记录 |
| | | * @param controllerId |
| | | * @return |
| | | */ |
| | | public Integer deleteTrampController(Long controllerId) { |
| | | return prControllerTrampMapper.deleteByPrimaryKey(controllerId); |
| | | } |
| | | } |