Hi I just built a simple version of the academy example module, repo on git pcachaca/Odoo Website Addon - Simple Academy example : https://github.com/pcachaca/Odoo-Website-Addon---Simple-Academy-example.git
This is a simple working version of the Academy Addon example for Odoo. It is a start for beginners - like me ;).
To show the academy page just go into website app of odoo, and go to url your_website_url/academy/
This addon includes a view.xml files, in order to be able to add datas on backend side of odoo, into academy top menu. The demo.xml file contains datas : the courses and teachers relations are not stated, so you can link a teacher to a course through the backend menu academy.
I have above questions, to make this example more fun ;)
The 2 questions (in templates.xml file) : we show the courses done by a teacher : <div t-esc="teacher.course_ids"/>. But how to show the name of this course ? Something like teacher.course_ids.name .... but how to make this working ??? Same to show the name of the teacher for a course. >> SOLVED by using teacher.course_ids.name
The third question is : how to write into the demo.xml file the data about the relations Courses-Teachers (One2many and many2one). ->> ALREADY SOLVED into commit n°4 : in file demo.xml file, added <field name="teacher_id" ref="padilla"/> where padilla is the ID of the target, repeat for each courses.
Thanks for contributor to review and improve the code, in order to meet new API rules of odoo v8
THIS IS A SIMPLE ACADEMY EXAMPLE FOR BEGINNERS, THANKS FOR YOUR HELP ;)
Please try to give a substantial answer. If you wanted to comment on the question or answer, just use the commenting tool. Please remember that you can always revise your answers - no need to answer the same question twice. Also, please don't forget to vote - it really helps to select the best questions and answers!
About This Community
|Asked: 9/25/14, 10:54 AM|
|Seen: 3456 times|
|Last updated: 3/16/15, 8:10 AM|