Element tree setChecked doesn't work?

[

]
{
    "FolderId":"folder_001",
    "FolderName":"",
    "FolderLevel":0,
    "Disable":true,
    "children":[
        {
            "FolderId":"folder_005",
            "FolderName":"2",
            "FolderLevel":1,
            "Disable":true,
            "children":[
                {
                    "FolderId":"folder_1530757700031164600",
                    "FolderName":"111",
                    "FolderLevel":2,
                    "Disable":true,
                    "children":[
                        {
                            "DeviceId":"device_00001112",
                            "DeviceName":"name2",
                            "Protocol":"28281",
                            "GbId":"5.20000000000122e+20",
                            "Server":{
                                "ServerId":"server_0000001",
                                "ServerName":"",
                                "Protocol":"",
                                "GbId":"",
                                "Launch":false,
                                "ServerIp":"",
                                "ServerPort":0,
                                "ServerPassword":"",
                                "Devices":null
                            },
                            "StreamServerId":"",
                            "RtmpUrl":"",
                            "HttpFlvUrl":"",
                            "HlsUrl":"",
                            "ClientId":"",
                            "Launch":true,
                            "HasPtz":true,
                            "DeviceIp":"",
                            "DevicePort":0,
                            "DevicePassword":"",
                            "label":"name2",
                            "id":"device_00001112",
                            "disabled":false
                        }
                    ],
                    "label":"111",
                    "id":"folder_1530757700031164600",
                    "disabled":true
                },
                {
                    "DeviceId":"device_00001111",
                    "DeviceName":"name1",
                    "Protocol":"28281",
                    "GbId":"520000000000122345550",
                    "Server":{
                        "ServerId":"server_0000001",
                        "ServerName":"",
                        "Protocol":"",
                        "GbId":"",
                        "Launch":false,
                        "ServerIp":"",
                        "ServerPort":0,
                        "ServerPassword":"",
                        "Devices":null
                    },
                    "StreamServerId":"",
                    "RtmpUrl":"",
                    "HttpFlvUrl":"",
                    "HlsUrl":"",
                    "ClientId":"",
                    "Launch":true,
                    "HasPtz":true,
                    "DeviceIp":"",
                    "DevicePort":0,
                    "DevicePassword":"",
                    "label":"name1",
                    "id":"device_00001111",
                    "disabled":false
                }
            ],
            "label":"2",
            "id":"folder_005",
            "disabled":true
        },
        {
            "FolderId":"folder_004",
            "FolderName":"1",
            "FolderLevel":1,
            "Disable":true,
            "children":[
                {
                    "DeviceId":"device_00001111",
                    "DeviceName":"name1",
                    "Protocol":"28281",
                    "GbId":"520000000000122345550",
                    "Server":{
                        "ServerId":"server_0000001",
                        "ServerName":"",
                        "Protocol":"",
                        "GbId":"",
                        "Launch":false,
                        "ServerIp":"",
                        "ServerPort":0,
                        "ServerPassword":"",
                        "Devices":null
                    },
                    "StreamServerId":"",
                    "RtmpUrl":"",
                    "HttpFlvUrl":"",
                    "HlsUrl":"",
                    "ClientId":"",
                    "Launch":true,
                    "HasPtz":true,
                    "DeviceIp":"",
                    "DevicePort":0,
                    "DevicePassword":"",
                    "label":"name1",
                    "id":"device_00001111",
                    "disabled":false
                },
                {
                    "DeviceId":"device_00001112",
                    "DeviceName":"name2",
                    "Protocol":"28281",
                    "GbId":"5.20000000000122e+20",
                    "Server":{
                        "ServerId":"server_0000001",
                        "ServerName":"",
                        "Protocol":"",
                        "GbId":"",
                        "Launch":false,
                        "ServerIp":"",
                        "ServerPort":0,
                        "ServerPassword":"",
                        "Devices":null
                    },
                    "StreamServerId":"",
                    "RtmpUrl":"",
                    "HttpFlvUrl":"",
                    "HlsUrl":"",
                    "ClientId":"",
                    "Launch":true,
                    "HasPtz":true,
                    "DeviceIp":"",
                    "DevicePort":0,
                    "DevicePassword":"",
                    "label":"name2",
                    "id":"device_00001112",
                    "disabled":false
                }
            ],
            "label":"1",
            "id":"folder_004",
            "disabled":true
        },
        {
            "FolderId":"folder_003",
            "FolderName":"",
            "FolderLevel":1,
            "Disable":true,
            "children":[
                {
                    "DeviceId":"device_00001112",
                    "DeviceName":"name2",
                    "Protocol":"28281",
                    "GbId":"5.20000000000122e+20",
                    "Server":{
                        "ServerId":"server_0000001",
                        "ServerName":"",
                        "Protocol":"",
                        "GbId":"",
                        "Launch":false,
                        "ServerIp":"",
                        "ServerPort":0,
                        "ServerPassword":"",
                        "Devices":null
                    },
                    "StreamServerId":"",
                    "RtmpUrl":"",
                    "HttpFlvUrl":"",
                    "HlsUrl":"",
                    "ClientId":"",
                    "Launch":true,
                    "HasPtz":true,
                    "DeviceIp":"",
                    "DevicePort":0,
                    "DevicePassword":"",
                    "label":"name2",
                    "id":"device_00001112",
                    "disabled":false
                },
                {
                    "DeviceId":"device_00001111",
                    "DeviceName":"name1",
                    "Protocol":"28281",
                    "GbId":"520000000000122345550",
                    "Server":{
                        "ServerId":"server_0000001",
                        "ServerName":"",
                        "Protocol":"",
                        "GbId":"",
                        "Launch":false,
                        "ServerIp":"",
                        "ServerPort":0,
                        "ServerPassword":"",
                        "Devices":null
                    },
                    "StreamServerId":"",
                    "RtmpUrl":"",
                    "HttpFlvUrl":"",
                    "HlsUrl":"",
                    "ClientId":"",
                    "Launch":true,
                    "HasPtz":true,
                    "DeviceIp":"",
                    "DevicePort":0,
                    "DevicePassword":"",
                    "label":"name1",
                    "id":"device_00001111",
                    "disabled":false
                }
            ],
            "label":"",
            "id":"folder_003",
            "disabled":true
        },
        {
            "FolderId":"folder_002",
            "FolderName":"",
            "FolderLevel":1,
            "Disable":true,
            "children":[
                {
                    "FolderId":"folder_008",
                    "FolderName":"",
                    "FolderLevel":2,
                    "Disable":true,
                    "children":[
                        {
                            "DeviceId":"device_00001112",
                            "DeviceName":"name2",
                            "Protocol":"28281",
                            "GbId":"5.20000000000122e+20",
                            "Server":{
                                "ServerId":"server_0000001",
                                "ServerName":"",
                                "Protocol":"",
                                "GbId":"",
                                "Launch":false,
                                "ServerIp":"",
                                "ServerPort":0,
                                "ServerPassword":"",
                                "Devices":null
                            },
                            "StreamServerId":"",
                            "RtmpUrl":"",
                            "HttpFlvUrl":"",
                            "HlsUrl":"",
                            "ClientId":"",
                            "Launch":true,
                            "HasPtz":true,
                            "DeviceIp":"",
                            "DevicePort":0,
                            "DevicePassword":"",
                            "label":"name2",
                            "id":"device_00001112",
                            "disabled":false
                        },
                        {
                            "DeviceId":"device_00001111",
                            "DeviceName":"name1",
                            "Protocol":"28281",
                            "GbId":"520000000000122345550",
                            "Server":{
                                "ServerId":"server_0000001",
                                "ServerName":"",
                                "Protocol":"",
                                "GbId":"",
                                "Launch":false,
                                "ServerIp":"",
                                "ServerPort":0,
                                "ServerPassword":"",
                                "Devices":null
                            },
                            "StreamServerId":"",
                            "RtmpUrl":"",
                            "HttpFlvUrl":"",
                            "HlsUrl":"",
                            "ClientId":"",
                            "Launch":true,
                            "HasPtz":true,
                            "DeviceIp":"",
                            "DevicePort":0,
                            "DevicePassword":"",
                            "label":"name1",
                            "id":"device_00001111",
                            "disabled":false
                        }
                    ],
                    "label":"",
                    "id":"folder_008",
                    "disabled":true
                },
                {
                    "FolderId":"folder_007",
                    "FolderName":"",
                    "FolderLevel":2,
                    "Disable":true,
                    "children":[
                        {
                            "DeviceId":"device_00001112",
                            "DeviceName":"name2",
                            "Protocol":"28281",
                            "GbId":"5.20000000000122e+20",
                            "Server":{
                                "ServerId":"server_0000001",
                                "ServerName":"",
                                "Protocol":"",
                                "GbId":"",
                                "Launch":false,
                                "ServerIp":"",
                                "ServerPort":0,
                                "ServerPassword":"",
                                "Devices":null
                            },
                            "StreamServerId":"",
                            "RtmpUrl":"",
                            "HttpFlvUrl":"",
                            "HlsUrl":"",
                            "ClientId":"",
                            "Launch":true,
                            "HasPtz":true,
                            "DeviceIp":"",
                            "DevicePort":0,
                            "DevicePassword":"",
                            "label":"name2",
                            "id":"device_00001112",
                            "disabled":false
                        },
                        {
                            "DeviceId":"device_00001111",
                            "DeviceName":"name1",
                            "Protocol":"28281",
                            "GbId":"520000000000122345550",
                            "Server":{
                                "ServerId":"server_0000001",
                                "ServerName":"",
                                "Protocol":"",
                                "GbId":"",
                                "Launch":false,
                                "ServerIp":"",
                                "ServerPort":0,
                                "ServerPassword":"",
                                "Devices":null
                            },
                            "StreamServerId":"",
                            "RtmpUrl":"",
                            "HttpFlvUrl":"",
                            "HlsUrl":"",
                            "ClientId":"",
                            "Launch":true,
                            "HasPtz":true,
                            "DeviceIp":"",
                            "DevicePort":0,
                            "DevicePassword":"",
                            "label":"name1",
                            "id":"device_00001111",
                            "disabled":false
                        }
                    ],
                    "label":"",
                    "id":"folder_007",
                    "disabled":true
                },
                {
                    "FolderId":"folder_006",
                    "FolderName":"",
                    "FolderLevel":2,
                    "Disable":true,
                    "children":[
                        {
                            "DeviceId":"device_00001112",
                            "DeviceName":"name2",
                            "Protocol":"28281",
                            "GbId":"5.20000000000122e+20",
                            "Server":{
                                "ServerId":"server_0000001",
                                "ServerName":"",
                                "Protocol":"",
                                "GbId":"",
                                "Launch":false,
                                "ServerIp":"",
                                "ServerPort":0,
                                "ServerPassword":"",
                                "Devices":null
                            },
                            "StreamServerId":"",
                            "RtmpUrl":"",
                            "HttpFlvUrl":"",
                            "HlsUrl":"",
                            "ClientId":"",
                            "Launch":true,
                            "HasPtz":true,
                            "DeviceIp":"",
                            "DevicePort":0,
                            "DevicePassword":"",
                            "label":"name2",
                            "id":"device_00001112",
                            "disabled":false
                        },
                        {
                            "DeviceId":"device_00001111",
                            "DeviceName":"name1",
                            "Protocol":"28281",
                            "GbId":"520000000000122345550",
                            "Server":{
                                "ServerId":"server_0000001",
                                "ServerName":"",
                                "Protocol":"",
                                "GbId":"",
                                "Launch":false,
                                "ServerIp":"",
                                "ServerPort":0,
                                "ServerPassword":"",
                                "Devices":null
                            },
                            "StreamServerId":"",
                            "RtmpUrl":"",
                            "HttpFlvUrl":"",
                            "HlsUrl":"",
                            "ClientId":"",
                            "Launch":true,
                            "HasPtz":true,
                            "DeviceIp":"",
                            "DevicePort":0,
                            "DevicePassword":"",
                            "label":"name1",
                            "id":"device_00001111",
                            "disabled":false
                        }
                    ],
                    "label":"",
                    "id":"folder_006",
                    "disabled":true
                }
            ],
            "label":"",
            "id":"folder_002",
            "disabled":true
        }
    ],
    "label":"",
    "disabled":true,
    "id":"folder_001"
}

]

<el-tree
        :data="deviceTree"
        show-checkbox
        default-expand-all
        node-key="id"
        ref="tree"
        :highlight-current="true"
       
        check-strictly
        @check="handleNodeChecked"
        >
        </el-tree>
        

my data is like this, this.$refs.tree.setChecked (data,false); this.$refs.tree.getNode (data)
are all valid. What"s the matter? the data given by examples will take effect. Is there something wrong with the data?


set yourself up. Forget it. I can't trust my sister in the background any more. The data returned is too fake.

Menu