This commit is contained in:
root 2025-12-15 12:57:29 +08:00
commit 1ae2146ff0
19 changed files with 287 additions and 199 deletions

View File

@ -189,8 +189,8 @@ function stopBackendService() {
function createWindow() {
splashWindow = new BrowserWindow({
width: 480,
height: 320,
width: 1920,
height: 1080,
frame: false,
resizable: false,
alwaysOnTop: true,

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.0 KiB

After

Width:  |  Height:  |  Size: 4.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.8 KiB

After

Width:  |  Height:  |  Size: 3.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.8 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.8 KiB

After

Width:  |  Height:  |  Size: 3.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.8 KiB

View File

@ -8,46 +8,50 @@
@click="generatePDF">
<div class="AloneReportComparison-container-body" id="pdf-content">
<div style="height: 100%; padding:0 90px; box-sizing: border-box;">
<div style="height: 100%; padding:0 40px; box-sizing: border-box;">
<div class="AloneReportComparison-container-bodytitle">体态测量报告单对比</div>
<div class="AloneReportComparison-container-display">
<!-- <div class="AloneReportComparison-container-userinfotext">检测时间{{ detectionInfo.start_time }}</div>
<div class="AloneReportComparison-container-userinfotext">ID{{ detectionInfo.id }}</div> -->
</div>
<div class="AloneReportComparison-container-userinfodisplay">
<div class="AloneReportComparison-container-userinfotext2">
<div class="AloneReportComparison-container-userinfotext2" style="width: 180px;">
ID{{ selectedPatient.id }}
</div>
<div class="AloneReportComparison-container-userinfotext2 width-210">
<div class="AloneReportComparison-container-userinfotext2" style="width: 180px;">
姓名{{ selectedPatient.name }}
</div>
<div class="AloneReportComparison-container-userinfotext2 width-195">
<div class="AloneReportComparison-container-userinfotext2" style="width: 100px;">
性别{{ selectedPatient.gender }}
</div>
<div class="AloneReportComparison-container-userinfotext2 width-195">
<div class="AloneReportComparison-container-userinfotext2" style="width: 120px;">
年龄{{ calculateAge(selectedPatient.birth_date) }}
</div>
<div class="AloneReportComparison-container-userinfotext2 width-235">
<div class="AloneReportComparison-container-userinfotext2" style="width: 120px;">
身高{{ selectedPatient.height }}cm
</div>
<div class="AloneReportComparison-container-userinfotext2 width-215">
<div class="AloneReportComparison-container-userinfotext2" style="width: 120px;">
体重{{ selectedPatient.weight }}kg
</div>
<div class="AloneReportComparison-container-userinfotext2 width-95">
<div class="AloneReportComparison-container-userinfotext2" style="width: 100px;">
鞋码{{ selectedPatient.shoe_size }}
</div>
<div class="AloneReportComparison-container-userinfotext2">
电话{{ selectedPatient.phone }}
</div>
<div class="AloneReportComparison-container-userinfotext2 width-405">
邮箱{{ selectedPatient.email }}
</div>
<div class="AloneReportComparison-container-userinfotext2 width-430">
居住地{{ selectedPatient.residence }}
</div>
<div class="AloneReportComparison-container-userinfotext2 width-310">
<div class="AloneReportComparison-container-userinfotext2" style="width: 140px;">
职业{{ selectedPatient.occupation }}
</div>
<div class="AloneReportComparison-container-userinfotext2" style="width: 180px;">
电话{{ selectedPatient.phone }}
</div>
<div class="AloneReportComparison-container-userinfotext2" style="padding-left:10px;width: auto;">
邮箱{{ selectedPatient.email }}
</div>
<div class="AloneReportComparison-container-userinfotext2 " style="padding-left:10px;width: auto;">
居住地{{ selectedPatient.residence }}
</div>
</div>
<div class="AloneReportComparison-container-testdatatitle">检测数据</div>
<div class="AloneReportComparison-containerdisplay">
@ -66,7 +70,7 @@
<div class="AloneReportComparison-content-title">身体姿态</div>
<!-- <div style="width: 100%;height: 454px; display: flex;justify-content: center;"> -->
<img :src="BACKEND_URL+'/' + rawOneData.body_image" alt="" srcset=""
style="width: 100%;height: 454px; object-fit:contain; ">
style="width: 99%;height: 454px; object-fit:contain; ">
<!-- </div> -->
<div class="AloneReportComparison-content-title">头部姿态</div>
<div style="width: 380px;padding:20px 0; display: flex;justify-content: space-between;">
@ -74,7 +78,7 @@
<img src="@/assets/archive/yaw.png">
<img src="@/assets/archive/pitch.png">
</div>
<div style="width: 430px;padding:20px 0; display: flex;justify-content: space-between;">
<div style="width: 460px;padding:20px 0; display: flex;justify-content: space-between;">
<div class="rollyawpitchtext"><span class="rollyawpitchtextcolor">
{{headPoseMaxValuesLeft.rotationLeftMax}}°
</span>
@ -86,7 +90,7 @@
{{headPoseMaxValuesLeft.pitchDownMax}}°
</span></div>
</div>
<div style="width: 430px;padding:20px 0; display: flex;justify-content: space-between;">
<div style="width: 460px;padding:20px 0; display: flex;justify-content: space-between;">
<div class="rollyawpitchtext"><span class="rollyawpitchtextcolor">
{{headPoseMaxValuesLeft.rotationRightMax}}°
</span></div>
@ -140,7 +144,7 @@
<div class="AloneReportComparison-content-title">身体姿态</div>
<img :src="BACKEND_URL+'/' + rawTwoData.body_image" alt="" srcset=""
style="width: 100%;height: 454px; object-fit:contain;">
style="width: 99%;height: 454px; object-fit:contain;">
<div class="AloneReportComparison-content-title">头部姿态</div>
<div style="width:380px;padding:20px 0; display: flex;justify-content: space-between;">
<img src="@/assets/archive/roll.png">
@ -214,7 +218,7 @@
import { ref, onMounted, onUnmounted } from 'vue'
import { historyAPI,getBackendUrl } from '@/services/api.js'
import { ElMessage } from 'element-plus'
import dayjs from 'dayjs';
const emit = defineEmits([ 'closeAloneReportComparison' ]);
const props = defineProps({
selectedPatient: {
@ -339,7 +343,7 @@ const generatePDF = async () => {
const url = URL.createObjectURL(blob)
const a = document.createElement('a')
a.href = url
a.download = '对比报告'
a.download = '体态测量对比报告单-' + dayjs().format('YYYY-MM-DD HH:mm:ss')
document.body.appendChild(a)
a.click()
document.body.removeChild(a)
@ -447,12 +451,13 @@ function handleCancel(){
display: flex;
}
.AloneReportComparison-container-leftbox{
width: 50%;
width: calc(50% - 5px);
border-right:1px solid rgb(208, 208, 208) ;
box-sizing: border-box;
}
.AloneReportComparison-container-rightbox{
width: 50%;
margin-left: 10px;
width: calc(50% - 5px);
box-sizing: border-box;
}
.displayflex{
@ -621,19 +626,6 @@ function handleCancel(){
background-color: white !important;
}
/* 左右分栏调整 */
.AloneReportComparison-container-leftbox,
.AloneReportComparison-container-rightbox {
width: 49% !important;
display: inline-block !important;
vertical-align: top !important;
box-sizing: border-box !important;
margin: 0 !important;
padding: 0 10px !important;
border: none !important;
/* 允许分栏内部内容自然分页 */
break-inside: auto !important;
}
.AloneReportComparison-container-leftbox {
border-right: 1px solid #ccc !important;
@ -661,26 +653,19 @@ function handleCancel(){
padding-bottom: 10px !important;
}
.AloneReportComparison-container-display,
/* .AloneReportComparison-container-display,
.AloneReportComparison-container-userinfodisplay {
padding: 10px 0 !important;
}
.AloneReportComparison-container-userinfotext2 {
font-size: 14px !important;
width: auto !important;
margin-right: 20px !important;
padding-bottom: 5px !important;
}
} */
/* 标题字号调整 */
.AloneReportComparison-content-title,
/* .AloneReportComparison-content-title,
.AloneReportComparison-container-testdatatitle,
.AloneReportComparison-title2 {
font-size: 16px !important;
padding-top: 10px !important;
padding-bottom: 5px !important;
}
} */
/* 分页控制 */
.AloneReportComparison-content-title {
@ -703,6 +688,7 @@ function handleCancel(){
padding-top: 40px;
border-top: 1px solid #333;
display: flex;
justify-content: space-between;
font-weight: 700;
font-style: normal;
color: rgb(40, 40, 40);

View File

@ -23,6 +23,7 @@
</div>
<el-table ref="tableRef" :data="patients" style="width: 100%;height: calc(100% - 100px);"
@cell-click="selectPatient"
row-key="id"
highlight-current-row>
<el-table-column type="index" label="序号" width="60" />
<el-table-column prop="id" label="患者ID" min-width="120" align="center" />
@ -276,23 +277,7 @@ const userInfo = reactive({
avatar: ''
})
const tableRef = ref(null)
const dialogVisible = ref(false)
//
const patientForm = ref({
id: '',
name: '',
gender: '',
birth_date: '',
nationality: '',
residence: '',
height: '',
weight: '',
shoe_size: '',
phone: '',
occupation: '',
idcode: '',
email: ''
})
const calculatedAge = ref('')
function delRowClick(id){
tipType.value = '删除'
@ -413,14 +398,6 @@ const getStatusType = (lastDetection) => {
return 'danger'
}
const getStatusText = (lastDetection) => {
if (!lastDetection) return '未检测'
const daysDiff = Math.floor((Date.now() - new Date(lastDetection).getTime()) / (1000 * 60 * 60 * 24))
if (daysDiff === 0) return '今日检测'
if (daysDiff <= 7) return `${daysDiff}天前`
if (daysDiff <= 30) return `${daysDiff}天前`
return '超过30天'
}
const formatDate = (date) => {
const d = new Date(date)
@ -445,7 +422,7 @@ const calculateAge = (birthDate) => {
const size =ref(15)
const page =ref(1)
const search = ref("")
const loadPatients = async () => {
const loadPatients = async (type) => {
try {
const response = await patientAPI.getPatients({
page:page.value,
@ -465,6 +442,9 @@ const loadPatients = async () => {
const lastcheck = mh && mh.lastcheck_time ? mh.lastcheck_time : ''
return { ...p, doctor, status, updated_at: lastcheck || p.updated_at }
})
if(type === '02' && patients.value[rowIndex.value] != null){
tableRef.value?.setCurrentRow(patients.value[rowIndex.value], true); // true
}
patienttotal.value =response.data.total
} else if (Array.isArray(response.data)) {
patients.value = (response.data || []).map(p => {
@ -477,6 +457,9 @@ const loadPatients = async () => {
const lastcheck = mh && mh.lastcheck_time ? mh.lastcheck_time : ''
return { ...p, doctor, status, updated_at: lastcheck || p.updated_at }
})
if(type === '02' && patients.value[rowIndex.value] != null){
tableRef.value?.setCurrentRow(patients.value[rowIndex.value], true); // true
}
patienttotal.value =response.total
} else {
patients.value = []
@ -534,16 +517,18 @@ function closecreatbox(e,e2){
patients.value[rowIndex.value] = { ...patients.value[rowIndex.value], ...e2 }
}
selectedPatient.value = e2
loadPatients()
loadPatients('02')
}
isCloseCreat.value = false
}
function endChange(){
loadPatients('02')
isDetection.value = false
}
function closePatientProfile(){
loadPatients('02')
isPatientProfile.value =false
}
function handleCurrentChange (val) {

View File

@ -2087,7 +2087,7 @@ const startRecord = async () => { // 开始录屏
patientInfo.value.detectionStartTime = Date.now()
console.log('✅ 录屏会话创建成功会话ID:', patientInfo.value.sessionId)
isRecording.value = true
ElMessage.success('录屏已开始')
// ElMessage.success('')
} else {
throw new Error(result.message || '开始录屏失败')
}

View File

@ -2137,7 +2137,6 @@ const startRecord = async () => { // 开始录屏
patientInfo.value.detectionStartTime = Date.now()
console.log('✅ 录屏会话创建成功会话ID:', patientInfo.value.sessionId)
isRecording.value = true
ElMessage.success('录屏已开始')
} else {
throw new Error(result.message || '开始录屏失败')
}

View File

@ -77,7 +77,7 @@
<img src="@/assets/archive/yaw.png">
<img src="@/assets/archive/pitch.png">
</div>
<div style="width: 630px;padding:20px 0; display: flex;justify-content: space-between;">
<div style="width: 575px;padding:20px 0; display: flex;justify-content: space-between;">
<div class="rollyawpitchtext"><span class="rollyawpitchtextcolor">
{{headPoseMaxValuesLeft.rotationLeftMax}}°
</span>
@ -89,7 +89,7 @@
{{headPoseMaxValuesLeft.pitchDownMax}}°
</span></div>
</div>
<div style="width: 630px;padding:20px 0; display: flex;justify-content: space-between;">
<div style="width: 575px;padding:20px 0; display: flex;justify-content: space-between;">
<div class="rollyawpitchtext"><span class="rollyawpitchtextcolor">
{{headPoseMaxValuesLeft.rotationRightMax}}°
</span></div>
@ -144,7 +144,7 @@
<img src="@/assets/archive/yaw.png">
<img src="@/assets/archive/pitch.png">
</div>
<div style="width: 630px;padding:20px 0; display: flex;justify-content: space-between;">
<div style="width: 575px;padding:20px 0; display: flex;justify-content: space-between;">
<div class="rollyawpitchtext"><span class="rollyawpitchtextcolor">
{{headPoseMaxValuesRight.rotationLeftMax}}°
</span>
@ -156,7 +156,7 @@
{{headPoseMaxValuesRight.pitchDownMax}}°
</span></div>
</div>
<div style="width: 630px;padding:20px 0; display: flex;justify-content: space-between;">
<div style="width: 575px;padding:20px 0; display: flex;justify-content: space-between;">
<div class="rollyawpitchtext"><span class="rollyawpitchtextcolor">
{{headPoseMaxValuesRight.rotationRightMax}}°
</span></div>

View File

@ -21,7 +21,7 @@
<img src="@/assets/archive/yaw.png">
<img src="@/assets/archive/pitch.png">
</div>
<div style="width: 630px;padding:20px 0; display: flex;justify-content: space-between;">
<div style="width: 575px;padding:20px 0; display: flex;justify-content: space-between;">
<div class="rollyawpitchtext"><span class="rollyawpitchtextcolor">
{{headPoseMaxValuesRight.rotationLeftMax}}°
</span>
@ -33,7 +33,7 @@
{{headPoseMaxValuesRight.pitchDownMax}}°
</span></div>
</div>
<div style="width: 630px;padding:20px 0; display: flex;justify-content: space-between;">
<div style="width: 575px;padding:20px 0; display: flex;justify-content: space-between;">
<div class="rollyawpitchtext"><span class="rollyawpitchtextcolor">
{{headPoseMaxValuesRight.rotationRightMax}}°
</span></div>

View File

@ -40,7 +40,7 @@
<img src="@/assets/archive/yaw.png">
<img src="@/assets/archive/pitch.png">
</div>
<div style="width: 630px;padding:20px 0; display: flex;justify-content: space-between;">
<div style="width: 575px;padding:20px 0; display: flex;justify-content: space-between;">
<div class="rollyawpitchtext"><span class="rollyawpitchtextcolor">
{{headPoseMaxValuesLeft.rotationLeftMax}}°
</span>
@ -52,7 +52,7 @@
{{headPoseMaxValuesLeft.pitchDownMax}}°
</span></div>
</div>
<div style="width: 630px;padding:20px 0; display: flex;justify-content: space-between;">
<div style="width: 575px;padding:20px 0; display: flex;justify-content: space-between;">
<div class="rollyawpitchtext"><span class="rollyawpitchtextcolor">
{{headPoseMaxValuesLeft.rotationRightMax}}°
</span></div>
@ -78,7 +78,7 @@
<img src="@/assets/archive/yaw.png">
<img src="@/assets/archive/pitch.png">
</div>
<div style="width: 630px;padding:20px 0; display: flex;justify-content: space-between;">
<div style="width: 575px;padding:20px 0; display: flex;justify-content: space-between;">
<div class="rollyawpitchtext"><span class="rollyawpitchtextcolor">
{{headPoseMaxValuesRight.rotationLeftMax}}°
</span>
@ -90,7 +90,7 @@
{{headPoseMaxValuesRight.pitchDownMax}}°
</span></div>
</div>
<div style="width: 630px;padding:20px 0; display: flex;justify-content: space-between;">
<div style="width: 575px;padding:20px 0; display: flex;justify-content: space-between;">
<div class="rollyawpitchtext"><span class="rollyawpitchtextcolor">
{{headPoseMaxValuesRight.rotationRightMax}}°
</span></div>

View File

@ -1242,11 +1242,12 @@ historyAPI.VideoDelById(ids).then((response)=>{
height: 24px;
margin-top: 5px;
cursor: pointer;
margin-left: 4px;
}
.patientprofile-del{
position: absolute;
left: -5px;
right: -10px;
top: -5px;
display: none;
z-index: 1;

View File

@ -699,17 +699,7 @@ const loadPatientInfo = async () => {
} catch (error) {
console.error('加载患者信息失败:', error)
//
patient.value = {
id: route.params.id,
name: '张三',
gender: '男',
age: 45,
height: 175,
weight: 70,
phone: '13800138001',
doctor: '李医生',
createdAt: '2024-01-15T10:30:00Z'
}
patient.value = {}
}
}

View File

@ -4,46 +4,49 @@
alt="" style="cursor: pointer;position: fixed; right: 20px; top: 20px;z-index: 99;"
@click="handleCancel">
<div class="PopUpOnlyReport-container-body" id="pdf-content">
<div style="height: 100%; padding:0 90px; box-sizing: border-box;">
<div style="height: 100%; padding:0 40px; box-sizing: border-box;">
<div class="PopUpOnlyReport-container-bodytitle">体态测量报告单</div>
<div class="PopUpOnlyReport-container-display">
<div class="PopUpOnlyReport-container-userinfotext">检测时间{{ detectionInfo.start_time }}</div>
<div class="PopUpOnlyReport-container-userinfotext">ID{{ detectionInfo.id }}</div>
</div>
<div class="PopUpOnlyReport-container-userinfodisplay">
<div class="PopUpOnlyReport-container-userinfotext2">
<div class="PopUpOnlyReport-container-userinfotext2" style="width: 180px;">
ID{{ selectedPatient.id }}
</div>
<div class="PopUpOnlyReport-container-userinfotext2 width-210">
<div class="PopUpOnlyReport-container-userinfotext2" style="width: 180px;">
姓名{{ selectedPatient.name }}
</div>
<div class="PopUpOnlyReport-container-userinfotext2 width-195">
<div class="PopUpOnlyReport-container-userinfotext2" style="width: 100px;">
性别{{ selectedPatient.gender }}
</div>
<div class="PopUpOnlyReport-container-userinfotext2 width-195">
<div class="PopUpOnlyReport-container-userinfotext2" style="width: 120px;">
年龄{{ calculateAge(selectedPatient.birth_date) }}
</div>
<div class="PopUpOnlyReport-container-userinfotext2 width-235">
<div class="PopUpOnlyReport-container-userinfotext2" style="width: 120px;">
身高{{ selectedPatient.height }}cm
</div>
<div class="PopUpOnlyReport-container-userinfotext2 width-215">
<div class="PopUpOnlyReport-container-userinfotext2" style="width: 120px;">
体重{{ selectedPatient.weight }}kg
</div>
<div class="PopUpOnlyReport-container-userinfotext2 width-95">
<div class="PopUpOnlyReport-container-userinfotext2" style="width: 100px;">
鞋码{{ selectedPatient.shoe_size }}
</div>
<div class="PopUpOnlyReport-container-userinfotext2">
电话{{ selectedPatient.phone }}
</div>
<div class="PopUpOnlyReport-container-userinfotext2 width-405">
邮箱{{ selectedPatient.email }}
</div>
<div class="PopUpOnlyReport-container-userinfotext2 width-430">
居住地{{ selectedPatient.residence }}
</div>
<div class="PopUpOnlyReport-container-userinfotext2 width-310">
<div class="PopUpOnlyReport-container-userinfotext2" style="width: 140px;">
职业{{ selectedPatient.occupation }}
</div>
<div class="PopUpOnlyReport-container-userinfotext2" style="width: 180px;">
电话{{ selectedPatient.phone }}
</div>
<div class="PopUpOnlyReport-container-userinfotext2" style="padding-left:10px;width: auto;">
邮箱{{ selectedPatient.email }}
</div>
<div class="PopUpOnlyReport-container-userinfotext2 " style="padding-left:10px;width: auto;">
居住地{{ selectedPatient.residence }}
</div>
</div>
<div class="PopUpOnlyReport-container-testdatatitle">检测数据</div>
<div class="PopUpOnlyReport-containerdisplay">
@ -61,10 +64,9 @@
<img :src="BACKEND_URL+'/' + rawData.screen_image" alt="" srcset="" style="width: 100%;height: 100%;">
</div>
<div class="PopUpOnlyReport-content-title">身体姿态</div>
<div style="width: 216px;height: 454px; display: flex;justify-content: center; margin: auto;">
<img :src="BACKEND_URL+'/' + rawData.body_image" alt="" srcset="" style="width: 100%;height: 100%;
object-fit:contain; ">
</div>
<img :src="BACKEND_URL+'/' + rawData.body_image" alt="" srcset=""
style="width: 99%;height: 454px; object-fit:contain; ">
<div class="PopUpOnlyReport-content-title">头部姿态</div>
<div style="width: 630px;padding:20px 0; margin: auto; display: flex;justify-content: space-between;">
<img src="@/assets/archive/roll.png">
@ -350,7 +352,7 @@ function handleCancel(){
}
.PopUpOnlyReport-container-body{
margin:20px auto 0;
width: 1600px;
width: 1048px;
background: #fff;
border-radius: 5px;
padding: 50px 0 20px;
@ -538,9 +540,140 @@ function handleCancel(){
padding-top: 40px;
border-top: 1px solid #333;
display: flex;
justify-content: space-between;
font-weight: 700;
font-style: normal;
color: rgb(40, 40, 40);
font-size: 18px;
}
</style>
<style>
@media print {
@page {
size: A4 landscape;
margin: 10mm;
}
html, body {
height: auto !important;
overflow: visible !important;
background: white !important;
}
/* 隐藏所有元素,但保留占位,避免 display:none 导致的父级隐藏问题 */
body * {
visibility: hidden;
}
/* 显式显示目标容器及其子元素 */
#popup-report-root,
#popup-report-root *,
#electron-print-container,
#electron-print-container * {
visibility: visible !important;
}
/* 确保根节点可见并重置布局 */
#popup-report-root {
position: static !important;
width: 100% !important;
height: auto !important;
margin: 0 !important;
padding: 0 !important;
background-color: white !important;
z-index: 9999 !important;
overflow: visible !important;
}
/* 容器样式重置 */
.PopUpOnlyReport-container-body {
width: 100% !important;
margin: 0 !important;
box-shadow: none !important;
padding: 10px !important;
border: none !important;
height: auto !important;
overflow: visible !important;
display: block !important;
min-height: 100vh !important;
}
/* 移除内层div的固定高度 */
.PopUpOnlyReport-container-body > div {
height: auto !important;
padding: 0 !important;
}
/* 针对克隆节点的特定样式 */
#electron-print-container .PopUpOnlyReport-container {
position: static !important;
width: 100% !important;
height: auto !important;
overflow: visible !important;
margin: 0 !important;
padding: 0 !important;
background-color: white !important;
}
/* 图片容器自适应 */
.PopUpOnlyReport-container-body div[style*="width: 600px"] {
width: 100% !important;
height: auto !important;
margin-bottom: 10px !important;
break-inside: avoid !important;
}
/* 图片自适应 */
img {
max-width: 100% !important;
height: auto !important;
object-fit: contain !important;
max-height: 300px !important; /* 限制最大高度,防止一页占满 */
}
/* 头部信息紧凑化 */
.PopUpOnlyReport-container-bodytitle {
font-size: 24px !important;
padding-bottom: 10px !important;
}
.PopUpOnlyReport-container-display,
.PopUpOnlyReport-container-userinfodisplay {
padding: 10px 0 !important;
}
/* .PopUpOnlyReport-container-userinfotext2 {
font-size: 14px !important;
width: auto !important;
margin-right: 20px !important;
padding-bottom: 5px !important;
} */
/* 标题字号调整 */
.PopUpOnlyReport-content-title,
.PopUpOnlyReport-container-testdatatitle,
.PopUpOnlyReport-title2 {
font-size: 16px !important;
padding-top: 10px !important;
padding-bottom: 5px !important;
}
/* 分页控制 */
.PopUpOnlyReport-content-title {
break-after: avoid;
}
img {
break-inside: avoid;
}
/* 隐藏不需要的UI元素 */
.displayflexselect-icon,
::-webkit-scrollbar {
display: none !important;
}
}
</style>

View File

@ -4,46 +4,50 @@
alt="" style="cursor: pointer;position: fixed; right: 20px; top: 20px;z-index: 99;"
@click="handleCancel">
<div class="PopUpReport-container-body" id="pdf-content">
<div style="height: 100%; padding:0 90px; box-sizing: border-box;">
<div style="height: 100%; padding:0 40px; box-sizing: border-box;">
<div class="PopUpReport-container-bodytitle">体态测量报告单</div>
<div class="PopUpReport-container-display">
<div class="PopUpReport-container-userinfotext">检测时间{{ detectionInfo.start_time }}</div>
<div class="PopUpReport-container-userinfotext">ID{{ detectionInfo.id }}</div>
</div>
<div class="PopUpReport-container-userinfodisplay">
<div class="PopUpReport-container-userinfotext2">
<div class="PopUpReport-container-userinfotext2" style="width: 180px;">
ID{{ selectedPatient.id }}
</div>
<div class="PopUpReport-container-userinfotext2 width-210">
<div class="PopUpReport-container-userinfotext2" style="width: 180px;">
姓名{{ selectedPatient.name }}
</div>
<div class="PopUpReport-container-userinfotext2 width-195">
<div class="PopUpReport-container-userinfotext2" style="width: 100px;">
性别{{ selectedPatient.gender }}
</div>
<div class="PopUpReport-container-userinfotext2 width-195">
<div class="PopUpReport-container-userinfotext2" style="width: 120px;">
年龄{{ calculateAge(selectedPatient.birth_date) }}
</div>
<div class="PopUpReport-container-userinfotext2 width-235">
<div class="PopUpReport-container-userinfotext2" style="width: 120px;">
身高{{ selectedPatient.height }}cm
</div>
<div class="PopUpReport-container-userinfotext2 width-215">
<div class="PopUpReport-container-userinfotext2" style="width: 120px;">
体重{{ selectedPatient.weight }}kg
</div>
<div class="PopUpReport-container-userinfotext2 width-95">
<div class="PopUpReport-container-userinfotext2" style="width: 100px;">
鞋码{{ selectedPatient.shoe_size }}
</div>
<div class="PopUpReport-container-userinfotext2">
电话{{ selectedPatient.phone }}
</div>
<div class="PopUpReport-container-userinfotext2 width-405">
邮箱{{ selectedPatient.email }}
</div>
<div class="PopUpReport-container-userinfotext2 width-430">
居住地{{ selectedPatient.residence }}
</div>
<div class="PopUpReport-container-userinfotext2 width-310">
<div class="PopUpReport-container-userinfotext2" style="width: 140px;">
职业{{ selectedPatient.occupation }}
</div>
<div class="PopUpReport-container-userinfotext2" style="width: 180px;">
电话{{ selectedPatient.phone }}
</div>
<div class="PopUpReport-container-userinfotext2 " style="padding-left:10px;width: auto;">
邮箱{{ selectedPatient.email }}
</div>
<div class="PopUpReport-container-userinfotext2 " style="padding-left:10px;width: auto;">
居住地{{ selectedPatient.residence }}
</div>
</div>
<div class="PopUpReport-container-testdatatitle">检测数据</div>
<div class="PopUpReport-containerdisplay">
@ -57,20 +61,20 @@
<!-- 选中后显示内容 -->
<div v-if="rawData.id && rawData.id!=''">
<div class="PopUpReport-content-title">整体数据</div>
<div style="width: 600px;height: 327px;">
<div style="width: 90%;height: 219px;">
<img :src="BACKEND_URL+'/' + rawData.screen_image" alt="" srcset="" style="width: 100%;height: 100%;
object-fit:contain; ">
</div>
<div class="PopUpReport-content-title">身体姿态</div>
<img :src="BACKEND_URL+'/' + rawData.body_image" alt="" srcset=""
style="width: 300px;height: 600px;margin-left: 100px;">
style="width: 99%;height: 454px; object-fit:contain; ">
<div class="PopUpReport-content-title">头部姿态</div>
<div style="width:500px;padding:20px 0; display: flex;justify-content: space-between;">
<div style="width:380px;padding:20px 0; display: flex;justify-content: space-between;">
<img src="@/assets/archive/roll.png">
<img src="@/assets/archive/yaw.png">
<img src="@/assets/archive/pitch.png">
</div>
<div style="width: 570px;padding:20px 0; display: flex;justify-content: space-between;">
<div style="width: 460px;padding:20px 0; display: flex;justify-content: space-between;">
<div class="rollyawpitchtext"><span class="rollyawpitchtextcolor">
{{headPoseMaxValuesLeft.rotationLeftMax}}°
</span>
@ -82,7 +86,7 @@
{{headPoseMaxValuesLeft.pitchDownMax}}°
</span></div>
</div>
<div style="width: 570px;padding:20px 0; display: flex;justify-content: space-between;">
<div style="width: 460px;padding:20px 0; display: flex;justify-content: space-between;">
<div class="rollyawpitchtext"><span class="rollyawpitchtextcolor">
{{headPoseMaxValuesLeft.rotationRightMax}}°
</span></div>
@ -98,16 +102,16 @@
</div>
</div>
<div class="PopUpReport-content-title">足底压力</div>
<div style="width: 600px;height: 370px; display: flex;">
<div style="width: 90%;height: 280px; display: flex;">
<img :src="BACKEND_URL+'/' + rawData.foot_data_image" alt="" srcset="" style="width: 100%;height: 100%;
object-fit:contain; ">
</div>
<div class="PopUpReport-content-title">视频1图片</div>
<div style="width: 600px;height: 338px; display: flex;">
<div style="width: 90%;height: 230px; display: flex;">
<img :src="BACKEND_URL+'/' + rawData.foot1_image" alt="" srcset="" style="width: 100%;height: 100%;">
</div>
<div class="PopUpReport-content-title">视频2图片</div>
<div style="width: 600px;height: 338px; display: flex;">
<div style="width: 90%;height: 230px; display: flex;">
<img :src="BACKEND_URL+'/' + rawData.foot2_image" alt="" srcset="" style="width: 100%;height: 100%;">
</div>
</div>
@ -122,19 +126,20 @@
<!-- 选中后显示内容 -->
<div v-if="calibrationData.id && calibrationData.id!=''">
<div class="PopUpReport-content-title">整体数据</div>
<div style="width: 600px;height: 327px;">
<img :src="BACKEND_URL+'/' + calibrationData.screen_image" alt="" srcset="" style="width: 100%;height: 100%;">
<div style="width: 90%;height: 219px;">
<img :src="BACKEND_URL+'/' + calibrationData.screen_image" alt="" srcset=""
style="width: 100%;height: 100%; object-fit:contain;">
</div>
<div class="PopUpReport-content-title">身体姿态</div>
<img :src="BACKEND_URL+'/' + calibrationData.body_image" alt="" srcset=""
style="width: 300px;height: 600px;margin-left: 100px; ">
style="width: 99%;height: 454px; object-fit:contain; ">
<div class="PopUpReport-content-title">头部姿态</div>
<div style="width: 500px;padding:20px 0; display: flex;justify-content: space-between;">
<div style="width: 380px;padding:20px 0; display: flex;justify-content: space-between;">
<img src="@/assets/archive/roll.png">
<img src="@/assets/archive/yaw.png">
<img src="@/assets/archive/pitch.png">
</div>
<div style="width: 570px;padding:20px 0; display: flex;justify-content: space-between;">
<div style="width: 460px;padding:20px 0; display: flex;justify-content: space-between;">
<div class="rollyawpitchtext"><span class="rollyawpitchtextcolor">
{{headPoseMaxValuesRight.rotationLeftMax}}°
</span>
@ -146,7 +151,7 @@
{{headPoseMaxValuesRight.pitchDownMax}}°
</span></div>
</div>
<div style="width: 570px;padding:20px 0; display: flex;justify-content: space-between;">
<div style="width: 460px;padding:20px 0; display: flex;justify-content: space-between;">
<div class="rollyawpitchtext"><span class="rollyawpitchtextcolor">
{{headPoseMaxValuesRight.rotationRightMax}}°
</span></div>
@ -162,16 +167,16 @@
</div>
</div>
<div class="PopUpReport-content-title">足底压力</div>
<div style="width: 600px;height: 370px; display: flex;">
<div style="width: 90%;height: 280px; display: flex;">
<img :src="BACKEND_URL+'/' + calibrationData.foot_data_image" alt="" srcset="" style="width: 100%;height: 100%;
object-fit:contain; ">
</div>
<div class="PopUpReport-content-title">视频1图片</div>
<div style="width: 600px;height: 338px; display: flex;">
<div style="width: 90%;height: 230px; display: flex;">
<img :src="BACKEND_URL+'/' + calibrationData.foot1_image" alt="" srcset="" style="width: 100%;height: 100%;">
</div>
<div class="PopUpReport-content-title">视频2图片</div>
<div style="width: 600px;height: 338px; display: flex;">
<div style="width: 90%;height: 230px; display: flex;">
<img :src="BACKEND_URL+'/' + calibrationData.foot2_image" alt="" srcset="" style="width: 100%;height: 100%;">
</div>
</div>
@ -364,7 +369,7 @@ function getFormattedTime() {
}
.PopUpReport-container-body{
margin:20px auto 0;
width: 1600px;
width: 1048px;
background: #fff;
border-radius: 5px;
padding: 20px 0 30px;
@ -432,14 +437,14 @@ function getFormattedTime() {
display: flex;
}
.PopUpReport-container-leftbox{
width: 50%;
width: calc(50% - 5px);
border-right:1px solid rgb(208, 208, 208) ;
box-sizing: border-box;
}
.PopUpReport-container-rightbox{
width: 50%;
margin-left: 10px;
width: calc(50% - 5px);
box-sizing: border-box;
padding-left: 80px;
}
.displayflex{
display: flex;
@ -607,23 +612,6 @@ function getFormattedTime() {
background-color: white !important;
}
/* 左右分栏调整 */
.PopUpReport-container-leftbox,
.PopUpReport-container-rightbox {
width: 49% !important;
display: inline-block !important;
vertical-align: top !important;
box-sizing: border-box !important;
margin: 0 !important;
padding: 0 10px !important;
border: none !important;
/* 允许分栏内部内容自然分页 */
break-inside: auto !important;
}
.PopUpReport-container-leftbox {
border-right: 1px solid #ccc !important;
}
/* 图片容器自适应 */
.PopUpReport-container-body div[style*="width: 600px"] {
@ -652,12 +640,12 @@ function getFormattedTime() {
padding: 10px 0 !important;
}
.PopUpReport-container-userinfotext2 {
/* .PopUpReport-container-userinfotext2 {
font-size: 14px !important;
width: auto !important;
margin-right: 20px !important;
padding-bottom: 5px !important;
}
} */
/* 标题字号调整 */
.PopUpReport-content-title,
@ -689,6 +677,7 @@ function getFormattedTime() {
padding-top: 40px;
border-top: 1px solid #333;
display: flex;
justify-content: space-between;
font-weight: 700;
font-style: normal;
color: rgb(40, 40, 40);

View File

@ -7,44 +7,48 @@
style="cursor: pointer;position: fixed; right: 60px; top: 17px;z-index: 99;height: 28px;"
@click="generatePDF">
<div class="ReportComparison-container-body" id="pdf-content">
<div style="height: 100%; padding:0 90px; box-sizing: border-box;">
<div style="height: 100%; padding:0 40px; box-sizing: border-box;">
<div class="ReportComparison-container-bodytitle">体态测量报告单对比</div>
<div class="ReportComparison-container-display">
<!-- <div class="ReportComparison-container-userinfotext">检测时间{{ detectionInfo.start_time }}</div>
<div class="ReportComparison-container-userinfotext">ID{{ detectionInfo.id }}</div> -->
</div>
<div class="ReportComparison-container-userinfodisplay">
<div class="ReportComparison-container-userinfotext2">
<div class="ReportComparison-container-userinfotext2" style="width: 180px;">
ID{{ selectedPatient.id }}
</div>
<div class="ReportComparison-container-userinfotext2 width-210">
<div class="ReportComparison-container-userinfotext2" style="width: 180px;">
姓名{{ selectedPatient.name }}
</div>
<div class="ReportComparison-container-userinfotext2 width-195">
<div class="ReportComparison-container-userinfotext2" style="width: 100px;">
性别{{ selectedPatient.gender }}
</div>
<div class="ReportComparison-container-userinfotext2 width-195">
<div class="ReportComparison-container-userinfotext2" style="width: 120px;">
年龄{{ calculateAge(selectedPatient.birth_date) }}
</div>
<div class="ReportComparison-container-userinfotext2 width-235">
<div class="ReportComparison-container-userinfotext2" style="width: 120px;">
身高{{ selectedPatient.height }}cm
</div>
<div class="ReportComparison-container-userinfotext2 width-215">
<div class="ReportComparison-container-userinfotext2" style="width: 120px;">
体重{{ selectedPatient.weight }}kg
</div>
<div class="ReportComparison-container-userinfotext2 width-95">
<div class="ReportComparison-container-userinfotext2" style="width: 100px;">
鞋码{{ selectedPatient.shoe_size }}
</div>
<div class="ReportComparison-container-userinfotext2">
<div class="ReportComparison-container-userinfotext2" style="width: 180px;">
电话{{ selectedPatient.phone }}
</div>
<div class="ReportComparison-container-userinfotext2 width-405">
<div class="ReportComparison-container-userinfotext2" style="width: 340px">
邮箱{{ selectedPatient.email }}
</div>
<div class="ReportComparison-container-userinfotext2 width-430">
<div class="ReportComparison-container-userinfotext2 " style="width: 440px;">
居住地{{ selectedPatient.residence }}
</div>
<div class="ReportComparison-container-userinfotext2 width-310">
<div class="ReportComparison-container-userinfotext2" style="width: 180px;">
职业{{ selectedPatient.occupation }}
</div>
</div>
@ -356,7 +360,7 @@
import { ref, onMounted, onUnmounted } from 'vue'
import { historyAPI,getBackendUrl } from '@/services/api.js'
import { ElMessage } from 'element-plus'
import dayjs from 'dayjs';
const emit = defineEmits([ 'closeReportComparison' ]);
const props = defineProps({
selectedPatient: {
@ -536,7 +540,7 @@ const generatePDF = async () => {
const url = URL.createObjectURL(blob)
const a = document.createElement('a')
a.href = url
a.download = '对比报告'
a.download = '体态测量对比报告单-' + dayjs().format('YYYY-MM-DD HH:mm:ss')
document.body.appendChild(a)
a.click()
document.body.removeChild(a)
@ -904,6 +908,7 @@ function handleCancel(){
padding-top: 40px;
border-top: 1px solid #333;
display: flex;
justify-content: space-between;
font-weight: 700;
font-style: normal;
color: rgb(40, 40, 40);