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

Commit 15fe8d7

Browse files
committed
Merge pull request #441 from appirio-tech/DEM-588-copilot-status-in-profile
add copilot status to user profile
2 parents 4b2515d + 518de5a commit 15fe8d7

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

actions/memberStatistics.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -223,7 +223,8 @@ function getBasicUserProfile(api, handle, privateInfoEligibility, dbConnectionMa
223223
country: basic.country,
224224
memberSince: basic.member_since,
225225
quote: basic.quote,
226-
photoLink: basic.photo_link || ''
226+
photoLink: basic.photo_link || '',
227+
copilot: basic.copilot || false
227228
};
228229

229230
if (loadData.earnings && _.isDefined(basic.show_earnings) && basic.show_earnings !== 'hide') {

queries/get_user_basic_profile_basic

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,10 @@ SELECT
55
, co.quote
66
, p.path || i.file_name AS photo_link
77
, up.value AS show_earnings
8+
, (copilot_profile_id IS NOT NULL) as copilot
89
FROM user u
910
, coder co
11+
, OUTER copilot_profile cp
1012
, OUTER country c
1113
, OUTER(coder_image_xref cix
1214
, image i
@@ -23,3 +25,5 @@ AND i.image_type_id = 1
2325
AND i.path_id = p.path_id
2426
AND u.user_id = up.user_id
2527
AND up.preference_id = 100
28+
AND u.user_id = cp.user_id
29+
AND cp.copilot_profile_status_id = 1

0 commit comments

Comments
 (0)