title: Rails routes: GET method redirecting to show method
body: <p>I have simple controller and routes file. 
  In my route and controller i have created a module. I wrote a simple method which is redirecting me show. I am not sure why.</p>
  
  <p><strong>Controller</strong> </p>
  
  <pre><code>  module Seller
      class CampaignsController &lt; Seller::BaseController
  
        before_action :confirm_logged_in
  
        def viewAllCampaigns
         @campaigns = Campaign.all
  
        end
  
        def show
        end
  
      end
  
    end
  </code></pre>
  
  <p><strong>Routes file</strong></p>
  
  <pre><code> scope module: 'seller' do
     #namespace :power do
     resources :dashboard, only: [:index]
     resources :sessions, only: [:create, :destroy]
     resources :campaigns, only: [:index, :create, :show, :update, :destroy]   
     get 'viewAllCampaigns' =&gt; 'campaigns#viewAllCampaigns'   
   end
  </code></pre>
  
  <p><strong>Output</strong></p>
  
  <pre><code>Started GET "/campaigns/viewAllCampaigns" for 127.0.0.1 at 2015-10-12 17:39:43 +0500
    Processing by Seller::CampaignsController#show as HTML
    Parameters: {"id"=&gt;"viewAllCampaigns"}
    Rendered seller/campaigns/show.html.erb (0.1ms)
  </code></pre>
  
  <p>I am hitting <a href="http://localhost:3000/campaigns/viewAllCampaigns" rel="nofollow">http://localhost:3000/campaigns/viewAllCampaigns</a> in browser.</p>