]> git.koha-community.org Git - koha.git/commit
Bug 17501: Move getCategories and httpheaders from Upload.pm
authorMarcel de Rooy <m.de.rooy@rijksmuseum.nl>
Thu, 24 Nov 2016 08:27:23 +0000 (09:27 +0100)
committerKyle M Hall <kyle@bywatersolutions.com>
Fri, 20 Jan 2017 14:20:05 +0000 (14:20 +0000)
commitba5cd2455327c8eddc4c5e9c90642398b210a680
treedfbda46a5ae4d2de1d84d03aed26c9b8731637b3
parent158442eb9e3658e22c54a3315caa57673e6940ab
Bug 17501: Move getCategories and httpheaders from Upload.pm

Class method getCategories has no strict binding to Upload.pm. While
Upload.pm is now restricted to the actual uploading process with CGI
hook, this routine fits better in the UploadedFile package.

Class method httpheaders can be moved as well for the same reason. Note
that it actually is an instance method. The parameter $name is dropped.

Test plan:
[1] Run t/db_dependent/Upload.t.
[2] Check the categories in the combo box of tools/upload.
[3] Check a download via tools/upload and opac-retrieve-file.

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Koha/Upload.pm
Koha/UploadedFile.pm
opac/opac-retrieve-file.pl
t/db_dependent/Upload.t
tools/upload.pl