diff --git a/app/views/peoples/_people_form.rhtml b/app/views/peoples/_people_form.rhtml new file mode 100644 index 0000000..9651bda --- /dev/null +++ b/app/views/peoples/_people_form.rhtml @@ -0,0 +1,4 @@ +
+ <%= text_field 'people', 'title' %> +
+<%= render :partial => 'pages/page_form' %> diff --git a/app/views/peoples/edit.rhtml b/app/views/peoples/edit.rhtml index e7af0a6..004541c 100644 --- a/app/views/peoples/edit.rhtml +++ b/app/views/peoples/edit.rhtml @@ -1,10 +1,12 @@ <%= error_messages_for :people %> -<% form_for(:people, :url => people_path(@people), :html => { :method => :put }) do |f| %> +<% form_for(:people, :url => people_path(@people.page.title_for_url), :html => { :method => :put }) do |f| %> + <%= render :partial => 'people_form' %><%= submit_tag "Update" %>
<% end %> -<%= link_to 'Show', people_path(@people) %> | -<%= link_to 'Back', peoples_path %> \ No newline at end of file +<% content_for :sidebar do -%> + <%= show_people_link(@people) %><%= submit_tag "Create" %>
<% end %> - -<%= link_to 'Back', peoples_path %> \ No newline at end of file