update: 大屏接口

This commit is contained in:
xf
2025-07-09 15:10:30 +08:00
parent f6e5bb78da
commit 91abcfd78d
22 changed files with 418 additions and 78 deletions
+42 -12
View File
@@ -20,17 +20,17 @@
<a-select placeholder="选择部门" v-model:value="orgCode2" :options="option2" />
</a-form-item>
<slot name="searchSecond"></slot>
<div class="form-btn">
<a-button @click="handleClickReset" style="border-color: #00ccff">重置</a-button>
<a-button
@click="handleClicksearch"
:loading="loading"
style="margin-left: 10px; background: #00ccff; border-color: #00ccff; color: #ffffff"
>
搜索
</a-button>
</div>
</Form>
<div class="form-btn">
<a-button @click="handleClickReset" style="border-color: #00ccff">重置</a-button>
<a-button
@click="handleClicksearch"
:loading="loading"
style="margin-left: 10px; background: #00ccff; border-color: #00ccff; color: #ffffff"
>
搜索
</a-button>
</div>
</div>
<div class="top-bottom-center" v-if="twoROnly">
<div class="date-change">
@@ -134,6 +134,35 @@
if (type == dataActity.value) return;
dataActity.value = type;
getField();
if (props.twoROnly) {
const twoRData = localStorage.getItem('twoRList');
const newData = JSON.parse(twoRData);
if (props.twoROnly.type == 1) {
if (type == 1) {
normalNum.value = newData.weightLossCountDay;
abnormalNum.value = newData.weightLossAbnormalCountDay;
} else {
normalNum.value = newData.weightLossCountMonth;
abnormalNum.value = newData.weightLossAbnormalCountMonth;
}
} else if (props.twoROnly.type == 2) {
if (type == 1) {
normalNum.value = newData.bloodSugarCountDay;
abnormalNum.value = newData.bloodSugarAbnormalCountDay;
} else {
normalNum.value = newData.bloodSugarCountMonth;
abnormalNum.value = newData.bloodSugarAbnormalCountMonth;
}
} else {
if (type == 1) {
normalNum.value = newData.bloodPressureCountDay;
abnormalNum.value = newData.bloodPressureAbnormalCountDay;
} else {
normalNum.value = newData.bloodPressureCountMonth;
abnormalNum.value = newData.bloodPressureAbnormalCountMonth;
}
}
}
if (type == 1) {
formState.value.inputDateBegin = dayjs().format('YYYY-MM-DD');
formState.value.inputDateEnd = dayjs().format('YYYY-MM-DD');
@@ -212,7 +241,7 @@
abnormalNum.value = newData.weightLossAbnormalCountDay;
} else {
normalNum.value = newData.weightLossCountMonth;
abnormalNum.value = newData.weightLossCountMonth;
abnormalNum.value = newData.weightLossAbnormalCountMonth;
}
} else if (props.twoROnly.type == 2) {
if (props.twoROnly.date == 1) {
@@ -270,6 +299,7 @@
orgCode2.value = '';
orgCode1.value = '';
getField();
formRecord.value = {};
formState.value = {
...formState.value,
...formRecord.value,
@@ -303,7 +333,7 @@
border-radius: 4px !important;
}
:deep(.ant-form) {
width: 80%;
width: 100%;
display: flex;
.ant-form-item {
flex: 1;