Odoo is the world's easiest all-in-one management software. It includes hundreds of business apps:
CRM | e-Commerce | Accounting | Inventory | PoS | Project management | MRP | etc.
If you have this page built in XML it will have an ID. The XML ID refers to a class in a Python file which is inside an http.route and this determinates the page URL.An example for one of the pages I made. The XML:
<template id="categoryselection"> <t t-call="website.layout"> <div id="wrap"> <div class="container oe_website_sale"> <h1 class="mb32">Kies een categorie</h1> <div class="row"> <form method="post" class=""> <div class="row bg-info" style="padding:15px;margin-top:30px;border-radius:15px;"> <div class="form-inline form-group"> <label for="afwerking" class="h4">Type afwerking</label> <br /> <select id="afwerking" name="afwerking" class="form-control"> <t t-foreach="afwerkingen" t-as="afwerking"> <option t-att-value='afwerking.id'> <span t-field="afwerking.name" /> </option> </t> </select> </div> </div> <input type="submit" class='btn btn-primary pull-right' value='Bevestigen'/> </form> </div> </div> </div> </t> </template>
As you can see this has a template ID named 'categoryselection'. When you'd open the controller you will find a http route and a function which links to this page. In my example:
@http.route(['/shop/categoryselection'], type='http', auth="public", website=True) //The function for this page def categoryselection(self, **post): cr, uid, context, pool = request.cr, request.uid, request.context, request.registry order = request.website.sale_get_order() //Lots of irrelevant code for you after this.
This @http.route is the name of the webpage, so this would for example be http://localhost:8069/shop/categoryselection. By changing this @http.route you can modify the page URL.
I hope this helps you enough.
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
This platform is for beginners and experts willing to share their Odoo knowledge. It's not a forum to discuss ideas, but a knowledge base of questions and their answers.Register
Odoo Training Center
Access to our E-learning platform and experience all Odoo Apps through learning videos, exercises and Quizz.Test it now
|Asked: 6/24/15, 9:27 AM|
|Seen: 995 times|
|Last updated: 6/25/15, 2:22 AM|