From 9153c2090229132eb59ad286604946458e09a722 Mon Sep 17 00:00:00 2001
From: odjbin <1042039504@qq.com>
Date: Sat, 15 Jun 2024 00:47:17 +0800
Subject: [PATCH] =?UTF-8?q?fix=20:=20=E4=BF=AE=E5=A4=8D=E5=85=AC=E5=8F=B8?=
=?UTF-8?q?=E9=80=89=E6=8B=A9=E6=A1=86=E5=85=A8=E9=80=89=E5=8A=9F=E8=83=BD?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../DetailComponent/CompanyPicker.vue | 31 +++++++++++++++----
1 file changed, 25 insertions(+), 6 deletions(-)
diff --git a/src/components/DetailComponent/CompanyPicker.vue b/src/components/DetailComponent/CompanyPicker.vue
index 0e7e54e..222f8c6 100644
--- a/src/components/DetailComponent/CompanyPicker.vue
+++ b/src/components/DetailComponent/CompanyPicker.vue
@@ -5,14 +5,16 @@
+ clearable placeholder="输入公司进行搜索">
搜索
+
全选
+
不全选
-
+
filterText.value, (newVal) => {
tree.value.filter(newVal);
});
-
+const matterTree=(list)=>{
+ list.forEach(item=>{
+ tree.value.setChecked(item,true)
+ if(item.children!==undefined){
+ matterTree(item.children)
+ }
+ })
+}
+const cancelAll=()=>{
+ isChooseAll.value=true
+ tree.value.setCheckedNodes([])
+}
+const chooseAll=()=>{
+ isChooseAll.value=false
+ matterTree(dataList.value)
+}
const getList = () => {
getSubCompOpt().then(res => {
dataList.value = res.data;
@@ -252,6 +270,7 @@ $containWidth: 480px;
.footer {
float: right;
+ margin-top: 10px;
}
.picker {
@@ -261,9 +280,9 @@ $containWidth: 480px;
.candidate {
position: absolute;
- display: inline-block;
+ display: block;
width: $containWidth;
- height: 98%;
+ height: 100%;
border: 1px solid #e8e8e8;
:deep(.el-input) {
@@ -281,7 +300,7 @@ $containWidth: 480px;
position: absolute;
display: inline-block;
width: 450px;
- height: 98%;
+ height: 100%;
border: 1px solid #e8e8e8;
.count {