Better center of left, center and right part of titles.

This commit is contained in:
Laurent Destailleur
2016-09-20 12:51:09 +02:00
parent ead3990171
commit 79ddc2458d
5 changed files with 17 additions and 10 deletions

View File

@@ -104,7 +104,7 @@ function dol_print_cron_urls()
print '<u>'.$langs->trans("FileToLaunchCronJobs").':</u><br>';
$file='/scripts/cron/cron_run_jobs.php'.' '.(empty($conf->global->CRON_KEY)?'securitykey':''.$conf->global->CRON_KEY.'').' '.$user->login.' [cronjobid]';
print '<textarea rows="'.ROWS_2.'" cols="120">..'.$file."</textarea><br>\n";
print '<textarea class="quatrevingtpercent">..'.$file."</textarea><br>\n";
print '<br>';
// Add note
@@ -116,7 +116,7 @@ function dol_print_cron_urls()
{
print $langs->trans("CronExplainHowToRunUnix");
print '<br>';
print '<textarea rows="'.ROWS_1.'" style="width:80%">*/5 * * * * pathtoscript/scripts/cron/cron_run_jobs.php '.(empty($conf->global->CRON_KEY)?'securitykey':''.$conf->global->CRON_KEY.'').' '.$user->login.' &gt; '.DOL_DATA_ROOT.'/cron_run_jobs.php.log</textarea><br>';
print '<textarea class="quatrevingtpercent">*/5 * * * * pathtoscript/scripts/cron/cron_run_jobs.php '.(empty($conf->global->CRON_KEY)?'securitykey':''.$conf->global->CRON_KEY.'').' '.$user->login.' &gt; '.DOL_DATA_ROOT.'/cron_run_jobs.php.log</textarea><br>';
}
else
{

View File

@@ -3117,19 +3117,21 @@ function print_barre_liste($titre, $page, $file, $options='', $sortfield='', $so
print '<table width="100%" border="0" class="notopnoleftnoright'.($morecss?' '.$morecss:'').'" style="margin-bottom: 6px;"><tr>';
// Left
if ($picto && $titre) print '<td class="nobordernopadding hideonsmartphone" width="40" align="left" valign="middle">'.img_picto('', $picto, 'id="pictotitle"', $pictoisfullpath).'</td>';
print '<td class="nobordernopadding"><div class="titre">'.$titre;
//if ($picto && $titre) print '<td class="nobordernopadding hideonsmartphone" width="40" align="left" valign="middle">'.img_picto('', $picto, 'id="pictotitle"', $pictoisfullpath).'</td>';
print '<td class="nobordernopadding" style="width: 35%" valign="middle">';
if ($picto && $titre) print img_picto('', $picto, 'class="hideonsmartphone valignmiddle" id="pictotitle"', $pictoisfullpath);
print '<div class="titre inline-block">'.$titre;
if (!empty($titre) && $savtotalnboflines > 0) print ' ('.$totalnboflines.')';
print '</div></td>';
// Center
if ($center)
{
print '<td class="nobordernopadding" align="left" valign="middle">'.$center.'</td>';
print '<td class="nobordernopadding center" style="width: 30%" valign="middle">'.$center.'</td>';
}
// Right
print '<td class="nobordernopadding" align="right" valign="middle">';
print '<td class="nobordernopadding" align="right" style="width: 35%" valign="middle">';
if ($sortfield) $options .= "&amp;sortfield=".$sortfield;
if ($sortorder) $options .= "&amp;sortorder=".$sortorder;
// Show navigation bar

View File

@@ -109,6 +109,7 @@ print '</form>';
print '<br><br>';
print $langs->trans("UseMenuModuleToolsToAddCronJobs").'<br>';
if (! empty($conf->global->CRON_WARNING_DELAY_HOURS)) print info_admin($langs->trans("WarningCronDelayed", $conf->global->CRON_WARNING_DELAY_HOURS));
print '<br><br>';

View File

@@ -275,9 +275,6 @@ print '<input type="hidden" name="sortfield" value="'.$sortfield.'">';
print '<input type="hidden" name="sortorder" value="'.$sortorder.'">';
print '<input type="hidden" name="viewstatut" value="'.$viewstatut.'">';
print_barre_liste($pagetitle, $page, $_SERVER["PHP_SELF"], $param, $sortfield, $sortorder, $stringcurrentdate, $num, $nbtotalofrecords, 'title_setup', 0, '', '', $limit);
// Line with explanation and button new job
if (! $user->rights->cron->create)
{
@@ -287,7 +284,13 @@ else
{
$buttontoshow.='<a class="butAction" style="margin-right: 0px;margin-left: 0px;" href="'.DOL_URL_ROOT.'/cron/card.php?action=create">'.$langs->trans("CronCreateJob").'</a>';
}
print '<table class="centpercent"><tr><td>'.$langs->trans('CronInfo').'</td><td class="right">'.$buttontoshow.'</td></tr></table>';
print_barre_liste($pagetitle, $page, $_SERVER["PHP_SELF"], $param, $sortfield, $sortorder, $buttontoshow, $num, $nbtotalofrecords, 'title_setup', 0, '', '', $limit);
print $langs->trans('CronInfo').'<br>';
print $stringcurrentdate.'<br>';
if (! empty($conf->global->CRON_WARNING_DELAY_HOURS)) print info_admin($langs->trans("WarningCronDelayed", $conf->global->CRON_WARNING_DELAY_HOURS));
print '<br>';

View File

@@ -76,3 +76,4 @@ UseMenuModuleToolsToAddCronJobs=Go into menu "Home - Admin tools - Scheduled job
JobDisabled=Job disabled
MakeLocalDatabaseDumpShort=Local database backup
MakeLocalDatabaseDump=Create a local database dump
WarningCronDelayed=Attention, for performance purpose, whatever is next date of execution of active jobs, your jobs may be delayed to a maximum of %s hours before being run.