Se rendre au contenu
Menu
Cette question a été signalée
3531 Vues

Example:

 

Module1.module1

Name = fields.Char()

 

________________

|records  : Cow        |

|                : Goat       |

|                : Bull         |

|                : Chicken  |

|                : Fish         |

----------------------------

 

Module2.module2

 

Animal _type = fields.Many2one(‘module1.module1’)

Animal_id = fields.Char()

Animal_fat=fields.Char()

Animal_meat=fields.Char()

 

 

---------------------------------------------Records module2.module2---------------------------------------

Animal_type      |              Animal_ID           |              Animal Fat           |              Animal meat      |

Goat                      |              Goat001               |              40%                        |              60%                        |

Goat                      |              Goat002               |              20%                        |              80%                        |

Goat                      |              Goat003               |              10%                        |              90%                        |

Cow                       |              Cow045                |              30%                        |              70%                        |

 

 

 

Module2-webportal.xml

 

<template>

 

<!--- I want to add here the record list from module1.module1 the code will be inside of Module2-webportal.xml and it shows as dropdown--->

 

<t t-foreach=”docsModule2” t-as=”module2”>

<div>

                                                <span t-field=”module2.animal_type.display_name”/>

                                                <span t-field=”module2.animal_id”/>

                                                <span t-field=”module2.animal_fat”/>

<span t-field=”module2.animal_meat”/>

</div>

 

</t>

</template>

Avatar
Ignorer
Publications associées Réponses Vues Activité
4
mai 24
12338
1
avr. 24
3025
0
nov. 23
1854
1
sept. 23
1930
2
août 23
4245