mirror of
https://github.com/RaspAP/raspap-webgui.git
synced 2024-11-21 15:10:22 +00:00
Create api general + status tabs
This commit is contained in:
parent
7dc2fd6538
commit
8ecd542eae
3 changed files with 37 additions and 3 deletions
|
@ -17,16 +17,22 @@
|
|||
<div class="col">
|
||||
<i class="fas fa-puzzle-piece mr-2"></i><?php echo _("RestAPI"); ?>
|
||||
</div>
|
||||
<div class="col">
|
||||
<button class="btn btn-light btn-icon-split btn-sm service-status float-right">
|
||||
<span class="icon text-gray-600"><i class="fas fa-circle service-status-<?php echo $serviceStatus ?>"></i></span>
|
||||
<span class="text service-status">raspap-api <?php echo _($serviceStatus) ?></span>
|
||||
</button>
|
||||
</div>
|
||||
</div><!-- /.row -->
|
||||
</div><!-- /.card-header -->
|
||||
<div class="card-body">
|
||||
<?php $status->showMessages(); ?>
|
||||
<form role="form" action="restapi_conf" enctype="multipart/form-data" method="POST">
|
||||
<form role="form" action="restapi_conf" method="POST" class="needs-validation" novalidate>
|
||||
<?php echo CSRFTokenFieldTag() ?>
|
||||
<!-- Nav tabs -->
|
||||
<ul class="nav nav-tabs">
|
||||
<li class="nav-item"><a class="nav-link active" id="settingstab" href="#restapisettings" data-toggle="tab"><?php echo _("Settings"); ?></a></li>
|
||||
<li class="nav-item"><a class="nav-link" id="loggingtab" href="#restapistatus" data-toggle="tab"><?php echo _("Status"); ?></a></li>
|
||||
<li class="nav-item"><a class="nav-link active" id="restapisettingstab" href="#restapisettings" data-toggle="tab"><?php echo _("Settings"); ?></a></li>
|
||||
<li class="nav-item"><a class="nav-link" id="restapistatustab" href="#restapistatus" data-toggle="tab"><?php echo _("Status"); ?></a></li>
|
||||
</ul>
|
||||
|
||||
<!-- Tab panes -->
|
||||
|
|
|
@ -0,0 +1,17 @@
|
|||
<div class="tab-pane active" id="restapisettings">
|
||||
<h4 class="mt-3"><?php echo ("RestAPI settings") ;?></h4>
|
||||
<div class="row">
|
||||
<div class="form-group col-lg-12 mt-3">
|
||||
<div class="row">
|
||||
<div class="form-group col-md-6" required>
|
||||
<label for="txtapikey"><?php echo _("API Key"); ?></label>
|
||||
<input type="text" id="txtapikey" class="form-control" name="txtapikey" value="<?php echo htmlspecialchars($apiKey, ENT_QUOTES); ?>" required />
|
||||
<div class="invalid-feedback">
|
||||
<?php echo _("Please provide a valid API key."); ?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div><!-- /.tab-pane | general tab -->
|
||||
|
|
@ -0,0 +1,11 @@
|
|||
<!-- status tab -->
|
||||
<div class="tab-pane fade" id="restapistatus">
|
||||
<h4 class="mt-3 mb-3"><?php echo _("RestAPI status") ;?></h4>
|
||||
<p><?php echo _("Current <code>raspap-restapi.service</code> status is displayed below."); ?></p>
|
||||
<div class="row">
|
||||
<div class="form-group col-md-8 mt-2">
|
||||
<textarea class="logoutput"><?php echo htmlspecialchars($serviceLog, ENT_QUOTES); ?></textarea>
|
||||
</div>
|
||||
</div>
|
||||
</div><!-- /.tab-pane -->
|
||||
|
Loading…
Reference in a new issue