From e0eecf285728f37ca256fdc8ee6656ea934040a2 Mon Sep 17 00:00:00 2001 From: Laurence Maultsby Date: Tue, 11 Oct 2016 13:25:14 -0400 Subject: [PATCH] RIFT-14837: DNS Servers can now update Signed-off-by: Laurence Maultsby --- .../src/instantiate/instantiateInputParams.jsx | 4 ++-- .../launchpad/src/instantiate/instantiateStore.js | 12 ++++++++++-- 2 files changed, 12 insertions(+), 4 deletions(-) diff --git a/skyquake/plugins/launchpad/src/instantiate/instantiateInputParams.jsx b/skyquake/plugins/launchpad/src/instantiate/instantiateInputParams.jsx index e7788f696..164403cad 100644 --- a/skyquake/plugins/launchpad/src/instantiate/instantiateInputParams.jsx +++ b/skyquake/plugins/launchpad/src/instantiate/instantiateInputParams.jsx @@ -368,8 +368,8 @@ export default class InstantiateInputParams extends Component { return (
Remove diff --git a/skyquake/plugins/launchpad/src/instantiate/instantiateStore.js b/skyquake/plugins/launchpad/src/instantiate/instantiateStore.js index 69953d700..103aeea71 100644 --- a/skyquake/plugins/launchpad/src/instantiate/instantiateStore.js +++ b/skyquake/plugins/launchpad/src/instantiate/instantiateStore.js @@ -527,9 +527,9 @@ class LaunchNetworkServiceStore { let self = this; return function(e) { if(self.ipProfiles[i]['ip-profile-params']['dns-server']) { - self.ipProfiles[i]['ip-profile-params']['dns-server'].unshift('') + self.ipProfiles[i]['ip-profile-params']['dns-server'].unshift({}) } else { - self.ipProfiles[i]['ip-profile-params']['dns-server'] = ['']; + self.ipProfiles[i]['ip-profile-params']['dns-server'] = [{}]; } self.setState({ipProfiles:self.ipProfiles}); @@ -544,6 +544,14 @@ class LaunchNetworkServiceStore { } self.setState({ipProfiles:self.ipProfiles}); } + }, + updateDNS: (i, k) => { + let self = this; + return function(e) { + let value = e.target.value; + self.ipProfiles[i]['ip-profile-params']['dns-server'][k].address = value; + self.setState({ipProfiles:self.ipProfiles}); + } } } } -- 2.25.1