Bug 17094 - Methods of Koha::Object[s]-based classed should not return DBIx::Class objects
Summary: Methods of Koha::Object[s]-based classed should not return DBIx::Class objects
Status: CLOSED FIXED
Alias: None
Product: Koha
Classification: Unclassified
Component: Architecture, internals, and plumbing (show other bugs)
Version: master
Hardware: All All
: P5 - low enhancement (vote)
Assignee: Jonathan Druart
QA Contact: Testopia
URL:
Keywords:
Depends on: 17091
Blocks: 17249
  Show dependency treegraph
 
Reported: 2016-08-09 16:12 UTC by Jonathan Druart
Modified: 2017-06-14 22:15 UTC (History)
2 users (show)

See Also:
Change sponsored?: ---
Patch complexity: ---
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:


Attachments
Bug 17094: Add delete to the Koha::Objects AUTOLOAD method (2.31 KB, patch)
2016-08-09 16:52 UTC, Jonathan Druart
Details | Diff | Splinter Review
Bug 17094: Make Koha::Virtualshelf methods return Koha::Objects-based objects (7.83 KB, patch)
2016-08-09 16:52 UTC, Jonathan Druart
Details | Diff | Splinter Review
[SIGNED-OFF] Bug 17094: Add delete to the Koha::Objects AUTOLOAD method (2.38 KB, patch)
2016-08-23 23:42 UTC, Aleisha Amohia
Details | Diff | Splinter Review
[SIGNED-OFF] Bug 17094: Make Koha::Virtualshelf methods return Koha::Objects-based objects (7.91 KB, patch)
2016-08-23 23:43 UTC, Aleisha Amohia
Details | Diff | Splinter Review
[PASSED QA] Bug 17094: Make Koha::Virtualshelf methods return Koha::Objects-based objects (8.27 KB, patch)
2016-10-13 10:54 UTC, Martin Renvoize
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Jonathan Druart 2016-08-09 16:12:15 UTC
For instance the 2 methods get_shares and get_contents from Koha::Virtualshelf return DBIx::Class objects instead of Koha::Virtualshelfshares and Koha::Virtualshelfcontents objects.
Comment 1 Jonathan Druart 2016-08-09 16:52:07 UTC Comment hidden (obsolete)
Comment 2 Jonathan Druart 2016-08-09 16:52:10 UTC Comment hidden (obsolete)
Comment 3 Aleisha Amohia 2016-08-23 01:39:47 UTC
fatal: sha1 information is lacking or useless (Koha/Objects.pm).
Comment 4 Jonathan Druart 2016-08-23 10:03:30 UTC
(In reply to Aleisha Amohia from comment #3)
> fatal: sha1 information is lacking or useless (Koha/Objects.pm).

Did you apply all the dependencies?
Comment 5 Aleisha Amohia 2016-08-23 23:42:44 UTC Comment hidden (obsolete)
Comment 6 Aleisha Amohia 2016-08-23 23:43:37 UTC
Created attachment 54796 [details] [review]
[SIGNED-OFF] Bug 17094: Make Koha::Virtualshelf methods return Koha::Objects-based objects

Instead of DBIx::Class objects.

Test plan:
1/ Add content to a list and share it with another patron
2/ Try to view the list with the other patron
3/ download and send a shelf and check if the biblio list is correct
4/ prove t/db_dependent/Virtualshelves.t should return green

Signed-off-by: Aleisha Amohia <aleishaamohia@hotmail.com>
Comment 7 Jonathan Druart 2016-09-08 18:18:33 UTC
Comment on attachment 54795 [details] [review]
[SIGNED-OFF] Bug 17094: Add delete to the Koha::Objects AUTOLOAD method

Moved to bug 17091
Comment 8 Martin Renvoize 2016-10-13 10:54:59 UTC
Created attachment 56345 [details] [review]
[PASSED QA] Bug 17094: Make Koha::Virtualshelf methods return Koha::Objects-based objects

Instead of DBIx::Class objects.

Test plan:
1/ Add content to a list and share it with another patron
2/ Try to view the list with the other patron
3/ download and send a shelf and check if the biblio list is correct
4/ prove t/db_dependent/Virtualshelves.t should return green

Signed-off-by: Aleisha Amohia <aleishaamohia@hotmail.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Comment 9 Brendan Gallagher 2016-10-13 15:25:50 UTC
Pushed to Master - Should be in the November 16.11 Release.  Thanks!