Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to set selectedItems #7

Open
btpham77 opened this issue Apr 27, 2018 · 9 comments
Open

Unable to set selectedItems #7

btpham77 opened this issue Apr 27, 2018 · 9 comments

Comments

@btpham77
Copy link

btpham77 commented Apr 27, 2018

Can you make selectedItems as a parameter so prior to load the control, the caller can set selectedItems if need be?
So it can be set in
mounted () {
this.selectedItems = some exported property
}

I try to use 'value' property but that only work when the control loads the first time. If the select box has something in it, it wouldn't reset.

@zdy1988
Copy link
Owner

zdy1988 commented Apr 28, 2018

Why not use v-model

@btpham77
Copy link
Author

I did but ...
I have a compute property where I bind to v-model. When this property changes, the values do not reflect on the control. As though the initial value is the only thing it keeps.
Secondly, if I add some values to the selection then close the dialog with out saving it then go back to the dialog that has the control, the previous selections are still there and not the value I set to bind to v-model.

@zdy1988
Copy link
Owner

zdy1988 commented Apr 28, 2018

thanks , i think i didn't observe the value update, please wait..

@zdy1988
Copy link
Owner

zdy1988 commented Apr 28, 2018

i published 1.0.7 to fix observe the value

@btpham77
Copy link
Author

Thanks for the fix! If I don't want icon for the tree, is there a property on the control to set it?

@zdy1988
Copy link
Owner

zdy1988 commented Apr 30, 2018

classname :

.icon-hide { display:none;}

data :

{
...
icon: 'icon-hide'
...
}

@btpham77
Copy link
Author

True but there is that empty space in between

@zdy1988
Copy link
Owner

zdy1988 commented Apr 30, 2018

visibility:hidden;

@btpham77
Copy link
Author

Even then the empty space still exists.
Another issue, after selecting some nodes then save the items. Go back to the control, you won't be able to expand the tree...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants