mirror of
https://github.com/usememos/memos.git
synced 2025-06-05 22:09:59 +02:00
chore: update tag service
This commit is contained in:
@ -155,26 +155,10 @@ export function deleteResourceById(id: ResourceId) {
|
||||
return axios.delete(`/api/v1/resource/${id}`);
|
||||
}
|
||||
|
||||
export function getTagList() {
|
||||
return axios.get<string[]>(`/api/v1/tag`);
|
||||
}
|
||||
|
||||
export function getTagSuggestionList() {
|
||||
return axios.get<string[]>(`/api/v1/tag/suggestion`);
|
||||
}
|
||||
|
||||
export function upsertTag(tagName: string) {
|
||||
return axios.post<string>(`/api/v1/tag`, {
|
||||
name: tagName,
|
||||
});
|
||||
}
|
||||
|
||||
export function deleteTag(tagName: string) {
|
||||
return axios.post(`/api/v1/tag/delete`, {
|
||||
name: tagName,
|
||||
});
|
||||
}
|
||||
|
||||
export function getStorageList() {
|
||||
return axios.get<ObjectStorage[]>(`/api/v1/storage`);
|
||||
}
|
||||
|
Reference in New Issue
Block a user