init
This commit is contained in:
@@ -0,0 +1,9 @@
|
||||
import http from './index'
|
||||
|
||||
export const templateApi = {
|
||||
list: (params?: any) => http.get('/templates', { params }),
|
||||
get: (id: number) => http.get(`/templates/${id}`),
|
||||
upload: (formData: FormData) => http.post('/templates/upload', formData, { headers: { 'Content-Type': 'multipart/form-data' } }),
|
||||
saveParagraphs: (id: number, data: any) => http.put(`/templates/${id}/paragraphs`, data),
|
||||
delete: (id: number) => http.delete(`/templates/${id}`),
|
||||
}
|
||||
Reference in New Issue
Block a user