diff --git a/htdocs/public/demo/index.php b/htdocs/public/demo/index.php index ec32ee9978d..af18a72b881 100644 --- a/htdocs/public/demo/index.php +++ b/htdocs/public/demo/index.php @@ -69,11 +69,6 @@ $parameters=array(); $object=(object) 'nothing'; $reshook=$hookmanager->executeHooks('addDemoProfile', $parameters, $object, $tmpaction); // Note that $action and $object may have been modified by some hooks $error=$hookmanager->error; $errors=$hookmanager->errors; -/* -$demoprofiles[]=array('default'=>'0', 'key'=>'profdemomed', 'lang'=>'cabinetmed@cabinetmed', 'label'=>'DemoCabinetMed', 'url'=>'http://demodolimed.dolibarr.org', - 'disablemodules'=>'adherent,boutique,don,externalsite', - 'icon'=>DOL_URL_ROOT.'/public/demo/dolibarr_screenshot6.png'); -*/ $alwayscheckedmodules=array('barcode','bookmark','externalrss','fckeditor','geoipmaxmind','gravatar','memcached','syslog','user','webservices'); // Technical module we always want $alwaysuncheckedmodules=array('paybox','paypal','google','scanner','workflow'); // Module we never want @@ -242,16 +237,21 @@ jQuery(document).ready(function () { jQuery('tr.moduleline').hide(); // Enable this to allow personalized setup jQuery('.modulelineshow').attr('href','#'); + jQuery('.cursorpointer').css('cursor','pointer'); jQuery(".modulelineshow").click(function() { - var currentId = $(this).attr('id').substring(2); - jQuery('tr.moduleline').hide(); - if (currentId != openedId) + var idstring=$(this).attr('id'); + if (typeof idstring != "undefined") { - openedId=currentId; - jQuery("#tr1"+currentId).show(); - jQuery("#tr2"+currentId).show(); + var currentId = idstring.substring(2); + jQuery('tr.moduleline').hide(); + if (currentId != openedId) + { + openedId=currentId; + jQuery("#tr1"+currentId).show(); + jQuery("#tr2"+currentId).show(); + } + else openedId = ''; } - else openedId = ''; }); }); @@ -302,8 +302,8 @@ foreach ($demoprofiles as $profilearray) print '
| '.$langs->trans($profilearray['label']).' | '; + print ''.$langs->trans($profilearray['label']).' | '; print '||
| '; print ' | |||
| '; -print ''; -print ' ">'; -print ' |