artists: allow members to rename, delete, and undelete artists.

Also allow Members to edit deleted or banned artists. Previously this
was limited in the html, but not in the backend.
This commit is contained in:
evazion
2019-12-16 19:38:16 -06:00
parent ddf928515c
commit fff4e3badd
6 changed files with 12 additions and 33 deletions

View File

@@ -1,10 +1,8 @@
<%= simple_form_for(@artist) do |f| %>
<% if @artist.new_record? %>
<%= f.input :name, as: :string, input_html: { data: { autocomplete: "tag" } } %>
<% elsif CurrentUser.user.is_builder? %>
<%= f.input :name, as: :string, input_html: { data: { autocomplete: "tag" } }, hint: "Change to rename this artist entry and its wiki page" %>
<% else %>
<p><%= @artist.name %></p>
<%= f.input :name, as: :string, input_html: { data: { autocomplete: "tag" } }, hint: "Change to rename this artist entry and its wiki page" %>
<% end %>
<%= f.input :other_names_string, label: "Other names", as: :text, input_html: { size: "50x1" }, hint: '<b style="color: red;">NEW</b> Separate names with spaces, not commas. Use underscores for spaces inside names.'.html_safe %>