import { baseRequest } from '@/utils/newRequest'

const request = (url, ...arg) => baseRequest(`/api/webapp/` + url, ...arg)

export default {
	// 获取章节列表
	page(data) {
		return request('disk/chapter/page', data, 'get')
	},
	// 章节添加
	add(data) {
		return request('disk/chapter/add', data, 'post')
	},
	// 章节编辑
	edit(data) {
		return request('disk/chapter/edit', data, 'post')
	},
	delete(data) {
		return request('disk/chapter/delete', data, 'post')
	},
	// 章节详情
	detail(data) {
		return request('disk/chapter/detail', data, 'get')
	},
	allList(data) {
		return request('disk/chapter/allList', data, 'get')
	}
}
