Przeglądaj źródła

Merge branch 'dev' of https://git.citupro.com/zhengnaiwen_citu/menduner into dev

Xiao_123 6 miesięcy temu
rodzic
commit
fa8bbda4f4

+ 10 - 0
src/views/recruit/enterprise/entInfoSetting/index.vue

@@ -28,6 +28,7 @@
         <template v-for="item in tabList" :key="item.id">
           <div v-show="item.value === tab">
             <component
+              ref="componentRef"
               :is="item.path"
               @complete="handleComplete"
             />
@@ -53,6 +54,8 @@ import {
 } from 'vue-router'
 import { useI18n } from '@/hooks/web/useI18n'
 
+const componentRef = ref()
+
 const route = useRoute()
 const { t } = useI18n()
 // tab
@@ -104,6 +107,13 @@ const handleComplete = (val) => { // completeNum: tab内完成数, totalNum: tab
     item.totalCount = val.totalCount || 0
   }
   calcCompletion()
+  // 目前 基础信息里面的企业名称 和工商信息里面的企业名称 没有要求需要一致
+  // if (val.isUpdate && val.id === 'businessInformation') {
+  //   // 工商信息更改同时更新基本信息
+  //   if (componentRef.value?.length) {
+  //     componentRef.value[0].getBaseInfo()
+  //   }
+  // }
 }
 </script>
 

+ 2 - 1
src/views/recruit/enterprise/entInfoSetting/informationSettingsComponents/basicInfo.vue

@@ -195,6 +195,7 @@ getDict('menduner_industry_type', {}, 'industryList').then(({ data }) => {
 //   return obj
 // })
 
+
 // 获取基本信息
 const getBaseInfo = async () => {
   let completeCount = 0
@@ -245,7 +246,7 @@ const handleSave = async () => {
 }
 
 // defineExpose({
-//   getAuthInfo
+//   getBaseInfo
 // })
 </script>
 

+ 4 - 3
src/views/recruit/enterprise/entInfoSetting/informationSettingsComponents/businessInformation.vue

@@ -192,8 +192,6 @@ const query = reactive({})
 
 // licenseUrl.value = info?.businessLicenseUrl ?? ''
 
-
-
 const handleSave = async () => {
   const { valid } = await CtFormRef.value.formRef.validate()
   if (!valid) return
@@ -205,13 +203,16 @@ const handleSave = async () => {
   if (!query.establishmentTime) return Snackbar.warning('请选择成立时间')
   await updateEnterpriseBusiness(query)
   Snackbar.success('编辑成功')
+  isUpdate = true
   getBaseInfo()
 }
 
+let isUpdate = false // 是否同时更新基本信息
 // 完成度展示
 const completeFun = (completeCount = 0) => {
   const totalCount = formItems.value.options?.length || 0
-  emit('complete', { totalCount, completeCount, id: 'businessInformation' })
+  emit('complete', { totalCount, completeCount, id: 'businessInformation', isUpdate })
+  isUpdate = false // 重置
 }
 
 // 识别营业执照图片