Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Functionality for exporting h5p nodes to h5p packages.
Comment | File | Size | Author |
---|---|---|---|
#7 | 2120227-h5p-export.patch | 13.19 KB | gafolini |
Comments
Comment #1
gafolini CreditAttribution: gafolini commentedPatch attatched.
Comment #2
falcon CreditAttribution: falcon commentedGreat work!
I did a brief code review, and it looks good. I find a few things that needs to be checked before I install and test the patch:
1. Library dependencies stored in h5p_nodes_libraries are the dependencies that needs to go into h5p.json. The editor stores the libraries that are actually beeing used by a node here.
2. Requests to the export url will result in an export even if export is turned of. Need to disable the menu path if export is switched off
3. Doesn't seem to handle the difference between preloaded and dynamic dependencies
4. If the node has a language use that language, if not use 'und'
5. The code below needs some comments and variable renaming, I had to read it twice:
Comment #3
Ellinokon CreditAttribution: Ellinokon commentedA new patch addressing the code review is attached.
Comment #4
Ellinokon CreditAttribution: Ellinokon commentedPrevious patch didn't contain the right code for cleaning up the temp directory. Attached is a new patch with the full code, to replace the one uploaded yesterday.
Comment #5
falcon CreditAttribution: falcon commentedAnother quick code review here:
When these small adjustments have been made we are good to go.
Comment #6
falcon CreditAttribution: falcon commentedComment #7
gafolini CreditAttribution: gafolini commentedThink we finished the remaining issues.
Comment #8
falcon CreditAttribution: falcon commentedGreat work! Thanks!
I made a few changes and added this feature to the beta16 release.