Sha256: bf34aca084df903e939295b4b4a6c887d2e8ac908098870f312837a99b021661

Contents?: true

Size: 698 Bytes

Versions: 2

Compression:

Stored size: 698 Bytes

Contents

Comable::Core::Engine.routes.draw do
  root to: 'home#show'

  resource :home, only: :show
  resources :products

  resource :cart do
    collection do
      # TODO: post => put
      post :add
      put :checkout
    end
  end

  resource :order, only: [:create] do
    collection do
      get 'signin', as: :signin
      put 'guest', as: :guest
      get ':state', action: :edit, as: :next
      put ':state', action: :update
    end
  end

  resources :pages, only: [:show]

  devise_for :user, path: :member, class_name: Comable::User.name, module: :devise

  resource :user, path: :member do
    member do
      get :addresses
      put :addresses, action: :update_addresses
    end
  end
end

Version data entries

2 entries across 2 versions & 2 rubygems

Version Path
comable-frontend-0.6.0 config/routes.rb
comable_frontend-0.5.0 config/routes.rb