changeset 2779:21eb85cdfe45

Client: improve a set of strings marking for translations * correct strings marking passing to UITabelHeader
author Fadi Abbud <fadi.abbud@intevation.de>
date Fri, 22 Mar 2019 13:26:24 +0100
parents 7ebd4154894e
children 5850ac0f9ab6
files client/src/components/Bottlenecks.vue client/src/components/importoverview/ImportOverview.vue client/src/components/ui/UITableHeader.vue
diffstat 3 files changed, 37 insertions(+), 10 deletions(-) [+]
line wrap: on
line diff
--- a/client/src/components/Bottlenecks.vue	Fri Mar 22 13:21:09 2019 +0100
+++ b/client/src/components/Bottlenecks.vue	Fri Mar 22 13:26:24 2019 +0100
@@ -7,13 +7,13 @@
     />
     <UITableHeader
       :columns="[
-        { id: 'properties.name', title: 'Name', class: 'col-4' },
+        { id: 'properties.name', title: `${nameLabel}`, class: 'col-4' },
         {
           id: 'properties.current',
-          title: 'Latest Measurement',
+          title: `${latestmeasurementLabel}`,
           class: 'col-3'
         },
-        { id: 'properties.from', title: 'Chainage', class: 'col-3' }
+        { id: 'properties.from', title: `${chainageLabel}`, class: 'col-3' }
       ]"
     />
     <UITableBody
@@ -147,6 +147,15 @@
     bottlenecksLabel() {
       return this.$gettext("Bottlenecks");
     },
+    nameLabel() {
+      return this.$gettext("Name");
+    },
+    latestmeasurementLabel() {
+      return this.$gettext("Latest Measurement");
+    },
+    chainageLabel() {
+      return this.$gettext("Chainage");
+    },
     sortIcon() {
       return this.sortDirection === "ASC"
         ? "sort-amount-down"
--- a/client/src/components/importoverview/ImportOverview.vue	Fri Mar 22 13:21:09 2019 +0100
+++ b/client/src/components/importoverview/ImportOverview.vue	Fri Mar 22 13:26:24 2019 +0100
@@ -83,12 +83,12 @@
       </div>
       <UITableHeader
         :columns="[
-          { id: 'id', title: 'Id', width: '79px' },
-          { id: 'kind', title: 'Kind', width: '53px' },
-          { id: 'enqueued', title: 'Enqueued', width: '138px' },
-          { id: 'user', title: 'User', width: '105px' },
-          { id: 'signer', title: 'Signer', width: '105px' },
-          { id: 'state', title: 'Status', width: '72px' },
+          { id: 'id', title: `${idLabel}`, width: '79px' },
+          { id: 'kind', title: `${kindLabel}`, width: '53px' },
+          { id: 'enqueued', title: `${enqueuedLabel}`, width: '138px' },
+          { id: 'user', title: `${userLabel}`, width: '105px' },
+          { id: 'signer', title: `${signerLabel}`, width: '105px' },
+          { id: 'state', title: `${statusLabel}`, width: '72px' },
           { id: 'warnings', icon: 'exclamation-triangle', width: '44px' }
         ]"
       />
@@ -172,6 +172,24 @@
     importReviewLabel() {
       return this.$gettext("Import review");
     },
+    idLabel() {
+      return this.$gettext("Id");
+    },
+    kindLabel() {
+      return this.$gettext("Kind");
+    },
+    enqueuedLabel() {
+      return this.$gettext("Enqueued");
+    },
+    userLabel() {
+      return this.$gettext("User");
+    },
+    signerLabel() {
+      return this.$gettext("Signer");
+    },
+    statusLabel() {
+      return this.$gettext("Status");
+    },
     interval() {
       return [this.startDate, this.endDate];
     }
--- a/client/src/components/ui/UITableHeader.vue	Fri Mar 22 13:21:09 2019 +0100
+++ b/client/src/components/ui/UITableHeader.vue	Fri Mar 22 13:26:24 2019 +0100
@@ -21,7 +21,7 @@
       </span>
       <font-awesome-icon v-if="column.icon" :icon="column.icon" fixed-width />
       <span v-if="column.title">
-        {{ $gettext(column.title) }}
+        {{ column.title }}
       </span>
     </a>
     <div v-if="extraColumnForButtons" class="col"></div>