Merge pull request #4315 from wallabag/add-published-date-epub

Added publication date on epub export
This commit is contained in:
Nicolas Lœuillet 2020-04-06 19:58:33 +02:00 committed by GitHub
commit b283ee0d6d
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
17 changed files with 23 additions and 0 deletions

View file

@ -196,10 +196,17 @@ class EntriesExport
$authors = implode(',', $publishedBy);
}
$publishedAt = $entry->getPublishedAt();
$publishedDate = $this->translator->trans('export.unknown');
if (!empty($publishedAt)) {
$publishedDate = $entry->getPublishedAt()->format('Y-m-d');
}
$titlepage = $content_start .
'<h1>' . $entry->getTitle() . '</h1>' .
'<dl>' .
'<dt>' . $this->translator->trans('entry.view.published_by') . '</dt><dd>' . $authors . '</dd>' .
'<dt>' . $this->translator->trans('entry.metadata.published_on') . '</dt><dd>' . $publishedDate . '</dd>' .
'<dt>' . $this->translator->trans('entry.metadata.reading_time') . '</dt><dd>' . $this->translator->trans('entry.metadata.reading_time_minutes_short', ['%readingTime%' => $entry->getReadingTime()]) . '</dd>' .
'<dt>' . $this->translator->trans('entry.metadata.added_on') . '</dt><dd>' . $entry->getCreatedAt()->format('Y-m-d') . '</dd>' .
'<dt>' . $this->translator->trans('entry.metadata.address') . '</dt><dd><a href="' . $entry->getUrl() . '">' . $entry->getUrl() . '</a></dd>' .

View file

@ -285,6 +285,7 @@ entry:
# reading_time_minutes_short: "%readingTime% min"
# address: "Address"
# added_on: "Added on"
# published_on: "Published on"
about:
page_title: 'Om'

View file

@ -285,6 +285,7 @@ entry:
# reading_time_minutes_short: "%readingTime% min"
# address: "Address"
# added_on: "Added on"
# published_on: "Published on"
about:
page_title: 'Über'

View file

@ -285,6 +285,7 @@ entry:
reading_time_minutes_short: "%readingTime% min"
address: "Address"
added_on: "Added on"
published_on: "Published on"
about:
page_title: 'About'

View file

@ -285,6 +285,7 @@ entry:
reading_time_minutes_short: "%readingTime% min"
address: "Dirección"
added_on: "Añadido el"
# published_on: "Published on"
about:
page_title: 'Acerca de'

View file

@ -285,6 +285,7 @@ entry:
# reading_time_minutes_short: "%readingTime% min"
# address: "Address"
# added_on: "Added on"
# published_on: "Published on"
about:
page_title: 'درباره'

View file

@ -285,6 +285,7 @@ entry:
reading_time_minutes_short: "%readingTime% min"
address: "Adresse"
added_on: "Ajouté le"
published_on: "Publié le"
about:
page_title: "À propos"

View file

@ -285,6 +285,7 @@ entry:
# reading_time_minutes_short: "%readingTime% min"
# address: "Address"
# added_on: "Added on"
# published_on: "Published on"
about:
page_title: 'A proposito'

View file

@ -285,6 +285,7 @@ entry:
reading_time_minutes_short: "%readingTime% 分"
address: "アドレス"
added_on: "追加日"
# published_on: "Published on"
about:
page_title: 'アプリについて'

View file

@ -285,6 +285,7 @@ entry:
reading_time_minutes_short: "%readingTime% min"
address: "Adreça"
added_on: "Ajustat a"
# published_on: "Published on"
about:
page_title: 'A prepaus'

View file

@ -285,6 +285,7 @@ entry:
# reading_time_minutes_short: "%readingTime% min"
# address: "Address"
# added_on: "Added on"
# published_on: "Published on"
about:
page_title: 'O nas'

View file

@ -285,6 +285,7 @@ entry:
reading_time_minutes_short: "%readingTime% min"
address: "Endereço"
added_on: "Adicionado o"
# published_on: "Published on"
about:
page_title: 'Sobre'

View file

@ -285,6 +285,7 @@ entry:
# reading_time_minutes_short: "%readingTime% min"
# address: "Address"
# added_on: "Added on"
# published_on: "Published on"
about:
page_title: 'Despre'

View file

@ -285,6 +285,7 @@ entry:
# reading_time_minutes_short: "%readingTime% min"
# address: "Address"
# added_on: "Added on"
# published_on: "Published on"
about:
page_title: 'О'

View file

@ -285,6 +285,7 @@ entry:
# reading_time_minutes_short: "%readingTime% min"
# address: "Address"
# added_on: "Added on"
# published_on: "Published on"
about:
page_title: 'เกี่ยวกับ'

View file

@ -285,6 +285,7 @@ entry:
# reading_time_minutes_short: "%readingTime% min"
# address: "Address"
# added_on: "Added on"
# published_on: "Published on"
about:
page_title: 'Hakkımızda'

View file

@ -285,6 +285,7 @@ entry:
reading_time_minutes_short: "%readingTime% 分钟"
address: "地址"
added_on: "添加于"
# published_on: "Published on"
about:
page_title: '关于'