Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(18)  |  Call(14)  |  Derive(0)  |  Import(4)

src/d/j/django-cached-modelforms-0.2.1/cached_modelforms/tests/test_fields.py   django-cached-modelforms(Download)
from cached_modelforms.tests.utils import SettingsTestCase
from cached_modelforms.tests.models import SimpleModel
from cached_modelforms import (CachedModelChoiceField,
                               CachedModelMultipleChoiceField)
 
        class FormMultiple(forms.Form):
            obj = CachedModelMultipleChoiceField(
                objects=lambda:self.cached_list,
                required=False
            )
        '''
        as_list = CachedModelMultipleChoiceField(
            objects=lambda:self.cached_list
        )
        as_iterable = CachedModelMultipleChoiceField(
            objects=lambda:iter(self.cached_list)
        )
        list_of_tuples = [(x.pk, x) for x in self.cached_list]
        as_list_of_tuples = CachedModelMultipleChoiceField(
            objects=lambda:list_of_tuples

src/d/j/django-cached-modelforms-HEAD/cached_modelforms/tests/test_fields.py   django-cached-modelforms(Download)
from cached_modelforms.tests.utils import SettingsTestCase
from cached_modelforms.tests.models import SimpleModel
from cached_modelforms import (CachedModelChoiceField,
                               CachedModelMultipleChoiceField)
 
        class FormMultiple(forms.Form):
            obj = CachedModelMultipleChoiceField(
                objects=lambda:self.cached_list,
                required=False
            )
        '''
        as_list = CachedModelMultipleChoiceField(
            objects=lambda:self.cached_list
        )
        as_iterable = CachedModelMultipleChoiceField(
            objects=lambda:iter(self.cached_list)
        )
        list_of_tuples = [(x.pk, x) for x in self.cached_list]
        as_list_of_tuples = CachedModelMultipleChoiceField(
            objects=lambda:list_of_tuples

src/d/j/django-cached-modelforms-HEAD/cached_modelforms/tests/test_forms.py   django-cached-modelforms(Download)
from django.db.models import CharField
 
from cached_modelforms import (ModelForm, CachedModelChoiceField,
                               CachedModelMultipleChoiceField)
from cached_modelforms.tests.utils import SettingsTestCase

src/d/j/django-cached-modelforms-0.2.1/cached_modelforms/tests/test_forms.py   django-cached-modelforms(Download)
from django.db.models import CharField
 
from cached_modelforms import (ModelForm, CachedModelChoiceField,
                               CachedModelMultipleChoiceField)
from cached_modelforms.tests.utils import SettingsTestCase