Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit bd6c733

Browse files
Merge pull request #96 from wsfe/fix/tree-search-check-all
fix: tree search check all
2 parents dfb4bfd + c617ecd commit bd6c733

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

‎package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@wsfe/vue-tree",
3-
"version": "4.0.0",
3+
"version": "4.0.1",
44
"types": "./types",
55
"description": "A vue tree component using virtual list.",
66
"main": "./dist/vue-tree.umd.js",

‎src/components/TreeSearch.vue

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -224,11 +224,11 @@ function search(keyword1?: string): Promise<void> {
224224
//#region Event handlers
225225
/** 处理全选点击 */
226226
function handleCheckAll(): void {
227-
const keyField = treeRef.value?.keyField
227+
const keyField = props.keyField
228228
if (props.searchDisabled || checkAllStatus.disabled || !treeRef.value || !keyField) return
229229
230230
const currentVisibleKeys = treeRef.value.getCurrentVisibleNodes().map((node: TreeNode) => node[keyField])
231-
if (checkAllStatus.checked||checkAllStatus.indeterminate) {
231+
if (checkAllStatus.checked) {
232232
// 反选
233233
treeRef.value.setCheckedKeys(currentVisibleKeys, false)
234234
} else {

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /