Bỏ qua để đến Nội dung
Menu
Câu hỏi này đã bị gắn cờ
1 Trả lời
1153 Lượt xem

Hello Odooers,

Can I add a new value in print_format field using the inherited view? I know I can't add value using Odoo Studio or in Technical-->Database Structure-->Fields since it is a base field. However, is there any way to modify or add value using an inherited view? I'm using Odoo 17 Enterprise Edition.

I try to create a new field with similar selection values of print_format, then replace the print_format field with the field I created in the inherited views. Whenever I downloaded different formats, it downloaded the 2x7 format for all formats. I want to add 8x24 format in the print_format field. Thank you. 

Ảnh đại diện
Huỷ bỏ
Tác giả

Hello Niyas,
Thank you for your feedback, yes, I want to add a new option in the print product label wizard pop-up which is under print_format selection field. I can't add a value in print_label since it is a Base Field. That's why I created a new custom selection field with a value of only 8x24. When I try to add it to the form view, see the result in the image below:
https://i.postimg.cc/8C248JN0/Screenshot-2024-03-29-020435.png
The 2x7 format is selected as default, and when I select 8x24 format it will still select the 2x7 format. As a result, I have selected 2 formats. I tried to unable the set default option but I didn't find the default option for the print_format field.

Câu trả lời hay nhất

Hi,
I believe you are looking to add a new option in the print product label pop up (based on previous question asked), it is fine to add a new selection to that list, but depending on the new selection value, you need to adjust further code to take the new template, which you will create for 8 * 24

What you need to do is:


* Add new selection value named 8*24
* create new template for 8*24
* adjust the code to choose to take new template when 8*24 is selected


Thanks

Ảnh đại diện
Huỷ bỏ
Bài viết liên quan Trả lời Lượt xem Hoạt động
1
thg 4 24
2355
3
thg 5 25
1630
4
thg 5 25
22412
4
thg 5 25
2496
2
thg 5 25
5855