per page, with , order by , clip by
Results of 1 - 10 of about 24 for today (0.009 sec.)
条件式 15996
条件式 Conditional expressions let you use if ... elif ... else logic within filters, annotations, aggregations, and updates. A conditional expression evaluates a series of conditions for each row of a table and returns the matching result ... n >>> Client . objects . create ( ... name = "Jane Doe" , ... account_type = Client . REGULAR , ... registered_on = date . today () - timedelta ( days = 36 ), ... ) >>> Client . objects . create ( ... name = "James Smith" , ... account_type = Client . ... GOLD , ... registered_on = date . today () - timedelta ( days = 5 ), ... ) >>> Client . objects . create ( ... name = "Jack Black" , ... account_type = Client . P ... LATINUM , ... registered_on = date . today () - timedelta ( days = 10 * 365 ), ... ) >>> # Get the discount for each Client based on the account type >>> Client . ob ...
https://man.mtool.work/django/6.1/ref/models/conditional-expressions.html
django.contrib.humanize 9224
django.contrib.humanize humanize は、データに「人間くささ(human touch)」を与えるための Django テンプレートフィルタセットです。 これらのフィルタを有効にするには、 INSTALLED_APPS 設定に 'django.contrib.humanize' を加えます。インストール後、 ... -1200000000 は '-1,2 Milliarden' になります。 naturalday 日付が今日、明日、昨日のいずれかに該当する場合、それぞれ「今日(“today”)」、 「明日(“tomorrow”)」、「昨日(“yesterday”)」を返します。それ以外の日付の 場合は、引数に渡したフォーマット文字列を ... マット文字列 表示例 ( 今日の日付を 2007年 2月 17日 とします ) : 2007年 2月 16日 は yesterday になります。 2007年 2月 17日 は today になります。 2007年 2月 18日 は tomorrow になります。 今日、昨日、明日以外の日付は与えられた引数に従ってフォーマットされま ...
https://man.mtool.work/django/6.1/ref/contrib/humanize.html
ジェネリック日付ビュー 9057
ジェネリック日付ビュー 日付ベースのジェネリックビュー ( django.views.generic.dates 内で提供されています) は、日付ベースのデータのために、ドリルダウンページを描画するためのビューです。 注釈 このページの例のいくつかは、 myapp/models.py 内で下 ... % endif %} {% if previous_day and next_day %} -- {% endif %} {% if next_day %} Next Day: {{ next_day }} {% endif %} </ p > TodayArchiveView class TodayArchiveView [ソース] 今日 の全てのオブジェクトを表示する、日時のアーカイブページです。 year / month ... ic.list.MultipleObjectTemplateResponseMixin django.views.generic.base.TemplateResponseMixin django.views.generic.dates.BaseTodayArchiveView django.views.generic.dates.BaseDayArchiveView django.views.generic.dates.YearMixin django.views.generic.dates.M ... n django.views.generic.dates.DateMixin django.views.generic.base.View ノート デフォルトの template_name_suffix は _archive_today です。 例 myapp/views.py : from django.views.generic.dates import TodayArchiveView from myapp.models import Article class ...
https://man.mtool.work/django/6.1/ref/class-based-views/generic-date-based.html
クエリを作成する 9057
クエリを作成する 一度 データモデル を作成すれば、Django はデータオブジェクトの作成、取得、更新および削除を行えるようにデータベースを抽象化した API を自動的に提供します。本ドキュメントではこの API をどのように用いるかを説明します。多様なモデ ... 255 ) body_text = models . TextField () pub_date = models . DateField () mod_date = models . DateField ( default = date . today ) authors = models . ManyToManyField ( Author ) number_of_comments = models . IntegerField ( default = 0 ) number_of_pingb ... できます。 >>> Entry . objects . filter ( headline__startswith = "What" ) . exclude ( ... pub_date__gte = datetime . date . today () ... ) . filter ( pub_date__gte = datetime . date ( 2005 , 1 , 30 )) これはデータベース内のすべてのエントリーを含む Quer ... q1 = Entry . objects . filter ( headline__startswith = "What" ) >>> q2 = q1 . exclude ( pub_date__gte = datetime . date . today ()) >>> q3 = q1 . filter ( pub_date__gte = datetime . date . today ()) これら3つのクエリセットは独立しています。1番目は基本 ...
https://man.mtool.work/django/6.1/topics/db/queries.html
配信 (syndication) フィード フレームワーク 8440
配信 (syndication) フィード フレームワーク Django には、 RSS と Atom フィードを作成するための高レベルな配信 (syndication) フィード生成フレームワークが付属しています。 任意の配信フィードを作成するには、短い Python クラスを書くだけで済みます。 ... eed ( ... title = "My Blog" , ... link = "https://www.example.com/" , ... description = "In which I write about what I ate today." , ... language = "en" , ... author_name = "Myself" , ... feed_url = "https://example.com/atom.xml" , ... ) >>> f . add_i ... tem ( ... title = "Hot dog today" , ... link = "https://www.example.com/entries/1/" , ... pubdate = datetime . now (), ... description = "<p>Today I had a ...
https://man.mtool.work/django/6.1/ref/contrib/syndication.html
Sprint quickstart guide 8290
Sprint quickstart guide This document explains how to prepare to contribute to Django. It is intended for use during sprints, or by people who are already familiar with contributing to Python open source projects. This guide assumes you're ... The filters that are applied are: Triage stage = Accepted Patch needs improvement = Yes Created = between 5 years ago and today Modified = between 5 years ago and 6 months ago Claiming a ticket When you find a ticket, make yourself the owner by click ...
https://man.mtool.work/django/6.1/internals/contributing/sprint-quickstart.html
モデルフィールドリファレンス 8140
モデルフィールドリファレンス このドキュメントには、Django が提供するフィールドオプション field options とフィールド型 field types を含む、 Field のすべての API リファレンスが記載されています。 注釈 フィールドは django.db.models.fields に定義 ... 修正できるようにしておきたい場合は、 auto_now_add=True の代わりに以下をセットしてください: DateField に対して: default=date.today - datetime.date.today() より DateTimeField に対して: default=timezone.now - django.utils.timezone.now() より このフィールド ... のデフォルトのフォームウィジェットは DateInput です。admin は JavaScript カレンダーと "Today" のショートカットを追加します。追加の invalid_date エラーメッセージキーを含みます。 オプション auto_now_add 、 auto_now 、 ... 限するのに役立ちます。例えば下記のようにします: def limit_pub_date_choices (): return { "pub_date__lte" : datetime . date . today ()} limit_choices_to = limit_pub_date_choices もし limit_choices_to が Q オブジェクト を返す場合、これは 複雑なクエリ に便 ...
https://man.mtool.work/django/6.1/ref/models/fields.html
Django 1.0 リリースノート 8140
Django 1.0 リリースノート Django 1.0 へようこそ! We've been looking forward to this moment for over three years, and it's finally here. Django 1.0 represents the largest milestone in Django's development to date: a web framework that a grou ... pen Source project. Django's received contributions from hundreds of developers, been translated into fifty languages, and today is used by developers on every continent and in every kind of job. 興味深い歴史的記録として、2005年7月に Django が最初にリ ...
https://man.mtool.work/django/6.1/releases/1.0.html
Django 1.7 リリースノート 7989
Django 1.7 リリースノート September 2, 2014 Django 1.7 へようこそ! このリリースノートでは、 バージョン 1.7 の新機能 と、Django 1.6 以前からアップグレードする際に注意すべき、 後方互換性のない変更 について説明します。 非推奨サイクルが終了した ... ase to support Python 3.4. This change should affect only a small number of Django users, as most operating-system vendors today are shipping Python 2.7 or newer as their default version. If you're still using Python 2.6, however, you'll need to stick ... multiple times with different querysets. See prefetch_related() for more details. Admin shortcuts support time zones The "today" and "now" shortcuts next to date and time input widgets in the admin are now operating in the current time zone . Previou ...
https://man.mtool.work/django/6.1/releases/1.7.html
How to release Django 7823
How to release Django このドキュメントでは、Django のリリース方法について説明しています。 これらの手順を変更した場合は、最新の情報を保ってください! ここでのポイントは、規定を設けるのではなく、説明的であることです。自由に効率化したり、変更し ... release is fully published (last step). LTS Enable if the release is part of an LTS branch. Dates Set the release date to today. This release will not be published until is_active is enabled. Artifacts Upload the tarball ( django-<version>.tar.gz ), ...
https://man.mtool.work/django/6.1/internals/howto-release-django.html
PREV 1 2 3 NEXT