]> git.openstreetmap.org Git - nominatim-ui.git/blobdiff - src/templates/detailspage.hbs
detail page: add permalink, equivalent to https://github.com/openstreetmap/Nominatim...
[nominatim-ui.git] / src / templates / detailspage.hbs
index c7098b4d8edaccf568bb8ccd3a8872043604ab43..8328f1ce14cb9e86eadf0bc7065e2ceb7bb9fae0 100644 (file)
         <td>{{this.rank_address}}</td>
         <td>{{formatAdminLevel this.admin_level}}</td>
         <td>{{formatDistance this.distance}}</td>
-        <td>{{detailsLink this}}</td>
+        <td>{{detailsLink this null}}</td>
     </tr>
 {{/inline}}
 
 {{#*inline "partial_details_keyword_one_row"}}
     <tr>
-        <td>{{formatKeywordToken this.word_token}}</td>
-        {{#if this.word_id}}
-            <td>word id: {{this.word_id}}</td>
+        <td>{{formatKeywordToken this.token}}</td>
+        {{#if this.id}}
+            <td>word id: {{this.id}}</td>
         {{/if}}
     </tr>
 {{/inline}}
@@ -38,7 +38,7 @@
 <div class="container">
     <div class="row">
         <div class="col-sm-10">
-            <h1>{{aPlace.localname}}</h1>
+            <h1>{{aPlace.localname}} <small>{{detailsPermaLink aPlace 'link to this page'}}</small></h1>
         </div>
         <div class="col-sm-2 text-right">
             {{formatMapIcon aPlace.icon}}
                 <tr>
                     <td>Name</td>
                     <td>
-                        {{#each aPlace.aNames}}
+                        {{#each aPlace.names}}
                             <div class="line"><span class="name">{{this}}</span> ({{@key}})</div>
                         {{/each}}
                     </td>
                 </tr>
                 <tr>
                     <td>Type</td>
-                    <td>{{aPlace.class}}:{{aPlace.type}}</td>
+                    <td>{{aPlace.category}}:{{aPlace.type}}</td>
                 </tr>
                 <tr>
                     <td>Last Updated</td>
@@ -92,7 +92,7 @@
                     <td>OSM</td>
                     <td>{{osmLink aPlace}}
                 </tr>
-                {{#if aPlace.wikipedia}}
+                {{#if aPlace.calculated_wikipedia}}
                     <tr>
                         <td>Wikipedia Calculated</td>
                         <td>{{wikipediaLink aPlace}}</td>
                 {{/if}}
                 <tr>
                     <td>Computed Postcode</td>
-                    <td>{{aPlace.postcode}}</td>
+                    <td>{{aPlace.calculated_postcode}}</td>
                 </tr>
                 <tr>
                     <td>Address Tags</td>
                     <td>
-                        {{#each aPlace.aAddressTags}}
+                        {{#each aPlace.addresstags}}
                             <div class="line"><span class="name">{{this}}</span> ({{@key}})</div>
                         {{/each}}
                     </td>
                 <tr>
                     <td>Extra Tags</td>
                     <td>
-                        {{#each aPlace.aExtraTags}}
+                        {{#each aPlace.extratags}}
                             <div class="line"><span class="name">{{this}}</span> ({{@key}})</div>
                         {{/each}}
                     </td>
                     </tr>
                 </thead>
                 <tbody>
-                    {{#if aPlace.address_lines}}
-                        {{#each aPlace.address_lines}}
+                    {{#if aPlace.address}}
+                        {{#each aPlace.address}}
                             {{> partial_details_one_row}}
                         {{/each}}
                     {{/if}}
 
-                    {{#if aPlace.linked_lines}}
+                    {{#if aPlace.linked_places}}
                         {{> partial_h2 'Linked Places'}}
-                        {{#each aPlace.linked_lines}}
+                        {{#each aPlace.linked_places}}
                             {{> partial_details_one_row}}
                         {{/each}}
                     {{/if}}
 
-                    {{#if aPlace.place_search_name_keywords}}
+                    {{#if aPlace.keywords}}
                         {{> partial_h2 'Name Keywords'}}
-                        {{#each aPlace.place_search_name_keywords}}
+                        {{#each aPlace.keywords.name}}
                             {{> partial_details_keyword_one_row}}
                         {{/each}}
-                    {{/if}}
 
-                    {{#if aPlace.place_search_address_keywords}}
                         {{> partial_h2 'Address Keywords'}}
-                        {{#each aPlace.place_search_address_keywords}}
+                        {{#each aPlace.keywords.address}}
                             {{> partial_details_keyword_one_row}}
                         {{/each}}
                     {{/if}}
 
-                    {{#if aPlace.parentof_lines}}
+                    {{#if aPlace.hierarchy}}
                         {{> partial_h2 'Parent Of'}}
 
-                        {{#each aPlace.parentof_lines as |lines type|}}
+                        {{#each aPlace.hierarchy as |lines type|}}
                             {{> partial_h3 type}}
                             {{#each lines}}
                                 {{> partial_details_one_row}}
                             {{/each}}
                         {{/each}}
                     {{/if}}
-                    {{tooManyParentLinesWarning aPlace}}
+                    {{tooManyHierarchyLinesWarning aPlace}}
                 </tbody>
             </table>
         </div>