From 65a6bc5002baddb511bcc34dd728fcf45c3bebb7 Mon Sep 17 00:00:00 2001 From: attiyaIshaque Date: Thu, 14 Oct 2021 16:45:19 +0500 Subject: [PATCH] feat: [VAN-751] Put user's year of birth behind the feature flag --- .env | 1 + .env.development | 1 + .env.test | 1 + src/account-settings/AccountSettingsPage.jsx | 21 +++++++++++--------- src/index.jsx | 1 + 5 files changed, 16 insertions(+), 9 deletions(-) diff --git a/.env b/.env index de0a81d..3e41fbc 100644 --- a/.env +++ b/.env @@ -25,3 +25,4 @@ SITE_NAME='' STUDIO_BASE_URL='' SUPPORT_URL='' USER_INFO_COOKIE_NAME='' +COLLECT_YEAR_OF_BIRTH='true' diff --git a/.env.development b/.env.development index 05dd4b7..70531ef 100644 --- a/.env.development +++ b/.env.development @@ -26,3 +26,4 @@ SITE_NAME=localhost STUDIO_BASE_URL='' SUPPORT_URL='http://localhost:18000/support' USER_INFO_COOKIE_NAME='edx-user-info' +COLLECT_YEAR_OF_BIRTH='true' diff --git a/.env.test b/.env.test index 5b426af..475c577 100644 --- a/.env.test +++ b/.env.test @@ -25,3 +25,4 @@ SITE_NAME=localhost STUDIO_BASE_URL='' SUPPORT_URL='http://localhost:18000/support' USER_INFO_COOKIE_NAME='edx-user-info' +COLLECT_YEAR_OF_BIRTH='true' diff --git a/src/account-settings/AccountSettingsPage.jsx b/src/account-settings/AccountSettingsPage.jsx index 71432c5..05cea6b 100644 --- a/src/account-settings/AccountSettingsPage.jsx +++ b/src/account-settings/AccountSettingsPage.jsx @@ -583,15 +583,18 @@ class AccountSettingsPage extends React.Component { /> {this.renderSecondaryEmailField(editableFieldProps)} - + {(getConfig().COLLECT_YEAR_OF_BIRTH === 'true') + && ( + + )}