From f7ce8c245fde3f6202103ae614b181c0ba44ed93 Mon Sep 17 00:00:00 2001 From: hukl Date: Wed, 9 Sep 2009 15:19:33 +0200 Subject: added editing of slugs and moving of nodes. to edit a slug or move a node you edit that node, make your changes and save. the slug and parent node changes get staged and are applied once that revision is published --- app/views/nodes/edit.html.erb | 22 +++++++++++++++++++++- 1 file changed, 21 insertions(+), 1 deletion(-) (limited to 'app/views') diff --git a/app/views/nodes/edit.html.erb b/app/views/nodes/edit.html.erb index e41321d..c23381f 100644 --- a/app/views/nodes/edit.html.erb +++ b/app/views/nodes/edit.html.erb @@ -18,7 +18,27 @@ Slug - <%= f.text_field :slug %> + + <%= + f.text_field( + :staged_slug, :value => @node.staged_slug || @node.slug + ) + %> + + + + parent + + <%= text_field_tag :move_to_search_term, @node.parent.title rescue "" %> +
+ +
+ <%= f.hidden_field( + :staged_parent_id, + :value => @node.staged_parent_id || @node.parent_id + ) + %> + <% fields_for @draft do |d| %> -- cgit v1.3