mirror of
https://github.com/openfoodfoundation/openfoodnetwork
synced 2026-03-03 02:21:33 +00:00
25 lines
387 B
Ruby
25 lines
387 B
Ruby
class Shop::CheckoutController < BaseController
|
|
layout 'darkswarm'
|
|
|
|
before_filter :set_distributor
|
|
before_filter :require_order_cycle
|
|
|
|
def new
|
|
|
|
end
|
|
|
|
private
|
|
|
|
def set_distributor
|
|
unless @distributor = current_distributor
|
|
redirect_to root_path
|
|
end
|
|
end
|
|
|
|
def require_order_cycle
|
|
unless current_order_cycle
|
|
redirect_to shop_path
|
|
end
|
|
end
|
|
end
|