Skip to content

Commit 78f88d1

Browse files
committed
[IMP] Created estate_property model
1 parent 45e5903 commit 78f88d1

File tree

3 files changed

+32
-0
lines changed

3 files changed

+32
-0
lines changed

estate/__init__.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
2+
from . import models

estate/models/__init__.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
2+
from . import estate_property

estate/models/estate_property.py

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
2+
from odoo import models, fields
3+
4+
class EstateProperty(models.Model):
5+
_name = "estate.property"
6+
_description = "Real Estate module"
7+
8+
name = fields.Char(required=True)
9+
description = fields.Text()
10+
postcode = fields.Char()
11+
date_availability = fields.Date()
12+
expected_price = fields.Float(required=True)
13+
selling_price = fields.Float()
14+
bedrooms = fields.Integer()
15+
living_area = fields.Integer()
16+
facades = fields.Integer()
17+
garage = fields.Boolean()
18+
garden = fields.Boolean()
19+
garden_area = fields.Integer()
20+
garden_orientation = fields.Selection(
21+
string = 'Type',
22+
selection=[
23+
('north', 'North'),
24+
('south', 'South'),
25+
('east', 'East'),
26+
('west', 'West')
27+
],
28+
)

0 commit comments

Comments
 (0)