|
|
@ -316,19 +316,6 @@ function editFilter(id) {
|
|
|
|
dialog.show();
|
|
|
|
dialog.show();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
function getSelectedLabels() {
|
|
|
|
|
|
|
|
const tree = dijit.byId("labelTree");
|
|
|
|
|
|
|
|
const items = tree.model.getCheckedItems();
|
|
|
|
|
|
|
|
const rv = [];
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
items.each(function(item) {
|
|
|
|
|
|
|
|
rv.push(tree.model.store.getValue(item, 'bare_id'));
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
return rv;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
function getSelectedUsers() {
|
|
|
|
function getSelectedUsers() {
|
|
|
|
return Tables.getSelected("prefUserList");
|
|
|
|
return Tables.getSelected("prefUserList");
|
|
|
|
}
|
|
|
|
}
|
|
|
@ -372,28 +359,6 @@ function getSelectedFilters() {
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
function removeSelectedLabels() {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
const sel_rows = getSelectedLabels();
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (sel_rows.length > 0) {
|
|
|
|
|
|
|
|
if (confirm(__("Remove selected labels?"))) {
|
|
|
|
|
|
|
|
notify_progress("Removing selected labels...");
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
const query = { op: "pref-labels", method: "remove",
|
|
|
|
|
|
|
|
ids: sel_rows.toString() };
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
xhrPost("backend.php", query, () => {
|
|
|
|
|
|
|
|
updateLabelList();
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
} else {
|
|
|
|
|
|
|
|
alert(__("No labels are selected."));
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
return false;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
function removeSelectedUsers() {
|
|
|
|
function removeSelectedUsers() {
|
|
|
|
|
|
|
|
|
|
|
|
const sel_rows = getSelectedUsers();
|
|
|
|
const sel_rows = getSelectedUsers();
|
|
|
@ -906,25 +871,6 @@ function opmlRegenKey() {
|
|
|
|
return false;
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
function labelColorReset() {
|
|
|
|
|
|
|
|
const labels = getSelectedLabels();
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (labels.length > 0) {
|
|
|
|
|
|
|
|
if (confirm(__("Reset selected labels to default colors?"))) {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
const query = { op: "pref-labels", method: "colorreset",
|
|
|
|
|
|
|
|
ids: labels.toString() };
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
xhrPost("backend.php", query, () => {
|
|
|
|
|
|
|
|
updateLabelList();
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
} else {
|
|
|
|
|
|
|
|
alert(__("No labels are selected."));
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
function editProfiles() {
|
|
|
|
function editProfiles() {
|
|
|
|
|
|
|
|
|
|
|
|
if (dijit.byId("profileEditDlg"))
|
|
|
|
if (dijit.byId("profileEditDlg"))
|
|
|
|