-
Notifications
You must be signed in to change notification settings - Fork 3.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[BB-5819] Make course description editable in certs #29850
[BB-5819] Make course description editable in certs #29850
Conversation
Thanks for the pull request, @pkulkark! As a core committer in this repo, you can merge this once the pull request is approved per the core committer reviewer requirements and according to the agreement with your edX Champion. |
'{partner_short_name}.').format( | ||
partner_short_name=context['organization_short_name'], | ||
platform_name=platform_name) | ||
context['accomplishment_copy_course_description'] = context['certificate_data'].get('course_description', '') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@pkulkark actually, setting the default value to empty means that we take away the default text. I think this is something we wouldn't like to do as it could cause confusion -- why isn't the a course of study offered by {partner_short_name}...
text is there.
I would suggest having the course description as an override. If the value is set, we don't care about the default text, otherwise we default to the removed condition.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good point. Made the changes.
if context['certificate_data'].get('course_description', ''): | ||
context['accomplishment_copy_course_description'] = context['certificate_data']['course_description'] | ||
elif context['organization_long_name']: | ||
# Translators: This text represents the description of course | ||
context['accomplishment_copy_course_description'] = _('a course of study offered by {partner_short_name}, ' | ||
'an online learning initiative of ' | ||
'{partner_long_name}.').format( | ||
partner_short_name=context['organization_short_name'], | ||
partner_long_name=context['organization_long_name'], | ||
platform_name=platform_name) | ||
else: | ||
# Translators: This text represents the description of course | ||
context['accomplishment_copy_course_description'] = _('a course of study offered by ' | ||
'{partner_short_name}.').format( | ||
partner_short_name=context['organization_short_name'], | ||
platform_name=platform_name) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for the changes @pkulkark, just a small nit, feel free to ignore it. It may not help the formatting a lot at all. How about this?
course_description_override = context['certificate_data'].get('course_description')
if course_description_override:
accomplishment_copy_course_description = course_description_override
elif context['organization_long_name']:
# Translators: This text represents the description of course
accomplishment_copy_course_description = _(
'a course of study offered by {partner_short_name}, '
'an online learning initiative of '
'{partner_long_name}.'
).format(
partner_short_name=context['organization_short_name'],
partner_long_name=context['organization_long_name'],
platform_name=platform_name,
)
else:
# Translators: This text represents the description of course
accomplishment_copy_course_description = _('a course of study offered by {partner_short_name}.').format(
partner_short_name=context['organization_short_name'],
platform_name=platform_name,
)
context['accomplishment_copy_course_description'] = accomplishment_copy_course_description
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Added it
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍 🎉 The changes are working great by the way!
I tested what's in the test instructions
I read through the code
4dec732
to
1cfbdcf
Compare
@natabene This is good for edX's review. |
@pkulkark Thank you for your contribution. |
db62308
to
a89baaf
Compare
Thanks for your review @gabor-boros, it was very helpful to read through. I will try to get eyes on this and merge it soon. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm hesitant to add complexity to this feature that we want to extract to the credentials service in the long run. If you have specific needs for this feature would you be willing to participate in some roadmap planning we are going to be starting?
@pkulkark, @gabor-boros, do we have any plans on this PR? Asking, because we carry it in our shared branch from a release to release. |
@pkulkark @gabor-boros Just checking in on this to see if there are plans to move forward with this? |
Hello @mphilbrick211, As @pkulkark is the author and I'm no longer on that given project that this PR belongs to, @pkulkark do we still need this PR? |
@mphilbrick211 This was put on hold because of the plan to move course certs to credential service. But it looks like that's going take a while. It's not a very high risk change so we could probably move ahead with this if there's no objection. What do you think? |
Hi @hurtstotouchfire - please see the comment above from @pkulkark - I'm not sure if this should move forward, could you please advise? It looks like you requested some changes a while back. |
@hurtstotouchfire - flagging this comment again to see if this should move forward. Thanks! |
@hurtstotouchfire just checking to see if this is still being pursued? If so, we'll need to have Product take a look as well. |
@mphilbrick211 Imo this could move forward. As @hurtstotouchfire notes, it's a low risk change. We have all the requisite info needed for product review here, and the next step would be for me/Ryan to assign it to Claire Zhang to complete the product review. |
@mphilbrick211 Sorry, as you may have noticed I miss a lot of github pings due to signal to noise issues, and it's best to ping me in slack. From my perspective, this adds an additional field which would need to be migrated to Credentials when we extract course certs. Description is also a larger and more complex field than title, so it's a step beyond the current precedent in terms of complexity. Here's what I would like to see from product:
|
Hi @pkulkark! We've had a couple new tests pop up that need to be run (e.g. "shellcheck") - would you mind re-running these while this PR is in product review? Thanks! |
a89baaf
to
db94c07
Compare
@mphilbrick211 Sorry for the delay in getting back on this. I've just rebased it to latest master and started the tests. |
Adds the ability to edit the default course description shown in certificates.
db94c07
to
f507dbe
Compare
@mphilbrick211 Just following up on this - can this be merged soon? |
hi @pkulkark - I believe this is still under Product review. Flagging for @openedx/2u-aperture and @jmakowski1123 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is still very far from viable from my perspective. I would still like to see a clear set of requirements from Product and a sense of the level of need, but from there we would also need to work through several other questions about the particulars of how this feature should work, such as:
- What does the field need to support? HTML? Django templating commands? Does it have a character limit?
- How would this behave in existing templates? The OSPR updates the base templates but any existing templates in live instances will need to be manually updated to support this field.
- Given that it requires updating all of your current templates to support this field, operators should have the ability to disable this feature if they do not plan to support it.
I think there is probably more that would come up if we thought through the requirements for this and really laid out all of the implications. But generally speaking, I don't feel this is production-ready as a feature.
Thanks for the pull request, @pkulkark! Please note that it may take us up to several weeks or months to complete a review and merge your PR. Feel free to add as much of the following information to the ticket as you can:
All technical communication about the code itself will be done via the GitHub pull request interface. As a reminder, our process documentation is here. Please let us know once your PR is ready for our review and all tests are green. |
Closing for now per Jenna's comment. |
@pkulkark Even though your pull request wasn’t merged, please take a moment to answer a two question survey so we can improve your experience in the future. |
Description
This PR makes the default description text that appears under the course title editable/configurable for certificates.
Supporting information
JIRA tickets: BB-5819
Screenshots
Creating new certificates:
Testing instructions
Reviewers: