Skip to content
Open
Changes from 1 commit
Commits
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
Prev Previous commit
Next Next commit
Update search.php
  • Loading branch information
Sekiro-kost committed Jun 9, 2025
commit bc8fe60b46ea9e35d1cdb02085cb6e52a8586e67
22 changes: 21 additions & 1 deletion desktop/modal/search.php
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@

<div class="col-lg-4 searchType" data-searchType="equipment" data-tableFilter="1111110">
<div class="input-group input-group-sm" >
<input id="in_searchFor_equipment" class="form-control roundedLeft" value="" disabled/>
<input id="in_searchFor_equipment" class="form-control roundedLeft" value=""/>
<span class="input-group-btn">
<button type="button" class="btn btn-default cursor bt_selectEqLogic roundedRight" title="{{Rechercher un équipement}}"><i class="fas fa-cube"></i></button>
</span>
Expand Down Expand Up @@ -652,6 +652,24 @@
jeeM.init()


function updateEquipmentInputDisabled() {
var inputIds = [
'in_searchFor_equipment',
'in_searchFor_command',
];
inputIds.forEach(function(id) {
var input = document.getElementById(id);
if (input) {
input.disabled = true;
}
});
}

updateEquipmentInputDisabled();

document.getElementById('sel_searchByType')?.addEventListener('change', updateEquipmentInputDisabled);


//Manage events outside parents delegations:
document.querySelector('#md_search #in_searchFor_string')?.addEventListener('keypress', function(event) {
if (event.which === 13) {
Expand Down Expand Up @@ -785,6 +803,8 @@
if (dataFilter[i] == 1) table.parentNode.seen()
else table.parentNode.unseen()
}

updateEquipmentInputDisabled();
return
}

Expand Down