]> git.openstreetmap.org Git - nominatim.git/commitdiff
Merge remote-tracking branch 'upstream/master'
authorSarah Hoffmann <lonvia@denofr.de>
Fri, 18 Sep 2020 20:41:47 +0000 (22:41 +0200)
committerSarah Hoffmann <lonvia@denofr.de>
Fri, 18 Sep 2020 20:41:47 +0000 (22:41 +0200)
1  2 
CMakeLists.txt
sql/functions/address_lookup.sql

diff --combined CMakeLists.txt
index e1ccae8724469dfebba936b78ac60e7978b3a359,43721cc4c6bdf33b4350988a2c6c2f51ade8e56d..5aa71800b8c235d8205062646911b2b6183d6317
@@@ -129,16 -129,6 +129,16 @@@ if (BUILD_API
         website/status.php
     )
  
 +   set(WEBSITEFILES
 +       403.html
 +       509.html
 +       crossdomain.xml
 +       favicon.ico
 +       nominatim.xml
 +       robots.txt
 +       taginfo.json
 +   )
 +
     foreach (script_source ${WEBSITESCRIPTS})
         configure_file(${PROJECT_SOURCE_DIR}/cmake/website.tmpl
                        ${PROJECT_BINARY_DIR}/${script_source})
  
     set(WEBPATHS css images js)
  
 +   foreach (webfile ${WEBSITEFILES})
 +       configure_file(${PROJECT_SOURCE_DIR}/website/${webfile}
 +                      ${PROJECT_BINARY_DIR}/website/${webfile})
 +   endforeach()
 +
     foreach (wp ${WEBPATHS})
         execute_process(
             COMMAND ln -sf ${PROJECT_SOURCE_DIR}/website/${wp} ${PROJECT_BINARY_DIR}/website/
             php -S 127.0.0.1:8088
             WORKING_DIRECTORY ${PROJECT_BINARY_DIR}/website
     )
+    add_custom_target(serve-global
+            php -S 0.0.0.0:8088
+            WORKING_DIRECTORY ${PROJECT_BINARY_DIR}/website
+    )
  endif()
  
  #-----------------------------------------------------------------------------
index 88b3a741f3d5e85099263d3b954f072c00ede472,d1ed69902eb61f2a30a4e0b1e279e6f9198c7b9e..196fb434868f69aacf87bdd7b895f80e11c458db
@@@ -180,6 -180,7 +180,7 @@@ BEGI
    -- Return the record for the base entry.
    FOR location IN
      SELECT placex.place_id, osm_type, osm_id, name,
+            coalesce(extratags->'linked_place', extratags->'place') as place_type,
             class, type, admin_level,
             type not in ('postcode', 'postal_code') as isaddress,
             CASE WHEN rank_address = 0 THEN 100
        searchcountrycode := NULL;
      END IF;
      countrylocation := ROW(location.place_id, location.osm_type, location.osm_id,
-                            location.name, location.class, location.type, NULL,
+                            location.name, location.class, location.type,
+                            location.place_type,
                             location.admin_level, true, location.isaddress,
                             location.rank_address, location.distance)::addressline;
      RETURN NEXT countrylocation;
    FOR location IN
      SELECT placex.place_id, osm_type, osm_id, name, class, type,
             coalesce(extratags->'linked_place', extratags->'place') as place_type,
 -           admin_level, fromarea, isaddress,
 +           admin_level, fromarea, isaddress and linked_place_id is NULL as isaddress,
             CASE WHEN rank_address = 11 THEN 5 ELSE rank_address END as rank_address,
             distance, country_code, postcode
        FROM place_addressline join placex on (address_place_id = placex.place_id)