offline: toggleCollapseCat() update status in local db
This commit is contained in:
parent
75aa83ec61
commit
c26aa9f0e1
|
@ -400,6 +400,8 @@ function toggleCollapseCat(cat) {
|
|||
new Ajax.Request("backend.php?op=feeds&subop=collapse&cid=" +
|
||||
param_escape(cat));
|
||||
|
||||
local_collapse_cat(cat);
|
||||
|
||||
} catch (e) {
|
||||
exception_error("toggleCollapseCat", e);
|
||||
}
|
||||
|
|
10
offline.js
10
offline.js
|
@ -830,3 +830,13 @@ function gotoOnline() {
|
|||
window.location.href = "tt-rss.php";
|
||||
}
|
||||
|
||||
function local_collapse_cat(id) {
|
||||
try {
|
||||
if (db) {
|
||||
db.execute("UPDATE categories SET collapsed = NOT collapsed WHERE id = ?",
|
||||
[id]);
|
||||
}
|
||||
} catch (e) {
|
||||
exception_error("local_collapse_cat", e);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue