https://github.com/plataformatec/has_scope this gem simplifies the need to create long hard coded queries that makes the function bloated. is there any chance we can use this to query the data?