You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
54 lines
944 B
54 lines
944 B
import request from '@/utils/request' |
|
|
|
// 创建 |
|
export function createWorkHour(data) { |
|
return request({ |
|
url: '/farm/work-hour/create', |
|
method: 'post', |
|
data: data |
|
}) |
|
} |
|
|
|
// 更新 |
|
export function updateWorkHour(data) { |
|
return request({ |
|
url: '/farm/work-hour/update', |
|
method: 'put', |
|
data: data |
|
}) |
|
} |
|
|
|
// 删除 |
|
export function deleteWorkHour(id) { |
|
return request({ |
|
url: '/farm/work-hour/delete?id=' + id, |
|
method: 'delete' |
|
}) |
|
} |
|
|
|
// 获得 |
|
export function getWorkHour(id) { |
|
return request({ |
|
url: '/farm/work-hour/get?id=' + id, |
|
method: 'get' |
|
}) |
|
} |
|
|
|
// 获得分页 |
|
export function getWorkHourPage(query) { |
|
return request({ |
|
url: '/farm/work-hour/page', |
|
method: 'get', |
|
params: query |
|
}) |
|
} |
|
|
|
// 导出 Excel |
|
export function exportWorkHourExcel(query) { |
|
return request({ |
|
url: '/farm/work-hour/export-excel', |
|
method: 'get', |
|
params: query, |
|
responseType: 'blob' |
|
}) |
|
}
|
|
|