Commit Graph

7782 Commits

Author SHA1 Message Date
Tarmo Tänav
fa795ccfad Include mysql older than 5.1.23 in the 5.1 series in the list of those that can't handle NULL defaults
Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net>
2008-08-26 00:53:19 -07:00
Jeremy Kemper
52e15abbed um.. yeah 2008-08-26 00:10:16 -07:00
Jeremy Kemper
6d66ddaa34 typo 2008-08-26 00:02:30 -07:00
Jeremy Kemper
842d55cb16 fix another ordering failure 2008-08-26 00:02:22 -07:00
Jeremy Kemper
ca48da6300 fix tests relying on implicit ordering 2008-08-25 23:53:31 -07:00
Josh Susser
1092c181b5 add dynamic finder bang version to raise RecordNotFound
[#905 state:resolved]

Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net>
2008-08-25 23:33:16 -07:00
Josh Susser
143f5fbb21 refactor dynamic finder name matching into its own class
Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net>
2008-08-25 23:32:20 -07:00
Jeremy Kemper
3beed9cdb7 ensure tests load sibling Active Support instead of a gem 2008-08-25 23:32:03 -07:00
Tarmo Tänav
77b003fb61 Use DECIMAL instead of INTEGER when casting as mysql doesn't work with just "INTEGER" and other databases don't like "UNSIGNED" which mysql requires
And don't mask exceptions.

Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net>
2008-08-25 23:23:34 -07:00
Tarmo Tänav
3d2ac918b9 Cache migrated versions list in Migrator and use it to fetch the latest migrated version name [#845 state:resolved]
Also optimized Migrator#current_version class method to fetch
only the latest version number and not all of them.

With this change no matter how many migrations there are the
schema_migrations table is only SELECTed from once.

Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net>
2008-08-25 22:03:47 -07:00
Jeremy Kemper
4bcd64c9e9 Ruby 1.9 compat: switch profile_options to superclass_delegating_accessor 2008-08-25 22:01:02 -07:00
Tarmo Tänav
a445cdd884 Load the first and not the last has_one result when doing join-based eager loading
This matters when the has_one is defined with an order in which case
there is an expectation that the first one will be loaded.

[#904 state:resolved]

Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net>
2008-08-25 21:23:35 -07:00
Frederick Cheung
2dbda11945 Implement old-skool eagerloading for has_one :through
Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net>
2008-08-25 21:23:15 -07:00
Jeremy Kemper
172606e21f Harmonize framework require strategy. Don't add self to load path since Rails initializer and RubyGems handle it. 2008-08-25 21:22:34 -07:00
Frederick Cheung
b7a37b742c Fix preloading of has_one through associations
[#903 state:resolved]

Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net>
2008-08-25 20:49:55 -07:00
Joshua Peek
f2d8d13c64 Performance: Cache modules that extend the view context for JavaScriptGenerator 2008-08-25 21:50:26 -05:00
Joshua Peek
ba0d621695 Include all helpers into ActionView::Helper 2008-08-25 21:50:26 -05:00
Jeremy Kemper
e5cad34916 strip trailing whitespace 2008-08-25 18:16:58 -07:00
Jeremy Kemper
1c54ca4f75 Ruby 1.9 compat: fix test error masked by old String#each behavior 2008-08-25 18:16:21 -07:00
Jeremy Kemper
5e1ceb153c Work around frozen Date memoization 2008-08-25 17:05:50 -07:00
Joshua Peek
a916c2e3d3 The view context always responds to controller, check if controller available instead 2008-08-25 15:37:19 -05:00
Joshua Peek
fe2640549b Base path may be nil if template is at the root of the view path 2008-08-25 15:36:11 -05:00
Sven Fuchs
49859b0bb1 I18n: fix activerecord i18n test for classy backend 2008-08-25 11:48:03 +02:00
Sven Fuchs
43a0012e50 Merge branch 'i18n' of git@github.com:svenfuchs/rails into i18n 2008-08-25 11:43:44 +02:00
Sven Fuchs
d0a4d9b73a Update translations for pluralization key change from 'many' to 'other' 2008-08-25 11:41:51 +02:00
Sven Fuchs
84d8957e04 Update translations for pluralization key change from 'many' to 'other' 2008-08-25 11:25:59 +02:00
Sven Fuchs
a61e87aeb9 update i18n gem 2008-08-25 11:20:24 +02:00
Sven Fuchs
e464f9b6b9 Merge commit 'rails/master' into i18n 2008-08-25 11:11:08 +02:00
Sven Fuchs
90a9637d41 I18n: add aliases #t and #l to TranslationHelper#translate and #localize 2008-08-25 11:06:18 +02:00
Chad Woolley
fb20d6f09d properly reference geminstaller config under ci dir 2008-08-25 10:34:01 +02:00
Jeremy Kemper
8a4d7233aa Update translations for pluralization key change from 'other' to 'many' 2008-08-24 11:10:15 -07:00
Jeremy Kemper
950ea33242 Fix test to assign the module instead of a new instance 2008-08-24 11:08:49 -07:00
Jeremy Kemper
3c52c4c12b Merge branch 'master' of git@github.com:rails/rails 2008-08-24 11:08:25 -07:00
Chad Woolley
337b043c93 Include the CI configuration and setup instructions.
This should make it easy to set up your own copy of the CI environment, and easier for us to keep ours running.
2008-08-24 16:27:20 +02:00
Michael Koziarski
33ed19f428 Merge branch 'patches' 2008-08-24 14:34:47 +02:00
Xavier Noria
e02f0dcc24 Rollback the transaction when a before_* callback returns false.
Previously this would have committed the transaction but not carried out save or destroy operation.

[#891 state:committed]
Signed-off-by: Michael Koziarski <michael@koziarski.com>
2008-08-24 14:34:24 +02:00
Michael Koziarski
eb2b81c766 Reverse the priority of the mysql commands in dbconsole 2008-08-24 13:20:23 +02:00
Jeremy Kemper
bb3dd6ad2e Ruby 1.9 compat: update bundled i18n lib 2008-08-23 21:51:06 -07:00
Jeremy Kemper
53e2e8ef2b Merge branch 'master' into i18n 2008-08-23 21:41:18 -07:00
Jeremy Kemper
c471f13db6 Ruby 1.9 compat: Hash is now flattenable, so explicitly exclude it 2008-08-23 21:26:14 -07:00
Jeremy Kemper
2efdeb7a95 Ruby 1.9 compat: set source encoding 2008-08-23 16:06:54 -07:00
Jeremy Kemper
92a7239a3d Ruby 1.9: silence some warnings for block args shadowing local vars 2008-08-23 16:03:00 -07:00
Jeremy Kemper
e7127be365 Ruby 1.9: constantize takes advantage of new inherit arg to const_get and const_defined? 2008-08-23 15:59:59 -07:00
Sven Fuchs
d6989aa0e1 I18n: use :other instead of :many as default key for pluralization to better conform w/ cldr pluralization rules
Signed-off-by: Michael Koziarski <michael@koziarski.com>
2008-08-23 21:23:00 +02:00
Tarmo Tänav
b1f3c6e6ec Generate belongs_to association when generating a model 2008-08-23 21:54:43 +03:00
Tarmo Tänav
9223a91911 Generate belongs_to associations automatically for 'references' types [#640 state:resolved] 2008-08-23 20:58:44 +03:00
Sven Fuchs
23fb26a0dc I18n: use :other instead of :many as default key for pluralization to better conform w/ cldr pluralization rules 2008-08-23 19:43:57 +02:00
Peter Wagenet
a652c300ac New inflectors will overwrite defaults [#337 state:resolved]
Signed-off-by: Tarmo Tänav <tarmo@itech.ee>
2008-08-23 20:43:22 +03:00
Tarmo Tänav
74c3c701f7 Don't set "NULL" as a constraint on nullable columns [#398 state:resolved]
This is already the default and adding it breaks SQL standards compatibility.
2008-08-23 19:51:09 +03:00
Tarmo Tänav
5232d81281 Pass class through to DeprecatedConstantProxy target
This is needed because include_all_modules_from checks
calls "class" on every constant and sometimes it can
hit deprecated constants which aren't even Modules,
but while checking for it deprecation warnings are shown.
2008-08-23 19:12:14 +03:00