Manage your Rails database through a spreadsheet-like interface.
- Look at and modify your DB within the app itself (no rails console required!).
- Give controlled DB access to your admin users without having to create CRUD views for each table.
- Lightweight and fast. We keep usage simple and configuration to the minimum.
- Add
gem "hotsheet"
to your Gemfile. - Run
bundle
. - Run
bin/rails g hotsheet:install
.
After the installation, you can start the Rails server and visit /hotsheet to view the spreadsheet.
You can configure which models ('sheets') this gem should manage, and specify which database columns should be editable or viewable in the spreadsheet. This can be done by editing the config/initializers/hotsheet.rb file created by the install command:
Hotsheet.configure do
# Configure the visible and editable columns for each model.
# The ID is included as the first column by default.
# The number of rows displayed can be configured using the `per` option,
# which defaults to 100.
sheet :User, per: 10 do
column :name
column :email, editable: false
column :birthdate, editable: -> { rand > 0.5 }
end
# Leave the block out to include all database columns.
sheet :Post
end
If you don't want everyone to have access to Hotsheet, you can set a basic auth environment variable:
HOTSHEET_BASIC_AUTH="admin:password"
You can create custom translations by overwriting the default locales defined in config/locales/en.yml.
See Contributing Guide and please follow the Code of Conduct.
This is a newly created gem, and we will firstly focus on:
- Single-user experience (styles and usability)
- Configuration and access permissions
- Concurrent users (broadcasting, conflict resolution)
Feel free to look at our planned enhancements or add your own.
Hotsheet is available as open source under the terms of the
MIT License.
Copyright © 2024-present Renuo AG.