Skip to content

Commit

Permalink
Remove StockMovements#new
Browse files Browse the repository at this point in the history
I broke this page over a year ago in
0f5c0d0

Nobody noticed so it should probably be safe to remove.

This page previously provided an interface to manually create a stock
movement. I think this can more easily be done by editing stock from our
stock management page.
  • Loading branch information
John Hawthorn committed Mar 13, 2017
1 parent 7289efd commit 2e6aef0
Show file tree
Hide file tree
Showing 6 changed files with 1 addition and 56 deletions.
1 change: 0 additions & 1 deletion backend/app/assets/javascripts/spree/backend.js
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,6 @@
//= require spree/backend/stock_management/index_add_forms
//= require spree/backend/stock_management/index_update_forms
//= require spree/backend/stock_management/stock_item
//= require spree/backend/stock_movement
//= require spree/backend/stock_transfers/count_update_forms
//= require spree/backend/stock_transfers/edit
//= require spree/backend/stock_transfers/receive
Expand Down

This file was deleted.

12 changes: 0 additions & 12 deletions backend/app/views/spree/admin/stock_movements/_form.html.erb

This file was deleted.

6 changes: 0 additions & 6 deletions backend/app/views/spree/admin/stock_movements/index.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,6 @@


<% content_for :page_actions do %>
<% if can?(:create, Spree::StockMovement) %>
<li>
<%= button_link_to Spree.t(:new_stock_movement), new_admin_stock_location_stock_movement_path(@stock_location), id: 'admin_new_stock_movement_link' %>
</li>
<% end %>

<% if can?(:display, Spree::StockLocation) %>
<li>
<%= link_to_with_icon 'arrow-left', Spree.t(:back_to_stock_locations_list), admin_stock_locations_path, class: 'button' %>
Expand Down
15 changes: 0 additions & 15 deletions backend/app/views/spree/admin/stock_movements/new.html.erb

This file was deleted.

2 changes: 1 addition & 1 deletion backend/config/routes.rb
Original file line number Diff line number Diff line change
Expand Up @@ -167,7 +167,7 @@
end

resources :stock_locations do
resources :stock_movements, except: [:edit, :update, :destroy]
resources :stock_movements, only: [:index]
collection do
post :transfer_stock
post :update_positions
Expand Down

0 comments on commit 2e6aef0

Please sign in to comment.