per page, with , order by , clip by
Results of 1 - 10 of about 45 for success (0.004 sec.)
ミックスイン (mixin) を編集する 15541
ミックスイン (mixin) を編集する 以下のミックスイン (mixin) は、Djangoの編集ビューを構築するのに使用されます。 django.views.generic.edit.FormMixin django.views.generic.edit.ModelFormMixin django.views.generic.edit.ProcessFormView django.view ... ContextMixin メソッドと属性 initial フォームの初期化データのディクショナリ。 form_class インスタンス化するフォームクラス。 success_url フォームが正常に処理されたときにリダイレクトするURL。 prefix 生成されるフォームの prefix 。 get_initial () フォームの初 ... t.FILES ) も提供されます。 get_prefix () 生成されるフォームの prefix を特定します。 デフォルトでは prefix を返します。 get_success_url () フォームのバリデーションに成功したときにリダイレクトする URL を特定します。 デフォルトでは success_url を返します。 ... form_valid ( form ) get_success_url() にリダイレクトします。 form_invalid ( form ) 無効なフォームをコンテキストとして提供し、レスポンスをレンダリングします ...
https://man.mtool.work/django/6.1/ref/class-based-views/mixins-editing.html
メッセージフレームワーク 12525
メッセージフレームワーク Web アプリケーションでは非常に一般的に、フォームやその他のユーザーインプットのプロセスの後、ユーザーに向けて一過性の通知メッセージ ("フラッシュメッセージ" とも言われます) を表示する必要があります。 Django は、anonym ... 的 DEBUG プロダクション環境では無視 (ないし削除) される、開発に関連したメッセージ INFO ユーザーに何か情報を伝えるメッセージ SUCCESS あるアクションが成功した、例えば "あなたのプロフィールは無事に更新されました" WARNING 問題は起きなかったが、問題になり得る ... フォルトでは、それぞれのレベルは、レベル定数を小文字にした、単一のタグを持っています。 レベル定数 タグ DEBUG debug INFO info SUCCESS success WARNING warning ERROR error メッセージレベル (ビルトインないしカスタムのいずれか) のデフォルトのタグを変更するため ... SQL statements were executed." % count ) messages . info ( request , "Three credits remain in your account." ) messages . success ( request , "Profile details updated." ) messages . warning ( request , "Your account expires in three days." ) messages . ...
https://man.mtool.work/django/6.1/ref/contrib/messages.html
クラスベースのジェネリックビュー: フラットインデックス 10121
クラスベースのジェネリックビュー: フラットインデックス この索引は、クラスベースビューのリファレンス文書を、異なる観点から編成したものです。ビューごとに、クラスツリーの有効な属性とメソッドが表されます。動作を定義するクラスの観点から編集された ... form_class() ] http_method_names initial [ get_initial() ] prefix [ get_prefix() ] response_class [ render_to_response() ] success_url [ get_success_url() ] template_engine template_name [ get_template_names() ] メソッド as_view() dispatch() form_invali ... nd_slug queryset [ get_queryset() ] response_class [ render_to_response() ] slug_field [ get_slug_field() ] slug_url_kwarg success_url [ get_success_url() ] template_engine template_name [ get_template_names() ] template_name_field template_name_suffix ... nd_slug queryset [ get_queryset() ] response_class [ render_to_response() ] slug_field [ get_slug_field() ] slug_url_kwarg success_url [ get_success_url() ] template_engine template_name [ get_template_names() ] template_name_field template_name_suffix ...
https://man.mtool.work/django/6.1/ref/class-based-views/flattened-index.html
クラスベースのビューでフォームを扱う 8452
クラスベースのビューでフォームを扱う フォームの処理には、一般に3つの場合分けが存在します。 最初の GET リクエスト (空白またはデフォルト値が埋め込まれたフォームを返す) 無効なデータの POST リクエスト (よくあるパターンは、エラー表示を追加したフ ... s.generic.edit import FormView class ContactFormView ( FormView ): template_name = "contact.html" form_class = ContactForm success_url = "/thanks/" def form_valid ( self , form ): # This method is called when valid form data has been POSTed. # It should ... plateResponseMixin を継承するため、ここでは template_name を使うことができます。 form_valid() デフォルトの実装は、ただ単に success_url にリダイレクトするというものです。 モデルフォーム Generic views really shine when working with models. These generic v ... ally. You can override this if you have any special requirements; see below for examples. You don't even need to provide a success_url for CreateView or UpdateView - they will use get_absolute_url() on the model object if available. カスタムの ModelForm ...
https://man.mtool.work/django/6.1/topics/class-based-views/generic-editing.html
ファイルのアップロード 8023
ファイルのアップロード Django がファイルアップロードを扱うとき、ファイルデータは request.FILES に格納されます ( request についての詳細は リクエスト/レスポンス オブジェクト を参照してください)。ここでは、ファイルがどのようにディスクとメモリに ... equest . FILES ) if form . is_valid (): handle_uploaded_file ( request . FILES [ "file" ]) return HttpResponseRedirect ( "/success/url/" ) else : form = UploadFileForm () return render ( request , "upload.html" , { "form" : form }) ここで、 request.FILE ... ( request . POST , request . FILES ) if form . is_valid (): # file is saved form . save () return HttpResponseRedirect ( "/success/url/" ) else : form = ModelFormWithFileField () return render ( request , "upload.html" , { "form" : form }) 手動でオブジェ ... nstance = ModelWithFileField ( file_field = request . FILES [ "file" ]) instance . save () return HttpResponseRedirect ( "/success/url/" ) else : form = UploadFileForm () return render ( request , "upload.html" , { "form" : form }) リクエストの外で手動で ...
https://man.mtool.work/django/6.1/topics/http/file-uploads.html
Djangoの認証システムを使用する 7931
Djangoの認証システムを使用する このドキュメントでは、デフォルト設定でのDjangoの認証システムの使用方法を説明します。この設定は、タスクの適切な範囲を管理することで、最も一般的なプロジェクトのニーズにかなうよう徐々に発展してきました。そして、パ ... ate ( request , username = username , password = password ) if user is not None : login ( request , user ) # Redirect to a success page. ... else : # Return an 'invalid login' error message. ... 認証バックエンドの選択 ユーザーがログインするとき、そのユー ... urn value. Example: from django.contrib.auth import logout def logout_view ( request ): logout ( request ) # Redirect to a success page. Note that logout() doesn't throw any errors if the user wasn't logged in. When you call logout() , the session data ... ed() デコレータを使用したときに raise_exception パラメータを使用しない限り、リダイレクトループが発生する可能性があります。 success_url_allowed_hosts ログイン後にリダイレクトしても安全なホストの set を、 request.get_host() に加えて指定します。デフォルトは ...
https://man.mtool.work/django/6.1/topics/auth/default.html
Django 1.4.20 リリースノート 7824
Django 1.4.20 リリースノート March 18, 2015 Django 1.4.20 fixes one security issue in 1.4.19. Mitigated possible XSS attack via user-supplied redirect URLs Django relies on user input in some cases (e.g. django.contrib.auth.views.login() an ... d i18n ) to redirect the user to an "on success" URL. The security checks for these redirects (namely django.utils.http.is_safe_url() ) accepted URLs with leading control ...
https://man.mtool.work/django/6.1/releases/1.4.20.html
Django 1.8.18 リリースノート 7824
Django 1.8.18 リリースノート April 4, 2017 Django 1.8.18 fixes two security issues in 1.8.17. CVE-2017-7233: Open redirect and possible XSS attack via user-supplied numeric redirect URLs Django relies on user input in some cases (e.g. djang ... o.contrib.auth.views.login() and i18n ) to redirect the user to an "on success" URL. The security check for these redirects (namely django.utils.http.is_safe_url() ) considered some numeric URLs (e.g. ...
https://man.mtool.work/django/6.1/releases/1.8.18.html
Django 1.10.7 リリースノート 7717
Django 1.10.7 リリースノート April 4, 2017 Django 1.10.7 fixes two security issues and a bug in 1.10.6. CVE-2017-7233: Open redirect and possible XSS attack via user-supplied numeric redirect URLs Django relies on user input in some cases ( ... e.g. django.contrib.auth.views.login() and i18n ) to redirect the user to an "on success" URL. The security check for these redirects (namely django.utils.http.is_safe_url() ) considered some numeric URLs (e.g. ...
https://man.mtool.work/django/6.1/releases/1.10.7.html
Django 1.4.6 リリースノート 7717
Django 1.4.6 リリースノート August 13, 2013 Django 1.4.6 fixes one security issue present in previous Django releases in the 1.4 series, as well as one other bug. This is the sixth bugfix/security release in the Django 1.4 series. Mitigated ... n some cases (e.g. django.contrib.auth.views.login() , django.contrib.comments , and i18n ) to redirect the user to an "on success" URL. The security checks for these redirects (namely django.utils.http.is_safe_url() ) didn't check if the scheme is http ...
https://man.mtool.work/django/6.1/releases/1.4.6.html
PREV 1 2 3 4 5 NEXT