Cleans up style
parent
2d4205916b
commit
d64fc5cf56
|
@ -57,19 +57,19 @@ if ($_SERVER['REQUEST_METHOD'] == 'POST') {
|
|||
|
||||
switch ($action) {
|
||||
case 'add':
|
||||
include('../app/templates/agent-add.php');
|
||||
include '../app/templates/agent-add.php';
|
||||
break;
|
||||
case 'edit':
|
||||
$agentDetails = $agentObject->getAgentDetails($platform_id, $agent);
|
||||
include('../app/templates/agent-edit.php');
|
||||
include '../app/templates/agent-edit.php';
|
||||
break;
|
||||
case 'delete':
|
||||
$agentDetails = $agentObject->getAgentDetails($platform_id, $agent);
|
||||
include('../app/templates/agent-delete.php');
|
||||
include '../app/templates/agent-delete.php';
|
||||
break;
|
||||
default:
|
||||
$agentDetails = $agentObject->getAgentDetails($platform_id);
|
||||
include('../app/templates/agent-list.php');
|
||||
include '../app/templates/agent-list.php';
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -29,10 +29,10 @@ if (isset($_REQUEST['name']) && $_REQUEST['name'] != '') {
|
|||
|
||||
|
||||
// list of all component events (default)
|
||||
$component = new Component($db);
|
||||
$componentObject = new Component($db);
|
||||
|
||||
// prepare the result
|
||||
$search = $component->jitsiComponents($jitsi_component, $component_id, $from_time, $until_time);
|
||||
$search = $componentObject->jitsiComponents($jitsi_component, $component_id, $from_time, $until_time);
|
||||
|
||||
if (!empty($search)) {
|
||||
$components = array();
|
||||
|
@ -77,6 +77,6 @@ if (!empty($components['records'])) {
|
|||
}
|
||||
|
||||
// display the widget
|
||||
include('../app/templates/widget.php');
|
||||
include '../app/templates/widget.php';
|
||||
|
||||
?>
|
||||
|
|
|
@ -29,17 +29,17 @@ if (isset($_REQUEST['id']) && $_REQUEST['id'] != '') {
|
|||
//
|
||||
|
||||
|
||||
$conference = new Conference($db);
|
||||
$conferenceObject = new Conference($db);
|
||||
|
||||
// search and list specific conference ID
|
||||
if (isset($conferenceId)) {
|
||||
$search = $conference->conferenceById($conferenceId, $from_time, $until_time);
|
||||
$search = $conferenceObject->conferenceById($conferenceId, $from_time, $until_time);
|
||||
// search and list specific conference name
|
||||
} elseif (isset($conferenceName)) {
|
||||
$search = $conference->conferenceByName($conferenceName, $from_time, $until_time);
|
||||
$search = $conferenceObject->conferenceByName($conferenceName, $from_time, $until_time);
|
||||
// list of all conferences (default)
|
||||
} else {
|
||||
$search = $conference->conferencesAllFormatted($from_time, $until_time);
|
||||
$search = $conferenceObject->conferencesAllFormatted($from_time, $until_time);
|
||||
}
|
||||
|
||||
if (!empty($search)) {
|
||||
|
@ -126,6 +126,6 @@ if (!empty($conferences['records'])) {
|
|||
}
|
||||
|
||||
// display the widget
|
||||
include('../app/templates/widget.php');
|
||||
include '../app/templates/widget.php';
|
||||
|
||||
?>
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
$action = $_REQUEST['action'] ?? '';
|
||||
require '../app/classes/config.php';
|
||||
|
||||
$configure = new Config();
|
||||
$configObject = new Config();
|
||||
|
||||
// if a form is submitted, it's from the edit page
|
||||
if ($_SERVER['REQUEST_METHOD'] == 'POST') {
|
||||
|
@ -70,30 +70,30 @@ if ($_SERVER['REQUEST_METHOD'] == 'POST') {
|
|||
case 'configjs':
|
||||
$mode = $_REQUEST['mode'] ?? '';
|
||||
$raw = ($mode === 'raw');
|
||||
$platformConfigjs = $configure->getPlatformConfigjs($platformDetails[0]['jitsi_url'], $raw);
|
||||
include('../app/templates/config-list-configjs.php');
|
||||
$platformConfigjs = $configObject->getPlatformConfigjs($platformDetails[0]['jitsi_url'], $raw);
|
||||
include '../app/templates/config-list-configjs.php';
|
||||
break;
|
||||
case 'interfaceconfigjs':
|
||||
$mode = $_REQUEST['mode'] ?? '';
|
||||
$raw = ($mode === 'raw');
|
||||
$platformInterfaceConfigjs = $configure->getPlatformInterfaceConfigjs($platformDetails[0]['jitsi_url'], $raw);
|
||||
include('../app/templates/config-list-interfaceconfigjs.php');
|
||||
$platformInterfaceConfigjs = $configObject->getPlatformInterfaceConfigjs($platformDetails[0]['jitsi_url'], $raw);
|
||||
include '../app/templates/config-list-interfaceconfigjs.php';
|
||||
break;
|
||||
|
||||
// if there is no $item, we work on the local config file
|
||||
default:
|
||||
switch ($action) {
|
||||
case 'add':
|
||||
include('../app/templates/config-add-platform.php');
|
||||
include '../app/templates/config-add-platform.php';
|
||||
break;
|
||||
case 'edit':
|
||||
include('../app/templates/config-edit-platform.php');
|
||||
include '../app/templates/config-edit-platform.php';
|
||||
break;
|
||||
case 'delete':
|
||||
include('../app/templates/config-delete-platform.php');
|
||||
include '../app/templates/config-delete-platform.php';
|
||||
break;
|
||||
default:
|
||||
include('../app/templates/config-list.php');
|
||||
include '../app/templates/config-list.php';
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -14,8 +14,8 @@ $db = connectDB($config, 'jilo', $platformDetails[0]['jilo_database'], $platform
|
|||
|
||||
////
|
||||
// monthly usage
|
||||
$conference = new Conference($db);
|
||||
$participant = new Participant($db);
|
||||
$conferenceObject = new Conference($db);
|
||||
$participantObject = new Participant($db);
|
||||
|
||||
// monthly conferences for the last year
|
||||
$fromMonth = (new DateTime())->sub(new DateInterval('P1Y'));
|
||||
|
@ -36,8 +36,8 @@ while ($fromMonth < $thisMonth) {
|
|||
$from_time = $fromMonth->format('Y-m-d');
|
||||
$until_time = $untilMonth->format('Y-m-d');
|
||||
|
||||
$searchConferenceNumber = $conference->conferenceNumber($from_time, $until_time);
|
||||
$searchParticipantNumber = $participant->participantNumber($from_time, $until_time);
|
||||
$searchConferenceNumber = $conferenceObject->conferenceNumber($from_time, $until_time);
|
||||
$searchParticipantNumber = $participantObject->participantNumber($from_time, $until_time);
|
||||
|
||||
// pretty format for displaying the month in the widget
|
||||
$month = $fromMonth->format('F Y');
|
||||
|
@ -71,12 +71,11 @@ if (!empty($searchConferenceNumber) && !empty($searchParticipantNumber)) {
|
|||
}
|
||||
|
||||
// display the widget
|
||||
include('../app/templates/widget-monthly.php');
|
||||
include '../app/templates/widget-monthly.php';
|
||||
|
||||
|
||||
////
|
||||
// conferences in last 2 days
|
||||
$conference = new Conference($db);
|
||||
|
||||
// time range limit
|
||||
$from_time = date('Y-m-d', time() - 60 * 60 * 24 * 2);
|
||||
|
@ -84,7 +83,7 @@ $until_time = date('Y-m-d', time());
|
|||
$time_range_specified = true;
|
||||
|
||||
// prepare the result
|
||||
$search = $conference->conferencesAllFormatted($from_time, $until_time);
|
||||
$search = $conferenceObject->conferencesAllFormatted($from_time, $until_time);
|
||||
|
||||
if (!empty($search)) {
|
||||
$conferences = array();
|
||||
|
@ -130,12 +129,11 @@ if (!empty($conferences['records'])) {
|
|||
}
|
||||
|
||||
// display the widget
|
||||
include('../app/templates/widget.php');
|
||||
include '../app/templates/widget.php';
|
||||
|
||||
|
||||
////
|
||||
// last 10 conferences
|
||||
$conference = new Conference($db);
|
||||
|
||||
// all time
|
||||
$from_time = '0000-01-01';
|
||||
|
@ -145,7 +143,7 @@ $time_range_specified = false;
|
|||
$conference_number = 10;
|
||||
|
||||
// prepare the result
|
||||
$search = $conference->conferencesAllFormatted($from_time, $until_time);
|
||||
$search = $conferenceObject->conferencesAllFormatted($from_time, $until_time);
|
||||
|
||||
if (!empty($search)) {
|
||||
$conferences = array();
|
||||
|
@ -197,6 +195,6 @@ if (!empty($conferences['records'])) {
|
|||
}
|
||||
|
||||
// display the widget
|
||||
include('../app/templates/widget.php');
|
||||
include '../app/templates/widget.php';
|
||||
|
||||
?>
|
||||
|
|
|
@ -10,14 +10,14 @@ try {
|
|||
// connect to database
|
||||
$dbWeb = connectDB($config);
|
||||
|
||||
$user = new User($dbWeb);
|
||||
$userObject = new User($dbWeb);
|
||||
|
||||
if ( $_SERVER['REQUEST_METHOD'] == 'POST' ) {
|
||||
$username = $_POST['username'];
|
||||
$password = $_POST['password'];
|
||||
|
||||
// login successful
|
||||
if ( $user->login($username, $password) ) {
|
||||
if ( $userObject->login($username, $password) ) {
|
||||
// if remember_me is checked, max out the session
|
||||
if (isset($_POST['remember_me'])) {
|
||||
// 30*24*60*60 = 30 days
|
||||
|
|
|
@ -32,21 +32,21 @@ if (isset($_REQUEST['id']) && $_REQUEST['id'] != '') {
|
|||
// Participant listings
|
||||
//
|
||||
|
||||
$participant = new Participant($db);
|
||||
$participantObject = new Participant($db);
|
||||
|
||||
// search and list specific participant ID
|
||||
if (isset($participantId)) {
|
||||
$search = $participant->conferenceByParticipantId($participantId, $from_time, $until_time, $participantId, $from_time, $until_time);
|
||||
$search = $participantObject->conferenceByParticipantId($participantId, $from_time, $until_time, $participantId, $from_time, $until_time);
|
||||
// search and list specific participant name (stats_id)
|
||||
} elseif (isset($participantName)) {
|
||||
$search = $participant->conferenceByParticipantName($participantName, $from_time, $until_time);
|
||||
$search = $participantObject->conferenceByParticipantName($participantName, $from_time, $until_time);
|
||||
// search and list specific participant IP
|
||||
} elseif (isset($participantIp)) {
|
||||
$search = $participant->conferenceByParticipantIP($participantIp, $from_time, $until_time);
|
||||
$search = $participantObject->conferenceByParticipantIP($participantIp, $from_time, $until_time);
|
||||
// list of all participants (default)
|
||||
} else {
|
||||
// prepare the result
|
||||
$search = $participant->participantsAll($from_time, $until_time);
|
||||
$search = $participantObject->participantsAll($from_time, $until_time);
|
||||
}
|
||||
|
||||
if (!empty($search)) {
|
||||
|
@ -135,6 +135,6 @@ if (!empty($participants['records'])) {
|
|||
}
|
||||
|
||||
// display the widget
|
||||
include('../app/templates/widget.php');
|
||||
include '../app/templates/widget.php';
|
||||
|
||||
?>
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
<?php
|
||||
|
||||
include('../app/templates/widget-profile.php');
|
||||
include '../app/templates/widget-profile.php';
|
||||
|
||||
?>
|
||||
|
|
|
@ -11,14 +11,14 @@ if ($config['registration_enabled'] === true) {
|
|||
// connect to database
|
||||
$dbWeb = connectDB($config);
|
||||
|
||||
$user = new User($dbWeb);
|
||||
$userObject = new User($dbWeb);
|
||||
|
||||
if ( $_SERVER['REQUEST_METHOD'] == 'POST' ) {
|
||||
$username = $_POST['username'];
|
||||
$password = $_POST['password'];
|
||||
|
||||
// redirect to login
|
||||
if ( $user->register($username, $password) ) {
|
||||
if ( $userObject->register($username, $password) ) {
|
||||
$_SESSION['notice'] = "Registration successful.<br />You can log in now.";
|
||||
header('Location: index.php');
|
||||
exit();
|
||||
|
|
|
@ -8,7 +8,7 @@
|
|||
<div class="card w-auto bg-light border-light card-body" style="flex-direction: row;"><?= $widget['title'] ?></div>
|
||||
<?php } ?>
|
||||
<?php if ($widget['filter'] === true) {
|
||||
include('../app/templates/block-results-filter.php'); } ?>
|
||||
include '../app/templates/block-results-filter.php'; } ?>
|
||||
<?php if ($widget['collapsible'] === true) { ?>
|
||||
</a>
|
||||
<?php } ?>
|
||||
|
|
|
@ -7,7 +7,7 @@
|
|||
<div class="card w-auto bg-light border-light card-body" style="flex-direction: row;"><?= $widget['title'] ?></div>
|
||||
<?php } ?>
|
||||
<?php if ($widget['filter'] === true) {
|
||||
include('../app/templates/block-results-filter.php'); } ?>
|
||||
include '../app/templates/block-results-filter.php'; } ?>
|
||||
<?php if ($widget['collapsible'] === true) { ?>
|
||||
</a>
|
||||
<?php } ?>
|
||||
|
|
Loading…
Reference in New Issue