fix: exclude test accounts from leaderboard
Deploy olons-server production / deploy (push) Successful in 4m29s
Deploy olons-server production / deploy (push) Successful in 4m29s
This commit is contained in:
@@ -256,7 +256,7 @@ func (s *Store) TaskLeaderboard(ctx context.Context, tenantID int64, limit int)
|
|||||||
LEFT JOIN hg_sys_attachment a ON a.id=p.avatar_attachment_id AND a.status=1
|
LEFT JOIN hg_sys_attachment a ON a.id=p.avatar_attachment_id AND a.status=1
|
||||||
JOIN hg_trade_order o ON o.tenant_id=m.tenant_id AND o.member_id=m.id
|
JOIN hg_trade_order o ON o.tenant_id=m.tenant_id AND o.member_id=m.id
|
||||||
AND o.order_type=2 AND o.order_status=4
|
AND o.order_type=2 AND o.order_status=4
|
||||||
WHERE m.tenant_id=? AND m.member_status=1 AND m.deleted_at IS NULL
|
WHERE m.tenant_id=? AND m.member_status=1 AND m.is_test_account=2 AND m.deleted_at IS NULL
|
||||||
GROUP BY m.id,m.username,a.file_url
|
GROUP BY m.id,m.username,a.file_url
|
||||||
ORDER BY claimed_points DESC,m.id ASC LIMIT ?`, tenantID, limit)
|
ORDER BY claimed_points DESC,m.id ASC LIMIT ?`, tenantID, limit)
|
||||||
return rows, err
|
return rows, err
|
||||||
|
|||||||
Reference in New Issue
Block a user