Skip to content

Technical Onboarding - Server Framework 101#1284

Open
sidum-odoo wants to merge 1 commit into
odoo:19.0from
odoo-dev:19.0-technical-onboarding-sidum
Open

Technical Onboarding - Server Framework 101#1284
sidum-odoo wants to merge 1 commit into
odoo:19.0from
odoo-dev:19.0-technical-onboarding-sidum

Conversation

@sidum-odoo
Copy link
Copy Markdown

No description provided.

@robodoo
Copy link
Copy Markdown

robodoo commented May 19, 2026

Pull request status dashboard

@Megaaaaaa Megaaaaaa self-requested a review May 20, 2026 06:54
@sidum-odoo sidum-odoo changed the title Chapter 1-6 Technical Onboarding - Server 101 May 21, 2026
@sidum-odoo sidum-odoo changed the title Technical Onboarding - Server 101 Technical Onboarding - Server Framework 101 May 21, 2026
@sidum-odoo sidum-odoo force-pushed the 19.0-technical-onboarding-sidum branch 6 times, most recently from d9590a4 to 7c8b8e2 Compare May 22, 2026 09:31
@sidum-odoo
Copy link
Copy Markdown
Author

@Megaaaaaa ready for review

Chapters 1 to 15 of the Server Framework 101 Tutorial, which is about building a Real Estate Management App within Odoo.
The main module "estate" allows property management with Kanban, List and Form views. Types and tags and offers can be added/assigned to a property. The flow is managed through automatic state changes when offers are received/accepted. Additionnaly, the module "estate_account" allows automatic invoice creation when a property is sold.
@sidum-odoo sidum-odoo force-pushed the 19.0-technical-onboarding-sidum branch from 7c8b8e2 to f46f1a1 Compare May 22, 2026 11:38
Copy link
Copy Markdown

@Megaaaaaa Megaaaaaa left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hello 👋

I must say I'm impressed, this is a really really good PR 👍

There is very few things to say and very few reccurring comments. Only the trailing commas and the translations. Otherwise it's rather comment about technical stuff than about guielines. Tat's the kind of thing you want to have on your PRs later. That's nice 👍

So, please keep in mind that a review is not the utlimate solution, it's only someone seeing things he would have done differently and offering an alternative. You're always free to answer with an other alternative or even say you disagree and bring your arguments. For stuff that's not just styling or conventions, don't tak the wrong habit of just blindly applying comments, you spent time developping the thing, everything you've tried doesn't show up in the diff, only the final one. You probably have very interesting things to say to the reviewer about the decisions you made.

What I would suggest you do and continue to do while you're not the most comfortable with odoo's structure is to not apply all the changes at once. For example, changing multiple compute methods at once might lead you to a lot of errors if you don't check that the new implementation doesn't break anything before working on another one. Splitting the review in multiple steps and trying to run your db in between those can save you a lot of time in the long run.

Also a quick tip for the methodology when applying reviews changes: What I like to do it put a reaction like a thumbsup on a message once I have made the change locally. Then when everything is marked with something, I push, go through my diff and mark as resolved the things that are now outdated so nothing is left forgotten.

If you have any question, don't hesitate to ask!

Comment thread estate/models/__init__.py
Comment on lines +1 to +7
from . import (
estate_property,
estate_property_offer,
estate_property_tag,
estate_property_type,
res_users,
)
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I agree it looks better but we write the from . import x on each line except maybe for test files 😄

Suggested change
from . import (
estate_property,
estate_property_offer,
estate_property_tag,
estate_property_type,
res_users,
)
from . import estate_property
from . import estate_property_offer
from . import estate_property_tag
from . import estate_property_type
from . import res_users

Comment on lines +1 to +5
from dateutil.relativedelta import relativedelta

from odoo import api, fields, models
from odoo.exceptions import UserError, ValidationError
from odoo.tools.float_utils import float_compare, float_is_zero
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice ordering

Comment on lines +8 to +11
class EstateProperty(models.Model):
_name = "estate.property"
_description = "Estate Property"
_order = "id desc"
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice naming

_description = "Estate Property"
_order = "id desc"

name = fields.Char(string="Title", required=True)
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

And nice indentation, spacing, decision making on when to oneline or multiline a field. I already sense this review is going to go very well 👍

("south", "South"),
("east", "East"),
("west", "West"),
]
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The trailing coma so that people can add attributes to the field without modifying your lines 👍

Suggested change
]
],

property_ids = fields.One2many(
"estate.property",
"salesperson_id",
domain="['|',('state', '=', 'new'),('state', '=', 'offer_received')]",
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No space around operators but definitely a space after commas 😄

Suggested change
domain="['|',('state', '=', 'new'),('state', '=', 'offer_received')]",
domain="['|', ('state', '=', 'new'), ('state', '=', 'offer_received')]",

<list>
<field name="name"/>
<field name="expected_price"/>
<field name ="state"/>
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You did that to check if I was paying attention right ? Well I AM ! 😄

Suggested change
<field name ="state"/>
<field name="state"/>

Comment thread estate/__manifest__.py
"name": "Real Estate",
"application": True,
"depends": ["base"],
"author": "Simon Dumoulin",
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As an Odoo employee, you can't sign your work in your own name. The author of this module is "Odoo S.A." 😄

Comment thread .gitignore
Comment on lines +9 to 13
# IDE
.vscode/
ruff.toml

# Distribution / packaging
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Shouldn't be part of your diff 😄

{
"name": "Property Invoicing",
"depends": ["estate", "account"],
"author": "Simon Dumoulin",
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Odoo S.A.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants