José Valim
|
67582f08bf
|
Push a failing test for issues [#4994] and [#5003].
|
2010-06-29 19:50:09 +02:00 |
|
Neeraj Singh
|
40e87ac669
|
with_exclusive_scope does not work properly if ARel is passed. It does work nicely if hash is passed. Blow up if user is attempting it pass ARel to with_exclusive_scope.
[#3838 state:resolved]
Signed-off-by: José Valim <jose.valim@gmail.com>
|
2010-06-29 01:18:20 +02:00 |
|
James Le Cuirot
|
f664c57fe8
|
Don't overwrite unsaved updates when loading an association but preserve the order of the loaded records. Reapplied from before but now allows already-saved records to be refreshed.
[#4830 state:resolved]
Signed-off-by: José Valim <jose.valim@gmail.com>
|
2010-06-20 00:32:06 +02:00 |
|
José Valim
|
85cc1fa657
|
Revert "Don't overwrite unsaved updates when loading an association but preserve the order of the loaded records. [#4642 state:open]"
This commit introduced a regression described in ticket [#4830].
This reverts commit 0265c708b9.
|
2010-06-11 17:05:54 +02:00 |
|
James Le Cuirot
|
0265c708b9
|
Don't overwrite unsaved updates when loading an association but preserve the order of the loaded records. [#4642 state:resolved]
Signed-off-by: Pratik Naik <pratiknaik@gmail.com>
|
2010-06-09 18:17:52 +05:30 |
|
Raimonds Simanovskis
|
8136230cca
|
Explicitly set Topic model last_read attribute as Date value when Oracle enhanced adapter is used
(otherwise some tests are failing which assume that this attribute will have Date value)
|
2010-06-04 22:44:02 +03:00 |
|
Pratik Naik
|
517f709b51
|
Properly cache association_collection#scopes calls having arguments
|
2010-06-04 00:53:45 +01:00 |
|
José Valim
|
ad4be3d75d
|
Fix failing test.
|
2010-05-21 16:20:56 +02:00 |
|
Ian White
|
b439d85a19
|
Nested records (re: autosave) are now updated even when the intermediate parent record is unchanged [#4242 state:resolved]
Signed-off-by: José Valim <jose.valim@gmail.com>
|
2010-05-18 16:13:00 +02:00 |
|
Diego Algorta
|
3436fdfc12
|
Fix for get_ids when including a belongs_to association on a has_many association [#2896 state:resolved]
Signed-off-by: Pratik Naik <pratiknaik@gmail.com>
|
2010-05-15 16:53:59 +01:00 |
|
José Valim
|
5c245b91d2
|
Make sure valid? preceives the context as in ActiveModel API (ht: Carlos Antonio)
|
2010-05-10 12:28:38 +03:00 |
|
Lawrence Pit
|
60504e62c8
|
to_xml with :include should skip_instruct on the included records [#4506 state:resolved]
Signed-off-by: José Valim <jose.valim@gmail.com>
|
2010-04-30 14:22:57 +02:00 |
|
Neeraj Singh
|
883f27aa9a
|
test cases for record.to_xml [#458 state:resolved]
Signed-off-by: José Valim <jose.valim@gmail.com>
|
2010-04-30 13:19:30 +02:00 |
|
Andrew White
|
8ec085bf18
|
Support fixtures for namespaced models [#2965 state:resolved]
Signed-off-by: José Valim <jose.valim@gmail.com>
|
2010-04-25 16:04:38 +02:00 |
|
Andrew White
|
9cea9bc7f0
|
Refactor compute_type to handle situations where the correct class is already loaded
Signed-off-by: wycats <wycats@gmail.com>
|
2010-04-12 21:31:20 -07:00 |
|
Pratik Naik
|
b77dd218ce
|
Add Relation extensions
|
2010-04-02 17:38:02 +01:00 |
|
Andrew White
|
67d1cec4c8
|
Add the ability to specify table_name_prefix on individual modules
Signed-off-by: wycats <wycats@gmail.com>
|
2010-03-28 23:43:28 -07:00 |
|
Rizwan Reza
|
f1e5a9ff98
|
Add :dependent = to has_one and has_many [#3075 state:resolved]
|
2010-03-28 18:47:46 +04:30 |
|
Carlos Antonio da Silva
|
47d252f992
|
Fix associations to call :destroy or :delete based on the right :dependent option
Signed-off-by: José Valim <jose.valim@gmail.com>
|
2010-03-09 00:11:34 +01:00 |
|
Henry Hsu
|
bf9a0ae12b
|
Fix a bug where default_scope was overriding attributes given on model initialization [#3218 status:resolved]
Signed-off-by: José Valim <jose.valim@gmail.com>
|
2010-02-26 11:09:43 +01:00 |
|
Joshua Peek
|
db49c706b6
|
Axe AM state machine
We're going do it eventually, get it done before 3.0 is final.
|
2010-01-30 18:38:01 -06:00 |
|
Pratik Naik
|
8ff2fb6f3a
|
Make default_scope work with Relations
|
2010-01-23 13:41:09 +05:30 |
|
Pratik Naik
|
9e7ec2a9f1
|
Simplify calculation scope building. Remove :order from associations as it is troublesome w/ calculation methods using postgresql.
|
2010-01-18 23:40:42 +05:30 |
|
Pratik Naik
|
d60bb0a9e4
|
Rename named_scope to scope
|
2010-01-18 04:38:19 +05:30 |
|
Pratik Naik
|
dca3de3bc7
|
Make relations work as scopes
|
2010-01-17 23:22:11 +05:30 |
|
Pratik Naik
|
f0cde5be54
|
Make sure named_scope names are not used as method names already
|
2010-01-17 21:34:41 +05:30 |
|
Eloy Duran
|
f2aacd5140
|
Rollback the transaction when one of the autosave associations fails to save. [#3391 state:resolved]
|
2010-01-08 21:45:02 +01:00 |
|
Bryan Stearns
|
1080351437
|
Add failing test that triggers the stack overflow
|
2010-01-08 21:45:02 +01:00 |
|
José Valim
|
8c5fe60ec8
|
Simplify repair_validations on AR and make it work with new callbacks.
|
2010-01-01 03:20:38 +01:00 |
|
Eloy Duran
|
c23fbd0d47
|
Refactored previous changes to nested attributes.
|
2009-12-28 21:09:22 +01:00 |
|
Murray Steele
|
ff508640e2
|
Make polymorphic_inverse_of in Reflection throw an InverseOfAssociationNotFoundError if the supplied class doesn't have the appropriate association. [#3520 state:resolved]
Signed-off-by: Eloy Duran <eloy.de.enige@gmail.com>
|
2009-12-28 15:12:17 +01:00 |
|
George Ogata
|
81ca0cf2b0
|
Add inverse polymorphic association support. [#3520 state:resolved]
Signed-off-by: Eloy Duran <eloy.de.enige@gmail.com>
|
2009-12-28 15:12:13 +01:00 |
|
Matt Jones
|
d625312fe1
|
delete correct records for a has_many with :primary_key and :dependent => :delete_all
Signed-off-by: Michael Koziarski <michael@koziarski.com>
|
2009-11-10 18:41:37 +13:00 |
|
Eloy Duran
|
f125a34501
|
Define autosave association callbacks when using accepts_nested_attributes_for.
This way we don't define all the validation methods for all associations by
default, but only when needed.
[#3355 state:resolved]
|
2009-11-07 00:42:42 +01:00 |
|
Pratik Naik
|
572323135f
|
Allow accepts_nested_attributes_for :reject_if option accept symbols for using a method
Conflicts:
activerecord/lib/active_record/nested_attributes.rb
|
2009-10-07 23:50:30 +01:00 |
|
Luciano G Panaro
|
4168f87623
|
Make has_one with :conditions hash scope build or creation of the associated object with those conditions
Signed-off-by: Michael Koziarski <michael@koziarski.com>
[#3088 state:committed]
|
2009-09-28 14:50:33 +13:00 |
|
Alexey Kovyrin
|
938c0ee045
|
Define autosave association validation methods only when needed. [#3161 state:resolved]
Signed-off-by: Eloy Duran <eloy.de.enige@gmail.com>
|
2009-09-12 16:04:36 +02:00 |
|
Graeme Porteous
|
c01be9de32
|
Fix has_one with foreign_key and primary_key association bug which caused the associated object being lost when saving the owner. [#1756 state:resolved]
Mixed in a bit from patch by ransom-briggs. [#2813 state:resolved]
Signed-off-by: Eloy Duran <eloy.de.enige@gmail.com>
|
2009-09-12 16:03:32 +02:00 |
|
Eloy Duran
|
6cc0b9638f
|
Explicitely setting `autosave => false' should override new_record autosaving. [#2214 state:resolved]
Original author is Jacob.
|
2009-09-12 15:53:15 +02:00 |
|
Mike Breen
|
bcd0ef710e
|
Raise an exception with friendlier error message when attempting to build a polymorphic belongs_to with accepts_nested_attributes_for. [#2318 state:resolved]
Signed-off-by: Eloy Duran <eloy.de.enige@gmail.com>
|
2009-09-12 15:37:54 +02:00 |
|
José Valim
|
2ea1d684d9
|
Refactor new callbacks and AR implementation.
Signed-off-by: Joshua Peek <josh@joshpeek.com>
|
2009-09-08 10:26:39 -05:00 |
|
José Valim
|
4f37b97033
|
Changed ActiveRecord to use new callbacks and speed up observers by only notifying events that are actually being consumed.
Signed-off-by: Joshua Peek <josh@joshpeek.com>
|
2009-09-08 10:26:39 -05:00 |
|
railsbob
|
e06a0b03c8
|
has_many :through create should not raise validation errors
[#2934 state:committed]
Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net>
|
2009-08-09 18:44:45 -07:00 |
|
Tristan Dunn
|
0472839d68
|
Prevent overwriting of table name in merging SQL conditions [#2949 state:resolved]
|
2009-08-10 00:41:36 +01:00 |
|
Gabe da Silveira
|
00d6c76660
|
Enable has_many :through for going through a has_one association on the join model [#2719 state:resolved]
Signed-off-by: Pratik Naik <pratiknaik@gmail.com>
|
2009-08-10 00:30:44 +01:00 |
|
Rich Bradley
|
9bb8ef9ede
|
Fix for nested :include with namespaced models.
[#260 state:committed]
|
2009-08-09 00:31:46 -07:00 |
|
Matt Duncan
|
3b3798506b
|
Adding :from scoping to ActiveRecord calculations
Signed-off-by: Michael Koziarski <michael@koziarski.com>
[#1229 state:committed]
|
2009-08-09 12:43:07 +12:00 |
|
Raimonds Simanovskis
|
090ec47bec
|
added Subject#after_initialize to be the same as Topic#after_initialize
|
2009-08-06 23:41:00 +03:00 |
|
Raimonds Simanovskis
|
5666a3ad06
|
added :order option to find :first methods and associations as otherwise Oracle tests were failing
Oracle stores '' string as NULL
Oracle cannot have identifiers larger than 30 characters
added missing fixtures to test setup method
|
2009-08-06 23:40:59 +03:00 |
|
Joshua Peek
|
aad5a30bf2
|
Add simple support for ActiveModel's StateMachine for ActiveRecord
|
2009-08-04 11:03:57 -05:00 |
|