From ea8df827cedacbb7225d92ce143900ea80de7744 Mon Sep 17 00:00:00 2001
From: blavenie <benoit.lavenier@e-is.pro>
Date: Thu, 3 Jan 2019 11:59:41 +0100
Subject: [PATCH] [fix] Profile: city must be required if street has been
 filled

---
 doc/changelog/changelog_v1.3.1.md                  |  7 ++++++-
 platforms/desktop                                  |  2 +-
 www/plugins/es/i18n/locale-en-GB.json              |  1 +
 www/plugins/es/i18n/locale-en.json                 |  1 +
 www/plugins/es/i18n/locale-es-ES.json              |  1 +
 www/plugins/es/i18n/locale-fr-FR.json              |  1 +
 www/plugins/es/templates/common/edit_position.html | 10 +++++++++-
 7 files changed, 20 insertions(+), 3 deletions(-)

diff --git a/doc/changelog/changelog_v1.3.1.md b/doc/changelog/changelog_v1.3.1.md
index f34401ec..5a53b09c 100644
--- a/doc/changelog/changelog_v1.3.1.md
+++ b/doc/changelog/changelog_v1.3.1.md
@@ -1,5 +1,10 @@
 # Version v1.3.0
 
+# Version v1.3.0
+
 ## Desktop version
 
-- Fix error "Expected buffer" when authenticate - fix #790
\ No newline at end of file
+- [enh] Display logs in terminal
+- [enh] Add option `--debug` to show debug logs
+- [fix] Fix error "Expected buffer" when authenticate - fix [#790](https://git.duniter.org/clients/cesium-grp/cesium/issues/790)
+- [fix] Do not try to open Dev tools, when NW is not a SDK version (e.g. production mode)
\ No newline at end of file
diff --git a/platforms/desktop b/platforms/desktop
index 51d96307..3273ea59 160000
--- a/platforms/desktop
+++ b/platforms/desktop
@@ -1 +1 @@
-Subproject commit 51d9630735dbb138d8bea53fbeae3f85d33b6681
+Subproject commit 3273ea59ac91cada3450021dc126403bca8f0ab9
diff --git a/www/plugins/es/i18n/locale-en-GB.json b/www/plugins/es/i18n/locale-en-GB.json
index bbe9e86b..8ebf90a9 100644
--- a/www/plugins/es/i18n/locale-en-GB.json
+++ b/www/plugins/es/i18n/locale-en-GB.json
@@ -362,6 +362,7 @@
       "POSITION": "lat/lon : {{lat}} / {{lon}}"
     },
     "ERROR": {
+      "CITY_REQUIRED_IF_STREET": "Required if a street has been filled",
       "REQUIRED_FOR_LOCATION": "Required field to appear on the map",
       "INVALID_FOR_LOCATION": "Unknown address",
       "GEO_LOCATION_FAILED": "Unable to retrieve your current position. Please use the search button.",
diff --git a/www/plugins/es/i18n/locale-en.json b/www/plugins/es/i18n/locale-en.json
index bbe9e86b..8ebf90a9 100644
--- a/www/plugins/es/i18n/locale-en.json
+++ b/www/plugins/es/i18n/locale-en.json
@@ -362,6 +362,7 @@
       "POSITION": "lat/lon : {{lat}} / {{lon}}"
     },
     "ERROR": {
+      "CITY_REQUIRED_IF_STREET": "Required if a street has been filled",
       "REQUIRED_FOR_LOCATION": "Required field to appear on the map",
       "INVALID_FOR_LOCATION": "Unknown address",
       "GEO_LOCATION_FAILED": "Unable to retrieve your current position. Please use the search button.",
diff --git a/www/plugins/es/i18n/locale-es-ES.json b/www/plugins/es/i18n/locale-es-ES.json
index 1702ab27..58d8b4f9 100644
--- a/www/plugins/es/i18n/locale-es-ES.json
+++ b/www/plugins/es/i18n/locale-es-ES.json
@@ -409,6 +409,7 @@
       "POSITION": "Latitud/Longitud : {{lat}} / {{lon}}"
     },
     "ERROR": {
+      "CITY_REQUIRED_IF_STREET": "Requerido si una calle ha sido llenada",
       "REQUIRED_FOR_LOCATION": "Campo obligatorio para aparecer en el mapa",
       "INVALID_FOR_LOCATION": "Dirección desconocida",
       "GEO_LOCATION_FAILED": "No se puede recuperar su ubicación Por favor usa el botón de búsqueda.",
diff --git a/www/plugins/es/i18n/locale-fr-FR.json b/www/plugins/es/i18n/locale-fr-FR.json
index 14a9b96e..5e2ed5fd 100644
--- a/www/plugins/es/i18n/locale-fr-FR.json
+++ b/www/plugins/es/i18n/locale-fr-FR.json
@@ -413,6 +413,7 @@
       "POSITION": "Lat/Lon : {{lat}}/{{lon}}"
     },
     "ERROR": {
+      "CITY_REQUIRED_IF_STREET": "Champ obligatoire (car une rue est saisie)",
       "REQUIRED_FOR_LOCATION": "Champ obligatoire pour apparaître sur la carte",
       "INVALID_FOR_LOCATION": "Adresse inconnue",
       "GEO_LOCATION_FAILED": "Impossible de récupérer votre position. Veuillez utiliser le bouton de recherche.",
diff --git a/www/plugins/es/templates/common/edit_position.html b/www/plugins/es/templates/common/edit_position.html
index 55498187..9c1c538c 100644
--- a/www/plugins/es/templates/common/edit_position.html
+++ b/www/plugins/es/templates/common/edit_position.html
@@ -1,6 +1,6 @@
 <div class="item item-divider" translate>LOCATION.LOCATION_DIVIDER</div>
 
-<!-- address -->
+<!-- street -->
 <ion-item class="item-input item-floating-label item-button-right">
   <span class="input-label">{{'LOCATION.ADDRESS' | translate}}</span>
   <textarea placeholder="{{'LOCATION.ADDRESS_HELP' | translate}}"
@@ -17,6 +17,7 @@
   <input type="text" placeholder="{{'LOCATION.CITY_HELP'|translate}}"
          ng-model="formData.city"
          ng-model-options="{ updateOn: 'blur' }"
+         required-if="formData.address"
          ng-change="onCityChanged()">
 </div>
 <input type="hidden"
@@ -24,6 +25,13 @@
        ng-model="formData.geoPoint"
        required-if="formPosition.enable"
        geo-point>
+<div class="form-errors"
+     ng-show="form.$submitted && form.city.$error"
+     ng-messages="form.city.$error">
+  <div class="form-error" ng-message="required">
+    <span translate="LOCATION.ERROR.CITY_REQUIRED_IF_STREET"></span>
+  </div>
+</div>
 <div class="form-errors"
      ng-show="form.$submitted && form.geoPoint.$error"
      ng-messages="form.geoPoint.$error">
-- 
GitLab