diff --git a/src/ic/ic-action.js b/src/ic/ic-action.js index 584f1f5..9c39da4 100644 --- a/src/ic/ic-action.js +++ b/src/ic/ic-action.js @@ -73,10 +73,17 @@ class ICAction extends React.Component { * see: https://villas.fein-aachen.org/doc/controller-protocol.html */ - if (newAction.action === "delete") { + if (newAction.action == "create" || newAction.action === "delete") { // prepare parameters for delete incl. correct IC id newAction["parameters"] = {}; - newAction.parameters["uuid"] = ic.uuid; + + if (newAction.action == "delete") { + newAction.parameters["uuid"] = ic.uuid; + } + else if (newAction.action == "create") { + newAction.parameters = ic.statusupdateraw.properties; + } + // get the ID of the manager IC let managerIC = null; for (let i of this.props.ics) { diff --git a/src/ic/ics.js b/src/ic/ics.js index def093e..6bf620b 100644 --- a/src/ic/ics.js +++ b/src/ic/ics.js @@ -514,7 +514,8 @@ class InfrastructureComponents extends Component { {id: '-1', title: 'Action', data: {action: 'none'}}, {id: '0', title: 'Reset', data: {action: 'reset'}}, {id: '1', title: 'Shutdown', data: {action: 'shutdown'}}, - {id: '2', title: 'Delete', data: {action: 'delete'}} + {id: '2', title: 'Delete', data: {action: 'delete'}}, + {id: '3', title: 'Recreate', data: {action: 'create'}}, ]} />