WIP jquery conversion

This commit is contained in:
Andrew Bauer committed 2021-01-04 13:05:33 -06:00
1 parent a1b26c8f61
commit 75e2f526ae
4 files changed
+7 -10

No files matched your search

+4 -3
View File
@@ -1,5 +1,5 @@
function updateLabel() {
var form = $('contentForm');
function initPage() {
var form = document.getElementById('contentForm');
var preset_ddm = form.elements['preset'];
var presetIndex = preset_ddm[preset_ddm.selectedIndex].value;
@@ -9,4 +9,5 @@ function updateLabel() {
form.newLabel.value = '';
}
}
window.addEventListener('DOMContentLoaded', updateLabel);
$j(document).ready(initPage );
+3 -3
View File
@@ -429,12 +429,12 @@ function manageModalBtns(id) {
}
}
function init() {
updateButtons( $('executeButton') );
function initPage() {
updateButtons($j('#executeButton')[0]);
$j('#Id').chosen();
$j('#fieldsTable select').not("[name$='br\\]'], [name$='cnj\\]']").chosen({width: '101%'}); //Every select except brackets/and
$j("#sortTable [name$='sort_field\\]']").chosen();
parseRows($j('#fieldsTable tbody').children());
}
window.addEventListener( 'DOMContentLoaded', init );
$j(document).ready(initPage );
-3
View File
@@ -71,9 +71,6 @@ function initPage() {
var backBtn = $j('#backBtn');
var onvifBtn = $j('#onvifBtn');
//var protocolSelector = $('contentForm').elements['newMonitor[Protocol]'];
//if ( $(protocolSelector).getTag() == 'select' )
//updateMethods( $(protocolSelector) );
document.querySelectorAll('input[name="newMonitor[SignalCheckColour]"]').forEach(function(el) {
el.oninput = function(event) {
$j('#SignalCheckSwatch').css('background-color', event.target.value);
@@ -230,7 +230,6 @@ for ( $i=0; $i < count($speeds); $i++ )
echo "];\n";
?>
var scrubAsObject=$('scrub');
var cWidth; // save canvas width
var cHeight; // save canvas height
var canvas; // global canvas definition so we don't have to keep looking it up