Add the settings navigation sidebar to the integration sub-pages

This commit is contained in:
Alex Tselegidis 2023-01-21 12:50:12 +01:00
parent 1f9d82b18e
commit b447751c39
3 changed files with 113 additions and 110 deletions

View file

@ -3,49 +3,50 @@
<?php section('content') ?> <?php section('content') ?>
<div id="api-settings-page" class="container backend-page"> <div id="api-settings-page" class="container backend-page">
<div id="api-settings"> <div class="row">
<div class="row"> <div class="col-sm-3 offset-sm-1">
<div class="col-lg-8 offset-lg-2"> <?php component('settings_nav') ?>
<form> </div>
<fieldset> <div id="api-settings" class="col-sm-6">
<div class="d-flex justify-content-between align-items-center border-bottom mb-4 py-2"> <form>
<h4 class="text-black-50 mb-0 fw-light"> <fieldset>
<?= lang('api') ?> <div class="d-flex justify-content-between align-items-center border-bottom mb-4 py-2">
</h4> <h4 class="text-black-50 mb-0 fw-light">
<?= lang('api') ?>
</h4>
<div> <div>
<a href="<?= site_url('integrations') ?>" class="btn btn-outline-primary me-2"> <a href="<?= site_url('integrations') ?>" class="btn btn-outline-primary me-2">
<i class="fas fa-chevron-left me-2"></i> <i class="fas fa-chevron-left me-2"></i>
<?= lang('back') ?> <?= lang('back') ?>
</a> </a>
<?php if (can('edit', PRIV_SYSTEM_SETTINGS)): ?> <?php if (can('edit', PRIV_SYSTEM_SETTINGS)): ?>
<button type="button" id="save-settings" class="btn btn-primary"> <button type="button" id="save-settings" class="btn btn-primary">
<i class="fas fa-check-square me-2"></i> <i class="fas fa-check-square me-2"></i>
<?= lang('save') ?> <?= lang('save') ?>
</button> </button>
<?php endif ?> <?php endif ?>
</div>
</div> </div>
</div>
<div class="row"> <div class="row">
<div class="col-12"> <div class="col-12">
<div class="mb-3"> <div class="mb-3">
<label class="form-label" for="api-token"> <label class="form-label" for="api-token">
<?= lang('api_token') ?> <?= lang('api_token') ?>
</label> </label>
<input id="api-token" class="form-control" data-field="api_token"> <input id="api-token" class="form-control" data-field="api_token">
<div class="form-text text-muted"> <div class="form-text text-muted">
<small> <small>
<?= lang('api_token_hint') ?> <?= lang('api_token_hint') ?>
</small> </small>
</div>
</div> </div>
</div> </div>
</div> </div>
</fieldset> </div>
</form> </fieldset>
</div> </form>
</div> </div>
</div> </div>
</div> </div>

View file

@ -3,50 +3,51 @@
<?php section('content') ?> <?php section('content') ?>
<div id="google-analytics-settings-page" class="container backend-page"> <div id="google-analytics-settings-page" class="container backend-page">
<div id="google-analytics-settings"> <div class="row">
<div class="row"> <div class="col-sm-3 offset-sm-1">
<div class="col-lg-8 offset-lg-2"> <?php component('settings_nav') ?>
<form> </div>
<fieldset> <div id="google-analytics-settings" class="col-sm-6">
<div class="d-flex justify-content-between align-items-center border-bottom mb-4 py-2"> <form>
<h4 class="text-black-50 mb-0 fw-light"> <fieldset>
<?= lang('google_analytics') ?> <div class="d-flex justify-content-between align-items-center border-bottom mb-4 py-2">
</h4> <h4 class="text-black-50 mb-0 fw-light">
<?= lang('google_analytics') ?>
</h4>
<div> <div>
<a href="<?= site_url('integrations') ?>" class="btn btn-outline-primary me-2"> <a href="<?= site_url('integrations') ?>" class="btn btn-outline-primary me-2">
<i class="fas fa-chevron-left me-2"></i> <i class="fas fa-chevron-left me-2"></i>
<?= lang('back') ?> <?= lang('back') ?>
</a> </a>
<?php if (can('edit', PRIV_SYSTEM_SETTINGS)): ?> <?php if (can('edit', PRIV_SYSTEM_SETTINGS)): ?>
<button type="button" id="save-settings" class="btn btn-primary"> <button type="button" id="save-settings" class="btn btn-primary">
<i class="fas fa-check-square me-2"></i> <i class="fas fa-check-square me-2"></i>
<?= lang('save') ?> <?= lang('save') ?>
</button> </button>
<?php endif ?> <?php endif ?>
</div>
</div> </div>
</div>
<div class="row"> <div class="row">
<div class="col-12"> <div class="col-12">
<div class="mb-3"> <div class="mb-3">
<label class="form-label" for="google-analytics-code"> <label class="form-label" for="google-analytics-code">
<?= lang('google_analytics_code') ?> <?= lang('google_analytics_code') ?>
</label> </label>
<input id="google-analytics-code" placeholder="UA-XXXXXXXX-XX or G-XXXXXXXXXX" <input id="google-analytics-code" placeholder="UA-XXXXXXXX-XX or G-XXXXXXXXXX"
class="form-control" data-field="google_analytics_code"> class="form-control" data-field="google_analytics_code">
<div class="form-text text-muted"> <div class="form-text text-muted">
<small> <small>
<?= lang('google_analytics_code_hint') ?> <?= lang('google_analytics_code_hint') ?>
</small> </small>
</div>
</div> </div>
</div> </div>
</div> </div>
</fieldset> </div>
</form> </fieldset>
</div> </form>
</div> </div>
</div> </div>
</div> </div>

