Sha256: 0938645a1d596aa23ceeb8624b93230d6ab7b0cfee143c133de83443ff01482a

Contents?: true

Size: 544 Bytes

Versions: 6

Compression:

Stored size: 544 Bytes

Contents

People::Engine.routes.draw do

	root to: "users#index"

	<% if !options.active_admin? %>
  scope 'admin' do
	  resources :users
	end
	<% end %>

	scope 'api' do
		scope '1' do
	  	resources :users, controller: 'api/v1/users' do
	  		<% if options.arcadex? %>
				collection do
					# /api/1/users/register
					post 'register', to: "api/v1/users#register"
					# /api/1/users/login
					post 'login', to: "api/v1/users#login"
					# /api/1/users/logout
					get 'logout', to: "api/v1/users#logout"
				end
				<% end %>
	  	end
		end
	end

end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
json_voorhees-0.4.4 lib/generators/json_voorhees/app_make_user/templates/user/user_routes.rb
json_voorhees-0.4.3 lib/generators/json_voorhees/app_make_user/templates/user/user_routes.rb
json_voorhees-0.4.2 lib/generators/json_voorhees/app_make_user/templates/user/user_routes.rb
json_voorhees-0.4.1 lib/generators/json_voorhees/app_make_user/templates/user/user_routes.rb
json_voorhees-0.4.0 lib/generators/json_voorhees/app_make_user/templates/user/user_routes.rb
json_voorhees-0.3.9 lib/generators/json_voorhees/app_make_user/templates/user/user_routes.rb