active_model_serializers icon indicating copy to clipboard operation
active_model_serializers copied to clipboard

ActiveModel::Serializer implementation and Rails hooks

Results 120 active_model_serializers issues
Sort by recently updated
recently updated
newest added
trafficstars

Consider an STI case with only parent class serializers and no separate child serializers. Now throw in different namespaces. With model's: ``` class Parent < ActiveRecord::Base end class ChildA <...

Probably doing something wrong, but ... #### Expected behavior vs actual behavior Given the following models & serialisers: ```ruby class Shipment < ApplicationRecord has_many :shipment_service_types end class ShipmentServiceType < ApplicationRecord...

C: Documentation
S: Ready for PR
C: Deep Nesting

Hello AMS team, 👋 🙂 First of all, thank you for maintaining this little gem! It's not a gem issue, rather an upgrade question and I would really appreciate any...

#### Expected behavior vs actual behavior We have several failures that have popped up in our unit-test cases (rspec) after upgrading to Rails 4, largely related to the `revisions` and...

while deserializing any polymorphic relation, the type of the record was coming wrong. (e.g, for a relation of type 'BlogPost', the type was coming out as 'Blog-post'). This was happening...

#### Expected behavior vs actual behavior Given the data ``` data = { "data"=>{ "id"=>"1", "type"=>"comments", "attributes"=>{ "comment"=>"Comment 2", "image-url"=>"", "author"=>"unverified", "created-at"=>"2018-07-06T21:08:52" }, "relationships"=>{ "commentable"=>{"data"=>{"id"=>"7", "type"=>"blog-posts"}} } } } }...

I'm trying to either generate a link, or get the proper data in my has_many relationships #### Expected behavior vs actual behavior Inside a has_many block I expect to be...

I'm running my RSpec tests and my polymorphic comments are not rendering as expected. It seems like it's not even being passed to the associated serializer in my PostSerializer. The...

#### Purpose With models that have many relationships, especially nested relationships, automatically including those relationships by default can make an otherwise fast query take a long time. Allowing an easy...

This is more of a question, since I'm not sure you want to support this use case. This is related to an issue with [Discourse](https://github.com/discourse/discourse) - https://meta.discourse.org/t/inconsistent-behaviour-in-plugins-between-development-and-production/87220 #### Expected behavior...