diff --git a/public/css/main.css b/public/css/main.css index 56da8af..630412e 100644 --- a/public/css/main.css +++ b/public/css/main.css @@ -119,7 +119,7 @@ Feedback field position: relative; text-align: center; top:200px; - background:rgba(0, 0, 0, 0.4); + background:rgba(0, 0, 0, 0.4); width: 550px; height: 225px; color: white; diff --git a/src/actions/index.js b/src/actions/index.js index d70edc6..ae354ce 100644 --- a/src/actions/index.js +++ b/src/actions/index.js @@ -38,11 +38,19 @@ export const GET_KUBAM_IP = 'GET_KUBAM_IP'; export const RECEIVED_KUBAM_IP = 'RECEIVED_KUBAM_IP'; export const GET_PROXY = 'GET_PROXY'; export const RECEIVED_PROXY = 'RECEIVED_PROXY'; + +export const GET_ORG = 'GET_ORG'; +export const RECEIVED_ORG = 'RECEIVED_ORG'; + export const UPDATE_SETTINGS = 'UPDATE_SETTINGS'; export const DID_UPDATE_SETTINGS = 'DID_UPDATE_SETTINGS'; export const DEPLOY = 'DEPLOY'; export const DESTROY = 'DESTROY'; export const DID_DEPLOY = 'DID_DEPLOY'; +/* Feedback */ +export const POST_FEEDBACK = 'POST_FEEDBACK'; +export const POSTED_FEEDBACK = 'POSTED_FEEDBACK'; + export const selectTab = (selected) => ({ type: SELECTED_TAB, @@ -183,17 +191,28 @@ export const receivedProxy = (proxy) => ({ proxy, }) +export const getOrg = () => ({ + type: GET_ORG, +}) + +export const receivedOrg = (org) => ({ + type: RECEIVED_ORG, + org, +}) + + export const receivedKeys = (keys) => ({ type: RECEIVED_KEYS, keys, }) // update settings -export const updateSettings = (kubam_ip, keys, proxy) => ({ +export const updateSettings = (kubam_ip, keys, proxy, org) => ({ type: UPDATE_SETTINGS, kubam_ip, keys, proxy, + org, }) @@ -223,3 +242,15 @@ export const receivedCatalog = (catalog) => ({ type: RECEIVED_CATALOG, catalog, }) + +export const postFeedback = (feedback) => ({ + type: POST_FEEDBACK, + feedback, +}) + +export const postedFeedback = (response) => ({ + type: POSTED_FEEDBACK, + response, +}) + + diff --git a/src/components/Feedbackfield.js b/src/components/Feedbackfield.js index a49d4d9..816cce2 100644 --- a/src/components/Feedbackfield.js +++ b/src/components/Feedbackfield.js @@ -1,51 +1,76 @@ -import React from 'react' +import React, {Component } from 'react' +import { connect } from 'react-redux' +import {postFeedback} from '../actions' //import PropTypes from 'prop-types' -var Feedbackfield = ({selected, onClick}) => ( -
+ KUBAM will create resources inside UCS. By default all resources will be created under the kubam org. You can, however, put any org you want. No spaces or tricky names. UCS doesn't like that. +
+ +Please enter a public key so you can log into the servers after they are installed.
diff --git a/src/containers/Deploy.js b/src/containers/Deploy.js index e61b3ca..dc1ca26 100644 --- a/src/containers/Deploy.js +++ b/src/containers/Deploy.js @@ -48,7 +48,8 @@ class Deploy extends Component { } destroyFunc = (event) => { - this.props.destroy() + this.props.destroy(); + document.getElementById('destroyoverlay').style.display = 'none'; } render() { diff --git a/src/containers/Settings.js b/src/containers/Settings.js index 1335b90..e40fbe5 100644 --- a/src/containers/Settings.js +++ b/src/containers/Settings.js @@ -1,6 +1,6 @@ import React, { Component } from 'react' import { connect } from 'react-redux' -import { getKUBAMIP, getKeys, getProxy, updateSettings } from '../actions' +import { getKUBAMIP, getKeys, getProxy, getOrg, updateSettings } from '../actions' import SettingsPanel from '../components/panels/settings/' import Error from '../components/Error' @@ -10,6 +10,7 @@ class Settings extends Component { this.state = { keys: this.props.keys , kubam_ip: this.props.kubam_ip, + org: this.props.org, proxy: this.props.proxy, working: this.props.working, } @@ -21,6 +22,7 @@ class Settings extends Component { this.props.getKUBAMIP() this.props.getKeys() this.props.getProxy() + this.props.getOrg() } componentWillReceiveProps(nextProps) { @@ -28,6 +30,7 @@ class Settings extends Component { keys: Array.isArray(nextProps.keys) ? nextProps.keys[0] : "", kubam_ip: nextProps.kubam_ip, proxy: nextProps.proxy, + org: nextProps.org, working: nextProps.working, }) } @@ -44,6 +47,9 @@ class Settings extends Component { case "proxy": s.proxy = event.target.value; break; + case "org": + s.org = event.target.value; + break; default: } @@ -53,14 +59,14 @@ class Settings extends Component { updateFunc = (event) => { // get the ip and the key. // the keys should be in an array. Right now the interface only allows for one key. - this.props.updateSettings(this.state.kubam_ip, [this.state.keys], this.state.proxy); + this.props.updateSettings(this.state.kubam_ip, [this.state.keys], this.state.proxy, this.state.org); } render() { return (