Skip to content

Commit

Permalink
Replace instanceId for instanceName in network list
Browse files Browse the repository at this point in the history
  • Loading branch information
jadsonluan committed Jul 17, 2020
1 parent d11ce65 commit f7884cf
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/components/ComputeForm.js
Original file line number Diff line number Diff line change
Expand Up @@ -293,16 +293,17 @@ class ComputeForm extends Component {
onAddRequirement={this.addRequirement}
onResetRequirements={this.resetRequirements}/>

<label>Network ID(s)</label>
<label>Networks</label>
<fieldset className="checkbox-list">
{ !this.state.provider || !this.state.cloudName ? <label>No cloud or provider selected</label> : undefined }
{ this.props.networks.loading ?
this.props.networks.data.map((network, idx) => {
return network.provider === this.state.provider &&
network.cloudName === this.state.cloudName ?
<div className="checkbox-field">
{ console.log(network) }
<input onChange={this.handleChange} type="checkbox" id={idx} value={network.instanceId} name="networkIds"></input>
<label htmlFor={idx}>{network.instanceId}</label>
<label htmlFor={idx}>{network.instanceName}</label>
</div> : undefined
; }) :
undefined
Expand Down

0 comments on commit f7884cf

Please sign in to comment.