mirror of
https://git.tt-rss.org/git/tt-rss.git
synced 2025-12-19 00:21:29 +00:00
add button to clear bayes database
This commit is contained in:
@@ -15,3 +15,23 @@ function bayesTrain(id, train_up) {
|
||||
}
|
||||
}
|
||||
|
||||
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);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
} catch (e) {
|
||||
exception_error("showTrgmRelated", e);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user