计划数据导出功能问题解决,新增查询loading功能
| | |
| | | |
| | | // 导出Plan值 |
| | | export const exportPlanValue = (data: PlanChartReqVO) => { |
| | | return request.post({ url: '/data/api/export-plan/history-value', data }) |
| | | return request.downloadByPost({ url: '/data/api/export-plan/history-value', data }) |
| | | } |
| | |
| | | const res = await request({ method: 'GET', responseType: 'blob', ...option }) |
| | | return res as unknown as Promise<T> |
| | | }, |
| | | downloadByPost: async <T = any>(option: any) => { |
| | | const res = await request({ method: 'POST', responseType: 'blob', ...option }) |
| | | return res as unknown as Promise<T> |
| | | }, |
| | | upload: async <T = any>(option: any) => { |
| | | option.headersType = 'multipart/form-data' |
| | | const res = await request({ method: 'POST', ...option }) |
| | |
| | | </el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | <div ref="chartDomPlan" class="result-chart"></div> |
| | | <div ref="chartDomPlan" class="result-chart" v-loading="loading"></div> |
| | | </el-dialog> |
| | | </template> |
| | | |
| | |
| | | start: undefined, |
| | | end: undefined, |
| | | }) |
| | | const loading = ref(true) // 列表的加载中 |
| | | |
| | | function getYMDHMS() { |
| | | let timestamp = new Date().getTime(); |
| | |
| | | |
| | | async function getDataList() { |
| | | visible.value = true; |
| | | loading.value = true |
| | | if (dataForm.value.id) { |
| | | try { |
| | | queryParams.itemNos = [dataForm.value.itemNo]; |
| | | queryParams.start = dataForm.value.startTime; |
| | | queryParams.end = dataForm.value.endTime; |
| | | const data = await ItemApi.getPlanChart(queryParams) |
| | | loading.value = false |
| | | let seriesData = [] |
| | | data.series.forEach(item => { |
| | | seriesData.push({ |
| | |
| | | </el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | <div ref="chartDom" class="result-chart"></div> |
| | | <div ref="chartDom" class="result-chart" v-loading="loading"></div> |
| | | </el-dialog> |
| | | </template> |
| | | |
| | |
| | | startTime: getYMDHM0(new Date() - 60 * 60 * 1000), |
| | | endTime: "", |
| | | }); |
| | | |
| | | const loading = ref(true) // 列表的加载中 |
| | | /** 打开弹窗 */ |
| | | const open = async (row: object) => { |
| | | visible.value = true |
| | |
| | | |
| | | async function getDataList() { |
| | | visible.value = true; |
| | | loading.value = true |
| | | if (dataForm.value.id) { |
| | | try { |
| | | chartParams.codes=[dataForm.value.pointNo]; |
| | | chartParams.startDate = dataForm.value.startTime; |
| | | chartParams.endDate = dataForm.value.endTime; |
| | | const data = await DaPoint.getPointDaChart(chartParams) |
| | | loading.value = false |
| | | let seriesData = [] |
| | | data.series.forEach(item => { |
| | | seriesData.push({ |