Displaying 7 results from an estimated 7 matches for "reportscontrol".
2006 May 15
1
1 controller, 2 layouts
I am having an issue with a controller that needs to utilize two
different layouts, depending on the action. The entire app makes use of
the application layout, so I added this to my controller to use for all
of our reports:
class ReportsController < ApplicationController
layout "reporter", :except => :index
I was hoping that the layout would only be applied to all the actual
reports (there are several), while the index action would continue to
use the application layout. Instead, the reports are wrapped in the
layout...
2010 Apr 29
2
send_data => invalid byte sequence in US-ASCII
...ode by writing its output to a file and displaying it
-- it works.) My Report model receives the .png image as a string:
class Report << ActiveRecord::Base
def imagedata
image = GnuPlot(@gnuplot_commands)
end
end
My Controller uses send_data() to serve up a page:
class ReportsController < ApplicationController
def plot
report = Report.find(params[:id])
send_data(report.imagedata, :type => ''image/gif'')
end
end
[FWIW, without really understanding it, I also tried added an :encoding
=> ''utf8'' to the send_data call...
2013 Mar 07
2
Puppet Dashboard changed reports view error
...gt;>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
Processing ReportsController#changed (for 10.0.8.58 at 2013-03-06
18:04:27) [GET]
Parameters: {"action"=>"changed", "controller"=>"reports"}
Rendering template within layouts/application
Rendering reports/index
ActionView::TemplateError (node_url failed to generate from
{:...
2006 Jun 19
1
pdf simpletable help needed
...m trying to generate a pdf of all of the users in an application that
i have built. i am still pretty new to ruby and rails so i don''t know
the best way to go about it.
here is my controller code:
require ''pdf/writer''
require ''pdf/simpletable''
class ReportsController < ApplicationController
def test
_pdf = PDF::Writer.new
table = PDF::SimpleTable.new
user_data = []
for user in User.find(:all)
user_data << user.attributes
end
table.data = user_data
table.render_on(_pdf)
send_data _pdf.render, :filename =>...
2009 May 15
0
Help with Jasper reports(Jasper Server) integration
...led the soap4r & jasperserver-client gems and setup a
Jasper Server. I''ve also added a sample working report to the
repository that I''m trying to run from Rails. I''m getting the
following error when trying to connect to Jasper Server via Rails:
uninitialized constant ReportsController::JasperServer
Can someone help me with this?
I''m sure I''m missing a require or something like that.
Thanks,
Gary.
2006 Mar 15
13
usage of constants
I would like to define some constants that I can use across models and
views and I cannot figure out how to do that. Googling hasn''t turned up
anything useful and I''m looking at the PickAxe book, and I get the
impression that a constant must belong to a class.
If I just want a constant like...
CompanyPhoneNo = "(602) 999-9999"
and be able to use it in any view
2007 Dec 06
10
Feedback on RC2
I tried to upgrade my existing application to RC2 last night. Like many, I
use this mostly for running scheduled tasks. For the moment, I''ve abandoned
the effort, but am looking forward to being able to use this. Feedback
below:
First, the reason I was looking forward to this upgrade was to use the
threaded scheduler. I have an application with long-running tasks. I found
that