Redirect to URL of TICKscript after creation

pull/3111/head
Alex P 2018-04-02 17:03:10 -07:00
parent ac17bc333e
commit 45b2a9786b
1 changed files with 2 additions and 0 deletions

View File

@ -173,6 +173,7 @@ class TickscriptPage extends Component {
response = await updateTask(kapacitor, task, ruleID, router, sourceID)
} else {
response = await createTask(kapacitor, task, router, sourceID)
router.push(`/sources/${sourceID}/tickscript/${response.id}`)
}
if (response.code) {
this.setState({unsavedChanges: true, consoleMessage: response.message})
@ -227,6 +228,7 @@ class TickscriptPage extends Component {
unsavedChanges,
consoleMessage,
} = this.state
return (
<Tickscript
task={task}