aboutsummaryrefslogtreecommitdiff
path: root/app/views/helpers
diff options
context:
space:
mode:
authorGravatar Alexandre Alapetite <alexandre@alapetite.fr> 2018-12-22 13:22:20 +0100
committerGravatar GitHub <noreply@github.com> 2018-12-22 13:22:20 +0100
commitf0a359619fa2936d66a2b96dd086d4686e7405fa (patch)
treeddad42a7f6813bd458f39d5203d083daad4cc1c5 /app/views/helpers
parente04804d0f67dd43fd3f072b9a127768ee7b7b56c (diff)
parent4a1a852f457d52fa47191e3f7e3e9073e1324cd9 (diff)
Merge pull request #2186 from FreshRSS/dev1.13.0
FreshRSS 1.13.0
Diffstat (limited to 'app/views/helpers')
-rw-r--r--app/views/helpers/export/articles.phtml18
-rw-r--r--app/views/helpers/feed/update.phtml2
-rw-r--r--app/views/helpers/index/normal/entry_bottom.phtml2
-rw-r--r--app/views/helpers/javascript_vars.phtml2
4 files changed, 20 insertions, 4 deletions
diff --git a/app/views/helpers/export/articles.phtml b/app/views/helpers/export/articles.phtml
index b8958f527..59a2c7ad7 100644
--- a/app/views/helpers/export/articles.phtml
+++ b/app/views/helpers/export/articles.phtml
@@ -16,6 +16,12 @@ $articles = array(
echo rtrim(json_encode($articles, $options), " ]}\n\r\t"), "\n";
$first = true;
+$tagDAO = FreshRSS_Factory::createTagDao();
+$entryIdsTagNames = $tagDAO->getEntryIdsTagNames($this->entriesRaw);
+if ($entryIdsTagNames == false) {
+ $entryIdsTagNames = array();
+}
+
foreach ($this->entriesRaw as $entryRaw) {
if (empty($entryRaw)) {
continue;
@@ -32,13 +38,14 @@ foreach ($this->entriesRaw as $entryRaw) {
$article = array(
'id' => $entry->guid(),
+ 'timestampUsec' => '' . $entry->id(),
'categories' => array_values($entry->tags()),
'title' => $entry->title(),
- 'author' => $entry->authors(true), //TODO: Make an array like tags?
+ 'author' => $entry->authors(true),
'published' => $entry->date(true),
'updated' => $entry->date(true),
'alternate' => array(array(
- 'href' => $entry->link(),
+ 'href' => htmlspecialchars_decode($entry->link(), ENT_QUOTES),
'type' => 'text/html',
)),
'content' => array(
@@ -51,6 +58,13 @@ foreach ($this->entriesRaw as $entryRaw) {
'feedUrl' => $feed == null ? '' : $feed->url(),
)
);
+ if ($entry->isFavorite()) {
+ $article['categories'][] = 'user/-/state/com.google/starred';
+ }
+ $tagNames = isset($entryIdsTagNames['e_' . $entry->id()]) ? $entryIdsTagNames['e_' . $entry->id()] : array();
+ foreach ($tagNames as $tagName) {
+ $article['categories'][] = 'user/-/label/' . $tagName;
+ }
$line = json_encode($article, $options);
if ($line != '') {
diff --git a/app/views/helpers/feed/update.phtml b/app/views/helpers/feed/update.phtml
index 4dbaacd04..bc90ba456 100644
--- a/app/views/helpers/feed/update.phtml
+++ b/app/views/helpers/feed/update.phtml
@@ -133,7 +133,7 @@
</div>
</div>
<div class="form-group">
- <label class="group-name" for="pubsubhubbub"><?php echo _t('sub.feed.pubsubhubbub'); ?></label>
+ <label class="group-name" for="pubsubhubbub"><?php echo _t('sub.feed.websub'); ?></label>
<div class="group-controls">
<label class="checkbox" for="pubsubhubbub">
<input type="checkbox" name="pubsubhubbub" id="pubsubhubbub" disabled="disabled" value="1"<?php echo $this->feed->pubSubHubbubEnabled() ? ' checked="checked"' : ''; ?> />
diff --git a/app/views/helpers/index/normal/entry_bottom.phtml b/app/views/helpers/index/normal/entry_bottom.phtml
index 784a41e1f..1f35318e3 100644
--- a/app/views/helpers/index/normal/entry_bottom.phtml
+++ b/app/views/helpers/index/normal/entry_bottom.phtml
@@ -42,7 +42,7 @@
<a class="dropdown-toggle" href="#dropdown-labels-<?php echo $this->entry->id();?>"><?php
echo _t('index.menu.tags');
?></a>
- <ul class="dropdown-menu">
+ <ul class="dropdown-menu dropdown-menu-scrollable">
<li class="dropdown-close"><a href="#close">❌</a></li>
<!-- Ajax -->
</ul>
diff --git a/app/views/helpers/javascript_vars.phtml b/app/views/helpers/javascript_vars.phtml
index d7b3e4360..a434a04a3 100644
--- a/app/views/helpers/javascript_vars.phtml
+++ b/app/views/helpers/javascript_vars.phtml
@@ -26,6 +26,8 @@ echo htmlspecialchars(json_encode(array(
'go_website' => @$s['go_website'],
'prev_entry' => @$s['prev_entry'],
'next_entry' => @$s['next_entry'],
+ 'skip_prev_entry' => @$s['skip_prev_entry'],
+ 'skip_next_entry' => @$s['skip_next_entry'],
'first_entry' => @$s['first_entry'],
'last_entry' => @$s['last_entry'],
'collapse_entry' => @$s['collapse_entry'],