per page, with , order by , clip by
Results of 1 - 10 of about 80 for choices (0.009 sec.)
モデルフィールドリファレンス — Django 6.1 ドキュメント 12273
Django 6.1 ドキュメント Home | Table of contents | Index | Modules « previous | up | next » モデルフィールドリファレンス ¶ このドキュメントには、Django が提供するフィールドオプション field options とフィールド型 field types を含む、 Field の ... ue は null=False のフィールドでも使用できますが、この場合、 clean() を実装し、欠損値をプログラムで補完する必要があります。 choices ¶ Field. choices [ソース] ¶ このフィールドの選択肢として使用するための、以下で説明する形式のマッピングまたはイテラブルです ... 。choices が指定された場合、 モデルのバリデーション によって強制的に、デフォルトのフォームウィジェットが通常のテキストフィールドの代 ... マッピングが指定された場合、キー要素はモデルに設定される実際の値で、2番目の要素は人間が読める名前です。例えば YEAR_IN_SCHOOL_CHOICES = { "FR" : "Freshman" , "SO" : "Sophomore" , "JR" : "Junior" , "SR" : "Senior" , "GR" : "Graduate" , } また、 sequence とし ...
https://man.mtool.work/django/6.1/ref/models/fields.html
モデルフィールドリファレンス — Django 6.1 ドキュメント 12273
Django 6.1 ドキュメント Home | Table of contents | Index | Modules « previous | up | next » モデルフィールドリファレンス ¶ このドキュメントには、Django が提供するフィールドオプション field options とフィールド型 field types を含む、 Field の ... ue は null=False のフィールドでも使用できますが、この場合、 clean() を実装し、欠損値をプログラムで補完する必要があります。 choices ¶ Field. choices [ソース] ¶ このフィールドの選択肢として使用するための、以下で説明する形式のマッピングまたはイテラブルです ... 。choices が指定された場合、 モデルのバリデーション によって強制的に、デフォルトのフォームウィジェットが通常のテキストフィールドの代 ... マッピングが指定された場合、キー要素はモデルに設定される実際の値で、2番目の要素は人間が読める名前です。例えば YEAR_IN_SCHOOL_CHOICES = { "FR" : "Freshman" , "SO" : "Sophomore" , "JR" : "Junior" , "SR" : "Senior" , "GR" : "Graduate" , } また、 sequence とし ...
https://man.mtool.work/django/6.1/ref/models/fields.html
Django 5.0 リリースノート — Django 6.1 ドキュメント 11807
Django 6.1 ドキュメント Home | Table of contents | Index | Modules « previous | up | next » Django 5.0 リリースノート ¶ 2023年12月4日 Django 5.0 へようこそ! このリリースノートでは、 バージョン 5.0 の新機能 と、Django 4.2 以前からアップグレー ... output_field = models . BigIntegerField (), db_persist = True , ) フィールドの選択肢を宣言する際のオプションが増加 ¶ Field.choices (モデルフィールド用) と ChoiceField.choices (フォームフィールド用) により、値を宣言する際の柔軟性が向上しました。以前のバー ... ジョンの Django では、 choices は 2 タプルのリストか、 列挙型 のサブクラスである必要がありましたが、後者の場合、 .choices 属性にアクセスして、期待される形 ... 式で値を提供する必要がありました: from django.db import models Medal = models . TextChoices ( "Medal" , "GOLD SILVER BRONZE" ) SPORT_CHOICES = [ ( "Martial Arts" , [( "judo" , "Judo" ), ( "karate" , "Karate" )]), ( ...
https://man.mtool.work/django/6.1/releases/5.0.html
Django 5.0 リリースノート — Django 6.1 ドキュメント 11807
Django 6.1 ドキュメント Home | Table of contents | Index | Modules « previous | up | next » Django 5.0 リリースノート ¶ 2023年12月4日 Django 5.0 へようこそ! このリリースノートでは、 バージョン 5.0 の新機能 と、Django 4.2 以前からアップグレー ... output_field = models . BigIntegerField (), db_persist = True , ) フィールドの選択肢を宣言する際のオプションが増加 ¶ Field.choices (モデルフィールド用) と ChoiceField.choices (フォームフィールド用) により、値を宣言する際の柔軟性が向上しました。以前のバー ... ジョンの Django では、 choices は 2 タプルのリストか、 列挙型 のサブクラスである必要がありましたが、後者の場合、 .choices 属性にアクセスして、期待される形 ... 式で値を提供する必要がありました: from django.db import models Medal = models . TextChoices ( "Medal" , "GOLD SILVER BRONZE" ) SPORT_CHOICES = [ ( "Martial Arts" , [( "judo" , "Judo" ), ( "karate" , "Karate" )]), ( ...
https://man.mtool.work/django/6.1/releases/5.0.html
フォーム フィールド — Django 6.1 ドキュメント 8410
Django 6.1 ドキュメント Home | Table of contents | Index | Modules « previous | up | next » フォーム フィールド ¶ class Field [ソース] ¶ Form クラスを作成時の一番重要な部分は、form のフィールド (field) の定義です。各フィールドにはカスタムの ... エラーメッセージには %(value)s が含まれていることがあり、選択された選択肢に置き換えられます。 1つの追加引数を受け取ります: choices [ソース] ¶ このフィールドの選択肢として使用する2値タプルの iterable 、 列挙型 、またはそのようなイテラブルを返す呼び出し可 ... 能オブジェクトのいずれか。この引数は、モデルフィールドの choices 引数と同じ形式を受け入れます。詳細については、 モデルフィールドのリファレンスドキュメント を参照してください。引数が呼び出 ... ecified location should be included. Either this or allow_files must be True . FilePathField has the following method: set_choices () [ソース] ¶ New in Django 6.1. Scans the directory at path and refreshes the field's choices. This is called automatical ...
https://man.mtool.work/django/6.1/ref/forms/fields.html
フォーム フィールド — Django 6.1 ドキュメント 8410
Django 6.1 ドキュメント Home | Table of contents | Index | Modules « previous | up | next » フォーム フィールド ¶ class Field [ソース] ¶ Form クラスを作成時の一番重要な部分は、form のフィールド (field) の定義です。各フィールドにはカスタムの ... エラーメッセージには %(value)s が含まれていることがあり、選択された選択肢に置き換えられます。 1つの追加引数を受け取ります: choices [ソース] ¶ このフィールドの選択肢として使用する2値タプルの iterable 、 列挙型 、またはそのようなイテラブルを返す呼び出し可 ... 能オブジェクトのいずれか。この引数は、モデルフィールドの choices 引数と同じ形式を受け入れます。詳細については、 モデルフィールドのリファレンスドキュメント を参照してください。引数が呼び出 ... ecified location should be included. Either this or allow_files must be True . FilePathField has the following method: set_choices () [ソース] ¶ New in Django 6.1. Scans the directory at path and refreshes the field's choices. This is called automatical ...
https://man.mtool.work/django/6.1/ref/forms/fields.html
ウィジェット — Django 6.1 ドキュメント 8410
Django 6.1 ドキュメント Home | Table of contents | Index | Modules « previous | up | next » ウィジェット ¶ ウィジェットは、Django が HTML の input 要素の表現方法です。ウィジェットは、HTML のレンダリングをコントロールして、ウィジェットに合致 ... 際にセットできます。以下の例では、 SelectDateWidget に対して years 属性がセットされます: from django import forms BIRTH_YEAR_CHOICES = [ "1980" , "1981" , "1982" ] FAVORITE_COLORS_CHOICES = { "blue" : "Blue" , "green" : "Green" , "black" : "Black" , } cla ... ss SimpleForm ( forms . Form ): birth_year = forms . DateField ( widget = forms . SelectDateWidget ( years = BIRTH_YEAR_CHOICES ) ) favorite_colors = forms . MultipleChoiceField ( required = False , widget = forms . CheckboxSelectMultiple , choices = ... FAVORITE_COLORS_CHOICES , ) 使用可能なウィジェットとそれぞれの引数の詳細については、 ビルトインのウィジェット を参照してください。 ウィジェットのイ ...
https://man.mtool.work/django/6.1/ref/forms/widgets.html
ウィジェット — Django 6.1 ドキュメント 8287
Django 6.1 ドキュメント Home | Table of contents | Index | Modules « previous | up | next » ウィジェット ¶ ウィジェットは、Django が HTML の input 要素の表現方法です。ウィジェットは、HTML のレンダリングをコントロールして、ウィジェットに合致 ... 際にセットできます。以下の例では、 SelectDateWidget に対して years 属性がセットされます: from django import forms BIRTH_YEAR_CHOICES = [ "1980" , "1981" , "1982" ] FAVORITE_COLORS_CHOICES = { "blue" : "Blue" , "green" : "Green" , "black" : "Black" , } cla ... ss SimpleForm ( forms . Form ): birth_year = forms . DateField ( widget = forms . SelectDateWidget ( years = BIRTH_YEAR_CHOICES ) ) favorite_colors = forms . MultipleChoiceField ( required = False , widget = forms . CheckboxSelectMultiple , choices = ... FAVORITE_COLORS_CHOICES , ) 使用可能なウィジェットとそれぞれの引数の詳細については、 ビルトインのウィジェット を参照してください。 ウィジェットのイ ...
https://man.mtool.work/django/6.1/ref/forms/widgets.html
Django 6.1 release notes — Django 6.1 ドキュメント 7944
Django 6.1 ドキュメント Home | Table of contents | Index | Modules « previous | up | next » Django 6.1 release notes ¶ August 5, 2026 Welcome to Django 6.1! These release notes cover the new features , as well as some backwards incompatible ... ng to the admin index page. The admin's FilteredSelectMultiple widget now uses <optgroup> s to preserve named groups (e.g. choices=[("Group", [("1", "Item")]), ...] ). When ModelAdmin.list_select_related is False (the default), the change list now selec ... CE_LABEL defines a more accessible and translatable default label for the blank choice in forms, which is appended to most choices lists. The transitional setting USE_BLANK_CHOICE_DASH allows you to revert back to the old default label. FilePathField no ... w provides a set_choices() method to scan the directory at path and refresh the field's choices. This allows per-request refreshing when called in ...
https://man.mtool.work/django/6.1/releases/6.1.html
Django 6.1 release notes — Django 6.1 ドキュメント 7944
Django 6.1 ドキュメント Home | Table of contents | Index | Modules « previous | up | next » Django 6.1 release notes ¶ August 5, 2026 Welcome to Django 6.1! These release notes cover the new features , as well as some backwards incompatible ... ng to the admin index page. The admin's FilteredSelectMultiple widget now uses <optgroup> s to preserve named groups (e.g. choices=[("Group", [("1", "Item")]), ...] ). When ModelAdmin.list_select_related is False (the default), the change list now selec ... CE_LABEL defines a more accessible and translatable default label for the blank choice in forms, which is appended to most choices lists. The transitional setting USE_BLANK_CHOICE_DASH allows you to revert back to the old default label. FilePathField no ... w provides a set_choices() method to scan the directory at path and refresh the field's choices. This allows per-request refreshing when called in ...
https://man.mtool.work/django/6.1/releases/6.1.html
PREV 1 2 3 4 5 6 7 8 NEXT