File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ from . import models
Original file line number Diff line number Diff line change 88 "author" : "Piyush" ,
99 "category" : "Tutorials" ,
1010 "depends" : ["base" ],
11+ "license" : "LGPL-3" ,
1112 "data" : [],
1213 "application" : True ,
1314 "installable" : True ,
14- }
15+ }
Original file line number Diff line number Diff line change 1+ from . import estate_property
Original file line number Diff line number Diff line change 1- from odoo import fields ,models
1+ from odoo import fields , models
22
33
44class EstateProperty (models .Model ):
55 _name = "estate.property"
66 _description = "Real Estate Property"
7-
8- name = fields .Char ()
9- expected_price = fields .Float ()
10- bedrooms = fields .Integer ()
7+
8+ name = fields .Char (required = True )
9+ description = fields .Text ()
10+ postcode = fields .Char ()
11+ date_availability = fields .Date ()
12+
13+ expected_price = fields .Float (required = True )
14+ selling_price = fields .Float ()
15+
16+ bedrooms = fields .Integer ()
17+ living_area = fields .Integer ()
18+ facades = fields .Integer ()
19+
20+ garage = fields .Boolean ()
21+ garden = fields .Boolean ()
22+ garden_area = fields .Integer ()
23+
24+ garden_orientation = fields .Selection (
25+ selection = [
26+ ("north" , "North" ),
27+ ("south" , "South" ),
28+ ("east" , "East" ),
29+ ("west" , "West" ),
30+ ],
31+ string = "Garden Orientation" ,
32+ )
You can’t perform that action at this time.
0 commit comments