Skip to content
This repository has been archived by the owner on Jan 16, 2023. It is now read-only.

Added multi select checkbox functionality #110

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

bindalkumar
Copy link

@bindalkumar bindalkumar commented Dec 20, 2017

@alexcurtis please review. I have created this new PR to allow user to use multi select checkbox functionality.

In order to use this functionality user will have to pass following props:

<Treebeard data={stateData}
  ....
  enableCheckbox={true}
  handleCheckbox={this.handleCheckbox}
  checkboxField="name"
/>

enableCheckbox

If it is true the checkbox will be displayed. Default to false.

checkboxField

This is field which will set the checkbox value. This can be picked from data object. Defaults to name

handleCheckbox

Callback function when a checbox is checked / unchecked. Passes 2 attributes: the data node and it's checked boolean value.

handleCheckbox(node, isChecked) {
 node.checked = isChecked;
 this.setState({cursor: node});
}

@coveralls
Copy link

coveralls commented Dec 20, 2017

Coverage Status

Coverage decreased (-0.4%) to 98.127% when pulling de11f04 on bindalkumar:multiselect_checkbox into 9069701 on alexcurtis:master.

@coveralls
Copy link

coveralls commented Dec 20, 2017

Coverage Status

Coverage decreased (-0.4%) to 98.127% when pulling de11f04 on bindalkumar:multiselect_checkbox into 9069701 on alexcurtis:master.

@coveralls
Copy link

coveralls commented Dec 20, 2017

Coverage Status

Coverage decreased (-0.1%) to 98.44% when pulling 0d886d5 on bindalkumar:multiselect_checkbox into 9069701 on alexcurtis:master.

@bindalkumar bindalkumar force-pushed the multiselect_checkbox branch from 0d886d5 to 33b2b8f Compare January 1, 2018 09:43
@bindalkumar bindalkumar force-pushed the multiselect_checkbox branch from 33b2b8f to e42ddd9 Compare January 1, 2018 10:48
@coveralls
Copy link

Coverage Status

Coverage increased (+0.03%) to 98.58% when pulling e42ddd9 on bindalkumar:multiselect_checkbox into 9069701 on alexcurtis:master.

@bindalkumar
Copy link
Author

@alexcurtis getting following errors while integration:

1
2

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

Successfully merging this pull request may close these issues.

3 participants