5 Campos 📑 AUTOMÁTICOS Creados por Odoo | Fields de creación y actualización

5 Campos 📑 AUTOMÁTICOS Creados por Odoo | Fields de creación y actualización

Understanding Automatic Fields in Node Models

Introduction to Automatic Fields

  • José introduces the topic of automatic fields created by models in Node, explaining that these fields are generated automatically when a new model is created.
  • These automatic fields are managed by the system and cannot be modified directly; however, they can be read if necessary.

Functionality of Automatic Fields

  • It is possible to disable certain automatic fields to prevent unnecessary data storage, particularly for models where these fields are not useful.
  • The log_access field defaults to the same value as the _auto field. If no value is specified during model creation, _auto will default to true.

Key Automatic Fields Explained

  • The unique identifier for each record in a model is stored in the id field, which ensures that no two records share the same identifier.
  • The create_date field captures the timestamp of when a record was created. This field automatically assigns its value without user intervention.

User and Modification Tracking

  • The create_uid field stores information about the user who created the record and is linked as a many-to-one relationship with the user model.
  • The write_date field logs the last modification date of a record, while write_uid keeps track of which user made that modification.

Summary of Automatic Field Creation

Video description

En este video te explico qué son y cuáles son los campos o fields automáticos que Odoo crea en cada uno de los modelos. Estos son campos que no se declaran en el modelo y que son administrados por el propio sistema. 🌐 Hosting que utilizo: linode.gvw92c.net/RyqgXv 🎤 El micrófono que utilizo: https://amzn.to/3NK26Qw ☕️ Apoya a este canal con un Café: https://ko-fi.com/josuheuh 00:00 Introducción 00:12 Campos automáticos creados por Odoo 00:45 Actualización automática si _log_access = True 02:34 Campo id: identificador único 03:07 Campos de creación create_date y create_uid 04:01 Campos de escritura o actualización write_date y write_uid