You've already forked FrameTour-BE
实现商品信息查询和商品价格查询逻辑
This commit is contained in:
@ -107,7 +107,7 @@
|
||||
</select>
|
||||
<select id="getById" resultMap="scenicAndConfig">
|
||||
select s.id, `name`, introduction, longitude, latitude, radius, province, city, area, address, `status`, s.create_time, update_time,
|
||||
c.start_time, c.end_time, c.is_default, c.create_time
|
||||
c.start_time, c.end_time, c.is_default, c.create_time,s.price
|
||||
from scenic s
|
||||
left join scenic_config c on s.id = c.id
|
||||
where s.id = #{id}
|
||||
|
@ -27,6 +27,10 @@
|
||||
<if test="deviceId!= null">and device_id = #{deviceId} </if>
|
||||
<if test="memberId!= null">and member_id = #{memberId} </if>
|
||||
<if test="url!= null">and url = #{url} </if>
|
||||
<if test="isBuy!=null">
|
||||
and is_buy = #{isBuy}
|
||||
</if>
|
||||
<if test="type!=null">and so.type = #{type} </if>
|
||||
<if test="startTime!= null">and so.create_time >= #{startTime} </if>
|
||||
<if test="endTime!= null">and so.create_time <= #{endTime} </if>
|
||||
</where>
|
||||
@ -35,6 +39,19 @@
|
||||
select so.id, scenic_id, device_id, member_id, url, so.create_time, so.update_time,sc.`name` as scenicName
|
||||
from source so
|
||||
left join scenic sc on sc.id = so.scenic_id
|
||||
where id = #{id}
|
||||
where so.id = #{id}
|
||||
</select>
|
||||
<select id="listGroupByType" resultType="com.ycwl.basic.model.pc.source.resp.SourceRespVO">
|
||||
select so.id, scenic_id,sc.name scenicName, sc.longitude ,sc.latitude,so.type
|
||||
from source so
|
||||
left join scenic sc on sc.id = so.scenic_id
|
||||
<where>
|
||||
<if test="scenicId!= null">and scenic_id = #{scenicId} </if>
|
||||
<if test="memberId!= null">and member_id = #{memberId} </if>
|
||||
<if test="isBuy!=null">
|
||||
and is_buy = #{isBuy}
|
||||
</if>
|
||||
</where>
|
||||
group by so.type
|
||||
</select>
|
||||
</mapper>
|
@ -21,8 +21,11 @@
|
||||
delete from video where id = #{id}
|
||||
</delete>
|
||||
<select id="list" resultType="com.ycwl.basic.model.pc.video.resp.VideoRespVO">
|
||||
select id, scenic_id, member_id, template_id, task_id, worker_id, video_url, create_time, update_time
|
||||
from video
|
||||
select v.id, scenic_id, member_id, template_id, task_id, worker_id, video_url, v.create_time, v.update_time,
|
||||
s.name scenicName, s.latitude, s.longitude, t.name templateName, t.price templatePrice
|
||||
from video v
|
||||
left join scenic s on s.id = v.scenic_id
|
||||
left join template t on v.template_id = t.id
|
||||
<where>
|
||||
<if test="scenicId!= null">and scenic_id = #{scenicId} </if>
|
||||
<if test="memberId!= null">and member_id = #{memberId} </if>
|
||||
@ -31,13 +34,18 @@
|
||||
and task_id = #{taskId}
|
||||
</if>
|
||||
<if test="workerId!= null">and worker_id = #{workerId} </if>
|
||||
<if test="startTime!= null">and create_time >= #{startTime} </if>
|
||||
<if test="endTime!= null">and create_time <= #{endTime} </if>
|
||||
<if test="isBuy!=null">
|
||||
and is_buy = #{isBuy}
|
||||
</if>
|
||||
<if test="startTime!= null">and v.create_time >= #{startTime} </if>
|
||||
<if test="endTime!= null">and v.create_time <= #{endTime} </if>
|
||||
</where>
|
||||
</select>
|
||||
<select id="getById" resultType="com.ycwl.basic.model.pc.video.resp.VideoRespVO">
|
||||
select id, scenic_id, member_id, template_id, task_id, worker_id, video_url, create_time, update_time
|
||||
from video
|
||||
where id = #{id}
|
||||
select v.id, scenic_id, member_id, template_id, task_id, worker_id, video_url, v.create_time, v.update_time,
|
||||
t.name templateName,t.price templatePrice
|
||||
from video v
|
||||
left join template t on v.template_id = t.id
|
||||
where v.id = #{id}
|
||||
</select>
|
||||
</mapper>
|
Reference in New Issue
Block a user