|
@@ -6,8 +6,7 @@
|
|
<resultMap id="StationSubInfoMap" type="com.jpsoft.bus.modules.bus.entity.StationSubInfo">
|
|
<resultMap id="StationSubInfoMap" type="com.jpsoft.bus.modules.bus.entity.StationSubInfo">
|
|
<id property="id" column="id_"/>
|
|
<id property="id" column="id_"/>
|
|
<result property="stationId" column="station_id"/>
|
|
<result property="stationId" column="station_id"/>
|
|
- <result property="startStationId" column="start_station_id"/>
|
|
|
|
- <result property="endStationId" column="end_station_id"/>
|
|
|
|
|
|
+ <result property="direction" column="direction_"/>
|
|
<result property="longitude" column="longitude_"/>
|
|
<result property="longitude" column="longitude_"/>
|
|
<result property="latitude" column="latitude_"/>
|
|
<result property="latitude" column="latitude_"/>
|
|
<result property="createBy" column="create_by"/>
|
|
<result property="createBy" column="create_by"/>
|
|
@@ -25,13 +24,12 @@
|
|
-->
|
|
-->
|
|
<![CDATA[
|
|
<![CDATA[
|
|
insert into bus_station_sub_info
|
|
insert into bus_station_sub_info
|
|
- (id_,station_id,start_station_id,end_station_id,longitude_,latitude_,create_by,create_time,update_by,update_time,del_flag,radius_)
|
|
|
|
|
|
+ (id_,station_id,direction_,longitude_,latitude_,create_by,create_time,update_by,update_time,del_flag,radius_)
|
|
values
|
|
values
|
|
(
|
|
(
|
|
#{id,jdbcType=VARCHAR}
|
|
#{id,jdbcType=VARCHAR}
|
|
,#{stationId,jdbcType=VARCHAR}
|
|
,#{stationId,jdbcType=VARCHAR}
|
|
- ,#{startStationId,jdbcType=VARCHAR}
|
|
|
|
- ,#{endStationId,jdbcType=VARCHAR}
|
|
|
|
|
|
+ ,#{direction,jdbcType=VARCHAR}
|
|
,#{longitude,jdbcType= NUMERIC }
|
|
,#{longitude,jdbcType= NUMERIC }
|
|
,#{latitude,jdbcType= NUMERIC }
|
|
,#{latitude,jdbcType= NUMERIC }
|
|
,#{createBy,jdbcType=VARCHAR}
|
|
,#{createBy,jdbcType=VARCHAR}
|
|
@@ -52,11 +50,8 @@
|
|
<if test="stationId!=null">
|
|
<if test="stationId!=null">
|
|
station_id=#{stationId,jdbcType=VARCHAR},
|
|
station_id=#{stationId,jdbcType=VARCHAR},
|
|
</if>
|
|
</if>
|
|
- <if test="startStationId!=null">
|
|
|
|
- start_station_id=#{startStationId,jdbcType=VARCHAR},
|
|
|
|
- </if>
|
|
|
|
- <if test="endStationId!=null">
|
|
|
|
- end_station_id=#{endStationId,jdbcType=VARCHAR},
|
|
|
|
|
|
+ <if test="direction!=null">
|
|
|
|
+ direction_=#{direction,jdbcType=VARCHAR},
|
|
</if>
|
|
</if>
|
|
<if test="longitude!=null">
|
|
<if test="longitude!=null">
|
|
longitude_=#{longitude,jdbcType= NUMERIC },
|
|
longitude_=#{longitude,jdbcType= NUMERIC },
|
|
@@ -120,26 +115,20 @@
|
|
<if test="searchParams.minLatitude != null">
|
|
<if test="searchParams.minLatitude != null">
|
|
and latitude_ >= #{searchParams.minLatitude}
|
|
and latitude_ >= #{searchParams.minLatitude}
|
|
</if>
|
|
</if>
|
|
-
|
|
|
|
- <if test="searchParams.startStationId != null">
|
|
|
|
- and start_station_id = #{searchParams.startStationId}
|
|
|
|
- </if>
|
|
|
|
- <if test="searchParams.endStationId != null">
|
|
|
|
- and end_station_id = #{searchParams.endStationId}
|
|
|
|
|
|
+ <if test="searchParams.direction != null">
|
|
|
|
+ and direction_ = #{searchParams.direction}
|
|
</if>
|
|
</if>
|
|
-
|
|
|
|
</where>
|
|
</where>
|
|
<foreach item="sort" collection="sortList" open="order by" separator=",">
|
|
<foreach item="sort" collection="sortList" open="order by" separator=",">
|
|
${sort.name} ${sort.order}
|
|
${sort.name} ${sort.order}
|
|
</foreach>
|
|
</foreach>
|
|
</select>
|
|
</select>
|
|
- <select id="findByStationIdStartEnd" resultMap="StationSubInfoMap">
|
|
|
|
|
|
+ <select id="findByStationIdAndDirection" resultMap="StationSubInfoMap">
|
|
<![CDATA[
|
|
<![CDATA[
|
|
select * from bus_station_sub_info
|
|
select * from bus_station_sub_info
|
|
where del_flag = 0
|
|
where del_flag = 0
|
|
and station_id = #{stationId}
|
|
and station_id = #{stationId}
|
|
- and start_station_id = #{startStationId}
|
|
|
|
- and end_station_id = #{endStationId}
|
|
|
|
|
|
+ and direction_ = #{direction}
|
|
limit 1
|
|
limit 1
|
|
]]>
|
|
]]>
|
|
</select>
|
|
</select>
|