Browse Source

Collapse edit server items

Kristan Kenney 5 years ago
parent
commit
ff9e51b338
1 changed files with 25 additions and 90 deletions
  1. 25 90
      web/templates/admin/edit_server.html

+ 25 - 90
web/templates/admin/edit_server.html

@@ -180,26 +180,16 @@
                                     <table style="display:<?php if (empty($v_adv)) echo 'none';?> ;" id="version">
                                         <tr>
                                             <td class="vst-text step-top">
-                                                <?php print _('Version'); ?>
-                                            </td>
-                                        </tr>
-                                        <tr>
-                                            <td>
-                                                <input type="text" size="20" class="vst-input" name="v_version" value="<?php echo $_SESSION['VERSION']; ?>" disabled>
-                                                <br><br>
+                                                <?php print _('Version'); ?>: <span class="optional"><?php echo $_SESSION['VERSION']; ?></span>
                                             </td>
                                         </tr>
+                                        <?php if ($_SESSION['RELEASE_BRANCH'] !== 'release') {?>
                                         <tr>
                                             <td class="vst-text input-label">
-                                                <?php print _('Release'); ?>
-                                            </td>
-                                        </tr>
-                                        <tr>
-                                            <td>
-                                                <input type="text" size="20" class="vst-input" name="v_release_branch" value="<?php echo $_SESSION['RELEASE_BRANCH']; ?>">
-                                                <br><br>
+                                                <?php print _('Release'); ?>: <span class="optional"><?php echo $_SESSION['RELEASE_BRANCH'] ?></span>
                                             </td>
                                         </tr>
+                                        <?}?>
                                         <tr>
                                             <td class="vst-text input-label">
                                                 <?php print _('Options'); ?>
@@ -236,55 +226,34 @@
                                         <?php if (!empty($_SESSION['PROXY_SYSTEM'])) { ?>
                                         <tr>
                                             <td class="vst-text">
-                                                <?php print _('Proxy Server') ?> <a href="/edit/server/<? echo $_SESSION['PROXY_SYSTEM'] ?>/"><i class="fas fa-pencil-alt status-icon orange icon-pad-right"></i></a>
-                                            </td>
-                                        </tr>
-                                        <tr>
-                                            <td>
-                                                <input type="text" size="20" class="vst-input" name="v_proxy_system" value="<?php echo $_SESSION['PROXY_SYSTEM']; ?>" disabled>
-                                                <br><br>
+                                                <?php print _('Proxy Server') ?>: <span class="optional"><?php echo $_SESSION['PROXY_SYSTEM']; ?> <a href="/edit/server/<? echo $_SESSION['PROXY_SYSTEM'] ?>/"><i class="fas fa-pencil-alt status-icon orange icon-pad-right"></i></a></span>
                                             </td>
                                         </tr>
                                         <?php } ?>
