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

Checkbox Cascade option does not work . #46

Open
veegandhi opened this issue Jun 21, 2016 · 4 comments
Open

Checkbox Cascade option does not work . #46

veegandhi opened this issue Jun 21, 2016 · 4 comments

Comments

@veegandhi
Copy link

When I am sending the config hash from the controller , the cascade option of tree hierarchy selection does not work . However the three_state option works .

Below is code :
Controller :
checkboxOptions:{
cascade : 'up'
},
plugins:'checkbox,wholerow,types'

Template : {
{{ember-jstree
actionReceiver=jstreeActionReceiver
selectedNodes=jstreeSelectedNodes
data=data
plugins=plugins
checkboxOptions=checkboxOptions
typesOptions=typesOptions
eventDidSelectNode="selectAccount"
eventDidDeselectNode="deselectAccount"
contextMenuReportClicked="contextMenuReportClicked"
eventDidBecomeReady="handleTreeDidBecomeReady"
}}
}

@ritesh83
Copy link
Owner

Hi @veegandhi

I'm not able to reproduce this issue.
Can you provide an ember-twiddle example?

@veegandhi
Copy link
Author

How do I add this addon to twiddle ? @ritesh83

@ritesh83
Copy link
Owner

@veegandhi You have to add it to the "addons" section in twiddle.json. Anyways I tried creating a twiddle but its throwing a security error https://ember-twiddle.com/82809a6f7b4570b4de8416260fbb59db

Looks like you'll have a create a test project on github and share it with us.

@hadiwina
Copy link

hadiwina commented Apr 13, 2018

@veegandhi From my experience, this may require you to provide all the essential options in the hash that you're sending as checkboxOptions, not just the cascade: 'up'.

let checkboxOptions = this.get('checkboxOptions');
if (Ember.isPresent(checkboxOptions) && pluginsArray.includes('checkbox')) {
    configObject['checkbox'] = checkboxOptions;
}

@ritesh83 is this a correct assumption? -- Or do you think it's on JSTree's level that it replaces the whole thing? It looks like the other default is gone when we provide only certain option(s).

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

3 participants