2013-03-19 14:32:49 +00:00
|
|
|
function mailtoArticle(id) {
|
|
|
|
try {
|
|
|
|
if (!id) {
|
2018-12-02 05:32:13 +00:00
|
|
|
const ids = Headlines.getSelected();
|
2013-03-19 14:32:49 +00:00
|
|
|
|
|
|
|
if (ids.length == 0) {
|
2018-12-02 13:30:32 +00:00
|
|
|
alert(__("No articles selected."));
|
2013-03-19 14:32:49 +00:00
|
|
|
return;
|
|
|
|
}
|
|
|
|
|
|
|
|
id = ids.toString();
|
|
|
|
}
|
|
|
|
|
|
|
|
if (dijit.byId("emailArticleDlg"))
|
|
|
|
dijit.byId("emailArticleDlg").destroyRecursive();
|
|
|
|
|
2018-12-02 17:07:57 +00:00
|
|
|
const query = "backend.php?op=pluginhandler&plugin=mailto&method=emailArticle¶m=" + encodeURIComponent(id);
|
2013-03-19 14:32:49 +00:00
|
|
|
|
|
|
|
dialog = new dijit.Dialog({
|
|
|
|
id: "emailArticleDlg",
|
|
|
|
title: __("Forward article by email"),
|
|
|
|
style: "width: 600px",
|
|
|
|
href: query});
|
|
|
|
|
|
|
|
dialog.show();
|
|
|
|
|
|
|
|
} catch (e) {
|
|
|
|
exception_error("emailArticle", e);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|