Commit Graph

2098 Commits

Author SHA1 Message Date
Jeremy Kemper
fe0ffe406e Ticket 2263 - Make clean logger compatible with both 1.8.2 and 1.8.3
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2369 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-09-27 20:18:55 +00:00
Nicholas Seckar
564077373d Streamline render process, code cleaning. Closes #2294.
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2368 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-09-27 16:45:39 +00:00
Jeremy Kemper
64937891c7 r3632@asus: jeremy | 2005-09-27 12:18:49 -0700
reset_sequences cleanup also fixed #2183; credit ticket author


git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2367 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-09-27 15:45:48 +00:00
Scott Barron
a111e1a271 Keep flash after component is rendered. Closes #2291.
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2363 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-09-27 11:02:11 +00:00
Sam Stephenson
72c3ffc7fb Make the migration generator only check files ending in *.rb when calculating the next file name #2317 [Chad Fowler]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2362 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-09-27 10:47:47 +00:00
Scott Barron
76a7a52557 Fix serialization problem with YAML in 1.8.3
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2360 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-09-27 09:25:17 +00:00
Jeremy Kemper
f5f7beb369 r3613@asus: jeremy | 2005-09-26 22:25:04 -0700
Handle sequence reset for empty tables and models with custom primary keys.


git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2357 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-09-27 01:51:05 +00:00
Jeremy Kemper
169785162c r3605@asus: jeremy | 2005-09-26 19:10:50 -0700
Update change log.


git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2356 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-09-26 22:41:18 +00:00
Jeremy Kemper
6d7551f1bb r3604@asus: jeremy | 2005-09-26 19:10:42 -0700
Treat validates_size_of :within as a single validator rather than splitting it into to ends of the range, thus yield two error messages on nil (yuck)


git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2355 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-09-26 22:41:02 +00:00
Jeremy Kemper
54adccda08 r3603@asus: jeremy | 2005-09-26 19:10:00 -0700
Add unit tests for nil assigned to validates_size_of :attr, :within


git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2354 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-09-26 22:40:51 +00:00
Marcel Molina
1d738cab80 Make update_attribute use the same writer method that update_attributes uses.
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2353 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-09-26 21:55:37 +00:00
Marcel Molina
1465f9cee2 Make migrations honor table name prefixes and suffixes.
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2352 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-09-26 21:30:12 +00:00
Jeremy Kemper
0f276de512 r3597@asus: jeremy | 2005-09-26 17:39:23 -0700
Minor improvement to SQLite adapter blob escaping.


git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2351 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-09-26 21:04:36 +00:00
Marcel Molina
b54560600b Have text helpers use built in Regexp.escape rather than home grown alternative
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2350 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-09-26 20:49:52 +00:00
Jeremy Kemper
bbfde01b94 r3592@asus: jeremy | 2005-09-26 17:01:47 -0700
Update change log.


git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2349 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-09-26 20:29:11 +00:00
Jeremy Kemper
27ecb482c6 r3591@asus: jeremy | 2005-09-26 17:01:30 -0700
Simplify binary unit test.  Use flowers.jpg instead of associations.png


git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2348 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-09-26 20:29:06 +00:00
Jeremy Kemper
a5e2f6cd28 r3590@asus: jeremy | 2005-09-26 17:00:53 -0700
Correct and optimize PostgreSQL bytea escaping.  This is a blend of four patches, each providing a bit to the solution.


git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2347 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-09-26 20:29:01 +00:00
Jeremy Kemper
79a535ecd7 r3589@asus: jeremy | 2005-09-26 16:58:40 -0700
Remove associations.png in favor of flower.jpg which reveals a bug in binary escaping.


git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2346 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-09-26 20:28:55 +00:00
Jeremy Kemper
9852197f83 r3573@asus: jeremy | 2005-09-26 11:38:44 -0700
Ticket 1507 - IE file uploads give the filename as a full Windows path, but Ruby on UNIX doesn't know how to File.basename('C:\\blah\blah.foo').
 r3574@asus:  jeremy | 2005-09-26 14:32:11 -0700
 Get rid of constant redefine warning.
 r3575@asus:  jeremy | 2005-09-26 14:33:07 -0700
 Override the file upload's original_filename singleton method in CGIMethods.get_typed_value.
 r3576@asus:  jeremy | 2005-09-26 14:33:49 -0700
 Unit test overridden original_filename against normal filenames and full Windows paths.
 r3577@asus:  jeremy | 2005-09-26 14:33:57 -0700
 Update change log.


git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2345 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-09-26 17:59:46 +00:00
Jeremy Kemper
a68557952f r3569@asus: jeremy | 2005-09-26 05:33:09 -0700
Ticket 1749 - reset_sequences workaround for non-integer sequences
 r3570@asus:  jeremy | 2005-09-26 08:30:30 -0700
 Fixtures.reset_sequences should only reset sequences corresponding to integer primary keys named id.  #1749
 r3571@asus:  jeremy | 2005-09-26 08:31:11 -0700
 Update change log.


