Перейти к содержимому
Меню
Чтобы взаимодействовать с сообществом, необходимо зарегистрироваться.
Этот вопрос был отмечен
2 Ответы
8268 Представления

Hi everyone,

   What would the right way to add odoo fields as prefix in sequence? I want to use Internal Reference field (ref; res_partner) as prefix to order number sequence code, so i know straight ahead who is the customer by looking at order number. 

Thanks in advance.

Аватар
Отменить

Is this possible in odoo 16 Saas without customization

Автор Лучший ответ

Sorry, took me a while to come back to this. Which file should I be working on? Sorry, i'm new to odoo. Where does it keep sequence setting for sales orders?

ok, i found file ir_sequence.py, where i should add my field (by the way, field i want to show in sequence is "doc.partner_id.ref". How can i define it and make it work as, let say %(ref) in my sequence settings? Thanks!

Аватар
Отменить
Лучший ответ

In create() method you can append it

Аватар
Отменить
Related Posts Ответы Просмотры Активность
1
мая 25
2442
1
сент. 24
1354
1
июн. 23
2327
1
апр. 23
11434
1
июн. 22
2690