CHANGELOG.md in ransack-1.5.1 vs CHANGELOG.md in ransack-1.6.0

- old
+ new

@@ -1,60 +1,147 @@ # Change Log -This change log was started in August 2014. All notable changes to this project -henceforth should be documented here. -## Version 1.5.1 - 2014-10-30 +## Version 1.6.0 - 2015-01-12 ### Added -* Add base specs for search on fields with `_start` and `_end`. +* Add support for using Ransack with `Mongoid 4.0` without associations + ([PR #407](https://github.com/activerecord-hackery/ransack/pull/407)). + *Zhomart Mukhamejanov* + +* Add support and tests for passing stringy booleans for ransackable scopes + ([PR #460](https://github.com/activerecord-hackery/ransack/pull/460)). + + *Josh Kovach* + +* Add an sort_link option to not display sort direction arrows + ([PR #473](https://github.com/activerecord-hackery/ransack/pull/473)). + + *Fred Bergman* + +* Numerous documentation improvements to the README, Contributing Guide and + wiki. + *Jon Atack* -* Add a failing spec for detecting attribute fields containing `_and_` that - needs to be fixed. Method names containing `_and_` and `_or_` are still not - parsed/detected correctly. +### Fixed +* Fix passing arrays to ransackers with Rails 4.2 / Arel 6.0 (pull requests + [#486](https://github.com/activerecord-hackery/ransack/pull/486) and + [#488](https://github.com/activerecord-hackery/ransack/pull/488)). + + *Idean Labib* + +* Make `search_form_for`'s default `:as` option respect the custom search key + if it has been set + ([PR #470](https://github.com/activerecord-hackery/ransack/pull/470)). + Prior to this change, if you set a custom `search_key` option in the + Ransack initializer file, you'd have to also pass an `as: :whatever` option + to all of the search forms. Fixes + [#92](https://github.com/activerecord-hackery/ransack/issues/92). + + *Robert Speicher* + +* Fix sorting on polymorphic associations (missing downcase) + ([PR #467](https://github.com/activerecord-hackery/ransack/pull/467)). + + *Eugen Neagoe* + +* Fix Rails 5 / Arel 5 compatibility after the Arel and Active Record API + changed. + +* Fix and add tests for sort_link `default_order` parsing if the option is set + as a string instead of symbol. + +* Fix and add a test to handle `nil` in options passed to sort_link. + +* Fix #search method name conflicts in the README. + *Jon Atack* +### Changed + +* Refactor and DRY up FormHelper#SortLink. Encapsulate parsing into a + Plain Old Ruby Object with few public methods and small, private functional + methods. Limit mutations to explicit methods and mutate no ivars. + +* Numerous speed improvements by using more specific Ruby methods like: + - `Hash#each_key` instead of `Hash#keys.each` + - `#none?` instead of `select#empty?` + - `#any?` instead of `#select` followed by `#any?` + - `#flat_map` instead of `#flatten` followed by `#map` + - `!include?` instead of `#none?` + +* Replace `string#freeze` instances with top level constants to reduce string + allocations in Ruby < 2.1. + +* Remove unneeded `Ransack::` namespacing on most of the constants. + +* In enumerable methods, pass a symbol as an argument instead of a block. + +* Update Travis-ci for Rails 5.0.0 and 4-2-stable. + +* Update the Travis-ci tests and the Gemfile for Ruby 2.2. + +* Replace `#search` with `#ransack` class methods in the README and wiki + code examples. Enabling the `#search` alias by default may possibly be + deprecated in the next major release (Ransack v.2.0.0) to address + [#369](https://github.com/activerecord-hackery/ransack/issues/369). + + *Jon Atack* + +## Version 1.5.1 - 2014-10-30 ### Fixed -* Fix a regression caused by incorrect string constants in context.rb. +* Fix a regression caused by incorrect string constants in `context.rb`. - *Kazuhiro NISHIYAMA* + *Kazuhiro Nishiyama* +### Added + +* Add base specs for search on fields with `_start` and `_end`. + + *Jon Atack* + +* Add a failing spec for detecting attribute fields containing `_and_` that + needs to be fixed. Attribute names containing `_and_` and `_or_` are still + not parsed/detected correctly. + + *Jon Atack* + ### Changed -* Remove duplicate code in spec/support/schema.rb. +* Remove duplicate code in `spec/support/schema.rb`. *Jon Atack* ## Version 1.5.0 - 2014-10-26 ### Added * Add support for multiple sort fields and default orders in Ransack `sort_link` helpers - ([pull request](https://github.com/activerecord-hackery/ransack/pull/438)). - + ([PR #438](https://github.com/activerecord-hackery/ransack/pull/438)). + *Caleb Land*, *James u007* * Add tests for `lteq`, `lt`, `gteq` and `gt` predicates. They are also tested in Arel, but testing them in Ransack has proven useful to detect issues. *Jon Atack* * Add tests for unknown attribute names. - + *Joe Yates* -* Add tests for attribute names containing '_or_' and '_and_'. - +* Add tests for attribute names containing `_or_` and `_and_`. + *Joe Yates*, *Jon Atack* -* Add tests for attribute names ending with '_start' and '_end'. - +* Add tests for attribute names ending with `_start` and `_end``. + *Jon Atack*, *Timo Schilling* * Add tests for `start`, `not_start`, `end` and `not_end` predicates, with emphasis on cases when attribute names end with `_start` and `_end`. @@ -162,11 +249,12 @@ * Refactor Ransack::Translate. * Rewrite much of the Ransack README documentation, including the Associations section code examples and the Authorizations section detailing how to whitelist attributes, associations, sorts and scopes. - + *Jon Atack* + ## Version 1.3.0 - 2014-08-23 ### Added * Add search scopes by popular demand. Using `ransackable_scopes`, users can