From 5b6c4c659710814ea5f59dcab8ac64ddd8acfe6f Mon Sep 17 00:00:00 2001
From: zhouwx <1175765986@qq.com>
Date: 星期四, 03 七月 2025 14:08:44 +0800
Subject: [PATCH] 模板导入
---
src/views/build/conpanyFunctionConsult/companyInfo/basicInfo/components/basicInfoDialog.vue | 24 ++++++++++++++++++++++--
1 files changed, 22 insertions(+), 2 deletions(-)
diff --git a/src/views/build/conpanyFunctionConsult/companyInfo/basicInfo/components/basicInfoDialog.vue b/src/views/build/conpanyFunctionConsult/companyInfo/basicInfo/components/basicInfoDialog.vue
index c6db9e0..fd4945d 100644
--- a/src/views/build/conpanyFunctionConsult/companyInfo/basicInfo/components/basicInfoDialog.vue
+++ b/src/views/build/conpanyFunctionConsult/companyInfo/basicInfo/components/basicInfoDialog.vue
@@ -65,7 +65,7 @@
</div>
</template>
<script setup>
-import {reactive, ref, toRefs} from 'vue'
+import {onMounted, reactive, ref, toRefs} from 'vue'
import Editor from "@/components/Editor/index.vue";
import {ElMessage} from "element-plus";
import {addNotice} from "@/api/backManage/notice";
@@ -109,10 +109,17 @@
companyList: []
})
+onMounted(() => {
+})
const openDialog = async (type, value) => {
+
+
const userInfo = JSON.parse(Cookies.get('userInfo'))
state.isAdmin = userInfo.userType === 0;
+ if(state.isAdmin){
+ await getCompanyList()
+ }
title.value = type === 'add' ? '新增' : type ==='edit' ? '编辑' : '查看' ;
if(type === 'edit' || type === 'review') {
state.form = JSON.parse(JSON.stringify(value));
@@ -197,7 +204,7 @@
})
}
const getCompanyList = async (val)=>{
- if(val != ""){
+ if(val){
const queryParams = {
name: val
}
@@ -208,6 +215,19 @@
} else {
ElMessage.warning(res.message)
}
+ }else {
+
+ const queryParams = {
+ pageSize: 10,
+ pageNum: 1,
+ }
+ const res = await getCompany(queryParams)
+ if (res.code == 200) {
+ state.companyList = res.data.list
+
+ } else {
+ ElMessage.warning(res.message)
+ }
}
}
defineExpose({
--
Gitblit v1.9.2