12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576 |
- import http from '@/api'
- import {TargetDetectionVO, TargetDetectionForm, TargetDetectionQuery} from '@/api/interface/demo/TargetDetection'
- /**
- * @name 查询目标检测列表
- * @param query 参数
- * @returns 返回列表
- */
- export const listTargetDetectionApi = (query: TargetDetectionQuery) => {
- return http.get<TargetDetectionVO[]>('/demo/TargetDetection/list', query, {loading: true})
- }
- /**
- * @name 查询目标检测详细
- * @param id id
- * @returns returns
- */
- export const getTargetDetectionApi = (id: string | number) => {
- return http.get<TargetDetectionVO>(`/demo/TargetDetection/${id}`)
- }
- /**
- * @name 新增目标检测
- * @param data data
- * @returns returns
- */
- export const addTargetDetectionApi = (data: TargetDetectionForm) => {
- return http.post<any>('/demo/TargetDetection', data, {loading: false})
- }
- /**
- * @name 修改目标检测
- * @param data data
- * @returns returns
- */
- export const updateTargetDetectionApi = (data: TargetDetectionForm) => {
- return http.put<any>('/demo/TargetDetection', data, {loading: false})
- }
- /**
- * @name 删除目标检测
- * @param id id
- * @returns returns
- */
- export const delTargetDetectionApi = (id: string | number | Array<string | number>) => {
- return http.delete<any>(`/demo/TargetDetection/${id}`)
- }
- /**
- * @name 下载模板
- * @returns returns
- */
- export const importTemplateApi = () => {
- return http.downloadPost('/demo/TargetDetection/importTemplate', {})
- }
- /**
- * @name 导入数据
- * @returns returns
- */
- export const importTargetDetectionDataApi = (data: any) => {
- return http.post('/demo/TargetDetection/importData', data)
- }
- /**
- * @name 导出数据
- * @returns returns
- */
- export const exportTargetDetectionApi = (data: any) => {
- return http.downloadPost('/demo/TargetDetection/export', data)
- }
- export const startTargetDetectionApi = (id: string | number) => {
- return http.get<any>(`/demo/TargetDetection/start/${id}`)
- }
|