Skip to content

work-design/rails_extend

Repository files navigation

RailsExtend

测试 Docker构建 Gem

Rails 通用基础库,对 Rails 的各个组件进行了扩展。

功能模块

支持 enum

# zh.yml
activerecord:
  enum:
    notification:
      receiver_type:
        User: 全体用户
        Member: 成员
t.select :receiver_type, options_for_select(Notification.options_i18n(:receiver_type))
  • Override
activerecord:
  enum:
    notification:
      receiver_type:
        User: 全体用户
        Member: # remain this blank

版权

遵循 MIT 协议

About

Rails 框架核心库拓展

Resources

Stars

Watchers

Forks

Sponsor this project

Packages

No packages published

Languages