title: Should I define get_absolute_url() if the url is not unique?
body: <p>In the Django framework, models can define a <code>get_absolute_url()</code> method. The method is used to create urls for instances of the model and it is considered a good practice to define and use this method.</p>
  
  <p>Is it still a good practice to define this method even if the generated urls are not unique?</p>
  
  <p>Example:</p>
  
  <pre><code>class Project(models.Model):
      name = models.CharField(max_length=128)
  
      def get_absolute_url(self):
          return reverse('xxx:project_details', args=(self.id,))
  
  
  class Item(models.Model):
      project = models.ForeignKey(Project, on_delete=models.CASCADE)
      name = models.CharField(max_length=128)
  
      def get_absolute_url(self):
          return reverse('xxx:project_details', args=(self.project.id,))
  </code></pre>
  
  <p>Currently, the <code>Item</code> instances can only be seen in a list on the <code>project_details</code> page and I intend to keep it that way. The <code>get_absolute_url()</code> method returns the project details url. This means that all Items of the same project return the same url. Is that okay? I found it useful, because some generic views use <code>get_absolute_url()</code> and automatically redirect to the correct page. However, I am new to Django and want to know whether this will cause problems later.</p>