mirror of
https://github.com/siyuan-note/siyuan.git
synced 2026-01-04 15:58:49 +01:00
This commit is contained in:
parent
06a504487b
commit
6ecf512a73
1 changed files with 9 additions and 8 deletions
|
|
@ -432,14 +432,15 @@ export const openHistory = () => {
|
|||
});
|
||||
break;
|
||||
} else if (type === "removeRepoTagSnapshot" || type === "removeCloudRepoTagSnapshot") {
|
||||
fetchPost("/api/repo/" + type, {
|
||||
tag: target.parentElement.getAttribute("data-tag")
|
||||
}, () => {
|
||||
if (target.parentElement.parentElement.childElementCount === 1) {
|
||||
target.parentElement.parentElement.innerHTML = `<li class="b3-list--empty">${window.siyuan.languages.emptyContent}</li>`
|
||||
} else {
|
||||
target.parentElement.remove();
|
||||
}
|
||||
const tag = target.parentElement.getAttribute("data-tag");
|
||||
confirmDialog(window.siyuan.languages.delete, `${window.siyuan.languages.confirmDelete} <i>${tag}</i>?`, () => {
|
||||
fetchPost("/api/repo/" + type, {tag}, () => {
|
||||
if (target.parentElement.parentElement.childElementCount === 1) {
|
||||
target.parentElement.parentElement.innerHTML = `<li class="b3-list--empty">${window.siyuan.languages.emptyContent}</li>`
|
||||
} else {
|
||||
target.parentElement.remove();
|
||||
}
|
||||
});
|
||||
});
|
||||
} else if (type === "uploadSnapshot") {
|
||||
fetchPost("/api/repo/uploadCloudSnapshot", {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue