Real estate prices – data model, report and permissions
Storage of listings and price history, the source, the report groupings, the two kinds of deletion and the map permission.
Overview
Property listings and their price history; the source is the newsletter of a listing portal, processed by the portal adapter of the e-mail task. Report and chart by settlement, district, neighbourhood and street. There is deliberately no content scope, as this is market data.
Data model
Table names carry the installation's own prefix in the database.
| Table | Role |
|---|---|
realestate_listing | listing (location, building type, deal, type, area, current and first price, status) |
realestate_price | price history |
ksh_settlement | county and NUTS from the settlement register |
Functions
- List: current price, price per square metre, first price, total change in per cent, price history in the collapsible panel; table existence check (
error_table); the bin is shown according tocanSeeDeleted(). - Report (
listing.report,listing.chart): grouping by settlement, district, neighbourhood, street or type; count, average price, average price per square metre, min–max, average area, rose and fell counts; the chart uses the same query. - Move to bin:
status = 9; if the user only has the permanent delete right, the header button uses that path. - Permanent delete: physical deletion of the listing and its price history (
deleteListings), logged. - Map: link and layer only with
mapandgeo/map::list; geocoding is done by the map module.
Permissions
- Catalogue seed:
install/permission_realestate_v1.sql, map permissioninstall/permission_market_map_v1.sql. list,report,debug,map; deletion by count withcanBulkAction():statusdelete/bulkstatusdelete,delete/bulkdelete, plus the basicmodifyright.