diff options
| author | jc0b <j@jc0b.computer> | 2020-07-22 16:28:47 +0200 |
|---|---|---|
| committer | Fabian Mastenbroek <mail.fabianm@gmail.com> | 2020-08-24 19:48:21 +0200 |
| commit | d7469b9ebb01cf36a78cc98aab31fa8f307c4f65 (patch) | |
| tree | d0535fa0cfe95001302fbd2b0d046d51caab6ffd /frontend/src/components/modals/custom-components/NewTopologyModalComponent.js | |
| parent | 67b6ec800df8e023efadb60ae5f7919030b19789 (diff) | |
| parent | 9e7cb3bd367607b32e102c3a87b68b33c53dec46 (diff) | |
Merge branch 'master' onto working copy
Diffstat (limited to 'frontend/src/components/modals/custom-components/NewTopologyModalComponent.js')
| -rw-r--r-- | frontend/src/components/modals/custom-components/NewTopologyModalComponent.js | 14 |
1 files changed, 5 insertions, 9 deletions
diff --git a/frontend/src/components/modals/custom-components/NewTopologyModalComponent.js b/frontend/src/components/modals/custom-components/NewTopologyModalComponent.js index a0d736a1..a244b730 100644 --- a/frontend/src/components/modals/custom-components/NewTopologyModalComponent.js +++ b/frontend/src/components/modals/custom-components/NewTopologyModalComponent.js @@ -31,10 +31,7 @@ class NewTopologyModalComponent extends React.Component { } onDuplicate() { - this.props.onCreateTopology( - this.textInput.value, - this.originTopology.value, - ) + this.props.onDuplicateTopology(this.textInput.value, this.originTopology.value) this.reset() } @@ -52,7 +49,7 @@ class NewTopologyModalComponent extends React.Component { onCancel={this.onCancel.bind(this)} > <form - onSubmit={e => { + onSubmit={(e) => { e.preventDefault() this.onSubmit() }} @@ -63,20 +60,19 @@ class NewTopologyModalComponent extends React.Component { type="text" className="form-control" required - ref={textInput => (this.textInput = textInput)} + ref={(textInput) => (this.textInput = textInput)} /> </div> <div className="form-group"> <label className="form-control-label">Topology to duplicate (not supported yet)</label> <select className="form-control" - disabled - ref={originTopology => (this.originTopology = originTopology)} + ref={(originTopology) => (this.originTopology = originTopology)} > <option value={-1} key={-1}> None - start from scratch </option> - {this.props.topologies.map(topology => ( + {this.props.topologies.map((topology) => ( <option value={topology._id} key={topology._id}> {topology.name} </option> |
