I have an application that I'm in the process of upgrading to Rails
3.0.5.  I'm doing this by copying my code over a fresh Rails 3 app.  I
installed ActiveScaffold using:

rails plugin install git://github.com/vhochstein/active_scaffold.git

It seemed to work fine, but I'm now getting an error in my
controller.  Here's the controller:

class PagesController < ApplicationController

  active_scaffold :pages

  def local_authenticate
    authenticate(['PageManager'])
  end

  active_scaffold :pages do | config |
    config.list.columns = [:title, :created_at, :updated_at]
    config.show.columns =
[:title, :body, :permalink, :created_at, :updated_at]
    config.create.columns = [:title, :body, :permalink]
    config.update.columns = [:title, :body, :permalink]
    config.action_links.add 'read', :label => 'Proof', :type
=> :record, :inline => :false
  end

  layout "admin"

  ########################## PUBLIC METHODS
###########################

  def read
    @page = Page.find(params[:id].to_i)
    render :layout => "application"
  end

end

-------------------
-------------------
And here's the error:
-------------------
-------------------

ArgumentError in User#index

Showing /Users/dlamet/Documents/dev/DigiBunker/site3/athena/vendor/
plugins/active_scaffold/frontends/default/views/_action_group.html.erb
where line #4 raised:

wrong number of arguments (1 for 0)

Extracted source (around line #4):

1: <% record ||= nil
2:    start_level_0_tag ||= ''
3:    end_level_0_tag ||= ''%>
4: <% action_links.traverse(controller, traverse_options) do |parent,
link, options| -%>
5:   <% if (options[:node] == :finished_traversing) -%>
6:     <%= "</ul>#{(options[:level] == 0 ? "</div>#{end_level_0_tag}":
'</li>')}".html_safe %>
7:   <% elsif (options[:node] == :start_traversing) -%>

Trace of template inclusion: vendor/plugins/active_scaffold/frontends/
default/views/_list_actions.html.erb, vendor/plugins/active_scaffold/
frontends/default/views/_list_record.html.erb, vendor/plugins/
active_scaffold/frontends/default/views/_list.html.erb, vendor/plugins/
active_scaffold/frontends/default/views/_list_with_header.html.erb,
vendor/plugins/active_scaffold/frontends/default/views/list.html.erb

Rails.root: /Users/dlamet/Documents/dev/DigiBunker/site3/athena

-------------------
-------------------

Any suggestions?  Thanks, Dan

-- 
You received this message because you are subscribed to the Google Groups 
"ActiveScaffold : Ruby on Rails plugin" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/activescaffold?hl=en.

Reply via email to