From c242a0561bbb4c000df21d337b492732597aaf27 Mon Sep 17 00:00:00 2001 From: Francis Appels Date: Fri, 25 Feb 2022 16:11:16 +0100 Subject: [PATCH] Fix shipping list, e.shipping_method_id should be e.fk_shipping_method. Disabled searchall for shipping method, does not work. --- htdocs/expedition/list.php | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/htdocs/expedition/list.php b/htdocs/expedition/list.php index 378d95e00c8..2d81c5e0545 100644 --- a/htdocs/expedition/list.php +++ b/htdocs/expedition/list.php @@ -116,7 +116,7 @@ $fieldstosearchall = array( 'e.ref'=>"Ref", 's.nom'=>"ThirdParty", 'e.note_public'=>'NotePublic', - 'e.shipping_method_id'=>'SendingMethod', + //'e.fk_shipping_method'=>'SendingMethod', // TODO fix this, does not work 'e.tracking_number'=>"TrackingNumber", ); if (empty($user->socid)) { @@ -134,7 +134,7 @@ $arrayfields = array( 'country.code_iso'=>array('label'=>$langs->trans("Country"), 'checked'=>0, 'position'=>7), 'typent.code'=>array('label'=>$langs->trans("ThirdPartyType"), 'checked'=>$checkedtypetiers, 'position'=>8), 'e.date_delivery'=>array('label'=>$langs->trans("DateDeliveryPlanned"), 'checked'=>1, 'position'=>9), - 'e.shipping_method_id'=>array('label'=>$langs->trans('SendingMethod'), 'checked'=>1, 'position'=>10), + 'e.fk_shipping_method'=>array('label'=>$langs->trans('SendingMethod'), 'checked'=>1, 'position'=>10), 'e.tracking_number'=>array('label'=>$langs->trans("TrackingNumber"), 'checked'=>1, 'position'=>11), 'e.weight'=>array('label'=>$langs->trans("Weight"), 'checked'=>0, 'position'=>12), 'e.datec'=>array('label'=>$langs->trans("DateCreation"), 'checked'=>0, 'position'=>500), @@ -654,7 +654,7 @@ if (!empty($arrayfields['e.date_delivery']['checked'])) { print ''; print ''; } -if (!empty($arrayfields['e.shipping_method_id']['checked'])) { +if (!empty($arrayfields['e.fk_shipping_method']['checked'])) { // Delivery method print ''; $shipment->fetch_delivery_methods(); @@ -751,8 +751,8 @@ if (!empty($arrayfields['e.weight']['checked'])) { if (!empty($arrayfields['e.date_delivery']['checked'])) { print_liste_field_titre($arrayfields['e.date_delivery']['label'], $_SERVER["PHP_SELF"], "e.date_delivery", "", $param, '', $sortfield, $sortorder, 'center '); } -if (!empty($arrayfields['e.shipping_method_id']['checked'])) { - print_liste_field_titre($arrayfields['e.shipping_method_id']['label'], $_SERVER["PHP_SELF"], "e.fk_shipping_method", "", $param, '', $sortfield, $sortorder, 'center '); +if (!empty($arrayfields['e.fk_shipping_method']['checked'])) { + print_liste_field_titre($arrayfields['e.fk_shipping_method']['label'], $_SERVER["PHP_SELF"], "e.fk_shipping_method", "", $param, '', $sortfield, $sortorder, 'center '); } if (!empty($arrayfields['e.tracking_number']['checked'])) { print_liste_field_titre($arrayfields['e.tracking_number']['label'], $_SERVER["PHP_SELF"], "e.tracking_number", "", $param, '', $sortfield, $sortorder, 'center '); @@ -901,7 +901,7 @@ while ($i < min($num, $limit)) { print dol_print_date($db->jdate($obj->delivery_date), "dayhour"); print "\n"; } - if (!empty($arrayfields['e.shipping_method_id']['checked'])) { + if (!empty($arrayfields['e.fk_shipping_method']['checked'])) { // Get code using getLabelFromKey $code=$langs->getLabelFromKey($db, $shipment->shipping_method_id, 'c_shipment_mode', 'rowid', 'code'); print '';