ecg-form/src/api/processImage/index.ts

32 lines
709 B
TypeScript
Raw Normal View History

2025-05-16 10:27:49 +08:00
import axios from 'axios'
// 超声组件 API
export const processImageApi = {
// 查询模版表数据
paramsList:[{
startX:1800,
startY:100,
height:400,
width:900,
options:{watermarkFontSize:40}
},{}],
processImg: async (params: any) => {
try {
const response = await axios({
method: 'post',
url: 'https://zzxmc.gw12320.com/processImage',
data: params,
headers: {
'Content-Type': 'application/json',
'Access-Control-Allow-Origin': '*'
},
withCredentials: true
})
return response.data
} catch (error) {
console.error('Error fetching image:', error)
throw error
}
}
}