I have an application with reporting feature where user can go query for my data.
As of now, I have written all the code to create the dynamic queries based on user's criteria and then run those queries in the data base and show it to the user.
What I need is a reporting tool, to which I will just give my data/database , and it will be provide an interface to run reports on.
My application is a Ruby on Rails application.
Any ideas ?
Checkout rails-data-explorer (RDE). RDE is a Rails engine plugin that makes it magically easy to explore your app's data using charts and statistics.
Related
I trying to integrate a current wordpress woocomerce website with a rails app.
I need to figure out with the best way to do two things:
Fetch, Create, update and delete products/posts with all the taxonomies and fields in the wordpress woocomerce website from my rails app.
Know when an order was did from paypal in the wordpress woocomerce website and then update my rails app.(already woocomerce know when the order was did and then update their wp tables)
I will appreciate if anyone could help me or show me the right way to do this :)
I was originally going to write about using an API for this, however, I think there's a better way - to hook into the WP table from Rails
From what you've written (which doesn't give much context btw), it seems you're looking for some way to manage your products & orders independently of Wordpress. Perhaps you want to integrate the data into a CRM, or you want to create an order-tracking system; it all needs data
Data
There are two ways to do it:
Create independent Rails app & port data with an API
Build the Rails app on top of the Wordpress db
API
An API will be best if you want to keep your data separate (you have sensitive data / you want to migrate to a total Rails solution)
You'll need to create your db through Rails, and then use a RESTful API interface to process JSON strings of all the products from WP. You'd have to send the objects by either a plugin, or a cron-job running a simple script to comb the database every night
As you can guess, this will be the least efficient way of doing it, but the most robust. You'd have two data-sets, and any updates in WP's table structure will have to be reflected in your Rails implementation
Wordpress
The better way to do this will be to hook into the Wordpress db directly
The problem here is that you'll effectively be managing two database systems (Rails likes to run off its own db), so you'll have to manage user profiles etc from the Rails DB, whilst hooking into the products db in Wordpress
Although I've got zero experience with this, I found some resources which may help:
Ruby on Rails Integration With Wordpress
Searching WordPress blog from Rails app
Hope this gives you some ideas!
Disclaimer: We're a collection of scientists that are just now getting into python/ruby.
Project summary: We have analytics and usage data from social networking sites that we are using R and Highcharts (via lazy_high_chart gem) to present analytics to users through a website. The user can interact with this data by specifying which and when they want to investigate a social media segment. So the user defines the subject and the website responds with a slew of metrics.
Problem: So far we have been using straight ruby to pull social networking data (one class), send it to the analytics engine (another class), and present it in plotted glory (final class). However, this is all been proof of principle and console driven so it seems inefficient to push it to a site from this start. Should we have started from the ground up with a rails framework and just built the site with all of these analytic engines built into the site? Or...is it better to have this backend pipeline written in ruby that only interfaces with a rails framework trough yet another object?
A suggestion or pointer to a general document that hints on how to integrate backend data crunching with frontend rails would be great.
Your question is basically how to architecture the system, and this is somewhat hard answer since it usually depends on a lot of things: system requirements, application landscape, project planning, skills, etc.
But just looking at the two alternatives you mentioned, I think there's nothing wrong with creating a fresh Rails application, copying your prototype modules into the lib/ directory and connecting things the standard way. You can use rake tasks to keep the console interface you already have. In the end, your setup looks quite similar to a standard web application. (Usually you have a database doing the "data crunching", in your case it is the R engine.)
I don't know any specific documentation about integration Rails with R, but some research about general system integration with Rails should give you a good starting point. (However, this would only be needed if you really want to build two independent systems.)
I need build in web query capability similar to what you can do in Excel for a project that I'm working on. Has anyone come across a gem, plug-in or application with this capability.
Clarification: To clarify, the excel web query features that I'm trying to create is the ability to extract data from specified tables on a web page. A good example would be if given a particular ticker symbol the web query would be able to submit the ticker symbol and then extract and display output table.
I've looked at fork on project like nokogiri, celerity and other screen scraping apps but have not come across what I'm looking for yet.
Thanks for your insights, ideas and suggestions.
If you are interested in possible screen scraping gems/plugins checkout: regexp_crawler, spidr, scrAPI or mechanize
I am developing my first Rails app, a web replacement to a paper form system. Some way through development I discover my client wants to be able to add ad hoc new forms to the live system.
I have considered using wufoo/ google forms/ or survey monkey, but I don't think they are going to fit the bill, due to integration requirements.
What I basically want is to enable one or two super-users to create forms, which will then be available to other users in the system. When the forms are completed the output should be made available to my system. The data is to be manually collated for analysis, so even CSV is fine - there is no need for complex modelling.
I have been struggling to find any paths to a solution - I really don't want to build a form builder myself! So if anybody can point me in the right direction it would be most appreciated!
Cheers!
The liquid template is a good choice for custom building web pages. The easier approach is creating pure HTML pages with form to your system, if your customer allows to.
For the data storage, you'd better try nosql database, such as the mongodb and mongo gem as the ruby adapter, so you can save any data structure without managing the tables and columns. By the way, you have to learn some ruby meta-programming skills to process the dynamic data from the client.
It seems to me that Rails shines when building web-centric applications such as the Depot online-store app presented in the Agile book or the Basecamp project management system. The crux of these applications is their web interface, and Rails gives you the tools to create these webapps quickly, easily, and elegantly.
But what if you have an application with a command line interface for which you'd like to add a front-end? For example, imagine an application which processes third-party EDI files - it gets them from an FTP server, parses them, inserts the data into a database and sends out reports via emails. The schedule of when the app should run, which reports should be generated, who should get the email, etc. is all configured in a database. And although the main point of the application is the processing of EDI files and you want to run it via cron, you'd like to build a web page to allow users to manage which reports they're receiving, how often they receive them, etc.
Both the command line app and the web page need to access the same data in the database. They should be able to share models and business logic. If the command line app already contains a library with a data access layer, is there a way to leverage this library within Rails? Or, conversely, is there a way to reuse Rails' models and controllers in an outside app? Or does it not make sense to use Rails as the web framework in this scenario?
You could always just include the ActiveRecord library (and ActiveSupport) in a regular ruby application, if you are just looking to abstract away the model layer for a db centric app.
Actually, most rails apps have a web interface and also a command-line interface - through rake.
The classical example are batch jobs that have to be run periodically, though cron or whenever. But it is also possible to run those tasks manually.
If I were you, I'd try building some rake tasks inside lib/tasks in order to map those command-line commands.