Commit Graph

66 Commits

Author SHA1 Message Date
Sarah Hoffmann
8c444378bc better grouping 2020-02-28 22:10:35 +01:00
Sarah Hoffmann
55fdf0abda output linked place into address details 2020-02-28 22:07:06 +01:00
Sarah Hoffmann
6511ec3aa8 Convert importance to float value
Fixes #1369.
2019-04-30 23:21:53 +02:00
marc tobias
890d415e1f Nominatim::DB support input variables, custom error messages 2019-03-10 16:56:36 +01:00
marc tobias
d4b633bfc5 replace database abstraction DB with PDO 2019-03-09 00:18:15 +01:00
Sarah Hoffmann
2e9cebf025 define types for null returns in PlaceLookup
Fixes #1127.
2018-08-05 15:47:55 +02:00
Sarah Hoffmann
25baaf530d unify address details lookup
Introduces new AddressDetails class which is responsible
for address lookups. Saves always the complete result
and then allows filtering throught the different access
function. Remove special handling in Geocode() and use
there the lookup throught PlaceLookup() as well.
2018-07-10 23:54:35 +02:00
Sarah Hoffmann
320d488627 move ClassTypes into own namespace
Also adds some convenience functions for lookups.
2018-07-09 23:20:46 +02:00
Sarah Hoffmann
05bef92f0f ignore admin_level = 15 in geocodejson output
Level 15 is an artifical value.
2018-07-06 21:59:17 +02:00
Sarah Hoffmann
01d5ecb86b use already existing address field in geocodejson 2018-07-06 21:58:41 +02:00
Sarah Hoffmann
f50f46c1ce Merge branch 'geojson-output' of https://github.com/mtmail/Nominatim into mtmail-geojson-output 2018-07-06 20:26:33 +02:00
gemo1011
1d7ed6737e added comments and improved geOutline function 2018-06-27 14:55:24 +02:00
gemo1011
426e108b34 added case when for highways in subquery 2018-06-27 14:55:18 +02:00
gemo1011
a5750a6ef6 fixed getoutlinesfunction 2018-06-27 14:55:15 +02:00
gemo1011
07eb108a6d fixed typo 2018-06-27 14:55:12 +02:00
gemo1011
41249377d2 fixed getoutlines function if no coordinates are passed 2018-06-27 14:55:11 +02:00
gemo1011
398467b2f4 using ST_ClosestPoint and a subquery 2018-06-27 14:55:10 +02:00
gemo1011
ab5bcd6d2f rebase 2018-06-27 14:55:05 +02:00
gemo1011
6b8c99a275 rebase 2018-06-27 14:55:03 +02:00
Marc Tobias Metten
7a964efb3a search/reverse/lookup with geojson,geocodejson output 2018-05-29 17:20:34 +02:00
Sarah Hoffmann
2c42bda9ce nicer formatting for Geocode debug output 2018-03-25 22:28:18 +02:00
marc tobias
27bc8d4f7b replace PHP sizeof() with either count() or empty() 2018-03-22 12:36:24 +01:00
Jonas Hantelmann
a489ac07cd PlaceLookup::getAddressDetails() should be public, restore default values
PlaceLookup::getAddressDetails() is also used within the hierarchy.php
file so it must not be private.
2018-02-12 11:21:05 +01:00
Sarah Hoffmann
6c1977b448 replace double-quoting with single quotes where applicable 2017-10-26 21:40:33 +02:00
Sarah Hoffmann
7eeb79ce67 placex must not return a lookup housenumber 2017-10-25 20:11:51 +02:00
Sarah Hoffmann
282c6777ee use PlaceLookup::loadParamArray in search and lookup 2017-10-23 23:30:53 +02:00
Sarah Hoffmann
9981d74ee1 add loadParamArray function to PlaceLookup and use for reverse 2017-10-23 23:30:53 +02:00
Sarah Hoffmann
1a4506f6ab use PlaceLookup in search 2017-10-23 23:30:53 +02:00
Sarah Hoffmann
914caab43d make PlaceLookup::lookup() accept multiple results 2017-10-23 23:30:53 +02:00
Sarah Hoffmann
5eb11800a7 replace SQL code in PlaceLookup with content of search's get_details 2017-10-23 23:30:53 +02:00
Sarah Hoffmann
1424e8e29b use Result class in reverse geocoding
Also simplifies the reverse algorithm slightly by no longer
having an additional distance lookup.
2017-10-23 23:30:53 +02:00
Sarah Hoffmann
89c576fbe1 tests: more coverage for all API endpoints 2017-10-04 00:05:34 +02:00
Sarah Hoffmann
050b0a2ced remove street and addr_place columns in placex
The information is onyl needed for parenting,
so no need to store it permanently.
2017-04-08 19:58:10 +02:00
Sarah Hoffmann
c8e79397f5 introduce address column for place tables
The column is a hstore containing the full OSM tag with key and
value.
2017-04-08 18:58:26 +02:00
Sarah Hoffmann
bb1c3f23ab reduce maximum line length to 199 for all php files 2016-10-14 00:01:16 +02:00
Marc Tobias Metten
6238ae6032 add namespaces, method visibility according to PSR2 standard 2016-09-16 02:27:36 +02:00
Marc Tobias Metten
4a321487f3 fix indentation and misc errors according to PSR2 coding style guide 2016-09-14 03:16:46 +02:00
Marc Tobias Metten
2a784fa3d4 fix function declaration errors according to PSR2 coding style guide 2016-09-11 05:22:51 +02:00
marc tobias
3887423381 fix array-related errors according to PSR2 coding style guide 2016-09-10 21:10:52 +02:00
marc tobias
f05ea577f4 bracket spacing for if/else/for/foreach/while/switch according to PSR2 standard 2016-09-08 02:16:22 +01:00
Marc Tobias Metten
832547f192 tabs-to-spaces 2016-09-04 03:19:48 +02:00
Sarah Hoffmann
d594bb238b cleanup interface of PlaceLookup
Move lookup parameters (place id, type, frac etc.) from members
to parameters for lookup().
2016-07-26 20:54:14 +02:00
Sarah Hoffmann
033b9590bd use chksql everywhere in lib/
Replaces manual PEAR error checks and adds the chksql wrapper
where the error checks were still missing.
2016-06-12 14:58:05 +02:00
Markus Gail
db719d489f index on geometry of interpolation lines, and more improvements. 2016-04-27 17:42:59 +02:00
Markus Gail
b03be15442 Merge remote-tracking branch 'origin/master' into osmline
Conflicts:
	lib/Geocode.php
	lib/PlaceLookup.php
	sql/functions.sql
	sql/tables.sql
	utils/setup.php
