From cb0ab53709e4c61857928ba922cd93ac4e76c956 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Sun, 27 Oct 2024 14:08:59 +0100 Subject: [PATCH] Look and feel v21 --- htdocs/admin/mails_templates.php | 4 +-- .../comm/action/class/cactioncomm.class.php | 12 ++++----- htdocs/core/modules/modWebsite.class.php | 2 +- htdocs/main.inc.php | 2 +- htdocs/mrp/mo_agenda.php | 1 + htdocs/mrp/mo_production.php | 25 +++++++++---------- htdocs/product/stock/massstockmove.php | 4 +-- htdocs/theme/eldy/global.inc.php | 12 ++++++--- htdocs/theme/md/style.css.php | 9 ++++--- 9 files changed, 39 insertions(+), 32 deletions(-) diff --git a/htdocs/admin/mails_templates.php b/htdocs/admin/mails_templates.php index 3075bb2eb14..64908830b93 100644 --- a/htdocs/admin/mails_templates.php +++ b/htdocs/admin/mails_templates.php @@ -62,6 +62,7 @@ $massaction = GETPOST('massaction', 'alpha'); $confirm = GETPOST('confirm', 'alpha'); // Result of a confirmation $mode = GETPOST('mode', 'aZ09'); $optioncss = GETPOST('optioncss', 'alpha'); +$contextpage = GETPOST('contextpage', 'aZ09'); $id = $rowid = (GETPOSTINT('id') ? GETPOSTINT('id') : GETPOSTINT('rowid')); $search_label = GETPOST('search_label', 'alphanohtml'); // Must allow value like 'Abc Def' or '(MyTemplateName)' @@ -1231,8 +1232,7 @@ if ($num) { print ''.img_view().''; } if ($iserasable) { - print ''.img_delete().''; - //else print ''.img_delete().''; // Some dictionary can be edited by other profile than admin + print ''.img_delete().''; } print ''; } diff --git a/htdocs/comm/action/class/cactioncomm.class.php b/htdocs/comm/action/class/cactioncomm.class.php index 57d266226bd..8c2476b9739 100644 --- a/htdocs/comm/action/class/cactioncomm.class.php +++ b/htdocs/comm/action/class/cactioncomm.class.php @@ -308,24 +308,24 @@ class CActionComm if (($onlyautoornot == -1 || $onlyautoornot == -2) && getDolGlobalString('AGENDA_USE_EVENT_TYPE')) { // Add a group of elements if ($typecalendar == 'system' || $typecalendar == 'user') { - $label = '   '.$label; + //$label = '   '.$label; $TSystem['id'][-99] = $langs->trans("ActionAC_MANUAL"); - $TSystem['code']['AC_NON_AUTO'] = '-- '.$langs->trans("ActionAC_MANUAL").''; + $TSystem['code']['AC_NON_AUTO'] = '-- '.$langs->trans("ActionAC_MANUAL").''; } if ($typecalendar == 'systemauto') { - $label = '   '.$label; + //$label = '   '.$label; $TSystemAuto['id'][-98] = $langs->trans("ActionAC_AUTO"); - $TSystemAuto['code']['AC_ALL_AUTO'] = '-- '.$langs->trans("ActionAC_AUTO").''; + $TSystemAuto['code']['AC_ALL_AUTO'] = '-- '.$langs->trans("ActionAC_AUTO").''; } if ($typecalendar == 'module') { $module = preg_replace('/^[^@]+@/', '', $obj->module); - $label = '   '.$label; + //$label = '   '.$label; if (!isset($TModule['id'][-1 * $idforallfornewmodule])) { // If first time for this module $idforallfornewmodule--; } $TModule['id'][-1 * $idforallfornewmodule] = $langs->trans("ActionAC_ALL_".strtoupper($module)); - $TModule['code']['AC_ALL_'.strtoupper($module)] = '-- '.$langs->trans("Module").' '.ucfirst($module).''; + $TModule['code']['AC_ALL_'.strtoupper($module)] = '-- '.$langs->trans("Module").' '.ucfirst($module).''; } } // Add element diff --git a/htdocs/core/modules/modWebsite.class.php b/htdocs/core/modules/modWebsite.class.php index 262a5bbcd38..afd5a4291ff 100644 --- a/htdocs/core/modules/modWebsite.class.php +++ b/htdocs/core/modules/modWebsite.class.php @@ -160,7 +160,7 @@ class modWebsite extends DolibarrModules */ public function init($options = '') { - global $conf, $langs; + global $langs; $error = 0; diff --git a/htdocs/main.inc.php b/htdocs/main.inc.php index 256acfde763..0befd9431f7 100644 --- a/htdocs/main.inc.php +++ b/htdocs/main.inc.php @@ -630,7 +630,7 @@ if ((!defined('NOCSRFCHECK') && empty($dolibarr_nocsrfcheck) && getDolGlobalInt( $sensitiveget = false; if ((GETPOSTISSET('massaction') || GETPOST('action', 'aZ09')) && getDolGlobalInt('MAIN_SECURITY_CSRF_WITH_TOKEN') >= 3) { // All GET actions (except the listed exceptions that are usually post for pre-actions and not real action) and mass actions are processed as sensitive. - if (GETPOSTISSET('massaction') || !in_array(GETPOST('action', 'aZ09'), array('create', 'createsite', 'createcard', 'edit', 'editcontract', 'editvalidator', 'file_manager', 'presend', 'presend_addmessage', 'preview', 'reconcile', 'specimen'))) { // We exclude some action that are not sensitive so legitimate + if (GETPOSTISSET('massaction') || !in_array(GETPOST('action', 'aZ09'), array('create', 'create2', 'createsite', 'createcard', 'edit', 'editcontract', 'editvalidator', 'file_manager', 'presend', 'presend_addmessage', 'preview', 'reconcile', 'specimen'))) { // We exclude some action that are not sensitive so legitimate $sensitiveget = true; } } elseif (getDolGlobalInt('MAIN_SECURITY_CSRF_WITH_TOKEN') >= 2) { diff --git a/htdocs/mrp/mo_agenda.php b/htdocs/mrp/mo_agenda.php index 42efc3ef0f4..1e4cfed2937 100644 --- a/htdocs/mrp/mo_agenda.php +++ b/htdocs/mrp/mo_agenda.php @@ -45,6 +45,7 @@ $ref = GETPOST('ref', 'alpha'); $action = GETPOST('action', 'aZ09'); $cancel = GETPOST('cancel', 'aZ09'); $backtopage = GETPOST('backtopage', 'alpha'); +$contextpage = GETPOST('contextpage', 'aZ') ? GETPOST('contextpage', 'aZ') : 'moagenda'; // To manage different context of search if (GETPOST('actioncode', 'array')) { $actioncode = GETPOST('actioncode', 'array', 3); diff --git a/htdocs/mrp/mo_production.php b/htdocs/mrp/mo_production.php index 685ff1d1117..a3844a3b0e7 100644 --- a/htdocs/mrp/mo_production.php +++ b/htdocs/mrp/mo_production.php @@ -915,31 +915,30 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea print ''; // Product print ''; - print $form->select_produits('', 'productidtoadd', '', 0, 0, -1, 2, '', 1, array(), 0, '1', 0, 'maxwidth300'); + print $form->select_produits('', 'productidtoadd', '', 0, 0, -1, 2, '', 1, array(), 0, '1', 0, 'maxwidth150'); print ''; // Qty - print ''; + print ''; // Unit print ''; // Cost price if ($permissiontoupdatecost && getDolGlobalString('MRP_SHOW_COST_FOR_CONSUMPTION')) { print ''; } + + $colspan="3"; + if (isModEnabled('stock')) { + $colspan++;; + } + if (isModEnabled('productbatch')) { + $colspan++; + } // Qty already consumed + Warehouse - print ''; + print ''; print ''; print ''; print ''; - if (isModEnabled('stock')) { - print ''; - } - // Lot - serial - if (isModEnabled('productbatch')) { - print ''; - } - // Split - print ''; - // SplitAll + // Split All print ''; // Edit Line if ($object->status == Mo::STATUS_DRAFT) { diff --git a/htdocs/product/stock/massstockmove.php b/htdocs/product/stock/massstockmove.php index 463b39d5723..33c832e5bc5 100644 --- a/htdocs/product/stock/massstockmove.php +++ b/htdocs/product/stock/massstockmove.php @@ -567,7 +567,7 @@ print '
'; //print '
'; // Form to upload a file -print '
'; +print ''; print ''; print ''; if (!empty($conf->dol_optimize_smallscreen)) { @@ -660,7 +660,7 @@ print ''; print '
'; -print ''; +print '
'; $param = ''; diff --git a/htdocs/theme/eldy/global.inc.php b/htdocs/theme/eldy/global.inc.php index fa209693316..6a7ca1832e6 100644 --- a/htdocs/theme/eldy/global.inc.php +++ b/htdocs/theme/eldy/global.inc.php @@ -896,6 +896,10 @@ textarea.centpercent { .small, small { font-size: 85%; } +.smallincombo { + font-size: 95%; + font-weight: bold; +} .lineheightsmall { line-height: 1.2em; } @@ -7273,11 +7277,11 @@ select.multiselectononeline { @media only screen and (min-width: 768px) { /* CSS to have the dropdown boxes larger that the input search area */ - .select2-container.select2-container--open:not(.graphtype):not(.yesno) .select2-dropdown.ui-dialog { + .select2-container.select2-container--open:not(.graphtype, .limit, .combolargeelem):not(.yesno) .select2-dropdown.ui-dialog { min-width: 230px !important; } - .select2-container.select2-container--open:not(.graphtype):not(.yesno) .select2-dropdown--below:not(.onrightofpage), - .select2-container.select2-container--open:not(.graphtype):not(.yesno) .select2-dropdown--above:not(.onrightofpage) { + .select2-container.select2-container--open:not(.graphtype, .limit, .combolargeelem):not(.yesno) .select2-dropdown--below:not(.onrightofpage), + .select2-container.select2-container--open:not(.graphtype, .limit, .combolargeelem):not(.yesno) .select2-dropdown--above:not(.onrightofpage) { min-width: 230px !important; } .onrightofpage span.select2-dropdown.ui-dialog.select2-dropdown--below, @@ -7285,7 +7289,7 @@ select.multiselectononeline { min-width: 140px !important; } .combolargeelem.select2-container.select2-container--open .select2-dropdown.ui-dialog { - min-width: 300px !important; + min-width: 320px !important; } .select2-container--open .select2-dropdown--below { diff --git a/htdocs/theme/md/style.css.php b/htdocs/theme/md/style.css.php index 0a62153c512..7c174e4d531 100644 --- a/htdocs/theme/md/style.css.php +++ b/htdocs/theme/md/style.css.php @@ -7147,17 +7147,20 @@ select.multiselectononeline { @media only screen and (min-width: 767px) { /* CSS to have the dropdown boxes larger that the input search area */ - .select2-container.select2-container--open:not(.graphtype):not(.yesno) .select2-dropdown.ui-dialog { + .select2-container.select2-container--open:not(.graphtype, .limit, .combolargeelem):not(.yesno) .select2-dropdown.ui-dialog { min-width: 240px !important; } - .select2-container.select2-container--open:not(.graphtype):not(.yesno) .select2-dropdown--below:not(.onrightofpage), - .select2-container.select2-container--open:not(.graphtype):not(.yesno) .select2-dropdown--above:not(.onrightofpage) { + .select2-container.select2-container--open:not(.graphtype, .limit, .combolargeelem):not(.yesno) .select2-dropdown--below:not(.onrightofpage), + .select2-container.select2-container--open:not(.graphtype, .limit, .combolargeelem):not(.yesno) .select2-dropdown--above:not(.onrightofpage) { min-width: 240px !important; } .onrightofpage span.select2-dropdown.ui-dialog.select2-dropdown--below, .onrightofpage span.select2-dropdown.ui-dialog.select2-dropdown--above { min-width: 140px !important; } + .combolargeelem.select2-container.select2-container--open .select2-dropdown.ui-dialog { + min-width: 320px !important; + } .select2-container--open .select2-dropdown--below { border-top: 1px solid var(--inputbordercolor);