Django

Code

Show
Ignore:
Timestamp:
08/12/08 09:15:38 (4 months ago)
Author:
gwilson
Message:

Fixed a couple typos in the modeltests' descriptions and made use of ReST inline literal markup for code snippets.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • django/trunk/tests/modeltests/get_object_or_404/models.py

    r6838 r8325  
    2235. DB-API Shortcuts 
    33 
    4 get_object_or_404 is a shortcut function to be used in view functions for 
    5 performing a get() lookup and raising a Http404 exception if a DoesNotExist 
    6 exception was raised during the get() call. 
     4``get_object_or_404()`` is a shortcut function to be used in view functions for 
     5performing a ``get()`` lookup and raising a ``Http404`` exception if a 
     6``DoesNotExist`` exception was raised during the ``get()`` call. 
    77 
    8 get_list_or_404 is a shortcut function to be used in view functions for 
    9 performing a filter() lookup and raising a Http404 exception if a DoesNotExist 
    10 exception was raised during the filter() call. 
     8``get_list_or_404()`` is a shortcut function to be used in view functions for 
     9performing a ``filter()`` lookup and raising a ``Http404`` exception if a 
     10``DoesNotExist`` exception was raised during the ``filter()`` call. 
    1111""" 
    1212 
     
    1717class Author(models.Model): 
    1818    name = models.CharField(max_length=50) 
    19      
     19 
    2020    def __unicode__(self): 
    2121        return self.name 
     
    3030    objects = models.Manager() 
    3131    by_a_sir = ArticleManager() 
    32      
     32 
    3333    def __unicode__(self): 
    3434        return self.title