#656 open
Kieran P

better documentation required for table-plus

Reported by Kieran P | March 3rd, 2010 @ 05:27 AM | in Hobo 1.1

Overiding collection with a table-plus for children displays on the parent fails with 'undefined method member_name'

I'm not sure if I'm doing it right, so it's more of a 'possibly bug report, help me with this' type ticket.

Steps to reproduce:

hobo contacts_list
cd contacts_list
ruby script/generate hobo_model_resource Company name:string
ruby script/generate hobo_model_resource Contact name:string

class Company
  ...
  has_many :contacts
end

class Contact
  ...
  belongs_to :company
end

class CompanyHints < Hobo::ViewHints
  children :contacts
end

Add the following to application.dryml

  <extend tag="show-page" for="Company">
    <old-show-page merge>
      <collection: replace>
        <table-plus fields="this"/>
      </collection:>
    </old-show-page>
  </extend>

ruby script/generate hobo_migration

ruby script/server

Then:

  • Create a default account
  • Create a company
  • Create a contact of that company
  • Go to the company show page
  • ERROR :-(

Comments and changes to this ticket

  • Tim Griffin

    Tim Griffin April 15th, 2010 @ 07:20 PM

    • Assigned user set to “Owen”

    I had a similar error with Tutorial 17 in The Agile Project Manager. The text on Page 214 shows
    <table-plus: requirements fields="this, status"> where it should show:
    <table-plus:requirements fields="this, status">

    Notice that there is not supposed to be a space in between the table-plus: and the association name.

    With the space, this was creating a "undefined method member_class' " error.

  • Owen

    Owen May 3rd, 2010 @ 11:24 PM

    Thanks, I missed this one. There is a separate LIghthouse project for "Rapid Rails with Hobo"

  • Owen

    Owen May 29th, 2010 @ 12:15 AM

    • Milestone set to Hobo 1.0X
    • State changed from “new” to “open”
    • Assigned user changed from “Owen” to “Bryan Larsen”
  • Bryan Larsen

    Bryan Larsen November 15th, 2010 @ 04:32 PM

    • Milestone changed from Hobo 1.0X to Hobo 1.1
    • Title changed from “Overiding collection with a table-plus for children displays on the parent fails with 'undefined method member_name'” to “better documentation required for table-plus”
    • Tag changed from children, collection, table-plus to children, collection, doc, table-plus
    • Milestone order changed from “0” to “0”

Please Sign in or create a free account to add a new ticket.

With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.

New-ticket Create new ticket

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile ยป

Pages