mirror of
https://github.com/Dolibarr/dolibarr.git
synced 2025-02-20 13:46:52 +01:00
if we set another view list mode, we keep it
if we set another view list mode, we keep it (till we change one more time)
This commit is contained in:
parent
febc1b8600
commit
2d8c629200
|
|
@ -43,10 +43,15 @@ require_once DOL_DOCUMENT_ROOT.'/admin/dolistore/class/dolistore.class.php';
|
|||
// Load translation files required by the page
|
||||
$langs->loadLangs(array("errors", "admin", "modulebuilder"));
|
||||
|
||||
$mode = GETPOSTISSET('mode') ? GETPOST('mode', 'alpha') : (empty($conf->global->MAIN_MODULE_SETUP_ON_LIST_BY_DEFAULT) ? 'commonkanban' : 'common');
|
||||
if (empty($mode)) {
|
||||
$mode = 'common';
|
||||
// if we set another view list mode, we keep it (till we change one more time)
|
||||
if (GETPOSTISSET('mode')) {
|
||||
$mode = GETPOST('mode', 'alpha');
|
||||
if ($mode =='common' || $mode =='commonkanban')
|
||||
dolibarr_set_const( $db, "MAIN_MODULE_SETUP_ON_LIST_BY_DEFAULT", $mode, 'chaine', 0, '', $conf->entity);
|
||||
} else {
|
||||
$mode = (empty($conf->global->MAIN_MODULE_SETUP_ON_LIST_BY_DEFAULT) ? 'commonkanban' : $conf->global->MAIN_MODULE_SETUP_ON_LIST_BY_DEFAULT);
|
||||
}
|
||||
|
||||
$action = GETPOST('action', 'aZ09');
|
||||
$value = GETPOST('value', 'alpha');
|
||||
$page_y = GETPOST('page_y', 'int');
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user