forked from Wavyzz/dolibarr
Merge branch '20.0' of git@github.com:Dolibarr/dolibarr.git into 21.0
This commit is contained in:
@@ -682,7 +682,7 @@ class Translate
|
||||
}
|
||||
}
|
||||
|
||||
$str = str_replace('%)', '__percent_parenthesis__', $str);
|
||||
$str = preg_replace('/([^%])%([^0sd])/', '__percent_parenthesis__', $str);
|
||||
|
||||
if (strpos($key, 'Format') !== 0) {
|
||||
try {
|
||||
|
||||
@@ -1270,7 +1270,7 @@ function activateModule($value, $withdeps = 1, $noconfverification = 0)
|
||||
if ($activateerr) {
|
||||
$ret['errors'][] = $activateerr;
|
||||
}
|
||||
$ret['errors'][] = $langs->trans('activateModuleDependNotSatisfied', $objMod->name, $modulestring);
|
||||
$ret['errors'][] = $langs->trans('activateModuleDependNotSatisfied', $objMod->name, $modulestring, $objMod->name).'<br>'.$langs->trans('activateModuleDependNotSatisfied2', $modulestring, $objMod->name);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -2797,6 +2797,7 @@ function print_projecttasks_array($db, $form, $socid, $projectsListId, $mytasks
|
||||
}
|
||||
|
||||
print '<td class="right">';
|
||||
$alttext = '';
|
||||
if ($objp->opp_percent && $objp->opp_amount) {
|
||||
$opp_weighted_amount = $objp->opp_percent * $objp->opp_amount / 100;
|
||||
$alttext = $langs->trans("OpportunityWeightedAmount").' '.price($opp_weighted_amount, 0, '', 1, -1, 0, $conf->currency);
|
||||
|
||||
@@ -2114,7 +2114,8 @@ AddSubstitutions=Add keys substitutions
|
||||
DetectionNotPossible=Detection not possible
|
||||
UrlToGetKeyToUseAPIs=Url to get token to use API (once token has been received it is saved in database user table and must be provided on each API call)
|
||||
ListOfAvailableAPIs=List of available APIs
|
||||
activateModuleDependNotSatisfied=Module "%s" depends on module "%s", that is missing, so module "%1$s" may not work correctly. Please install module "%2$s" or disable module "%1$s" if you want to be safe from any surprise
|
||||
activateModuleDependNotSatisfied=Module "%s" depends on module "%s", that is missing, so module "%s" may not work correctly.
|
||||
activateModuleDependNotSatisfied2=Please install module "%s" or disable module "%s" if you want to be safe from any surprise.
|
||||
CommandIsNotInsideAllowedCommands=The command you are trying to run is not in the list of allowed commands defined in parameter <strong>$dolibarr_main_restrict_os_commands</strong> in the <strong>conf.php</strong> file.
|
||||
LandingPage=Landing page
|
||||
SamePriceAlsoForSharedCompanies=If you use a multicompany module, with the choice "Single price", the price will also be the same for all companies if products are shared between environments
|
||||
|
||||
@@ -2250,6 +2250,9 @@ class Project extends CommonObject
|
||||
$this->monthWorkLoadPerTask[$week_number][$obj->fk_element] = $obj->element_duration;
|
||||
} else {
|
||||
$this->monthWorkLoad[$week_number] += $obj->element_duration;
|
||||
if (!isset($this->monthWorkLoadPerTask[$week_number][$obj->fk_element])) {
|
||||
$this->monthWorkLoadPerTask[$week_number][$obj->fk_element] = 0;
|
||||
}
|
||||
$this->monthWorkLoadPerTask[$week_number][$obj->fk_element] += $obj->element_duration;
|
||||
}
|
||||
$weekalreadyfound[$week_number] = 1;
|
||||
|
||||
@@ -81,7 +81,10 @@ if ($reshook < 0) {
|
||||
}
|
||||
|
||||
if ($id > 0 || $ref) {
|
||||
$object->fetch($id, $ref);
|
||||
$ret = $object->fetch($id, $ref);
|
||||
if ($ret > 0) {
|
||||
$projectstatic->fetch($object->fk_project);
|
||||
}
|
||||
}
|
||||
|
||||
// Security check
|
||||
@@ -244,7 +247,7 @@ if ($action == 'remove_file' && $user->hasRight('projet', 'creer')) {
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/lib/files.lib.php';
|
||||
|
||||
$langs->load("other");
|
||||
$upload_dir = $conf->project->dir_output;
|
||||
$upload_dir = $conf->project->dir_output."/".dol_sanitizeFileName($projectstatic->ref)."/".dol_sanitizeFileName($object->ref);
|
||||
$file = $upload_dir.'/'.dol_sanitizeFileName(GETPOST('file'));
|
||||
|
||||
$ret = dol_delete_file($file);
|
||||
@@ -263,7 +266,6 @@ $form = new Form($db);
|
||||
$formother = new FormOther($db);
|
||||
$formfile = new FormFile($db);
|
||||
$formproject = new FormProjets($db);
|
||||
$result = $projectstatic->fetch($object->fk_project);
|
||||
|
||||
$title = $object->ref;
|
||||
if (!empty($withproject)) {
|
||||
@@ -758,7 +760,7 @@ if ($id > 0 || !empty($ref)) {
|
||||
/*
|
||||
* Generated documents
|
||||
*/
|
||||
$filename = dol_sanitizeFileName($projectstatic->ref)."/".dol_sanitizeFileName($object->ref);
|
||||
$filename = '';
|
||||
$filedir = $conf->project->dir_output."/".dol_sanitizeFileName($projectstatic->ref)."/".dol_sanitizeFileName($object->ref);
|
||||
$urlsource = $_SERVER["PHP_SELF"]."?id=".$object->id;
|
||||
$genallowed = ($user->hasRight('projet', 'lire'));
|
||||
|
||||
@@ -77,6 +77,7 @@ $cancel = GETPOST('cancel', 'alpha');
|
||||
$backtopage = GETPOST('backtopage', 'alpha');
|
||||
$backtopageforcancel = GETPOST('backtopageforcancel', 'alpha');
|
||||
|
||||
$limit = GETPOSTINT('limit') ? GETPOSTINT('limit') : $conf->liste_limit;
|
||||
$sortfield = GETPOST('sortfield', 'aZ09comma') ? GETPOST('sortfield', 'aZ09comma') : "a.datep";
|
||||
$sortorder = GETPOST('sortorder', 'aZ09comma') ? GETPOST('sortorder', 'aZ09comma') : "desc";
|
||||
$search_rowid = GETPOST('search_rowid');
|
||||
|
||||
Reference in New Issue
Block a user