mirror of
https://github.com/casdoor/casdoor.git
synced 2025-07-05 05:50:19 +08:00
feat: add sync button to execute syncer once (#668)
* feat: add sync button to execute syncer once Signed-off-by: Yixiang Zhao <seriouszyx@foxmail.com> * fix: requested changes Signed-off-by: Yixiang Zhao <seriouszyx@foxmail.com> * fix: requested changes Signed-off-by: Yixiang Zhao <seriouszyx@foxmail.com>
This commit is contained in:
@ -54,3 +54,10 @@ export function deleteSyncer(syncer) {
|
||||
body: JSON.stringify(newSyncer),
|
||||
}).then(res => res.json());
|
||||
}
|
||||
|
||||
export function runSyncer(owner, name) {
|
||||
return fetch(`${Setting.ServerUrl}/api/run-syncer?id=${owner}/${encodeURIComponent(name)}`, {
|
||||
method: 'GET',
|
||||
credentials: 'include',
|
||||
}).then(res => res.json());
|
||||
}
|
||||
|
Reference in New Issue
Block a user