Hi Team,
I need to extend answer type under questions (appointments) to include HTML and others. Currently only see single line text, multi line text, check box, drop down.
Is there away to easily extend this list?
Thanks
Odoo is the world's easiest all-in-one management software.
It includes hundreds of business apps:
Hi Team,
I need to extend answer type under questions (appointments) to include HTML and others. Currently only see single line text, multi line text, check box, drop down.
Is there away to easily extend this list?
Thanks
Hi,
1. Inherit the appointment.question model
Create a custom module, and inherit the model to add your custom types:
from odoo import models, fields
class AppointmentQuestion(models.Model):
_inherit = 'appointment.question'
answer_type = fields.Selection(
selection_add=[
('html', 'HTML'),
# You can add more custom types
],
ondelete={'html': 'set default'} # Handle deletion behavior
)
Hope it helps
Stwórz konto dzisiaj, aby cieszyć się ekskluzywnymi funkcjami i wchodzić w interakcje z naszą wspaniałą społecznością!
Zarejestruj sięPowiązane posty | Odpowiedzi | Widoki | Czynność | |
---|---|---|---|---|
|
0
lut 25
|
1041 | ||
|
0
lut 25
|
888 | ||
|
0
mar 25
|
756 | ||
|
0
lis 24
|
835 | ||
Poor UX in Appointment Cancellation Flow
Rozwiązane
|
|
1
cze 25
|
422 |