|
|
@@ -1309,13 +1309,13 @@ where a.id=#{id,jdbcType=VARCHAR}
|
|
|
ifnull( x.d, 0 ) as commentCount, ifnull( cast(x.a*100 / x.d as decimal(18, 2)), 100 ) as favorableRate
|
|
|
from
|
|
|
`user` u left join user_identity ui on ui.uid = u.id
|
|
|
- left join(select b.seller_id as uid,
|
|
|
+ left join(select b.commodity_id as uid,
|
|
|
sum(case when a.star > 3 then 1 else 0 end) as a,
|
|
|
sum(case when a.star=3 then 1 else 0 end) as b,
|
|
|
sum(case when a.star < 3 then 1 else 0 end) as c,count(*) as d
|
|
|
from jt_commodity_comment a
|
|
|
left join jt_consult_order b on a.order_no=b.order_no
|
|
|
- group by b.seller_id)x on u.id=x.uid
|
|
|
+ group by a.commodity_id)x on u.id=x.uid
|
|
|
left join( select count(*) as count, to_uid from user_interest group by to_uid) a
|
|
|
on u.id = a.to_uid left join( select to_uid from user_interest where from_uid =#{uid,jdbcType=VARCHAR} ) b
|
|
|
on u.id = b.to_uid
|