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 {