Przeglądaj źródła

Merge branch 'master' of http://119.23.210.103:3000/WuYi/zdqy_firm_former

huangws 2 dni temu
rodzic
commit
6f8494f632

+ 2 - 4
src/business/platform/form/formrender/dynamic-form/dynamic-form.vue

@@ -355,10 +355,8 @@ export default {
         params: [this.formDef.key]
       })
       const { data = [] } = res.variables || {}
-      this.formReference =
-        data.length > 0
-          ? `${data[0].bian_hao_} ${data[0].sheng_xiao_ri_qi_}`
-          : ''
+      this.formReference = data.length > 0 ? `${data[0].zi_ding_yi_biao_d}` : ''
+      console.log(data, this.formReference, 'this.formReference')
     }
   },
   mounted() {

+ 7 - 1
src/views/component/personnelFile/components/personnelInfo.vue

@@ -12,7 +12,7 @@
       <div class="photoSty">
         <el-avatar
           :src="getPhoto(personInfoData.photo)"
-          fit="fit"
+          class="center-avatar"
           @error="errorHandler"
         >
           <img src="/images/common/default_user_image.jpg" />
@@ -488,6 +488,12 @@ export default {
         width: 14vh;
         border-radius: 100%;
       }
+      .center-avatar ::v-deep img {
+        object-fit: contain; /* 保持比例完整显示 */
+        object-position: center; /* 居中 */
+        width: 100%;
+        height: 100%;
+      }
     }
     .contentSty {
       height: 100%;

+ 16 - 1
src/views/system/fasc/index.vue

@@ -11,7 +11,7 @@
         class="clearfix fasc-card-hearder"
         @click="goToDetailPage(card)"
       >
-        <span>{{ card.facs_type.split('-')[1] }}</span>
+        <span>{{ getFacsTypeTitle(card.facs_type) }}</span>
       </div>
 
       <el-collapse v-model="card.activeName" accordion>
@@ -60,6 +60,13 @@ export default {
       cardInfos: []
     }
   },
+  computed: {
+    // 设施环境类型配置(来自全局配置 facilityEnv.typeList)
+    facilityEnvTypeList() {
+      const { setting = {} } = this.$store.getters
+      return setting?.facilityEnv?.typeList || {}
+    }
+  },
   mounted() {
     getFacsDaily().then((res) => {
       const list = {
@@ -144,6 +151,14 @@ export default {
     })
   },
   methods: {
+    // 设施环境类型标题:优先取 facilityEnv.typeList 中配置的 label,没有则取 key 中 '-' 后面的名称
+    getFacsTypeTitle(facs_type) {
+      if (!facs_type) return ''
+      const typeList = this.facilityEnvTypeList
+      const label = typeList[facs_type]?.label
+      if (label) return label
+      return facs_type.split('-')[1] || facs_type
+    },
     goToDetailPage(card) {
       if (!card.pagePath) {
         this.$message.warning('该卡片暂未配置页面路径')