hejianhao
2026-04-02 a9ba32b9d04ae91104a64ababad72ff8e77f003b
fix: 修复设备租赁单位和联系人显示问题
2个文件已修改
45 ■■■■■ 已修改文件
screen/src/components/customDialog.vue 2 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
screen/src/view/projectHome/index.vue 43 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
screen/src/components/customDialog.vue
@@ -1,6 +1,6 @@
<template>
  <div>
    <el-dialog v-bind="$attrs" v-on="$listeners">
    <el-dialog v-bind="$attrs" v-on="$listeners" :modal-append-to-body="false">
      <slot></slot>
    </el-dialog>
  </div>
screen/src/view/projectHome/index.vue
@@ -108,7 +108,16 @@
                <div class="flex2 flex">
                  <div class="label dept">
                    设备租赁单位
                  </div>
                  <div class="value" v-if="filteredRentalUnits.length >= 1">
                    {{
                      filteredRentalUnits[0][
                        "工程起重机械租赁单位"
                      ] || "-"
                    }}
                  </div>
                    <el-tooltip
                      style="margin-left: 10px"
                      v-if="filteredRentalUnits.length > 1"
                      placement="top"
                      effect="dark"
@@ -129,19 +138,18 @@
                        filteredRentalUnits.length
                      }}</span>
                    </el-tooltip>
                  </div>
                  <div class="value" v-if="filteredProperties.length ==1">
                    {{
                      filteredProperties[0][
                        "工程起重机械租赁单位"
                      ] || "-"
                    }}
                  </div>
                </div>
                <div class="flex1 flex">
                  <div class="label">
                    联系人
                  </div>
                  <div class="value" v-if="filteredContacts.length >= 1">
                    {{
                      filteredContacts[0]["联系人"] || "-"
                    }}
                  </div>
                    <el-tooltip
                      style="margin-left: 10px"
                      v-if="filteredContacts.length > 1"
                      placement="top"
                      effect="dark"
@@ -156,7 +164,7 @@
                            联系人{{ index + 1 }}:
                          </div>
                          <div class="tooltip-value">
                            {{ item["联系电话"] || "-" }}
                            {{ item["联系人"] || "-" }}
                          </div>
                        </div>
                      </div>
@@ -164,12 +172,6 @@
                        filteredContacts.length
                      }}</span>
                    </el-tooltip>
                  </div>
                  <div class="value" v-if="filteredContacts.length ==1">
                    {{
                      filteredProperties[0]["联系电话"] || "-"
                    }}
                  </div>
                </div>
              </div>
              <div class="info-item11">
@@ -772,7 +774,6 @@
      this.projectInfo.properties.forEach((itemStr) => {
        try {
          const item = JSON.parse(itemStr)
          console.log('item item', item)
          const rentalUnit = item['工程起重机械租赁单位']
          if (!rentalUnit) return
          const key = String(rentalUnit).trim()
@@ -784,8 +785,6 @@
        }
      })
      console.log('1111111111111', list)
      return list
    },
    filteredContacts () {
@@ -802,13 +801,13 @@
      this.projectInfo.properties.forEach((itemStr) => {
        try {
          const item = JSON.parse(itemStr)
          const contact = item['联系电话']
          if (!contact) return
          const key = String(contact).trim()
          const name = item['联系人']
          if (!name) return
          const key = String(name).trim()
          if (!key) return
          if (seen.has(key)) return
          seen.add(key)
          list.push({ '联系电话': contact })
          list.push({ '联系人': name })
        } catch (e) {
        }