Django

Code

Changeset 3032

Show
Ignore:
Timestamp:
05/31/06 14:25:57 (3 years ago)
Author:
adrian
Message:

Fixed build_documentation to display the correct import statement

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • djangoproject.com/django_website/apps/docs/parts/build_documentation.py

    r3029 r3032  
    3030<h2 id="sample-usage">Sample API usage</h2> 
    3131<p>This sample code assumes the above model{{ models|pluralize }} {% if models|pluralize %}have{% else %}has{% endif %} 
    32 been saved in a file <tt class="docutils literal"><span class="pre">examplemodel.py</span></tt>. 
    33 <pre class="literal-block">&gt;&gt;&gt; from django.models.examplemodel import {% for model in models %}{{ model.module_name }}{% if not forloop.last %}, {% endif %}{% endfor %} 
     32been saved in a file <tt class="docutils literal"><span class="pre">mysite/models.py</span></tt>. 
     33<pre class="literal-block">&gt;&gt;&gt; from mysite.models import {% for model in models %}{{ model.name }}{% if not forloop.last %}, {% endif %}{% endfor %} 
    3434{{ api_usage }}</pre> 
    3535</div>