https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=23649
--- Comment #5 from Björn Nylén <[email protected]> --- More interesting things can be done eg. maths: In this case we want to promote newer books over older. So define a new numeric field 'pubyear-numeric' in the ES mappings and map it to 008/07-10. After some existance- and sanity-checking we weight records (in this case) newer than 1980 higher. - script_score: script: source: "long y = doc['pubyear-numeric'].size()==0 ? params.start : doc['pubyear-numeric'].value; y = (y<params.start || y>2100) ? params.start : y; return (y-params.start)/params.divider+1;" params: start: 1980 divider: 20 -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes. _______________________________________________ Koha-bugs mailing list [email protected] https://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
