From 666e60a883961edd2b3e13707ba34cbda2164a0a Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Mon, 4 Nov 2019 11:40:54 +0100 Subject: [PATCH] Responsive --- htdocs/contrat/class/contrat.class.php | 14 +++++++------- .../boxes/box_accountancy_last_manual_entries.php | 2 +- htdocs/core/boxes/box_activity.php | 8 ++++---- htdocs/core/boxes/box_boms.php | 2 +- htdocs/core/boxes/box_commandes.php | 4 ++-- htdocs/core/boxes/box_comptes.php | 2 +- htdocs/core/boxes/box_contacts.php | 4 ++-- htdocs/core/boxes/box_factures_fourn_imp.php | 4 ++-- htdocs/core/boxes/box_factures_imp.php | 2 +- htdocs/core/boxes/box_ficheinter.php | 4 ++-- htdocs/core/boxes/box_last_modified_ticket.php | 8 ++++---- htdocs/core/boxes/box_last_ticket.php | 8 ++++---- htdocs/core/boxes/box_lastlogin.php | 4 ++-- htdocs/core/boxes/box_members.php | 4 ++-- htdocs/core/boxes/box_mos.php | 2 +- htdocs/core/boxes/box_project.php | 2 +- htdocs/core/boxes/box_propales.php | 2 +- htdocs/core/boxes/box_supplier_orders.php | 6 +++--- .../box_supplier_orders_awaiting_reception.php | 6 +++--- htdocs/theme/eldy/global.inc.php | 6 ++++++ 20 files changed, 50 insertions(+), 44 deletions(-) diff --git a/htdocs/contrat/class/contrat.class.php b/htdocs/contrat/class/contrat.class.php index 0b9c6768eda..7049ce77076 100644 --- a/htdocs/contrat/class/contrat.class.php +++ b/htdocs/contrat/class/contrat.class.php @@ -1875,8 +1875,8 @@ class Contrat extends CommonObject /** * Return label of a contract status * - * @param int $mode 0=libelle long, 1=libelle court, 2=Picto + Libelle court, 3=Picto, 4=Picto + Long label of all services, 5=Libelle court + Picto, 6=Picto of all services, 7=Same than 6 with fixed length - * @return string Label + * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto, 7=Same than 6 with fixed length + * @return string Label */ public function getLibStatut($mode) { @@ -1888,7 +1888,7 @@ class Contrat extends CommonObject * Renvoi label of a given contrat status * * @param int $status Id status - * @param int $mode 0=Long label, 1=Short label, 2=Picto + Libelle court, 3=Picto, 4=Picto + Long label of all services, 5=Libelle court + Picto, 6=Picto of all services, 7=Same than 6 with fixed length + * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto, 7=Same than 6 with fixed length * @return string Label */ public function LibStatut($status, $mode) @@ -1921,13 +1921,13 @@ class Contrat extends CommonObject $text.=':     '; $text.=''; } - $text.=($mode == 7?'':''); + $text.=($mode == 7?'':''); $text.=($mode != 7 || $this->nbofserviceswait > 0) ? ($this->nbofserviceswait.ContratLigne::LibStatut(0, 3, -1, 'class="marginleft2"')).(($mode != 7 || $this->nbofservicesopened || $this->nbofservicesexpired || $this->nbofservicesclosed)?'   ':'') : ''; - $text.=($mode == 7?'':''); + $text.=($mode == 7?'':''); $text.=($mode != 7 || $this->nbofservicesopened > 0) ? ($this->nbofservicesopened.ContratLigne::LibStatut(4, 3, 0, 'class="marginleft2"')).(($mode != 7 || $this->nbofservicesexpired || $this->nbofservicesclosed)?'   ':'') : ''; - $text.=($mode == 7?'':''); + $text.=($mode == 7?'':''); $text.=($mode != 7 || $this->nbofservicesexpired > 0) ? ($this->nbofservicesexpired.ContratLigne::LibStatut(4, 3, 1, 'class="marginleft2"')).(($mode != 7 || $this->nbofservicesclosed)?'   ':'') : ''; - $text.=($mode == 7?'':''); + $text.=($mode == 7?'':''); $text.=($mode != 7 || $this->nbofservicesclosed > 0) ? ($this->nbofservicesclosed.ContratLigne::LibStatut(5, 3, -1, 'class="marginleft2"')) : ''; $text.=($mode == 7?'':''); return $text; diff --git a/htdocs/core/boxes/box_accountancy_last_manual_entries.php b/htdocs/core/boxes/box_accountancy_last_manual_entries.php index 2c788b66b71..474280d17a7 100644 --- a/htdocs/core/boxes/box_accountancy_last_manual_entries.php +++ b/htdocs/core/boxes/box_accountancy_last_manual_entries.php @@ -133,7 +133,7 @@ class box_accountancy_last_manual_entries extends ModeleBoxes ); $this->info_box_contents[$line][] = array( - 'td' => 'class="nowrap right"', + 'td' => 'class="nowraponall right"', 'text' => price($amount, 0, $langs, 0, -1, -1, $conf->currency), ); diff --git a/htdocs/core/boxes/box_activity.php b/htdocs/core/boxes/box_activity.php index 9609f596618..4864bcad371 100644 --- a/htdocs/core/boxes/box_activity.php +++ b/htdocs/core/boxes/box_activity.php @@ -173,7 +173,7 @@ class box_activity extends ModeleBoxes $totalnb += $data[$j]->nb; $this->info_box_contents[$line][3] = array( - 'td' => 'class="nowrap right"', + 'td' => 'class="nowraponall right"', 'text' => price($data[$j]->Mnttot, 1, $langs, 0, 0, -1, $conf->currency), ); $this->info_box_contents[$line][4] = array( @@ -255,7 +255,7 @@ class box_activity extends ModeleBoxes $totalnb += $data[$j]->nb; $this->info_box_contents[$line][3] = array( - 'td' => 'class="nowrap right"', + 'td' => 'class="nowraponall right"', 'text' => price($data[$j]->Mnttot, 1, $langs, 0, 0, -1, $conf->currency), ); $this->info_box_contents[$line][4] = array( @@ -339,7 +339,7 @@ class box_activity extends ModeleBoxes ); $this->info_box_contents[$line][3] = array( - 'td' => 'class="nowrap right"', + 'td' => 'class="nowraponall right"', 'text' => price($data[$j]->Mnttot, 1, $langs, 0, 0, -1, $conf->currency) ); @@ -421,7 +421,7 @@ class box_activity extends ModeleBoxes ); $totalnb += $data[$j]->nb; $this->info_box_contents[$line][3] = array( - 'td' => 'class="nowrap right"', + 'td' => 'class="nowraponall right"', 'text' => price($data[$j]->Mnttot, 1, $langs, 0, 0, -1, $conf->currency), ); $this->info_box_contents[$line][4] = array( diff --git a/htdocs/core/boxes/box_boms.php b/htdocs/core/boxes/box_boms.php index b4ac04b3051..8f27ff739e0 100644 --- a/htdocs/core/boxes/box_boms.php +++ b/htdocs/core/boxes/box_boms.php @@ -116,7 +116,7 @@ class box_boms extends ModeleBoxes $productstatic->ref = $objp->product_ref; $this->info_box_contents[$line][] = array( - 'td' => '', + 'td' => 'class="nowraponall"', 'text' => $bomstatic->getNomUrl(1), 'asis' => 1, ); diff --git a/htdocs/core/boxes/box_commandes.php b/htdocs/core/boxes/box_commandes.php index 40d809fd6e7..c8a050ea1d4 100644 --- a/htdocs/core/boxes/box_commandes.php +++ b/htdocs/core/boxes/box_commandes.php @@ -135,7 +135,7 @@ class box_commandes extends ModeleBoxes $societestatic->logo = $objp->logo; $this->info_box_contents[$line][] = array( - 'td' => '', + 'td' => 'class="nowraponall"', 'text' => $commandestatic->getNomUrl(1), 'asis' => 1, ); @@ -147,7 +147,7 @@ class box_commandes extends ModeleBoxes ); $this->info_box_contents[$line][] = array( - 'td' => 'class="nowrap right"', + 'td' => 'class="nowraponall right"', 'text' => price($objp->total_ht, 0, $langs, 0, -1, -1, $conf->currency), ); diff --git a/htdocs/core/boxes/box_comptes.php b/htdocs/core/boxes/box_comptes.php index c4259b6252a..00f5722076c 100644 --- a/htdocs/core/boxes/box_comptes.php +++ b/htdocs/core/boxes/box_comptes.php @@ -154,7 +154,7 @@ class box_comptes extends ModeleBoxes ); $this->info_box_contents[$line][] = array( - 'td' => 'class="liste_total right"', + 'td' => 'class="liste_total right nowraponall"', 'text' => price($solde, 0, $langs, 0, -1, -1, $key) ); $line++; diff --git a/htdocs/core/boxes/box_contacts.php b/htdocs/core/boxes/box_contacts.php index 5bdb17ba0b9..6df28e03e30 100644 --- a/htdocs/core/boxes/box_contacts.php +++ b/htdocs/core/boxes/box_contacts.php @@ -136,13 +136,13 @@ class box_contacts extends ModeleBoxes $societestatic->fournisseur = $objp->fournisseur; $this->info_box_contents[$line][] = array( - 'td' => '', + 'td' => 'class="tdoverflowmax150 maxwidth150onsmartphone"', 'text' => $contactstatic->getNomUrl(1), 'asis' => 1, ); $this->info_box_contents[$line][] = array( - 'td' => '', + 'td' => 'class="tdoverflowmax150 maxwidth150onsmartphone"', 'text' => ($objp->fk_soc > 0 ? $societestatic->getNomUrl(1) : ''), 'asis' => 1, ); diff --git a/htdocs/core/boxes/box_factures_fourn_imp.php b/htdocs/core/boxes/box_factures_fourn_imp.php index 3c0fc6444a2..d4cb4143463 100644 --- a/htdocs/core/boxes/box_factures_fourn_imp.php +++ b/htdocs/core/boxes/box_factures_fourn_imp.php @@ -145,13 +145,13 @@ class box_factures_fourn_imp extends ModeleBoxes ); $this->info_box_contents[$line][] = array( - 'td' => '', + 'td' => 'class="tdoverflowmax150 maxwidth150onsmartphone"', 'text' => $thirdpartytmp->getNomUrl(1, '', 40), 'asis' => 1, ); $this->info_box_contents[$line][] = array( - 'td' => 'class="nowrap right"', + 'td' => 'class="nowraponall right"', 'text' => price($objp->total_ht, 0, $langs, 0, -1, -1, $conf->currency), ); diff --git a/htdocs/core/boxes/box_factures_imp.php b/htdocs/core/boxes/box_factures_imp.php index cee85e3e8dc..bb6eb95b32f 100644 --- a/htdocs/core/boxes/box_factures_imp.php +++ b/htdocs/core/boxes/box_factures_imp.php @@ -157,7 +157,7 @@ class box_factures_imp extends ModeleBoxes ); $this->info_box_contents[$line][] = array( - 'td' => '', + 'td' => 'class="tdoverflowmax150 maxwidth150onsmartphone"', 'text' => $societestatic->getNomUrl(1, '', 44), 'asis' => 1, ); diff --git a/htdocs/core/boxes/box_ficheinter.php b/htdocs/core/boxes/box_ficheinter.php index b0851ed28c0..a81b0cf3b86 100644 --- a/htdocs/core/boxes/box_ficheinter.php +++ b/htdocs/core/boxes/box_ficheinter.php @@ -120,13 +120,13 @@ class box_ficheinter extends ModeleBoxes $companystatic->email = $objp->semail; $this->info_box_contents[$i][] = array( - 'td' => '', + 'td' => 'class="nowraponall"', 'text' => $ficheinterstatic->getNomUrl(1), 'asis' => 1, ); $this->info_box_contents[$i][] = array( - 'td' => '', + 'td' => 'class="tdoverflowmax150 maxwidth150onsmartphone"', 'text' => $companystatic->getNomUrl(1), 'asis' => 1, ); diff --git a/htdocs/core/boxes/box_last_modified_ticket.php b/htdocs/core/boxes/box_last_modified_ticket.php index de2bbd79181..18c2ebfe340 100644 --- a/htdocs/core/boxes/box_last_modified_ticket.php +++ b/htdocs/core/boxes/box_last_modified_ticket.php @@ -140,7 +140,7 @@ class box_last_modified_ticket extends ModeleBoxes // Ticket $this->info_box_contents[$i][0] = array( - 'td' => 'class="left"', + 'td' => 'class="nowraponall"', 'text' => $ticket->getNomUrl(1), 'asis' => 1, ); @@ -148,7 +148,7 @@ class box_last_modified_ticket extends ModeleBoxes // Subject $this->info_box_contents[$i][$r] = array( - 'td' => 'class="left"', + 'td' => 'class="nowrap"', 'text' => $objp->subject, // Some event have no ref 'url' => DOL_URL_ROOT."/ticket/card.php?track_id=".$objp->track_id, ); @@ -156,7 +156,7 @@ class box_last_modified_ticket extends ModeleBoxes // Customer $this->info_box_contents[$i][$r] = array( - 'td' => 'class="left"', + 'td' => 'class="tdoverflowmax150 maxwidth300onsmartphone"', 'text' => $link, 'asis' => 1, ); @@ -172,7 +172,7 @@ class box_last_modified_ticket extends ModeleBoxes // Statut $this->info_box_contents[$i][$r] = array( - 'td' => 'class="right"', + 'td' => 'class="right nowraponall"', 'text' => $ticket->getLibStatut(3) ); $r++; diff --git a/htdocs/core/boxes/box_last_ticket.php b/htdocs/core/boxes/box_last_ticket.php index 4c66c647477..4a0842139d6 100644 --- a/htdocs/core/boxes/box_last_ticket.php +++ b/htdocs/core/boxes/box_last_ticket.php @@ -141,7 +141,7 @@ class box_last_ticket extends ModeleBoxes // Ticket $this->info_box_contents[$i][$r] = array( - 'td' => 'class="left"', + 'td' => 'class="nowraponall"', 'text' => $ticket->getNomUrl(1), 'asis' => 1 ); @@ -149,7 +149,7 @@ class box_last_ticket extends ModeleBoxes // Subject $this->info_box_contents[$i][$r] = array( - 'td' => 'class="left"', + 'td' => '', 'text' => $objp->subject, // Some event have no ref 'url' => DOL_URL_ROOT."/ticket/card.php?track_id=" . $objp->track_id, ); @@ -157,7 +157,7 @@ class box_last_ticket extends ModeleBoxes // Customer $this->info_box_contents[$i][$r] = array( - 'td' => 'class="left"', + 'td' => '', 'text' => $link, 'asis' => 1, ); @@ -172,7 +172,7 @@ class box_last_ticket extends ModeleBoxes // Statut $this->info_box_contents[$i][$r] = array( - 'td' => 'class="right"', + 'td' => 'class="right nowraponall"', 'text' => $ticket->getLibStatut(3), ); $r++; diff --git a/htdocs/core/boxes/box_lastlogin.php b/htdocs/core/boxes/box_lastlogin.php index 970619ee7ac..7a6c74e216c 100644 --- a/htdocs/core/boxes/box_lastlogin.php +++ b/htdocs/core/boxes/box_lastlogin.php @@ -78,11 +78,11 @@ class box_lastlogin extends ModeleBoxes $line=0; $this->info_box_contents[$line][0] = array( - 'td' => '', + 'td' => 'class="tdoverflowmax150 maxwidth150onsmartphone"', 'text' => $langs->trans("User"), ); $this->info_box_contents[$line][1] = array( - 'td' => '', + 'td' => 'class="tdoverflowmax150 maxwidth150onsmartphone"', 'text' => $user->getNomUrl(-1), 'asis' => 1 ); diff --git a/htdocs/core/boxes/box_members.php b/htdocs/core/boxes/box_members.php index 29f37751ce9..242f26e5d60 100644 --- a/htdocs/core/boxes/box_members.php +++ b/htdocs/core/boxes/box_members.php @@ -124,13 +124,13 @@ class box_members extends ModeleBoxes } $this->info_box_contents[$line][] = array( - 'td' => '', + 'td' => 'class="tdoverflowmax150 maxwidth150onsmartphone"', 'text' => $memberstatic->getNomUrl(1), 'asis' => 1, ); $this->info_box_contents[$line][] = array( - 'td' => '', + 'td' => 'class="tdoverflowmax150 maxwidth150onsmartphone"', 'text' => $memberstatic->company, 'url' => DOL_URL_ROOT."/adherents/card.php?rowid=".$objp->rowid, ); diff --git a/htdocs/core/boxes/box_mos.php b/htdocs/core/boxes/box_mos.php index 32ae864fc2f..949f63776f6 100644 --- a/htdocs/core/boxes/box_mos.php +++ b/htdocs/core/boxes/box_mos.php @@ -116,7 +116,7 @@ class box_mos extends ModeleBoxes $productstatic->ref = $objp->product_ref; $this->info_box_contents[$line][] = array( - 'td' => '', + 'td' => 'class="nowraponall"', 'text' => $mostatic->getNomUrl(1), 'asis' => 1, ); diff --git a/htdocs/core/boxes/box_project.php b/htdocs/core/boxes/box_project.php index 48a6d260e2c..edd6c89054d 100644 --- a/htdocs/core/boxes/box_project.php +++ b/htdocs/core/boxes/box_project.php @@ -123,7 +123,7 @@ class box_project extends ModeleBoxes ); $this->info_box_contents[$i][] = array( - 'td' => '', + 'td' => 'class="tdoverflowmax150 maxwidth200onsmartphone"', 'text' => $objp->title, ); diff --git a/htdocs/core/boxes/box_propales.php b/htdocs/core/boxes/box_propales.php index 1fe8c2a0ed8..58b97c89386 100644 --- a/htdocs/core/boxes/box_propales.php +++ b/htdocs/core/boxes/box_propales.php @@ -128,7 +128,7 @@ class box_propales extends ModeleBoxes } $this->info_box_contents[$line][] = array( - 'td' => '', + 'td' => 'class="nowraponall"', 'text' => $propalstatic->getNomUrl(1), 'text2'=> $late, 'asis' => 1, diff --git a/htdocs/core/boxes/box_supplier_orders.php b/htdocs/core/boxes/box_supplier_orders.php index a95c008688b..881e17f73ec 100644 --- a/htdocs/core/boxes/box_supplier_orders.php +++ b/htdocs/core/boxes/box_supplier_orders.php @@ -124,19 +124,19 @@ class box_supplier_orders extends ModeleBoxes $thirdpartytmp->logo = $objp->logo; $this->info_box_contents[$line][] = array( - 'td' => '', + 'td' => 'class="nowraponall"', 'text' => $supplierorderstatic->getNomUrl(1), 'asis' => 1 ); $this->info_box_contents[$line][] = array( - 'td' => '', + 'td' => 'class="tdoverflowmax150 maxwidth150onsmartphone"', 'text' => $thirdpartytmp->getNomUrl(1, 'supplier'), 'asis' => 1, ); $this->info_box_contents[$line][] = array( - 'td' => 'class="right nowrap"', + 'td' => 'class="right nowraponall"', 'text' => price($objp->total_ht, 0, $langs, 0, -1, -1, $conf->currency), ); diff --git a/htdocs/core/boxes/box_supplier_orders_awaiting_reception.php b/htdocs/core/boxes/box_supplier_orders_awaiting_reception.php index 326a9297ce8..416dc7f2f2a 100644 --- a/htdocs/core/boxes/box_supplier_orders_awaiting_reception.php +++ b/htdocs/core/boxes/box_supplier_orders_awaiting_reception.php @@ -130,19 +130,19 @@ class box_supplier_orders_awaiting_reception extends ModeleBoxes $thirdpartytmp->logo = $objp->logo; $this->info_box_contents[$line][] = array( - 'td' => '', + 'td' => 'class="nowraponall"', 'text' => $supplierorderstatic->getNomUrl(1), 'asis' => 1 ); $this->info_box_contents[$line][] = array( - 'td' => '', + 'td' => 'class="tdoverflowmax150 maxwidth150onsmartphone"', 'text' => $thirdpartytmp->getNomUrl(1, 'supplier'), 'asis' => 1, ); $this->info_box_contents[$line][] = array( - 'td' => 'class="right nowrap"', + 'td' => 'class="right nowraponall"', 'text' => price($objp->total_ht, 0, $langs, 0, -1, -1, $conf->currency), ); diff --git a/htdocs/theme/eldy/global.inc.php b/htdocs/theme/eldy/global.inc.php index 6db99927fb1..8cab8f2cf5f 100644 --- a/htdocs/theme/eldy/global.inc.php +++ b/htdocs/theme/eldy/global.inc.php @@ -681,6 +681,12 @@ select.flat.selectlimit { -webkit-line-clamp: 2; overflow: hidden; } +.twolinesmax { + display: -webkit-box; + -webkit-box-orient: vertical; + -webkit-line-clamp: 2; + overflow: hidden; +} .tablelistofcalendars { margin-top: 25px !important;