From a7ecf9f18b4a1ce3f9e9aa9580549853937d90f0 Mon Sep 17 00:00:00 2001 From: Alexandre SPANGARO Date: Wed, 4 Sep 2019 09:32:37 +0200 Subject: [PATCH 1/6] FIX Missing ticket icon on md theme --- htdocs/theme/md/img/title_ticket.png | Bin 0 -> 234 bytes htdocs/theme/md/img/title_ticketsup.png | Bin 1044 -> 0 bytes 2 files changed, 0 insertions(+), 0 deletions(-) create mode 100644 htdocs/theme/md/img/title_ticket.png delete mode 100644 htdocs/theme/md/img/title_ticketsup.png diff --git a/htdocs/theme/md/img/title_ticket.png b/htdocs/theme/md/img/title_ticket.png new file mode 100644 index 0000000000000000000000000000000000000000..b1cf5df0e7580226f61d129d2ebbd93506c0ee75 GIT binary patch literal 234 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`Y)RhkE^%(yc-&<;;;jpisG|i(`nz>ARCRaxok7IL~kXzgpJm zM11VK^(HA9|5mHa<@0*ky3KvMaD~7LH>R5mMdzB|2db>yXXyFuWtvwery_%ZMTfA= zhjgLjJv)AvF52&z70kZ(`(4T8Co7wyvYBt$D^Iz;@5gSAYJ<(cFLJz|+5P3Pw|E2l Ywo4Xlix2!20y=@g)78&qol`;+0C<>DdjJ3c literal 0 HcmV?d00001 diff --git a/htdocs/theme/md/img/title_ticketsup.png b/htdocs/theme/md/img/title_ticketsup.png deleted file mode 100644 index 3ec332075e66b1160122713117fa0d8087f659c5..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1044 zcmV+v1nc{WP)kdg00002VoOIv0RM-N z%)bBt010qNS#tmY4c7nw4c7reD4Tcy000McNliru;sXr{7YHUBg%1D#1EonsK~zY` z&6Vv>+f@|DKj+?GOI!Oe%0ttN3<`sdEyC0&NN_>-kSr`F#uvWx?=#VuMVTRPCT5Yr zP}vM5jFurAY!phN4;j$*_q)DmDJ{$w`bN*Yn{&ROdmeJ`h5y<#QQFC2{*|_yCP87* zN0FzL|AE*dj+&fVoe_65-(Z92B{Iloa0Y6 z;Jn9-FoK6BJh*@o2OM%B4|uS20K7>T2{M(89t#fnTLn{Kj%~800OBV^8}CT~lh5Sl?fd!d`exKwPxRI0 z{dnFvGpl~FlMDG{&!vD)nh$s1CloQh$ zeuhU36K#-38Rk*pp);pfRg)fk=i(`V88s1XW`9iri%fH+0dR$B7UB1&YDR2{$ml76 z6}B8}K`#RkB!)wKP2P?}j39tcSc}?N%_jgO5#<$2WmKi}1}_8D(&Qooc&q!8CoQ79 z!;uDnM3qb1YI~*tfQ^qK+_(U6;bsUQHo$B_?`XuWVvQxl#H)~8_2f{-%~eVOl(>qU zGEVifoD%VxXam5~T8kscOYPtgr3-*AqL?E&C`W89E~^2cQgWy)9jL}+Sp?kl0?>;a z!{X7ds-SYop-MHDu%QmM(&0~h)%%y2!b=>0I9{e$s^svoPqirI(5yEA{3%@&RGav# zz#S$@)-p&k$xgKce$}c(m;8+xd|xIf!iA~?AWec+T4rxDgI=|!9|E&exn;N zKa*#l9QK6eTxV3oJd~-VeFBiM`?As@t%S9!e`mQsj^|_%c35G99Hm<=e5A%yKrO2~ zchawU4-$J9EZw8Sa!&l`vmfLi+d#Tf{g+l(r`(Wh;#Yfe@4NZBN1%S?KJ{>oal*hB zQ*4ss0Pqkb!VMz8E_bq?S!@i3pUe;6?4693*MB@;G@Bl}O?TyEkyTb%`D&N{rTqo<%tv;ioLqST O0000 Date: Thu, 5 Sep 2019 11:11:48 +0200 Subject: [PATCH 2/6] Update stripe.class.php --- htdocs/stripe/class/stripe.class.php | 1 + 1 file changed, 1 insertion(+) diff --git a/htdocs/stripe/class/stripe.class.php b/htdocs/stripe/class/stripe.class.php index d0459e1e288..2211bf80118 100644 --- a/htdocs/stripe/class/stripe.class.php +++ b/htdocs/stripe/class/stripe.class.php @@ -383,6 +383,7 @@ class Stripe extends CommonObject { $metadata['dol_type'] = $object->element; $metadata['dol_id'] = $object->id; + if (isset($object->thirdparty->id)) $metadata['dol_thirdparty_id'] = $object->thirdparty->id; } $dataforintent = array( From 4fe141c9f1eb3e4999f87e9667bd4afe8c132d00 Mon Sep 17 00:00:00 2001 From: Alexandre SPANGARO Date: Thu, 5 Sep 2019 12:05:50 +0200 Subject: [PATCH 3/6] FIX Nowrap missing on amount in boxes --- htdocs/core/boxes/box_activity.php | 6 +++--- htdocs/core/boxes/box_comptes.php | 2 +- htdocs/core/boxes/box_produits_alerte_stock.php | 4 ++-- htdocs/core/boxes/box_supplier_orders.php | 2 +- 4 files changed, 7 insertions(+), 7 deletions(-) diff --git a/htdocs/core/boxes/box_activity.php b/htdocs/core/boxes/box_activity.php index 995ba93fb64..c313b6c526a 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="right"', + 'td' => 'class="nowrap right"', 'text' => price($data[$j]->Mnttot, 1, $langs, 0, 0, -1, $conf->currency), ); $this->info_box_contents[$line][4] = array( @@ -256,7 +256,7 @@ class box_activity extends ModeleBoxes $totalnb += $data[$j]->nb; $this->info_box_contents[$line][3] = array( - 'td' => 'class="right"', + 'td' => 'class="nowrap right"', 'text' => price($data[$j]->Mnttot, 1, $langs, 0, 0, -1, $conf->currency), ); $this->info_box_contents[$line][4] = array( @@ -340,7 +340,7 @@ class box_activity extends ModeleBoxes ); $this->info_box_contents[$line][3] = array( - 'td' => 'class="right"', + 'td' => 'class="nowrap right"', 'text' => price($data[$j]->Mnttot, 1, $langs, 0, 0, -1, $conf->currency) ); diff --git a/htdocs/core/boxes/box_comptes.php b/htdocs/core/boxes/box_comptes.php index 525562d308d..1928ac7cc94 100644 --- a/htdocs/core/boxes/box_comptes.php +++ b/htdocs/core/boxes/box_comptes.php @@ -134,7 +134,7 @@ class box_comptes extends ModeleBoxes ); $this->info_box_contents[$line][] = array( - 'td' => 'class="right"', + 'td' => 'class="right nowraponall"', 'text' => price($solde, 0, $langs, 0, -1, -1, $objp->currency_code) ); diff --git a/htdocs/core/boxes/box_produits_alerte_stock.php b/htdocs/core/boxes/box_produits_alerte_stock.php index d1381870338..165b6db0d6b 100644 --- a/htdocs/core/boxes/box_produits_alerte_stock.php +++ b/htdocs/core/boxes/box_produits_alerte_stock.php @@ -179,12 +179,12 @@ class box_produits_alerte_stock extends ModeleBoxes } $this->info_box_contents[$line][] = array( - 'td' => 'class="right"', + 'td' => 'class="right nowraponall"', 'text' => $price, ); $this->info_box_contents[$line][] = array( - 'td' => 'class="nowrap"', + 'td' => 'class="right"', 'text' => $price_base_type, ); diff --git a/htdocs/core/boxes/box_supplier_orders.php b/htdocs/core/boxes/box_supplier_orders.php index 34316cd1ad1..6874425db78 100644 --- a/htdocs/core/boxes/box_supplier_orders.php +++ b/htdocs/core/boxes/box_supplier_orders.php @@ -135,7 +135,7 @@ class box_supplier_orders extends ModeleBoxes ); $this->info_box_contents[$line][] = array( - 'td' => 'class="right"', + 'td' => 'class="right nowrap"', 'text' => price($objp->total_ht, 0, $langs, 0, -1, -1, $conf->currency), ); From 369961b3766891766626307efbd8a3c5eab97ac1 Mon Sep 17 00:00:00 2001 From: Regis Houssin Date: Fri, 6 Sep 2019 11:55:41 +0200 Subject: [PATCH 4/6] FIX avoid Warning: A non-numeric value encountered --- htdocs/contrat/card.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/htdocs/contrat/card.php b/htdocs/contrat/card.php index 5c9ac3375dd..35338f41903 100644 --- a/htdocs/contrat/card.php +++ b/htdocs/contrat/card.php @@ -433,7 +433,7 @@ if (empty($reshook)) } $qty = GETPOST('qty'.$predef); - $remise_percent = GETPOST('remise_percent'.$predef); + $remise_percent = (GETPOST('remise_percent'.$predef) != '' ? GETPOST('remise_percent'.$predef) : 0); if ($qty == '') { @@ -566,7 +566,8 @@ if (empty($reshook)) $info_bits=0; if ($tva_npr) $info_bits |= 0x01; - if (((!empty($conf->global->MAIN_USE_ADVANCED_PERMS) && empty($user->rights->produit->ignore_price_min_advance)) || empty($conf->global->MAIN_USE_ADVANCED_PERMS) )&& ($price_min && (price2num($pu_ht)*(1-price2num($remise_percent)/100) < price2num($price_min)))) + if (((! empty($conf->global->MAIN_USE_ADVANCED_PERMS) && empty($user->rights->produit->ignore_price_min_advance)) + || empty($conf->global->MAIN_USE_ADVANCED_PERMS) ) && ($price_min && (price2num($pu_ht)*(1-price2num($remise_percent)/100) < price2num($price_min)))) { $object->error = $langs->trans("CantBeLessThanMinPrice", price(price2num($price_min, 'MU'), 0, $langs, 0, 0, -1, $conf->currency)); $result = -1 ; From f12a01293233b43dceed54eb13ed3842dcf2b76d Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Fri, 6 Sep 2019 23:25:40 +0200 Subject: [PATCH 5/6] Update card.php --- htdocs/contrat/card.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/htdocs/contrat/card.php b/htdocs/contrat/card.php index 35338f41903..0bf304b96a1 100644 --- a/htdocs/contrat/card.php +++ b/htdocs/contrat/card.php @@ -433,7 +433,7 @@ if (empty($reshook)) } $qty = GETPOST('qty'.$predef); - $remise_percent = (GETPOST('remise_percent'.$predef) != '' ? GETPOST('remise_percent'.$predef) : 0); + $remise_percent = ((GETPOST('remise_percent'.$predef) != '') ? GETPOST('remise_percent'.$predef) : 0); if ($qty == '') { From a168c989f8a12462bee3c96a4f1e50ec737480cd Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Fri, 6 Sep 2019 23:29:27 +0200 Subject: [PATCH 6/6] Update stripe.class.php --- htdocs/stripe/class/stripe.class.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/htdocs/stripe/class/stripe.class.php b/htdocs/stripe/class/stripe.class.php index 2211bf80118..abc875c370f 100644 --- a/htdocs/stripe/class/stripe.class.php +++ b/htdocs/stripe/class/stripe.class.php @@ -383,7 +383,7 @@ class Stripe extends CommonObject { $metadata['dol_type'] = $object->element; $metadata['dol_id'] = $object->id; - if (isset($object->thirdparty->id)) $metadata['dol_thirdparty_id'] = $object->thirdparty->id; + if (is_object($object->thirdparty) && $object->thirdparty->id > 0) $metadata['dol_thirdparty_id'] = $object->thirdparty->id; } $dataforintent = array(