12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394 |
- import http from '@/api'
- import { ToInfraredVO, ToInfraredForm, ToInfraredQuery } from '@/api/interface/demo/toInfrared'
- /**
- * @name 查询可见光转红外列表
- * @param query 参数
- * @returns 返回列表
- */
- export const listToInfraredApi = (query: ToInfraredQuery) => {
- return http.get<ToInfraredVO[]>('/demo/toInfrared/list', query, { loading: true })
- }
- /**
- * @name 查询可见光转红外详细
- * @param id id
- * @returns returns
- */
- export const getToInfraredApi = (id: string | number) => {
- return http.get<ToInfraredVO>(`/demo/toInfrared/${id}`)
- }
- /**
- * @name 新增可见光转红外
- * @param data data
- * @returns returns
- */
- export const addToInfraredApi = (data: ToInfraredForm) => {
- return http.post<any>('/demo/toInfrared', data, { loading: true })
- }
- /**
- * @name 修改可见光转红外
- * @param data data
- * @returns returns
- */
- export const updateToInfraredApi = (data: ToInfraredForm) => {
- return http.put<any>('/demo/toInfrared', data, { loading: true })
- }
- /**
- * @name 删除可见光转红外
- * @param id id
- * @returns returns
- */
- export const delToInfraredApi = (id: string | number | Array<string | number>) => {
- return http.delete<any>(`/demo/toInfrared/${id}`)
- }
- /**
- * @name 下载模板
- * @returns returns
- */
- export const importTemplateApi = () => {
- return http.downloadPost('/demo/toInfrared/importTemplate', {})
- }
- /**
- * @name 导入数据
- * @returns returns
- */
- export const importToInfraredDataApi = (data: any) => {
- return http.post('/demo/toInfrared/importData', data)
- }
- /**
- * @name 导出数据
- * @returns returns
- */
- export const exportToInfraredApi = (data: any) => {
- return http.downloadPost('/demo/toInfrared/export', data)
- }
- export const startToInfraredApi = (id: string | number) => {
- return http.get('/demo/toInfrared/start/' + id)
- }
- export const stopToInfraredApi = (id: string | number) => {
- return http.get('/demo/toInfrared/stop/' + id)
- }
- /**
- * @name 下载压缩包
- * @returns returns
- */
- export const dowloadToInfraredApi = (id: string | number): Promise<any> => {
- return http.downloadGet('/demo/toInfrared/zip/' + id)
- }
- export const getLogToInfraredApi = (id: string | number) => {
- return http.get('/demo/toInfrared/log/' + id, {}, { loading: false })
- }
- export const showToInfraredModelApi = (id: string | number) => {
- return http.get('/demo/toInfrared/model/' + id, {}, { loading: false })
- }
|