aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack/test/controller/output_escaping_test.rb
diff options
context:
space:
mode:
authorRoque Pinel <repinel@gmail.com>2015-06-21 15:46:08 -0400
committerRoque Pinel <repinel@gmail.com>2015-06-30 17:36:51 -0500
commitb220c9f9b4cc5b17af40b09046501f3469929a11 (patch)
treea163a761ea0bdacf428b3c7dbe7ecc5fd57a49d3 /actionpack/test/controller/output_escaping_test.rb
parentbc6ac8609cf79f28047c0928b9433e00e6ea1f09 (diff)
downloadrails-b220c9f9b4cc5b17af40b09046501f3469929a11.tar.gz
rails-b220c9f9b4cc5b17af40b09046501f3469929a11.tar.bz2
rails-b220c9f9b4cc5b17af40b09046501f3469929a11.zip
Allow select with Arel and count as well as calculations with Arel
It allows a query like `User.select(:name).count` to be written using Arel as `User.select(User.arel_table[:name]).count`. It exposes the calculations API to accept Arel nodes: `User.count(User.arel_table[:name])`, `User.sum(User.arel_table[:id])`, `Account.average(Account.arel_table[:credit_limit])`, `Account.maximum(Account.arel_table[:credit_limit])` and `Account.minimum(Account.arel_table[:credit_limit])`.
Diffstat (limited to 'actionpack/test/controller/output_escaping_test.rb')
0 files changed, 0 insertions, 0 deletions