per page, with , order by , clip by
Results of 1 - 10 of about 14 for editor (0.003 sec.)
マイグレーション・オペレーション 12901
マイグレーション・オペレーション マイグレーションファイルは一つ以上の オペレーション 、データベースに対してマイグレーションが行うべきオペレーションを宣言的に保持するオブジェクト、から構成されます。 Django はこれらの Operation オブジェクトも ... 。フィールドが null 許容でなく、デフォルト値を持たない場合、この操作は不可逆です。 Changed in Django 6.0: BaseDatabaseSchemaEditor and PostgreSQL backends no longer use CASCADE to delete dependent related database objects, such as views. Any dependent o ... おいて処理の場所が一致している履歴を反映したモデルを含んだ django.apps.registry.Apps のインスタンスであり、第二引数は SchemaEditor のインスタンスです。 reverse_code 引数はマイグレーションを元に戻す際に呼び出されます。この呼び出し可能オブジェクトはマイグ ... untry モデル上の初期オブジェクトを追加する例を示します: from django.db import migrations def forwards_func ( apps , schema_editor ): # We get the model from the versioned app registry; # if we directly import it, it'll be the wrong version Country = ap ...
https://man.mtool.work/django/6.1/ref/migration-operations.html
Working with Git and GitHub 11343
Working with Git and GitHub This section explains how the community can contribute code to Django via pull requests. If you're interested in how mergers handle them, see プルリクエストの取り扱い . Below, we are going to show how to create a ... themselves. Editing commit messages To change the message of the most recent commit, run: git commit --amend This opens an editor with the current commit message. Edit it, save, and close to update the commit. To change the message of an earlier commit ... rd" option in interactive rebase. For example, to reword one of the last three commits: git rebase -i HEAD~3 This opens an editor listing the three commits, each prefixed with the word "pick". Change "pick" to "reword" (or "r") on the line of the commi ... t you want to change, then save and close. A new editor will open for each commit marked as "reword", allowing you to update the message. See コミットガイドライン for the require ...
https://man.mtool.work/django/6.1/internals/contributing/writing-code/working-wi...
データベースのマイグレーションの作成方法 10783
データベースのマイグレーションの作成方法 このドキュメントでは、遭遇する可能性のあるいくつかのシナリオに対する、データベースのマイグレーションの構成方法と書き方について説明します。マイグレーションに関する入門的な資料を探しているなら、 トピッ ... 例えば、特定のデータベースに対してのみマイグレーションを実行したい場合です。 これを行うには、 RunPython 操作の中で、 schema_editor.connection.alias 属性を見て、データベース接続のエイリアスを確認します: from django.db import migrations def forwards ( app ... s , schema_editor ): if schema_editor . connection . alias != "default" : return # Your migration code goes here class Migration ( migration ... True これをマイグレーションに利用するには、次のようにします: from django.db import migrations def forwards ( apps , schema_editor ): # Your migration code goes here ... class Migration ( migrations . Migration ): dependencies = [ # Dependencies to othe ...
https://man.mtool.work/django/6.1/howto/writing-migrations.html
SchemaEditor 9802
SchemaEditor class BaseDatabaseSchemaEditor [ソース] Django のマイグレーションシステムは2つの部分に分かれています。データベースに対してどのような操作を実行するべきかを計算してその結果を保管するロジックの部分 ( django.db.migrations )と、「モ ... フィールドを削除する」といった操作を SQL に変換する、データベースの抽象レイヤーの部分です。後者の仕事を担当するのが、 SchemaEditor です。 Django を使っている普通の開発者が SchemaEditor を直接扱うことはほとんどありませんが、自前のマイグレーションシステム ... には、SQL を書くのではなく、こちらを選びましょう。 Django のデータベースのバックエンドは、それぞれ対応するバージョンの SchemaEditor を提供しており、好きなときに connection.schema_editor() コンテキストマネージャを使ってアクセスできます。 with connection . ... schema_editor () as schema_editor : schema_editor . delete_model ( MyModel ) これは、トランザクションや遅延SQL ( ForeignKey 制約の作成な ...
https://man.mtool.work/django/6.1/ref/schema-editor.html
JavaScript code 9382
JavaScript code While most of Django core is Python, the admin and gis contrib apps contain JavaScript code. Please follow these coding standards when writing JavaScript code for inclusion in Django. Code style Please conform to the indenta ... tion style dictated in the .editorconfig file. We recommend using a text editor with EditorConfig support to avoid indentation and whitespace issues. Most of ... gs and style errors. Biome will be run by the pre-commit hooks. We also recommended installing a Biome plugin in your text editor. Where possible, write code that will work even if the page structure is later changed with JavaScript. For instance, when ...
https://man.mtool.work/django/6.1/internals/contributing/writing-code/javascript...
Django 2.0 リリースノート 8104
Django 2.0 リリースノート December 2, 2017 Django 2.0 へようこそ! このリリースノートでは、 バージョン 2.0 の新機能 と、Django 1.11 以前からアップグレードする際に注意すべき、 後方互換性のない変更 について説明します。 非推奨サイクルが終了した ... that your backend works with. Django may use it in various messages, such as in system checks. The first argument of SchemaEditor._alter_column_type_sql() is now model rather than table . The first argument of SchemaEditor._create_index_name() is now t ... base , "_meta" ): base . _meta . local_many_to_many = [] model . _meta . local_many_to_many = [] with connection . schema_editor () as editor : editor . _remake_table ( model ) This script hasn't received extensive testing and needs adaption for vario ...
https://man.mtool.work/django/6.1/releases/2.0.html
"sites" フレームワーク 7824
"sites" フレームワーク Django にはオプションで "sites" フレームワークが付属しています。これは、オブジェクトや機能を特定の Web サイトに関連付けるためのフックで、 Django で動くサイトのドメイン名や "冗長な" 名前を保持する場所です。 1 つの Djan ... % current_site . name , "Thanks for your subscription. We appreciate it. \n\n -The %s team." % ( current_site . name ,), "editor@ %s " % current_site . domain , [ user . email ], ) # ... Lawrence.com では、このメールの件名は "Thanks for subscribing to ... t" ) . render ({}) message = loader . get_template ( "alerts/message.txt" ) . render ({}) send_mail ( subject , message , "editor@ljworld.com" , [ user . email ]) # ... この場合、LJWorld.com と Lawrence.com のテンプレートディレクトリの両方について、 su ...
https://man.mtool.work/django/6.1/ref/contrib/sites.html
Django 1.7.2 リリースノート 7824
Django 1.7.2 リリースノート January 2, 2015 Django 1.7.2 fixes several bugs in 1.7.1. Additionally, Django's vendored version of six, django.utils.six , has been upgraded to the latest release (1.9.0). バグ修正 Fixed migration's renaming of ... d missing index_together handling for SQLite ( #23880 ). Fixed a crash when RunSQL SQL content was collected by the schema editor, typically when using sqlmigrate ( #23909 ). Fixed a regression in contrib.admin add/change views which caused some ModelA ... th in Django's own test suite ( #23969 ). Fixed timesince filter translations in Korean ( #23989 ). Fixed the SQLite SchemaEditor to properly add defaults in the absence of a user specified default . For example, a CharField with blank=True didn't set ...
https://man.mtool.work/django/6.1/releases/1.7.2.html
マネージャ 7824
マネージャ class Manager [ソース] マネージャ (Manager) とは、Django のモデルに対するデータベースクエリの操作を提供するインターフェイスです。Django アプリケーション内の1つのモデルに対して、 Manager は最低でも1つは存在します。 Manager クラスの ... orManager ( models . Manager ): def get_queryset ( self ): return super () . get_queryset () . filter ( role = "A" ) class EditorManager ( models . Manager ): def get_queryset ( self ): return super () . get_queryset () . filter ( role = "E" ) class Pe ... . CharField ( max_length = 50 ) role = models . CharField ( max_length = 1 , choices = { "A" : _ ( "Author" ), "E" : _ ( "Editor" )}) people = models . Manager () authors = AuthorManager () editors = EditorManager () この例では、 Person.authors.all() ... 、 Person.editors.all() 、 Person.people.all() を指定でき、期待通りの結果が得られます。 デフォルトマネージャ Model. _default_manager カスタ ...
https://man.mtool.work/django/6.1/topics/db/managers.html
Coding style 7544
Coding style Please follow these coding standards when writing code for inclusion in Django. Pre-commit checks pre-commit is a framework for managing pre-commit hooks. These hooks help to identify simple issues before committing code for re ... using the black auto-formatter. This will be run by pre-commit if that is configured. The project repository includes an .editorconfig file. We recommend using a text editor with EditorConfig support to avoid indentation and whitespace issues. The Pyt ...
https://man.mtool.work/django/6.1/internals/contributing/writing-code/coding-sty...
PREV 1 2 NEXT