onenote 式样修改

This commit is contained in:
simple321vip
2023-02-06 08:47:28 +08:00
parent 86f63ff973
commit d07abaa7b5
6 changed files with 349 additions and 395 deletions
+43 -10
View File
@@ -1,10 +1,49 @@
import { service } from '../utils/request'
const get_notes = (params: Object) => {
const get_categorys = () => {
return service({
url: '/onenote/api/v1/one_note',
url: '/onenote/api/v1/category',
method: 'GET',
params: params
})
}
const get_items = (category_id: string) => {
return service({
url: '/onenote/api/v1/' + category_id + '/items/',
method: 'GET',
})
}
const put_category = (data: Object) => {
return service({
url: '/onenote/api/v1/category',
method: 'PUT',
data: data
})
}
const put_item = (data: Object) => {
return service({
url: '/onenote/api/v1/item',
method: 'PUT',
data: data
})
}
const post_item = (data: Object) => {
return service({
url: '/onenote/api/v1/item',
method: 'post',
data: data
})
}
const delete_item = (data: Object) => {
return service({
url: '/onenote/api/v1/item',
method: 'delete',
data: data
})
}
@@ -24,12 +63,6 @@ const update_section = (params: Object) => {
})
}
const insert_section = () => {
return service({
url: '/onenote/api/v1/one_note/insert_section',
method: 'PUT'
})
}
const insert_page = (params: Object) => {
return service({
@@ -39,4 +72,4 @@ const insert_page = (params: Object) => {
})
}
export { get_notes, update_page, update_section, insert_section, insert_page }
export { get_categorys, get_items, update_page, update_section, put_category, put_item, post_item, delete_item, insert_page }