git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2343 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-09-26 11:56:16 +00:00
Jeremy Kemper
b2c46ed5fd Include the orders table in *.drop.sql
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2342 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-09-26 08:23:04 +00:00
Marcel Molina
b25933f296 Get rid of warnings generated by calling obsolete .to_a method on a Symbol
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2341 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-09-26 02:02:55 +00:00
Jamis Buck
c5f53ca333 Remove duplicate 'quote_column_name' definition
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2340 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-09-25 21:15:44 +00:00
David Heinemeier Hansson
b3df95985a Refactored the AbstractAdapter to be a lot less scary. Cleaned up the docs and style for the OSS adapters
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2339 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-09-25 17:56:03 +00:00
Jamis Buck
ea65465422 Standardize the interpretation of boolean columns in the Mysql and Sqlite adapters. (Use MysqlAdapter.emulate_booleans = false to disable this behavior)
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2335 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-09-25 15:49:35 +00:00
Scott Barron
e7059fd281 Fix migrations with PG 7.x.
Closes #1850


git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2332 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-09-25 10:52:16 +00:00
Scott Barron
fa7d4a691f This seems unnecessary to call in teardown and is causing the tests
to error because the table has been dropped.


git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2331 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-09-25 10:41:22 +00:00
David Heinemeier Hansson
b2b0ace058 Okay, you can have an extra space
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2330 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-09-25 09:14:58 +00:00
David Heinemeier Hansson
6720efb8e3 Use assignment instead of call
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2329 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-09-25 08:50:47 +00:00
David Heinemeier Hansson
7f86e026f6 Use assignment instead of call
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2327 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-09-25 08:48:30 +00:00
David Heinemeier Hansson
948be2c998 Added new symbol-driven approach to activating observers with Base#observer [DHH]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2326 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-09-25 08:26:29 +00:00
Thomas Fuchs
2346f5716f Fix open/save dialog in IE not opening files send with send_file/send_data, #2279
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2325 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-09-25 06:53:42 +00:00
Jamis Buck
2a35baa0bb Wrap :conditions in parentheses to prevent problems with OR's #1871
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2324 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-09-24 23:58:13 +00:00
David Heinemeier Hansson
caaf40d535 Added AbstractAdapter#select_value and AbstractAdapter#select_values as convenience methods for selecting single values, instead of hashes, of the first column in a SELECT #2283
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2323 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-09-24 19:50:57 +00:00
David Heinemeier Hansson
66820a4aa7 Just include activerecord/schema with AR so it doesnt need to be dumped
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2322 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-09-24 17:50:07 +00:00
David Heinemeier Hansson
6d336753b9 Added prevention of duplicate migrations from the generator #2240 [fbeausoleil@ftml.net]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2320 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-09-24 08:42:38 +00:00
David Heinemeier Hansson
df95567598 Added native, faster implementations of .blank? for the core types #2286 [skae]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2319 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-09-24 05:14:04 +00:00
Jamis Buck
1f4dc25250 Make the sqlite adapter preserve not-null constraints and index names when altering tables
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2318 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-09-24 00:33:47 +00:00
Jamis Buck
11411effde Allow the postgresql adapter to work with the SchemaDumper.
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2317 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-09-23 17:27:59 +00:00
Jamis Buck
9838a5f8b3 Post the postgresql adapter (and hopefully other adapters) pass all tests
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2316 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-09-23 15:46:04 +00:00
Jamis Buck
6d4a4a0d2e Make sqlite adapter pass all tests
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2315 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-09-23 15:00:56 +00:00
Jamis Buck
119855c438 Add db_schema_dump and db_schema_import rake tasks to work with the new ActiveRecord::SchemaDumper (for dumping a schema to and reading a schema from a ruby file).
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2313 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-09-23 13:45:32 +00:00
Jamis Buck
7dc45818dc Add ActiveRecord::SchemaDumper for dumping a DB schema to a pure-ruby file, making it easier to consolidate large migration lists and port database schemas between databases.
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2312 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-09-23 13:29:33 +00:00
David Heinemeier Hansson
436d54c3f1 Only configure settings for loaded frameworks
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2304 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-09-22 14:11:13 +00:00
David Heinemeier Hansson
2a31691ee2 Fixed that auto_discovery_link_tag couldn't take a string as the URL
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2296 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-09-22 11:37:16 +00:00
David Heinemeier Hansson
0b54f18c47 Fixed clean logger to work with Ruby 1.8.3 Logger class #2245
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2286 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-09-21 13:45:16 +00:00
David Heinemeier Hansson
2d4fe31af6 Fixed migrations for Windows when using more than 10 [David Naseby]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2285 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-09-21 13:27:45 +00:00
David Heinemeier Hansson
d616b86025 Asserts now need html/document so it should require it
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2284 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-09-21 09:04:05 +00:00
David Heinemeier Hansson
66ecf31ffe Fixed that the create_x method from belongs_to wouldn't save the association properly #2042 [Florian Weber]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2279 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-09-20 18:36:14 +00:00
Jamis Buck
5213a1f733 Fixed saving a record with two unsaved belongs_to associations pointing to the same object #2023 [Tobias Luetke]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2278 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-09-20 16:12:13 +00:00