WXL (wul)
5 天以前 5319d5b95497b5b546947ac340c14c71e5b54ca6
src/views/patient/patient/profile/index.vue
@@ -212,6 +212,316 @@
                </el-form-item>
              </el-col>
            </el-row>
            <!-- 筛查摘要模块 -->
            <el-row :gutter="20">
              <el-col :span="12">
                <div class="screening-summary">
                  <div class="summary-header">
                    <i class="el-icon-search"></i>
                    <span>筛查摘要</span>
                    <div
                      style="
                        margin-left: auto;
                        display: flex;
                        align-items: center;
                      "
                    >
                      <el-button
                        type="primary"
                        size="mini"
                        @click="addScreening"
                      >
                        <i class="el-icon-plus"></i> 新增
                      </el-button>
                      <el-button
                        type="text"
                        size="mini"
                        @click="refreshScreeningData"
                        style="margin-left: 10px"
                      >
                        <i class="el-icon-refresh"></i> 刷新
                      </el-button>
                    </div>
                  </div>
                  <div class="summary-content">
                    <el-table
                      :data="screeningSummaryData"
                      border
                      size="mini"
                      height="200"
                      v-loading="screeningLoading"
                    >
                      <el-table-column
                        prop="screeningType"
                        label="筛查类型"
                        width="100"
                      >
                        <template slot-scope="scope">
                          <el-tag
                            :type="getScreeningTagType(scope.row.screeningType)"
                          >
                            {{ scope.row.screeningType }}
                          </el-tag>
                        </template>
                      </el-table-column>
                      <el-table-column
                        prop="screeningDate"
                        label="筛查日期"
                        width="100"
                      >
                        <template slot-scope="scope">
                          {{ formatTime(scope.row.screeningDate) }}
                        </template>
                      </el-table-column>
                      <el-table-column prop="result" label="结果" width="80">
                        <template slot-scope="scope">
                          <el-tag
                            :type="
                              scope.row.result === '正常'
                                ? 'success'
                                : scope.row.result === '异常'
                                ? 'danger'
                                : 'warning'
                            "
                            size="small"
                          >
                            {{ scope.row.result }}
                          </el-tag>
                        </template>
                      </el-table-column>
                      <el-table-column
                        prop="details"
                        label="详细结果"
                        min-width="120"
                      >
                        <template slot-scope="scope">
                          <el-tooltip
                            :content="scope.row.details"
                            placement="top"
                            v-if="
                              scope.row.details && scope.row.details.length > 10
                            "
                          >
                            <span
                              >{{ scope.row.details.substring(0, 10) }}...</span
                            >
                          </el-tooltip>
                          <span v-else>{{ scope.row.details }}</span>
                        </template>
                      </el-table-column>
                      <el-table-column label="操作" width="150" fixed="right">
                        <template slot-scope="scope">
                          <el-button
                            type="primary"
                            size="mini"
                            @click="editScreening(scope.$index, scope.row)"
                          >
                            编辑
                          </el-button>
                          <el-button
                            type="danger"
                            size="mini"
                            @click="deleteScreening(scope.$index, scope.row)"
                          >
                            删除
                          </el-button>
                        </template>
                      </el-table-column>
                    </el-table>
                    <div class="summary-stats">
                      <el-row :gutter="10">
                        <el-col :span="8">
                          <div class="stat-item">
                            <div class="stat-value" style="color: #67c23a">
                              {{ screeningStats.normal }}
                            </div>
                            <div class="stat-label">正常</div>
                          </div>
                        </el-col>
                        <el-col :span="8">
                          <div class="stat-item">
                            <div class="stat-value" style="color: #e6a23c">
                              {{ screeningStats.abnormal }}
                            </div>
                            <div class="stat-label">异常</div>
                          </div>
                        </el-col>
                        <el-col :span="8">
                          <div class="stat-item">
                            <div class="stat-value" style="color: #f56c6c">
                              {{ screeningStats.critical }}
                            </div>
                            <div class="stat-label">危急</div>
                          </div>
                        </el-col>
                      </el-row>
                    </div>
                  </div>
                </div>
              </el-col>
              <!-- 慢病摘要模块 -->
              <el-col :span="12">
                <div class="chronic-disease-summary">
                  <div class="summary-header">
                    <i class="el-icon-document"></i>
                    <span>慢病摘要</span>
                    <div
                      style="
                        margin-left: auto;
                        display: flex;
                        align-items: center;
                      "
                    >
                      <el-button
                        type="primary"
                        size="mini"
                        @click="addChronicDisease"
                      >
                        <i class="el-icon-plus"></i> 新增
                      </el-button>
                      <el-button
                        type="text"
                        size="mini"
                        @click="refreshChronicData"
                        style="margin-left: 10px"
                      >
                        <i class="el-icon-refresh"></i> 刷新
                      </el-button>
                    </div>
                  </div>
                  <div class="summary-content">
                    <el-table
                      :data="chronicDiseaseData"
                      border
                      size="mini"
                      height="200"
                      v-loading="chronicLoading"
                    >
                      <el-table-column
                        prop="diseaseName"
                        label="疾病名称"
                        width="120"
                      >
                        <template slot-scope="scope">
                          <el-tag
                            :type="getDiseaseTagType(scope.row.diseaseName)"
                          >
                            {{ scope.row.diseaseName }}
                          </el-tag>
                        </template>
                      </el-table-column>
                      <el-table-column
                        prop="diagnoseDate"
                        label="确诊日期"
                        width="100"
                      >
                        <template slot-scope="scope">
                          {{ formatTime(scope.row.diagnoseDate) }}
                        </template>
                      </el-table-column>
                      <el-table-column prop="status" label="状态" width="80">
                        <template slot-scope="scope">
                          <el-tag
                            :type="
                              scope.row.status === '稳定'
                                ? 'success'
                                : scope.row.status === '活动期'
                                ? 'warning'
                                : 'danger'
                            "
                            size="small"
                          >
                            {{ scope.row.status }}
                          </el-tag>
                        </template>
                      </el-table-column>
                      <el-table-column
                        prop="currentTreatment"
                        label="当前治疗"
                        min-width="120"
                      >
                        <template slot-scope="scope">
                          <el-tooltip
                            :content="scope.row.currentTreatment"
                            placement="top"
                            v-if="
                              scope.row.currentTreatment &&
                              scope.row.currentTreatment.length > 10
                            "
                          >
                            <span
                              >{{
                                scope.row.currentTreatment.substring(0, 10)
                              }}...</span
                            >
                          </el-tooltip>
                          <span v-else>{{ scope.row.currentTreatment }}</span>
                        </template>
                      </el-table-column>
                      <el-table-column label="操作" width="150" fixed="right">
                        <template slot-scope="scope">
                          <el-button
                            type="primary"
                            size="mini"
                            @click="editChronicDisease(scope.$index, scope.row)"
                          >
                            编辑
                          </el-button>
                          <el-button
                            type="danger"
                            size="mini"
                            @click="
                              deleteChronicDisease(scope.$index, scope.row)
                            "
                          >
                            删除
                          </el-button>
                        </template>
                      </el-table-column>
                    </el-table>
                    <div class="summary-stats">
                      <el-row :gutter="10">
                        <el-col :span="6">
                          <div class="stat-item">
                            <div class="stat-value" style="color: #67c23a">
                              {{ chronicStats.stable }}
                            </div>
                            <div class="stat-label">稳定</div>
                          </div>
                        </el-col>
                        <el-col :span="6">
                          <div class="stat-item">
                            <div class="stat-value" style="color: #e6a23c">
                              {{ chronicStats.active }}
                            </div>
                            <div class="stat-label">活动期</div>
                          </div>
                        </el-col>
                        <el-col :span="6">
                          <div class="stat-item">
                            <div class="stat-value" style="color: #f56c6c">
                              {{ chronicStats.severe }}
                            </div>
                            <div class="stat-label">严重</div>
                          </div>
                        </el-col>
                        <el-col :span="6">
                          <div class="stat-item">
                            <div class="stat-value" style="color: #909399">
                              {{ chronicStats.total }}
                            </div>
                            <div class="stat-label">总数</div>
                          </div>
                        </el-col>
                      </el-row>
                    </div>
                  </div>
                </div>
              </el-col>
            </el-row>
          </el-form>
        </div>
      </div>
