xml file
<?xml version="1.0"?> <openerp><data> <!-- Action to open To-do Task list --> <act_window id="action_todo_task" name="To-do Task" res_model="todo.task" view_mode="tree,form" />
<!-- Menu item to open To-do Task list --> <menuitem id="menu_todo_task" name="To-Do Tasks" sequence="20" action="action_todo_task" /> </data></openerp>
__openerp__.py
{ 'name':'To-Do Application', 'description':'Manage your personal tasks with this module', 'author':'Priyanshi Dharu', 'depends':['mail'], 'application':True, 'data':['todo_view.xml'],}
model.py
# -*- coding: utf-8 -*-from openerp import models,fieldsclass TodoTask(models.Model):
#model added to our custom module _name = 'todo.task' #attribute used to refer this model name as name = fields.Char('Description',required=True) #name of record is_done = fields.Boolean('Done?') active = fields.Boolean('Active?',default=True) #showing only active records
__init.py
from . import todo_model