https://github.com/oklas/activeadmin-sqlpage
rails dbconsole online - ActiveAdmin page that allow execute SQL requests and show result in table
https://github.com/oklas/activeadmin-sqlpage
activeadmin database dbconsole online ruby ruby-gem ruby-on-rails sql
Last synced: 6 months ago
JSON representation
rails dbconsole online - ActiveAdmin page that allow execute SQL requests and show result in table
- Host: GitHub
- URL: https://github.com/oklas/activeadmin-sqlpage
- Owner: oklas
- License: mit
- Created: 2016-08-09T09:01:06.000Z (over 9 years ago)
- Default Branch: master
- Last Pushed: 2017-06-01T19:16:58.000Z (almost 9 years ago)
- Last Synced: 2024-04-24T18:54:57.516Z (almost 2 years ago)
- Topics: activeadmin, database, dbconsole, online, ruby, ruby-gem, ruby-on-rails, sql
- Language: Ruby
- Homepage:
- Size: 6.84 KB
- Stars: 1
- Watchers: 2
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.txt
Awesome Lists containing this project
README
# ActiveAdmin::SqlPage
This is **`rails dbconsole`** online
Add page to your ActiveAdmin panel that allow execute raw SQL requests and show result in table
[](https://rubygems.org/gems/activeadmin-sqlpage)
## Installation
Add this line to your application's Gemfile:
```ruby
gem 'activeadmin-sqlpage'
```
And then execute:
$ bundle
Or install it yourself as:
$ gem install activeadmin-sqlpage
## Usage
To add SQL Page to your active admin place this peace of code for example to `app/admin/sql.rb`:
```ruby
ActiveAdmin::SqlPage::register
```
Open your site at active admin page, navigate menu `SQL`, enter raw sql request in textarea, and press `Ctrl-Enter` hotkey or click `submit`.
Be carefull to execute sql requests. It may upset the consistent of your database. It is recomented to enable this page for worked project where only advanced user may have access to execute sql.
## Contributing
Bug reports and pull requests are welcome on GitHub at https://github.com/oklas/activeadmin-sqlpage.
## License
The gem is available as open source under the terms of the [MIT License](http://opensource.org/licenses/MIT).
## Copyright
Copyright (c) 2016-present Serguei Okladnikov