Enable users to copy a course to create a new course

Bug #1929588 reported by Beth Willis
10
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Evergreen
Fix Committed
Wishlist
Unassigned

Bug Description

Users should be able to create a new course by copying the contents of an existing course. This is a different feature from the existing feature that allows users to associate a course with multiple terms. Users may want to copy a course if there is another course that is similar to, but not the same as, the existing course.

Revision history for this message
Kyle Huckins (khuckins) wrote :

I've pushed a branch here: https://git.evergreen-ils.org/?p=working/Evergreen.git;a=shortlog;h=refs/heads/user/khuckins/lp1929588-duplicate-course

This supplies a grid action to duplicate selected courses, copying specifically the name, course number, section number, owning library, and archived status. It doesn't copy over materials, users, or term information

tags: added: pullrequest
Revision history for this message
Jennifer Pringle (jpringle-u) wrote :

Duplicating works as advertised but I'm not sure how useful this is if there aren't options to copy over materials, users, and term information.

To distinguish between your original course and your duplicated course you likely need to edit some aspect of the course on the Edit Course screen anyways.

I could see if you had multiple sections of a course it would be handy to set up everything that's the same (term, materials, maybe users), duplicate the course as many times as you need for your sections and then edit the duplicates to add the information specific to the section. Maybe there's required reading that's the same across all sections, but different optional texts.

I work with academic libraries but not in one so I'd love to hear what people who actually do course reserves think.

tags: added: needsdiscussion
Revision history for this message
Gina Monti (gmonti90) wrote :

Trying to test this for Feedback Fest. I do see a Copy to Clipboard but unsure how the bug fix 'works'. Is the feature supposed to just show up? When pasting into the form, it's a long string in one field.

Revision history for this message
Kyle Huckins (khuckins) wrote :

That's a good point Jennifer - I'm operating on the assumption that you wouldn't want to copy over users at the very least(unless it's non-public users?). Materials weren't copied over as it could be problematic with how materials are tied to specific copies. +1 to needsdiscussion

Gina, on the Course List, if you select a Course from the grid and either right click or go to actions, there should be a Duplicate Course option - that will create a new instance of the course, which can then be edited.

Revision history for this message
Gina Monti (gmonti90) wrote :

I also see that the duplicate action works but without copying materials, roles, and terms over. The duplicate course also has the same name without an indication of which is the duplicate and which is the original.

Revision history for this message
Terran McCanna (tmccanna) wrote :

Perhaps the duplicated course could have " (copy)" or something similar appended to the title?

Revision history for this message
Jennifer Pringle (jpringle-u) wrote :

+1 to Terran's suggestion. I like the idea of having some text like "copy" to show which is the duplicate

Revision history for this message
Kyle Huckins (khuckins) wrote :

I've pushed up a quick commit implementing Terran's suggestion

Changed in evergreen:
importance: Undecided → Wishlist
Changed in evergreen:
status: New → Confirmed
Revision history for this message
Jane Sandberg (sandbergja) wrote :

Thank you, Kyle! I've signed off on this at user/sandbergja/lp1929588-duplicate-course-signoff

It also includes a follow-up commit to make the (Copy) string translatable.

Michele Morgan (mmorgan)
tags: added: signedoff
Galen Charlton (gmc)
Changed in evergreen:
assignee: nobody → Galen Charlton (gmc)
milestone: none → 3.10-beta
Revision history for this message
Galen Charlton (gmc) wrote :

Tested and removing signoff:

[1] If more than one course is selected for duplication, the new courses take their title only from the last selected course. Either this behavior should be corrected or the action should be permitted only when exactly one course is selected.
[2] There's some ng lint noise.

Regarding the original discussion, I note that ALEPH does include an option to copy over the reading list items when you duplicate a course. I think adding an option to copy over materials would make the feature more useful, but would entail some changes to open-ils.courses.detach_material and friends to handle the case where an item is associated with more than one course.

I would be fine merging a don't-copy-over-materials branch, by the way, once #1 and #2 are addressed.

tags: removed: signedoff
Jason Boyer (jboyer)
tags: added: needswork
removed: pullrequest
Revision history for this message
Jane Sandberg (sandbergja) wrote :

Since there are outstanding issues noted on the slush date (today), I'm removing the 3.10 target.

Changed in evergreen:
milestone: 3.10-beta → 3.next
Galen Charlton (gmc)
Changed in evergreen:
assignee: Galen Charlton (gmc) → nobody
Revision history for this message
Jane Sandberg (sandbergja) wrote :

Updated branch pushed to user/sandbergja/lp1929588-duplicate-course-signoff, which:
1. rebases on main
2. adds a fourth commit to address the issues that Galen identified.

When/if this is merged, I think we should open a second ticket to copy over the materials.

tags: added: pullrequest
removed: needswork
Changed in evergreen:
milestone: 3.next → 3.12-beta
Andrea Neiman (aneiman)
Changed in evergreen:
assignee: nobody → Andrea Neiman (aneiman)
Andrea Neiman (aneiman)
Changed in evergreen:
assignee: Andrea Neiman (aneiman) → nobody
Revision history for this message
Jane Sandberg (sandbergja) wrote :

Here's a brief test plan for this feature:

1. Go to Local Administration > Course Reserves List
2. Create several new courses. All fields are required except the section number
3. Select a subset of the courses you've created.
4. On the grid actions menu, choose duplicate selected.
5. Confirm that those courses now have duplicates, each with the word (Copy) after the course name.

Revision history for this message
Jane Sandberg (sandbergja) wrote :

Thanks, Kyle! Pushed to main for inclusion in 3.12.

Changed in evergreen:
assignee: nobody → Jane Sandberg (sandbergja)
assignee: Jane Sandberg (sandbergja) → nobody
status: Confirmed → Fix Committed
tags: added: signedoff
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.