Commit message (Collapse) | Author | Age | Files | Lines | |
---|---|---|---|---|---|
* | Merge pull request #28270 from mmangino/dont_ignore_seralization_options | Ryuta Kamizono | 2018-02-27 | 1 | -1/+1 |
|\ | | | | | | | Don't accidentally lose includes in serialization | ||||
| * | Don't accidentally lose includes in serialization | Mike Mangino | 2017-03-03 | 1 | -1/+1 |
| | | |||||
* | | Use frozen string literal in activemodel/ | Kir Shatrov | 2017-07-16 | 1 | -0/+2 |
| | | |||||
* | | Revert "Merge pull request #29540 from kirs/rubocop-frozen-string" | Matthew Draper | 2017-07-02 | 1 | -1/+0 |
| | | | | | | | | | | This reverts commit 3420a14590c0e6915d8b6c242887f74adb4120f9, reversing changes made to afb66a5a598ce4ac74ad84b125a5abf046dcf5aa. | ||||
* | | Enforce frozen string in Rubocop | Kir Shatrov | 2017-07-01 | 1 | -0/+1 |
|/ | |||||
* | applies new string literal convention in activemodel/lib | Xavier Noria | 2016-08-06 | 1 | -2/+2 |
| | | | | | The current code base is not uniform. After some discussion, we have chosen to go with double quotes by default. | ||||
* | [ci skip] Fix explanation of `ActiveModel::Serialization` | yui-knk | 2015-10-02 | 1 | -3/+3 |
| | | | | | | This explanation was change by https://github.com/rails/rails/commit/7a27de2b. This change reversed the including module (`ActiveModel::Serializers::JSON`) and the included module (`ActiveModel::Serialization`) by mistake. | ||||
* | Tiny documentation improvements [ci skip] | Robin Dupret | 2015-08-28 | 1 | -2/+3 |
| | |||||
* | discard xml Serialization documentation that is no longer available [ci skip] | Gaurav Sharma | 2015-08-22 | 1 | -5/+3 |
| | |||||
* | Remove XML Serialization from core. | Zachary Scott | 2015-08-07 | 1 | -3/+0 |
| | | | | | | | This includes the following classes: - ActiveModel::Serializers::Xml - ActiveRecord::Serialization::XmlSerializer | ||||
* | Revert "Add code example for include option of ↵ | Rafael Mendonça França | 2015-06-10 | 1 | -14/+1 |
| | | | | | | | | AM::Serialization#serializable_hash" This reverts commit 3d949f34816d6eca0a6b59cfa08d91f36e8e64dd. This was already documented in other PR. | ||||
* | Add code example for include option of AM::Serialization#serializable_hash | Radan Skoric | 2015-06-09 | 1 | -1/+14 |
| | |||||
* | Tiny documentation edits [ci skip] | Robin Dupret | 2015-06-07 | 1 | -2/+2 |
| | |||||
* | add docs to include option at ActiveModel::Serialization#serializable_hash ↵ | rusikf | 2015-05-11 | 1 | -0/+31 |
| | | | | [ci skip] | ||||
* | ensure `method_missing` called for non-existing methods passed to | Jay Elaraj | 2015-04-28 | 1 | -1/+1 |
| | | | | `ActiveModel::Serialization#serializable_hash` | ||||
* | :scissors: and :nail_care: from d60c405 [ci skip] | Zachary Scott | 2014-06-16 | 1 | -3/+3 |
| | |||||
* | [ci skip] correct doc for serialization in accordance with API Doc Guide | Aditya Kapoor | 2014-06-16 | 1 | -11/+11 |
| | |||||
* | Fix few typos and improve markup at some levels | Robin Dupret | 2013-12-24 | 1 | -1/+1 |
| | |||||
* | Replace comments' non-breaking spaces with spaces | claudiob | 2012-12-04 | 1 | -1/+1 |
| | | | | | | | | | | Sometimes, on Mac OS X, programmers accidentally press Option+Space rather than just Space and don’t see the difference. The problem is that Option+Space writes a non-breaking space (0XA0) rather than a normal space (0x20). This commit removes all the non-breaking spaces inadvertently introduced in the comments of the code. | ||||
* | minor edits in AM documentation [ci skip] | Francesco Rodriguez | 2012-10-21 | 1 | -1/+1 |
| | |||||
* | update ActiveModel::Serialization documentation [ci skip] | Francesco Rodriguez | 2012-07-06 | 1 | -14/+36 |
| | |||||
* | Merge pull request #5678 from troyk/patch-1 | Carlos Antonio da Silva | 2012-05-19 | 1 | -1/+1 |
|\ | | | | | Remove sort on attributes.keys | ||||
| * | Remove sort on attributes.keys | Troy Kruthoff | 2012-03-30 | 1 | -1/+1 |
| | | |||||
* | | Missed colon | Alexey Vakhov | 2012-05-14 | 1 | -1/+1 |
| | | |||||
* | | Use respond_to?(:to_ary) rather than is_a?(Enumerable) to detect ↵ | Jon Leighton | 2012-05-11 | 1 | -2/+2 |
| | | | | | | | | collection-thing. | ||||
* | | Use <tt>Foo::Bar</tt> instead of +Foo::Bar+ | Mark Rushakof | 2012-04-27 | 1 | -1/+1 |
| | | | | | | | | | | | | | | | | The latter doesn't render as code in HTML output. Regex used in Rubymine to locate the latter form: (\+)(:*\w+:(?::|\w)+)(\+) | ||||
* | | Merge branch 'master' of github.com:lifo/docrails | Vijay Dev | 2012-04-25 | 1 | -5/+11 |
|\ \ | |||||
| * | | fix code syntax | Oscar Del Ben | 2012-04-25 | 1 | -2/+2 |
| | | | |||||
| * | | Add include documentation to serialization | Oscar Del Ben | 2012-04-25 | 1 | -1/+6 |
| | | | |||||
| * | | improve serialization doc | Oscar Del Ben | 2012-04-25 | 1 | -4/+5 |
| |/ | |||||
* / | Minor refactor of serializable hash | Oscar Del Ben | 2012-04-25 | 1 | -2/+1 |
|/ | |||||
* | Rename variable to avoid using name "include" | Carlos Antonio da Silva | 2012-03-09 | 1 | -8/+4 |
| | | | | Better syntax highlight :) | ||||
* | Remove Array#wrap usage in AMo serialization | Carlos Antonio da Silva | 2012-03-09 | 1 | -2/+1 |
| | |||||
* | Make sure serializable hash with :include always returns string keys | Carlos Antonio da Silva | 2012-03-09 | 1 | -2/+1 |
| | |||||
* | Merge pull request #5018 from hammerdr/issue-4659-docs | Aaron Patterson | 2012-02-13 | 1 | -4/+7 |
|\ | | | | | Adding documentation to clarify usage of attributes hash. | ||||
| * | Missed a code example. Fixing the docs to be consistant. | Derek Hammer | 2012-02-12 | 1 | -1/+1 |
| | | |||||
| * | Adding documentation to clarify usage of attributes hash. | Derek Hammer | 2012-02-12 | 1 | -3/+6 |
| | | | | | | | | | | | | Serialization uses only the attributes hash's keys and calls methods that are of the same name as the keys on the serialized object. | ||||
* | | Make sure serializable hash with :methods option returns always string keys | Carlos Antonio da Silva | 2012-02-13 | 1 | -1/+1 |
|/ | |||||
* | Remove Array.wrap call in ActiveModel | Rafael Mendonça França | 2012-01-06 | 1 | -3/+3 |
| | |||||
* | Revert "Implement ArraySerializer and move old serialization API to a new ↵ | José Valim | 2011-11-30 | 1 | -5/+134 |
| | | | | | | | | | | | | | namespace." This reverts commit 8896b4fdc8a543157cdf4dfc378607ebf6c10ab0. Conflicts: activemodel/lib/active_model.rb activemodel/lib/active_model/serializable.rb activemodel/lib/active_model/serializer.rb activemodel/test/cases/serializer_test.rb | ||||
* | Implement ArraySerializer and move old serialization API to a new namespace. | José Valim | 2011-11-23 | 1 | -134/+5 |
| | | | | | | | | | | | | | The following constants were renamed: ActiveModel::Serialization => ActiveModel::Serializable ActiveModel::Serializers::JSON => ActiveModel::Serializable::JSON ActiveModel::Serializers::Xml => ActiveModel::Serializable::XML The main motivation for such a change is that `ActiveModel::Serializers::JSON` was not actually a serializer, but a module that when included allows the target to be serializable to JSON. With such changes, we were able to clean up the namespace to add true serializers as the ArraySerializer. | ||||
* | Fixed serialization issues with multiple includes with options | zhengjia | 2011-10-11 | 1 | -1/+1 |
| | |||||
* | Provide read_attribute_for_serialization as the API to serialize attributes. | José Valim | 2011-09-30 | 1 | -2/+23 |
| | |||||
* | Make serializable_hash take attr values directly from attributes hash. | Jon Leighton | 2011-09-26 | 1 | -1/+3 |
| | | | | | | | | | | | | Previously, it would use send() to get the attribute. In Active Resource, this would rely on hitting method missing. If a method with the same name was defined further up the ancestor chain, that method would wrongly be called. This change fixes test_to_xml_with_private_method_name_as_attribute in activeresource/test/cases/base_test.rb, which was broken after 51bef9d8fb0b4da7a104425ab8545e9331387743, because that change made to_xml use serializable_hash. | ||||
* | added missing require array/wrap in serialization | Anand | 2011-08-23 | 1 | -0/+2 |
| | |||||
* | ActiveModel support for the :include serialization option | John Firebaugh | 2011-07-17 | 1 | -1/+32 |
| | | | | | | | | | | | | | | | | | | | | This commit moves support for the :include serialization option for serializing associated objects out of ActiveRecord in into ActiveModel. The following methods support the :include option: * serializable_hash * to_json * to_xml Instances must respond to methods named by the values of the :includes array (or keys of the :includes hash). If an association method returns an object that is_a?(Enumerable) (which AR has_many associations do), it is assumed to be a collection association, and its elements must respond to :serializable_hash. Otherwise it must respond to :serializable_hash itself. While here, fix #858, XmlSerializer should not singularize already singular association names. | ||||
* | Replace map+compact with select | John Firebaugh | 2011-07-17 | 1 | -1/+1 |
| | |||||
* | serializable_hash(:only => [], :methods => [:foo]) should work | John Firebaugh | 2011-07-17 | 1 | -7/+4 |
| | |||||
* | Remove extra white spaces on ActiveModel docs. | Sebastian Martinez | 2011-05-23 | 1 | -1/+1 |
| | |||||
* | Fixed broken, memoized attributes method example | Nathaniel Bibler | 2011-02-07 | 1 | -2/+2 |
| | | | | | | [#6245 state:committed] Signed-off-by: Santiago Pastorino <santiago@wyeworks.com> |