mirror of
https://github.com/siyuan-note/siyuan.git
synced 2026-02-18 04:58:06 +01:00
🎨 公测云端同步数据仓库 https://github.com/siyuan-note/siyuan/issues/5337
This commit is contained in:
parent
5e8ca37d75
commit
fc5895091a
2 changed files with 14 additions and 2 deletions
|
|
@ -518,8 +518,16 @@ ${passwordHTML}
|
|||
target.parentElement.setAttribute("disabled", "disabled");
|
||||
fetchPost("/api/sync/getSyncDirection", {name: target.getAttribute("data-name")}, (response) => {
|
||||
target.parentElement.removeAttribute("disabled");
|
||||
const name = target.getAttribute("data-name");
|
||||
if (40 == response.code) { // 使用数据仓库同步不需要对比同步方向
|
||||
fetchPost("/api/sync/setCloudSyncDir", {name}, () => {
|
||||
window.siyuan.config.sync.cloudName = name;
|
||||
getCloudList(true);
|
||||
});
|
||||
return
|
||||
}
|
||||
|
||||
confirmDialog(window.siyuan.languages.confirm, response.msg, () => {
|
||||
const name = target.getAttribute("data-name");
|
||||
fetchPost("/api/sync/setCloudSyncDir", {name}, () => {
|
||||
window.siyuan.config.sync.cloudName = name;
|
||||
getCloudList(true);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue