Skip to content

Move form to a partial #25

@bgates

Description

@bgates

Instead of having the form exist in the new and edit (and now index!) templates, put it in a partial and refer to that partial in the new and edit templates.

For the index template, remove the form entirely and bring back the link to Add New Restaurant - but have the link work by xhr to insert the form after the link.

When the new restaurant form is submitted, have it insert the new restaurant row via xhr (which it should be doing now), and then remove the form from the page.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions