Book Image

Odoo 15 Development Essentials - Fifth Edition

By : Daniel Reis
4.5 (2)
Book Image

Odoo 15 Development Essentials - Fifth Edition

4.5 (2)
By: Daniel Reis

Overview of this book

Odoo is fast becoming the reference open source platform for business applications thanks to the fact that it provides the infrastructure needed for developers to deliver software solutions for any business process quickly. Odoo's layered module approach makes it particularly effective for combining and extending features. This updated fifth edition is a tutorial-style introduction to essential Odoo development topics. The book starts by covering the development essentials for building business applications and takes you through Odoo installation and configuration, gradually transitioning from having no specific knowledge of Odoo to being ready for application development. You'll then learn how to develop your first Odoo application, while covering topics such as models and views. Later chapters will get you up to speed with using server APIs to add business logic, helping you lay a solid foundation for advanced topics. As you progress, you’ll get equipped to build and customize your applications and explore the new features available in Odoo 12 and beyond, such as in-memory ORM and computed writable fields. Finally, you’ll gain insights into building business logic and using the Odoo API to integrate with various applications. By the end of this book, you’ll be able to build business apps from scratch using the latest version of Odoo.
Table of Contents (22 chapters)
1
Section 1: Introduction to Odoo Development
6
Section 2: Models
9
Section 3: Business Logic
13
Section 4: Views
18
Section 5: Deployment and Maintenance

What this book covers

Chapter 1, Quick Start Using the Developer Mode, visually introduces the Odoo development concepts, creating an Odoo application directly from the user interface – a simple to-do tracking application. Instructions are given to get Odoo working on the work machine, but an existing Odoo installation, or an Odoo.com instance, can be used, so no local setup is required.

Chapter 2, Preparing the Development Environment, explains how to install Odoo from source code, and how to set up the development environment to be used throughout the book. We choose to install Odoo in an Ubuntu environment, and under Windows 10 the Windows Subsystem for Linux (WSL) can be used to achieve this.

Chapter 3, Your First Odoo Application, provides a step-by-step guide through the creation of our first Odoo module, a book catalog for a library app. While the example is kept simple, it covers all the different layers and components that can be involved in an Odoo application: models, business logic, backend views, and web frontend views.

Chapter 4, Extending Modules, explains the available inheritance mechanisms and how to use them to create extension modules, adding or modifying features from other existing add-on modules.

Chapter 5, Importing, Exporting, and Module Data, addresses the usage of data files in Odoo, and their role in modules to load data and configurations to the database. It covers the XML and CSV data file formats, the external identifier concept, how to use data files in modules, and data import/export operations.

Chapter 6, Models – Structuring the Application Data, discusses the model layer in detail, introducing the framework's Object-Relational Mapping (ORM), the different types of models available, and the field types, including relational and computed fields.

Chapter 7, Recordsets – Working with Model Data, introduces ORM concepts and features, how to query and browse data from models, how to manipulate recordsets, and how to write changes to model data.

Chapter 8, Business Logic – Supporting Business Processes, explores programming business logic on the server side to manipulate data and implement specific business rules. It also explains how to use wizards for more sophisticated user interaction. The built-in social features – messages, chatter, followers, and channels – are addressed, as well as testing and debugging techniques.

Chapter 9, External API – Integrating with Other Systems, shows how to implement Odoo external applications by implementing a command-line client that interacts with our Odoo server. There are several alternative client programming libraries available, which are introduced and used to implement our showcase client utility.

Chapter 10, Backend Views – Designing the User Interface, covers the web client's View layer, explaining the several types of views in detail and all the elements that can be used to create dynamic and intuitive user interfaces.

Chapter 11, Kanban Views and Client-Side QWeb, continues working with the web client, but introduces Kanban views and explains the QWeb templates used to design the Kanban board elements.

Chapter 12, Creating Printable PDF Reports with Server-Side QWeb, discusses using the QWeb-based report engine and everything needed to generate printer-friendly PDF reports.

Chapter 13, Creating Web and Portal Frontend Features, introduces Odoo website development, including web controller implementations and using QWeb templates to build frontend web pages.

Chapter 14, Understanding Odoo Built-In Models, provides an overview of the models provided by the Odoo base module, such as Partners, Users, and the Models and Fields definitions.

Chapter 15, Deploying and Maintaining Production Instances, shows how to prepare a server for production prime time, explaining what configuration should be taken care of and how to configure an nginx reverse proxy for improved security and scalability.