Django

Code

Changeset 3648

Show
Ignore:
Timestamp:
08/22/06 11:46:32 (2 years ago)
Author:
adrian
Message:

[multi-db] Merged to [3646]

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • django/branches/multiple-db-support/django/contrib/admin/media/css/global.css

    r3427 r3648  
    1 body { margin:0; padding:0; font-size:12px; font-family:"Lucida Grande","Bitstream Vera Sans",Verdana,Arial,sans-serif; color:#333; background:#fff; } 
     1body { margin:0; padding:0; font-size:12px; font-family:"Lucida Grande","DejaVu Sans","Bitstream Vera Sans",Verdana,Arial,sans-serif; color:#333; background:#fff; } 
    22 
    33/* LINKS */ 
  • django/branches/multiple-db-support/django/contrib/admin/templates/admin_doc/model_detail.html

    r3355 r3648  
    3636    <td>{{ field.name }}</td> 
    3737    <td>{{ field.data_type }}</td> 
    38     <td>{% if field.verbose %}{{ field.verbose|escape }}{% endif %}{% if field.help_text %} - {{ field.help_text|escape }}{% endif %}</td> 
     38    <td>{% if field.verbose %}{{ field.verbose }}{% endif %}{% if field.help_text %} - {{ field.help_text }}{% endif %}</td> 
    3939</tr> 
    4040{% endfor %} 
  • django/branches/multiple-db-support/django/core/validators.py

    r3355 r3648  
    6969def isSlug(field_data, all_data): 
    7070    if not slug_re.search(field_data): 
    71         raise ValidationError, "This value must contain only letters, numbers, underscores or hyphens." 
     71        raise ValidationError, gettext("This value must contain only letters, numbers, underscores or hyphens.") 
    7272 
    7373def isLowerCase(field_data, all_data): 
  • django/branches/multiple-db-support/django/views/generic/date_based.py

    r3502 r3648  
    22from django.core.exceptions import ObjectDoesNotExist 
    33from django.core.xheaders import populate_xheaders 
     4from django.db.models.fields import DateTimeField 
    45from django.http import Http404, HttpResponse 
    56import datetime, time 
     
    236237    now = datetime.datetime.now() 
    237238 
    238     lookup_kwargs = { 
    239         '%s__range' % date_field: (datetime.datetime.combine(date, datetime.time.min), datetime.datetime.combine(date, datetime.time.max)), 
    240     } 
     239    if isinstance(model._meta.get_field(date_field), DateTimeField): 
     240        lookup_kwargs = {'%s__range' % date_field: (datetime.datetime.combine(date, datetime.time.min), datetime.datetime.combine(date, datetime.time.max))} 
     241    else: 
     242        lookup_kwargs = {date_field: date} 
    241243 
    242244    # Only bother to check current date if the date isn't in the past and future objects aren't requested. 
     
    305307    now = datetime.datetime.now() 
    306308 
    307     lookup_kwargs = { 
    308         '%s__range' % date_field: (datetime.datetime.combine(date, datetime.time.min), datetime.datetime.combine(date, datetime.time.max)), 
    309     } 
     309    if isinstance(model._meta.get_field(date_field), DateTimeField): 
     310        lookup_kwargs = {'%s__range' % date_field: (datetime.datetime.combine(date, datetime.time.min), datetime.datetime.combine(date, datetime.time.max))} 
     311    else: 
     312        lookup_kwargs = {date_field: date} 
    310313 
    311314    # Only bother to check current date if the date isn't in the past and future objects aren't requested. 
  • django/branches/multiple-db-support/docs/settings.txt

    r3581 r3648  
    474474 
    475475    LANGUAGES = ( 
     476        ('ar', _('Arabic')), 
    476477        ('bn', _('Bengali')), 
    477478        ('cs', _('Czech')), 
     
    479480        ('da', _('Danish')), 
    480481        ('de', _('German')), 
     482        ('el', _('Greek')), 
    481483        ('en', _('English')), 
    482484        ('es', _('Spanish')), 
     485        ('es_AR', _('Argentinean Spanish')), 
    483486        ('fr', _('French')), 
    484487        ('gl', _('Galician')), 
     488        ('hu', _('Hungarian')), 
     489        ('he', _('Hebrew')), 
    485490        ('is', _('Icelandic')), 
    486491        ('it', _('Italian')), 
     492        ('ja', _('Japanese')), 
     493        ('nl', _('Dutch')), 
    487494        ('no', _('Norwegian')), 
    488495        ('pt-br', _('Brazilian')), 
     
    490497        ('ru', _('Russian')), 
    491498        ('sk', _('Slovak')), 
     499        ('sl', _('Slovenian')), 
    492500        ('sr', _('Serbian')), 
    493501        ('sv', _('Swedish')), 
     502        ('ta', _('Tamil')), 
     503        ('uk', _('Ukrainian')), 
    494504        ('zh-cn', _('Simplified Chinese')), 
     505        ('zh-tw', _('Traditional Chinese')), 
    495506    ) 
    496507 
  • django/branches/multiple-db-support/docs/templates.txt

    r3502 r3648  
    142142        </div> 
    143143    </body> 
     144    </html> 
    144145 
    145146This template, which we'll call ``base.html``, defines a simple HTML skeleton 
     
    197198        </div> 
    198199    </body> 
     200    </html> 
    199201 
    200202Note that since the child template didn't define the ``sidebar`` block, the 
     
    364366Signal that this template extends a parent template. 
    365367 
    366 This tag can be used in two ways:  
     368This tag can be used in two ways: 
    367369 
    368370   * ``{% extends "base.html" %}`` (with quotes) uses the literal value 
     
    962964~~~~~~~~~ 
    963965 
    964 Returns a plural suffix if the value is not 1. By default, this suffix is ``'s'``.  
     966Returns a plural suffix if the value is not 1. By default, this suffix is ``'s'``. 
    965967 
    966968Example:: 
     
    968970    You have {{ num_messages }} message{{ num_messages|pluralize }}. 
    969971 
    970 For words that require a suffix other than ``'s'``, you can provide an alternate  
     972For words that require a suffix other than ``'s'``, you can provide an alternate 
    971973suffix as a parameter to the filter. 
    972974