[html-formfu] Config generator

Byron Young Byron.Young at riverbed.com
Thu Mar 13 21:24:35 GMT 2008


Zbigniew Lukasiak wrote:
> Hi there,
>
> I've made a new version of the config generator - see the attachment.

Hey Zbigniew,

I think it's very useful.  Thanks!

However, I think I've found a problem with how it handles belongs_to relationships.  In my [very limited] usage of HTML::FormFu, belongs_to ought to be represented with a Block, like so:

  - type: Block
    elements:
      - type: Select
        name: belongs_to
        label: Belong_to
        attributes:
          title: Pick something from the other table
        model_config:
          DBIC:
            model: DB::ForeignTable


Instead, your generator creates a Repeatable, which seems to me to only make sense in the has_many case (or many_to_many), since with belongs_to you can only have one item from the foreign table.

Are my assumptions wrong?  Since I am a FormFu noob, I wouldn't be surprised if the way I'm using it is not standard convention.

Regards,
Byron



More information about the HTML-FormFu mailing list