Sha256: e6ed7baa7e96ea9ceca7dded662f52b8dde436ebf3d6927d9f7b9e2c3cc37374

Contents?: true

Size: 484 Bytes

Versions: 1

Compression:

Stored size: 484 Bytes

Contents

Bodega::Engine.routes.draw do
  # Building orders
  get '', as: :root, to: 'orders#new'
  post '', to: 'orders#create'

  # Add products to an order
  post :add, to: 'orders#add'
  get 'remove/:product_id', as: :remove, constraints: {product_id: /.+\.\d+/}, to: 'orders#remove'

  # Processing orders
  get  :complete, to: 'orders#complete'
  post :complete, to: 'orders#complete'

  # Existing orders
  get  ':id', as: :order, to: 'orders#show'
  post ':id', to: 'orders#update'
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
bodega-0.3.0 config/routes.rb