Skip to Content
เมนู
คุณต้องลงทะเบียนเพื่อโต้ตอบกับคอมมูนิตี้
คำถามนี้ถูกตั้งค่าสถานะ
1 ตอบกลับ
471 มุมมอง

Hello community,

I’m creating a contact form in Odoo and I need it to include a checkbox with the text:

"I have read and accept the privacy policy", which should be unchecked by default and mandatory to submit the form.

My version is  saas-18.4

Could you please guide me on how to implement this correctly?

  • Is it possible to configure it directly from Website Form?
  • Or should I do it through code/QWeb by adding the field as a required checkbox?
  • Any practical example or snippet that could help me as a reference?

Thank you very much for your support!

อวตาร
ละทิ้ง
คำตอบที่ดีที่สุด

You can add a new Field of Type Checkbox when switching to the Website Editor on the Form page in question, then click somewhere into that form and click + Field:

 


Which results in this behavior upon submitting the form:

อวตาร
ละทิ้ง