Phcmemberspro::Engine.routes.draw do constraints(Mtdevise::Constraints::SubdomainRequired) do # Application Client Backend namespace :members do # Members Main Index root 'mains#index' # Member Routes resources :mains do resources :listings resources :contacts # Auto Complete Routes get :autocomplete_members_contact_mccompanyname, :on => :collection end end namespace :directory do # Directory Main Index root 'categories#index' # Directory Routes resources :categories do resources :catlists end end end mount Mtdevise::Engine, :at => '/' end