How to validate error message if some field is empty or uncheck etc ? is there any built-in function tag am using required in xml view but not working ?
Odoo is the world's easiest all-in-one management software.
It includes hundreds of business apps:
- CRM
- e-Commerce
- 会計
- 在庫
- PoS
- Project
- MRP
この質問にフラグが付けられました
2
返信
3195
ビュー
I tried but not working am using on the xml??
from odoo import fields, models, api, _from odoo.exceptions import UserError
class SchoolProfile(models.Model): _name = "school.profile"
name = fields.Many2one("school.profile", string="School Name", required=True)
did you upgrade the module after making the changes in xml?
yesi did but still not working
Hi,
The following ways allow you to make a field required: either updating in Python or XML.
<field name="employee_id" required="1"/>
OR
employee_id = fields.Many2one('hr.employee', string='Employee', required=1)
関連投稿 | 返信 | ビュー | 活動 | |
---|---|---|---|---|
|
0
10月 24
|
1480 | ||
|
0
7月 24
|
1245 | ||
|
0
11月 23
|
1439 | ||
|
0
9月 23
|
2087 | ||
|
1
11月 22
|
4141 |
yes i did but still not working