Conversation
mash-odoo
left a comment
There was a problem hiding this comment.
Hello!
Thank you for your work!
Here are some suggestions, mostly linter as of now!
Also, please update your PR title and description.
Furthermore, please update description in your commits while pushing, regarding the chapters and topics covered.
estate/models/estate_property.py
Outdated
| _postcode = "estate.postcode" | ||
| _date_avalilabilty = "estate.date_availability" | ||
| _expected_price = "estete.expected_price" | ||
| _selling_price = "estate.selling_price" | ||
| _bedrooms = "estate.bedrooms" | ||
| _living_area = "estate.living_area" | ||
| _facades = "estate.facades" | ||
| _garage = "estate.garage" | ||
| _garden = "estate.garden" | ||
| _garden_area = "estate.garden_area" | ||
| _garden_orientation = "estate.garden_orientation" |
There was a problem hiding this comment.
Hello, can you explain why you have added these here?
Also do you know what's the purpose of writing _name and _description?
There was a problem hiding this comment.
Yes ma’am, the additional underscored attributes such as _postcode and _date_availability were mistakenly added and are not required. They are not recognized by the Odoo ORM and do not have any functional impact on the model.
In contrast, meta attributes like _name and _description are part of Odoo’s model configuration. The _name attribute defines the technical name of the model and is responsible for registering it in the ORM and creating the corresponding database table. The _description attribute provides a human-readable label for the model, mainly for clarity in the user interface and metadata.
I will remove the unnecessary underscored attributes to keep the code clean and aligned with Odoo development standards. Thank you for your guidance.
estate/models/estate_property.py
Outdated
| garden = fields.Boolean(required=True) | ||
| garden_area = fields.Integer(required=True) | ||
| garden_orientation = fields.Selection( | ||
| selection=[("north", "North"), ("south", "South")], required=True |
There was a problem hiding this comment.
| selection=[("north", "North"), ("south", "South")], required=True | |
| selection=[('north', "North"), ('south', "South")], required=True |
Try keeping the key in lowercase
There was a problem hiding this comment.
Thankyou for your suggestion mam, i will from now on follow that and use odoo style conventions to keep the codebase clean.
| </form> | ||
| </field> | ||
| </record> | ||
| </odoo> No newline at end of file |
There was a problem hiding this comment.
Always add an extra line at the end of the file
There was a problem hiding this comment.
Thankyou for your suggestion ma'am,i have understood the mistake and will not repeat it again.
|
|
||
|
|
| <field name="selling_price"/> | ||
| <field name="bedrooms"/> | ||
| </group> | ||
|
|
estate/models/estate_property.py
Outdated
| from odoo import models, fields | ||
|
|
||
|
|
||
| class TestModal(models.Model): |
There was a problem hiding this comment.
| class TestModal(models.Model): | |
| class EstateProperty(models.Model): |
Keep the class name same as the file/table name
There was a problem hiding this comment.
Thankyou for pointing that out ma'am,I will update the class name to EstateProperty to ensure proper alignment with the model structure and coding standards.
…gic (chapter 8-9)

Chapters 1–7: Estate module implementation
This PR completes Chapters 1 to 7 of the Odoo tutorial for the estate module.
Covered topics:
This PR brings the estate module to a stable state up to Chapter 7.