title: Missing template action error in rails3
body: <p>I have defined a method in controller that is like:</p>
  
  <pre><code>def self.dailymail
    ....  #fill data from db
  
    ac = ActionController::Base.new()  
    kit = PDFKit.new(ac.render_to_string(:action =&gt; "formatinhtml.html.erb",:rawdata =&gt; data))
    pdf = kit.to_pdf
   ...   #send pdf in mail
   end
  </code></pre>
  
  <p>formatinhtml is like:</p>
  
  <pre><code>def formatinhtml
      @dailyrep = params[:rawdata]
      respond_to do |format|
        format.html # daily.html.erb
      end
  end
  </code></pre>
  
  <p>I have to use self.dailymail so that I can call it from model &amp; in turn from rufus scheduler.<br/>But,still I get error such as:</p>
  
  <pre><code>scheduler caught exception:
  Missing template action_controller/base/daily.html with {:locale=&gt;[:en], :formats=&gt;[:html, :text, :js, :css, :ics, :csv, :png, :jpeg, :gif, :bmp, :tiff, :mpeg, :xml, :rss, :atom, :yaml, :multipart_form, :url_encoded_form, :json, :pdf, :zip, :xls], :handlers=&gt;[:erb, :builder, :coffee]}. Searched in:
    * "F:/DEVELOPMENT/TrackIt/app/views"
  C:/Ruby193/lib/ruby/gems/1.9.1/gems/actionpack-3.2.8/lib/action_view/path_set.rb:58:in `find'
  C:/Ruby193/lib/ruby/gems/1.9.1/gems/actionpack-3.2.8/lib/action_view/lookup_context.rb:109:in `find'...
  </code></pre>
  
  <p>so,what does I need to do?</p>
  
  <p><br/><b>Update:</b> After debugging,I found action <code>formatinhtml</code> is not actually being getting  called;I have defined neccessary routes.</p>