Rails 3: using non-Active Record objects with form_for

后端 未结 2 706
没有蜡笔的小新
没有蜡笔的小新 2021-02-13 00:36

Is there any documentation, or advice?

相关标签:
2条回答
  • 2021-02-13 01:08

    You can use Active Model

    Take a look here.

    Look at the source code at Github.

    0 讨论(0)
  • 2021-02-13 01:09

    Using ActiveAttr is the more modern way of doing this.

    Gem: https://github.com/cgriego/active_attr
    Railscast: http://railscasts.com/episodes/326-activeattr

    0 讨论(0)
提交回复
热议问题