mirror of
https://git.tt-rss.org/fox/tt-rss.git
synced 2025-08-05 21:57:24 +02:00
Merge branch 'feature/article-display-url-skip-request' into 'master'
Use existing headline info for 'Article.displayUrl()' See merge request tt-rss/tt-rss!164
This commit is contained in:
commit
d3599707ac
@ -123,15 +123,12 @@ const Article = {
|
|||||||
Article.setActive(0);
|
Article.setActive(0);
|
||||||
},
|
},
|
||||||
displayUrl: function (id) {
|
displayUrl: function (id) {
|
||||||
const query = {op: "Article", method: "getmetadatabyid", id: id};
|
const hl = Headlines.objectById(id);
|
||||||
|
|
||||||
xhr.json("backend.php", query, (reply) => {
|
if (hl?.link)
|
||||||
if (reply && reply.link) {
|
prompt(__("Article URL:"), hl.link);
|
||||||
prompt(__("Article URL:"), reply.link);
|
else
|
||||||
} else {
|
alert(__("No URL could be displayed for this article."));
|
||||||
alert(__("No URL could be displayed for this article."));
|
|
||||||
}
|
|
||||||
});
|
|
||||||
},
|
},
|
||||||
openInNewWindow: function (id) {
|
openInNewWindow: function (id) {
|
||||||
/* global __csrf_token */
|
/* global __csrf_token */
|
||||||
|
Loading…
Reference in New Issue
Block a user