Custom Field not working

@vinothkannans Again thanks for suggestion,

I have successfully added field.

I have one issue though the add_to_serializer is loaded before a HTTP request comes in, therefore if I set the value of the custom field with params[“value_to_field”] from the params Hash, it fails for obvious reason, the fact that it add_to_serializer does not have access to params, is there a way to circumvent this limitation.

Thanks

You can get params only in controllers.

You have to understand the differences between serializers and controllers. Also read other Rails essentials.

2 Likes