Skip to content
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

Feature: add bulk library actions #59

Merged
merged 2 commits into from
Aug 29, 2024

Conversation

rhell4
Copy link

@rhell4 rhell4 commented Aug 28, 2024

This includes:

  • Bulk update libraries to latest versions
  • Bulk upgrade content to latest library version (button will be disabled if there is no content that needs upgrading)
  • Bulk export libraries (for importing to another site)
  • Bulk import is already a feature using the existing "Upload Libraries"

You'll find the 3 new buttons on the /mod/hvp/library_list.php page
2024-08-28_11-20

I tested these new options using the following 2 H5Ps in this zip; test-h5p.zip
Both H5Ps are using older libraries, so you should be able to test updating the libraries and the content.

When updating the libraries ensure the content type cache is up to date using the "Update content type cache" at the top of the page because this is required to check if a library has a newer version.

For the bulk export/import, I ran the export on the site I was testing on and then imported into a clean new site I had.

I've also fixed some PHP warnings/deprecations that were filling up the screen/logs when updating or uploading libraries.

@rhell4 rhell4 force-pushed the add-bulk-library-actions branch from 7136512 to 75ef957 Compare August 28, 2024 01:41
export_libraries.php Outdated Show resolved Hide resolved
export_libraries.php Outdated Show resolved Hide resolved
update_libraries.php Outdated Show resolved Hide resolved
rhell4 added 2 commits August 28, 2024 16:13
This includes:
- Bulk update libraries to latest versions
- Bulk upgrade content to latest library version
- Bulk export libraries (for importing to another site)
- Bulk import is already a feature using the existing "Upload Libraries"
@rhell4 rhell4 force-pushed the add-bulk-library-actions branch from 75ef957 to ba8f7ef Compare August 28, 2024 06:14
@Peterburnett
Copy link
Collaborator

Thanks Rossco, this is looking great!. For any future folks, CI is cooked due a ton of lint errors from the main repo, but the tests are passing.

@Peterburnett Peterburnett merged commit 22f233d into stable-catalyst-400 Aug 29, 2024
7 of 24 checks passed
@Peterburnett Peterburnett deleted the add-bulk-library-actions branch August 29, 2024 01:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants