| | |
| | | |
| | | <div class="orgTreeBox" id="org-tree-container"> |
| | | <vue3-tree-org |
| | | :data="deptList" |
| | | :data="deptTree" |
| | | :horizontal="false" |
| | | :props="treeProps" |
| | | :toolBar="tools" |
| | |
| | | children: [] |
| | | }, |
| | | treeProps: { |
| | | label: 'deptName' |
| | | label: 'label' |
| | | }, |
| | | tools: { |
| | | scale: false, restore: false, expand: false, zoom: false, fullscreen: false |
| | |
| | | executionDate: '' |
| | | }, |
| | | formRules: {}, |
| | | userList: [] |
| | | userList: [], |
| | | deptTree: { |
| | | id: 0, |
| | | label: "", |
| | | children: [] |
| | | } |
| | | }); |
| | | |
| | | const { |
| | |
| | | dialogVisible, |
| | | dialogForm, |
| | | formRules, |
| | | userList |
| | | userList, |
| | | deptTree |
| | | } = toRefs(data); |
| | | const userInfo = ref() |
| | | const formRef = ref() |
| | |
| | | if (res.code == 200) { |
| | | data.originDeptList = JSON.parse(JSON.stringify(res.data)) |
| | | data.deptList.deptName = val.companyName |
| | | data.deptTree.label = val.companyName |
| | | data.deptList.children = proxy.handleTree(res.data, "deptId") |
| | | } else { |
| | | ElMessage.warning(res.message) |
| | |
| | | loading.value = false |
| | | return Promise.reject(new Error('该企业暂无质量数据')) |
| | | } |
| | | data.deptTree.children = res.data.treeSelects || [] |
| | | console.log(data.deptTree,'tree') |
| | | data.companyInfo.summaries = res.data.companySummaries ? res.data.companySummaries[0]?.companySummary : [] |
| | | data.companyInfo.policies = res.data.companyQualityPolicies ? res.data.companyQualityPolicies[0]?.policy : [] |
| | | const duties = transToTableData(res.data.sysFunctionalDistributions, data.originDeptList) |
| | |
| | | }) || [] |
| | | data.companyInfo.productServiceImages = res.data.productServiceDatas ? await processImagesToBase64(res.data.productServiceDatas) : [] |
| | | data.companyInfo.proclaim1 = res.data.proclaim.find(i=>i.type == 1)?.content || '' |
| | | data.companyInfo.sign1 = await urlToBase64(res.data.proclaim.find(i=>i.type == 1)?.sign) || '' |
| | | // data.companyInfo.sign1 = await urlToBase64(res.data.proclaim.find(i=>i.type == 1)?.sign) || '' |
| | | data.companyInfo.updateTime1 = res.data.proclaim.find(i=>i.type == 1 && i.status == 1)?.updateTime?.substring(0,10) || '' |
| | | data.companyInfo.proclaim2 = res.data.proclaim.find(i=>i.type == 2)?.content || '' |
| | | data.companyInfo.sign2 = await urlToBase64(res.data.proclaim.find(i=>i.type == 2)?.sign) || '' |
| | | // data.companyInfo.sign2 = await urlToBase64(res.data.proclaim.find(i=>i.type == 2)?.sign) || '' |
| | | data.companyInfo.updateTime2 = res.data.proclaim.find(i=>i.type == 2 && i.status == 1)?.updateTime?.substring(0,10) || '' |
| | | data.companyInfo.proclaim3 = res.data.proclaim.find(i=>i.type == 3)?.content || '' |
| | | data.companyInfo.sign3 = await urlToBase64(res.data.proclaim.find(i=>i.type == 3)?.sign) || '' |
| | | // data.companyInfo.sign3 = await urlToBase64(res.data.proclaim.find(i=>i.type == 3)?.sign) || '' |
| | | data.companyInfo.updateTime3 = res.data.proclaim.find(i=>i.type == 3 && i.status == 1)?.updateTime?.substring(0,10) || '' |
| | | data.companyInfo.proclaim4 = res.data.proclaim.find(i=>i.type == 4)?.content || '' |
| | | data.companyInfo.sign4 = await urlToBase64(res.data.proclaim.find(i=>i.type == 4)?.sign) || '' |
| | | // data.companyInfo.sign4 = await urlToBase64(res.data.proclaim.find(i=>i.type == 4)?.sign) || '' |
| | | data.companyInfo.updateTime4 = res.data.proclaim.find(i=>i.type == 4 && i.status == 1)?.updateTime?.substring(0,10) || '' |
| | | } else { |
| | | ElMessage.warning(res.message) |
| | |
| | | </script> |
| | | <style lang="scss"> |
| | | .orgTreeBox { |
| | | width: 700px; |
| | | height: 700px; |
| | | width: 1200px; |
| | | height: 1200px; |
| | | position: absolute; /* 或 fixed */ |
| | | left: -9999px; /* 移出可视区域 */ |
| | | pointer-events: none; /* 禁止交互 */ |