diff --git a/htdocs/admin/emailcollector_list.php b/htdocs/admin/emailcollector_list.php index 55b2052936c..c57e681be34 100644 --- a/htdocs/admin/emailcollector_list.php +++ b/htdocs/admin/emailcollector_list.php @@ -315,21 +315,6 @@ if ($num == 1 && !empty($conf->global->MAIN_SEARCH_DIRECT_OPEN_IF_ONLY_ONE) && $ llxHeader('', $title, $help_url); -// Example : Adding jquery code -print ''; - $arrayofselected = is_array($toselect) ? $toselect : array(); $param = ''; diff --git a/htdocs/asset/list.php b/htdocs/asset/list.php index 056a73328dc..1d994e25177 100644 --- a/htdocs/asset/list.php +++ b/htdocs/asset/list.php @@ -305,21 +305,6 @@ if ($num == 1 && !empty($conf->global->MAIN_SEARCH_DIRECT_OPEN_IF_ONLY_ONE) && $ llxHeader('', $title, $help_url); -// Example : Adding jquery code -print ''; - $arrayofselected = is_array($toselect) ? $toselect : array(); $param = ''; diff --git a/htdocs/bom/bom_card.php b/htdocs/bom/bom_card.php index fbd219a298b..b598b95ae0a 100644 --- a/htdocs/bom/bom_card.php +++ b/htdocs/bom/bom_card.php @@ -244,22 +244,6 @@ $title = $langs->trans('BOM'); $help_url ='EN:Module_BOM'; llxHeader('', $title, $help_url); -// Example : Adding jquery code -print ''; - - // Part to create if ($action == 'create') { print load_fiche_titre($langs->trans("NewBOM"), '', 'bom'); diff --git a/htdocs/commande/class/commande.class.php b/htdocs/commande/class/commande.class.php index 2805f4556d3..a819bb40f1c 100644 --- a/htdocs/commande/class/commande.class.php +++ b/htdocs/commande/class/commande.class.php @@ -4131,7 +4131,7 @@ class OrderLine extends CommonOrderLine $sql .= ' cd.fk_unit,'; $sql .= ' cd.fk_multicurrency, cd.multicurrency_code, cd.multicurrency_subprice, cd.multicurrency_total_ht, cd.multicurrency_total_tva, cd.multicurrency_total_ttc,'; $sql .= ' p.ref as product_ref, p.label as product_label, p.description as product_desc, p.tobatch as product_tobatch,'; - $sql .= ' cd.date_start, cd.date_end'; + $sql .= ' cd.date_start, cd.date_end, cd.vat_src_code'; $sql .= ' FROM '.MAIN_DB_PREFIX.'commandedet as cd'; $sql .= ' LEFT JOIN '.MAIN_DB_PREFIX.'product as p ON cd.fk_product = p.rowid'; $sql .= ' WHERE cd.rowid = '.((int) $rowid); @@ -4352,7 +4352,8 @@ class OrderLine extends CommonOrderLine // if buy price not defined, define buyprice as configured in margin admin if ($this->pa_ht == 0 && $pa_ht_isemptystring) { - if (($result = $this->defineBuyPrice($this->subprice, $this->remise_percent, $this->fk_product)) < 0) { + $result = $this->defineBuyPrice($this->subprice, $this->remise_percent, $this->fk_product); + if ($result < 0) { return $result; } else { $this->pa_ht = $result; @@ -4529,7 +4530,8 @@ class OrderLine extends CommonOrderLine // if buy price not defined, define buyprice as configured in margin admin if ($this->pa_ht == 0 && $pa_ht_isemptystring) { - if (($result = $this->defineBuyPrice($this->subprice, $this->remise_percent, $this->fk_product)) < 0) { + $result = $this->defineBuyPrice($this->subprice, $this->remise_percent, $this->fk_product); + if ($result < 0) { return $result; } else { $this->pa_ht = $result; diff --git a/htdocs/commande/list.php b/htdocs/commande/list.php index 98bbd00b351..73413d1070f 100644 --- a/htdocs/commande/list.php +++ b/htdocs/commande/list.php @@ -1373,7 +1373,7 @@ if ($resql) { $generic_product = new Product($db); $userstatic = new User($db); $i = 0; - $totalarray = array(); + $totalarray = array('nbfield' => 0, 'val' => array(), 'pos' => array()); while ($i < min($num, $limit)) { $obj = $db->fetch_object($resql); @@ -1610,7 +1610,11 @@ if ($resql) { if (!$i) { $totalarray['pos'][$totalarray['nbfield']] = 'c.total_ht'; } - $totalarray['val']['c.total_ht'] += $obj->total_ht; + if (isset($totalarray['val']['c.total_ht'])) { + $totalarray['val']['c.total_ht'] += $obj->total_ht; + } else { + $totalarray['val']['c.total_ht'] = $obj->total_ht; + } } // Amount VAT if (!empty($arrayfields['c.total_vat']['checked'])) { diff --git a/htdocs/compta/cashcontrol/cashcontrol_list.php b/htdocs/compta/cashcontrol/cashcontrol_list.php index ab8451c9e59..ec7af37940c 100644 --- a/htdocs/compta/cashcontrol/cashcontrol_list.php +++ b/htdocs/compta/cashcontrol/cashcontrol_list.php @@ -343,21 +343,6 @@ if ($num == 1 && !empty($conf->global->MAIN_SEARCH_DIRECT_OPEN_IF_ONLY_ONE) && $ llxHeader('', $title, $help_url, '', 0, 0, $morejs, $morecss, '', 'classforhorizontalscrolloftabs'); -// Example : Adding jquery code -print ''; - $arrayofselected = is_array($toselect) ? $toselect : array(); $param = ''; diff --git a/htdocs/compta/facture/card.php b/htdocs/compta/facture/card.php index 585cabc1be4..b44b7d22fd8 100644 --- a/htdocs/compta/facture/card.php +++ b/htdocs/compta/facture/card.php @@ -2375,12 +2375,12 @@ if (empty($reshook)) { setEventMessages($mesg, null, 'warnings'); $error++; $result = -1; + } elseif (GETPOST('progress') < $percent) { + $mesg = '
'.$langs->trans("CantBeLessThanMinPercent").'
'; + setEventMessages($mesg, null, 'warnings'); + $error++; + $result = -1; } - } elseif (GETPOST('progress') < $percent) { - $mesg = '
'.$langs->trans("CantBeLessThanMinPercent").'
'; - setEventMessages($mesg, null, 'warnings'); - $error++; - $result = -1; } // Check minimum price diff --git a/htdocs/eventorganization/conferenceorbooth_list.php b/htdocs/eventorganization/conferenceorbooth_list.php index b51823242f8..d7f7cdb8bb1 100644 --- a/htdocs/eventorganization/conferenceorbooth_list.php +++ b/htdocs/eventorganization/conferenceorbooth_list.php @@ -253,20 +253,6 @@ if ($projectid > 0) { llxHeader('', $title, $help_url); -// Example : Adding jquery code -print ''; if ($projectid > 0) { // To verify role of users diff --git a/htdocs/fourn/commande/list.php b/htdocs/fourn/commande/list.php index c644f9e35a5..bf8e53e8b82 100644 --- a/htdocs/fourn/commande/list.php +++ b/htdocs/fourn/commande/list.php @@ -610,7 +610,7 @@ $sql .= ' cf.fk_multicurrency, cf.multicurrency_code, cf.multicurrency_tx, cf.mu $sql .= ' cf.date_creation as date_creation, cf.tms as date_update,'; $sql .= ' cf.note_public, cf.note_private,'; $sql .= " p.rowid as project_id, p.ref as project_ref, p.title as project_title,"; -$sql .= " u.firstname, u.lastname, u.photo, u.login, u.email as user_email"; +$sql .= " u.firstname, u.lastname, u.photo, u.login, u.email as user_email, u.statut as user_status"; // Add fields from extrafields if (!empty($extrafields->attributes[$object->table_element]['label'])) { foreach ($extrafields->attributes[$object->table_element]['label'] as $key => $val) { @@ -1346,6 +1346,7 @@ if ($resql) { $userstatic->login = $obj->login; $userstatic->photo = $obj->photo; $userstatic->email = $obj->user_email; + $userstatic->statut = $obj->user_status; if (!empty($arrayfields['u.login']['checked'])) { print ''; if ($userstatic->id) { diff --git a/htdocs/langs/nl_NL/main.lang b/htdocs/langs/nl_NL/main.lang index 4a0eb506398..9c0fcdfa791 100644 --- a/htdocs/langs/nl_NL/main.lang +++ b/htdocs/langs/nl_NL/main.lang @@ -10,10 +10,10 @@ SeparatorDecimal=, SeparatorThousand=Space FormatDateShort=%m/%d/%Y FormatDateShortInput=%m/%d/%Y -FormatDateShortJava=MM/dd/jjjj -FormatDateShortJavaInput=MM/dd/jjjj -FormatDateShortJQuery=mm/dd/jj -FormatDateShortJQueryInput=mm/dd/jj +FormatDateShortJava=MM/dd/yyyy +FormatDateShortJavaInput=MM/dd/yyyy +FormatDateShortJQuery=mm/dd/yy +FormatDateShortJQueryInput=mm/dd/yy FormatHourShortJQuery=HH:MI FormatHourShort=%I:%M %p FormatHourShortDuration=%H:%M diff --git a/htdocs/modulebuilder/template/myobject_card.php b/htdocs/modulebuilder/template/myobject_card.php index 9a689c79a08..cac59593950 100644 --- a/htdocs/modulebuilder/template/myobject_card.php +++ b/htdocs/modulebuilder/template/myobject_card.php @@ -212,19 +212,19 @@ $help_url = ''; llxHeader('', $title, $help_url); // Example : Adding jquery code -print ''; +// print ''; // Part to create diff --git a/htdocs/modulebuilder/template/myobject_list.php b/htdocs/modulebuilder/template/myobject_list.php index 41561a5a45b..abc8b879d33 100644 --- a/htdocs/modulebuilder/template/myobject_list.php +++ b/htdocs/modulebuilder/template/myobject_list.php @@ -386,19 +386,19 @@ if ($num == 1 && !empty($conf->global->MAIN_SEARCH_DIRECT_OPEN_IF_ONLY_ONE) && $ llxHeader('', $title, $help_url, '', 0, 0, $morejs, $morecss, '', 'classforhorizontalscrolloftabs'); // Example : Adding jquery code -print ''; +// print ''; $arrayofselected = is_array($toselect) ? $toselect : array(); diff --git a/htdocs/mrp/mo_card.php b/htdocs/mrp/mo_card.php index fad22645cd5..b6cc502bd60 100644 --- a/htdocs/mrp/mo_card.php +++ b/htdocs/mrp/mo_card.php @@ -201,20 +201,6 @@ $title = $langs->trans('Mo')." - ".$langs->trans("Card"); llxHeader('', $title, ''); -// Example : Adding jquery code -print ''; // Part to create diff --git a/htdocs/mrp/mo_list.php b/htdocs/mrp/mo_list.php index 1883517470c..731a7bcfc50 100644 --- a/htdocs/mrp/mo_list.php +++ b/htdocs/mrp/mo_list.php @@ -299,20 +299,6 @@ if ($num == 1 && !empty($conf->global->MAIN_SEARCH_DIRECT_OPEN_IF_ONLY_ONE) && $ llxHeader('', $title, $help_url); -// Example : Adding jquery code -print ''; $arrayofselected = is_array($toselect) ? $toselect : array(); diff --git a/htdocs/partnership/partnership_list.php b/htdocs/partnership/partnership_list.php index 79f51be6ca9..49d46c652fd 100644 --- a/htdocs/partnership/partnership_list.php +++ b/htdocs/partnership/partnership_list.php @@ -398,20 +398,6 @@ if ($num == 1 && !empty($conf->global->MAIN_SEARCH_DIRECT_OPEN_IF_ONLY_ONE) && $ llxHeader('', $title, $help_url, '', 0, 0, $morejs, $morecss, '', 'classforhorizontalscrolloftabs'); -// Example : Adding jquery code -print ''; $arrayofselected = is_array($toselect) ? $toselect : array(); diff --git a/htdocs/product/inventory/card.php b/htdocs/product/inventory/card.php index 6a29a414ed7..5ec359e5d8a 100644 --- a/htdocs/product/inventory/card.php +++ b/htdocs/product/inventory/card.php @@ -168,20 +168,6 @@ $help_url = 'EN:Module_Stocks_En|FR:Module_Stock|ES:Módulo_Stocks|DE:Modul_Best llxHeader('', $title, $help_url); -// Example : Adding jquery code -print ''; // Part to create diff --git a/htdocs/recruitment/recruitmentcandidature_card.php b/htdocs/recruitment/recruitmentcandidature_card.php index 4826dc735ef..a1e98ded601 100644 --- a/htdocs/recruitment/recruitmentcandidature_card.php +++ b/htdocs/recruitment/recruitmentcandidature_card.php @@ -305,21 +305,6 @@ $title = $langs->trans("RecruitmentCandidature"); $help_url = ''; llxHeader('', $title, $help_url); -// Example : Adding jquery code -print ''; - // Part to create if ($action == 'create') { diff --git a/htdocs/recruitment/recruitmentcandidature_list.php b/htdocs/recruitment/recruitmentcandidature_list.php index 1caeb05095f..7a5a88bc6c4 100644 --- a/htdocs/recruitment/recruitmentcandidature_list.php +++ b/htdocs/recruitment/recruitmentcandidature_list.php @@ -348,21 +348,6 @@ if ($num == 1 && !empty($conf->global->MAIN_SEARCH_DIRECT_OPEN_IF_ONLY_ONE) && $ llxHeader('', $title, $help_url); -// Example : Adding jquery code -print ''; - $arrayofselected = is_array($toselect) ? $toselect : array(); $param = ''; diff --git a/htdocs/recruitment/recruitmentjobposition_list.php b/htdocs/recruitment/recruitmentjobposition_list.php index 6475a60a8ed..7ccad1de16a 100644 --- a/htdocs/recruitment/recruitmentjobposition_list.php +++ b/htdocs/recruitment/recruitmentjobposition_list.php @@ -349,21 +349,6 @@ if ($num == 1 && !empty($conf->global->MAIN_SEARCH_DIRECT_OPEN_IF_ONLY_ONE) && $ llxHeader('', $title, $help_url); -// Example : Adding jquery code -print ''; - $arrayofselected = is_array($toselect) ? $toselect : array(); $param = ''; diff --git a/htdocs/website/websiteaccount_card.php b/htdocs/website/websiteaccount_card.php index 2074873a031..cf4d26b2c33 100644 --- a/htdocs/website/websiteaccount_card.php +++ b/htdocs/website/websiteaccount_card.php @@ -117,22 +117,6 @@ $formfile = new FormFile($db); llxHeader('', 'WebsiteAccount', ''); -// Example : Adding jquery code -print ''; - - // Part to create if ($action == 'create') { print load_fiche_titre($langs->trans("NewObject", $langs->transnoentitiesnoconv("WebsiteAccount"))); diff --git a/htdocs/workstation/workstation_card.php b/htdocs/workstation/workstation_card.php index 673b1db935d..5b63ca2d481 100755 --- a/htdocs/workstation/workstation_card.php +++ b/htdocs/workstation/workstation_card.php @@ -159,7 +159,7 @@ $help_url = 'EN:Module_Workstation'; llxHeader('', $title, $help_url); -// Example : Adding jquery code +// jquery code ?>