-
Notifications
You must be signed in to change notification settings - Fork 1.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[ADD] estate: created new estate module and added types,offers,tags,v… #137
Conversation
4c41827
to
446d986
Compare
446d986
to
e3dc153
Compare
…iews - created a new estate module -defined init and manifest -created an estate_property model with the below fields and methods: -postcode,date_availability,selling_price,bed_rooms,facades.garden, orientation -compute_total,on_change,action_sold,action_cancel -created estate_property_type,tags,offers models and their corresponding views
e3dc153
to
57b72ab
Compare
…plates Added new features to the estate module, including the ability to generate comprehensive reports and the option to add dummy data for testing purposes. These enhancements improve the module's functionality and usability, allowing for better data visualization and easier testing scenarios.
f310f8c
to
9b0f6dc
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hello @koye-odoo
Some comments mostly regarding the guidelines.
Can you please check.
Thanks!!
estate/demo/estate_demo.xml
Outdated
]"/> | ||
</record> | ||
|
||
</odoo> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Need a blank line at EOF
Check for other files also.
estate/models/estate_property.py
Outdated
from odoo import api, models, fields | ||
from datetime import datetime | ||
from dateutil.relativedelta import relativedelta | ||
from odoo.exceptions import UserError, ValidationError |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
from odoo import api, models, fields | |
from datetime import datetime | |
from dateutil.relativedelta import relativedelta | |
from odoo.exceptions import UserError, ValidationError | |
from datetime import datetime | |
from dateutil.relativedelta import relativedelta | |
from odoo import api, fields, models | |
from odoo.exceptions import UserError, ValidationError |
Generally, we follow a convention in which we first import external libraries and then we make import from odoo in alphabetical order. Do same for other files also
estate/models/estate_property.py
Outdated
# def check_limit(self, vals): | ||
# self.status == "Offer Received" | ||
# if vals.get("price") <= self.best_price: | ||
# raise ValidationError("the offer must be higher than best price") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Try to avoid pushing the commented code.
<div class="d-flex justify-content-end"> | ||
<header> | ||
<button name="%(estate.action_open_offer)d" type="action" string="Offer" | ||
icon="fa-money" class="oe_stat_button"> | ||
<field name="offer_count" string="Offer Count"> | ||
</field> | ||
</button> | ||
</header> | ||
</div> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
<div class="d-flex justify-content-end"> | |
<header> | |
<button name="%(estate.action_open_offer)d" type="action" string="Offer" | |
icon="fa-money" class="oe_stat_button"> | |
<field name="offer_count" string="Offer Count"> | |
</field> | |
</button> | |
</header> | |
</div> | |
<div name="button_box"> | |
<button class="oe_stat_button" type="action" name="%(estate.action_open_offer)d" | |
icon="fa-ticket"> | |
<field string="Offers" name="offer_count" widget="statinfo"/> | |
</button> | |
</div> | |
You can do something like this for better placement of stat button
</form> | ||
</field> | ||
</record> | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
remove extra blankline
- Created 'security.xml'`to define security groups for Real Estate users. - Added 'category' field to the `__manifest.py with value 'Real Estate/ Brokerage'. - Created security groups: - `estate_group_user` (Agent) with category ` base.module_category_real_estate_brokerage`. - `estate_group_manager` (Manager) which implies `estate_group_user`. - Configured user roles so real estate agents only have access to the Real Estate app. - Tested access control by logging in with a real estate agent user and verifying limited access.
- Implemented rule limiting agents to view/modify only properties with no salesperson or where they are the assigned salesperson. - Ensured real estate managers retain access to all properties. - Verified estate_group_manager inherits permissions from estate_group_user as required.
- Restricted the creation of Property Types and Tags to agents by updating access control rules. - Made the Settings menu only visible to estate managers and another group by adding group-based restrictions. - Applied multi-company rules to silo data access between different companies/agencies in the estate module.
498b0c0
to
17a5e88
Compare
…operties. - Added 'Add Offer' button in the estate property tree view header. - Enabled selection of multiple properties for offer creation. - Created wizard with fields for price, offer status, and buyer. - Included 'Make an Offer' button to handle business logic and 'Cancel' button for form cancellation.
b868ace
to
2a8358d
Compare
…iews
-created an estate_property model with the below fields and methods:
-postcode,date_availability,selling_price,bed_rooms,facades.garden,
orientation
-compute_total,on_change,action_sold,action_cancel
-created estate_property_type,tags,offers models and their corresponding views