[ADD] estate : real estate module implementation#1232
Draft
aykhu-odoo wants to merge 16 commits intoodoo:19.0from
Draft
[ADD] estate : real estate module implementation#1232aykhu-odoo wants to merge 16 commits intoodoo:19.0from
aykhu-odoo wants to merge 16 commits intoodoo:19.0from
Conversation
…tion - Configured manifest with required metadata and dependencies. - It covers chapter- 2 and 3 task - Added the required fields.
- Completed Ch 4 task for Access Rights
a0a9563 to
4fe99f0
Compare
- Created an action - Define main menu and submenus - Add views to manifest 'data' list - Completed Ch 5 Action and Menu part
- Added is_active and state fields in form - Added fields in list view - Improved and adjusted fields in Form View - Completed Ch 5 and Ch 6 List and Form Views
- Implemented search view - Added property types, tags, and offers models - Linked properties with buyer, salesperson, types, tags, and offers - Completed Ch 6 and Ch 7.
- Added Best Offer and Total Area fields in property form view - Covers 2 tasks of chapter 8.
…nction - Added Validity and date_deadline fields with inverse function - Implemented onchange logic for garden_area and garden_orientation - Suggested fixes implemented - Covers last 2 tasks of chapter 8.
- Added sold and cancelled action buttons for state transition - Prevent invalid transitions between 'sold' and 'cancelled' states
- Introduce Accept and Refuse buttons for property offers - Assign buyer and selling price to property on acceptance - Restrict multiple offers from being accepted for the same property - Chapter 9 Completed.
- Ensure positive property and offer prices - Ensure unique property tag and type names - Chapter 10 task 1 completed.
- Adds constraint using float_compare, ignores zero selling price. - Chapter 10 completed.
- Added inline list view for property types - Implemented statusbar widget for property state - Defined default ordering on models - Added conditional visibility and readonly attributes - Enhanced list views with decorations and optional fields - Introduced stat button on property type to access related offers - Added related field and computed offer count for property types - Chapter 11 completed
- Extended CRUD methods for offer validation, state update - Added constraints to prevent invalid operations (state and offer price check) - Inherited res.users to add property_ids relation - Implemented view inheritance to display properties in user form - Completed chapter 12
- Integrated account module to create invoices from sold properties - Reused account.move for financial operations - Enhanced kanban view using QWeb templating - Implemented conditional UI logic with t-if and raw values - Chapter 13 and 14 completed.
- Added visit scheduling with list, form, and calendar views - Added constraint to prevent overlapping visits within the same property - Automatically create calendar events on visit creation - Added issue reporting with list and form views - Completed Group Tasks.
4fe99f0 to
b8bc03e
Compare
- Added chatter and activities - Implemented logic to reject all other offers when one is accepted - Added “Accept Best Offer” action to simplify offer selection - Added rainbow animation when a property is marked as sold - Display sold ribbon in form and kanban views - Updated kanban default grouping to state and disabled record drag - Made “Sold” and “Accept Best Offer” buttons conditional primary actions
26c6c8b to
92ab5a6
Compare
bit-odoo
reviewed
Apr 20, 2026
bit-odoo
left a comment
There was a problem hiding this comment.
Hello
Can you please update your pr description?
Thanks
|
|
||
| from odoo import api, fields, models | ||
|
|
||
| AVAILABLE_PRIORITIES = [ |
| def action_property_sold(self): | ||
| for record in self: | ||
| if record.state == "cancelled": | ||
| raise UserError("Cancelled property cannot be set as sold.") |
There was a problem hiding this comment.
It's good to make the error message translatable.
raise UserError(_("Cancelled property cannot be set as sold."))
| @api.depends('visit_ids') | ||
| def _compute_issue_count(self): | ||
| for record in self: | ||
| record.issue_count = len(record.issue_ids) |
| <field name="arch" type="xml"> | ||
| <form> | ||
| <header> | ||
| <button name="action_rainbow_man" string="Sold" class="btn-primary" type="object" invisible="state != 'offer_accepted'"/> |
There was a problem hiding this comment.
The name is not aligned with the string.
|
|
||
| def action_accepted(self): | ||
| for offer in self.property_id.offer_ids: | ||
| if offer.status == "accepted": |
There was a problem hiding this comment.
You already made the button invisible. No need for this condition.
| <field name="property_type_id"/> | ||
| <field name="validity" width="100"/> | ||
| <field name="date_deadline"/> | ||
| <button name="action_accepted" type="object" string="Accept" icon="fa-check" invisible="status != False"/> |
There was a problem hiding this comment.
Suggested change
| <button name="action_accepted" type="object" string="Accept" icon="fa-check" invisible="status != False"/> | |
| <button name="action_offer_accepted" type="object" string="Accept" icon="fa-check" invisible="status != False"/> |
| <field name="validity" width="100"/> | ||
| <field name="date_deadline"/> | ||
| <button name="action_accepted" type="object" string="Accept" icon="fa-check" invisible="status != False"/> | ||
| <button name="action_refused" type="object" string="Refuse" icon="fa-times" invisible="status != False"/> |
There was a problem hiding this comment.
Suggested change
| <button name="action_refused" type="object" string="Refuse" icon="fa-times" invisible="status != False"/> | |
| <button name="action_offer_refused" type="object" string="Refuse" icon="fa-times" invisible="status != False"/> |
Comment on lines
+17
to
+20
| <field name="property_type_id"/> | ||
| <field name="property_tags_ids" widget="many2many_tags" options="{'color_field': 'color'}" width="300"/> | ||
| <field name="bedrooms"/> | ||
| <field name="living_area"/> |
There was a problem hiding this comment.
No need to display too many fields. You can make these fields optional.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Implementation of Real Estate Advertisement module
Features: