Search Here

Pages

Thursday, 22 September 2016

How to create custom reports in Odoo (Qweb)

Qweb Reporting Engine | To day you will learn how to create custom reports in odoo using qweb reporting engine. In this post we will learn how to create simple custom reports and its template using qweb.

How to convert datetime.date to datetime.datetime

To day you will learn How to convert datetime.date to datetime.datetime.

#converting datetime.date to datetime.datetime
start_date = datetime.strptime(s_date.strftime('%Y%m%d'), '%Y%m%d')


Date formatting in Qweb reports (dd-mm-yy):

<h5 class="pull-right" style="position:relative; top: 2px; margin:0;"><u>Printed Date: <span t-esc="time.strftime('%d-%b-%Y')"></span></u></h5>

How to create Form and Tree view in Odoo

Hello how are you guys!!! In my previous post you learned about "Action Menu" in odoo. We also learned in very detail how to create action menu in odoo. Today you will learn about Views in odoo.

What are Views in Odoo:

        Odoo have several types of views, but there are three commonly used views. Which are "List, Form and Search View". List view also know as "Tree".

How to create models in odoo

Before creating our first model in odoo, we need to know about model. A model is a python class
that represent business entity (fields) that are stored in PostgreSQL database. In odoo all business
entities are implemented as model or class. Model fields (class property) are defined as attributes or 
column or fields in a database.