mirror of
https://github.com/zulip/zulip.git
synced 2025-11-17 20:41:46 +00:00
models: Add external_account in custom profile field types.
Add new custom profile field type, External account. External account field links user's social media profile with account. e.g. GitHub, Twitter, etc. Fixes part of #12302
This commit is contained in:
committed by
Tim Abbott
parent
3368589df2
commit
d7ee2aced1
@@ -2613,6 +2613,7 @@ class CustomProfileField(models.Model):
|
||||
DATE = 4
|
||||
URL = 5
|
||||
USER = 6
|
||||
EXTERNAL_ACCOUNT = 7
|
||||
|
||||
# These are the fields whose validators require more than var_name
|
||||
# and value argument. i.e. CHOICE require field_data, USER require
|
||||
@@ -2637,6 +2638,7 @@ class CustomProfileField(models.Model):
|
||||
(LONG_TEXT, str(_('Long text')), check_long_string, str, "LONG_TEXT"),
|
||||
(DATE, str(_('Date picker')), check_date, str, "DATE"),
|
||||
(URL, str(_('Link')), check_url, str, "URL"),
|
||||
(EXTERNAL_ACCOUNT, str(_('External account')), check_short_string, str, "EXTERNAL_ACCOUNT"),
|
||||
] # type: FieldTypeData
|
||||
|
||||
ALL_FIELD_TYPES = FIELD_TYPE_DATA + CHOICE_FIELD_TYPE_DATA + USER_FIELD_TYPE_DATA
|
||||
|
||||
Reference in New Issue
Block a user