增加获取场站列表的接口
This commit is contained in:
parent
30e691e4c9
commit
a7d04d2454
@ -38,6 +38,17 @@ public class WorkStationController extends BaseController {
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@GetMapping("/getStationPage")
|
||||||
|
public TableDataInfo getStationList(String tenantId){
|
||||||
|
startPage();
|
||||||
|
Map<String, Object> params = new HashMap<>();
|
||||||
|
params.put("tenantId", tenantId);
|
||||||
|
params.put("delFlag", 0);
|
||||||
|
|
||||||
|
return getDataTable(stationService.getStationList(params));
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
@GetMapping("/getTree")
|
@GetMapping("/getTree")
|
||||||
public TableDataInfo getTree(String stationName,
|
public TableDataInfo getTree(String stationName,
|
||||||
String terminalName){
|
String terminalName){
|
||||||
|
|||||||
@ -3,8 +3,13 @@ package com.xhpc.workorder.mapper;
|
|||||||
import com.xhpc.workorder.domain.XhpcWorkStationDomain;
|
import com.xhpc.workorder.domain.XhpcWorkStationDomain;
|
||||||
import org.apache.ibatis.annotations.Param;
|
import org.apache.ibatis.annotations.Param;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
import java.util.Map;
|
||||||
|
|
||||||
public interface XhpcWorkStationMapper {
|
public interface XhpcWorkStationMapper {
|
||||||
|
|
||||||
|
List<XhpcWorkStationDomain> selectListByParams(@Param("params") Map params);
|
||||||
|
|
||||||
XhpcWorkStationDomain selectByName(@Param("stationName") String stationName);
|
XhpcWorkStationDomain selectByName(@Param("stationName") String stationName);
|
||||||
|
|
||||||
int deleteByPrimaryKey(Long workStationId);
|
int deleteByPrimaryKey(Long workStationId);
|
||||||
|
|||||||
@ -1,6 +1,7 @@
|
|||||||
package com.xhpc.workorder.service;
|
package com.xhpc.workorder.service;
|
||||||
|
|
||||||
import com.xhpc.workorder.domain.XhpcStationDeviceDomain;
|
import com.xhpc.workorder.domain.XhpcStationDeviceDomain;
|
||||||
|
import com.xhpc.workorder.domain.XhpcWorkStationDomain;
|
||||||
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
@ -11,6 +12,9 @@ public interface WorkStationService {
|
|||||||
List<Map<String, Object>> getStationDevice(Map<String, Object> params);
|
List<Map<String, Object>> getStationDevice(Map<String, Object> params);
|
||||||
|
|
||||||
|
|
||||||
|
List<XhpcWorkStationDomain> getStationList(Map<String, Object> params);
|
||||||
|
|
||||||
|
|
||||||
List<Map<String, Object>> getStationDeviceTree(Map<String, Object> params);
|
List<Map<String, Object>> getStationDeviceTree(Map<String, Object> params);
|
||||||
|
|
||||||
String importDevice(List<XhpcStationDeviceDomain> deviceDomainList, Boolean updateSupport);
|
String importDevice(List<XhpcStationDeviceDomain> deviceDomainList, Boolean updateSupport);
|
||||||
|
|||||||
@ -29,6 +29,13 @@ public class WorkStationServiceImpl implements WorkStationService {
|
|||||||
return deviceMapper.selectStationGunDeviceListByParams(params);
|
return deviceMapper.selectStationGunDeviceListByParams(params);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public List<XhpcWorkStationDomain> getStationList(Map<String, Object> params){
|
||||||
|
return stationMapper.selectListByParams(params);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public List<Map<String, Object>> getStationDeviceTree(Map<String, Object> params){
|
public List<Map<String, Object>> getStationDeviceTree(Map<String, Object> params){
|
||||||
|
|
||||||
|
|||||||
@ -38,6 +38,27 @@
|
|||||||
park_nums, tenant_id
|
park_nums, tenant_id
|
||||||
</sql>
|
</sql>
|
||||||
|
|
||||||
|
<select id="selectListByParams">
|
||||||
|
select
|
||||||
|
<include refid="Base_Column_List" />
|
||||||
|
from xhpc_work_station
|
||||||
|
<where>
|
||||||
|
<if test="params.name != null and params.name !=''">
|
||||||
|
and name like concat('%', #{params.name}, '%')
|
||||||
|
</if>
|
||||||
|
<if test="params.tenantId!=null and params.tenantId!=''">
|
||||||
|
and tenant_id = #{params.tenantId}
|
||||||
|
</if>
|
||||||
|
<if test="params.status != null">
|
||||||
|
and status=#{params.status}
|
||||||
|
</if>
|
||||||
|
<if test="params.delFlag!=null">
|
||||||
|
and del_flag=#{params.delFlag}
|
||||||
|
</if>
|
||||||
|
</where>
|
||||||
|
|
||||||
|
</select>
|
||||||
|
|
||||||
|
|
||||||
<select id="selectByName" resultType="com.xhpc.workorder.domain.XhpcWorkStationDomain">
|
<select id="selectByName" resultType="com.xhpc.workorder.domain.XhpcWorkStationDomain">
|
||||||
select
|
select
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user