Commit 02901842 authored by hanbing's avatar hanbing

方案管理-灯组配置-数据层基础

parent c58b9b6f
package net.wanji.web.controller.scheme;
import io.swagger.annotations.Api;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
/**
* @author Kent HAN
* @date 2022/12/20 10:14
*/
@Api(value = "LightsConfigController", description = "方案管理-灯组配置")
@RequestMapping("/lightsConfig")
@RestController
public class LightsConfigController {
}
package net.wanji.web.mapper.scheme;
/**
* 灯组基础信息;(t_base_cross_lights)表数据库访问层
* @author : hanbing
* @date : 2023-1-3
*/
public interface CrossLightsMapper {
}
package net.wanji.web.mapper.scheme;
/**
* 相位灯组关系;(t_base_cross_phase_lights)表数据库访问层
* @author : hanbing
* @date : 2023-1-3
*/
public interface PhaseLightsMapper {
}
package net.wanji.web.po.scheme;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import java.util.Date;
/**
* @author Kent HAN
* @date 2023/1/3 9:40
*/
@Data
public class CrossLightsPO {
/** 灯组ID */
@ApiModelProperty(name = "灯组ID",notes = "")
private Integer id ;
/** 灯组号 */
@ApiModelProperty(name = "灯组号",notes = "")
private String lightsNo ;
/** 灯组类型:机动车(1圆饼灯;2左转灯;3直行灯;4右转灯;5掉头灯;);非机动车(10非机动车灯;11左转灯;12直行灯;13右转灯;14掉头灯);20行人灯;21行人进口灯;22行人出口灯;30公交专用灯 */
@ApiModelProperty(name = "灯组类型:机动车(1圆饼灯;2左转灯;3直行灯;4右转灯;5掉头灯;);非机动车(10非机动车灯;11左转灯;12直行灯;13右转灯;14掉头灯);20行人灯;21行人进口灯;22行人出口灯;30公交专用灯",notes = "")
private Integer type ;
/** 灯组放行方向:1北;2东北;3东;4东南;5南;6西南;7西;8西北 */
@ApiModelProperty(name = "灯组放行方向:1北;2东北;3东;4东南;5南;6西南;7西;8西北",notes = "")
private Integer dir ;
/** 灯组序号 */
@ApiModelProperty(name = "灯组序号",notes = "")
private Integer sort ;
/** 路口ID */
@ApiModelProperty(name = "路口ID",notes = "")
private String crossId ;
/** 创建时间 */
@ApiModelProperty(name = "创建时间",notes = "")
private Date gmtCreate ;
/** 修改时间 */
@ApiModelProperty(name = "修改时间",notes = "")
private Date gmtModified ;
}
package net.wanji.web.po.scheme;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import java.util.Date;
/**
* @author Kent HAN
* @date 2023/1/3 9:51
*/
@Data
public class PhaseLightsPO {
/** 主键 */
@ApiModelProperty(name = "主键",notes = "")
private Integer id ;
/** 灯组ID */
@ApiModelProperty(name = "灯组ID",notes = "")
private Integer lightsId ;
/** 相位ID */
@ApiModelProperty(name = "相位ID",notes = "")
private Integer phaseId ;
/** 路口ID */
@ApiModelProperty(name = "路口ID",notes = "")
private String crossId ;
/** 创建时间 */
@ApiModelProperty(name = "创建时间",notes = "")
private Date gmtCreate ;
/** 修改时间 */
@ApiModelProperty(name = "修改时间",notes = "")
private Date gmtModified ;
}
package net.wanji.web.service.scheme;
/**
* @author Kent HAN
* @date 2023/1/3 9:59
*/
public interface LightsConfigService {
}
package net.wanji.web.service.scheme.impl;
import net.wanji.web.service.scheme.LightsConfigService;
/**
* @author Kent HAN
* @date 2023/1/3 10:00
*/
public class LightsConfigServiceImpl implements LightsConfigService {
}
...@@ -14,7 +14,7 @@ service: ...@@ -14,7 +14,7 @@ service:
mybatis: mybatis:
type-aliases-package: net.wanji.*.model type-aliases-package: net.wanji.*.model
mapper-locations: classpath:mapper/*.xml mapper-locations: classpath:mapper/*.xml,classpath:mapper/*/*.xml
configuration: configuration:
log-impl: org.apache.ibatis.logging.stdout.StdOutImpl log-impl: org.apache.ibatis.logging.stdout.StdOutImpl
......
<?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="net.wanji.web.mapper.scheme.CrossLightsMapper">
<!-- 通用查询映射结果 -->
<resultMap type="net.wanji.web.po.scheme.CrossLightsPO" id="BaseResultMap">
<result property="id" column="id"/>
<result property="lightsNo" column="lights_no"/>
<result property="type" column="type"/>
<result property="dir" column="dir"/>
<result property="sort" column="sort"/>
<result property="crossId" column="cross_id"/>
<result property="gmtCreate" column="gmt_create"/>
<result property="gmtModified" column="gmt_modified"/>
</resultMap>
</mapper>
<?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="net.wanji.web.mapper.scheme.PhaseLightsMapper">
<!-- 通用查询映射结果 -->
<resultMap type="net.wanji.web.po.scheme.PhaseLightsPO" id="BaseResultMap">
<result property="id" column="id"/>
<result property="lightsId" column="lights_id"/>
<result property="phaseId" column="phase_id"/>
<result property="crossId" column="cross_id"/>
<result property="gmtCreate" column="gmt_create"/>
<result property="gmtModified" column="gmt_modified"/>
</resultMap>
</mapper>
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