File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 2727
2828// Creazione righe fantasma ottimizzata
2929$ autofill = new Util \Autofill (6 , 70 );
30- if ($ fattura_accompagnatoria ) {
31- $ autofill ->setRows (21 , 0 , 35 );
32- } else {
33- $ autofill ->setRows (26 , 0 );
34- }
30+ $ rows_per_page = 25 ;
3531
3632// Calcolo ottimizzato delle righe da sottrarre
3733$ c = 0 ;
3834foreach ($ v_iva as $ desc_iva => $ tot_iva ) {
3935 ++$ c ;
4036}
4137
38+ // Calcolo ottimizzato delle righe intestazione
39+ if ($ f_sitoweb || $ f_pec ) {
40+ ++$ c ;
41+ }
42+ if ($ destinazione ) {
43+ $ c += 2 ;
44+ }
45+
4246// Gestione ottimizzata destinazione
4347if ($ destinazione ) {
4448 $ c += $ codice_destinatario ? 2 : 1 ;
4549}
4650
4751// Diminuisco le righe disponibili per pagina
48- $ autofill ->setRows ($ rows_per_page - $ c , 0 );
52+ if ($ fattura_accompagnatoria ) {
53+ $ autofill ->setRows (20 - $ c , 0 , 35 );
54+ } else {
55+ $ autofill ->setRows ($ rows_per_page - $ c , 0 , 30 );
56+ }
4957
5058// Intestazione tabella per righe
5159echo "
You can’t perform that action at this time.
0 commit comments