From 8410d59182c558ecb36cbea899ca587c9af71444 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Thu, 14 Mar 2019 16:16:50 +0100 Subject: [PATCH] FIX Missing field "In sale" in list --- htdocs/accountancy/admin/productaccount.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/htdocs/accountancy/admin/productaccount.php b/htdocs/accountancy/admin/productaccount.php index 246d3752f56..389dd8df7b8 100644 --- a/htdocs/accountancy/admin/productaccount.php +++ b/htdocs/accountancy/admin/productaccount.php @@ -65,6 +65,8 @@ $accounting_product_mode = GETPOST('accounting_product_mode', 'alpha'); $btn_changeaccount = GETPOST('changeaccount', 'alpha'); $btn_changetype = GETPOST('changetype', 'alpha'); +if (empty($accounting_product_mode)) $accounting_product_mode='ACCOUNTANCY_SELL'; + $limit = GETPOST('limit','int')?GETPOST('limit','int'):(empty($conf->global->ACCOUNTING_LIMIT_LIST_VENTILATION)?$conf->liste_limit:$conf->global->ACCOUNTING_LIMIT_LIST_VENTILATION); $sortfield = GETPOST("sortfield",'alpha'); $sortorder = GETPOST("sortorder",'alpha'); @@ -112,8 +114,6 @@ if ($action == 'update') { 'ACCOUNTANCY_BUY' ); - $accounting_product_mode = GETPOST('accounting_product_mode', 'alpha'); - if (in_array($accounting_product_mode, $accounting_product_modes)) { if (! dolibarr_set_const($db, 'ACCOUNTING_PRODUCT_MODE', $accounting_product_mode, 'chaine', 0, '', $conf->entity)) {