mirror of
https://github.com/osm-search/Nominatim.git
synced 2026-02-26 11:08:13 +00:00
remove most landuses from addresses
This commit is contained in:
@@ -1107,7 +1107,11 @@ BEGIN
|
|||||||
END IF;
|
END IF;
|
||||||
ELSEIF NEW.class = 'landuse' AND ST_GeometryType(NEW.geometry) in ('ST_Polygon','ST_MultiPolygon') THEN
|
ELSEIF NEW.class = 'landuse' AND ST_GeometryType(NEW.geometry) in ('ST_Polygon','ST_MultiPolygon') THEN
|
||||||
NEW.rank_search := 22;
|
NEW.rank_search := 22;
|
||||||
NEW.rank_address := NEW.rank_search;
|
IF NEW.type in ('residential', 'farm', 'farmyard', 'industrial', 'commercial', 'allotments', 'retail') THEN
|
||||||
|
NEW.rank_address := NEW.rank_search;
|
||||||
|
ELSE
|
||||||
|
NEW.rank_address := 0;
|
||||||
|
END IF;
|
||||||
ELSEIF NEW.class = 'natural' and NEW.type in ('peak','volcano','mountain_range') THEN
|
ELSEIF NEW.class = 'natural' and NEW.type in ('peak','volcano','mountain_range') THEN
|
||||||
NEW.rank_search := 18;
|
NEW.rank_search := 18;
|
||||||
NEW.rank_address := 0;
|
NEW.rank_address := 0;
|
||||||
|
|||||||
@@ -319,6 +319,7 @@ Feature: Import into placex
|
|||||||
| osm_type | osm_id | class | type | geometry
|
| osm_type | osm_id | class | type | geometry
|
||||||
| W | 4 | landuse | residential | poly-area:0.1
|
| W | 4 | landuse | residential | poly-area:0.1
|
||||||
| R | 2 | landuse | residential | poly-area:0.05
|
| R | 2 | landuse | residential | poly-area:0.05
|
||||||
|
| R | 3 | landuse | forrest | poly-area:0.5
|
||||||
When importing
|
When importing
|
||||||
Then table placex has no entry for N1
|
Then table placex has no entry for N1
|
||||||
And table placex has no entry for W1
|
And table placex has no entry for W1
|
||||||
@@ -331,6 +332,7 @@ Feature: Import into placex
|
|||||||
| W2 | 30 | 30
|
| W2 | 30 | 30
|
||||||
| W4 | 22 | 22
|
| W4 | 22 | 22
|
||||||
| R2 | 22 | 22
|
| R2 | 22 | 22
|
||||||
|
| R3 | 22 | 0
|
||||||
|
|
||||||
Scenario: rank and inclusion of naturals
|
Scenario: rank and inclusion of naturals
|
||||||
Given the place nodes
|
Given the place nodes
|
||||||
|
|||||||
Reference in New Issue
Block a user