ruby-on-rails - 包括 RailsAdmin 组中的所有剩余字段
问题描述
在组块之外使用时,include_all_fields
将呈现所有未在 CRUD 操作块中显式写入的剩余字段。
有没有办法include_all_fields
在 RailsAdmin 组中使用该方法?或者以某种方式呈现所有剩余字段,这些字段尚未在同一 CRUD 操作块中的其他组中呈现?
例如
module DummyAdmin
extend ActiveSupport::Concern
included do
rails_admin do
edit do
group :first_group do
field :some_field
end
group :second_group do
field :another_field
field :yet_another_field
end
group :group_containing_all_other_fields do
include_all_fields # this renders an error
# I'm looking for some other way to render all remaining fields inside this group block
end
end
end
end
end
解决方案
推荐阅读
- android - DexOverflowException:无法在 main-dex 文件中容纳请求的类
- c# - Nsubstitute - 当处理程序使用泛型时引发模拟对象的事件
- msbuild - VSTS 如何使用多项目解决方案创建包文件(zip)
- android - 在 Oreo 中自定义 google setupwizard 时出现安全异常
- sql-server - 使用在 MSSQL 中使用 EncryptByPassPhrase() 加密的 powershell 解密字符串
- r - 我正在 Rstudio 中进行参数化降价,并且无法更改使用 ggplot2 生成的条形图的颜色
- angular - 如何在 Angular 中的验证指令中触发 ngOnChanges 上的验证函数?
- dronekit-python - 在 2 个 python 代码上调用 vehicle = connect() 导致连接断开
- mapbox-gl-js - Mapbox 属性函数:基值
- java - 如何使用 Java 从 Windows 获取 GPS 位置