Skip to content
This repository was archived by the owner on Jan 23, 2025. It is now read-only.

add copilot status to user profile #441

Merged
merged 1 commit into from
Jun 15, 2015
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion actions/memberStatistics.js
Original file line number Diff line number Diff line change
Expand Up @@ -223,7 +223,8 @@ function getBasicUserProfile(api, handle, privateInfoEligibility, dbConnectionMa
country: basic.country,
memberSince: basic.member_since,
quote: basic.quote,
photoLink: basic.photo_link || ''
photoLink: basic.photo_link || '',
copilot: basic.copilot || false
};

if (loadData.earnings && _.isDefined(basic.show_earnings) && basic.show_earnings !== 'hide') {
Expand Down
4 changes: 4 additions & 0 deletions queries/get_user_basic_profile_basic
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,10 @@ SELECT
, co.quote
, p.path || i.file_name AS photo_link
, up.value AS show_earnings
, (copilot_profile_id IS NOT NULL) as copilot
FROM user u
, coder co
, OUTER copilot_profile cp
, OUTER country c
, OUTER(coder_image_xref cix
, image i
Expand All @@ -23,3 +25,5 @@ AND i.image_type_id = 1
AND i.path_id = p.path_id
AND u.user_id = up.user_id
AND up.preference_id = 100
AND u.user_id = cp.user_id
AND cp.copilot_profile_status_id = 1