Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/langalex/dead_simple_reports
create reports via sql or ruby code for your rails app in minutes
https://github.com/langalex/dead_simple_reports
Last synced: 15 days ago
JSON representation
create reports via sql or ruby code for your rails app in minutes
- Host: GitHub
- URL: https://github.com/langalex/dead_simple_reports
- Owner: langalex
- License: mit
- Created: 2008-04-11T12:59:01.000Z (over 16 years ago)
- Default Branch: master
- Last Pushed: 2008-07-07T17:26:33.000Z (over 16 years ago)
- Last Synced: 2024-04-13T09:17:54.561Z (8 months ago)
- Language: Ruby
- Homepage: http://upstream-berlin.com/blog/open-source/#dead_simple_reports
- Size: 88.9 KB
- Stars: 15
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README
- License: MIT-LICENSE
Awesome Lists containing this project
README
== dead simple reports ==
this rails plugin allows you to easily create and view arbitrary reports of your database tables. it therefore creates a reports controller with views and a report model in your application. to create a report you simply create an instance of Report. it then appears in the list of reports where you can view it either as html, csv or xls table.
=== to create a report ===
Report.create! :name => 'My Ruby Report', :kind => 'code', :code => 'User.find(:all).map(:&name)'
This will generate a report that lists all user's names.
Alternatively you can create a sql report:
Report.create! :name => 'My SQL Report', :kind => 'sql', :code => 'SELECT name FROM users'
to view the list of reports just go to http://localhost:3000/reports
=== customizing the views ===
to customzie the views you can simply edit the files under app/views/reports in your application.
== customizing the controller ==
to customize the controller you can add code to the app/controllers/reports_controller file generated in your application.
=== contact ===
for hints, questions etc. please email alex[at]upstream-berlin.com