diff -r 5bda901efcf6 -r 2a9ce7ec3a29 src_js/iconolab-bundle/src/components/editor/AnnotationForm.vue --- a/src_js/iconolab-bundle/src/components/editor/AnnotationForm.vue Tue Mar 14 13:30:45 2017 +0100 +++ b/src_js/iconolab-bundle/src/components/editor/AnnotationForm.vue Tue Mar 14 13:41:38 2017 +0100 @@ -34,6 +34,7 @@ @change="onTagsChange($event.tags)"> +

{{ lastRevisionText }}

@@ -45,6 +46,7 @@ import TagList from '../tagform/TagList.vue' import _ from 'lodash' import showdown from 'showdown' + import moment from 'moment' const converter = new showdown.Converter() @@ -91,9 +93,15 @@ } }, computed: { - descriptionComputed: function(){ + descriptionComputed: function() { return converter.makeHtml(this.description); }, + lastRevisionText: function() { + if (this.annotation) { + var date = moment(this.annotation.created).locale('fr'); + return 'Dernière version ' + date.fromNow() + ' par ' + this.annotation.author; + } + }, formAction: function() { if (this.annotation) { return this.action.replace(':annotation_guid', this.annotation.annotation_guid);