Commit message (Collapse) | Author | Age | Files | Lines | ||
---|---|---|---|---|---|---|
... | ||||||
* | In nested_attributes when association is not loaded and association | Subba Rao Pasupuleti | 2010-07-21 | 1 | -0/+6 | |
| | | | | | | | | record is saved and then in memory record attributes should be saved [#5053 state:resolved] Signed-off-by: José Valim <jose.valim@gmail.com> | |||||
* | - without the id test is passing even if I change :allow_destroy from ↵ | Neeraj Singh | 2010-07-21 | 1 | -2/+47 | |
| | | | | | | 'false' - adding more tests to strengthen the test suite Signed-off-by: José Valim <jose.valim@gmail.com> | |||||
* | This patch changes update_attribute implementatino so: | Neeraj Singh | 2010-07-08 | 1 | -9/+9 | |
| | | | | | | | | | | - it will only save the attribute it has been asked to save and not all dirty attributes - it does not invoke callbacks - it does change updated_at/on Signed-off-by: José Valim <jose.valim@gmail.com> | |||||
* | Don't remove scheduled destroys when loading an association. [#4642 ↵ | James Le Cuirot | 2010-07-01 | 1 | -0/+6 | |
| | | | | | | state:resolved] Signed-off-by: José Valim <jose.valim@gmail.com> | |||||
* | Fixes #2415 by creating a new instance of the Model when saving attributes ↵ | George Montana Harkin | 2010-06-27 | 1 | -13/+15 | |
| | | | | | | to that model and the associated attributes already exist. Tests included. [#2415 state:resolved] Signed-off-by: José Valim <jose.valim@gmail.com> | |||||
* | Don't overwrite unsaved updates when loading an association but preserve the ↵ | James Le Cuirot | 2010-06-20 | 1 | -0/+21 | |
| | | | | | | | | 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> | |||||
* | Revert "Don't overwrite unsaved updates when loading an association but ↵ | José Valim | 2010-06-11 | 1 | -14/+0 | |
| | | | | | | | | preserve the order of the loaded records. [#4642 state:open]" This commit introduced a regression described in ticket [#4830]. This reverts commit 0265c708b9696c3943518ad5f3dabdc22c5eba11. | |||||
* | Don't overwrite unsaved updates when loading an association but preserve the ↵ | James Le Cuirot | 2010-06-09 | 1 | -0/+14 | |
| | | | | | | order of the loaded records. [#4642 state:resolved] Signed-off-by: Pratik Naik <pratiknaik@gmail.com> | |||||
* | Fixing test class names and refactor line in autosave association | Carlos Antonio da Silva | 2010-06-07 | 1 | -2/+2 | |
| | | | | Signed-off-by: José Valim <jose.valim@gmail.com> | |||||
* | Nested records (re: autosave) are now updated even when the intermediate ↵ | Ian White | 2010-05-18 | 1 | -0/+80 | |
| | | | | | | parent record is unchanged [#4242 state:resolved] Signed-off-by: José Valim <jose.valim@gmail.com> | |||||
* | Use primary key in conditions, not 'id' [#4395 state:resolved] | Mathieu Arnold | 2010-05-04 | 1 | -0/+25 | |
| | | | | Signed-off-by: Pratik Naik <pratiknaik@gmail.com> | |||||
* | Ensure not to load the entire association when bulk updating existing ↵ | Pratik Naik | 2010-04-14 | 1 | -1/+11 | |
| | | | | records using nested attributes | |||||
* | Raise a RecordNotFound if an ID in nested attributes is given but doesn't ↵ | Eloy Duran | 2010-01-07 | 1 | -4/+20 | |
| | | | | return a record. [#2415 state:resolved] | |||||
* | Moved the validation logic to the association reflection and refactored ↵ | Eloy Duran | 2010-01-07 | 1 | -2/+2 | |
| | | | | autosave_association.rb a bit. | |||||
* | Remove deprecated '_delete' option from NestedAttributes. | Eloy Duran | 2010-01-07 | 1 | -6/+0 | |
| | ||||||
* | Refactored nested attributes a bit around :reject_if => :all_blank. | Eloy Duran | 2010-01-07 | 1 | -1/+4 | |
| | ||||||
* | Make nested attributes behave like in 2.3.5 and add a sanity test for it ↵ | José Valim | 2010-01-02 | 1 | -1/+1 | |
| | | | | with I18n. | |||||
* | Refactored previous changes to nested attributes. | Eloy Duran | 2009-12-28 | 1 | -15/+26 | |
| | ||||||
* | Add an :update_only option to accepts_nested_attributes_for for to-one ↵ | Michael Siebert | 2009-12-28 | 1 | -0/+31 | |
| | | | | | | associations. [#2563 state:resolved] Signed-off-by: Eloy Duran <eloy.de.enige@gmail.com> | |||||
* | Make sure to not add autosave callbacks multiple times. [#3575 state:resolved] | Eloy Duran | 2009-12-28 | 1 | -0/+9 | |
| | | | | This makes sure that, in a HABTM association, only one join record is craeted. | |||||
* | Add a :limit option to specify the maximum number of records that can be ↵ | Pratik Naik | 2009-10-09 | 1 | -0/+30 | |
| | | | | processed by accepts_nested_attributes_for | |||||
* | Store entire options hash in the class var rather than just the reject_if ↵ | Pratik Naik | 2009-10-09 | 1 | -4/+4 | |
| | | | | proc for the nested attributes | |||||
* | Use indifferent access attributes instead of stringifying them | Pratik Naik | 2009-10-08 | 1 | -0/+8 | |
| | ||||||
* | Allow accepts_nested_attributes_for :reject_if option accept symbols for ↵ | Pratik Naik | 2009-10-07 | 1 | -0/+20 | |
| | | | | | | | | using a method Conflicts: activerecord/lib/active_record/nested_attributes.rb | |||||
* | Rename nested attributes _delete to _destroy to reflect its actual behavior ↵ | José Valim | 2009-09-12 | 1 | -33/+39 | |
| | | | | | | and DSL (:allow_destroy). Deprecation warning added. [#2889 state:resolved] Signed-off-by: Eloy Duran <eloy.de.enige@gmail.com> | |||||
* | Raise an exception with friendlier error message when attempting to build a ↵ | Mike Breen | 2009-09-12 | 1 | -0/+8 | |
| | | | | | | polymorphic belongs_to with accepts_nested_attributes_for. [#2318 state:resolved] Signed-off-by: Eloy Duran <eloy.de.enige@gmail.com> | |||||
* | Add test to verify that the new :inverse_of association option will indeed ↵ | Wolfram Arnold | 2009-08-08 | 1 | -0/+37 | |
| | | | | | | | | fix the validation problem for a belongs_to relationship that validates_presence_of the parent, when both the parent and the child are new (in-memory) records. Also check that this works when the parents adds child via nested_attributes_for. Lastly, add a require 'models/pet' to association_validation_test.rb, so that test can be run independently (was failing due to that missing dependency). [#2815 status:resolved] Signed-off-by: José Valim <jose.valim@gmail.com> | |||||
* | Cherry-pick core extensions | Jeremy Kemper | 2009-05-13 | 1 | -0/+1 | |
| | ||||||
* | Allow you to pass :all_blank to :reject_if option to automatically create a ↵ | Mike Breen | 2009-05-10 | 1 | -1/+17 | |
| | | | | Proc that will reject any record with blank attributes. | |||||
* | Changed API of NestedAttributes to take an array, or hash with index keys, ↵ | Lance Ivy | 2009-02-13 | 1 | -76/+212 | |
| | | | | | | | | of hashes that have the id on the inside of the attributes hash and updated the FormBuilder to produce such hashes. Also fixed NestedAttributes with composite ids. Signed-off-by: Michael Koziarski <michael@koziarski.com> Signed-off-by: Eloy Duran <eloy.de.enige@gmail.com> [#1892 state:committed] | |||||
* | Nested attribute accessors should ignore new records with truthy _delete key. | Pascal Ehlert | 2009-02-06 | 1 | -0/+14 | |
| | | | | | Signed-off-by: Michael Koziarski <michael@koziarski.com> [#1861 state:committed] | |||||
* | Don't rely on the order in these tests | Michael Koziarski | 2009-02-01 | 1 | -2/+2 | |
| | ||||||
* | Add support for nested object forms to ActiveRecord and the helpers in ↵ | Eloy Duran | 2009-02-01 | 1 | -0/+359 | |
ActionPack Signed-Off-By: Michael Koziarski <michael@koziarski.com> [#1202 state:committed] |