Commit Graph

5922 Commits

Author SHA1 Message Date
Vijay Dev
0c9e7b69d8 more edits [ci skip] 2012-05-01 19:18:47 +05:30
Vijay Dev
42ff22f33a Merge branch 'master' of github.com:lifo/docrails 2012-05-01 19:06:03 +05:30
Aaron Patterson
de6a067078 return value of block is returned 2012-04-30 16:14:15 -07:00
Aaron Patterson
f0182d5cb9 only yield to finder block if something is found 2012-04-30 16:14:15 -07:00
Andrew White
838101ae04 Fix PR #6091
1. ActiveRecord::Base is not ActiveRecord::Relation
2. The order of records from an SQL query is uncertain without an ORDER clause
3. Run your own tests when submitting a pull request
2012-04-30 22:18:35 +01:00
twinturbo
93076168c4 Add ActiveRecord::Base#ids 2012-04-30 09:45:00 -07:00
Hrvoje Šimić
620cc9af11 add ActiveRecord::RecordInvalid to exceptions
sort the exception names alphabetically
2012-04-30 14:46:30 +02:00
Jeremy Kemper
363d7ee551 Merge pull request #6074 from mark-rushakoff/unused-variables
Remove some unused variable assignments
2012-04-29 21:27:09 -07:00
Mark Rushakoff
d56f5c8db7 Remove unused assignments 2012-04-29 11:03:11 -07:00
Jeremy Friesen
c809c47837 Removed extraneous .present? check for AR::Base#reload 2012-04-29 13:33:54 -04:00
Jeremy Friesen
d3ccdf6505 Removed deprecation warning for #find as a result of AR::Base#reload
Cleaned up "DEPRECATION WARNING: Passing options to #find is
deprecated. Please build a scope and then call #find on it."
2012-04-29 13:10:43 -04:00
Mark Rushakoff
c13d36c95f More using <tt>x</tt> instead of +x+ when the latter renders improperly. 2012-04-27 21:33:56 -07:00
Aaron Patterson
8de4d71f5d Merge pull request #5698 from dougcole/support_postgresql_partitioning
Support postgresql partitioning by making INSERT RETURNING optional
2012-04-27 08:50:07 -07:00
José Valim
0a8aec2c97 Revert "Merge pull request #5995 from kennyj/fix_5847-3"
Active Record should be lazy loaded and this pull request
forced Active Record to always be loaded after initialization.

This reverts commit 8cd14c0bc9f9429f03d1181912355d2f48b98157, reversing
changes made to 2f0c8c52e66f1a2a3d1c00efc207f227124e96c2.
2012-04-27 15:00:56 +02:00
Jon Leighton
61555a0df1 allow AssociationProxy#scoped to take options so that API is the same as Base#scoped 2012-04-27 11:52:34 +01:00
Jon Leighton
df6f971e3a %s/find(:\(first\|last\|all\), \([^()]*\))/scoped(\2).\1/gcI amongst other things 2012-04-27 11:42:50 +01:00
Andrey Deryabin
d42b60a411 fix tests for SQLite3Adapter 2012-04-27 13:31:37 +07:00
Andrey Deryabin
dd05a49a4a renamed class SQLiteColumn to SQLite3Column 2012-04-27 13:29:58 +07:00
Andrey Deryabin
3cc9b5f196 removed tail of old sqlite versions 2012-04-27 13:23:39 +07:00
Andrey Deryabin
1a3d4f75ce fix SQLite3Adapter doc 2012-04-27 13:19:44 +07:00
Andrey Deryabin
fc1bf36a3a Upgrade sqlite3 version to 1.3.6 2012-04-27 13:14:22 +07:00
Andrey Deryabin
7572efc827 merged sqlite and sqlite3 adapters 2012-04-27 13:08:55 +07:00
Andrey Deryabin
9fd640376e EXPLAIN only for sqlite3 2012-04-26 21:53:18 +07:00
Jon Leighton
8cd14c0bc9 Merge pull request #5995 from kennyj/fix_5847-3
Fix #5847 and #4045. Load AR::Base before loading an application model.
2012-04-26 06:11:00 -07:00
Jon Leighton
2f0c8c52e6 remove deprecate #update_all usage 2012-04-26 13:29:48 +01:00
kennyj
627f89b189 Fix #5847 and #4045. Load AR::Base before loading an application model. 2012-04-26 21:21:02 +09:00
Aaron Patterson
bc7309cde3 Merge pull request #5973 from academia-edu/master
Always quote hstore keys and values
2012-04-25 09:11:23 -07:00
Jon Leighton
2a9763621c Merge remote-tracking branch 'jmbejar/define_array_methods_collection_proxy' 2012-04-25 16:25:42 +01:00
Jon Leighton
8b941e977c Merge remote-tracking branch 'kennyj/fix_5563'
Conflicts:
	activerecord/test/cases/associations/belongs_to_associations_test.rb