@@ -923,7 +1233,147 @@
        </div>
      </div> -->
    </div>
    <!-- 筛查摘要编辑对话框 -->
    <el-dialog
      :title="screeningEditing ? '编辑筛查记录' : '新增筛查记录'"
      :visible.sync="screeningDialogVisible"
      width="600px"
    >
      <el-form :model="screeningForm" label-width="100px">
        <el-form-item label="筛查类型" prop="screeningType" required>
          <el-select
            v-model="screeningForm.screeningType"
            placeholder="请选择筛查类型"
            style="width: 100%"
          >
            <el-option
              v-for="item in screeningTypeOptions"
              :key="item.value"
              :label="item.label"
              :value="item.value"
            >
            </el-option>
          </el-select>
        </el-form-item>
        <el-form-item label="筛查日期" prop="screeningDate" required>
          <el-date-picker
            v-model="screeningForm.screeningDate"
            type="datetime"
            value-format="yyyy-MM-dd HH:mm:ss"
            placeholder="选择筛查日期"
            style="width: 100%"
          >
          </el-date-picker>
        </el-form-item>
        <el-form-item label="筛查结果" prop="result" required>
          <el-select
            v-model="screeningForm.result"
            placeholder="请选择结果"
            style="width: 100%"
          >
            <el-option
              v-for="item in resultOptions"
              :key="item.value"
              :label="item.label"
              :value="item.value"
            >
            </el-option>
          </el-select>
        </el-form-item>
        <el-form-item label="详细结果" prop="details">
          <el-input
            type="textarea"
            :rows="3"
            v-model="screeningForm.details"
            placeholder="请输入详细结果信息"
          >
          </el-input>
        </el-form-item>
      </el-form>
      <div slot="footer" class="dialog-footer">
        <el-button @click="screeningDialogVisible = false">取消</el-button>
        <el-button type="primary" @click="saveScreening">确定</el-button>
      </div>
    </el-dialog>
    <!-- 慢病摘要编辑对话框 -->
    <el-dialog
      :title="chronicEditing ? '编辑慢病记录' : '新增慢病记录'"
      :visible.sync="chronicDialogVisible"
      width="600px"
    >
      <el-form :model="chronicForm" label-width="100px">
        <el-form-item label="疾病名称" prop="diseaseName" required>
          <el-select
            v-model="chronicForm.diseaseName"
            placeholder="请选择疾病名称"
            style="width: 100%"
          >
            <el-option
              v-for="item in diseaseOptions"
              :key="item.value"
              :label="item.label"
              :value="item.value"
            >
            </el-option>
          </el-select>
        </el-form-item>
        <el-form-item label="确诊日期" prop="diagnoseDate" required>
          <el-date-picker
            v-model="chronicForm.diagnoseDate"
            type="date"
            value-format="yyyy-MM-dd"
            placeholder="选择确诊日期"
            style="width: 100%"
          >
          </el-date-picker>
        </el-form-item>
        <el-form-item label="当前状态" prop="status" required>
          <el-select
            v-model="chronicForm.status"
            placeholder="请选择状态"
            style="width: 100%"
          >
            <el-option
              v-for="item in statusOptions"
              :key="item.value"
              :label="item.label"
              :value="item.value"
            >
            </el-option>
          </el-select>
        </el-form-item>
        <el-form-item label="当前治疗" prop="currentTreatment">
          <el-input
            type="textarea"
            :rows="2"
            v-model="chronicForm.currentTreatment"
            placeholder="请输入当前治疗方案"
          >
          </el-input>
        </el-form-item>
        <el-form-item label="随访计划" prop="followUpPlan">
          <el-input
            v-model="chronicForm.followUpPlan"
            placeholder="请输入随访计划"
          >
          </el-input>
        </el-form-item>
      </el-form>
      <div slot="footer" class="dialog-footer">
        <el-button @click="chronicDialogVisible = false">取消</el-button>
        <el-button type="primary" @click="saveChronicDisease">确定</el-button>
      </div>
    </el-dialog>
    <el-dialog :title="titletb" :visible.sync="AddanumberVisible">
      <el-form :model="numberform" label-width="100px">
        <el-form-item label="姓名">
