Merge branch '12.0' of git@github.com:Dolibarr/dolibarr.git into develop
Conflicts: htdocs/admin/system/dolibarr.php
This commit is contained in:
commit
56d56929ec
@ -85,31 +85,37 @@ if (empty($conf->global->MAIN_VERSION_LAST_UPGRADE))
|
|||||||
if (DOL_VERSION != $conf->global->MAIN_VERSION_LAST_UPGRADE) print ' '.img_warning($langs->trans("RunningUpdateProcessMayBeRequired", DOL_VERSION, $conf->global->MAIN_VERSION_LAST_UPGRADE));
|
if (DOL_VERSION != $conf->global->MAIN_VERSION_LAST_UPGRADE) print ' '.img_warning($langs->trans("RunningUpdateProcessMayBeRequired", DOL_VERSION, $conf->global->MAIN_VERSION_LAST_UPGRADE));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
$version = DOL_VERSION;
|
||||||
|
if (preg_match('/[a-z]+/i', $version)) $version = 'develop'; // If version contains text, it is not an official tagged version, so we use the full change log.
|
||||||
|
print ' <a href="https://raw.githubusercontent.com/Dolibarr/dolibarr/'.$version.'/ChangeLog" target="_blank">'.$langs->trans("SeeChangeLog").'</a>';
|
||||||
|
|
||||||
|
$newversion = '';
|
||||||
if (function_exists('curl_init'))
|
if (function_exists('curl_init'))
|
||||||
{
|
{
|
||||||
$conf->global->MAIN_USE_RESPONSE_TIMEOUT = 10;
|
$conf->global->MAIN_USE_RESPONSE_TIMEOUT = 10;
|
||||||
print ' - ';
|
print ' - ';
|
||||||
if ($action == 'getlastversion')
|
if ($action == 'getlastversion') {
|
||||||
{
|
if ($sfurl) {
|
||||||
if ($sfurl)
|
$i = 0;
|
||||||
{
|
while (!empty($sfurl->channel[0]->item[$i]->title) && $i < 10000) {
|
||||||
while (!empty($sfurl->channel[0]->item[$i]->title) && $i < 10000)
|
$title = $sfurl->channel[0]->item[$i]->title;
|
||||||
{
|
$reg = array();
|
||||||
$title = $sfurl->channel[0]->item[$i]->title;
|
if (preg_match('/([0-9]+\.([0-9\.]+))/', $title, $reg)) {
|
||||||
if (preg_match('/([0-9]+\.([0-9\.]+))/', $title, $reg))
|
$newversion = $reg[1];
|
||||||
{
|
$newversionarray = explode('.', $newversion);
|
||||||
$newversion = $reg[1];
|
$versionarray = explode('.', $version);
|
||||||
$newversionarray = explode('.', $newversion);
|
//var_dump($newversionarray);var_dump($versionarray);
|
||||||
$versionarray = explode('.', $version);
|
if (versioncompare($newversionarray, $versionarray) > 0) $version = $newversion;
|
||||||
//var_dump($newversionarray);var_dump($versionarray);
|
}
|
||||||
if (versioncompare($newversionarray, $versionarray) > 0) $version = $newversion;
|
$i++;
|
||||||
}
|
}
|
||||||
$i++;
|
|
||||||
}
|
|
||||||
|
|
||||||
// Show version
|
// Show version
|
||||||
print $langs->trans("LastStableVersion").' : <b>'.(($version != '0.0') ? $version : $langs->trans("Unknown")).'</b>';
|
print $langs->trans("LastStableVersion").' : <b>'.(($version != '0.0') ? $version : $langs->trans("Unknown")).'</b>';
|
||||||
} else {
|
if ($version != '0.0') {
|
||||||
|
print ' <a href="https://raw.githubusercontent.com/Dolibarr/dolibarr/'.$version.'/ChangeLog" target="_blank">'.$langs->trans("SeeChangeLog").'</a>';
|
||||||
|
}
|
||||||
|
} else {
|
||||||
print $langs->trans("LastStableVersion").' : <b>'.$langs->trans("UpdateServerOffline").'</b>';
|
print $langs->trans("LastStableVersion").' : <b>'.$langs->trans("UpdateServerOffline").'</b>';
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
@ -118,12 +124,11 @@ if (function_exists('curl_init'))
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Now show link to the changelog
|
// Now show link to the changelog
|
||||||
print ' - ';
|
//print ' - ';
|
||||||
|
|
||||||
$version = DOL_VERSION;
|
$version = DOL_VERSION;
|
||||||
if (preg_match('/[a-z]+/i', $version)) $version = 'develop'; // If version contains text, it is not an official tagged version, so we use the full change log.
|
if (preg_match('/[a-z]+/i', $version)) $version = 'develop'; // If version contains text, it is not an official tagged version, so we use the full change log.
|
||||||
|
|
||||||
print '<a href="https://raw.githubusercontent.com/Dolibarr/dolibarr/'.$version.'/ChangeLog" target="_blank">'.$langs->trans("SeeChangeLog").'</a>';
|
|
||||||
print '</td></tr>'."\n";
|
print '</td></tr>'."\n";
|
||||||
print '<tr class="oddeven"><td>'.$langs->trans("VersionLastUpgrade").' ('.$langs->trans("Database").')</td><td>'.$conf->global->MAIN_VERSION_LAST_UPGRADE.'</td></tr>'."\n";
|
print '<tr class="oddeven"><td>'.$langs->trans("VersionLastUpgrade").' ('.$langs->trans("Database").')</td><td>'.$conf->global->MAIN_VERSION_LAST_UPGRADE.'</td></tr>'."\n";
|
||||||
print '<tr class="oddeven"><td>'.$langs->trans("VersionLastInstall").'</td><td>'.$conf->global->MAIN_VERSION_LAST_INSTALL.'</td></tr>'."\n";
|
print '<tr class="oddeven"><td>'.$langs->trans("VersionLastInstall").'</td><td>'.$conf->global->MAIN_VERSION_LAST_INSTALL.'</td></tr>'."\n";
|
||||||
|
|||||||
@ -919,7 +919,8 @@ if (empty($reshook))
|
|||||||
|
|
||||||
if ($result > 0) {
|
if ($result > 0) {
|
||||||
$ret = $object->fetch($object->id); // Reload to get new records
|
$ret = $object->fetch($object->id); // Reload to get new records
|
||||||
|
$object->fetch_thirdparty();
|
||||||
|
|
||||||
if (empty($conf->global->MAIN_DISABLE_PDF_AUTOUPDATE)) {
|
if (empty($conf->global->MAIN_DISABLE_PDF_AUTOUPDATE)) {
|
||||||
// Define output language
|
// Define output language
|
||||||
$outputlangs = $langs;
|
$outputlangs = $langs;
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user