Merge pull request #25348 from edx/ddumesnil/add-cert-to-linkedin-aa-385-2

AA-385: Adding in migration for LinkedInAddToProfileConfiguration
This commit is contained in:
Dillon Dumesnil
2020-10-19 10:53:27 -07:00
committed by GitHub
4 changed files with 31 additions and 19 deletions

View File

@@ -0,0 +1,26 @@
# Generated by Django 2.2.16 on 2020-10-09 19:50
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('student', '0036_userpasswordtogglehistory'),
]
operations = [
migrations.RemoveField(
model_name='linkedinaddtoprofileconfiguration',
name='dashboard_tracking_code',
),
migrations.RemoveField(
model_name='linkedinaddtoprofileconfiguration',
name='trk_partner_name',
),
migrations.AlterField(
model_name='linkedinaddtoprofileconfiguration',
name='company_identifier',
field=models.TextField(blank=True, help_text='Your organization ID (if your organization has an existing page on LinkedIn) e.g 1337. If not provided, will default to sending Platform Name (e.g. edX) instead.'),
),
]

View File

@@ -2545,24 +2545,11 @@ class LinkedInAddToProfileConfiguration(ConfigurationModel):
}
company_identifier = models.TextField(
help_text=_(
u"The company identifier for the LinkedIn Add-to-Profile button "
u"e.g 0_0dPSPyS070e0HsE9HNz_13_d11_"
)
)
# Deprecated
dashboard_tracking_code = models.TextField(default=u"", blank=True)
trk_partner_name = models.CharField(
max_length=10,
default="",
blank=True,
help_text=_(
u"Short identifier for the LinkedIn partner used in the tracking code. "
u"(Example: 'edx') "
u"If no value is provided, tracking codes will not be sent to LinkedIn."
)
'Your organization ID (if your organization has an existing page on LinkedIn) e.g 1337. '
'If not provided, will default to sending Platform Name (e.g. edX) instead.'
),
)
def is_enabled(self, *key_fields):

View File

@@ -106,9 +106,7 @@
"change_date": "2050-06-15 11:02:13.007790+00:00",
"changed_by": 99,
"enabled": true,
"dashboard_tracking_code": "edx-course-v1&TESTCOURSE",
"company_identifier": "7nTFLiuDkkQkdELSpruCwD4F6jzqtTFsx3PfJUIT2qHqXRLG1",
"trk_partner_name": "edx"
"company_identifier": 1337
}
},
{

View File

@@ -2754,6 +2754,7 @@ MKTG_URL_LINK_MAP = {
'ROOT': 'root',
'TOS': 'tos',
'HONOR': 'honor', # If your site does not have an honor code, simply delete this line.
'TOS_AND_HONOR': 'edx-terms-service',
'PRIVACY': 'privacy',
'PRESS': 'press',
'BLOG': 'blog',