Merge pull request #6561 from opf/fix/28274/use-slug-to-identify-page

[28274] Use page slug to identify page on edit
pull/6565/head
ulferts 6 years ago committed by GitHub
commit 9cc13208ef
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 2
      app/views/wiki/edit.html.erb

@ -30,7 +30,7 @@ See docs/COPYRIGHT.rdoc for more details.
<% breadcrumb_paths(*(@page.ancestors.reverse.collect { |parent| link_to h(parent.breadcrumb_title), {id: parent, project_id: parent.project}} + [h(@page.breadcrumb_title)] )) %>
<%= labelled_tabular_form_for @content,
as: :content,
url: {action: 'update', id: @page.title.presence || @old_title},
url: {action: 'update', id: @page.slug.presence || @old_title},
html: {method: :put, multipart: true, id: 'wiki_form'} do |f| %>
<%= f.hidden_field :lock_version %>

Loading…
Cancel
Save