mirror of
https://github.com/usememos/memos.git
synced 2025-06-05 22:09:59 +02:00
feat: storage service frontend (#1088)
This commit is contained in:
@ -206,6 +206,22 @@ export function deleteTag(tagName: string) {
|
||||
});
|
||||
}
|
||||
|
||||
export function getStorageList() {
|
||||
return axios.get<ResponseObject<Storage[]>>(`/api/storage`);
|
||||
}
|
||||
|
||||
export function createStorage(storageCreate: StorageCreate) {
|
||||
return axios.post<ResponseObject<Storage>>(`/api/storage`, storageCreate);
|
||||
}
|
||||
|
||||
export function patchStorage(storagePatch: StoragePatch) {
|
||||
return axios.patch<ResponseObject<Storage>>(`/api/storage/${storagePatch.id}`, storagePatch);
|
||||
}
|
||||
|
||||
export function deleteStorage(storageId: StorageId) {
|
||||
return axios.delete(`/api/storage/${storageId}`);
|
||||
}
|
||||
|
||||
export async function getRepoStarCount() {
|
||||
const { data } = await axios.get(`https://api.github.com/repos/usememos/memos`, {
|
||||
headers: {
|
||||
|
Reference in New Issue
Block a user