fix: allow user provided value if can auto-create orgs [FC-0076]#1582
Conversation
|
Thanks for the pull request, @pomegranited! This repository is currently maintained by @openedx/2u-tnl. Once you've gone through the following steps feel free to tag them in a comment and let them know that your changes are ready for engineering review.
|
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #1582 +/- ##
==========================================
+ Coverage 92.97% 93.08% +0.10%
==========================================
Files 1075 1092 +17
Lines 21205 21625 +420
Branches 4576 4661 +85
==========================================
+ Hits 19715 20129 +414
- Misses 1418 1424 +6
Partials 72 72 ☔ View full report in Codecov by Sentry. |
|
@pomegranited The test was fixed once I used async version of |
navinkarkera
left a comment
There was a problem hiding this comment.
👍 Looks good! @pomegranited
- I tested this: (Tried creating org via new lib page and course page)
- I read through the code
- I checked for accessibility issues
- Includes documentation
…nedx#1582) Allows Content Authors to auto-create an organization when creating a library, if auto-creating orgs is allowed by the platform.
…edx#1582) * feat: extend CourseOutlineSidebarTriggerSlot props * feat: Remove courseId from CourseOutlineSidebarTriggerPlugin props * feat: update useContextId to use courseware data along with coursehome * feat: extend useCourseOutlineSidebar values with sequenceStatus
Description
Allows Content Authors to auto-create an organization when creating a library, if auto-creating orgs is allowed by the platform.
Org.autocreate.-.Made.with.Clipchamp.mp4
Supporting information
Part of: #1577
Depends on: openedx/openedx-platform#36094 <-- this PR must be merged first.
Testing instructions
With cms
settings.ORGANIZATIONS_AUTOCREATE = True(default):NewOrgShould redirect to the new library's page and auto-create the organization.
With cms
settings.ORGANIZATIONS_AUTOCREATE = False:NewOrg2Should not allow the library (or organization) to be created, and instead show "Required field" under the Organization field.
Author Notes & Concerns:
OrganizationField. which I then modified to useForm.Autosuggestinstead ofDropdownto preserve "Create Library"'s auto-complete functionality.This works fine, but was a bigger change, so I decided against it.