|
|
|
@ -8,13 +8,14 @@ |
|
|
|
<result property="groupBuyStatus" column="groupBuyStatus"/> |
|
|
|
<result property="groupBuyPublishTime" column="groupBuyPublishTime"/> |
|
|
|
<result property="topFlag" column="TOP_FLAG"/> |
|
|
|
<result property="pickupMethod" column="PICKUP_METHOD"/> |
|
|
|
<collection property="groupBuyImg" ofType="java.lang.String"> |
|
|
|
<result property="image" column="IMG_URL"/> |
|
|
|
</collection> |
|
|
|
</resultMap> |
|
|
|
<select id="getGroupBuyList" |
|
|
|
resultMap="getGroupBuyListMap"> |
|
|
|
select egbi.ID, egbi.GROUP_BUY_TITLE, egbi.groupBuyStatus, egbi.groupBuyPublishTime, egbi.TOP_FLAG,t1.IMG_URL |
|
|
|
select egbi.ID, egbi.GROUP_BUY_TITLE, egbi.groupBuyStatus, egbi.groupBuyPublishTime, egbi.TOP_FLAG,egbi.PICKUP_METHOD,t1.IMG_URL |
|
|
|
from ( |
|
|
|
select t.ID, |
|
|
|
t.GROUP_BUY_TITLE, |
|
|
|
@ -22,7 +23,8 @@ |
|
|
|
t.CREATED_TIME as groupBuyPublishTime, |
|
|
|
t.TOP_FLAG, |
|
|
|
t.TOP_TIME, |
|
|
|
t.CREATED_TIME |
|
|
|
t.CREATED_TIME, |
|
|
|
t.PICKUP_METHOD |
|
|
|
from epdc_group_buy_info t |
|
|
|
where t.DEL_FLAG = '0' |
|
|
|
and t.SHIELD_FLAG = '0' |
|
|
|
@ -43,6 +45,7 @@ |
|
|
|
<result property="cancelReason" column="CANCEL_REASON"/> |
|
|
|
<result property="groupBuyStatus" column="groupBuyStatus"/> |
|
|
|
<result property="groupBuyEndTime" column="GROUP_BUY_END_TIME"/> |
|
|
|
<result property="pickupMethod" column="PICKUP_METHOD"/> |
|
|
|
<collection property="groupBuyImg" ofType="java.lang.String"> |
|
|
|
<result property="image" column="IMG_URL"/> |
|
|
|
</collection> |
|
|
|
@ -74,7 +77,8 @@ |
|
|
|
t2.GROUP_BUY_NUMBER, |
|
|
|
t2.GROUP_BUY_PRICE, |
|
|
|
t1.IMG_URL, |
|
|
|
t.GROUP_BUY_END_TIME |
|
|
|
t.GROUP_BUY_END_TIME, |
|
|
|
t.PICKUP_METHOD |
|
|
|
from epdc_group_buy_info t |
|
|
|
left join |
|
|
|
epdc_custom_img t1 |
|
|
|
@ -103,6 +107,7 @@ |
|
|
|
<result property="groupBuyStatus" column="groupBuyStatus"/> |
|
|
|
<result property="groupBuyPublishTime" column="groupBuyPublishTime"/> |
|
|
|
<result property="isEvaluation" column="isEvaluation"/> |
|
|
|
<result property="pickupMethod" column="PICKUP_METHOD"/> |
|
|
|
<collection property="groupBuyImg" ofType="java.lang.String"> |
|
|
|
<result property="image" column="IMG_URL"/> |
|
|
|
</collection> |
|
|
|
@ -114,6 +119,7 @@ |
|
|
|
egbi.groupBuyStatus, |
|
|
|
egbi.groupBuyPublishTime, |
|
|
|
egbi.isEvaluation, |
|
|
|
egbi.PICKUP_METHOD, |
|
|
|
t1.IMG_URL |
|
|
|
from ( |
|
|
|
select t.ID, |
|
|
|
@ -125,7 +131,8 @@ |
|
|
|
where egbe.DEL_FLAG = '0' |
|
|
|
and egbe.USER_ID = t2.USER_ID |
|
|
|
and egbe.GROUP_BUY_ID = t.ID) = 0, 0, 1) isEvaluation, |
|
|
|
t.CREATED_TIME |
|
|
|
t.CREATED_TIME, |
|
|
|
t.PICKUP_METHOD |
|
|
|
from epdc_group_buy_info t |
|
|
|
left join epdc_group_buy_sign_up t2 on t2.GROUP_BUY_ID = t.ID and t2.DEL_FLAG = '0' |
|
|
|
where t.DEL_FLAG = '0' |
|
|
|
@ -146,6 +153,7 @@ |
|
|
|
<result property="groupBuyStatus" column="groupBuyStatus"/> |
|
|
|
<result property="groupBuyPublishTime" column="groupBuyPublishTime"/> |
|
|
|
<result property="isEdit" column="isEdit"/> |
|
|
|
<result property="pickupMethod" column="PICKUP_METHOD"/> |
|
|
|
<collection property="groupBuyImg" ofType="java.lang.String"> |
|
|
|
<result property="image" column="IMG_URL"/> |
|
|
|
</collection> |
|
|
|
@ -157,6 +165,7 @@ |
|
|
|
egbi.groupBuyStatus, |
|
|
|
egbi.groupBuyPublishTime, |
|
|
|
egbi.isEdit, |
|
|
|
egbi.PICKUP_METHOD, |
|
|
|
t1.IMG_URL |
|
|
|
from( |
|
|
|
select t.ID, |
|
|
|
@ -164,7 +173,8 @@ |
|
|
|
if(t.GROUP_BUY_STATUS = '0' and t.GROUP_BUY_END_TIME is not null and t.GROUP_BUY_END_TIME < now(),4,t.GROUP_BUY_STATUS) as groupBuyStatus, |
|
|
|
t.CREATED_TIME as groupBuyPublishTime, |
|
|
|
if(t.GROUP_BUY_STATUS = 10 or t.GROUP_BUY_STATUS = 5 or t2.ID is not null,0,1)isEdit, |
|
|
|
t.CREATED_TIME |
|
|
|
t.CREATED_TIME, |
|
|
|
t.PICKUP_METHOD |
|
|
|
from epdc_group_buy_info t |
|
|
|
left join |
|
|
|
(select * from epdc_group_buy_sign_up where DEL_FLAG = '0' and SIGN_UP_STATUS != 10 group by GROUP_BUY_ID)t2 |
|
|
|
@ -224,6 +234,7 @@ |
|
|
|
<result property="cancelReason" column="CANCEL_REASON"/> |
|
|
|
<result property="createdTime" column="CREATED_TIME"/> |
|
|
|
<result property="groupBuyEndTime" column="GROUP_BUY_END_TIME"/> |
|
|
|
<result property="pickupMethod" column="PICKUP_METHOD"/> |
|
|
|
<collection property="prices" ofType="com.elink.esua.epdc.dto.GroupBuyPriceNumberDTO"> |
|
|
|
<result property="groupBuyNumber" column="GROUP_BUY_NUMBER"/> |
|
|
|
<result property="groupBuyPrice" column="GROUP_BUY_PRICE"/> |
|
|
|
@ -249,7 +260,8 @@ |
|
|
|
n.GROUP_BUY_NUMBER, |
|
|
|
n.GROUP_BUY_PRICE, |
|
|
|
img.IMG_URL, |
|
|
|
i.GROUP_BUY_END_TIME |
|
|
|
i.GROUP_BUY_END_TIME, |
|
|
|
i.PICKUP_METHOD |
|
|
|
FROM |
|
|
|
`epdc_group_buy_info` i |
|
|
|
LEFT JOIN epdc_group_buy_price_number n ON n.GROUP_BUY_ID = i.ID |
|
|
|
|