如何将css文件添加到管理面板?
我试过这个:https://github.com/sferik/rails_admin/wiki/Theming-and-customization
在app中:app / assets / stylesheets / rails_admin / custom / theming.css.scss
我查看了网页来源,但没有显示。
我只想将https://github.com/Nerian/bootstrap-wysihtml5-rails CSS和Javascript添加到管理面板。
由于生产中的某些原因,bootstrap-wysihtml5-rails编辑器无法显示。
感谢。
答案 0 :(得分:1)
问题是rails admin正在使用路径:/assets/bootstrap-wysihtml5.css和/assets/bootstrap-wysihtml5.js,编译的内容可能类似于/assets/bootstrap-wysihtml5-xyz22323.css等
我刚刚将普通文件:/assets/bootstrap-wysihtml5.css和/bootstrap-wysihtml5.js添加到公共目录。
答案 1 :(得分:0)
试试这个
$('.textarea').wysihtml5({
...
stylesheets: ["<%= asset_path('your-css-file.css') %>"]
});