Commit Graph

20048 Commits

Author SHA1 Message Date
David Heinemeier Hansson
39b5ea6e01 Switch from SHA2 to BCrypt (easy Windows compatibility is coming shortly with new compiled gem) 2010-12-18 15:39:32 -08:00
David Heinemeier Hansson
bcf4e4f2b0 Added ActiveRecord::Base#has_secure_password (via ActiveModel::SecurePassword) to encapsulate dead-simple password usage with SHA2 encryption and salting 2010-12-18 13:38:05 -08:00
Piotr Sarnacki
d9b732fcad Fix tests in railties 2010-12-18 21:47:27 +01:00
Piotr Sarnacki
4eb0d580a2 Use gemspec instead of gem rails in Gemfile 2010-12-18 19:42:03 +01:00
Don Wilson
f71809f257 Fixed number_with_precision rounding error [#6182 state:resolved] 2010-12-18 10:00:37 +01:00
Aaron Patterson
5008d33eee dry up case / when statement 2010-12-17 11:31:15 -08:00
Piotr Sarnacki
e22885f3a9 Use require 'bundler/setup' instead of directly calling Bundler.setup in config/boot.rb 2010-12-17 20:30:34 +01:00
Piotr Sarnacki
07567aea5f Revert "Fixed number_with_precision rounding error [#6182 state:resolved]"
This reverts commit 006ec77e60.
2010-12-17 16:11:47 +01:00
Piotr Sarnacki
f7e33620ca Allow to use BUNDLE_GEMFILE env variable in boot.rb [#6184 state:resolved] 2010-12-17 16:10:08 +01:00
Don Wilson
006ec77e60 Fixed number_with_precision rounding error [#6182 state:resolved] 2010-12-17 11:32:19 +01:00
Santiago Pastorino
3b9120fa52 Generate add_index by default when giving type belongs_to or references 2010-12-16 20:58:58 -02:00
Piotr Sarnacki
f176b2552e Changelog and guide entries for config.action_view.cache_template_loading 2010-12-16 22:53:19 +01:00
Piotr Sarnacki
40b15f9f38 ActiveRecord::Base.joins should allow single nil argument [#6181 state:resolved] 2010-12-16 22:25:09 +01:00
Piotr Sarnacki
e89fff2f6b Bring back config.action_view.cache_template_loading [#5847 state:resolved] 2010-12-16 22:24:48 +01:00
Santiago Pastorino
81cf98d342 dragdrop was tested twice and effects.js was missing, added checks for controls.js, dragdrop.js and effects.js to another test 2010-12-16 11:37:11 -02:00
Jon Leighton
14b880fd03 Fix various issues with the :primary_key option in :through associations [#2421 state:resolved] 2010-12-15 17:50:14 -08:00
Jon Leighton
09ddca67ac Fix problem with duplicated records when a :uniq :through association is preloaded [#2447 state:resolved] 2010-12-15 17:47:42 -08:00
Aaron Patterson
6bfa846a2c dry up compute type in attribute 2010-12-15 14:02:30 -08:00
Pavel Gorbokon
96bae30538 Replace rudimentary named_scope with scope. [#6052 state:resolved]
* rename method names (actually in tests)
* rename instance variable @_named_scopes_cache to @_scopes_cache
* rename references in doc comments
* don't touch CHANGELOG :)
2010-12-15 14:02:30 -08:00
Franck Verrot
aa40543022 Provide test for #4840: to_xml doesn't work in such case: Event.select('title as t').to_xml 2010-12-15 14:02:30 -08:00
Víctor Martínez
fe0db2b805 to_xml doesn't work in such case: Event.select('title as t').to_xml [#4840 state:resolved]
NilClass.type is no longer defined in Ruby 1.9 and causes ActiveRecord::Base.to_xml to fail with message: undefined method `type' for nil:NilClass
2010-12-15 14:02:30 -08:00
Vijay Dev
c594f22e65 Merge branch 'master' of github.com:lifo/docrails 2010-12-16 01:51:44 +05:30
Vijay Dev
f96fb78e57 removed info about deprecated rake tasks, documented the sandbox option for the rails console and minor corrections 2010-12-16 01:49:30 +05:30
Pivotal Labs
15984dbe35 test for eager load of has_one association with condition on the through table 2010-12-16 01:49:30 +05:30
Aaron Patterson
4cd3302279 make sure that join nodes are uniq 2010-12-16 01:49:30 +05:30
Jon Leighton
491ce5b6ce Verify that creating a has_many through record where there is a default_scope on the join model works correctly (creates the join record with the default scope applied) 2010-12-16 01:49:30 +05:30
Jon Leighton
eba7664086 Respect the default_scope on a join model when reading a through association 2010-12-16 01:49:30 +05:30
brainopia
ebc47465a5 Fix edge cases for domain :all option on cookie store
Dont set explicit domain for cookies if host is not a domain name

[#6002 state:committed]

Signed-off-by: Santiago Pastorino <santiago@wyeworks.com>
2010-12-16 01:49:30 +05:30
Piotr Sarnacki
875bbd58b4 AppGenerator: use options instead of @options 2010-12-16 01:49:30 +05:30
Piotr Sarnacki
bb89f8613a Kill whitespace! 2010-12-16 01:49:30 +05:30
Piotr Sarnacki
ed32c8fe51 Generate default layout in engine with --mountable option 2010-12-16 01:49:30 +05:30
Piotr Sarnacki
7f77d6691f Fix generation of prototype files, it should work with --javascript prototype, not --prototype 2010-12-16 01:49:30 +05:30
Piotr Sarnacki
978314c4e1 Generate javascripts in engine with --mountable option 2010-12-16 01:49:30 +05:30
Piotr Sarnacki
a462a76bd3 Set proper engine's asset directories when assets are served from engine.
When using stylesheet_link_tag(:all) or javascript_include_tag(:all),
assets directories are searched for css or js files. When
config.serve_static_assets is set to true, those files can be
served directly from engine's directories. That's why assets paths
should be set individually for controllers inside engine
if we want to serve static assets with ActionDispatch::Static
2010-12-16 01:49:29 +05:30
Piotr Sarnacki
8e955c5fe4 Should be isolated engine instead of namespaced engine 2010-12-16 01:49:29 +05:30
Ernie Miller
5d37ff6bb2 Fix hm:t to self table aliasing in construct_scope 2010-12-16 01:49:29 +05:30
Joe Hannon
7bffa9dd01 add test which fails for has_many through self join [#4361 state:open] 2010-12-16 01:49:29 +05:30
Aaron Patterson
a64bf22a71 class names are already strings, so we do not need to call to_s on the strings that are already strings 2010-12-16 01:49:29 +05:30
Aaron Patterson
2f0708e974 build SQL AST nodes rather than generate strings 2010-12-16 01:49:29 +05:30
Aaron Patterson
aa4d03fcfc construct_joins no longer needs an argument 2010-12-16 01:49:29 +05:30
Aaron Patterson
18402b5d64 supporting arel AST nodes when building join statements 2010-12-16 01:49:29 +05:30
Aaron Patterson
80ff64a947 just copy the joins to the list 2010-12-16 01:49:29 +05:30
Aaron Patterson
b68407f7f0 bucketing based on join type 2010-12-16 01:49:29 +05:30
Aaron Patterson
c02fd2acc5 taking advantage of the JoinSource node in the SQL AST 2010-12-16 01:49:29 +05:30
Aaron Patterson
08ccca7644 fixing whitespace errors 2010-12-16 01:49:29 +05:30
Piotr Sarnacki
f0f978a4f3 Fix indentation and newlines in generated engine 2010-12-16 01:49:29 +05:30
Aaron Patterson
63480d234d stop delegating inserts to ARel, use the INSERT SQL ourselves 2010-12-16 01:49:29 +05:30
Aaron Patterson
a1ca1e85a9 persisted? should be able to return a truthy object 2010-12-16 01:49:28 +05:30
Chiel Wester
bda16eb092 Only call save on belongs_to associations if the record has changed or any nested associations have changed (resolves #3353)
Signed-off-by: José Valim <jose.valim@gmail.com>
2010-12-16 01:49:28 +05:30
Santiago Pastorino
9cfbada93a This is not an executable file 2010-12-16 01:49:28 +05:30