summaryrefslogtreecommitdiffstats
path: root/apps
diff options
context:
space:
mode:
authorJohannes Merkel <mail@johannesgge.de>2023-06-16 14:29:26 +0200
committernextcloud-command <nextcloud-command@users.noreply.github.com>2023-07-07 15:16:58 +0000
commitdb8da6a571e1b67a8513b267a7d2677fb75fbf5f (patch)
tree25b2d4e808e11d15927da540d0726e895760c28d /apps
parentd2be510ff134bd5934c2857be82027945bf081c9 (diff)
downloadnextcloud-server-db8da6a571e1b67a8513b267a7d2677fb75fbf5f.tar.gz
nextcloud-server-db8da6a571e1b67a8513b267a7d2677fb75fbf5f.zip
fix(sab): put location in proper address field
Signed-off-by: Johannes Merkel <mail@johannesgge.de> Signed-off-by: nextcloud-command <nextcloud-command@users.noreply.github.com>
Diffstat (limited to 'apps')
-rw-r--r--apps/dav/lib/CardDAV/Converter.php14
-rw-r--r--apps/settings/src/components/PersonalInfo/LocationSection.vue2
2 files changed, 14 insertions, 2 deletions
diff --git a/apps/dav/lib/CardDAV/Converter.php b/apps/dav/lib/CardDAV/Converter.php
index c6c8f96308b..254c8015acf 100644
--- a/apps/dav/lib/CardDAV/Converter.php
+++ b/apps/dav/lib/CardDAV/Converter.php
@@ -92,7 +92,19 @@ class Converter {
$vCard->add(new Text($vCard, 'TEL', $property->getValue(), ['TYPE' => 'OTHER', 'X-NC-SCOPE' => $scope]));
break;
case IAccountManager::PROPERTY_ADDRESS:
- $vCard->add(new Text($vCard, 'ADR', $property->getValue(), ['TYPE' => 'OTHER', 'X-NC-SCOPE' => $scope]));
+ // structured prop: https://www.rfc-editor.org/rfc/rfc6350.html#section-6.3.1
+ // post office box;extended address;street address;locality;region;postal code;country
+ $vCard->add(
+ new Text(
+ $vCard,
+ 'ADR',
+ [ '', '', '', $property->getValue(), '', '', '' ],
+ [
+ 'TYPE' => 'OTHER',
+ 'X-NC-SCOPE' => $scope,
+ ]
+ )
+ );
break;
case IAccountManager::PROPERTY_TWITTER:
$vCard->add(new Text($vCard, 'X-SOCIALPROFILE', $property->getValue(), ['TYPE' => 'TWITTER', 'X-NC-SCOPE' => $scope]));
diff --git a/apps/settings/src/components/PersonalInfo/LocationSection.vue b/apps/settings/src/components/PersonalInfo/LocationSection.vue
index ceef7c432cd..57811ddf3b0 100644
--- a/apps/settings/src/components/PersonalInfo/LocationSection.vue
+++ b/apps/settings/src/components/PersonalInfo/LocationSection.vue
@@ -23,7 +23,7 @@
<template>
<AccountPropertySection v-bind.sync="location"
autocomplete="address-level1"
- :placeholder="t('settings', 'Your location')" />
+ :placeholder="t('settings', 'Your city')" />
</template>
<script>