Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add ActiveRecord::Calculations module to ActiveRecord::Base #730

Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions gems/activerecord/6.0/_test/activerecord-generated.rb
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ class Article < ActiveRecord::Base
User.preload(:address, friends: [:address, { followers: :users }]) # steep:ignore FallbackAny
User.in_order_of(:id, [1, 5, 3])
User.offset(5).limit(10)
User.count(:id)

t = User.arel_table
User.limit(10).select(:id, "name", t[:age].as("years"), t[:email])
1 change: 1 addition & 0 deletions gems/activerecord/6.0/activerecord.rbs
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ module ActiveRecord
extend ::ActiveRecord::AttributeMethods::Write::ClassMethods
extend ::ActiveRecord::Attributes::ClassMethods
extend ::ActiveRecord::AutosaveAssociation::ClassMethods
extend ::ActiveRecord::Calculations
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

extend ::ActiveRecord::Core::ClassMethods
extend ::ActiveRecord::CounterCache::ClassMethods
extend ::ActiveRecord::Inheritance::ClassMethods
Expand Down