Commit 1b7860ed authored by hkl's avatar hkl

feat:1.更新线路管理

parent e646b49b
...@@ -12,8 +12,8 @@ import org.jeecg.common.system.base.controller.JeecgController; ...@@ -12,8 +12,8 @@ import org.jeecg.common.system.base.controller.JeecgController;
import org.jeecg.modules.checkData.equipmentCheckData.dto.RailWearRecordDTO; import org.jeecg.modules.checkData.equipmentCheckData.dto.RailWearRecordDTO;
import org.jeecg.modules.checkData.equipmentCheckData.entity.RailWearRecord; import org.jeecg.modules.checkData.equipmentCheckData.entity.RailWearRecord;
import org.jeecg.modules.checkData.equipmentCheckData.service.IRailWearRecordService; import org.jeecg.modules.checkData.equipmentCheckData.service.IRailWearRecordService;
import org.jeecg.modules.checkData.equipmentCheckData.vo.RailWearRecordDetailVO;
import org.jeecg.modules.checkData.equipmentCheckData.vo.RailWearRecordVO; import org.jeecg.modules.checkData.equipmentCheckData.vo.RailWearRecordVO;
import org.jeecg.modules.checkData.equipmentCheckData.vo.UseTurnoutRecordCheckDetailVO;
import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam; import org.springframework.web.bind.annotation.RequestParam;
...@@ -47,8 +47,8 @@ public class RailWearRecordController extends JeecgController<RailWearRecord, IR ...@@ -47,8 +47,8 @@ public class RailWearRecordController extends JeecgController<RailWearRecord, IR
@AutoLog(value = "检查数据-设备检查记录数据-钢轨伤损情况检查详情页面") @AutoLog(value = "检查数据-设备检查记录数据-钢轨伤损情况检查详情页面")
@ApiOperation(value = "检查数据-设备检查记录数据-钢轨伤损情况检查详情页面", notes = "检查数据-设备检查记录数据-钢轨伤损情况检查详情页面") @ApiOperation(value = "检查数据-设备检查记录数据-钢轨伤损情况检查详情页面", notes = "检查数据-设备检查记录数据-钢轨伤损情况检查详情页面")
@GetMapping(value = "/getDetail") @GetMapping(value = "/getDetail")
public Result<UseTurnoutRecordCheckDetailVO> getDetail(@ApiParam("id") String id) { public Result<RailWearRecordDetailVO> getDetail(@ApiParam("id") String id) {
UseTurnoutRecordCheckDetailVO data = this.service.getDetail(id); RailWearRecordDetailVO data = this.service.getDetail(id);
return Result.OK(data); return Result.OK(data);
} }
......
...@@ -4,6 +4,7 @@ import com.baomidou.mybatisplus.extension.plugins.pagination.Page; ...@@ -4,6 +4,7 @@ import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import org.jeecg.modules.checkData.equipmentCheckData.dto.RailWearRecordDTO; import org.jeecg.modules.checkData.equipmentCheckData.dto.RailWearRecordDTO;
import org.jeecg.modules.checkData.equipmentCheckData.entity.RailWearRecord; import org.jeecg.modules.checkData.equipmentCheckData.entity.RailWearRecord;
import com.baomidou.mybatisplus.core.mapper.BaseMapper; import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.jeecg.modules.checkData.equipmentCheckData.vo.RailWearRecordDetailVO;
import org.jeecg.modules.checkData.equipmentCheckData.vo.RailWearRecordVO; import org.jeecg.modules.checkData.equipmentCheckData.vo.RailWearRecordVO;
import org.jeecg.modules.checkData.equipmentCheckData.vo.UseTurnoutRecordCheckDetailVO; import org.jeecg.modules.checkData.equipmentCheckData.vo.UseTurnoutRecordCheckDetailVO;
...@@ -19,5 +20,5 @@ public interface RailWearRecordMapper extends BaseMapper<RailWearRecord> { ...@@ -19,5 +20,5 @@ public interface RailWearRecordMapper extends BaseMapper<RailWearRecord> {
Page<RailWearRecordVO> queryPageList(Page<RailWearRecordVO> pageData, RailWearRecordDTO dto); Page<RailWearRecordVO> queryPageList(Page<RailWearRecordVO> pageData, RailWearRecordDTO dto);
UseTurnoutRecordCheckDetailVO getDetail(String id); RailWearRecordDetailVO getDetail(String id);
} }
...@@ -28,7 +28,7 @@ ...@@ -28,7 +28,7 @@
WHERE t1.del_flag = '0' WHERE t1.del_flag = '0'
</select> </select>
<select id="getDetail" <select id="getDetail"
resultType="org.jeecg.modules.checkData.equipmentCheckData.vo.UseTurnoutRecordCheckDetailVO"> resultType="org.jeecg.modules.checkData.equipmentCheckData.vo.RailWearRecordDetailVO">
SELECT SELECT
t1.id, t1.id,
t1.left_femoral_apparatus_code, t1.left_femoral_apparatus_code,
......
package org.jeecg.modules.checkData.equipmentCheckData.service; package org.jeecg.modules.checkData.equipmentCheckData.service;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page; import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;
import org.jeecg.modules.checkData.equipmentCheckData.dto.RailWearRecordDTO; import org.jeecg.modules.checkData.equipmentCheckData.dto.RailWearRecordDTO;
import org.jeecg.modules.checkData.equipmentCheckData.entity.RailWearRecord; import org.jeecg.modules.checkData.equipmentCheckData.entity.RailWearRecord;
import com.baomidou.mybatisplus.extension.service.IService; import org.jeecg.modules.checkData.equipmentCheckData.vo.RailWearRecordDetailVO;
import org.jeecg.modules.checkData.equipmentCheckData.vo.RailWearRecordVO; import org.jeecg.modules.checkData.equipmentCheckData.vo.RailWearRecordVO;
import org.jeecg.modules.checkData.equipmentCheckData.vo.UseTurnoutRecordCheckDetailVO;
/** /**
* <p> * <p>
...@@ -19,5 +19,5 @@ public interface IRailWearRecordService extends IService<RailWearRecord> { ...@@ -19,5 +19,5 @@ public interface IRailWearRecordService extends IService<RailWearRecord> {
Page<RailWearRecordVO> queryPageList(Page<RailWearRecordVO> pageData, RailWearRecordDTO dto); Page<RailWearRecordVO> queryPageList(Page<RailWearRecordVO> pageData, RailWearRecordDTO dto);
UseTurnoutRecordCheckDetailVO getDetail(String id); RailWearRecordDetailVO getDetail(String id);
} }
...@@ -6,6 +6,7 @@ import org.jeecg.modules.checkData.equipmentCheckData.entity.RailWearRecord; ...@@ -6,6 +6,7 @@ import org.jeecg.modules.checkData.equipmentCheckData.entity.RailWearRecord;
import org.jeecg.modules.checkData.equipmentCheckData.mapper.RailWearRecordMapper; import org.jeecg.modules.checkData.equipmentCheckData.mapper.RailWearRecordMapper;
import org.jeecg.modules.checkData.equipmentCheckData.service.IRailWearRecordService; import org.jeecg.modules.checkData.equipmentCheckData.service.IRailWearRecordService;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.jeecg.modules.checkData.equipmentCheckData.vo.RailWearRecordDetailVO;
import org.jeecg.modules.checkData.equipmentCheckData.vo.RailWearRecordVO; import org.jeecg.modules.checkData.equipmentCheckData.vo.RailWearRecordVO;
import org.jeecg.modules.checkData.equipmentCheckData.vo.UseTurnoutRecordCheckDetailVO; import org.jeecg.modules.checkData.equipmentCheckData.vo.UseTurnoutRecordCheckDetailVO;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
...@@ -27,7 +28,7 @@ public class RailWearRecordServiceImpl extends ServiceImpl<RailWearRecordMapper, ...@@ -27,7 +28,7 @@ public class RailWearRecordServiceImpl extends ServiceImpl<RailWearRecordMapper,
} }
@Override @Override
public UseTurnoutRecordCheckDetailVO getDetail(String id) { public RailWearRecordDetailVO getDetail(String id) {
return this.baseMapper.getDetail(id); return this.baseMapper.getDetail(id);
} }
} }
...@@ -7,7 +7,8 @@ ...@@ -7,7 +7,8 @@
"HY": "", "HY": "",
"QZ": "", "QZ": "",
"YH": "", "YH": "",
"HZ": "" "HZ": "",
"overLimitRecord": ""
}, },
"side": { "side": {
"checkName": "侧面消磨", "checkName": "侧面消磨",
...@@ -16,6 +17,7 @@ ...@@ -16,6 +17,7 @@
"HY": "", "HY": "",
"QZ": "", "QZ": "",
"YH": "", "YH": "",
"HZ": "" "HZ": "",
"overLimitRecord": ""
} }
} }
\ No newline at end of file
[ [
{ {
"checkName": "滑床板", "checkName": "滑床板",
"qualified": 1, "isQualified":"",
"notQualified": "", "notes": "",
"sort": 1 "sort": 1
}, },
{ {
"checkName": "顶铁", "checkName": "顶铁",
"qualified": 1, "isQualified":"",
"notQualified": "", "notes": "",
"sort": 2 "sort": 2
} }
] ]
\ No newline at end of file
[ [
{ {
"checkName": "接头螺栓", "checkName": "接头螺栓",
"qualified": 1, "isQualified":"",
"notQualified": "", "notes": "",
"sort": 1 "sort": 1
}, },
{ {
"checkName": "护轨螺栓", "checkName": "护轨螺栓",
"qualified": 1, "isQualified":"",
"notQualified": "", "notes": "",
"sort": 2 "sort": 2
} }
] ]
\ No newline at end of file
...@@ -72,6 +72,18 @@ ...@@ -72,6 +72,18 @@
"value8": "", "value8": "",
"value9": "" "value9": ""
}, },
"operator": {
"checkName": "操作者",
"value1": "",
"value2": "",
"value3": "",
"value4": "",
"value5": "",
"value6": "",
"value7": "",
"value8": "",
"value9": ""
},
"rightThigh": { "rightThigh": {
"checkName": "右股", "checkName": "右股",
"value1": "", "value1": "",
...@@ -83,5 +95,17 @@ ...@@ -83,5 +95,17 @@
"value7": "", "value7": "",
"value8": "", "value8": "",
"value9": "" "value9": ""
},
"mileage": {
"checkName": "里程",
"value1": "",
"value2": "",
"value3": "",
"value4": "",
"value5": "",
"value6": "",
"value7": "",
"value8": "",
"value9": ""
} }
} }
\ No newline at end of file
...@@ -72,6 +72,18 @@ ...@@ -72,6 +72,18 @@
"value8": "", "value8": "",
"value9": "" "value9": ""
}, },
"operator": {
"checkName": "操作者",
"value1": "",
"value2": "",
"value3": "",
"value4": "",
"value5": "",
"value6": "",
"value7": "",
"value8": "",
"value9": ""
},
"leftThigh": { "leftThigh": {
"checkName": "左股", "checkName": "左股",
"value1": "", "value1": "",
...@@ -83,5 +95,17 @@ ...@@ -83,5 +95,17 @@
"value7": "", "value7": "",
"value8": "", "value8": "",
"value9": "" "value9": ""
},
"mileage": {
"checkName": "里程",
"value1": "",
"value2": "",
"value3": "",
"value4": "",
"value5": "",
"value6": "",
"value7": "",
"value8": "",
"value9": ""
} }
} }
\ No newline at end of file
...@@ -22,12 +22,6 @@ public class RailWearRecordDetailVO { ...@@ -22,12 +22,6 @@ public class RailWearRecordDetailVO {
@ApiModelProperty("主键") @ApiModelProperty("主键")
private String id; private String id;
// @ApiModelProperty("线别Id")
// private String lineAliasId;
//
// @ApiModelProperty("线别名称")
// private String lineAliasName;
@ApiModelProperty("左股仪器编码") @ApiModelProperty("左股仪器编码")
private String leftFemoralApparatusCode; private String leftFemoralApparatusCode;
......
...@@ -13,7 +13,6 @@ import org.jeecg.modules.subwayNetwork.dto.LineAliasQueryDTO; ...@@ -13,7 +13,6 @@ import org.jeecg.modules.subwayNetwork.dto.LineAliasQueryDTO;
import org.jeecg.modules.subwayNetwork.entity.LineAlias; import org.jeecg.modules.subwayNetwork.entity.LineAlias;
import org.jeecg.modules.subwayNetwork.service.ILineAliasService; import org.jeecg.modules.subwayNetwork.service.ILineAliasService;
import org.jeecg.modules.subwayNetwork.vo.LightAliasQueryVO; import org.jeecg.modules.subwayNetwork.vo.LightAliasQueryVO;
import org.jeecg.modules.subwayNetwork.vo.SectionStationMapVO;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*; import org.springframework.web.bind.annotation.*;
...@@ -97,17 +96,10 @@ public class LightAliasController extends JeecgController<LineAlias, ILineAliasS ...@@ -97,17 +96,10 @@ public class LightAliasController extends JeecgController<LineAlias, ILineAliasS
map.put("label", alias.getLineAliasName()); map.put("label", alias.getLineAliasName());
map.put("code", alias.getLineAliasCode()); map.put("code", alias.getLineAliasCode());
map.put("value", alias.getId()); map.put("value", alias.getId());
map.put("type", alias.getType());
list.add(map); list.add(map);
} }
return Result.OK(list); return Result.OK(list);
} }
@AutoLog(value = "线路车站-线别管理-获取区间车站映射")
@ApiOperation(value = "线路车站-线别管理-获取区间车站映射", notes = "线路车站-线别管理-获取区间车站映射")
@GetMapping(value = "/getSectionStation")
public Result<List<SectionStationMapVO>> getSectionStation() {
return Result.OK(lineAliasService.getSectionStation());
}
} }
...@@ -83,7 +83,7 @@ public class TrainStationController extends JeecgController<TrainStation, ITrain ...@@ -83,7 +83,7 @@ public class TrainStationController extends JeecgController<TrainStation, ITrain
Map<String, Object> map = new HashMap<>(); Map<String, Object> map = new HashMap<>();
map.put("label", trainStation.getStationName()); map.put("label", trainStation.getStationName());
map.put("value", trainStation.getId()); map.put("value", trainStation.getId());
map.put("lineAliasCode", trainStation.getLineAliasCode()); map.put("lineAliasCode", trainStation.getLineAliasId());
map.put("lightRailId", trainStation.getLightRailId()); map.put("lightRailId", trainStation.getLightRailId());
list.add(map); list.add(map);
} }
......
...@@ -8,12 +8,7 @@ import lombok.Data; ...@@ -8,12 +8,7 @@ import lombok.Data;
@ApiModel(value = "线路DTO") @ApiModel(value = "线路DTO")
public class LineAliasQueryDTO { public class LineAliasQueryDTO {
@ApiModelProperty(value = "线别Code")
private String lineAliasCode;
@ApiModelProperty(value = "线别名称") @ApiModelProperty(value = "线别名称")
private String lineAliasName; private String lineAliasName;
@ApiModelProperty(value = "备注")
private String remark;
} }
...@@ -22,6 +22,9 @@ public class SubwaySectionEditDTO { ...@@ -22,6 +22,9 @@ public class SubwaySectionEditDTO {
@ApiModelProperty(value = "区间名") @ApiModelProperty(value = "区间名")
private String sectionName; private String sectionName;
@ApiModelProperty("所属线别id")
private String lineAliasId;
@ApiModelProperty(value = "备注") @ApiModelProperty(value = "备注")
private String remark; private String remark;
} }
...@@ -7,7 +7,11 @@ import lombok.Data; ...@@ -7,7 +7,11 @@ import lombok.Data;
@Data @Data
@ApiModel(value = "区间DTO") @ApiModel(value = "区间DTO")
public class SubwaySectionQueryDTO { public class SubwaySectionQueryDTO {
@ApiModelProperty(value = "区间名") @ApiModelProperty(value = "区间名")
private String sectionName; private String sectionName;
@ApiModelProperty(value = "线别id")
private String lineAliasId;
} }
...@@ -18,4 +18,7 @@ public class TrainStationQueryDTO { ...@@ -18,4 +18,7 @@ public class TrainStationQueryDTO {
@ApiModelProperty(value = "车站名") @ApiModelProperty(value = "车站名")
private String stationName; private String stationName;
@ApiModelProperty(value = "线别id")
private String lineAliasId;
} }
...@@ -30,20 +30,17 @@ import lombok.experimental.Accessors; ...@@ -30,20 +30,17 @@ import lombok.experimental.Accessors;
public class LightRail implements Serializable { public class LightRail implements Serializable {
private static final long serialVersionUID = 1L; private static final long serialVersionUID = 1L;
@TableId(type = IdType.ASSIGN_ID) @TableId(type = IdType.ASSIGN_ID)
@ApiModelProperty(value = "主键") @ApiModelProperty(value = "主键")
private java.lang.String id; private String id;
@ApiModelProperty(value = "创建人") @ApiModelProperty(value = "创建人")
private java.lang.String createBy; private String createBy;
@JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss") @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss") @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@ApiModelProperty(value = "创建日期") @ApiModelProperty(value = "创建日期")
private java.util.Date createTime; private Date createTime;
@ApiModelProperty(value = "更新人") @ApiModelProperty(value = "更新人")
private String updateBy; private String updateBy;
......
...@@ -44,6 +44,9 @@ public class LineAlias { ...@@ -44,6 +44,9 @@ public class LineAlias {
@ApiModelProperty(value = "线别名称") @ApiModelProperty(value = "线别名称")
private String lineAliasName; private String lineAliasName;
@ApiModelProperty(value = "类型")
private Integer type;
@ApiModelProperty(value = "备注") @ApiModelProperty(value = "备注")
private String remark; private String remark;
......
...@@ -11,6 +11,7 @@ import lombok.EqualsAndHashCode; ...@@ -11,6 +11,7 @@ import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors; import lombok.experimental.Accessors;
import org.springframework.format.annotation.DateTimeFormat; import org.springframework.format.annotation.DateTimeFormat;
import java.math.BigDecimal;
import java.util.Date; import java.util.Date;
@Data @Data
...@@ -57,5 +58,21 @@ public class SectionStationMap { ...@@ -57,5 +58,21 @@ public class SectionStationMap {
@ApiModelProperty(value = "车站名称") @ApiModelProperty(value = "车站名称")
private String stationName; private String stationName;
@ApiModelProperty("所属线别id")
private String stationLineAliasId;
@ApiModelProperty("所属线别名称")
private String stationLineAliasName;
@ApiModelProperty(value = "起始里程")
private BigDecimal stationStartingMileage;
@ApiModelProperty(value = "中心里程")
private BigDecimal stationCenterMileage;
@ApiModelProperty(value = "结束里程")
private BigDecimal stationEndMileage;
} }
...@@ -49,19 +49,15 @@ public class SubwaySection implements Serializable { ...@@ -49,19 +49,15 @@ public class SubwaySection implements Serializable {
@ApiModelProperty(value = "更新日期") @ApiModelProperty(value = "更新日期")
private java.util.Date updateTime; private java.util.Date updateTime;
@Excel(name = "区间名", width = 15)
@ApiModelProperty(value = "区间名") @ApiModelProperty(value = "区间名")
private java.lang.String sectionName; private java.lang.String sectionName;
@Excel(name = "区间code", width = 15)
@ApiModelProperty(value = "区间code") @ApiModelProperty(value = "区间code")
private java.lang.String sectionCode; private java.lang.String sectionCode;
@Excel(name = "线路id", width = 15)
@ApiModelProperty(value = "轻轨线路ID") @ApiModelProperty(value = "轻轨线路ID")
private String lightRailId; private String lightRailId;
@Excel(name = "轻轨线路Name", width = 15)
@ApiModelProperty(value = "轻轨线路Name") @ApiModelProperty(value = "轻轨线路Name")
private String lightRailName; private String lightRailName;
...@@ -71,6 +67,15 @@ public class SubwaySection implements Serializable { ...@@ -71,6 +67,15 @@ public class SubwaySection implements Serializable {
@ApiModelProperty(value = "结束车站Id") @ApiModelProperty(value = "结束车站Id")
private String endTrainStationId; private String endTrainStationId;
@ApiModelProperty("所属线别id")
private String lineAliasId;
@ApiModelProperty(value = "区间起始里程")
private BigDecimal sectionStartingMileage;
@ApiModelProperty(value = "区间结束里程")
private BigDecimal sectionEndMileage;
@ApiModelProperty(value = "备注") @ApiModelProperty(value = "备注")
private String remark; private String remark;
} }
...@@ -59,33 +59,21 @@ public class TrainStation implements Serializable { ...@@ -59,33 +59,21 @@ public class TrainStation implements Serializable {
@ApiModelProperty(value = "更新日期") @ApiModelProperty(value = "更新日期")
private Date updateTime; private Date updateTime;
@Excel(name = "轻轨线路ID", width = 15)
@ApiModelProperty(value = "轻轨线路ID") @ApiModelProperty(value = "轻轨线路ID")
private String lightRailId; private String lightRailId;
@Excel(name = "车站名", width = 15)
@ApiModelProperty(value = "车站名") @ApiModelProperty(value = "车站名")
private String stationName; private String stationName;
@Excel(name = "车站编码", width = 15) @ApiModelProperty("所属线别id")
@ApiModelProperty(value = "车站编码") private String lineAliasId;
private String stationCode;
@Excel(name = "线别", width = 15)
@ApiModelProperty(value = "线别Code")
private String lineAliasCode;
@Excel(name = "起始里程", width = 15)
@ApiModelProperty(value = "起始里程") @ApiModelProperty(value = "起始里程")
private BigDecimal startingMileage; private BigDecimal startingMileage;
@Excel(name = "中心里程", width = 15)
@ApiModelProperty(value = "中心里程") @ApiModelProperty(value = "中心里程")
private BigDecimal centerMileage; private BigDecimal centerMileage;
@Excel(name = "结束里程", width = 15)
@ApiModelProperty(value = "结束里程") @ApiModelProperty(value = "结束里程")
private BigDecimal endMileage; private BigDecimal endMileage;
......
...@@ -13,5 +13,4 @@ import java.util.List; ...@@ -13,5 +13,4 @@ import java.util.List;
public interface LineAliasMapper extends BaseMapper<LineAlias> { public interface LineAliasMapper extends BaseMapper<LineAlias> {
IPage<LightAliasQueryVO> queryPageList(Page<LightAliasQueryVO> pageData, LineAliasQueryDTO dto); IPage<LightAliasQueryVO> queryPageList(Page<LightAliasQueryVO> pageData, LineAliasQueryDTO dto);
List<SectionStationMapVO> getSectionStation();
} }
...@@ -14,7 +14,8 @@ ...@@ -14,7 +14,8 @@
t1.update_time, t1.update_time,
(SELECT count(1) FROM t_sn_subway_section WHERE light_rail_id = t1.id ) subwaySectionNum, (SELECT count(1) FROM t_sn_subway_section WHERE light_rail_id = t1.id ) subwaySectionNum,
(SELECT count( DISTINCT station_name) FROM t_sn_train_station WHERE light_rail_id = t1.id ) trainStationNum, (SELECT count( DISTINCT station_name) FROM t_sn_train_station WHERE light_rail_id = t1.id ) trainStationNum,
(SELECT max(end_mileage) FROM t_sn_train_station WHERE light_rail_id = t1.id ) lineMileage (SELECT max(end_mileage) FROM t_sn_train_station WHERE light_rail_id = t1.id AND line_alias_id = '1' ) upLineMileage,
(SELECT max(end_mileage) FROM t_sn_train_station WHERE light_rail_id = t1.id AND line_alias_id = '2' ) downLineMileage
FROM FROM
t_sn_light_rail t1 t_sn_light_rail t1
<where> <where>
...@@ -25,7 +26,6 @@ ...@@ -25,7 +26,6 @@
AND t1.status = #{query.status} AND t1.status = #{query.status}
</if> </if>
</where> </where>
GROUP BY t1.id
</select> </select>
<select id="getSectionStation" resultType="org.jeecg.modules.subwayNetwork.vo.SectionStationMapVO"> <select id="getSectionStation" resultType="org.jeecg.modules.subwayNetwork.vo.SectionStationMapVO">
SELECT SELECT
......
...@@ -3,18 +3,14 @@ ...@@ -3,18 +3,14 @@
<mapper namespace="org.jeecg.modules.subwayNetwork.mapper.LineAliasMapper"> <mapper namespace="org.jeecg.modules.subwayNetwork.mapper.LineAliasMapper">
<select id="queryPageList" resultType="org.jeecg.modules.subwayNetwork.vo.LightAliasQueryVO"> <select id="queryPageList" resultType="org.jeecg.modules.subwayNetwork.vo.LightAliasQueryVO">
select * from t_sn_line_alias SELECT t1.* from t_sn_line_alias t1
</select>
<select id="getSectionStation" resultType="org.jeecg.modules.subwayNetwork.vo.SectionStationMapVO"> <where>
SELECT <if test="dto.lineAliasName != null and dto.lineAliasName != ''">
id, AND t1.line_alias_name like concat('%',#{dto.lineAliasName},'%')
light_rail_id, </if>
light_rail_name, </where>
section_name , ORDER BY create_time
section_id ,
station_id,
station_name
FROM
t_sn_section_station_map
</select> </select>
</mapper> </mapper>
\ No newline at end of file
...@@ -12,6 +12,10 @@ ...@@ -12,6 +12,10 @@
t1.light_rail_id, t1.light_rail_id,
t1.start_train_station_id, t1.start_train_station_id,
t1.end_train_station_id, t1.end_train_station_id,
t1.line_alias_id,
(SELECT line_alias_name FROM t_sn_line_alias WHERE id = t1.line_alias_id limit 1) line_alias_name,
t1.section_starting_mileage,
t1.section_end_mileage,
t1.remark t1.remark
FROM FROM
t_sn_subway_section t1 LEFT JOIN t_sn_light_rail t2 ON t1.light_rail_id = t2.id t_sn_subway_section t1 LEFT JOIN t_sn_light_rail t2 ON t1.light_rail_id = t2.id
...@@ -19,6 +23,9 @@ ...@@ -19,6 +23,9 @@
<if test="query.sectionName != null and query.sectionName != ''"> <if test="query.sectionName != null and query.sectionName != ''">
AND t1.section_name like concat('%',#{query.sectionName},'%') AND t1.section_name like concat('%',#{query.sectionName},'%')
</if> </if>
<if test="query.lineAliasId !=null and query.lineAliasId!=''">
AND t1.line_alias_id = #{query.lineAliasId}
</if>
</where> </where>
</select> </select>
</mapper> </mapper>
\ No newline at end of file
...@@ -6,10 +6,10 @@ ...@@ -6,10 +6,10 @@
SELECT SELECT
t1.id, t1.id,
t1.station_name, t1.station_name,
t1.station_code,
t1.light_rail_id, t1.light_rail_id,
t2.rail_line_name light_rail_name, t2.rail_line_name light_rail_name,
t1.line_alias_code, t1.line_alias_id,
(SELECT line_alias_name FROM t_sn_line_alias WHERE id = t1.line_alias_id limit 1) line_alias_name,
t1.starting_mileage, t1.starting_mileage,
t1.center_mileage, t1.center_mileage,
t1.end_mileage, t1.end_mileage,
...@@ -26,6 +26,9 @@ ...@@ -26,6 +26,9 @@
<if test="query.stationName !=null and query.stationName!=''"> <if test="query.stationName !=null and query.stationName!=''">
AND t1.station_name like concat('%',#{query.stationName},'%') AND t1.station_name like concat('%',#{query.stationName},'%')
</if> </if>
<if test="query.lineAliasId !=null and query.lineAliasId!=''">
AND t1.line_alias_id = #{query.lineAliasId}
</if>
</where> </where>
</select> </select>
</mapper> </mapper>
\ No newline at end of file
...@@ -5,11 +5,7 @@ import com.baomidou.mybatisplus.extension.plugins.pagination.Page; ...@@ -5,11 +5,7 @@ import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService; import com.baomidou.mybatisplus.extension.service.IService;
import org.jeecg.modules.subwayNetwork.dto.LineAliasQueryDTO; import org.jeecg.modules.subwayNetwork.dto.LineAliasQueryDTO;
import org.jeecg.modules.subwayNetwork.entity.LineAlias; import org.jeecg.modules.subwayNetwork.entity.LineAlias;
import org.jeecg.modules.subwayNetwork.entity.SectionStationMap;
import org.jeecg.modules.subwayNetwork.vo.LightAliasQueryVO; import org.jeecg.modules.subwayNetwork.vo.LightAliasQueryVO;
import org.jeecg.modules.subwayNetwork.vo.SectionStationMapVO;
import java.util.List;
/** /**
* @Description: 线路车站-线别管理 * @Description: 线路车站-线别管理
...@@ -19,5 +15,4 @@ public interface ILineAliasService extends IService<LineAlias> { ...@@ -19,5 +15,4 @@ public interface ILineAliasService extends IService<LineAlias> {
IPage<LightAliasQueryVO> queryPageList(Page<LightAliasQueryVO> pageData, LineAliasQueryDTO dto); IPage<LightAliasQueryVO> queryPageList(Page<LightAliasQueryVO> pageData, LineAliasQueryDTO dto);
List<SectionStationMapVO> getSectionStation();
} }
...@@ -8,11 +8,8 @@ import org.jeecg.modules.subwayNetwork.entity.LineAlias; ...@@ -8,11 +8,8 @@ import org.jeecg.modules.subwayNetwork.entity.LineAlias;
import org.jeecg.modules.subwayNetwork.mapper.LineAliasMapper; import org.jeecg.modules.subwayNetwork.mapper.LineAliasMapper;
import org.jeecg.modules.subwayNetwork.service.ILineAliasService; import org.jeecg.modules.subwayNetwork.service.ILineAliasService;
import org.jeecg.modules.subwayNetwork.vo.LightAliasQueryVO; import org.jeecg.modules.subwayNetwork.vo.LightAliasQueryVO;
import org.jeecg.modules.subwayNetwork.vo.SectionStationMapVO;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
import java.util.List;
/** /**
* @Description: 线路车站-轻轨线路 * @Description: 线路车站-轻轨线路
* @Author: jeecg-boot * @Author: jeecg-boot
...@@ -27,8 +24,4 @@ public class LightAliasServiceImpl extends ServiceImpl<LineAliasMapper, LineAlia ...@@ -27,8 +24,4 @@ public class LightAliasServiceImpl extends ServiceImpl<LineAliasMapper, LineAlia
return this.baseMapper.queryPageList(pageData, dto); return this.baseMapper.queryPageList(pageData, dto);
} }
@Override
public List<SectionStationMapVO> getSectionStation() {
return this.baseMapper.getSectionStation();
}
} }
...@@ -67,8 +67,8 @@ public class SubwaySectionServiceImpl extends ServiceImpl<SubwaySectionMapper, S ...@@ -67,8 +67,8 @@ public class SubwaySectionServiceImpl extends ServiceImpl<SubwaySectionMapper, S
TrainStation startTrainStation = trainStationMapper.selectById(subwaySection.getStartTrainStationId()); TrainStation startTrainStation = trainStationMapper.selectById(subwaySection.getStartTrainStationId());
TrainStation endTrainStation = trainStationMapper.selectById(subwaySection.getEndTrainStationId()); TrainStation endTrainStation = trainStationMapper.selectById(subwaySection.getEndTrainStationId());
QueryWrapper<TrainStation> tsQueryWrapper = new QueryWrapper<>(); QueryWrapper<TrainStation> tsQueryWrapper = new QueryWrapper<>();
tsQueryWrapper.select("DISTINCT station_name station_name", "id");
tsQueryWrapper.lambda().ge(TrainStation::getSeq, startTrainStation.getSeq()) tsQueryWrapper.lambda().ge(TrainStation::getSeq, startTrainStation.getSeq())
.eq(TrainStation::getLineAliasId, dto.getLineAliasId())
.le(TrainStation::getSeq, endTrainStation.getSeq()) .le(TrainStation::getSeq, endTrainStation.getSeq())
.eq(TrainStation::getLightRailId, subwaySection.getLightRailId()); .eq(TrainStation::getLightRailId, subwaySection.getLightRailId());
List<TrainStation> trainStations = trainStationMapper.selectList(tsQueryWrapper); List<TrainStation> trainStations = trainStationMapper.selectList(tsQueryWrapper);
...@@ -80,10 +80,10 @@ public class SubwaySectionServiceImpl extends ServiceImpl<SubwaySectionMapper, S ...@@ -80,10 +80,10 @@ public class SubwaySectionServiceImpl extends ServiceImpl<SubwaySectionMapper, S
SectionStationMap sectionStationMap = new SectionStationMap(); SectionStationMap sectionStationMap = new SectionStationMap();
sectionStationMap.setLightRailId(lightRail.getId());// 车站id sectionStationMap.setLightRailId(lightRail.getId());// 车站id
sectionStationMap.setLightRailName(lightRail.getRailLineName()); // 车站名称 sectionStationMap.setLightRailName(lightRail.getRailLineName()); // 车站名称
sectionStationMap.setSectionId(subwaySection.getId()); sectionStationMap.setSectionId(subwaySection.getId());// 区间id
sectionStationMap.setSectionName(subwaySection.getSectionName()); sectionStationMap.setSectionName(subwaySection.getSectionName()); // 区间名称
sectionStationMap.setStationId(trainStation.getId()); sectionStationMap.setStationId(trainStation.getId()); // 车站id
sectionStationMap.setStationName(trainStation.getStationName()); sectionStationMap.setStationName(trainStation.getStationName()); // 车站名称
sectionStationMapMapper.insert(sectionStationMap); sectionStationMapMapper.insert(sectionStationMap);
} }
......
...@@ -42,6 +42,9 @@ public class LightAliasQueryVO { ...@@ -42,6 +42,9 @@ public class LightAliasQueryVO {
@ApiModelProperty(value = "线别名称") @ApiModelProperty(value = "线别名称")
private String lineAliasName; private String lineAliasName;
@ApiModelProperty(value = "类型 1-基础线别 2-其他线别")
private Integer type;
@ApiModelProperty(value = "备注") @ApiModelProperty(value = "备注")
private String remark; private String remark;
} }
...@@ -33,10 +33,10 @@ public class LightRailQueryVO { ...@@ -33,10 +33,10 @@ public class LightRailQueryVO {
private Date updateTime; private Date updateTime;
@ApiModelProperty(value = "线路名称") @ApiModelProperty(value = "线路名称")
private java.lang.String railLineName; private String railLineName;
@ApiModelProperty(value = "线路code") @ApiModelProperty(value = "线路code")
private java.lang.String railLineCode; private String railLineCode;
@ApiModelProperty(value = "状态") @ApiModelProperty(value = "状态")
private Integer status; private Integer status;
...@@ -47,6 +47,9 @@ public class LightRailQueryVO { ...@@ -47,6 +47,9 @@ public class LightRailQueryVO {
@ApiModelProperty(value = "车站数量") @ApiModelProperty(value = "车站数量")
private Integer trainStationNum; private Integer trainStationNum;
@ApiModelProperty(value = "线路里程") @ApiModelProperty(value = "上行线路里程")
private BigDecimal lineMileage; private BigDecimal upLineMileage;
@ApiModelProperty(value = "下线路里程")
private BigDecimal downLineMileage;
} }
...@@ -53,6 +53,18 @@ public class SubwaySectionVO { ...@@ -53,6 +53,18 @@ public class SubwaySectionVO {
@ApiModelProperty(value = "车站数量") @ApiModelProperty(value = "车站数量")
private Integer trainStationNum; private Integer trainStationNum;
@ApiModelProperty("所属线别id")
private String lineAliasId;
@ApiModelProperty("所属线别名称")
private String lineAliasName;
@ApiModelProperty(value = "区间起始里程")
private BigDecimal sectionStartingMileage;
@ApiModelProperty(value = "区间结束里程")
private BigDecimal sectionEndMileage;
@ApiModelProperty(value = "备注") @ApiModelProperty(value = "备注")
private String remark; private String remark;
......
...@@ -41,11 +41,11 @@ public class TrainStationVO { ...@@ -41,11 +41,11 @@ public class TrainStationVO {
@ApiModelProperty(value = "车站名") @ApiModelProperty(value = "车站名")
private String stationName; private String stationName;
@ApiModelProperty(value = "车站编码") @ApiModelProperty(value = "线别id")
private String stationCode; private String lineAliasId;
@ApiModelProperty(value = "线别Code") @ApiModelProperty(value = "线别Name")
private String lineAliasCode; private String lineAliasName;
@ApiModelProperty(value = "起始里程") @ApiModelProperty(value = "起始里程")
private BigDecimal startingMileage; private BigDecimal startingMileage;
......
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