Merge branch '9.0' of git@github.com:Dolibarr/dolibarr.git into develop
Conflicts: htdocs/filefunc.inc.php htdocs/install/upgrade2.php
This commit is contained in:
commit
2621af96d6
1
build/debian/source/include-binaries
Normal file
1
build/debian/source/include-binaries
Normal file
@ -0,0 +1 @@
|
||||
htdocs/install/doctemplates/websites/website_template-corporate.zip
|
||||
@ -2922,9 +2922,9 @@ function migrate_project_task_actors($db,$langs,$conf)
|
||||
* @param Conf $conf Object conf
|
||||
* @param string $table Table name
|
||||
* @param int $fk_source Id of element source
|
||||
* @param type $sourcetype Type of element source
|
||||
* @param string $sourcetype Type of element source
|
||||
* @param int $fk_target Id of element target
|
||||
* @param type $targettype Type of element target
|
||||
* @param string $targettype Type of element target
|
||||
* @return void
|
||||
*/
|
||||
function migrate_relationship_tables($db,$langs,$conf,$table,$fk_source,$sourcetype,$fk_target,$targettype)
|
||||
@ -4833,7 +4833,7 @@ function migrate_reload_menu($db,$langs,$conf,$versionto)
|
||||
*/
|
||||
function migrate_user_photospath()
|
||||
{
|
||||
global $conf, $db, $langs;
|
||||
global $conf, $db, $langs, $user;
|
||||
|
||||
print '<tr><td colspan="4">';
|
||||
|
||||
@ -4842,6 +4842,8 @@ function migrate_user_photospath()
|
||||
include_once DOL_DOCUMENT_ROOT.'/user/class/user.class.php';
|
||||
$fuser = new User($db);
|
||||
|
||||
if (! is_object($user)) $user = $fuser; // To avoid error during migration
|
||||
|
||||
$sql = "SELECT rowid as uid from ".MAIN_DB_PREFIX."user"; // Get list of all users
|
||||
$resql = $db->query($sql);
|
||||
if ($resql)
|
||||
@ -4858,47 +4860,56 @@ function migrate_user_photospath()
|
||||
} else {
|
||||
$dir = $conf->user->multidir_output[$entity]; // $conf->user->multidir_output[] for each entity is construct by the multicompany module
|
||||
}
|
||||
|
||||
if ($dir)
|
||||
{
|
||||
$origin = $dir .'/'. get_exdir($fuser->id,2,0,0,$fuser,'user');
|
||||
$destin = $dir .'/'. $fuser->id;
|
||||
$origin = $dir .'/'. get_exdir($fuser->id,2,0,0,$fuser,'user');
|
||||
$destin = $dir .'/'. $fuser->id;
|
||||
|
||||
$error = 0;
|
||||
$origin_osencoded=dol_osencode($origin);
|
||||
|
||||
$origin_osencoded=dol_osencode($origin);
|
||||
$destin_osencoded=dol_osencode($destin);
|
||||
dol_mkdir($destin);
|
||||
//echo '<hr>'.$origin.' -> '.$destin;
|
||||
if (dol_is_dir($origin))
|
||||
{
|
||||
$handle=opendir($origin_osencoded);
|
||||
if (is_resource($handle))
|
||||
{
|
||||
while (($file = readdir($handle)) !== false)
|
||||
{
|
||||
if ($file != '.' && $file != '..' && is_dir($origin_osencoded.'/'.$file))
|
||||
{
|
||||
$thumbs = opendir($origin_osencoded.'/'.$file);
|
||||
if (is_resource($thumbs))
|
||||
{
|
||||
dol_mkdir($destin.'/'.$file);
|
||||
while (($thumb = readdir($thumbs)) !== false)
|
||||
{
|
||||
dol_move($origin.'/'.$file.'/'.$thumb, $destin.'/'.$file.'/'.$thumb);
|
||||
}
|
||||
// dol_delete_dir($origin.'/'.$file);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if (dol_is_file($origin.'/'.$file) )
|
||||
{
|
||||
dol_move($origin.'/'.$file, $destin.'/'.$file);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
dol_mkdir($destin);
|
||||
|
||||
//echo '<hr>'.$origin.' -> '.$destin;
|
||||
if (dol_is_dir($origin))
|
||||
{
|
||||
$handle=opendir($origin_osencoded);
|
||||
if (is_resource($handle))
|
||||
{
|
||||
while (($file = readdir($handle)) !== false)
|
||||
{
|
||||
if ($file == '.' || $file == '..') continue;
|
||||
|
||||
if (dol_is_dir($origin.'/'.$file)) // it is a dir (like 'thumbs')
|
||||
{
|
||||
$thumbs = opendir($origin_osencoded.'/'.$file);
|
||||
if (is_resource($thumbs))
|
||||
{
|
||||
dol_mkdir($destin.'/'.$file);
|
||||
while (($thumb = readdir($thumbs)) !== false)
|
||||
{
|
||||
if (! dol_is_file($destin.'/'.$file.'/'.$thumb))
|
||||
{
|
||||
if ($thumb == '.' || $thumb == '..') continue;
|
||||
|
||||
print '.';
|
||||
dol_move($origin.'/'.$file.'/'.$thumb, $destin.'/'.$file.'/'.$thumb, 0, 0, 0, 0);
|
||||
}
|
||||
}
|
||||
// dol_delete_dir($origin.'/'.$file);
|
||||
}
|
||||
}
|
||||
else // it is a file
|
||||
{
|
||||
if (! dol_is_file($destin.'/'.$file))
|
||||
{
|
||||
print '.';
|
||||
dol_move($origin.'/'.$file, $destin.'/'.$file, 0, 0, 0, 1);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -149,13 +149,13 @@ TaskCreatedInDolibarr=Task %s created
|
||||
TaskModifiedInDolibarr=Task %s modified
|
||||
TaskDeletedInDolibarr=Task %s deleted
|
||||
OpportunityStatus=Lead status
|
||||
OpportunityStatusShort=Opp. status
|
||||
OpportunityStatusShort=Lead status
|
||||
OpportunityProbability=Lead probability
|
||||
OpportunityProbabilityShort=Opp. probab.
|
||||
OpportunityProbabilityShort=Lead probab.
|
||||
OpportunityAmount=Lead amount
|
||||
OpportunityAmountShort=Opp. amount
|
||||
OpportunityAmountAverageShort=Average Opp. amount
|
||||
OpportunityAmountWeigthedShort=Weighted Opp. amount
|
||||
OpportunityAmountShort=Lead amount
|
||||
OpportunityAmountAverageShort=Average lead amount
|
||||
OpportunityAmountWeigthedShort=Weighted lead amount
|
||||
WonLostExcluded=Won/Lost excluded
|
||||
##### Types de contacts #####
|
||||
TypeContact_project_internal_PROJECTLEADER=Project leader
|
||||
@ -234,4 +234,4 @@ DontHaveTheValidateStatus=The project %s must be open to be closed
|
||||
RecordsClosed=%s project(s) closed
|
||||
SendProjectRef=Information project %s
|
||||
ModuleSalaryToDefineHourlyRateMustBeEnabled=Module 'Payment of employee wages' must be enabled to define employee hourly rate to have time spent valorized
|
||||
NewTaskRefSuggested=Task ref already used, a new task ref is suggested
|
||||
NewTaskRefSuggested=Task ref already used, a new task ref is suggested
|
||||
|
||||
Loading…
Reference in New Issue
Block a user