{"id":13879011,"url":"https://github.com/shioyama/mobility-ransack","last_synced_at":"2025-03-17T01:31:54.497Z","repository":{"id":32975691,"uuid":"148417130","full_name":"shioyama/mobility-ransack","owner":"shioyama","description":"Search attributes translated by Mobility with Ransack","archived":false,"fork":false,"pushed_at":"2023-03-04T06:48:14.000Z","size":72,"stargazers_count":29,"open_issues_count":2,"forks_count":10,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-03-15T02:39:28.282Z","etag":null,"topics":["i18n","rails","ransack","ruby","translation"],"latest_commit_sha":null,"homepage":null,"language":"Ruby","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/shioyama.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE.txt","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null}},"created_at":"2018-09-12T03:39:32.000Z","updated_at":"2025-01-22T23:39:58.000Z","dependencies_parsed_at":"2024-01-13T20:56:29.273Z","dependency_job_id":"24e9aae7-b81a-4c62-9a69-a02a5bf79a11","html_url":"https://github.com/shioyama/mobility-ransack","commit_stats":{"total_commits":70,"total_committers":9,"mean_commits":7.777777777777778,"dds":0.2571428571428571,"last_synced_commit":"142454c0a944581a9896ad1cb0b8ee33bd2885e3"},"previous_names":[],"tags_count":13,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shioyama%2Fmobility-ransack","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shioyama%2Fmobility-ransack/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shioyama%2Fmobility-ransack/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shioyama%2Fmobility-ransack/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/shioyama","download_url":"https://codeload.github.com/shioyama/mobility-ransack/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243676697,"owners_count":20329431,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["i18n","rails","ransack","ruby","translation"],"created_at":"2024-08-06T08:02:06.889Z","updated_at":"2025-03-17T01:31:54.179Z","avatar_url":"https://github.com/shioyama.png","language":"Ruby","funding_links":[],"categories":["Ruby"],"sub_categories":[],"readme":"Mobility Ransack\n================\n\n[![Gem Version](https://badge.fury.io/rb/mobility-ransack.svg)][gem]\n[![Build Status](https://github.com/shioyama/mobility-ransack/workflows/CI/badge.svg)][actions]\n[![Code Climate](https://api.codeclimate.com/v1/badges/2494f02bcd6b65a545fa/maintainability.svg)][codeclimate]\n\n[gem]: https://rubygems.org/gems/mobility-ransack\n[actions]: https://github.com/shioyama/mobility-ransack/actions\n[codeclimate]: https://codeclimate.com/github/shioyama/mobility-ransack\n\nSearch on translated attributes with\n[Mobility](https://github.com/shioyama/mobility) and\n[Ransack](https://github.com/activerecord-hackery/ransack).\n\n## Installation\n\nJust add the gem to your Gemfile:\n\n```ruby\ngem 'mobility-ransack', '~\u003e 1.2.2'\n```\n\nNow enable the `ransack` plugin in Mobility's configuration:\n\n```ruby\nMobility.configure do\n  plugins do\n    ransack\n\n    # ...\n  end\nend\n```\n\nThis will enable the ransack plugin for all models. Disable it by passing\n`false` to the `ransack` option:\n\n```ruby\nclass Post \u003c ApplicationRecord\n  extend Mobility\n  translates :foo, ransack: false\nend\n```\n\nYou can search on `foo` with Ransack just like any untranslated attribute, e.g.\nif `Post` has a `title` attribute translated with the Jsonb backend:\n\n```ruby\nPost.ransack(title_cont: \"foo\").result\n#=\u003e SELECT \"posts\".* FROM \"posts\" WHERE (\"posts\".\"title\" -\u003e\u003e 'en') ILIKE '%foo%'\n```\n\nOther backends work exactly the same way.\n\n## License\n\nThe gem is available as open source under the terms of the [MIT License](https://opensource.org/licenses/MIT).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fshioyama%2Fmobility-ransack","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fshioyama%2Fmobility-ransack","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fshioyama%2Fmobility-ransack/lists"}