Results of 11 - 20 of about 44 for choices (0.101 sec.)
- Admin actions — Django 4.0.6 ドキュメント 7653
- " + tagname + " "); } }); $("div.highlight\\-html\\+django span.nf").each(function(i, elem) { va
...
Article model: from django.db import models STATUS_CHOICES = [ ( 'd' , 'Draft' ), ( 'p' , 'Published' ), ( 'w ...
() status = models . CharField ( max_length = 1 , choices = STATUS_CHOICES ) def __str__ ( self ): return se ...
-
https://man.plustar.jp/django/ref/contrib/admin/actions.html
- [similar]
- マネージャ — Django 4.0.6 ドキュメント 7653
- " + tagname + " "); } }); $("div.highlight\\-html\\+django span.nf").each(function(i, elem) { va
...
50 ) role = models . CharField ( max_length = 1 , choices = [( 'A' , _ ( 'Author' )), ( 'E' , _ ( 'Editor' ) ...
r(question__name__startswith='What') would include choices related to deleted questions. Don't filter away an ...
50 ) role = models . CharField ( max_length = 1 , choices = [( 'A' , _ ( 'Author' )), ( 'E' , _ ( 'Editor' ) ...
-
https://man.plustar.jp/django/topics/db/managers.html
- [similar]
- Django 1.8 リリースノート — Django 4.0.6 ドキュメント 7576
- " + tagname + " "); } }); $("div.highlight\\-html\\+django span.nf").each(function(i, elem) { va
...
in ModelAdmin.list_filter to limit the list_filter choices to foreign objects which are attached to those fro ...
an now pass a callable that returns an iterable of choices when instantiating a ChoiceField . ジェネリックビュ ...
in Django 1.10. Use showmigrations instead. cache_choices option of ModelChoiceField and ModelMultipleChoice ...
eField took an undocumented, untested option cache_choices . This cached querysets between multiple rendering ...
-
https://man.plustar.jp/django/releases/1.8.html
- [similar]
- Django 2.2.5 リリースノート — Django 4.0.6 ドキュメント 7576
- " + tagname + " "); } }); $("div.highlight\\-html\\+django span.nf").each(function(i, elem) { va
...
ression in Django 2.2 where ModelAdmin.list_filter choices to foreign objects don't respect a model's Meta.or ...
-
https://man.plustar.jp/django/releases/2.2.5.html
- [similar]
- How to create custom model fields — Django 4.0.6 ドキュメント 7499
- " + tagname + " "); } }); $("div.highlight\\-html\\+django span.nf").each(function(i, elem) { va
...
。 unique_for_date unique_for_month unique_for_year choices help_text db_column もしバックエンドが tablespaces ...
ield class can be specified via the form_class and choices_form_class arguments; the latter is used if the fi ...
eld has choices specified, the former otherwise. If these argument ...
et up a good default for the form_class (and maybe choices_form_class ) argument and then delegate further ha ...
-
https://man.plustar.jp/django/howto/custom-model-fields.html
- [similar]
- Coding style — Django 4.0.6 ドキュメント 7407
- " + tagname + " "); } }); $("div.highlight\\-html\\+django span.nf").each(function(i, elem) { va
...
ave() def get_absolute_url() Any custom methods If choices is defined for a given model field, define each ch ...
DIRECTION_UP = 'U' DIRECTION_DOWN = 'D' DIRECTION_CHOICES = [ ( DIRECTION_UP , 'Up' ), ( DIRECTION_DOWN , 'D ...
-
https://man.plustar.jp/django/internals/contributing/writing-code/coding-style.h...
- [similar]
- はじめての Django アプリ作成、その 5 — Django 4.0.6 ドキュメント 7407
- " + tagname + " "); } }); $("div.highlight\\-html\\+django span.nf").each(function(i, elem) { va
...
ように他の方法でアプリを改善できるでしょう。例えば、 Choices を一つも持たない馬鹿げた Questions が公開可能になっ ...
Questions を排除するようビューでチェックできます。 Choices がない Question を作成し、それが公開されないことを ...
テストし、同じようにして、 Choices がある Question を作成し、それが公開 される ことを ...
のアップデートが必要になることがあります。たとえば、 Choices を持つ Questions だけを公開するようにビューを修正し ...
-
https://man.plustar.jp/django/intro/tutorial05.html
- [similar]
- Django 1.10 リリースノート — Django 4.0.6 ドキュメント 7407
- " + tagname + " "); } }); $("div.highlight\\-html\\+django span.nf").each(function(i, elem) { va
...
ject's change form. Added "No date" and "Has date" choices for DateFieldListFilter if the field is nullable. ...
nonexistent template_name is specified. The unused choices keyword argument of the Select and SelectMultiple ...
widgets' render() method is removed. The choices argument of the render_options() method is also re ...
moved, making selected_choices the first argument. Tests that violate deferrable ...
-
https://man.plustar.jp/django/releases/1.10.html
- [similar]
- Django の admin サイト — Django 4.0.6 ドキュメント 7330
- " + tagname + " "); } }); $("div.highlight\\-html\\+django span.nf").each(function(i, elem) { va
...
min. radio_fields ¶ デフォルトでは、 ForeignKey や choices がセットされたフィールドに対して、Django の admin ...
ちらを使用するか選択してください。 ForeignKey ないし choices がセットされたフィールド以外は、 radio_fields に含 ...
args ): if db_field . name == "status" : kwargs [ 'choices' ] = ( ( 'accepted' , 'Accepted' ), ( 'denied' , ' ...
), ) if request . user . is_superuser : kwargs [ 'choices' ] += (( 'ready' , 'Ready for deployment' ),) retu ...
-
https://man.plustar.jp/django/ref/contrib/admin/index.html
- [similar]
- QuerySet API リファレンス — Django 4.0.6 ドキュメント 7330
- " + tagname + " "); } }); $("div.highlight\\-html\\+django span.nf").each(function(i, elem) { va
...
cing the number of queries even further: >>> voted_choices = Choice . objects . filter ( votes__gt = 0 ) >>> ...
voted_choices <QuerySet [<Choice: The sky>]> >>> prefetch = Pref ...
etch ( 'choice_set' , queryset = voted_choices ) >>> Question . objects . prefetch_related ( pref ...
fetch = Prefetch ( 'choice_set' , queryset = voted_choices , to_attr = 'voted_choices' ) >>> Question . objec ...
-
https://man.plustar.jp/django/ref/models/querysets.html
- [similar]