コンテンツへスキップ
メニュー
この質問にフラグが付けられました
2 返信
6212 ビュー

Hi,

For example, when you have some required fields in a view and you try to save without filling them, you get that nice popup on the top right corner saying "The following fields are invalid".

How could I display such a thing in my modules?

Thanks

アバター
破棄
著作者 最善の回答

In fact, I was wondering if it's possible to use it for other purposes than check required fields. For example, I have a python function performing a check on the values entered, and I'd like to use this kind of popup instead of the usual messagebox. What interests me in this popup is that it doesn't take the focus and oblige the user to click ok before doing something else.

アバター
破棄

okay, sorry I not have idea. but this popup take the focus just tap Enter (I have tested it with chrome and firefox).

最善の回答

just add required in your field

example :

 'name': fields.char("Name ",size=128,required=True),

and this popup is automatically displayed.

アバター
破棄
関連投稿 返信 ビュー 活動
1
9月 23
9307
2
7月 25
1917
2
7月 25
8392
1
5月 25
1339
2
5月 25
1976