From 74a752879bcad54daa62994f9eae42fe4afdd299 Mon Sep 17 00:00:00 2001 From: Andrew Dolgov Date: Wed, 25 Nov 2015 21:07:24 +0300 Subject: af_sort_bayes: move to -attic repo, not really suitable for production use of any kind --- plugins/af_sort_bayes/init.js | 81 ------------------------------------------- 1 file changed, 81 deletions(-) delete mode 100644 plugins/af_sort_bayes/init.js (limited to 'plugins/af_sort_bayes/init.js') diff --git a/plugins/af_sort_bayes/init.js b/plugins/af_sort_bayes/init.js deleted file mode 100644 index bb6bf5954..000000000 --- a/plugins/af_sort_bayes/init.js +++ /dev/null @@ -1,81 +0,0 @@ -function bayesTrain(id, train_up, event) { - try { - - event.stopPropagation(); - - var query = "backend.php?op=pluginhandler&plugin=af_sort_bayes&method=trainArticle&article_id=" + param_escape(id) + - "&train_up=" + param_escape(train_up); - - notify_progress("Loading, please wait..."); - - new Ajax.Request("backend.php", { - parameters: query, - onComplete: function(transport) { - notify(transport.responseText); - updateScore(id); - } }); - - } catch (e) { - exception_error("showTrgmRelated", e); - } -} - -function bayesClearDatabase() { - try { - - if (confirm(__("Clear classifier database?"))) { - - var query = "backend.php?op=pluginhandler&plugin=af_sort_bayes&method=clearDatabase"; - - new Ajax.Request("backend.php", { - parameters: query, - onComplete: function (transport) { - notify(transport.responseText); - bayesUpdateUI(); - } - }); - } - - } catch (e) { - exception_error("showTrgmRelated", e); - } -} - -function bayesUpdateUI() { - try { - - var query = "backend.php?op=pluginhandler&plugin=af_sort_bayes&method=renderPrefsUI"; - - new Ajax.Request("backend.php", { - parameters: query, - onComplete: function (transport) { - dijit.byId("af_sort_bayes_prefs").attr("content", transport.responseText); - } - }); - - } catch (e) { - exception_error("showTrgmRelated", e); - } -} - -function bayesShow(id) { - try { - if (dijit.byId("bayesShowDlg")) - dijit.byId("bayesShowDlg").destroyRecursive(); - - var query = "backend.php?op=pluginhandler&plugin=af_sort_bayes&method=showArticleStats&article_id=" + param_escape(id); - - dialog = new dijit.Dialog({ - id: "bayesShowDlg", - title: __("Classifier information"), - style: "width: 600px", - href: query}); - - dialog.show(); - - } catch (e) { - exception_error("shareArticle", e); - } -} - - -- cgit v1.2.3