+                                        <?php if (!empty($_SESSION['WEB_SYSTEM'])) { ?>
                                         <tr>
                                             <td class="vst-text">
-                                                <?php print _('Web Server') ?> <a href="/edit/server/<? echo $_SESSION['WEB_SYSTEM'] ?>/"><i class="fas fa-pencil-alt status-icon orange icon-pad-right"></i></a>
-                                            </td>
-                                        </tr>
-                                        <tr>
-                                            <td>
-                                                <input type="text" size="20" class="vst-input" name="v_web_system" value="<?php echo $_SESSION['WEB_SYSTEM']; ?>" disabled>
-                                                <br><br>
+                                                <?php print _('Web Server') ?>: <span class="optional"><?php echo $_SESSION['WEB_SYSTEM']; ?> <a href="/edit/server/<? echo $_SESSION['WEB_SYSTEM'] ?>/"><i class="fas fa-pencil-alt status-icon orange icon-pad-right"></i></a></span>
                                             </td>
                                         </tr>
+                                        <?php } ?>
                                         <?php if (!empty($_SESSION['WEB_BACKEND'])) { ?>
                                         <tr>
                                             <td class="vst-text">
-                                                <?php print _('Backend Server') ?> <a href="/edit/server/<? echo $_SESSION['WEB_BACKEND'] ?>/"><i class="fas fa-pencil-alt status-icon orange icon-pad-right"></i></a>
-                                            </td>
-                                        </tr>
-                                        <tr>
-                                            <td>
-                                                <input type="text" size="20" class="vst-input" name="v_web_backend" value="<?php echo $_SESSION['WEB_BACKEND']; ?>" disabled>
-                                                <br><br>
+                                                <?php print _('Backend Server') ?>: <span class="optional"><?php echo $_SESSION['WEB_BACKEND']; ?> <a href="/edit/server/<? echo $_SESSION['WEB_BACKEND'] ?>/"><i class="fas fa-pencil-alt status-icon orange icon-pad-right"></i></a></span>
                                             </td>
                                         </tr>
+                                        <?php } ?>
+                                        <?php if (!empty($_SESSION['WEB_BACKEND_POOL'])) { ?>
                                         <tr>
                                             <td class="vst-text">
-                                                <?php print _('Backend Pool Mode') ?>
+                                                <?php print _('Backend Pool Mode') ?>: <span class="optional"><?php echo $_SESSION['WEB_BACKEND_POOL']; ?></span>
                                             </td>
                                         </tr>
-                                        <tr>
-                                            <td>
-                                                <input type="text" size="20" class="vst-input" name="v_web_backend_pool" value="<?php echo $_SESSION['WEB_BACKEND_POOL']; ?>" disabled>
-                                                <br><br>
-                                            </td>
-                                        </tr>
-
                                         <?php } ?>
                                         <?php if(count($v_php_versions)): ?>
                                         <tr>
-                                            <td class="vst-text">
+                                            <td class="vst-text step-top">
                                                 <?php print _('Enabled multi PHP versions') ?>
 
                                                 <span class="alert alert-info alert-with-icon">
@@ -335,28 +304,12 @@
                                     <table style="display:<?php if (empty($v_adv)) echo 'none';?> ;" id="dns">
                                         <tr>
                                             <td class="vst-text step-top">
-                                                <?php print _('DNS Server') ?> <a href="/edit/server/<? echo $_SESSION['DNS_SYSTEM'] ?>/"><i class="fas fa-pencil-alt status-icon orange icon-pad-right"></i></a>
-                                            </td>
-                                        </tr>
-                                        <tr>
-                                            <td>
-                                                <input type="text" size="20" class="vst-input" name="v_dns_system" value="<?php echo $_SESSION['DNS_SYSTEM']; ?>" disabled>
-                                                <br><br>
+                                                <?php print _('DNS Server') ?>: <span class="optional"><?php echo $_SESSION['DNS_SYSTEM']; ?> <a href="/edit/server/<? echo $_SESSION['DNS_SYSTEM'] ?>/"><i class="fas fa-pencil-alt status-icon orange icon-pad-right"></i></a></span>
                                             </td>
                                         </tr>
-
                                         <tr>
                                             <td class="vst-text input-label">
-                                                <?php print _('DNS Cluster');?>
-                                            </td>
-                                        </tr>
-                                        <tr>
-                                            <td>
-                                                <select class="vst-list" name="v_dns_cluster" disabled>
-                                                    <option value='no'><?php print _('no'); ?></option>
-                                                    <option value='yes' <?php if($v_dns_cluster == 'yes') echo 'selected' ?> ><?php print _('yes'); ?></option>
-                                                </select>
-                                                <br><br>
+                                                <?php print _('DNS Cluster');?>: <span class="optional"><? if ($v_dns_cluster == 'yes') { echo 'Yes'; } else { echo 'No'; } ?></span>
                                             </td>
                                         </tr>
                                         <?php if ($v_dns_cluster = 'yes') {
@@ -365,22 +318,22 @@
                                                       $i++;
                                          ?>
                                         <tr>
-                                            <td class="vst-text step-left">
+                                            <td class="vst-text">
                                                 <?php print _('Host'). ' #'.$i  ?>
                                             </td>
                                         </tr>
                                         <tr>
-                                            <td class="step-left">
+                                            <td class="vst-text">
                                                 <input type="text" size="20" class="vst-input" name="v_dns_remote_host" value="<?php echo $key; ?>" disabled>
-                                                <br><br>
                                             </td>
                                         </tr>
                                         <?php }} ?>
+                                        <tr>
+                                            <td><br></td>
+                                        </tr>
                                     </table>
                                 </td>
                             </tr>