View file

@ -3,50 +3,51 @@
<?php section('content') ?> <?php section('content') ?>
<div id="matomo-analytics-settings-page" class="container backend-page"> <div id="matomo-analytics-settings-page" class="container backend-page">
<div id="matomo-analytics-settings"> <div class="row">
<div class="row"> <div class="col-sm-3 offset-sm-1">
<div class="col-lg-8 offset-lg-2"> <?php component('settings_nav') ?>
<form> </div>
<fieldset> <div id="matomo-analytics-settings" class="col-sm-6">
<div class="d-flex justify-content-between align-items-center border-bottom mb-4 py-2"> <form>
<h4 class="text-black-50 mb-0 fw-light"> <fieldset>
<?= lang('matomo_analytics') ?> <div class="d-flex justify-content-between align-items-center border-bottom mb-4 py-2">
</h4> <h4 class="text-black-50 mb-0 fw-light">
<?= lang('matomo_analytics') ?>
</h4>
<div> <div>
<a href="<?= site_url('integrations') ?>" class="btn btn-outline-primary me-2"> <a href="<?= site_url('integrations') ?>" class="btn btn-outline-primary me-2">
<i class="fas fa-chevron-left me-2"></i> <i class="fas fa-chevron-left me-2"></i>
<?= lang('back') ?> <?= lang('back') ?>
</a> </a>
<?php if (can('edit', PRIV_SYSTEM_SETTINGS)): ?> <?php if (can('edit', PRIV_SYSTEM_SETTINGS)): ?>
<button type="button" id="save-settings" class="btn btn-primary"> <button type="button" id="save-settings" class="btn btn-primary">
<i class="fas fa-check-square me-2"></i> <i class="fas fa-check-square me-2"></i>
<?= lang('save') ?> <?= lang('save') ?>
</button> </button>
<?php endif ?> <?php endif ?>
</div>
</div> </div>
</div>
<div class="row"> <div class="row">
<div class="col-12"> <div class="col-12">
<div class="mb-3"> <div class="mb-3">
<label class="form-label" for="matomo-analytics-url"> <label class="form-label" for="matomo-analytics-url">
<?= lang('matomo_analytics_url') ?> <?= lang('matomo_analytics_url') ?>
</label> </label>
<input id="matomo-analytics-url" placeholder="//example.org/url/to/matomo/" <input id="matomo-analytics-url" placeholder="//example.org/url/to/matomo/"
data-field="matomo_analytics_url" class="form-control"> data-field="matomo_analytics_url" class="form-control">
<div class="form-text text-muted"> <div class="form-text text-muted">
<small> <small>
<?= lang('matomo_analytics_url_hint') ?> <?= lang('matomo_analytics_url_hint') ?>
</small> </small>
</div>
</div> </div>
</div> </div>
</div> </div>
</fieldset> </div>
</form> </fieldset>
</div> </form>
</div> </div>
</div> </div>
</div> </div>