title: Adding more views to a Router or viewset (Django-Rest-Framework)
body: <p>Essentially, I'm trying to find a good way to attach more views to a Router without creating a custom Router. <strong>What's a good way to accomplish this?</strong></p>
  
  <p>Here is something sort of equivalent to what I'm trying to accomplish. Variable names have been changed and the example method I want to introduce is extremely simplified for the sake of this question.</p>
  
  <p>Router:</p>
  
  <pre><code>router = routers.SimpleRouter(trailing_slash=False)
  router.register(r'myobjects', MyObjectViewSet, base_name='myobjects')
  urlpatterns = router.urls
  </code></pre>
  
  <p>ViewSet</p>
  
  <pre><code>class MyObjectsViewSet(viewsets.ViewSet):
  """ Provides API Methods to manage MyObjects. """
  
  def list(self, request):
      """ Returns a list of MyObjects. """
      data = get_list_of_myobjects()
      return Response(data)
  
  def retrieve(self, request, pk):
      """ Returns a single MyObject. """
      data = fetch_my_object(pk)
      return Response(data)
  
  def destroy(self, request, pk):
      """ Deletes a single MyObject. """
      fetch_my_object_and_delete(pk)
              return Response()
  </code></pre>
  
  <p>One example of another method type I need to include. (There are many of these):</p>
  
  <pre><code>def get_locations(self, request):
      """ Returns a list of location objects somehow related to MyObject """
      locations = calculate_something()
      return Response(locations)
  </code></pre>
  
  <p>The end-result is that the following URL would work correctly and be implemented 'cleanly'.</p>
  
  <pre><code>GET example.com/myobjects/123/locations
  </code></pre>