-
-
                             <tr>
                                 <td class="vst-text input-label step-top advanced-options">
                                     <a href="javascript:elementHideShow('mail');" class="vst-text">
@@ -393,44 +346,26 @@
                                     <table style="display:<?php if (empty($v_mail_adv)) echo 'none';?> ;" id="mail">
                                         <tr>
                                             <td class="vst-text step-top">
-                                                <?php print _('Mail Server') ?> <a href="/edit/server/<? echo $_SESSION['MAIL_SYSTEM'] ?>/"><i class="fas fa-pencil-alt status-icon orange icon-pad-right"></i></a>
-                                            </td>
-                                        </tr>
-                                        <tr>
-                                            <td>
-                                                <input type="text" size="20" class="vst-input" name="v_mail_system" value="<?php echo $_SESSION['MAIL_SYSTEM']; ?>" disabled>
-                                                <br><br>
+                                                <?php print _('Mail Server') ?>: <span class="optional"><?php echo $_SESSION['MAIL_SYSTEM']; ?> <a href="/edit/server/<? echo $_SESSION['MAIL_SYSTEM'] ?>/"><i class="fas fa-pencil-alt status-icon orange icon-pad-right"></i></a></span>
                                             </td>
                                         </tr>
                                         <?php if (!empty($_SESSION['ANTIVIRUS_SYSTEM'])) { ?>
                                         <tr>
                                             <td class="vst-text">
-                                                <?php print _('Antivirus') ?> <a href="/edit/server/<? echo $_SESSION['ANTIVIRUS_SYSTEM'] ?>/"><i class="fas fa-pencil-alt status-icon orange icon-pad-right"></i></a>
-                                            </td>
-                                        </tr>
-                                        <tr>
-                                            <td>
-                                                <input type="text" size="20" class="vst-input" name="v_antivirus_system" value="<?php echo $_SESSION['ANTIVIRUS_SYSTEM']; ?>" disabled>
-                                                <br><br>
+                                                <?php print _('Antivirus') ?>: <span class="optional"><?php echo $_SESSION['ANTIVIRUS_SYSTEM']; ?> <a href="/edit/server/<? echo $_SESSION['ANTIVIRUS_SYSTEM'] ?>/"><i class="fas fa-pencil-alt status-icon orange icon-pad-right"></i></a></span>
                                             </td>
                                         </tr>
                                         <?php } ?>
                                         <?php if (!empty($_SESSION['ANTISPAM_SYSTEM'])) { ?>
                                         <tr>
                                             <td class="vst-text">
-                                                <?php print _('AntiSpam') ?> <a href="/edit/server/<? echo $_SESSION['ANTISPAM_SYSTEM'] ?>/"><i class="fas fa-pencil-alt status-icon orange icon-pad-right"></i></a>
-                                            </td>
-                                        </tr>
-                                        <tr>
-                                            <td>
-                                                <input type="text" size="20" class="vst-input" name="v_antispam_system" value="<?php echo $_SESSION['ANTISPAM_SYSTEM']; ?>" disabled>
-                                                <br><br>
+                                                <?php print _('AntiSpam') ?>: <span class="optional"><?php echo $_SESSION['ANTISPAM_SYSTEM']; ?> <a href="/edit/server/<? echo $_SESSION['ANTISPAM_SYSTEM'] ?>/"><i class="fas fa-pencil-alt status-icon orange icon-pad-right"></i></a></span>
                                             </td>
                                         </tr>
                                         <?php } ?>
                                         <?php if($_SESSION['WEBMAIL_SYSTEM']){?>   
                                         <tr>
-                                            <td class="vst-text">
+                                            <td class="vst-text step-top">
                                                 <?php print _('Webmail URL') ?>
                                             </td>
                                         </tr>
@@ -442,7 +377,7 @@
                                         </tr>
                                         <?php } ?>
 					                    <tr>
-                                                <td class="vst-text">
+                                            <td class="vst-text">
                                                 <label>
                                                     <input type="checkbox" size="20" class="vst-checkbox" name="v_smtp_relay" <?php if ($v_smtp_relay == 'true') echo "checked=yes"; ?> onclick="javascript:elementHideShow('smtp_relay_table');"><?php print _('Global SMTP Relay');?>
                                                 </label>