fixed country client and parts column matrice
This commit is contained in:
parent
29e4b41874
commit
218fc14462
@ -1084,7 +1084,7 @@ foreach ($stmt->fetchAll(PDO::FETCH_ASSOC) as $row) {
|
|||||||
clientData.forEach(client => {
|
clientData.forEach(client => {
|
||||||
const nome = client.Nominativo || "Nome non disponibile";
|
const nome = client.Nominativo || "Nome non disponibile";
|
||||||
const id = client.IdCliente || "ID non disponibile";
|
const id = client.IdCliente || "ID non disponibile";
|
||||||
const option = new Option(`${nome.trim()} (ID: ${id})`, id);
|
const option = new Option(`${nome.trim()} - ${client.CodiceNazioneFatturazione} (ID: ${id})`, id);
|
||||||
if (parseInt(id) === parseInt(<?php echo json_encode($default_idclient ?? 0); ?>)) {
|
if (parseInt(id) === parseInt(<?php echo json_encode($default_idclient ?? 0); ?>)) {
|
||||||
option.selected = true;
|
option.selected = true;
|
||||||
}
|
}
|
||||||
@ -1116,7 +1116,7 @@ foreach ($stmt->fetchAll(PDO::FETCH_ASSOC) as $row) {
|
|||||||
clientData.forEach(client => {
|
clientData.forEach(client => {
|
||||||
const nome = client.Nominativo || "Nome non disponibile";
|
const nome = client.Nominativo || "Nome non disponibile";
|
||||||
const id = client.IdCliente || "ID non disponibile";
|
const id = client.IdCliente || "ID non disponibile";
|
||||||
const option = new Option(`${nome.trim()} (ID: ${id})`, id);
|
const option = new Option(`${nome.trim()} - ${client.CodiceNazioneFatturazione} (ID: ${id})`, id);
|
||||||
if (String(id) === String(currentValue)) {
|
if (String(id) === String(currentValue)) {
|
||||||
option.selected = true;
|
option.selected = true;
|
||||||
}
|
}
|
||||||
@ -1347,7 +1347,9 @@ foreach ($stmt->fetchAll(PDO::FETCH_ASSOC) as $row) {
|
|||||||
clientData.forEach(client => {
|
clientData.forEach(client => {
|
||||||
const nome = client.Nominativo || "Nome non disponibile";
|
const nome = client.Nominativo || "Nome non disponibile";
|
||||||
const id = client.IdCliente || "ID non disponibile";
|
const id = client.IdCliente || "ID non disponibile";
|
||||||
const option = new Option(`${nome.trim()} (ID: ${id})`, id);
|
const codice = (client.CodiceNazioneFatturazione || '').trim();
|
||||||
|
const option = new Option(`${nome.trim()} - ${codice} (ID: ${id})`, id);
|
||||||
|
|
||||||
if (parseInt(id) === parseInt(<?php echo json_encode($default_idclient ?? 0); ?>)) {
|
if (parseInt(id) === parseInt(<?php echo json_encode($default_idclient ?? 0); ?>)) {
|
||||||
option.selected = true;
|
option.selected = true;
|
||||||
}
|
}
|
||||||
@ -1377,7 +1379,9 @@ foreach ($stmt->fetchAll(PDO::FETCH_ASSOC) as $row) {
|
|||||||
clientData.forEach(client => {
|
clientData.forEach(client => {
|
||||||
const nome = client.Nominativo || "Nome non disponibile";
|
const nome = client.Nominativo || "Nome non disponibile";
|
||||||
const id = client.IdCliente || "ID non disponibile";
|
const id = client.IdCliente || "ID non disponibile";
|
||||||
const option = new Option(`${nome.trim()} (ID: ${id})`, id);
|
const codice = (client.CodiceNazioneFatturazione || '').trim();
|
||||||
|
const option = new Option(`${nome.trim()} - ${codice} (ID: ${id})`, id);
|
||||||
|
|
||||||
if (String(id) === String(currentValue)) {
|
if (String(id) === String(currentValue)) {
|
||||||
option.selected = true;
|
option.selected = true;
|
||||||
}
|
}
|
||||||
|
|||||||
@ -13,13 +13,13 @@ if (session_status() == PHP_SESSION_NONE) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Imposta variabili di sessione di default per evitare errori
|
// Imposta variabili di sessione di default per evitare errori
|
||||||
$_SESSION['iduserlogin'] = null; // Nessun utente loggato
|
$_SESSION['iduserlogin'] = '1'; // Nessun utente loggato
|
||||||
$_SESSION['nameuser'] = 'Ospite';
|
$_SESSION['nameuser'] = 'Ospite';
|
||||||
$_SESSION['surnameuser'] = '';
|
$_SESSION['surnameuser'] = '';
|
||||||
$_SESSION['emailuser'] = '';
|
$_SESSION['emailuser'] = '';
|
||||||
$_SESSION['photouser'] = '';
|
$_SESSION['photouser'] = '';
|
||||||
$photouser = $_SESSION['photouser'];
|
$photouser = $_SESSION['photouser'];
|
||||||
$photousername = '';
|
$photousername = '';
|
||||||
|
$iduserlogin = $_SESSION['iduserlogin'];
|
||||||
// Include file di lingua, se necessario
|
// Include file di lingua, se necessario
|
||||||
require_once(__DIR__ . '/../../languages/en/general.php');
|
require_once(__DIR__ . '/../../languages/en/general.php');
|
||||||
|
|||||||
@ -143,172 +143,215 @@
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<style>
|
<style>
|
||||||
|
/* --- Base --- */
|
||||||
#partsModal {
|
#partsModal {
|
||||||
z-index: 1060 !important;
|
z-index: 1060 !important
|
||||||
}
|
}
|
||||||
|
|
||||||
#partsModal .modal-backdrop {
|
#partsModal .modal-backdrop {
|
||||||
z-index: 1055 !important;
|
z-index: 1055 !important
|
||||||
}
|
}
|
||||||
|
|
||||||
#partsModal .modal-content {
|
#partsModal .modal-content {
|
||||||
width: 100% !important;
|
width: 100% !important;
|
||||||
max-width: 100% !important;
|
max-width: 100% !important
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* Tabelle */
|
||||||
#partsTable tr {
|
#partsTable tr {
|
||||||
display: table-row !important;
|
display: table-row !important
|
||||||
}
|
}
|
||||||
|
|
||||||
#partsTable tr:hover {
|
#partsTable tr:hover {
|
||||||
background-color: #f5f5f5;
|
background: #f5f5f5
|
||||||
display: table-row !important;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
#partsTable td,
|
#partsTable td,
|
||||||
#partsTable th {
|
#partsTable th {
|
||||||
padding: 0.2rem;
|
padding: .2rem;
|
||||||
vertical-align: middle;
|
vertical-align: middle
|
||||||
}
|
}
|
||||||
|
|
||||||
#partsTable input,
|
#partsTable input,
|
||||||
#partsTable select {
|
#partsTable select {
|
||||||
height: 24px;
|
height: 24px;
|
||||||
padding: 0.1rem 0.3rem;
|
padding: .1rem .3rem
|
||||||
}
|
}
|
||||||
|
|
||||||
#partsTable button {
|
#partsTable button {
|
||||||
padding: 0.1rem 0.3rem;
|
padding: .1rem .3rem;
|
||||||
margin: 0 2px;
|
margin: 0 2px
|
||||||
}
|
}
|
||||||
|
|
||||||
#partsTable i {
|
#partsTable i {
|
||||||
font-size: 0.6rem !important;
|
font-size: .6rem !important
|
||||||
}
|
}
|
||||||
|
|
||||||
#global-matrice,
|
/* --- Larghezze fisse header --- */
|
||||||
.part-matrice,
|
/* MacroMatrici = 250px */
|
||||||
#macro-matrice-filter {
|
#macro-matrice-filter {
|
||||||
width: 100% !important;
|
width: 250px !important;
|
||||||
min-width: 100% !important;
|
min-width: 250px !important;
|
||||||
|
max-width: 250px !important;
|
||||||
|
flex: 0 0 250px !important;
|
||||||
|
box-sizing: border-box;
|
||||||
|
overflow: hidden;
|
||||||
|
text-overflow: ellipsis;
|
||||||
|
white-space: nowrap;
|
||||||
}
|
}
|
||||||
|
|
||||||
.select2-container--default #global-matrice {
|
#macro-matrice-filter.select2-hidden-accessible+.select2 {
|
||||||
width: 350px !important;
|
width: 250px !important;
|
||||||
|
min-width: 250px !important;
|
||||||
|
max-width: 250px !important;
|
||||||
|
flex: 0 0 250px !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
#macro-matrice-filter.select2-hidden-accessible+.select2 .select2-selection__rendered {
|
||||||
|
overflow: hidden;
|
||||||
|
text-overflow: ellipsis;
|
||||||
|
white-space: nowrap;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Matrice globale = 450px */
|
||||||
|
#global-matrice {
|
||||||
|
width: 450px !important;
|
||||||
|
min-width: 450px !important;
|
||||||
|
max-width: 450px !important;
|
||||||
|
flex: 0 0 450px !important;
|
||||||
|
box-sizing: border-box;
|
||||||
|
overflow: hidden;
|
||||||
|
text-overflow: ellipsis;
|
||||||
|
white-space: nowrap;
|
||||||
|
}
|
||||||
|
|
||||||
|
#global-matrice.select2-hidden-accessible+.select2 {
|
||||||
|
width: 450px !important;
|
||||||
|
min-width: 450px !important;
|
||||||
|
max-width: 450px !important;
|
||||||
|
flex: 0 0 450px !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
#global-matrice.select2-hidden-accessible+.select2 .select2-selection__rendered {
|
||||||
|
overflow: hidden;
|
||||||
|
text-overflow: ellipsis;
|
||||||
|
white-space: nowrap;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Select delle righe (colonna Matrice) = 150px */
|
||||||
|
.part-matrice {
|
||||||
|
width: 300px !important;
|
||||||
|
min-width: 300px !important;
|
||||||
|
max-width: 300px !important;
|
||||||
|
flex: 0 0 300px !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
.part-matrice.select2-hidden-accessible+.select2 {
|
||||||
|
width: 300px !important;
|
||||||
|
min-width: 300px !important;
|
||||||
|
max-width: 300px !important;
|
||||||
|
flex: 0 0 300px !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Colonna Descrizione (2ª colonna) = 420px */
|
||||||
|
#partsTable th:nth-child(2),
|
||||||
|
#partsTable td:nth-child(2) {
|
||||||
|
width: 350 !important;
|
||||||
min-width: 350px !important;
|
min-width: 350px !important;
|
||||||
|
max-width: 350px !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
.select2-container--default #macro-matrice-filter {
|
#partsTable td:nth-child(2) .part-description {
|
||||||
width: 200px !important;
|
width: 100% !important;
|
||||||
min-width: 200px !important;
|
max-width: 100% !important;
|
||||||
}
|
overflow: hidden;
|
||||||
|
text-overflow: ellipsis;
|
||||||
.select2-container--default .part-matrice {
|
white-space: nowrap;
|
||||||
width: 150px !important;
|
|
||||||
min-width: 150px !important;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* Aspetto Select2 */
|
||||||
.select2-container--default .select2-selection--single {
|
.select2-container--default .select2-selection--single {
|
||||||
height: 24px !important;
|
height: 24px !important;
|
||||||
padding: 0.1rem 0.3rem !important;
|
padding: .1rem .3rem !important;
|
||||||
font-size: 0.8rem !important;
|
font-size: .8rem !important;
|
||||||
border: 1px solid #ced4da !important;
|
border: 1px solid #ced4da !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
.select2-container--default .select2-selection__rendered {
|
|
||||||
line-height: 22px !important;
|
|
||||||
overflow: hidden !important;
|
|
||||||
text-overflow: ellipsis !important;
|
|
||||||
white-space: nowrap !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
.select2-container--default .select2-selection__arrow {
|
.select2-container--default .select2-selection__arrow {
|
||||||
height: 24px !important;
|
height: 24px !important
|
||||||
}
|
}
|
||||||
|
|
||||||
.select2-container--open .select2-dropdown {
|
.select2-container--open .select2-dropdown {
|
||||||
z-index: 1061 !important;
|
z-index: 1061 !important;
|
||||||
border: 1px solid #aaa !important;
|
border: 1px solid #aaa !important;
|
||||||
border-radius: 4px !important;
|
border-radius: 4px !important;
|
||||||
background: white !important;
|
background: #fff !important;
|
||||||
overflow-y: auto !important;
|
|
||||||
max-height: 200px !important;
|
max-height: 200px !important;
|
||||||
|
overflow-y: auto !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* Evita stretching del flex nella riga dei filtri */
|
||||||
|
#partsModal .modal-body>.row .col-md-9>div[style*="display: flex"]>* {
|
||||||
|
flex: 0 0 auto;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Altri modali e pulsanti */
|
||||||
.propagate-matrice-btn,
|
.propagate-matrice-btn,
|
||||||
.propagate-all-btn {
|
.propagate-all-btn {
|
||||||
padding: 0.1rem 0.3rem !important;
|
padding: .1rem .3rem !important;
|
||||||
font-size: 0.8rem !important;
|
font-size: .8rem !important
|
||||||
}
|
}
|
||||||
|
|
||||||
.save-status,
|
.save-status,
|
||||||
.save-loading {
|
.save-loading {
|
||||||
margin-left: 5px;
|
margin-left: 5px
|
||||||
}
|
}
|
||||||
|
|
||||||
#confirmDeleteModal {
|
#confirmDeleteModal {
|
||||||
z-index: 1070 !important;
|
z-index: 1070 !important
|
||||||
}
|
}
|
||||||
|
|
||||||
#confirmDeleteModal .modal-backdrop {
|
#confirmDeleteModal .modal-backdrop {
|
||||||
z-index: 1065 !important;
|
z-index: 1065 !important
|
||||||
}
|
}
|
||||||
|
|
||||||
.note-btn {
|
.note-btn {
|
||||||
padding: 0.2rem 0.4rem !important;
|
padding: .2rem .4rem !important;
|
||||||
/* Aumentato leggermente il padding per un pulsante più grande */
|
font-size: .9rem !important
|
||||||
font-size: 0.9rem !important;
|
|
||||||
/* Aumentato il font-size per un'icona più grande */
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.note-btn.has-note {
|
.note-btn.has-note {
|
||||||
color: #dc3545 !important;
|
color: #dc3545 !important
|
||||||
/* Rosso quando la nota è presente */
|
|
||||||
}
|
}
|
||||||
|
|
||||||
#noteModal {
|
#noteModal {
|
||||||
z-index: 1090 !important;
|
z-index: 1090 !important
|
||||||
}
|
}
|
||||||
|
|
||||||
#noteModal .modal-backdrop {
|
#noteModal .modal-backdrop {
|
||||||
z-index: 1085 !important;
|
z-index: 1085 !important
|
||||||
}
|
}
|
||||||
|
|
||||||
#noteModal .modal-dialog {
|
#noteModal .modal-dialog {
|
||||||
position: relative;
|
position: relative;
|
||||||
z-index: 1090 !important;
|
z-index: 1090 !important
|
||||||
}
|
}
|
||||||
|
|
||||||
#noteModal textarea {
|
#noteModal textarea,
|
||||||
resize: vertical;
|
#commonNoteModal textarea {
|
||||||
}
|
resize: vertical
|
||||||
|
|
||||||
.propagate-date-btn {
|
|
||||||
padding: 0.2rem 0.4rem !important;
|
|
||||||
font-size: 0.9rem !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
.propagate-note-btn {
|
|
||||||
padding: 0.2rem 0.4rem !important;
|
|
||||||
font-size: 0.9rem !important;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
#commonNoteModal {
|
#commonNoteModal {
|
||||||
z-index: 1095 !important;
|
z-index: 1095 !important
|
||||||
/* Sopra #noteModal (1090) */
|
|
||||||
}
|
}
|
||||||
|
|
||||||
#commonNoteModal .modal-backdrop {
|
#commonNoteModal .modal-backdrop {
|
||||||
z-index: 1090 !important;
|
z-index: 1090 !important
|
||||||
/* Sopra il backdrop di #noteModal (1085) */
|
|
||||||
}
|
}
|
||||||
|
|
||||||
#commonNoteModal .modal-dialog {
|
#commonNoteModal .modal-dialog {
|
||||||
position: relative;
|
position: relative;
|
||||||
z-index: 1095 !important;
|
z-index: 1095 !important
|
||||||
}
|
|
||||||
|
|
||||||
#commonNoteModal textarea {
|
|
||||||
resize: vertical;
|
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
@ -1,6 +1,6 @@
|
|||||||
<?php
|
<?php
|
||||||
// upload_photos_mobile.php
|
// upload_photos_mobile.php
|
||||||
include('include/headscript.php');
|
include('include/headscriptnologin.php');
|
||||||
|
|
||||||
$db = DBHandlerSelect::getInstance();
|
$db = DBHandlerSelect::getInstance();
|
||||||
$pdo = $db->getConnection();
|
$pdo = $db->getConnection();
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user