Browse Source

志愿者活动排序

feature/syp_points
songyunpeng 5 years ago
parent
commit
0e5991d3f2
  1. 4
      esua-epdc/epdc-module/epdc-heart/epdc-heart-server/src/main/resources/mapper/activity/ActInfoDao.xml

4
esua-epdc/epdc-module/epdc-heart/epdc-heart-server/src/main/resources/mapper/activity/ActInfoDao.xml

@ -164,7 +164,7 @@
when <![CDATA[ DATE_FORMAT(actInfo.ACT_END_TIME,'%Y-%m-%d %H:%i:%s') < ]]> #{timestamp}
then '4'
end as actCurrentState,
IF(relation.USER_ID = #{userId},'1','0') as signupFlag
IF(relation.USER_ID = #{userId},'1','0') as signupFlag,actInfo.CREATED_TIME
FROM
epdc_act_info actInfo
left join epdc_act_user_relation relation on relation.DEL_FLAG = '0'
@ -182,7 +182,7 @@
<![CDATA[ AND DATE_FORMAT(actInfo.ACT_END_TIME,'%Y-%m-%d %H:%i:%s') <= ]]> #{timestamp}
</if>
) temp
ORDER BY temp.actCurrentState ASC
ORDER BY temp.actCurrentState ASC,temp.CREATED_TIME desc
<if test='actType != null and actType != "" and actType == "0"'>,temp.PUBLISH_TIME DESC</if>
<if test='actType != null and actType != "" and actType == "1"'>,temp.ACT_START_TIME ASC</if>
LIMIT #{pageIndex},#{pageSize}

Loading…
Cancel
Save