per page, with , order by , clip by
Results of 1 - 10 of about 30 for reporter (0.004 sec.)
多対一 (many-to-one) 関係 — Django 6.1 ドキュメント 13321
Django 6.1 ドキュメント Home | Table of contents | Index | Modules « previous | up | next » 多対一 (many-to-one) 関係 ¶ 多対一のリレーションシップを定義するには ForeignKey を使います。 この例では、 Reporter は複数の Article オブジェクトと関 ... 連付けることができますが、 Article は一つの Reporter オブジェクトしか持つことができません: from django.db import models class Reporter ( models . Model ): first_name = models ... } " class Article ( models . Model ): headline = models . CharField ( max_length = 100 ) pub_date = models . DateField () reporter = models . ForeignKey ( Reporter , on_delete = models . CASCADE ) def __str__ ( self ): return self . headline class Meta ... : ordering = [ "headline" ] 以下は、Python API の機能を使って実行できる操作の例です。 複数の Reporter を作成する: >>> r = Reporter ( first_name = "John" , last_name = "Smith" , email = "john@example.com" ) >>> r . save () >> ...
https://man.mtool.work/django/6.1/topics/db/examples/many_to_one.html
多対一 (many-to-one) 関係 — Django 6.1 ドキュメント 13289
Django 6.1 ドキュメント Home | Table of contents | Index | Modules « previous | up | next » 多対一 (many-to-one) 関係 ¶ 多対一のリレーションシップを定義するには ForeignKey を使います。 この例では、 Reporter は複数の Article オブジェクトと関 ... 連付けることができますが、 Article は一つの Reporter オブジェクトしか持つことができません: from django.db import models class Reporter ( models . Model ): first_name = models ... } " class Article ( models . Model ): headline = models . CharField ( max_length = 100 ) pub_date = models . DateField () reporter = models . ForeignKey ( Reporter , on_delete = models . CASCADE ) def __str__ ( self ): return self . headline class Meta ... : ordering = [ "headline" ] 以下は、Python API の機能を使って実行できる操作の例です。 複数の Reporter を作成する: >>> r = Reporter ( first_name = "John" , last_name = "Smith" , email = "john@example.com" ) >>> r . save () >> ...
https://man.mtool.work/django/6.1/topics/db/examples/many_to_one.html
Django の概要 — Django 6.1 ドキュメント 10689
Django 6.1 ドキュメント Home | Table of contents | Index | Modules « previous | up | next » Django の概要 ¶ Django は変転の激しいニュースルーム環境で開発された経緯から、よくある Web 開発タスクを迅速かつ簡単化するように設計されています。ここ ... ーススキーマの問題を解決してきた実績があります。 簡単な例を示しましょう: news/models.py ¶ from django.db import models class Reporter ( models . Model ): full_name = models . CharField ( max_length = 70 ) def __str__ ( self ): return self . full_name class ... del ): pub_date = models . DateField () headline = models . CharField ( max_length = 200 ) content = models . TextField () reporter = models . ForeignKey ( Reporter , on_delete = models . CASCADE ) def __str__ ( self ): return self . headline モデルのイン ... 、コードを作成する必要はありません: # Import the models we created from our "news" app >>> from news.models import Article , Reporter # No reporters are in the system yet. >>> Reporter . objects . all () <QuerySet []> # Create a new Reporter. >>> r = Repor ...
https://man.mtool.work/django/6.1/intro/overview.html
Django の概要 — Django 6.1 ドキュメント 10657
Django 6.1 ドキュメント Home | Table of contents | Index | Modules « previous | up | next » Django の概要 ¶ Django は変転の激しいニュースルーム環境で開発された経緯から、よくある Web 開発タスクを迅速かつ簡単化するように設計されています。ここ ... ーススキーマの問題を解決してきた実績があります。 簡単な例を示しましょう: news/models.py ¶ from django.db import models class Reporter ( models . Model ): full_name = models . CharField ( max_length = 70 ) def __str__ ( self ): return self . full_name class ... del ): pub_date = models . DateField () headline = models . CharField ( max_length = 200 ) content = models . TextField () reporter = models . ForeignKey ( Reporter , on_delete = models . CASCADE ) def __str__ ( self ): return self . headline モデルのイン ... 、コードを作成する必要はありません: # Import the models we created from our "news" app >>> from news.models import Article , Reporter # No reporters are in the system yet. >>> Reporter . objects . all () <QuerySet []> # Create a new Reporter. >>> r = Repor ...
https://man.mtool.work/django/6.1/intro/overview.html
クエリ式 (Query Expression) — Django 6.1 ドキュメント 8285
Django 6.1 ドキュメント Home | Table of contents | Index | Modules « previous | up | next » クエリ式 (Query Expression) ¶ クエリ式 (query expression) は、update、create、filter、order by、annotation、またはaggregateの一部として使用できる値ま ... レベルで必要な操作を記述する SQL 式を生成します。 例でやってみましょう。通常はこのようにします: # Tintin filed a news story! reporter = Reporters . objects . get ( name = "Tintin" ) reporter . stories_filed += 1 reporter . save () ここでは、 reporter.stori ... そのオブジェクトをデータベースに保存しています。しかし、代わりに次のようにすることもできます: from django.db.models import F reporter = Reporters . objects . get ( name = "Tintin" ) reporter . stories_filed = F ( "stories_filed" ) + 1 reporter . save () re ... Djangoが F() インスタンスを見つけると、標準のPython演算子をオーバーライドしてカプセル化されたSQL式を作成します。この場合、 reporter.stories_filed によって表されるデータベースフィールドをインクリメントするようにデータベースに指示する式が作成されます。 rep ...
https://man.mtool.work/django/6.1/ref/models/expressions.html
クエリ式 (Query Expression) — Django 6.1 ドキュメント 8285
Django 6.1 ドキュメント Home | Table of contents | Index | Modules « previous | up | next » クエリ式 (Query Expression) ¶ クエリ式 (query expression) は、update、create、filter、order by、annotation、またはaggregateの一部として使用できる値ま ... レベルで必要な操作を記述する SQL 式を生成します。 例でやってみましょう。通常はこのようにします: # Tintin filed a news story! reporter = Reporters . objects . get ( name = "Tintin" ) reporter . stories_filed += 1 reporter . save () ここでは、 reporter.stori ... そのオブジェクトをデータベースに保存しています。しかし、代わりに次のようにすることもできます: from django.db.models import F reporter = Reporters . objects . get ( name = "Tintin" ) reporter . stories_filed = F ( "stories_filed" ) + 1 reporter . save () re ... Djangoが F() インスタンスを見つけると、標準のPython演算子をオーバーライドしてカプセル化されたSQL式を作成します。この場合、 reporter.stories_filed によって表されるデータベースフィールドをインクリメントするようにデータベースに指示する式が作成されます。 rep ...
https://man.mtool.work/django/6.1/ref/models/expressions.html
エラーレポートの管理 — Django 6.1 ドキュメント 8188
Django 6.1 ドキュメント Home | Table of contents | Index | Modules « previous | up | next » エラーレポートの管理 ¶ サイトを公開している場合、 DEBUG 設定は常にオフにしておかなければなりません。これにより、サーバー動作は高速になり、エラーペー ... アノテートするだけです。実際のフィルタリングは Django のデフォルトのエラーレポートフィルタ ( django.views.debug.SafeExceptionReporterFilter ) で行われます。このフィルタはデコレータのアノテーションを使い、エラーレポートが生成される際に、対応する値をアスタリ ... 。このデフォルトの動作を上書きしたり、サイト全体でカスタマイズしたい場合は、独自のフィルタクラスを定義し、 DEFAULT_EXCEPTION_REPORTER_FILTER 設定でそれを使うように Django に指示する必要があります: DEFAULT_EXCEPTION_REPORTER_FILTER = "path.to.your.CustomExc ... eptionReporterFilter" また、 HttpRequest の exception_reporter_filter 属性を指定することで、任意のビューで使用するフィルタをより細かく制御 ...
https://man.mtool.work/django/6.1/howto/error-reporting.html
エラーレポートの管理 — Django 6.1 ドキュメント 8188
Django 6.1 ドキュメント Home | Table of contents | Index | Modules « previous | up | next » エラーレポートの管理 ¶ サイトを公開している場合、 DEBUG 設定は常にオフにしておかなければなりません。これにより、サーバー動作は高速になり、エラーペー ... アノテートするだけです。実際のフィルタリングは Django のデフォルトのエラーレポートフィルタ ( django.views.debug.SafeExceptionReporterFilter ) で行われます。このフィルタはデコレータのアノテーションを使い、エラーレポートが生成される際に、対応する値をアスタリ ... 。このデフォルトの動作を上書きしたり、サイト全体でカスタマイズしたい場合は、独自のフィルタクラスを定義し、 DEFAULT_EXCEPTION_REPORTER_FILTER 設定でそれを使うように Django に指示する必要があります: DEFAULT_EXCEPTION_REPORTER_FILTER = "path.to.your.CustomExc ... eptionReporterFilter" また、 HttpRequest の exception_reporter_filter 属性を指定することで、任意のビューで使用するフィルタをより細かく制御 ...
https://man.mtool.work/django/6.1/howto/error-reporting.html
ロギング — Django 6.1 ドキュメント 7619
Django 6.1 ドキュメント Home | Table of contents | Index | Modules « previous | up | next » ロギング ¶ 参考 ロギングの設定と利用 Django のロギングの概要 Django の logging モジュールは Python の 組み込み logging モジュールを継承しています。 ... るもの に加えて、1つのログハンドラを提供しています。 class AdminEmailHandler ( include_html = False , email_backend = None , reporter_class = None , using = None ) [ソース] ¶ このハンドラは、受け取ったログメッセージごとにサイトの ADMINS に電子メールを送信し ... idden. email_backend is not supported when MAILERS is defined or when the using argument is provided. AdminEmailHandler の reporter_class 引数では、メール本文で送信されるトレースバックテキストをカスタマイズするために django.views.debug.ExceptionReporter ... dlers" : { "mail_admins" : { "level" : "ERROR" , "class" : "django.utils.log.AdminEmailHandler" , "include_html" : True , "reporter_class" : "somepackage.error_reporter.CustomErrorReporter" , }, } Changed in Django 6.1: using 引数が追加されました。 バージ ...
https://man.mtool.work/django/6.1/ref/logging.html
ロギング — Django 6.1 ドキュメント 7619
Django 6.1 ドキュメント Home | Table of contents | Index | Modules « previous | up | next » ロギング ¶ 参考 ロギングの設定と利用 Django のロギングの概要 Django の logging モジュールは Python の 組み込み logging モジュールを継承しています。 ... るもの に加えて、1つのログハンドラを提供しています。 class AdminEmailHandler ( include_html = False , email_backend = None , reporter_class = None , using = None ) [ソース] ¶ このハンドラは、受け取ったログメッセージごとにサイトの ADMINS に電子メールを送信し ... idden. email_backend is not supported when MAILERS is defined or when the using argument is provided. AdminEmailHandler の reporter_class 引数では、メール本文で送信されるトレースバックテキストをカスタマイズするために django.views.debug.ExceptionReporter ... dlers" : { "mail_admins" : { "level" : "ERROR" , "class" : "django.utils.log.AdminEmailHandler" , "include_html" : True , "reporter_class" : "somepackage.error_reporter.CustomErrorReporter" , }, } Changed in Django 6.1: using 引数が追加されました。 バージ ...
https://man.mtool.work/django/6.1/ref/logging.html
PREV 1 2 3 NEXT