]> git.koha-community.org Git - koha.git/commit
Bug 17089: Koha::Ratings - Add Koha::Rating[s] classes
authorJonathan Druart <jonathan.druart@bugs.koha-community.org>
Tue, 12 Jul 2016 10:28:25 +0000 (11:28 +0100)
committerKyle M Hall <kyle@bywatersolutions.com>
Fri, 9 Sep 2016 09:29:18 +0000 (09:29 +0000)
commit01631b6e3146906984aa497a2937365dd3b3ab9e
treedf400d4584b9585b45859e8e4c05076ecafdbc80
parenteaa11da5624f308768c4eb2c7016b5cd32c35fb1
Bug 17089: Koha::Ratings - Add Koha::Rating[s] classes

The subroutines in C4::Ratings are only CRUD operations.
This patch set moves the entire module to Koha::Rating[s] based on
Koha::Object[s]

Test plan for the whole patch set:
0/ Set OpacStarRatings to "results and details"
1/ Log in at the OPAC
2/ Launch a search, you should see the star ratings
3/ Go on a detail page, you should see the star ratings
4/ Rate the record
5/ Log in with another patron
6/ Go on the same detail page, you should see the previous rating
7/ Rate the racord, you should see "2 votes" and the average rating
value.
8/ Cancel your rate
9/ Disable JavaScript and repeat 7

Note: You cannot cancel your rate if JavaScript is disabled (not a
regression).

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Koha/Rating.pm [new file with mode: 0644]
Koha/Ratings.pm [new file with mode: 0644]