Show both course id and the archive file when they differ when listing course archives in the admin course. - #3116
Merged
Alex-Jordan merged 2 commits intoAug 6, 2026
Conversation
…ives in the admin course.
The previous setup did not take into account what would happen if
multiple archive files contained the same course id. So instead of the
`listArchivedCourse` method returning a hash of the form
```perl
{
myTestCourse => {
filename => 'myTestCourse.tar.gz',
size => '605 KB'
}
}
```
it now returns a hash of the form
```perl
{
'myTestCourse.tar.gz' => {
courseID => 'myTestCourse',
size => '605 KB',
lastModified => 1778667472
}
}
```
Note that the `lastModified` key is only included because that is what
is saved in the cache file, and that is just directly returned if the
archive file has not been modified. Although, at this point it is not
used elsewhere.
Both the courseID and the filename are then displayed. The format
displayed is `myTestCourse (myTestCourse.tar.gz, 605 KB)`.
If there is also an archive file `myTestCourseAlt.tar.gz` then it will
also be listed as something like`myTestCourse (myTestCourseAlt.tar.gz, 1.6 MB)`.
somiaj
approved these changes
Aug 6, 2026
Contributor
|
Would adding some help to describe when the filename is listed be helpful for those who may not understand why sometimes the filename is there and others it isn't? |
Member
Author
|
I don't know. I think that most of the time the file names will not be shown at all. Those that do should be able to figure it out. |
Member
Author
|
Also, there isn't really a good way to add help here. There is not a help for the course listings page, and I wouldn't want the popover help here. |
Alex-Jordan
approved these changes
Aug 6, 2026
Alex-Jordan
added a commit
that referenced
this pull request
Aug 6, 2026
…lt-hotfix Show both course id and the archive file when they differ when listing course archives in the admin course. (hotfix of #3116)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This is an alternate to #3114.