[#2070] Move rating.py into model.

See: https://github.com/ckan/ckan/issues/2070