|
@@ -35,10 +35,8 @@
|
35
|
35
|
<!-- 获取分页资源(android) -->
|
36
|
36
|
<select id="listReadsForAndr" resultType="com.xhkjedu.sapi.model.itemtool.TRead">
|
37
|
37
|
SELECT r.readid,readname,readthumb,readauthor,readcount,createtime,readpath
|
38
|
|
- FROM t_read r left join t_read_date rd on r.readid=rd.readid
|
|
38
|
+ FROM t_read r
|
39
|
39
|
WHERE (belong=2 or schoolid=#{read.schoolid}) and readstate=1
|
40
|
|
- and rd.weeknum=DATE_FORMAT(CURDATE(),'%w') and CURRENT_TIME() between rd.begintime and concat(rd.endtime,':59')
|
41
|
|
- group by r.readid
|
42
|
40
|
<if test="read.rorder=='createtime'">ORDER BY createtime DESC</if>
|
43
|
41
|
<if test="read.rorder=='readcount'">ORDER BY readcount DESC</if>
|
44
|
42
|
limit #{read.page},#{read.pageSize}
|
|
@@ -99,10 +97,8 @@
|
99
|
97
|
<!--电子书列表-->
|
100
|
98
|
<select id="listReadForStuWeb" resultType="com.xhkjedu.sapi.model.itemtool.TRead">
|
101
|
99
|
SELECT r.readid,readname,readthumb,readauthor,readcount,createtime,readpath,readcomm
|
102
|
|
- FROM t_read r left join t_read_date rd on r.readid=rd.readid
|
|
100
|
+ FROM t_read r
|
103
|
101
|
WHERE (belong=2 or schoolid=#{read.schoolid}) and readstate=1
|
104
|
|
- and rd.weeknum=DATE_FORMAT(CURDATE(),'%w') and CURRENT_TIME() between rd.begintime and concat(rd.endtime,':59')
|
105
|
|
- group by r.readid
|
106
|
102
|
<if test="read.rorder=='createtime'">ORDER BY createtime DESC</if>
|
107
|
103
|
<if test="read.rorder=='readcount'">ORDER BY readcount DESC</if>
|
108
|
104
|
</select>
|