title: How to add DELETE method inside 'do' keyword in config/routes.rb?
body: <p>I know I can add a new DELETE method on <a href="http://localhost:3000/students" rel="nofollow noreferrer">http://localhost:3000/students</a> by editing config/routes.rb:</p>
  
  <pre><code>resources :students
  delete '/students',:to =&gt; 'students#destroymany'
  </code></pre>
  
  <p>Note: it is different from DELETE <a href="http://localhost:3000/students/1" rel="nofollow noreferrer">http://localhost:3000/students/1</a> because  the default DELETE supports deleting 1 student only, while I also want to support DELETE on <a href="http://localhost:3000/students/" rel="nofollow noreferrer">http://localhost:3000/students/</a> (without specific student id)</p>
  
  <p>but it has a disadvantage: I need to repeat typing 'students'. Is there any syntax that changes the routing statement to become</p>
  
  <pre><code>resources :students do
      xxx
  end
  </code></pre>
  
  <p>but have the same effect as the beginning version? I tried:</p>
  
  <pre><code>resources :students do
    delete '',:to =&gt; 'students#destroymany'
  end
  </code></pre>
  
  <p>but the error occurs:</p>
  
  <pre><code>No route matches [DELETE] "/students"
  </code></pre>
  
  <p>because it adds the routing to </p>
  
  <pre><code>/students/:student_id
  </code></pre>
  
  <p>instead of </p>
  
  <pre><code>/students
  </code></pre>