rs-pro / rails_admin_settings

Rails Admin Settings: App Settings management via RailsAdmin
https://gitlab.com/rocket-science/rails_admin_settings
MIT License
29 stars 21 forks source link

How to add new kinds of file or html like Shrine or Froala #12

Open prem-prakash opened 7 years ago

prem-prakash commented 7 years ago

I was wondering how to add new file engines, like Shrine. Or rich editors like Froala.

Could you provide a simple guide on which files I would have to work on?

glebtv commented 6 years ago

Hello, admin form can be changed in this view file https://github.com/rs-pro/rails_admin_settings/blob/master/app/views/rails_admin/main/_setting_value.html.haml You can just override it in your app, but pull requests are welcome.

File engines are here https://github.com/rs-pro/rails_admin_settings/blob/master/lib/rails_admin_settings/uploads.rb https://github.com/rs-pro/rails_admin_settings/search?utf8=%E2%9C%93&q=file_uploads_engine&type= and specs https://github.com/rs-pro/rails_admin_settings/blob/master/spec/paperclip_spec.rb here

Specs are run separately for each engine via env like so

UPLOADS=paperclip rspec