Skip to content

Enum type column is updated as '-' on Rails 5 #2713

@muraaano

Description

@muraaano

On rails 5, enum type can be shown on admin index view by default. (Nice!)
But it will be '-' on index view after updated once by edit view.

Environment:
rails (5.0.0)
rails_admin (1.0.0.rc)

Model file:
class Room < ApplicationRecord
enum state: {vacant:0, occupied:1, failed:2}

Log:
"room"=>{"state"=>"0"}

So it looks "0" is not correct, shall be 0 as integer not string?

Metadata

Metadata

Assignees

No one assigned

    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