Commit Graph

7995 Commits

Author SHA1 Message Date
Pratik Naik
a17027d13a Merge docrails 2008-09-13 20:28:01 +01:00
Mislav Marohnić
96055414d6 Ensure Hash#except is allowed on a frozen hash. References #382
Signed-off-by: Pratik Naik <pratiknaik@gmail.com>
2008-09-13 20:05:17 +01:00
Rich Cavanaugh
113de01eaf Allow for the dirty tracking to work with the aliased name of aliased attributes.
Signed-off-by: Michael Koziarski <michael@koziarski.com>
[#812 state:committed]
2008-09-13 11:41:14 +02:00
Jon Leighton
fcf31cb752 Support for updating a belongs to association from the foreign key (without saving and reloading the record)
Signed-off-by: Michael Koziarski <michael@koziarski.com>
[#142 state:committed]
2008-09-13 11:08:29 +02:00
miloops
646b5bfa61 Use select and change test so new tests can work on postgres.
Signed-off-by: Michael Koziarski <michael@koziarski.com>
2008-09-12 12:27:03 +02:00
miloops
a37c5ae961 Improve test coverage when using the group option in find, has_many or has_and_belongs_to_many.
Signed-off-by: Michael Koziarski <michael@koziarski.com>
2008-09-11 22:51:57 +02:00
Michael Koziarski
095ad690f3 Remove the .to_s fix in validates_uniqueness_of, as Chars get quoted correctly. 2008-09-11 22:51:57 +02:00
Manfred Stienstra
babbc1580d Fix ActiveRecord::Base.quote_bound_value for ActiveSupper::Multibyte::Chars values.
- Adds String#acts_like_string?
- Adds Chars#acts_like_string?

Signed-off-by: Michael Koziarski <michael@koziarski.com>
[#1029 state:committed]
2008-09-11 22:51:26 +02:00
wmoxam
923f4ecad2 Fixes validates_uniquness_of problem with case insensitive string containing newline characters
Signed-off-by: Michael Koziarski <michael@koziarski.com>
2008-09-11 17:40:14 +02:00
miloops
c98cb8ffc2 Add --debugger option to script/console.
Signed-off-by: Michael Koziarski <michael@koziarski.com>
[#1025 state:committed]
2008-09-11 17:12:00 +02:00
Michael Koziarski
1ddde91303 Flesh out the parameterize method to support non-ascii text and underscores. 2008-09-11 17:10:17 +02:00
Jamis Buck
46bac29de7 Add the Asia/Colombo definition from the tzinfo gem 2008-09-11 08:33:39 -06:00
Michael Koziarski
9460d45988 Add missing assert_deprecated calls to prevent spam during test runs 2008-09-11 11:21:22 +02:00
Sven Fuchs
e826c99201 add activerecord tests to make sure the deprecated %s and %d interpolation syntax still works
[#1016 state:committed]

Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net>
2008-09-10 19:28:36 -07:00
Sven Fuchs
31dcd78111 add activerecord tests for deprecation of %s and %d in error messages (and translations in general)
Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net>
2008-09-10 19:28:36 -07:00
Sven Fuchs
79c8b104d6 change activerecord validation tests to not use the deprecated interpolation syntax any more
Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net>
2008-09-10 19:28:36 -07:00
Joshua Peek
70a4f6c2dd Switched computed public paths cache over to a simple hash w/ mutex 2008-09-10 19:05:53 -05:00
Joshua Peek
2ba9ca95f9 Removed monitor from MemoryStore and created a seperate threadsafe store called SynchronizedMemoryStore 2008-09-10 18:56:03 -05:00
rsl
6ce13429cb fixed association preloading to use = instead of IN when there's only one record
[#1013 state:committed]

Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net>
2008-09-10 14:11:00 -07:00
Jamis Buck
5bbca48c22 Fix Sri Jayawardenepura time zone to map to Asia/Colombo 2008-09-10 13:32:10 -06:00
Jeremy Kemper
c19c0e7872 Disable warnings in AP tests 2008-09-10 11:03:32 -07:00
Pratik Naik
9994f0d902 Revert "Add :accessible option to Associations for allowing mass assignments using hash. [#474 state:resolved]"
This reverts commit e0750d6a5c.

Conflicts:

	activerecord/CHANGELOG
	activerecord/lib/active_record/associations.rb
	activerecord/lib/active_record/associations/association_collection.rb
2008-09-10 18:50:01 +01:00
Rob Anderton
b518b6c0d3 Expanded documentation for new composed_of options
Signed-off-by: Michael Koziarski <michael@koziarski.com>
[#892 state:committed]
2008-09-10 18:28:57 +02:00
Rob Anderton
2cee51d5c1 Added :constructor and :converter options to composed_of and deprecated the conversion block
Signed-off-by: Michael Koziarski <michael@koziarski.com>
2008-09-10 18:28:47 +02:00
Tarmo Tänav
7c9851dbb6 Support :limit on update_all so that has_many with :limit can be safely updated
Signed-off-by: Michael Koziarski <michael@koziarski.com>
2008-09-10 13:41:49 +02:00
Tarmo Tänav
14d1560e85 Fixed test_find_last_by_one_attribute_caches_dynamic_finder for postgresql 8.3
Signed-off-by: Michael Koziarski <michael@koziarski.com>
2008-09-10 13:40:45 +02:00
Sven Fuchs
a18ed6d563 Added ActionController::Translation module delegating to I18n #translate/#t and #localize/#l [status:committed #1008]
Signed-off-by: David Heinemeier Hansson <david@loudthinking.com>
2008-09-10 00:39:54 -05:00
David Heinemeier Hansson
c55565b032 Merge branch 'master' of git@github.com:rails/rails 2008-09-10 00:37:04 -05:00
David Heinemeier Hansson
90366a1521 Added Inflector#parameterize for easy slug generation ("Donald E. Knuth".parameterize => "donald-e-knuth") #713 [Matt Darby] 2008-09-10 00:36:37 -05:00
David Heinemeier Hansson
b8e8be83e9 Added Inflector#parameterize for easy slug generation ("Donald E. Knuth".parameterize => "donald-e-knuth") #713 [Matt Darby] 2008-09-10 00:26:50 -05:00
Alastair Brunton
b141624abb Added image_submit_tag confirm option [status:committed #784]
Signed-off-by: David Heinemeier Hansson <david@loudthinking.com>
2008-09-10 00:13:35 -05:00
Jose Fernandez
184cf27b12 The FormTagHelper#submit_tag helper will now pass along the original value of the submit button to the params if the :disable_with option is used [status:committed #633]
Signed-off-by: David Heinemeier Hansson <david@loudthinking.com>
2008-09-10 00:02:23 -05:00
David Heinemeier Hansson
6dc9173a63 Missing doc updates 2008-09-09 23:59:54 -05:00
Antonio Cangiano
854cf3d721 Fix for SQLite's db creation warnings [status:committed #614]
Signed-off-by: David Heinemeier Hansson <david@loudthinking.com>
2008-09-09 23:56:37 -05:00
miloops
567392bff3 Added find_last_by dynamic finder [status:committed #762]
Signed-off-by: David Heinemeier Hansson <david@loudthinking.com>
2008-09-09 23:44:52 -05:00
U-ESCAPEE\Mack
f3f7d166d8 Fixed problem causes by leftover backup templates ending in tilde [state:committed #969]
Signed-off-by: David Heinemeier Hansson <david@loudthinking.com>
2008-09-09 23:29:29 -05:00
David Heinemeier Hansson
704fc3785e No local variable in the global namespace plz 2008-09-09 23:13:37 -05:00
David Heinemeier Hansson
23a0e2c4a9 Fixed that REXML fix would break on earlier versions of ruby (Frederick Cheung) [state:resolved #987] 2008-09-09 23:07:34 -05:00
David Heinemeier Hansson
cc17863709 Revert "Remove the Version check as it's not always available."
This reverts commit 6e2851d426.
2008-09-09 23:05:09 -05:00
David Heinemeier Hansson
c5b65b4905 Only separate loggings with a comma when there are actually two statements 2008-09-09 22:42:49 -05:00
David Heinemeier Hansson
6233628ba0 Stopped logging template compiles as it only clogs up the log 2008-09-09 22:10:39 -05:00
David Heinemeier Hansson
dc8b21dc3c Dont reference the class being tested when it can be assumed 2008-09-09 17:59:34 -05:00
David Heinemeier Hansson
6228220c9b Revert "Revert "Add layout functionality to mailers.""
This reverts commit 36c6aa01ee.
2008-09-09 17:25:09 -05:00
David Heinemeier Hansson
36c6aa01ee Revert "Add layout functionality to mailers."
This reverts commit e9a8e0053b.
2008-09-09 17:20:55 -05:00
Hongli Lai (Phusion)
1398db0128 Add special AssociationReflection methods for creating association objects, and modify the code base to use those methods instead of creating association objects directly. This allows plugins to hook into association object creation behavior.
[#986 state:resolved]

Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net>
2008-09-09 13:13:12 -07:00
Hongli Lai (Phusion)
1692940441 Make the options that has_many, belongs_to and other association generation methods can accept, configurable.
[#985 state:resolved]

Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net>
2008-09-09 12:50:32 -07:00
Michael Koziarski
07913788f9 Interpolation requires double quotes 2008-09-09 21:16:06 +02:00
Akira Matsuda
5f7c42413b Ruby 1.9 compat: remove instance variables and global variables from block parameters
[#1000 state:resolved]

Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net>
2008-09-09 10:35:53 -07:00
Akira Matsuda
8e68ec4dcc Ruby 1.9 compat: use String#lines instead of to_a in Ruby 1.9
[#1001 state:resolved]

Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net>
2008-09-09 10:35:24 -07:00
Akira Matsuda
07eb9ffd15 Ruby 1.9 compat: remove constants from block parameters
[#1002 state:resolved]

Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net>
2008-09-09 10:07:59 -07:00