2016-04-25 11:01:04 +02:00
Markus Gail
7879ad44cd Remove interpolation lines from placex and save them in an extra table. 2016-04-25 09:44:01 +02:00
Sarah Hoffmann
a86563cfb1 make tables for external data (Tiger and aux) configurable
Introduces two new settings CONST_Use_US_Tiger_Data and
CONST_Use_Aux_Location_data, which are disabled by default.
When false the corresponding tables are ignored in queries
and updates.

Aux and tiger tables are no longer created by default. This
has to be done by the corresponding import scripts. The former
aux table creation can be found in sql/aux_tables.sql for
reference.
2016-04-07 21:47:51 +02:00
Sarah Hoffmann
02bd322c1d remove explicitly set postgres/postgis version
Get the version from the database where necessary or simply
probe for existence of features. Fake hstore_to_json when
necessary.

Bumps the minimum required versions fro postgres to 9.1 and
for postgis to 2.0.
2016-03-30 22:48:18 +02:00
Markus Gail
7dd0a63b68 Fix coding style. 2016-03-23 09:34:36 +01:00
Markus Gail
a4ecd9d73e Merge branch 'tigerlines' of /home/markus/Nominatim into tiger
Conflicts:
	lib/Geocode.php
	lib/ReverseGeocode.php
	lib/lib.php
2016-03-22 11:26:39 +01:00