@@ -984,7 +1434,7 @@
          </el-date-picker> -->
          <el-date-picker
            v-model="borninfoform.generatedTime"
             value-format="yyyy-MM-dd HH:mm:ss"
            value-format="yyyy-MM-dd HH:mm:ss"
            type="datetime"
            placeholder="选择日期时间"
          >
@@ -1065,6 +1515,24 @@
      sonactiveName: "inhospital", //健康监测导航
      sontwoactiveName: "weight", //医疗档案导航
      dynamicTags: [],
      // 筛查摘要相关数据
      screeningLoading: false,
      screeningSummaryData: [],
      screeningStats: {
        normal: 0,
        abnormal: 0,
        critical: 0,
      },
      // 慢病摘要相关数据
      chronicLoading: false,
      chronicDiseaseData: [],
      chronicStats: {
        stable: 0,
        active: 0,
        severe: 0,
        total: 0,
      },
      borninforules: {
        height: [
          { required: true, message: "身长不能为空", trigger: "blur" },
@@ -1166,6 +1634,58 @@
      xtechartdom: {},
      tzechartdom: {},
      tableData: [],
      // 筛查摘要编辑相关
      screeningEditing: false,
      screeningEditIndex: -1,
      screeningEditTemp: {},
      screeningDialogVisible: false,
      screeningForm: {
        screeningType: "",
        screeningDate: "",
        result: "正常",
        details: "",
      },
      // 慢病摘要编辑相关
      chronicEditing: false,
      chronicEditIndex: -1,
      chronicEditTemp: {},
      chronicDialogVisible: false,
      chronicForm: {
        diseaseName: "",
        diagnoseDate: "",
        status: "稳定",
        currentTreatment: "",
        followUpPlan: "",
      },
      // 筛选选项
      resultOptions: [
        { label: "正常", value: "正常" },
        { label: "异常", value: "异常" },
        { label: "危急", value: "危急" },
      ],
      statusOptions: [
        { label: "稳定", value: "稳定" },
        { label: "活动期", value: "活动期" },
        { label: "严重", value: "严重" },
      ],
      screeningTypeOptions: [
        { label: "心血管", value: "心血管" },
        { label: "糖尿病", value: "糖尿病" },
        { label: "肿瘤标志", value: "肿瘤标志" },
        { label: "肾功能", value: "肾功能" },
        { label: "呼吸系统", value: "呼吸系统" },
      ],
      diseaseOptions: [
        { label: "高血压", value: "高血压" },
        { label: "2型糖尿病", value: "2型糖尿病" },
        { label: "冠心病", value: "冠心病" },
        { label: "慢性肾病", value: "慢性肾病" },
      ],
      tableDatalist: [
        {
          id: 12,
@@ -1277,6 +1797,9 @@
    this.id = this.$route.query.id;
    this.getuserinfo();
    this.gettabList();
    // 初始化筛查和慢病数据
    this.initScreeningData();
    this.initChronicDiseaseData();
  },
  methods: {
@@ -1306,6 +1829,147 @@
          }
        });
      }
    },
    /** 筛查摘要 - 新增 */
    addScreening() {
      this.screeningEditing = false;
      this.screeningEditIndex = -1;
      this.screeningForm = {
        screeningType: "",
        screeningDate: new Date().toISOString().split("T")[0] + " 09:00:00",
        result: "正常",
        details: "",
      };
      this.screeningDialogVisible = true;
    },
    /** 筛查摘要 - 编辑 */
    editScreening(index, row) {
      this.screeningEditing = true;
      this.screeningEditIndex = index;
      this.screeningForm = { ...row };
      this.screeningDialogVisible = true;
    },
    /** 筛查摘要 - 保存 */
    saveScreening() {
      if (
        !this.screeningForm.screeningType ||
        !this.screeningForm.screeningDate
      ) {
        this.$message.error("请填写必填字段");
        return;
      }
      if (this.screeningEditing) {
        // 编辑现有记录
        this.screeningSummaryData.splice(this.screeningEditIndex, 1, {
          ...this.screeningForm,
          id: this.screeningSummaryData[this.screeningEditIndex].id,
        });
        this.$message.success("筛查记录修改成功");
      } else {
        // 新增记录
        const newRecord = {
          id: Date.now(), // 临时ID
          ...this.screeningForm,
          riskLevel: this.getRiskLevelByResult(this.screeningForm.result),
        };
        this.screeningSummaryData.unshift(newRecord);
        this.$message.success("筛查记录新增成功");
      }
      this.calculateScreeningStats();
      this.screeningDialogVisible = false;
    },
    /** 筛查摘要 - 删除 */
    deleteScreening(index, row) {
      this.$confirm("确定要删除这条筛查记录吗?", "提示", {
        confirmButtonText: "确定",
        cancelButtonText: "取消",
        type: "warning",
      })
        .then(() => {
          this.screeningSummaryData.splice(index, 1);
          this.calculateScreeningStats();
          this.$message.success("删除成功");
        })
        .catch(() => {});
    },
    /** 根据结果获取风险等级 */
    getRiskLevelByResult(result) {
      const riskMap = {
        正常: "low",
        异常: "medium",
        危急: "critical",
      };
      return riskMap[result] || "low";
    },
    /** 慢病摘要 - 新增 */
    addChronicDisease() {
      this.chronicEditing = false;
      this.chronicEditIndex = -1;
      this.chronicForm = {
        diseaseName: "",
        diagnoseDate: new Date().toISOString().split("T")[0],
        status: "稳定",
        currentTreatment: "",
        followUpPlan: "每月复诊一次",
      };
      this.chronicDialogVisible = true;
    },
    /** 慢病摘要 - 编辑 */
    editChronicDisease(index, row) {
      this.chronicEditing = true;
      this.chronicEditIndex = index;
      this.chronicForm = { ...row };
      this.chronicDialogVisible = true;
    },
    /** 慢病摘要 - 保存 */
    saveChronicDisease() {
      if (!this.chronicForm.diseaseName || !this.chronicForm.diagnoseDate) {
        this.$message.error("请填写必填字段");
        return;
      }
      if (this.chronicEditing) {
        // 编辑现有记录
        this.chronicDiseaseData.splice(this.chronicEditIndex, 1, {
          ...this.chronicForm,
          id: this.chronicDiseaseData[this.chronicEditIndex].id,
        });
        this.$message.success("慢病记录修改成功");
      } else {
        // 新增记录
        const newRecord = {
          id: Date.now(), // 临时ID
          ...this.chronicForm,
        };
        this.chronicDiseaseData.unshift(newRecord);
        this.$message.success("慢病记录新增成功");
      }
      this.calculateChronicStats();
      this.chronicDialogVisible = false;
    },
    /** 慢病摘要 - 删除 */
    deleteChronicDisease(index, row) {
      this.$confirm("确定要删除这条慢病记录吗?", "提示", {
        confirmButtonText: "确定",
        cancelButtonText: "取消",
        type: "warning",
      })
        .then(() => {
          this.chronicDiseaseData.splice(index, 1);
          this.calculateChronicStats();
          this.$message.success("删除成功");
        })
        .catch(() => {});
    },
    checkAgeExists(newAge) {
      // 假设已有数据存储在 this.existingData 中
@@ -1341,6 +2005,232 @@
      });
      // 联系信息
      this.getcontactlist();
    },
    /** 初始化筛查摘要数据 */
    initScreeningData() {
      // 模拟筛查摘要数据[1,4](@ref)
      this.screeningSummaryData = [
        {
          id: 1,
          screeningType: "心血管",
          screeningDate: "2024-11-15 09:00:00",
          result: "异常",
          details: "心电图显示ST段压低,建议进一步检查",
          riskLevel: "high",
        },
        {
          id: 2,
          screeningType: "糖尿病",
          screeningDate: "2024-11-10 14:30:00",
          result: "正常",
          details: "空腹血糖5.6mmol/L,糖化血红蛋白5.8%",
          riskLevel: "low",
        },
        {
          id: 3,
          screeningType: "肿瘤标志",
          screeningDate: "2024-11-05 10:15:00",
          result: "危急",
          details: "CEA 15.2ng/mL,建议立即专科就诊",
          riskLevel: "critical",
        },
        {
          id: 4,
          screeningType: "肾功能",
          screeningDate: "2024-10-28 16:20:00",
          result: "异常",
          details: "肌酐清除率偏低,eGFR 55mL/min",
          riskLevel: "medium",
        },
        {
          id: 5,
          screeningType: "呼吸系统",
          screeningDate: "2024-10-20 11:00:00",
          result: "正常",
          details: "肺功能检查未见明显异常",
          riskLevel: "low",
        },
      ];
      // 计算统计信息
      this.calculateScreeningStats();
    },
    /** 计算筛查统计信息 */
    calculateScreeningStats() {
      this.screeningStats = {
        normal: this.screeningSummaryData.filter(
          (item) => item.result === "正常"
        ).length,
        abnormal: this.screeningSummaryData.filter(
          (item) => item.result === "异常"
        ).length,
        critical: this.screeningSummaryData.filter(
          (item) => item.result === "危急"
        ).length,
      };
    },
    /** 初始化慢病摘要数据 */
    initChronicDiseaseData() {
      // 模拟慢病摘要数据[2,5](@ref)
      this.chronicDiseaseData = [
        {
          id: 1,
          diseaseName: "高血压",
          diagnoseDate: "2020-03-15",
          status: "稳定",
          currentTreatment: "氨氯地平 5mg qd,定期监测血压",
          followUpPlan: "每月复诊一次",
        },
        {
          id: 2,
          diseaseName: "2型糖尿病",
          diagnoseDate: "2019-08-20",
          status: "活动期",
          currentTreatment: "二甲双胍 500mg bid,胰岛素注射",
          followUpPlan: "每两周复诊一次",
        },
        {
          id: 3,
          diseaseName: "冠心病",
          diagnoseDate: "2021-05-10",
          status: "稳定",
          currentTreatment: "阿司匹林 100mg qd,阿托伐他汀 20mg qd",
          followUpPlan: "每季度复诊一次",
        },
        {
          id: 4,
          diseaseName: "慢性肾病",
          diagnoseDate: "2022-01-30",
          status: "严重",
          currentTreatment: "控制血压、血糖,低蛋白饮食",
          followUpPlan: "每月专科随访",
        },
      ];
      // 计算统计信息
      this.calculateChronicStats();
    },
    /** 计算慢病统计信息 */
    calculateChronicStats() {
      this.chronicStats = {
        stable: this.chronicDiseaseData.filter((item) => item.status === "稳定")
          .length,
        active: this.chronicDiseaseData.filter(
          (item) => item.status === "活动期"
        ).length,
        severe: this.chronicDiseaseData.filter((item) => item.status === "严重")
          .length,
        total: this.chronicDiseaseData.length,
      };
    },
    /** 获取筛查类型标签样式 */
    getScreeningTagType(type) {
      const typeMap = {
        心血管: "danger",
        糖尿病: "warning",
        肿瘤标志: "danger",
        肾功能: "warning",
        呼吸系统: "success",
      };
      return typeMap[type] || "info";
    },
    /** 获取疾病名称标签样式 */
    getDiseaseTagType(diseaseName) {
      const diseaseMap = {
        高血压: "warning",
        "2型糖尿病": "danger",
        冠心病: "danger",
        慢性肾病: "danger",
      };
      return diseaseMap[diseaseName] || "info";
    },
    /** 查看筛查详情 */
    viewScreeningDetail(row) {
      this.$alert(
        `<div>
        <p><strong>筛查类型:</strong>${row.screeningType}</p>
        <p><strong>筛查日期:</strong>${this.formatTime(row.screeningDate)}</p>
        <p><strong>筛查结果:</strong><el-tag type="${
          row.result === "正常"
            ? "success"
            : row.result === "异常"
            ? "danger"
            : "warning"
        }">${row.result}</el-tag></p>
        <p><strong>详细结果:</strong>${row.details}</p>
        <p><strong>风险评估:</strong>${this.getRiskLevelText(
          row.riskLevel
        )}</p>
      </div>`,
        "筛查详情",
        {
          dangerouslyUseHTMLString: true,
          customClass: "detail-dialog",
        }
      );
    },
    /** 查看慢病详情 */
    viewChronicDetail(row) {
      this.$alert(
        `<div>
        <p><strong>疾病名称:</strong>${row.diseaseName}</p>
        <p><strong>确诊日期:</strong>${this.formatTime(row.diagnoseDate)}</p>
        <p><strong>当前状态:</strong><el-tag type="${
          row.status === "稳定"
            ? "success"
            : row.status === "活动期"
            ? "warning"
            : "danger"
        }">${row.status}</el-tag></p>
        <p><strong>当前治疗:</strong>${row.currentTreatment}</p>
        <p><strong>随访计划:</strong>${row.followUpPlan}</p>
      </div>`,
        "慢病详情",
        {
          dangerouslyUseHTMLString: true,
          customClass: "detail-dialog",
        }
      );
    },
    /** 获取风险等级文本 */
    getRiskLevelText(level) {
      const levelMap = {
        low: "低风险",
        medium: "中风险",
        high: "高风险",
        critical: "危急",
      };
      return levelMap[level] || "未知";
    },
    /** 刷新筛查数据 */
    refreshScreeningData() {
      this.screeningLoading = true;
      // 模拟异步加载
      setTimeout(() => {
        this.initScreeningData();
        this.screeningLoading = false;
        this.$message.success("筛查数据已刷新");
      }, 1000);
    },
    /** 刷新慢病数据 */
    refreshChronicData() {
      this.chronicLoading = true;
      // 模拟异步加载
      setTimeout(() => {
        this.initChronicDiseaseData();
        this.chronicLoading = false;
        this.$message.success("慢病数据已刷新");
      }, 1000);
    },
    // 保存患者档案
    savefile() {
@@ -2370,6 +3260,81 @@
    }
  }
}
.screening-summary,
.chronic-disease-summary {
  background: #ffffff;
  border: 1px solid #e6e6e6;
  border-radius: 4px;
  margin-bottom: 20px;
  .summary-header {
    display: flex;
    align-items: center;
    padding: 12px 15px;
    background: #f5f7fa;
    border-bottom: 1px solid #e6e6e6;
    font-weight: 600;
    color: #333;
    i {
      margin-right: 8px;
      color: #409eff;
    }
  }
  .summary-content {
    padding: 15px;
    .summary-stats {
      margin-top: 15px;
      padding-top: 15px;
      border-top: 1px dashed #e6e6e6;
      .stat-item {
        text-align: center;
        .stat-value {
          font-size: 24px;
          font-weight: bold;
          margin-bottom: 5px;
        }
        .stat-label {
          font-size: 12px;
          color: #909399;
        }
      }
    }
  }
}
/* 详情对话框样式 */
:deep(.detail-dialog) {
  .el-message-box__message {
    p {
      margin: 10px 0;
      line-height: 1.6;
    }
    strong {
      color: #333;
      min-width: 80px;
      display: inline-block;
    }
  }
}
/* 响应式设计 */
@media (max-width: 1200px) {
  .screening-summary,
  .chronic-disease-summary {
    .summary-content {
      .el-table {
        font-size: 12px;
      }
    }
  }
}
.xinz-inf {
  font-size: 18px;
  // white-space: nowrap;
@@ -2470,4 +3435,24 @@
::v-deep.el-table .warning-row {
  background: oldlace;
}
/* 操作按钮组样式 */
.summary-header .el-button-group {
  margin-left: auto;
}
/* 对话框表单样式 */
.el-dialog .el-form-item {
  margin-bottom: 20px;
}
/* 统计数字样式优化 */
.stat-item {
  cursor: pointer;
  transition: all 0.3s;
}
.stat-item:hover {
  background-color: #f5f7fa;
  border-radius: 4px;
}
</style>