show error messages on bur failures
This commit is contained in:
@@ -32,7 +32,6 @@ class BulkUpdateRequestsController < ApplicationController
|
||||
|
||||
def approve
|
||||
@bulk_update_request.approve!(CurrentUser.user.id)
|
||||
flash[:notice] = "Bulk update request approved"
|
||||
respond_with(@bulk_update_request, :location => bulk_update_requests_path)
|
||||
end
|
||||
|
||||
|
||||
@@ -1 +1,5 @@
|
||||
$("#request-status-for-<%= @bulk_update_request.id %>").html("queued");
|
||||
<% if @bulk_update_request.errors.any? %>
|
||||
Danbooru.error(<%= j @bulk_update_request.errors.full_messages.join(',') %>);
|
||||
<% else %>
|
||||
$("#request-status-for-<%= @bulk_update_request.id %>").html("queued");
|
||||
<% end %>
|
||||
|
||||
Reference in New Issue
Block a user