Skip to Content
Menu
This question has been flagged
1 Reply
1306 Views

I have installation of odoo 12 with inventory and fleet apps installed.

I need to make field with spare parts in stock compatible with vehicles in fleet. So if you open product description there will be field with compatible vehicles and if you open vehicle there will be field with compatible products. Of course if you fill compatible vehicles in product page then you should see compatible parts in vehicle page.

I tried to add many2many fields in both models but have no idea how to connect them with each other so they will show me what i want.

Do you have any suggestions how to do that?

Avatar
Discard
Best Answer

Hello You should put the code to see it ..... and the other is that I think you should use a many2one, as well as invoices and use domains to create filters in the many2one field ... put an image to see better


Avatar
Discard
Author

Sorry for long absence.

Actually I tried to make it through web interface and don't have any code.

Unfortunately I cannot add an image here so I will add the link to them http://cloud.psytyo.com/s/EeSNF3GYXLkA7Jj

There are two screenshots. One is view from car page and another from spare part page.

So I want it to be connected like

car1 <--> part1

car1 <--> part2

car2 <--> part1

and so on. When you open page with spare parts you see all the cars compatible and vice versa.

Thank you.