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

const request = (url, ...arg) => baseRequest(`/biz/depotTruckBook/` + url, ...arg)

/**
 * 车辆预约表Api接口管理器
 *
 * @author xiang
 * @date  2023/09/13 09:21
 **/
export default {
	// 获取车辆预约表分页
	depotTruckBookPage(data) {
		return request('page', data, 'get')
	},
	// 获取车辆预约表列表
	depotTruckBookList(data) {
		return request('list', data, 'get')
	},
	// 提交车辆预约表表单 edit为true时为编辑，默认为新增
	depotTruckBookSubmitForm(data, edit = false) {
		return request(edit ? 'add' : 'edit', data)
	},
	// 提交车辆预约表一级审批
	depotOpApproval(data) {
		return request('depotOpApproval', data)
	},
	// 删除车辆预约表
	depotTruckBookDelete(data) {
		return request('delete', data)
	},
	// 获取车辆预约表详情
	depotTruckBookDetail(data) {
		return request('detail', data, 'get')
	}
}
