Skip to Content
Меню
Вам необхідно зареєструватися, щоб взаємодіяти зі спільнотою.
Це запитання позначене
1017 Переглядів

Hello Gurus,

I have a custom module where I need to easily track purchase orders raised for a job. I have a notebook sheet which displays links to related purchase orders and RFQs which works quite well. I want to enhance it by using the "create alternative" option which is loaded as part of the Purchase Agreements module. 

So, the situation is, if I duplicate the PO, all is good. 

In my module I inherit the purchase.orders and add my field:

job_id = fields.Many2one('jobs.jobs', string="Jobs", copy=True) 

My model has:

po_ids = fields.One2many('purchase.order', 'job_id', string="Purchase", copy=True)

If I use the Create Alternative, it does not carry across the id of the job across however, duplicating a PO does. I really want to have an easy way to cancel unsuccessful bidders that Create Alternatives provides.

I know I probably don't need the copy=True but, you know, trial and error and all that. 

Has anyone dealt with this before ? Got any tips?

As always, much appreciated!

Аватар
Відмінити
Related Posts Відповіді Переглядів Дія
2
лип. 25
567
1
черв. 25
571
0
вер. 23
1693
5
лют. 25
5962
2
груд. 24
1599