Преглед изворни кода

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

Xiao_123 пре 11 месеци
родитељ
комит
2623a87c6a

+ 1 - 0
components.d.ts

@@ -31,6 +31,7 @@ declare module 'vue' {
     Info: typeof import('./src/components/Enterprise/info.vue')['default']
     Introduction: typeof import('./src/components/Enterprise/components/introduction.vue')['default']
     Item: typeof import('./src/components/Position/item.vue')['default']
+    ItemGroup: typeof import('./src/components/FormUI/itemGroup/index.vue')['default']
     JobTypeCard: typeof import('./src/components/jobTypeCard/index.vue')['default']
     ListGroup: typeof import('./src/components/FormUI/nestedListGroup/components/listGroup.vue')['default']
     LongCompany: typeof import('./src/components/Position/longCompany.vue')['default']

+ 11 - 2
src/components/FormUI/nestedListGroup/components/listGroup.vue

@@ -17,20 +17,29 @@
         <template v-slot:activator="{ props }">
           <v-list-item v-bind="props" :title="val[item.itemText || 'label']"></v-list-item>
         </template>
-        <v-list-item
+        <template v-if="!val.children?.length">
+          <v-list-item
+            active-class="active"
+            color="primary"
+            :title="val[item.itemText || 'label']"
+          >
+          </v-list-item>
+        </template>
+        <!-- <v-list-item
           v-for="(k, i) in val.children"
           :key="`k_${i}`"
           color="primary"
           style="padding-left: 40px;"
           :title="k[item.itemText || 'label']"
           :value="k[item.itemValue || 'value']"
-        ></v-list-item>
+        ></v-list-item> -->
       </v-list-group>
     </template>
   </v-list>
 </template>
 
 <script setup>
+import listGroup from './listGroup'
 defineOptions({ name:'nestedListGroup-listGroup'})
 const propsData = defineProps({item: Object})
 const item = propsData.item

+ 4 - 2
src/components/FormUI/nestedListGroup/index.vue

@@ -30,7 +30,8 @@
           @update:modelValue="modelValueUpDate"
         ></v-text-field>
       </template>
-      <v-list class="side-box" color="primary">
+      <listGroup :item="item"></listGroup>
+      <!-- <v-list class="side-box" color="primary">
         <template v-for="(val, index) in item.items" :key="item?.itemValue? val[item.itemValue] : index">
           <template v-if="!val.children?.length">
             <v-list-item
@@ -58,12 +59,13 @@
             ></v-list-item>
           </v-list-group>
         </template>
-      </v-list>
+      </v-list> -->
     </v-menu>
   </div>
 </template>
 
 <script setup>
+import listGroup from './components/listGroup'
 import { defineEmits, ref } from 'vue';
 defineOptions({ name:'FormUI-nestedListGroup'})
 const propsData = defineProps({item: Object, modelValue: [String, Number]})

+ 15 - 6
src/layout/personal/navBar.vue

@@ -87,13 +87,16 @@
         
       </div>
     </v-toolbar>
-    <!-- <Dialog :visible="show" title="提示" :footer="false" widthType="2" @close="show = false">
-      <div class="mb-3 text-center" style="color: #999;">
+    <CtDialog :visible="show" title="提示" :footer="true" widthType="2" @close="show = false" @submit="handleSubmit">
+      <!-- <div class="mb-3 text-center" style="color: #999;">
         <div class="mb-5">您还未加入或注册企业, 请选择您要操作的类型!</div>
         <v-btn class="half-button" size="small" color="primary" variant="tonal" @click="handleChange(0)">加入企业</v-btn>
         <v-btn class="half-button ml-5" size="small" color="primary" variant="tonal" @click="handleChange(1)">{{ $t('enterprise.registeringNewEnterprise') }}</v-btn>
-      </div>
-    </Dialog> -->
+      </div> -->
+      <v-radio-group v-model="radios">
+        <v-radio v-for="item in enterpriseList" :key="item.enterpriseId" color="primary" :label="item.enterpriseName" :value="item.enterpriseId"></v-radio>
+      </v-radio-group>
+    </CtDialog>
   </div>
 </template>
 
@@ -103,6 +106,7 @@ import { getToken } from '@/utils/auth'
 import { useUserStore } from '@/store/user'
 import { useLocaleStore } from '@/store/locale'
 import { useI18n } from '@/hooks/web/useI18n'
+import CtDialog from '@/components/CtDialog'
 import { getUserBindEnterpriseList, getUserRegisterEnterpriseApply } from '@/api/personal/user'
 defineOptions({ name: 'personal-navbar' })
 
@@ -126,8 +130,12 @@ const list = ref([
 import { useRouter } from 'vue-router'
 const router = useRouter()
 const handleLogoClick = () => { router.push({ path: '/home'}) }
+const handleSubmit = () => { toEnterprise(radios.value) }
 
 // 查看用户是否有企业
+const show = ref(false)
+const radios = ref(null)
+const enterpriseList = ref([])
 const changeLoginType = async () => {
   // router.push({ path: '/login' })
   // router.push({ name: 'login', query: { loginType: 330 } })
@@ -136,8 +144,9 @@ const changeLoginType = async () => {
     // localStorage.setItem('companyInfo', JSON.stringify(data))
     // changeRole()
     if (data.length > 1) {
-      // 未开发
-      toEnterprise(data[0].enterpriseId)
+      show.value = true
+      enterpriseList.value = data
+      radios.value = data[0].enterpriseId
     } else {
       //只有一个企业直接切换
       toEnterprise(data[0].enterpriseId)

+ 10 - 8
src/views/resume/index.vue

@@ -39,6 +39,8 @@ import educationExp from './components/educationExp.vue'
 import workExperience from './components/workExperience.vue'
 import projectExperience from './components/projectExperience.vue'
 import vocationalSkills from './components/vocationalSkills.vue'
+import { useI18n } from '@/hooks/web/useI18n'
+const { t } = useI18n()
 import { ref } from 'vue'
 import { onMounted } from 'vue';
 const scrollBox = ref()
@@ -55,14 +57,14 @@ const comList = [
 ]
 
 const items = [
-  { text: '基本信息', icon: 'mdi-account-outline', id: 'basicInfo' },
-  { text: '个人优势', icon: 'mdi-account-star-outline', id: 'selfEvaluation' },
-  { text: '求职意向', icon: 'mdi-briefcase-variant-outline', id: 'jobIntention' },
-  { text: '教育经历', icon: 'mdi-school-outline', id: 'educationExp' },
-  { text: '工作经历', icon: 'mdi-ballot-outline', id: 'workExperience' },
-  { text: '项目经历', icon: 'mdi-card-text-outline', id: 'projectExperience' },
-  { text: '培训经历', icon: 'mdi-flag-outline', id: 'trainingExperience' },
-  { text: '职业技能', icon: 'mdi-star-check-outline', id: 'vocationalSkills' }
+  { text: t('resume.basicInfo'), icon: 'mdi-account-outline', id: 'basicInfo' },
+  { text: t('resume.personalAdvantages'), icon: 'mdi-account-star-outline', id: 'selfEvaluation' },
+  { text: t('resume.jobIntention'), icon: 'mdi-briefcase-variant-outline', id: 'jobIntention' },
+  { text: t('resume.educationExp'), icon: 'mdi-school-outline', id: 'educationExp' },
+  { text: t('resume.workExperience'), icon: 'mdi-ballot-outline', id: 'workExperience' },
+  { text: t('resume.projectExperience'), icon: 'mdi-card-text-outline', id: 'projectExperience' },
+  { text: t('resume.trainingExperience'), icon: 'mdi-flag-outline', id: 'trainingExperience' },
+  { text: t('resume.vocationalSkills'), icon: 'mdi-star-check-outline', id: 'vocationalSkills' }
 ]
 
 onMounted(() => {