Merge branch 'more-localization' into 'master'

More localization

See merge request phyks/Flatisfy!36
This commit is contained in:
Phyks 2018-12-26 10:43:14 +01:00
commit a21b0ef7bd
4 changed files with 13 additions and 3 deletions

View File

@ -41,12 +41,15 @@ export default {
'utilities_included': '(utilities included)',
'utilities_excluded': '(utilities excluded)',
'Description': 'Description',
'First_posted' : 'First posted',
'Details': 'Details',
'Metadata': 'Metadata',
'postal_code': 'Postal code',
'nearby_stations': 'Nearby stations',
'Times_to': 'Times to',
'Location': 'Location',
'Notes': 'Notes',
'Save': 'Save',
'Contact': 'Contact',
'Visit': 'Visit',
'setDateOfVisit': 'Set date of visit',

View File

@ -41,12 +41,15 @@ export default {
'utilities_included': '(charges comprises)',
'utilities_excluded': '(charges non comprises)',
'Description': 'Description',
'First_posted': 'Posté pour la première fois',
'Details': 'Détails',
'Metadata': 'Metadonnées',
'postal_code': 'Code postal',
'nearby_stations': 'Stations proches',
'Times_to': 'Temps jusqu\'à',
'Location': 'Localisation',
'Notes': 'Notes',
'Save': 'Sauvegarder',
'Contact': 'Contact',
'Visit': 'Visite',
'setDateOfVisit': 'Entrer une date de visite',

View File

@ -1,5 +1,6 @@
import Vue from 'vue'
import VueI18n from 'vue-i18n'
import moment from 'moment'
// Import translations
import en from './en'
@ -48,6 +49,9 @@ for (var i = 0; i < locales.length; ++i) {
}
}
// Set the locale for Moment.js
moment.locale(locale)
export default new VueI18n({
locale: locale,
messages

View File

@ -40,7 +40,7 @@
<h3>{{ $t("flatsDetails.Description") }}</h3>
<p>{{ flat.text }}</p>
<p class="right">{{ flat.location }}</p>
<p>First posted {{ flat.date ? flat.date.fromNow() : '?' }}.</p>
<p>{{ $t("flatsDetails.First_posted") }} {{ flat.date ? flat.date.fromNow() : '?' }}.</p>
</div>
<div>
<h3>{{ $t("flatsDetails.Details") }}</h3>
@ -114,11 +114,11 @@
<FlatsMap :flats="flatMarkers" :places="timeToPlaces" :journeys="journeys"></FlatsMap>
</div>
<div>
<h3>Notes</h3>
<h3>{{ $t("flatsDetails.Notes") }}</h3>
<form v-on:submit="updateFlatNotes">
<textarea ref="notesTextarea" rows="10">{{ flat.notes }}</textarea>
<p class="right"><input type="submit" value="Save"/></p>
<p class="right"><input type="submit" :value="$t('flatsDetails.Save')"/></p>
</form>
</div>
</div>