Wednesday, December 4, 2019

View types in odoo

ODOO

 

Views



In this step we will explain
  • View types in odoo
  • How to create your first python class (python class structure)


View types :
 
Form view : show editable form for your object just like in the image bellow

List view (tree view) : show existing records for your models in the database as list with some fields , just like bellow

Kanban view : show existing records in card view just like in the image bellow 
 
Calendar view : view to display and edit information about dates and durations in your records in a visual way
 
Graph view : show your data in graph views as bar chart, line chart and pie chart
Pivot view : show your data in dynamic views
Search view : design search view with some attributes like (group by ,filters …) to make search more easy for the user 

Now how to create your first python class ?

We can define the class (object) structure as bellow
Import packages : here we will import all packages that we will use
Class class_name.. : here we define our class (class name and type)
Class attributes : here we define the attributes for the class
Class attributes :
_name = ‘the object name’ … eg : _name = ‘clinic.patient’
_description = ‘object description’
_order = ‘field_name’ … to order the records by this field
_rec_name = ‘field_name’… to show record in relational fields by this field
_inherit = ‘object.object’ … write the inherited here


Class body : will define as
Fields

Constraints

Functions

Watch On YouTube 



PREVIOUS STEP          NEXT STEP

No comments:

Post a Comment

Odoo Invoice Qr code issues

There are two main issues must of us facing with the QR code in Odoo invoice & these issues are 1/ QR code displayed as broken image w...