mirror of
https://github.com/symkat/MeshMage.git
synced 2025-02-28 15:54:47 +08:00
Node and network creation redirect to dashboard.
This commit is contained in:
parent
f2ae3ee59a
commit
e981e8b796
3 changed files with 8 additions and 12 deletions
|
@ -13,7 +13,7 @@ sub create ($c) {
|
|||
$c->param('network_name'), $c->param('network_tld'), $c->param('network_cidr')
|
||||
]);
|
||||
|
||||
$c->redirect_to( '/network' );
|
||||
$c->redirect_to( $c->url_for( 'dashboard' )->query( notice => 'network-created' ) );
|
||||
}
|
||||
|
||||
1;
|
||||
|
|
|
@ -14,17 +14,7 @@ sub create ($c) {
|
|||
$c->param('network_id'), $c->param('is_lighthouse'), $c->param('hostname'), $c->param('address'), $c->param('public_address')
|
||||
]);
|
||||
|
||||
$c->redirect_to( '/node' );
|
||||
}
|
||||
|
||||
sub show ($c) {
|
||||
my $node = $c->db->resultset('Node')->find( $c->param('node_id') );
|
||||
my $jobs = $c->minion->jobs( { notes => [ $node->hostname ] } );
|
||||
|
||||
$c->stash(
|
||||
node => $node,
|
||||
jobs => $jobs,
|
||||
);
|
||||
$c->redirect_to( $c->url_for( 'dashboard' )->query( notice => 'node-created' ) );
|
||||
}
|
||||
|
||||
1;
|
||||
|
|
|
@ -11,6 +11,12 @@
|
|||
%% }
|
||||
%% if ( $notice == 'ssh-import' ) {
|
||||
Your ssh key is being imported, it should display below when complete.
|
||||
%% }
|
||||
%% if ( $notice == 'node-created' ) {
|
||||
Your node has been created, it should display below when its certs are generated.
|
||||
%% }
|
||||
%% if ( $notice == 'network-created' ) {
|
||||
Your network has been created, it should display below when its certs are generated.
|
||||
%% }
|
||||
</div>
|
||||
%% }
|
||||
|
|
Loading…
Reference in a new issue