2012-04-25 16:07:31 +01:00
Jon Leighton
d242e46781 extract #with_scope and #with_exclusive_scope to active_record_deprecated_finders 2012-04-25 15:45:06 +01:00
Jon Leighton
af27c8b041 extract deprecated code 2012-04-25 15:45:06 +01:00
Jon Leighton
618c5fc3c0 Extract deprecated code 2012-04-25 15:45:06 +01:00
Jon Leighton
ef1d1e1492 fix interpolation for hash merging 2012-04-25 15:45:06 +01:00
Jon Leighton
e8cdb3d5e7 allow merging a single where value 2012-04-25 15:45:05 +01:00
Jon Leighton
f3fce59d13 extract to active_record_deprecated_finders 2012-04-25 15:45:05 +01:00
Jon Leighton
408437334b giving a hash to default scope should not be deprecated (well, not for this reason) 2012-04-25 15:45:05 +01:00
Jeremy Kemper
5cfb0aec1f Merge pull request #5976 from aderyabin/fix1
Duplicate quote_table_name method
2012-04-25 05:13:28 -07:00
Andrey Deryabin
53362fcbcf cleanliness in method parameters 2012-04-25 16:51:40 +07:00
Andrey Deryabin
d6b3dbe34e already defined in quoting 2012-04-25 15:05:45 +07:00
Ryan Fitzgerald
1a05e15e13 Restore .to_s to escape_hstore 2012-04-24 20:59:45 -07:00
Ryan Fitzgerald
0c46dbbc45 Always quote hstore keys and values
escape_hstore uses quotation marks around keys and values only if it
seems necessary. However, it currently breaks in the presence of some
non-ASCII characters. Instead of trying to guess exactly which
characters are safe, it seems better to always use quotes.
2012-04-24 20:46:51 -07:00
Vijay Dev
5f6ef504b1 Merge pull request #5887 from mcrowe/document-relation-merge
Add documentation to the SpawnMethods#merge method.
2012-04-23 03:37:38 -07:00
Akira Matsuda
851b816f56 be sure to currectly fetch PK name from MySQL even if the PK has some custom option 2012-04-19 22:04:13 +09:00
Jorge Bejar
7dc03cfd76 Define array methods in ActiveRecord::Associations::CollectionProxy
if they are not defined or delegated.
In this way, we have a performance boost invoking some array methods
which are not defined in CollectionAssociation.
2012-04-18 10:57:46 -03:00
Mitch Crowe
43946ee891 Add documentation to the SpawnMethods#merge method. 2012-04-17 18:56:33 -07:00
Vijay Dev
5b336ff443 Merge branch 'master' of github.com:lifo/docrails 2012-04-18 00:10:06 +05:30
Aaron Patterson
b8f7482695 opening a connection will block if the pool is full 2012-04-15 18:13:15 -07:00
Joshua Wood
ca0af8221a Automatically create indexes for references/belongs_to statements in migrations. 2012-04-14 14:18:42 -07:00
Jon Leighton
789bade1b5 extract deprecated code for #find, #first, #last, #all 2012-04-13 19:59:50 +01:00
Jon Leighton
5aea01a610 extract deprecated #calculate code 2012-04-13 19:25:51 +01:00