Django for Designers/Adding models: Difference between revisions
Content added Content deleted
imported>Aldeka |
imported>Aldeka |
||
Line 568: | Line 568: | ||
>>> from bookmarks.models import Bookmark, Tag |
>>> from bookmarks.models import Bookmark, Tag |
||
>>> import random |
>>> import random |
||
>>> tag_names = ['kids', 'read_on_plane', ' |
>>> tag_names = ['kids', 'read_on_plane', 'send_to_dad'] |
||
>>> # Create the Tag objects |
>>> # Create the Tag objects |
||
>>> for tag_name in tag_names: |
>>> for tag_name in tag_names: |