inspect-front/src/api/inspect/inspectitems/index.ts

55 lines
1.6 KiB
TypeScript
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

import request from '@/config/axios'
// 检查项目 VO
export interface itemsVO {
id: number // 主键
itemName: string // 检查项目名称
itemCode: string // 项目代号
price: number // 项目单价
discountedPrice: number // 折扣价
discounted: number // 折扣 百分比
section: string // 科室
examDescription: string // 检查所见
itemResult: string // 检查结论
unit: string // 项目单位
highValue: number // 取值上限
lowValue: number // 取值下限
createTime: Date // 创建时间
moduleID: number // 模块ID体检单元ID 模块名称ID
moduleName: string // 模块名称:体检单元
sectionID: string // 科室ID
}
// 检查项目 API
export const itemsApi = {
// 查询检查项目分页
getitemsPage: async (params: any) => {
return await request.get({ url: `/inspect/Inspectitems/page`, params })
},
// 查询检查项目详情
getitems: async (id: number) => {
return await request.get({ url: `/inspect/Inspectitems/get?id=` + id })
},
// 新增检查项目
createitems: async (data: itemsVO) => {
return await request.post({ url: `/inspect/Inspectitems/create`, data })
},
// 修改检查项目
updateitems: async (data: itemsVO) => {
return await request.put({ url: `/inspect/Inspectitems/update`, data })
},
// 删除检查项目
deleteitems: async (id: number) => {
return await request.delete({ url: `/inspect/Inspectitems/delete?id=` + id })
},
// 导出检查项目 Excel
exportitems: async (params) => {
return await request.download({ url: `/inspect/Inspectitems/export-excel`, params })
},
}