mirror of
https://github.com/Dolibarr/dolibarr.git
synced 2025-12-15 22:11:36 +01:00
Work on removal of jmobile
This commit is contained in:
@@ -45,7 +45,6 @@ jQuery jNotify 1.1.00 Apache Software License 2.0 Yes
|
|||||||
jQuery jPicker 1.1.6 GPL and MIT License Yes JS library for color picker with not defined list of colors
|
jQuery jPicker 1.1.6 GPL and MIT License Yes JS library for color picker with not defined list of colors
|
||||||
jQuery jqueryFileTree 1.0.1 GPL and MIT License Yes JS library for color picker with not defined list of colors
|
jQuery jqueryFileTree 1.0.1 GPL and MIT License Yes JS library for color picker with not defined list of colors
|
||||||
jQuery jquerytreeview 1.4.1 MIT License Yes JS library for color picker with not defined list of colors
|
jQuery jquerytreeview 1.4.1 MIT License Yes JS library for color picker with not defined list of colors
|
||||||
jQuery Mobile 1.3.0 GPL and MIT License Yes JS library for smartphone (not used)
|
|
||||||
jQuery TableDnD 0.6 GPL and MIT License Yes JS library plugin TableDnD (to reorder table rows)
|
jQuery TableDnD 0.6 GPL and MIT License Yes JS library plugin TableDnD (to reorder table rows)
|
||||||
jQuery Timepicker 1.1.0 GPL and MIT License Yes JS library Timepicker addon for Datepicker
|
jQuery Timepicker 1.1.0 GPL and MIT License Yes JS library Timepicker addon for Datepicker
|
||||||
jQuery Tiptip 1.3 GPL and MIT License Yes JS library for tooltips
|
jQuery Tiptip 1.3 GPL and MIT License Yes JS library for tooltips
|
||||||
|
|||||||
@@ -33,6 +33,18 @@ if (! defined('NOTOKENRENEWAL')) define('NOTOKENRENEWAL',1);
|
|||||||
if (! defined('NOREQUIREMENU')) define('NOREQUIREMENU',1);
|
if (! defined('NOREQUIREMENU')) define('NOREQUIREMENU',1);
|
||||||
if (! defined('NOREQUIREHTML')) define('NOREQUIREHTML',1);
|
if (! defined('NOREQUIREHTML')) define('NOREQUIREHTML',1);
|
||||||
|
|
||||||
|
if (! defined('DISABLE_JQUERY_TABLEDND')) define('DISABLE_JQUERY_TABLEDND',1);
|
||||||
|
if (! defined('DISABLE_JQUERY_TIPTIP')) define('DISABLE_JQUERY_TIPTIP',1);
|
||||||
|
if (! defined('DISABLE_JQUERY_JNOTIFY')) define('DISABLE_JQUERY_JNOTIFY',1);
|
||||||
|
if (! defined('DISABLE_JQUERY_FLOT')) define('DISABLE_JQUERY_FLOT',1);
|
||||||
|
if (! defined('DISABLE_JQUERY_JEDITABLE')) define('DISABLE_JQUERY_JEDITABLE',1);
|
||||||
|
if (! defined('DISABLE_JQUERY_JEDITABLE')) define('DISABLE_JQUERY_JEDITABLE',1);
|
||||||
|
if (! defined('DISABLE_CKEDITOR')) define('DISABLE_CKEDITOR',1);
|
||||||
|
if (! defined('DISABLE_CKEDITOR')) define('DISABLE_CKEDITOR',1);
|
||||||
|
if (! defined('DISABLE_BROWSER_NOTIF')) define('DISABLE_BROWSER_NOTIF',1);
|
||||||
|
if (! defined('DISABLE_DATE_PICKER')) define('DISABLE_DATE_PICKER',1);
|
||||||
|
if (! defined('DISABLE_SELECT2')) define('DISABLE_SELECT2',1);
|
||||||
|
|
||||||
require_once '../main.inc.php';
|
require_once '../main.inc.php';
|
||||||
|
|
||||||
if (GETPOST('lang')) $langs->setDefaultLang(GETPOST('lang')); // If language was forced on URL by the main.inc.php
|
if (GETPOST('lang')) $langs->setDefaultLang(GETPOST('lang')); // If language was forced on URL by the main.inc.php
|
||||||
@@ -55,6 +67,89 @@ top_htmlhead($head, $title, 0, 0, $arrayofjs, $arrayofcss);
|
|||||||
|
|
||||||
print '<body>'."\n";
|
print '<body>'."\n";
|
||||||
|
|
||||||
|
// Javascript to make menu active like Jmobile did.
|
||||||
|
print '
|
||||||
|
<style>
|
||||||
|
/*Lets hide the non active LIs by default*/
|
||||||
|
body {
|
||||||
|
font-size: 16px;
|
||||||
|
}
|
||||||
|
body ul {
|
||||||
|
margin: 0;
|
||||||
|
padding-left: 0;
|
||||||
|
}
|
||||||
|
body ul li {
|
||||||
|
list-style: none;
|
||||||
|
}
|
||||||
|
body ul ul {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
a.alilevel0 {
|
||||||
|
background-image: url(\''.DOL_URL_ROOT.'/theme/'.$conf->theme.'/img/next.png\') !important;
|
||||||
|
background-repeat: no-repeat !important;
|
||||||
|
background-position-x: 10px;
|
||||||
|
background-position-y: 16px;
|
||||||
|
padding: 1em 15px 1em 40px;
|
||||||
|
}
|
||||||
|
li.lilevel1 {
|
||||||
|
padding: 1em 15px 0.5em 20px;
|
||||||
|
border-top: 1px solid #ccc;
|
||||||
|
margin-right: 20px;
|
||||||
|
border-right: 0px ! important;
|
||||||
|
}
|
||||||
|
li.lilevel1 a {
|
||||||
|
padding-bottom: 5px;
|
||||||
|
}
|
||||||
|
li.lilevel1 a, li.lilevel1 {
|
||||||
|
color: #000;
|
||||||
|
cursor: pointer;
|
||||||
|
display: block;
|
||||||
|
}
|
||||||
|
li.lilevel2 a {
|
||||||
|
padding: 0 15px 0.5em 40px;
|
||||||
|
color: #000;
|
||||||
|
cursor: pointer;
|
||||||
|
display: block;
|
||||||
|
}
|
||||||
|
li.lilevel3 a {
|
||||||
|
padding: 0.2em 15px 8px 60px;
|
||||||
|
color: #000;
|
||||||
|
cursor: pointer;
|
||||||
|
display: block;
|
||||||
|
}
|
||||||
|
li.lilevel3:last-child {
|
||||||
|
padding-bottom: 10px;
|
||||||
|
}
|
||||||
|
a.alilevel0, li.lilevel1 a {
|
||||||
|
text-overflow: ellipsis;
|
||||||
|
overflow: hidden;
|
||||||
|
white-space: nowrap;
|
||||||
|
display: block;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
|
|
||||||
|
<script type="text/javascript">
|
||||||
|
/*jQuery time*/
|
||||||
|
$(document).ready(function(){
|
||||||
|
$("body ul").click(function(){
|
||||||
|
console.log("We click on body ul");
|
||||||
|
|
||||||
|
$(this).siblings().find("li ul").slideUp(0);
|
||||||
|
//slide up all the link lists
|
||||||
|
$(this).find("li ul").slideToggle(200);
|
||||||
|
|
||||||
|
target = $(this);
|
||||||
|
$(\'html, body\').animate({
|
||||||
|
scrollTop: target.offset().top
|
||||||
|
}, 300);
|
||||||
|
|
||||||
|
})
|
||||||
|
});
|
||||||
|
</script>
|
||||||
|
';
|
||||||
|
|
||||||
|
|
||||||
if (empty($user->societe_id)) // If internal user or not defined
|
if (empty($user->societe_id)) // If internal user or not defined
|
||||||
{
|
{
|
||||||
$conf->standard_menu=(empty($conf->global->MAIN_MENU_STANDARD_FORCED)?(empty($conf->global->MAIN_MENU_STANDARD)?'eldy_menu.php':$conf->global->MAIN_MENU_STANDARD):$conf->global->MAIN_MENU_STANDARD_FORCED);
|
$conf->standard_menu=(empty($conf->global->MAIN_MENU_STANDARD_FORCED)?(empty($conf->global->MAIN_MENU_STANDARD)?'eldy_menu.php':$conf->global->MAIN_MENU_STANDARD):$conf->global->MAIN_MENU_STANDARD_FORCED);
|
||||||
|
|||||||
@@ -28,7 +28,8 @@ if (!defined('NOREQUIREHTML')) define('NOREQUIREHTML', 1);
|
|||||||
|
|
||||||
require_once '../../main.inc.php';
|
require_once '../../main.inc.php';
|
||||||
|
|
||||||
if (!($_SERVER['HTTP_REFERER'] === $dolibarr_main_url_root . '/' || $_SERVER['HTTP_REFERER'] === $dolibarr_main_url_root . '/index.php'))
|
if (! ($_SERVER['HTTP_REFERER'] === $dolibarr_main_url_root . '/' || $_SERVER['HTTP_REFERER'] === $dolibarr_main_url_root . '/index.php'
|
||||||
|
|| preg_match('/getmenu_div\.php/', $_SERVER['HTTP_REFERER'])))
|
||||||
{
|
{
|
||||||
global $langs, $conf;
|
global $langs, $conf;
|
||||||
|
|
||||||
|
|||||||
Binary file not shown.
|
Before Width: | Height: | Size: 7.6 KiB |
Binary file not shown.
|
Before Width: | Height: | Size: 1.9 KiB |
Binary file not shown.
|
Before Width: | Height: | Size: 1.9 KiB |
Binary file not shown.
|
Before Width: | Height: | Size: 3.8 KiB |
Binary file not shown.
|
Before Width: | Height: | Size: 3.8 KiB |
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@@ -986,13 +986,13 @@ function top_httphead()
|
|||||||
* Ouput html header of a page.
|
* Ouput html header of a page.
|
||||||
* This code is also duplicated into security2.lib.php::dol_loginfunction
|
* This code is also duplicated into security2.lib.php::dol_loginfunction
|
||||||
*
|
*
|
||||||
* @param string $head Optionnal head lines
|
* @param string $head Optionnal head lines
|
||||||
* @param string $title HTML title
|
* @param string $title HTML title
|
||||||
* @param int $disablejs Disable js output
|
* @param int $disablejs Disable js output
|
||||||
* @param int $disablehead Disable head output
|
* @param int $disablehead Disable head output
|
||||||
* @param array $arrayofjs Array of complementary js files
|
* @param array $arrayofjs Array of complementary js files
|
||||||
* @param array $arrayofcss Array of complementary css files
|
* @param array $arrayofcss Array of complementary css files
|
||||||
* @param int $disablejmobile Disable jmobile
|
* @param int $disablejmobile Disable jmobile (No more used)
|
||||||
* @param int $disablenofollow Disable no follow tag
|
* @param int $disablenofollow Disable no follow tag
|
||||||
* @return void
|
* @return void
|
||||||
*/
|
*/
|
||||||
@@ -1059,8 +1059,8 @@ function top_htmlhead($head, $title='', $disablejs=0, $disablehead=0, $arrayofjs
|
|||||||
if (!empty($conf->global->MAIN_USE_JQUERY_THEME)) $jquerytheme = $conf->global->MAIN_USE_JQUERY_THEME;
|
if (!empty($conf->global->MAIN_USE_JQUERY_THEME)) $jquerytheme = $conf->global->MAIN_USE_JQUERY_THEME;
|
||||||
if (constant('JS_JQUERY_UI')) print '<link rel="stylesheet" type="text/css" href="'.JS_JQUERY_UI.'css/'.$jquerytheme.'/jquery-ui.min.css'.($ext?'?'.$ext:'').'">'."\n"; // JQuery
|
if (constant('JS_JQUERY_UI')) print '<link rel="stylesheet" type="text/css" href="'.JS_JQUERY_UI.'css/'.$jquerytheme.'/jquery-ui.min.css'.($ext?'?'.$ext:'').'">'."\n"; // JQuery
|
||||||
else print '<link rel="stylesheet" type="text/css" href="'.DOL_URL_ROOT.'/includes/jquery/css/'.$jquerytheme.'/jquery-ui.css'.($ext?'?'.$ext:'').'">'."\n"; // JQuery
|
else print '<link rel="stylesheet" type="text/css" href="'.DOL_URL_ROOT.'/includes/jquery/css/'.$jquerytheme.'/jquery-ui.css'.($ext?'?'.$ext:'').'">'."\n"; // JQuery
|
||||||
print '<link rel="stylesheet" type="text/css" href="'.DOL_URL_ROOT.'/includes/jquery/plugins/tiptip/tipTip.css'.($ext?'?'.$ext:'').'">'."\n"; // Tooltip
|
if (! defined('DISABLE_JQUERY_TIPTIP')) print '<link rel="stylesheet" type="text/css" href="'.DOL_URL_ROOT.'/includes/jquery/plugins/tiptip/tipTip.css'.($ext?'?'.$ext:'').'">'."\n"; // Tooltip
|
||||||
print '<link rel="stylesheet" type="text/css" href="'.DOL_URL_ROOT.'/includes/jquery/plugins/jnotify/jquery.jnotify-alt.min.css'.($ext?'?'.$ext:'').'">'."\n"; // JNotify
|
if (! defined('DISABLE_JQUERY_JNOTIFY')) print '<link rel="stylesheet" type="text/css" href="'.DOL_URL_ROOT.'/includes/jquery/plugins/jnotify/jquery.jnotify-alt.min.css'.($ext?'?'.$ext:'').'">'."\n"; // JNotify
|
||||||
/* Removed a old hidden problematic feature never used in Dolibarr. If an external module need datatable, the module must provide all lib it needs and manage version problems with other dolibarr components
|
/* Removed a old hidden problematic feature never used in Dolibarr. If an external module need datatable, the module must provide all lib it needs and manage version problems with other dolibarr components
|
||||||
if (! empty($conf->global->MAIN_USE_JQUERY_DATATABLES) || (defined('REQUIRE_JQUERY_DATATABLES') && constant('REQUIRE_JQUERY_DATATABLES'))) // jQuery datatables
|
if (! empty($conf->global->MAIN_USE_JQUERY_DATATABLES) || (defined('REQUIRE_JQUERY_DATATABLES') && constant('REQUIRE_JQUERY_DATATABLES'))) // jQuery datatables
|
||||||
{
|
{
|
||||||
@@ -1068,7 +1068,7 @@ function top_htmlhead($head, $title='', $disablejs=0, $disablehead=0, $arrayofjs
|
|||||||
print '<link rel="stylesheet" type="text/css" href="'.DOL_URL_ROOT.'/includes/jquery/plugins/datatables/extensions/Buttons/css/buttons.dataTables.min.css'.($ext?'?'.$ext:'').'">'."\n";
|
print '<link rel="stylesheet" type="text/css" href="'.DOL_URL_ROOT.'/includes/jquery/plugins/datatables/extensions/Buttons/css/buttons.dataTables.min.css'.($ext?'?'.$ext:'').'">'."\n";
|
||||||
print '<link rel="stylesheet" type="text/css" href="'.DOL_URL_ROOT.'/includes/jquery/plugins/datatables/extensions/ColReorder/css/colReorder.dataTables.min.css'.($ext?'?'.$ext:'').'"></script>'."\n";
|
print '<link rel="stylesheet" type="text/css" href="'.DOL_URL_ROOT.'/includes/jquery/plugins/datatables/extensions/ColReorder/css/colReorder.dataTables.min.css'.($ext?'?'.$ext:'').'"></script>'."\n";
|
||||||
}*/
|
}*/
|
||||||
if (! empty($conf->global->MAIN_USE_JQUERY_MULTISELECT) || defined('REQUIRE_JQUERY_MULTISELECT')) // jQuery plugin "mutiselect", "multiple-select", "select2"...
|
if (! defined('DISABLE_SELECT2') && (! empty($conf->global->MAIN_USE_JQUERY_MULTISELECT) || defined('REQUIRE_JQUERY_MULTISELECT'))) // jQuery plugin "mutiselect", "multiple-select", "select2"...
|
||||||
{
|
{
|
||||||
$tmpplugin=empty($conf->global->MAIN_USE_JQUERY_MULTISELECT)?constant('REQUIRE_JQUERY_MULTISELECT'):$conf->global->MAIN_USE_JQUERY_MULTISELECT;
|
$tmpplugin=empty($conf->global->MAIN_USE_JQUERY_MULTISELECT)?constant('REQUIRE_JQUERY_MULTISELECT'):$conf->global->MAIN_USE_JQUERY_MULTISELECT;
|
||||||
print '<link rel="stylesheet" type="text/css" href="'.DOL_URL_ROOT.'/includes/jquery/plugins/'.$tmpplugin.'/'.$tmpplugin.'.css'.($ext?'?'.$ext:'').'">'."\n";
|
print '<link rel="stylesheet" type="text/css" href="'.DOL_URL_ROOT.'/includes/jquery/plugins/'.$tmpplugin.'/'.$tmpplugin.'.css'.($ext?'?'.$ext:'').'">'."\n";
|
||||||
@@ -1078,15 +1078,6 @@ function top_htmlhead($head, $title='', $disablejs=0, $disablehead=0, $arrayofjs
|
|||||||
{
|
{
|
||||||
print '<link rel="stylesheet" type="text/css" href="'.DOL_URL_ROOT.'/includes/jquery/plugins/timepicker/jquery-ui-timepicker-addon.css'.($ext?'?'.$ext:'').'">'."\n";
|
print '<link rel="stylesheet" type="text/css" href="'.DOL_URL_ROOT.'/includes/jquery/plugins/timepicker/jquery-ui-timepicker-addon.css'.($ext?'?'.$ext:'').'">'."\n";
|
||||||
}
|
}
|
||||||
// jQuery jMobile
|
|
||||||
if (! $disablejmobile && (! empty($conf->global->MAIN_USE_JQUERY_JMOBILE) || defined('REQUIRE_JQUERY_JMOBILE') || ! empty($conf->dol_use_jmobile)))
|
|
||||||
{
|
|
||||||
$tmp=basename($_SERVER["PHP_SELF"]);
|
|
||||||
if ($tmp == 'get_menudiv.php' || $conf->dol_use_jmobile == 4)
|
|
||||||
{
|
|
||||||
print '<link rel="stylesheet" type="text/css" href="'.DOL_URL_ROOT.'/includes/jquery/plugins/mobile/jquery.mobile-latest.min.css'.($ext?'?'.$ext:'').'">'."\n";
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
print '<!-- Includes CSS for Dolibarr theme -->'."\n";
|
print '<!-- Includes CSS for Dolibarr theme -->'."\n";
|
||||||
@@ -1149,8 +1140,8 @@ function top_htmlhead($head, $title='', $disablejs=0, $disablehead=0, $arrayofjs
|
|||||||
else print '<script type="text/javascript" src="'.DOL_URL_ROOT.'/includes/jquery/js/jquery.min.js'.($ext?'?'.$ext:'').'"></script>'."\n";
|
else print '<script type="text/javascript" src="'.DOL_URL_ROOT.'/includes/jquery/js/jquery.min.js'.($ext?'?'.$ext:'').'"></script>'."\n";
|
||||||
if (constant('JS_JQUERY_UI')) print '<script type="text/javascript" src="'.JS_JQUERY_UI.'jquery-ui.min.js'.($ext?'?'.$ext:'').'"></script>'."\n";
|
if (constant('JS_JQUERY_UI')) print '<script type="text/javascript" src="'.JS_JQUERY_UI.'jquery-ui.min.js'.($ext?'?'.$ext:'').'"></script>'."\n";
|
||||||
else print '<script type="text/javascript" src="'.DOL_URL_ROOT.'/includes/jquery/js/jquery-ui.min.js'.($ext?'?'.$ext:'').'"></script>'."\n";
|
else print '<script type="text/javascript" src="'.DOL_URL_ROOT.'/includes/jquery/js/jquery-ui.min.js'.($ext?'?'.$ext:'').'"></script>'."\n";
|
||||||
print '<script type="text/javascript" src="'.DOL_URL_ROOT.'/includes/jquery/plugins/tablednd/jquery.tablednd.0.6.min.js'.($ext?'?'.$ext:'').'"></script>'."\n";
|
if (! defined('DISABLE_JQUERY_TABLEDND')) print '<script type="text/javascript" src="'.DOL_URL_ROOT.'/includes/jquery/plugins/tablednd/jquery.tablednd.0.6.min.js'.($ext?'?'.$ext:'').'"></script>'."\n";
|
||||||
print '<script type="text/javascript" src="'.DOL_URL_ROOT.'/includes/jquery/plugins/tiptip/jquery.tipTip.min.js'.($ext?'?'.$ext:'').'"></script>'."\n";
|
if (! defined('DISABLE_JQUERY_TIPTIP')) print '<script type="text/javascript" src="'.DOL_URL_ROOT.'/includes/jquery/plugins/tiptip/jquery.tipTip.min.js'.($ext?'?'.$ext:'').'"></script>'."\n";
|
||||||
// jQuery jnotify
|
// jQuery jnotify
|
||||||
if (empty($conf->global->MAIN_DISABLE_JQUERY_JNOTIFY) && ! defined('DISABLE_JQUERY_JNOTIFY'))
|
if (empty($conf->global->MAIN_DISABLE_JQUERY_JNOTIFY) && ! defined('DISABLE_JQUERY_JNOTIFY'))
|
||||||
{
|
{
|
||||||
@@ -1167,7 +1158,7 @@ function top_htmlhead($head, $title='', $disablejs=0, $disablehead=0, $arrayofjs
|
|||||||
print '<script type="text/javascript" src="'.DOL_URL_ROOT.'/core/js/blockUI.js'.($ext?'?'.$ext:'').'"></script>'."\n";
|
print '<script type="text/javascript" src="'.DOL_URL_ROOT.'/core/js/blockUI.js'.($ext?'?'.$ext:'').'"></script>'."\n";
|
||||||
}
|
}
|
||||||
// Flot
|
// Flot
|
||||||
if (empty($conf->global->MAIN_DISABLE_JQUERY_FLOT))
|
if (empty($conf->global->MAIN_DISABLE_JQUERY_FLOT) && ! defined('DISABLE_JQUERY_FLOT'))
|
||||||
{
|
{
|
||||||
if (constant('JS_JQUERY_FLOT'))
|
if (constant('JS_JQUERY_FLOT'))
|
||||||
{
|
{
|
||||||
@@ -1183,7 +1174,7 @@ function top_htmlhead($head, $title='', $disablejs=0, $disablehead=0, $arrayofjs
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
// jQuery jeditable
|
// jQuery jeditable
|
||||||
if (! empty($conf->global->MAIN_USE_JQUERY_JEDITABLE))
|
if (! empty($conf->global->MAIN_USE_JQUERY_JEDITABLE) && ! defined('DISABLE_JQUERY_JEDITABLE'))
|
||||||
{
|
{
|
||||||
print '<!-- JS to manage editInPlace feature -->'."\n";
|
print '<!-- JS to manage editInPlace feature -->'."\n";
|
||||||
print '<script type="text/javascript" src="'.DOL_URL_ROOT.'/includes/jquery/plugins/jeditable/jquery.jeditable.min.js'.($ext?'?'.$ext:'').'"></script>'."\n";
|
print '<script type="text/javascript" src="'.DOL_URL_ROOT.'/includes/jquery/plugins/jeditable/jquery.jeditable.min.js'.($ext?'?'.$ext:'').'"></script>'."\n";
|
||||||
@@ -1234,55 +1225,18 @@ function top_htmlhead($head, $title='', $disablejs=0, $disablehead=0, $arrayofjs
|
|||||||
print '<script type="text/javascript" src="'.DOL_URL_ROOT.'/includes/jquery/plugins/timepicker/jquery-ui-timepicker-addon.js'.($ext?'?'.$ext:'').'"></script>'."\n";
|
print '<script type="text/javascript" src="'.DOL_URL_ROOT.'/includes/jquery/plugins/timepicker/jquery-ui-timepicker-addon.js'.($ext?'?'.$ext:'').'"></script>'."\n";
|
||||||
print '<script type="text/javascript" src="'.DOL_URL_ROOT.'/core/js/timepicker.js.php?lang='.$langs->defaultlang.($ext?'&'.$ext:'').'"></script>'."\n";
|
print '<script type="text/javascript" src="'.DOL_URL_ROOT.'/core/js/timepicker.js.php?lang='.$langs->defaultlang.($ext?'&'.$ext:'').'"></script>'."\n";
|
||||||
}
|
}
|
||||||
if (! empty($conf->global->MAIN_USE_JQUERY_MULTISELECT) || defined('REQUIRE_JQUERY_MULTISELECT')) // jQuery plugin "mutiselect", "multiple-select", "select2", ...
|
if (! defined('DISABLE_SELECT2') && (! empty($conf->global->MAIN_USE_JQUERY_MULTISELECT) || defined('REQUIRE_JQUERY_MULTISELECT'))) // jQuery plugin "mutiselect", "multiple-select", "select2", ...
|
||||||
{
|
{
|
||||||
$tmpplugin=empty($conf->global->MAIN_USE_JQUERY_MULTISELECT)?constant('REQUIRE_JQUERY_MULTISELECT'):$conf->global->MAIN_USE_JQUERY_MULTISELECT;
|
$tmpplugin=empty($conf->global->MAIN_USE_JQUERY_MULTISELECT)?constant('REQUIRE_JQUERY_MULTISELECT'):$conf->global->MAIN_USE_JQUERY_MULTISELECT;
|
||||||
print '<script type="text/javascript" src="'.DOL_URL_ROOT.'/includes/jquery/plugins/'.$tmpplugin.'/'.$tmpplugin.'.min.js'.($ext?'?'.$ext:'').'"></script>'."\n";
|
print '<script type="text/javascript" src="'.DOL_URL_ROOT.'/includes/jquery/plugins/'.$tmpplugin.'/'.$tmpplugin.'.min.js'.($ext?'?'.$ext:'').'"></script>'."\n";
|
||||||
print '<script type="text/javascript" src="'.DOL_URL_ROOT.'/core/js/select2_locale.js.php?lang='.$langs->defaultlang.($ext?'&'.$ext:'').'"></script>'."\n";
|
print '<script type="text/javascript" src="'.DOL_URL_ROOT.'/core/js/select2_locale.js.php?lang='.$langs->defaultlang.($ext?'&'.$ext:'').'"></script>'."\n";
|
||||||
}
|
}
|
||||||
// jQuery jMobile
|
|
||||||
if (! $disablejmobile && (! empty($conf->global->MAIN_USE_JQUERY_JMOBILE) || defined('REQUIRE_JQUERY_JMOBILE') || (! empty($conf->dol_use_jmobile) && $conf->dol_use_jmobile > 0)))
|
|
||||||
{
|
|
||||||
// We must force not using ajax because cache of jquery does not load js of other pages.
|
|
||||||
// This also increase seriously speed onto mobile device where complex js code is very slow and memory very low.
|
|
||||||
// Note: dol_use_jmobile=1 use jmobile without ajax, dol_use_jmobile=2 use jmobile with ajax
|
|
||||||
// 3=???
|
|
||||||
// 4=all pages, not only menu
|
|
||||||
$tmp=basename($_SERVER["PHP_SELF"]);
|
|
||||||
if ($tmp == 'get_menudiv.php' || $conf->dol_use_jmobile == 4)
|
|
||||||
{
|
|
||||||
if (empty($conf->dol_use_jmobile) || ($conf->dol_use_jmobile != 2 && $conf->dol_use_jmobile != 3))
|
|
||||||
{
|
|
||||||
print '<script type="text/javascript">
|
|
||||||
$(document).bind("mobileinit", function() {
|
|
||||||
';
|
|
||||||
if ($conf->theme == 'md')
|
|
||||||
{
|
|
||||||
// Disabled decoration for some css
|
|
||||||
print '
|
|
||||||
$.mobile.keepNative = \'input[type="submit"]\';
|
|
||||||
';
|
|
||||||
}
|
|
||||||
print '
|
|
||||||
$.extend( $.mobile , {
|
|
||||||
autoInitializePage : true,
|
|
||||||
touchOverflowEnabled : true,
|
|
||||||
defaultPageTransition : \'none\',
|
|
||||||
defaultDialogTransition : \'none\',
|
|
||||||
ajaxEnabled : false
|
|
||||||
});
|
|
||||||
});
|
|
||||||
</script>';
|
|
||||||
}
|
|
||||||
if (empty($conf->dol_use_jmobile) || $conf->dol_use_jmobile != 3) print '<script type="text/javascript" src="'.DOL_URL_ROOT.'/includes/jquery/plugins/mobile/jquery.mobile-latest.min.js'.($ext?'?'.$ext:'').'"></script>'."\n";
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if (! $disablejs && ! empty($conf->use_javascript_ajax))
|
if (! $disablejs && ! empty($conf->use_javascript_ajax))
|
||||||
{
|
{
|
||||||
// CKEditor
|
// CKEditor
|
||||||
if (! empty($conf->fckeditor->enabled) && (empty($conf->global->FCKEDITOR_EDITORNAME) || $conf->global->FCKEDITOR_EDITORNAME == 'ckeditor'))
|
if (! empty($conf->fckeditor->enabled) && (empty($conf->global->FCKEDITOR_EDITORNAME) || $conf->global->FCKEDITOR_EDITORNAME == 'ckeditor') && ! defined('DISABLE_CKEDITOR'))
|
||||||
{
|
{
|
||||||
print '<!-- Includes JS for CKEditor -->'."\n";
|
print '<!-- Includes JS for CKEditor -->'."\n";
|
||||||
$pathckeditor = DOL_URL_ROOT . '/includes/ckeditor/ckeditor/';
|
$pathckeditor = DOL_URL_ROOT . '/includes/ckeditor/ckeditor/';
|
||||||
@@ -1301,12 +1255,15 @@ function top_htmlhead($head, $title='', $disablejs=0, $disablehead=0, $arrayofjs
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Browser notifications
|
// Browser notifications
|
||||||
$enablebrowsernotif=false;
|
if (! defined('DISABLE_BROWSER_NOTIF'))
|
||||||
if (! empty($conf->agenda->enabled) && ! empty($conf->global->AGENDA_NOTIFICATION)) $enablebrowsernotif=true;
|
|
||||||
if ($enablebrowsernotif)
|
|
||||||
{
|
{
|
||||||
print '<!-- Includes JS of Dolibarr -->'."\n";
|
$enablebrowsernotif=false;
|
||||||
print '<script type="text/javascript" src="'.DOL_URL_ROOT.'/core/js/lib_notification.js.php?version='.urlencode(DOL_VERSION).($ext?'&'.$ext:'').'"></script>'."\n";
|
if (! empty($conf->agenda->enabled) && ! empty($conf->global->AGENDA_NOTIFICATION)) $enablebrowsernotif=true;
|
||||||
|
if ($enablebrowsernotif)
|
||||||
|
{
|
||||||
|
print '<!-- Includes JS of Dolibarr -->'."\n";
|
||||||
|
print '<script type="text/javascript" src="'.DOL_URL_ROOT.'/core/js/lib_notification.js.php?version='.urlencode(DOL_VERSION).($ext?'&'.$ext:'').'"></script>'."\n";
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// Global js function
|
// Global js function
|
||||||
@@ -1314,8 +1271,11 @@ function top_htmlhead($head, $title='', $disablejs=0, $disablehead=0, $arrayofjs
|
|||||||
print '<script type="text/javascript" src="'.DOL_URL_ROOT.'/core/js/lib_head.js.php'.($ext?'?'.$ext:'').'"></script>'."\n";
|
print '<script type="text/javascript" src="'.DOL_URL_ROOT.'/core/js/lib_head.js.php'.($ext?'?'.$ext:'').'"></script>'."\n";
|
||||||
|
|
||||||
// Add datepicker default options
|
// Add datepicker default options
|
||||||
print '<script type="text/javascript" src="'.DOL_URL_ROOT.'/core/js/datepicker.js.php'.($ext?'?'.$ext:'').'"></script>'."\n";
|
if (! defined('DISABLE_DATE_PICKER'))
|
||||||
|
{
|
||||||
|
print '<script type="text/javascript" src="'.DOL_URL_ROOT.'/core/js/datepicker.js.php'.($ext?'?'.$ext:'').'"></script>'."\n";
|
||||||
|
}
|
||||||
|
|
||||||
// JS forced by modules (relative url starting with /)
|
// JS forced by modules (relative url starting with /)
|
||||||
if (! empty($conf->modules_parts['js'])) // $conf->modules_parts['js'] is array('module'=>array('file1','file2'))
|
if (! empty($conf->modules_parts['js'])) // $conf->modules_parts['js'] is array('module'=>array('file1','file2'))
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -4253,7 +4253,7 @@ ul.ulmenu {
|
|||||||
}
|
}
|
||||||
.ulmenu {
|
.ulmenu {
|
||||||
box-shadow: none !important;
|
box-shadow: none !important;
|
||||||
border-bottom: 1px solid #444;
|
border-bottom: 1px solid #ccc;
|
||||||
}
|
}
|
||||||
.ui-btn-icon-right {
|
.ui-btn-icon-right {
|
||||||
border-right: 1px solid #ccc !important;
|
border-right: 1px solid #ccc !important;
|
||||||
|
|||||||
@@ -4152,7 +4152,7 @@ ul.ulmenu {
|
|||||||
}
|
}
|
||||||
.ulmenu {
|
.ulmenu {
|
||||||
box-shadow: none !important;
|
box-shadow: none !important;
|
||||||
border-bottom: 1px solid #444;
|
border-bottom: 1px solid #ccc;
|
||||||
}
|
}
|
||||||
.ui-btn-icon-right {
|
.ui-btn-icon-right {
|
||||||
border-right: 1px solid #ccc !important;
|
border-right: 1px solid #ccc !important;
|
||||||
|
|||||||
Reference in New Issue
Block a user