Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
38 commits
Select commit Hold shift + click to select a range
bb7c187
Feat: Added left side menu (functions.php)
IgorA100 Apr 15, 2025
9f9ccc3
Add "$tabs['auth'] = translate('Authentication');" from options.php (…
IgorA100 Apr 15, 2025
72b3cc7
Load files from "assets/pro-sidebar-template/dist" instead of "assets…
IgorA100 Apr 15, 2025
82aa87d
Added pro-sidebar-template from https://github.com/azouaoui-med/pro-s…
IgorA100 Apr 15, 2025
17363cd
Add pro-sidebar-template, swiped-events, mb.extruder (version)
IgorA100 Apr 15, 2025
a3e62bd
Added swiped-events v. 1.2.0 Apr 27, 2024
IgorA100 Apr 15, 2025
61a5ad1
Merge branch 'patch-617239' of https://github.com/IgorA100/zoneminder…
IgorA100 Apr 15, 2025
964430d
Added mb.extruder
IgorA100 Apr 15, 2025
f02ba12
Initialization of datepicker is moved to separate functions.
IgorA100 Apr 15, 2025
ac3d2a3
A little cleanup of unused code (mbExtruder.js)
IgorA100 Apr 15, 2025
945be7d
For "#extruderLeft" do not apply ".hidden-shift" (functions.php)
IgorA100 Apr 15, 2025
68ddbd3
Changed code commenting.
IgorA100 Apr 15, 2025
cd96b1f
Merge branch 'patch-617239' of https://github.com/IgorA100/zoneminder…
IgorA100 Apr 15, 2025
029bd5e
Added var --backgroundMediumDark
IgorA100 Apr 15, 2025
5024d32
Added a button to clear all selected elements in multi select. Becaus…
IgorA100 Apr 15, 2025
9b8abb0
Added a button to clear all selected elements in multi select. (Filte…
IgorA100 Apr 16, 2025
8481d68
Added formation and management of a new menu in the left Sidebar (ski…
IgorA100 Apr 16, 2025
191e346
Fix: eslint (skin.js)
IgorA100 Apr 16, 2025
df10fa2
Fix: eslint (skin.js)
IgorA100 Apr 16, 2025
b249cc1
Fix: eslint (skin.js)
IgorA100 Apr 16, 2025
f04f74a
Remove extra space (skin.js)
IgorA100 Apr 16, 2025
fb441b2
Uncommented the necessary code (skin.js)
IgorA100 Apr 16, 2025
947f7b4
Added a control file for switching the new/old menu (sidebar.css)
IgorA100 Apr 16, 2025
86630d4
Left Sidebar Style Update
IgorA100 Apr 16, 2025
57222d7
Fix: Sidebar header position when height is less than 500px (sidebar.…
IgorA100 Apr 16, 2025
6f155d5
For "datepicker" set z-index only when showing and clear z-index when…
IgorA100 Apr 23, 2025
2f5478c
Change tab to space (skin.js)
IgorA100 Apr 23, 2025
5823c5b
Code optimization (mbExtruder.js)
IgorA100 Apr 26, 2025
0386bc1
Code optimization (skin.js)
IgorA100 Apr 26, 2025
6f3816a
Fix space (skin.js)
IgorA100 Apr 26, 2025
670701f
Code cleaning (mbExtruder.js)
IgorA100 Apr 26, 2025
88dc87e
Update mbExtruder.js
IgorA100 Apr 26, 2025
3887a93
Optimization for small screens (skin.js)
IgorA100 Apr 30, 2025
9628d98
Optimization of styles
IgorA100 May 5, 2025
456f084
Added link to Slack (functions.php)
IgorA100 May 9, 2025
31b9856
For the menu we use font-size as for all content (sidebar.css)
IgorA100 May 9, 2025
8e5c69f
Merge branch 'master' into patch-617239
IgorA100 Jun 12, 2025
ec8d920
Added a link to zmninja.zoneminder.com "functions.php" to the menu
IgorA100 Jun 17, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 25 additions & 1 deletion web/includes/Filter.php
Original file line number Diff line number Diff line change
Expand Up @@ -1147,6 +1147,7 @@ public function simple_widget() {
$html .= '<span class="term-value-wrapper">';
$html .= htmlSelect("filter[Query][terms][$i][val]", $availableTags, $selected, $options).PHP_EOL;
$html .= '</span>';
$html .= $this->addButtonForFilterSelect("filter[Query][terms][$i][val]");
// $html .= '<span>'.htmlSelect("filter[Query][terms][$i][val]", array_combine($availableTags,$availableTags), $term['val'],
// $options).'</span>'.PHP_EOL;
// $html .= '<span>'.htmlSelect("filter[Query][terms][$i][val]", $availableTags, $term['val'], $options).'</span>'.PHP_EOL;
Expand Down Expand Up @@ -1192,22 +1193,25 @@ public function simple_widget() {
$html .= '<span class="term-value-wrapper">';
$html .= htmlSelect("filter[Query][terms][$i][val]", $booleanValues, $term['val'], ['class'=>'chosen chosen-auto-width']).PHP_EOL;
$html .= '</span>';

$html .= $this->addButtonForFilterSelect("filter[Query][terms][$i][val]");
} else if ( $term['attr'] == 'Group') {
$html .= '<span class="term-value-wrapper">';
$html .= htmlSelect("filter[Query][terms][$i][val]", Group::get_dropdown_options(), $term['val'],
['class'=>'term-value chosen chosen-auto-width',
'multiple'=>'multiple',
'data-placeholder'=>translate('All Groups')]).PHP_EOL;
$html .= '</span>';
$html .= $this->addButtonForFilterSelect("filter[Query][terms][$i][val]");
} else if ( $term['attr'] == 'StateId' ) {
$html .= '<span class="term-value-wrapper">';
$html .= htmlSelect("filter[Query][terms][$i][val]", $states, $term['val'], ['class'=>'chosen chosen-auto-width']).PHP_EOL;
$html .= '</span>';
$html .= $this->addButtonForFilterSelect("filter[Query][terms][$i][val]");
} else if ( strpos($term['attr'], 'Weekday') !== false ) {
$html .= '<span class="term-value-wrapper">';
$html .= htmlSelect("filter[Query][terms][$i][val]", $weekdays, $term['val'], ['class'=>'chosen chosen-auto-width']).PHP_EOL;
$html .= '</span>';
$html .= $this->addButtonForFilterSelect("filter[Query][terms][$i][val]");
} else if ( $term['attr'] == 'Monitor' ) {
$monitors = [];
foreach (Monitor::find(['Deleted'=>false], ['order'=>'lower(Name)']) as $m) {
Expand All @@ -1230,6 +1234,7 @@ public function simple_widget() {
$html .= '<span class="term-value-wrapper">';
$html .= htmlSelect("filter[Query][terms][$i][val]", $monitors, $selected, $options).PHP_EOL;
$html .= '</span>';
$html .= $this->addButtonForFilterSelect("filter[Query][terms][$i][val]");
} else if ( $term['attr'] == 'MonitorName' ) {
$monitor_names = [];
foreach (Monitor::find(['Deleted'=>false], ['order'=>'lower(Name)']) as $m) {
Expand All @@ -1241,11 +1246,13 @@ public function simple_widget() {
$html .= htmlSelect("filter[Query][terms][$i][val]", array_combine($monitor_names,$monitor_names), $term['val'],
['class'=>'term-value chosen chosen-auto-width', 'multiple'=>'multiple', 'data-placeholder'=>translate('All Monitors')]).PHP_EOL;
$html .= '</span>';
$html .= $this->addButtonForFilterSelect("filter[Query][terms][$i][val]");
} else if ( $term['attr'] == 'ServerId' || $term['attr'] == 'MonitorServerId' || $term['attr'] == 'StorageServerId' || $term['attr'] == 'FilterServerId' ) {
$html .= '<span class="term-value-wrapper">';
$html .= htmlSelect("filter[Query][terms][$i][val]", $servers, $term['val'],
['class'=>'term-value chosen chosen-auto-width', 'multiple'=>'multiple']).PHP_EOL;
$html .= '</span>';
$html .= $this->addButtonForFilterSelect("filter[Query][terms][$i][val]");
} else if ( ($term['attr'] == 'StorageId') || ($term['attr'] == 'SecondaryStorageId') ) {
if (!$storageareas) {
$storageareas = array('' => array('Name'=>'NULL Unspecified'), '0' => array('Name'=>'Zero')) + ZM_Object::Objects_Indexed_By_Id('ZM\Storage');
Expand All @@ -1254,11 +1261,13 @@ public function simple_widget() {
$html .= htmlSelect("filter[Query][terms][$i][val]", $storageareas, $term['val'],
['class'=>'term-value chosen chosen-auto-width', 'multiple'=>'multiple']).PHP_EOL;
$html .= '</span>';
$html .= $this->addButtonForFilterSelect("filter[Query][terms][$i][val]");
} else if ( $term['attr'] == 'AlarmedZoneId' ) {
$html .= '<span class="term-value-wrapper">';
$html .= htmlSelect("filter[Query][terms][$i][val]", $zones, $term['val'],
['class'=>'term-value chosen chosen-auto-width', 'multiple'=>'multiple']).PHP_EOL;
$html .= '</span>';
$html .= $this->addButtonForFilterSelect("filter[Query][terms][$i][val]");
} else if ( $term['attr'] == 'Notes' ) {
$attrs = ['id'=>'filterNotes', 'class'=>'term-value chosen chosen-auto-width', 'multiple'=>'multiple', 'data-placeholder'=>translate('Event Type')];
$selected = explode(',', $term['val']);
Expand Down Expand Up @@ -1286,6 +1295,7 @@ public function simple_widget() {
$html .= '<span class="term-value-wrapper">';
$html .= htmlSelect("filter[Query][terms][$i][val]", $options, $selected, $attrs).PHP_EOL;
$html .= '</span>';
$html .= $this->addButtonForFilterSelect("filter[Query][terms][$i][val]");
} else {
#$html .= $term['attr'];
$html .= '<span class="term-value-wrapper">';
Expand Down Expand Up @@ -1374,5 +1384,19 @@ public function canEdit($u=null) {
return false;
}

function addButtonForFilterSelect($nameSelect) {
if (isset($_COOKIE['zmUseOldMenuView']) and $_COOKIE["zmUseOldMenuView"] === 'true') {
$html = '';
} else {
$html = PHP_EOL . '
<span class="btn-term-remove-all">
<button type="button" name="deleteBtn" data-on-click-this="resetSelectElement" data-select-target="'.$nameSelect.'">
<i class="material-icons">clear</i>
<span class="text"></span>
</button>
</span>' . PHP_EOL;
}
return $html;
}
} # end class Filter
?>
Loading
Loading