fixed drag lines

This commit is contained in:
Claudio 2025-12-10 14:14:43 +01:00
parent 824ae278d1
commit 9649751ad8
2 changed files with 32 additions and 3 deletions

View File

@ -106,6 +106,11 @@
margin-top: 10px;
}
.btn-tools {
background: linear-gradient(135deg, #9f7aea, #b794f4);
}
.dash-btn {
width: 100%;
max-width: 280px;
@ -312,7 +317,7 @@
</button>
</div>
<!-- ===== TERZA RIGA (solo 2 bottoni centrati) ===== -->
<!-- ===== TERZA RIGA ===== -->
<div class="dashboard-grid-bottom">
<button class="dash-btn dash-btn-small btn-inserisci btn-inserisci-status" onclick="location.href='production_status.php'">
@ -320,15 +325,18 @@
<div>Status</div>
</button>
<button class="dash-btn dash-btn-small btn-problem" onclick="location.href='production_pause_reasons.php'">
<div class="dash-icon">🛑</div>
<div>Cause di Pausa</div>
</button>
<div></div>
<button class="dash-btn dash-btn-small btn-tools" onclick="location.href='production_tools.php'">
<div class="dash-icon">🛠️</div>
<div>Strumenti aggiuntivi</div>
</button>
</div>
</div>
</div>

View File

@ -668,9 +668,29 @@ if ($_SERVER['REQUEST_METHOD'] === 'POST' && !empty($_POST['action'])) {
const lineId = $(this).data("line");
// Programmati
$("#tabProgrammati tbody tr").each(function() {
const rowLine = $(this).find("td[data-line-id]").data("line-id");
if (!lineId || lineId == rowLine) {
$(this).show();
} else {
$(this).hide();
}
});
// Da Programmare
$("#tabDaProgrammare tbody tr").each(function() {
const rowLine = $(this).find("td[data-line-id]").data("line-id");
if (!lineId || lineId == rowLine) {
$(this).show();
} else {
$(this).hide();
}
});
// (opzionale) anche la tabella special, se vuoi filtrarla
$("#tabSpecial tbody tr").each(function() {
const rowLine = $(this).find("td[data-line-id]").data("line-id");
if (!lineId || lineId == rowLine) {
$(this).show();
} else {
@ -684,6 +704,7 @@ if ($_SERVER['REQUEST_METHOD'] === 'POST' && !empty($_POST['action'])) {
// Aggiungi al bottone "Pulisci" anche la rimozione filtro linea
$(document).on('click', '.btn-clear-filters', function() {
table.columns().search('').draw();