Browse Source

Merge remote-tracking branch 'origin/4.0' into develop

Laurent Destailleur 9 years ago
parent
commit
3265b7028d

+ 3 - 1
build/debian/source/lintian-overrides

@@ -1,3 +1,5 @@
 # Remove warning, we want to keep both standard and minified sources.
 dolibarr: source-contains-prebuilt-javascript-object htdocs/includes/jsgantt/*
-dolibarr: source-contains-prebuilt-javascript-object htdocs/includes/jquery/*
+dolibarr: source-contains-prebuilt-javascript-object htdocs/includes/jquery/*
+# This is a textual data file
+source-is-missing htdocs/includes/mobiledetect/mobiledetectlib/Mobile_Detect.json

+ 2 - 0
dev/translation/sanity_check_en_langfiles.php

@@ -298,6 +298,8 @@ if ((! empty($_REQUEST['unused']) && $_REQUEST['unused'] == 'true') || (isset($a
 	    // boxes.lang
 	    if (preg_match('/^BoxTitleLast/', $value)) $qualifiedforclean=0;
 	    if (preg_match('/^BoxTitleLatest/', $value)) $qualifiedforclean=0;
+	    // install.lang
+	    if (preg_match('/^KeepDefaultValues/', $value)) $qualifiedforclean=0;
 	    // main.lang
 	    if (preg_match('/^Duration/', $value)) $qualifiedforclean=0;
 	    if (preg_match('/^FormatDate/', $value)) $qualifiedforclean=0;

+ 3 - 3
htdocs/admin/modules.php

@@ -304,7 +304,7 @@ $h++;
 print "<br>\n";
 
 
-dol_fiche_head($head, $mode, $langs->trans("Modules"));
+dol_fiche_head($head, $mode, '');
 
 $var=true;
 
@@ -443,11 +443,11 @@ if ($mode != 'marketplace')
         if ($familykey!=$oldfamily)
         {
             print '<tr class="liste_titre">'."\n";
-            print '<td colspan="6">';
+            print '<td colspan="5">';
             $familytext=empty($familyinfo[$familykey]['label'])?$familykey:$familyinfo[$familykey]['label'];
             print $familytext;
             print "</td>\n";
-    		print '<td align="right">'.$langs->trans("SetupShort").'</td>'."\n";
+    		print '<td colspan="2" align="right">'.$langs->trans("SetupShort").'</td>'."\n";
             print "</tr>\n";
             $atleastoneforfamily=0;
             //print "<tr><td>yy".$oldfamily."-".$familykey."-".$atleastoneforfamily."<br></td><tr>";

+ 2 - 2
htdocs/admin/perms.php

@@ -200,13 +200,13 @@ if ($result)
         {
             print img_picto($langs->trans("Active"),'tick');
             print '</td><td>';
-            print '<a href="perms.php?pid='.$obj->id.'&amp;action=remove#'.$objMod->getName().'">'.img_edit_remove().'</a>';
+            print '<a class="reposition" href="perms.php?pid='.$obj->id.'&amp;action=remove">'.img_edit_remove().'</a>';
         }
         else
         {
             print '&nbsp;';
             print '</td><td>';
-            print '<a href="perms.php?pid='.$obj->id.'&amp;action=add#'.$objMod->getName().'">'.img_edit_add().'</a>';
+            print '<a class="reposition" href="perms.php?pid='.$obj->id.'&amp;action=add">'.img_edit_add().'</a>';
         }
 
         print '</td></tr>';

+ 2 - 1
htdocs/api/admin/explorer.php

@@ -28,6 +28,8 @@ require_once DOL_DOCUMENT_ROOT.'/core/lib/functions2.lib.php';
 require_once DOL_DOCUMENT_ROOT.'/api/class/api.class.php';
 require_once DOL_DOCUMENT_ROOT.'/api/class/api_access.class.php';
 
+$langs->load("admin");
+
 
 /*
  * View
@@ -36,7 +38,6 @@ require_once DOL_DOCUMENT_ROOT.'/api/class/api_access.class.php';
 // Enable and test if module Api is enabled
 if (empty($conf->global->MAIN_MODULE_API))
 {
-    $langs->load("admin");
     dol_syslog("Call Dolibarr API interfaces with module REST disabled");
     print $langs->trans("WarningModuleNotActive",'Api').'.<br><br>';
     print $langs->trans("ToActivateModule");

+ 1 - 1
htdocs/contrat/index.php

@@ -273,7 +273,7 @@ if (! empty($conf->contrat->enabled) && $user->rights->contrat->lire)
 		}
 		else
 		{
-			print '<tr '.$bc[$var].'><td colspan="3">'.$langs->trans("NoContracts").'</td></tr>';
+			print '<tr '.$bc[$var].' class><td colspan="3" class="opacitymedium">'.$langs->trans("NoContracts").'</td></tr>';
 		}
 		print "</table><br>";
 		$db->free($resql);

+ 1 - 2
htdocs/core/lib/files.lib.php

@@ -1990,8 +1990,7 @@ function dol_check_secure_access_document($modulepart,$original_file,$entity,$fu
 		$original_file=$conf->facture->dir_output.'/'.$original_file;
 		$sqlprotectagainstexternals = "SELECT fk_soc as fk_soc FROM ".MAIN_DB_PREFIX."facture WHERE ref='".$db->escape($refname)."' AND entity=".$conf->entity;
 	}
-
-	else if ($modulepart == 'massfilesarea')
+	else if ($modulepart == 'massfilesarea_facture')
 	{
 		if ($fuser->rights->facture->lire || preg_match('/^specimen/i',$original_file))
 		{

+ 5 - 1
htdocs/index.php

@@ -47,7 +47,11 @@ if (!isset($conf->global->MAIN_INFO_SOCIETE_NOM) || empty($conf->global->MAIN_IN
     header("Location: ".DOL_URL_ROOT."/admin/index.php?mainmenu=home&leftmenu=setup&mesg=setupnotcomplete");
     exit;
 }
-
+if (count($conf->modules) <= (empty($conf->global->MAIN_MIN_NB_ENABLED_MODULE_FOR_WARNING)?1:$conf->global->MAIN_MIN_NB_ENABLED_MODULE_FOR_WARNING))	// If only user module enabled
+{
+    header("Location: ".DOL_URL_ROOT."/admin/index.php?mainmenu=home&leftmenu=setup&mesg=setupnotcomplete");
+    exit;
+}
 if (GETPOST('addbox'))	// Add box (when submit is done from a form when ajax disabled)
 {
 	require_once DOL_DOCUMENT_ROOT.'/core/class/infobox.class.php';

+ 1 - 1
htdocs/langs/en_US/admin.lang

@@ -951,7 +951,7 @@ LogEventDesc=You can enable here the logging for Dolibarr security events. Admin
 AreaForAdminOnly=Those features can be used by <b>administrator users</b> only.
 SystemInfoDesc=System information is miscellaneous technical information you get in read only mode and visible for administrators only.
 SystemAreaForAdminOnly=This area is available for administrator users only. None of the Dolibarr permissions can reduce this limit.
-CompanyFundationDesc=Edit on this page all known information of the company or foundation you need to manage (For this, click on "Modify" button at bottom of page)
+CompanyFundationDesc=Edit on this page all known information of the company or foundation you need to manage (For this, click on "Modify" or "Save" button at bottom of page)
 DisplayDesc=You can choose each parameter related to the Dolibarr look and feel here
 AvailableModules=Available modules
 ToActivateModule=To activate modules, go on setup Area (Home->Setup->Modules).

+ 4 - 0
htdocs/langs/en_US/install.lang

@@ -133,6 +133,10 @@ ActivateModule=Activate module %s
 ShowEditTechnicalParameters=Click here to show/edit advanced parameters (expert mode)
 WarningUpgrade=Warning:\nDid your run a database backup first ?\nThis is highly recommanded: for example, due to some bugs into databases systems (for example mysql version 5.5.40/41/42/43), some data or tables may be lost during this process, so it is highly recommanded to have a complete dump of your database before starting migration.\n\nClick OK to start migration process...
 ErrorDatabaseVersionForbiddenForMigration=Your database version is %s. It has a critical bug making data loss if you make structure change on your database, like it is required by the migration process. For his reason, migration will not be allowed until you upgrade your database to a higher fixed version (list of known bugged version: %s) 
+KeepDefaultValuesWamp=You use the Dolibarr setup wizard from DoliWamp, so values proposed here are already optimized. Change them only if you know what you do.
+KeepDefaultValuesDeb=You use the Dolibarr setup wizard from a Linux package (Ubuntu, Debian, Fedora...), so values proposed here are already optimized. Only the password of the database owner to create must be completed. Change other parameters only if you know what you do.
+KeepDefaultValuesMamp=You use the Dolibarr setup wizard from DoliMamp, so values proposed here are already optimized. Change them only if you know what you do.
+KeepDefaultValuesProxmox=You use the Dolibarr setup wizard from a Proxmox virtual appliance, so values proposed here are already optimized. Change them only if you know what you do.
 
 #########
 # upgrade

+ 4 - 0
htdocs/langs/et_EE/install.lang

@@ -132,6 +132,10 @@ ActivateModule=Aktiveeri moodul %s
 ShowEditTechnicalParameters=Klõpsa siia lisaparameetrite näitamiseks/muutmiseks (spetsialisti režiim)
 WarningUpgrade=Warning:\nDid your run a database backup first ?\nThis is highly recommanded: for example, due to some bugs into databases systems (for example mysql version 5.5.40/41/42/43), some data or tables may be lost during this process, so it is highly recommanded to have a complete dump of your database before starting migration.\n\nClick OK to start migration process...
 ErrorDatabaseVersionForbiddenForMigration=Sinu andmebaasi versioon on %s. Selles versioonis on tõsine puuk, mis põhjustab andmebaasi struktuuri muutmisel andmekadu, nagu seda teeb migratsiooni protsess. Seega ei ole migratsioon lubatud seni, kuni uuendad oma andmebaasi parandustega versioonile (teadaolevate vigaste versioonide nimekiri: %s)
+KeepDefaultValuesWamp=You use the Dolibarr setup wizard from DoliWamp, so values proposed here are already optimized. Change them only if you know what you do.
+KeepDefaultValuesDeb=You use the Dolibarr setup wizard from a Linux package (Ubuntu, Debian, Fedora...), so values proposed here are already optimized. Only the password of the database owner to create must be completed. Change other parameters only if you know what you do.
+KeepDefaultValuesMamp=You use the Dolibarr setup wizard from DoliMamp, so values proposed here are already optimized. Change them only if you know what you do.
+KeepDefaultValuesProxmox=You use the Dolibarr setup wizard from a Proxmox virtual appliance, so values proposed here are already optimized. Change them only if you know what you do.
 
 #########
 # upgrade