Skip to content

save field results in to_s version all the time #1

@tillcarlos

Description

@tillcarlos

Hey guys

Awesome that you put this together! It comes at the right time :)

When I edit the form in correct json (text/tree), and then save the field, it always results in the to string version "{\"key\": ...

This is my schema:

    create_table :grammatical_forms do |t|
      t.json :translations
      t.string :identifier, index: true
      t.timestamps
    end

I use it in the dashboard as described

  ATTRIBUTE_TYPES = {
    meanings: Field::HasMany,
    id: Field::Number,
    identifier: Field::String.with_options(searchable: false),
    translations: Field::JSONB,
    created_at: Field::DateTime,
    updated_at: Field::DateTime,
  }.freeze

Any ideas right away? I haven't debugged yet, but I might do in the next days.

Thanks again

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions