diff --git a/estate/__init__.py b/estate/__init__.py new file mode 100644 index 00000000000..0650744f6bc --- /dev/null +++ b/estate/__init__.py @@ -0,0 +1 @@ +from . import models diff --git a/estate/__manifest__.py b/estate/__manifest__.py new file mode 100644 index 00000000000..1d861170f6c --- /dev/null +++ b/estate/__manifest__.py @@ -0,0 +1,20 @@ +{ + 'name': 'Real Estate', + 'version': '1.0', + 'license': 'LGPL-3', + 'summary': 'Real estate advertisement management', + 'description': """ + Real Estate tutorial module. + """, + 'author': 'Parth Sawant', + 'depends': ['base'], + 'category': 'Real Estate', + 'data': [ + 'security/ir.model.access.csv', + ], + 'demo': [ + 'demo/demo.xml', + ], + 'application': True, + 'installable': True, +} diff --git a/estate/demo/demo.xml b/estate/demo/demo.xml new file mode 100644 index 00000000000..1c2045ea42b --- /dev/null +++ b/estate/demo/demo.xml @@ -0,0 +1,198 @@ + + + + + Modern Downtown Apartment + Sleek apartment in the heart of the city + 10001 + 2025-06-01 + 250000 + 245000 + 2 + 85 + 1 + False + False + 0 + north + + + + Suburban Family Home + Spacious home with a large backyard + 20002 + 2025-07-15 + 450000 + 440000 + 4 + 180 + 3 + True + True + 120 + south + + + + Cozy Studio Near University + Compact studio ideal for students + 30003 + 2025-05-01 + 95000 + 90000 + 1 + 35 + 1 + False + False + 0 + east + + + + Luxury Beachfront Villa + Stunning villa with direct beach access + 40004 + 2025-09-01 + 1200000 + 1150000 + 5 + 350 + 4 + True + True + 500 + south + + + + Countryside Cottage + Charming cottage surrounded by nature + 50005 + 2025-08-01 + 175000 + 170000 + 2 + 90 + 2 + False + True + 200 + west + + + + City Center Penthouse + Exclusive penthouse with panoramic views + 60006 + 2025-10-01 + 850000 + 820000 + 3 + 210 + 2 + True + False + 0 + north + + + + Industrial Loft Conversion + Trendy loft in a converted warehouse + 70007 + 2025-06-15 + 320000 + 310000 + 2 + 130 + 1 + False + False + 0 + east + + + + Hillside Bungalow + Peaceful bungalow with valley views + 80008 + 2025-07-01 + 290000 + 280000 + 3 + 110 + 2 + True + True + 80 + west + + + + Gated Community Townhouse + Secure townhouse in a premium gated complex + 90009 + 2025-11-01 + 530000 + 515000 + 3 + 150 + 2 + True + True + 60 + south + + + + Riverside Duplex + Beautiful duplex with riverside views + 10010 + 2025-08-15 + 390000 + 375000 + 4 + 160 + 3 + True + True + 90 + east + + + + Mountain Cabin Retreat + Rustic cabin with stunning mountain views + 11011 + 2025-09-15 + 210000 + 200000 + 2 + 75 + 1 + False + True + 150 + south + + + + + Historic Downtown Loft + Unique loft in a historic building + 12012 + 2025-10-15 + 280000 + 270000 + 1 + 95 + 2 + False + False + 0 + north + + + + \ No newline at end of file diff --git a/estate/models/__init__.py b/estate/models/__init__.py new file mode 100644 index 00000000000..5e1963c9d2f --- /dev/null +++ b/estate/models/__init__.py @@ -0,0 +1 @@ +from . import estate_property diff --git a/estate/models/estate_property.py b/estate/models/estate_property.py new file mode 100644 index 00000000000..99e54be1f31 --- /dev/null +++ b/estate/models/estate_property.py @@ -0,0 +1,29 @@ +from odoo import fields, models + + +class EstateProperty(models.Model): + _name = 'estate.property' + _description = 'Real Estate Property' + + name = fields.Char(string='Property Name', required=True, help='Enter the name of the property') + description = fields.Text(string='Property Description', help='Enter a description of the property') + postcode = fields.Char(string='Postcode', help='Enter the postcode of the property') + date_availability = fields.Date(string='Availability Date', help='Enter the date when the property becomes available') + expected_price = fields.Float(string='Expected Price', required=True, help='Enter the expected price of the property') + selling_price = fields.Float(string='Selling Price', help='Enter the selling price of the property') + bedrooms = fields.Integer(string='Number of Bedrooms', help='Enter the number of bedrooms in the property') + living_area = fields.Integer(string='Living Area', help='Enter the living area of the property in square meters') + facades = fields.Integer(string='Number of Facades', help='Enter the number of facades of the property') + garage = fields.Boolean(string='Garage', help='Check if the property has a garage') + garden = fields.Boolean(string='Garden', help='Check if the property has a garden') + garden_area = fields.Integer(string='Garden Area', help='Enter the area of the garden in square meters') + garden_orientation = fields.Selection( + selection=[ + ('north', 'North'), + ('south', 'South'), + ('east', 'East'), + ('west', 'West'), + ], + string='Garden Orientation', + help='Select the orientation of the garden' + ) diff --git a/estate/security/ir.model.access.csv b/estate/security/ir.model.access.csv new file mode 100644 index 00000000000..ab63520e22b --- /dev/null +++ b/estate/security/ir.model.access.csv @@ -0,0 +1,2 @@ +id,name,model_id:id,group_id:id,perm_read,perm_write,perm_create,perm_unlink +estate.access_estate_property,access_estate_property,estate.model_estate_property,base.group_user,1,1,1,1 \ No newline at end of file