新增到出Excel
This commit is contained in:
parent
5399381076
commit
b5112d6224
@ -22,7 +22,7 @@ export interface EcganalysisparasVO {
|
|||||||
autoDiagResult: string // 算法自动诊断结果
|
autoDiagResult: string // 算法自动诊断结果
|
||||||
autoDiagTime: Date // 自动诊断的时间
|
autoDiagTime: Date // 自动诊断的时间
|
||||||
doctorDiagResult: string // 医生诊断结果
|
doctorDiagResult: string // 医生诊断结果
|
||||||
doctorDiagTime: string // 医生诊断的时间
|
doctorDiagTime: Date // 医生诊断的时间
|
||||||
doctorName: string // 诊断医生的姓名
|
doctorName: string // 诊断医生的姓名
|
||||||
doctorId: string // 诊断医生的医生id
|
doctorId: string // 诊断医生的医生id
|
||||||
departId: string // 诊断医生的科室id
|
departId: string // 诊断医生的科室id
|
||||||
@ -85,4 +85,8 @@ export const EcganalysisparasApi = {
|
|||||||
getDateStaAndEndData: async (doctorName:String,startDate:String,endDate:String) => {
|
getDateStaAndEndData: async (doctorName:String,startDate:String,endDate:String) => {
|
||||||
return await request.get({ url: `/tblist/ecganalysisparas/getDateStaAndEndData?doctorName=${doctorName}&TimeSta=${startDate}&TimeEnd=${endDate}` })
|
return await request.get({ url: `/tblist/ecganalysisparas/getDateStaAndEndData?doctorName=${doctorName}&TimeSta=${startDate}&TimeEnd=${endDate}` })
|
||||||
},
|
},
|
||||||
|
// 添加导出Excel的方法
|
||||||
|
exportWorkloadExcel: async (startTime:String,endTime:String) => {
|
||||||
|
return await request.download({ url: `/tblist/ecganalysisparas/export-workload-excel?startTime=${startTime}&endTime=${endTime} ` })
|
||||||
|
},
|
||||||
}
|
}
|
||||||
|
@ -15,6 +15,7 @@
|
|||||||
{{ chartType === 'line' ? '切换为柱状图' : '切换为折线图' }}
|
{{ chartType === 'line' ? '切换为柱状图' : '切换为折线图' }}
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button style="margin-left: 20px" @click="getdata()">查询</el-button>
|
<el-button style="margin-left: 20px" @click="getdata()">查询</el-button>
|
||||||
|
<el-button style="margin-left: 20px" @click="exportData()">导出</el-button>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</ContentWrap>
|
</ContentWrap>
|
||||||
@ -27,6 +28,7 @@
|
|||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import * as echarts from 'echarts'
|
import * as echarts from 'echarts'
|
||||||
import { ref } from 'vue'
|
import { ref } from 'vue'
|
||||||
|
import download from '@/utils/download'
|
||||||
import { EcganalysisparasApi } from '@/api/tblist/ecganalysisparas'
|
import { EcganalysisparasApi } from '@/api/tblist/ecganalysisparas'
|
||||||
import { getUserProfile, ProfileVO } from '@/api/system/user/profile'
|
import { getUserProfile, ProfileVO } from '@/api/system/user/profile'
|
||||||
const Profilevo = ref<ProfileVO>({} as ProfileVO) //当前登录人信息
|
const Profilevo = ref<ProfileVO>({} as ProfileVO) //当前登录人信息
|
||||||
@ -36,7 +38,12 @@ const Date_value = ref<[Date, Date]>([startDate, endDate])
|
|||||||
const getlogininfo = async () => {
|
const getlogininfo = async () => {
|
||||||
Profilevo.value = await getUserProfile()
|
Profilevo.value = await getUserProfile()
|
||||||
}
|
}
|
||||||
|
async function exportData(){
|
||||||
|
const startDate = `${formatDate(Date_value.value[0])} 00:00:00`
|
||||||
|
const endDate = `${formatDate(Date_value.value[1])} 23:59:59`
|
||||||
|
const data=await EcganalysisparasApi.exportWorkloadExcel( startDate, endDate)
|
||||||
|
download.excel(data, '工作量统计.xls')
|
||||||
|
}
|
||||||
const defaultTime = ref<[Date, Date]>([
|
const defaultTime = ref<[Date, Date]>([
|
||||||
new Date(2000, 1, 1, 0, 0, 0),
|
new Date(2000, 1, 1, 0, 0, 0),
|
||||||
new Date(2000, 2, 1, 23, 59, 59)
|
new Date(2000, 2, 1, 23, 59, 59)
|
||||||
|
Loading…
Reference in New Issue
Block a user