operation; if ($wizard->id !== null) { $extra .= '&id='.$wizard->id; } $bc[] = [ 'link' => $wizard->parentUrl, 'label' => __('Cluster list'), 'selected' => false, ]; $labels = $wizard->getLabels(); foreach ($labels as $key => $label) { $bc[] = [ 'link' => $wizard->url.(($key >= 0) ? $extra.'&page='.$key : ''), 'label' => __($label), 'selected' => ($wizard->page == $key), ]; } $wizard->prepareBreadcrum($bc); $header_str = __(ucfirst($wizard->getOperation())).' '; $header_str .= (($cluster->name() !== null) ? $cluster->name() : __('cluster ')); $header_str .= ' » '.__($labels[$wizard->page]); // Header. $buttons = []; $main_page = ''; $main_page .= html_print_image( 'images/logs@svg.svg', true, [ 'title' => __('Cluster list'), 'class' => 'main_menu_icon invert_filter', ] ); $main_page .= ''; $buttons = [ [ 'active' => false, 'text' => $main_page, ], ]; if ($cluster !== null) { if ($cluster->id() !== null) { $view = ''; $view .= html_print_image( 'images/details.svg', true, [ 'title' => __('View this cluster'), 'class' => 'main_menu_icon invert_filter', ] ); $view .= ''; $buttons[] = [ 'active' => false, 'text' => $view, ]; } } ui_print_page_header( $header_str, '', false, 'cluster_view', true, // Buttons. $buttons, false, '', GENERIC_SIZE_TEXT, '', $wizard->printHeader(true) ); // Check if any error ocurred. if (empty($wizard->errMessages) === false) { foreach ($wizard->errMessages as $msg) { ui_print_error_message(__($msg)); } } $buttons_input = ''; if (empty($form) === false) { // Print form (prepared in ClusterWizard). $submit = $form['submit-external-input']; unset($form['submit-external-input']); unset($bc[0]); $wizard->printSteps($bc); HTML::printForm($form, false, ($wizard->page < 6)); $buttons_input .= HTML::printInput($submit); } // Print always go back button. $buttons_input .= HTML::printForm($wizard->getGoBackForm(), true); html_print_action_buttons($buttons_input);