18 lines
536 B
CoffeeScript
18 lines
536 B
CoffeeScript
context = window
|
|
rest = window.JK.Rest()
|
|
logger = context.JK.logger
|
|
|
|
@InstrumentSelectorList = React.createClass({
|
|
instruments: []
|
|
componentDidUnmount: () ->
|
|
@instruments = []
|
|
|
|
componentDidMount: () ->
|
|
rest.getInstruments().done (instruments) =>
|
|
@instruments = instruments
|
|
|
|
render: () ->
|
|
`<div className="InstrumentSelectorList react-component">
|
|
<CheckBoxList onItemChanged={this.props.handleListChange} sourceObjects={this.instruments} selectedObjects={this.props.selectedInstruments}/>
|
|
</div>`
|
|
}) |