';
@@ -102,10 +102,10 @@ foreach ($list as $key)
if (! $supported) continue; // show only supported
$i++;
-
+
print '
';
// Api Name
- $label = $langs->trans($key[0]);
+ $label = $langs->trans($key[0]);
print '
'.$label.'
';
print '
';
if (! empty($key[3])) print $langs->trans($key[3]);
@@ -127,7 +127,7 @@ foreach ($list as $key)
print '
'.$langs->trans("FeatureNotYetSupported").'
';
print '
';
}
-
+
// Api Id
print '
';
print '
';
diff --git a/htdocs/admin/oauthlogintokens.php b/htdocs/admin/oauthlogintokens.php
index 06315222825..d2a7232a4fe 100644
--- a/htdocs/admin/oauthlogintokens.php
+++ b/htdocs/admin/oauthlogintokens.php
@@ -118,7 +118,7 @@ print load_fiche_titre($langs->trans('ConfigOAuth'),$linkback,'title_setup');
$head=oauthadmin_prepare_head($mode);
-dol_fiche_head($head, 'tokengeneration', '', 0, 'technic');
+dol_fiche_head($head, 'tokengeneration', '', -1, 'technic');
if ($mode == 'setup' && $user->admin)
@@ -131,8 +131,8 @@ if ($mode == 'setup' && $user->admin)
$supported=0;
if (in_array($key[0], array_keys($supportedoauth2array))) $supported=1;
if (! $supported) continue; // show only supported
-
-
+
+
$OAUTH_SERVICENAME='Unknown';
if ($key[0] == 'OAUTH_GITHUB_NAME')
{
@@ -148,7 +148,7 @@ if ($mode == 'setup' && $user->admin)
$urltodelete=$urlwithroot.'/core/modules/oauth/google_oauthcallback.php?action=delete&backtourl='.urlencode(DOL_URL_ROOT.'/admin/oauthlogintokens.php');
$urltocheckperms='https://security.google.com/settings/security/permissions';
}
-
+
// Show value of token
$tokenobj=null;
// Token
@@ -164,21 +164,21 @@ if ($mode == 'setup' && $user->admin)
{
// Return an error if token not found
}
-
+
// Set other properties
$refreshtoken=false;
$expiredat='';
-
+
$expire = false;
// Is token expired or will token expire in the next 30 seconds
if (is_object($tokenobj)) {
$expire = ($tokenobj->getEndOfLife() !== $tokenobj::EOL_NEVER_EXPIRES && $tokenobj->getEndOfLife() !== $tokenobj::EOL_UNKNOWN && time() > ($tokenobj->getEndOfLife() - 30));
}
-
+
if ($key[1] != '' && $key[2] != '') {
if (is_object($tokenobj)) {
$refreshtoken = $tokenobj->getRefreshToken();
-
+
$endoflife = $tokenobj->getEndOfLife();
if ($endoflife == $tokenobj::EOL_NEVER_EXPIRES)
{
@@ -196,21 +196,21 @@ if ($mode == 'setup' && $user->admin)
}
$submit_enabled=0;
-
+
print '';
}
-
+
}
if ($mode == 'test' && $user->admin)
@@ -344,7 +344,7 @@ if ($mode == 'test' && $user->admin)
}
}
-
+
print '';
}
@@ -368,7 +368,7 @@ if ($mode == 'userconf' && $user->admin)
$sql = 'SELECT p.rowid, p.printer_name, p.printer_location, p.printer_id, p.copy, p.module, p.driver, p.userid, u.login FROM '.MAIN_DB_PREFIX.'printing as p, '.MAIN_DB_PREFIX.'user as u WHERE p.userid=u.rowid';
$resql = $db->query($sql);
while ($row=$db->fetch_array($resql)) {
-
+
print '
';
print '
'.$row['login'].'
';
print '
'.$row['module'].'
';
diff --git a/htdocs/core/actions_printing.inc.php b/htdocs/core/actions_printing.inc.php
index dbf446d2112..4961c3e29f2 100644
--- a/htdocs/core/actions_printing.inc.php
+++ b/htdocs/core/actions_printing.inc.php
@@ -28,7 +28,7 @@
// Filename to print must be provided into 'file' parameter
// Print file
-if ($action == 'print_file' and $user->rights->printing->read)
+if ($action == 'print_file' and $user->rights->printing->read)
{
$langs->load("printing");
require_once DOL_DOCUMENT_ROOT . '/core/modules/printing/modules_printing.php';
@@ -44,10 +44,10 @@ if ($action == 'print_file' and $user->rights->printing->read)
$printer = new $classname($db);
//print '
'.print_r($printer, true).'
';
- if (! empty($conf->global->{$printer->active}))
+ if (! empty($conf->global->{$printer->active}))
{
$printerfound++;
-
+
$subdir=(GETPOST('printer', 'alpha')=='expedition'?'sending':'');
$module = GETPOST('printer', 'alpha');
if ($module =='commande_fournisseur') {
@@ -60,7 +60,7 @@ if ($action == 'print_file' and $user->rights->printing->read)
//print '
'.print_r($printer->errors, true).'
';
setEventMessages($printer->error, $printer->errors, 'errors');
}
- if ($ret==0)
+ if ($ret==0)
{
//print '
'.print_r($printer->errors, true).'
';
setEventMessages($printer->error, $printer->errors);
@@ -74,7 +74,7 @@ if ($action == 'print_file' and $user->rights->printing->read)
}
}
}
- if ($printerfound==0) setEventMessages($langs->trans("NoActivePrintingModuleFound"), null, 'warnings');
+ if ($printerfound==0) setEventMessages($langs->trans("NoActivePrintingModuleFound", $langs->transnoentities("Module64000Name")), null, 'warnings');
} else {
setEventMessages($langs->trans("NoModuleFound"), null, 'warnings');
}
diff --git a/htdocs/langs/en_US/printing.lang b/htdocs/langs/en_US/printing.lang
index a357409289a..36f4e75f23a 100644
--- a/htdocs/langs/en_US/printing.lang
+++ b/htdocs/langs/en_US/printing.lang
@@ -9,7 +9,7 @@ PrintingDriverDesc=Configuration variables for printing driver.
ListDrivers=List of drivers
PrintTestDesc=List of Printers.
FileWasSentToPrinter=File %s was sent to printer
-NoActivePrintingModuleFound=No active module to print document
+NoActivePrintingModuleFound=No active driver to print document. Check setup of module %s.
PleaseSelectaDriverfromList=Please select a driver from list.
PleaseConfigureDriverfromList=Please configure the selected driver from list.
SetupDriver=Driver setup
diff --git a/htdocs/langs/fr_FR/printing.lang b/htdocs/langs/fr_FR/printing.lang
index 734580af1cf..3e35b46ac00 100644
--- a/htdocs/langs/fr_FR/printing.lang
+++ b/htdocs/langs/fr_FR/printing.lang
@@ -9,7 +9,7 @@ PrintingDriverDesc=Paramètres de configuration pour le driver d'impression
ListDrivers=Liste des drivers
PrintTestDesc=Liste des imprimantes
FileWasSentToPrinter=Le fichier %s a été envoyé à l'imprimante
-NoActivePrintingModuleFound=Pas de module actif pour imprimer le document
+NoActivePrintingModuleFound=Pas de module actif pour imprimer le document. Vérifiez la configuration du module %s.
PleaseSelectaDriverfromList=Sélection un driver dans la liste
PleaseConfigureDriverfromList=Configurez le driver sélectionné depuis la liste
SetupDriver=Configuration du driver
diff --git a/htdocs/printing/admin/printing.php b/htdocs/printing/admin/printing.php
index 23a958211b2..e5892793c77 100644
--- a/htdocs/printing/admin/printing.php
+++ b/htdocs/printing/admin/printing.php
@@ -38,7 +38,7 @@ if (! $user->admin) accessforbidden();
$action = GETPOST('action','alpha');
$mode = GETPOST('mode','alpha');
-$value = GETPOST('value','alpha');
+$value = GETPOST('value','alpha',0,null,null,1); // The value may be __google__docs so we force disable of replace
$varname = GETPOST('varname', 'alpha');
$driver = GETPOST('driver', 'alpha');
@@ -123,7 +123,7 @@ if ($mode == 'setup' && $user->admin)
print '';
print '';
- dol_fiche_head($head, $mode, $langs->trans("ModuleSetup"), 0, 'technic');
+ dol_fiche_head($head, $mode, $langs->trans("ModuleSetup"), -1, 'technic');
print $langs->trans("PrintingDriverDesc".$driver)."
\n";
@@ -142,12 +142,12 @@ if ($mode == 'setup' && $user->admin)
$classname = 'printing_'.$driver;
$langs->load($driver);
$printer = new $classname($db);
-
+
$i=0;
$submit_enabled=0;
foreach ($printer->conf as $key)
{
-
+
switch ($key['type']) {
case "text":
case "password":
@@ -191,7 +191,7 @@ if ($mode == 'setup' && $user->admin)
break;
}
$i++;
-
+
if ($key['varname'] == 'PRINTGCP_TOKEN_ACCESS')
{
// Token
@@ -229,9 +229,9 @@ if ($mode == 'setup' && $user->admin)
}
print '';
-
+
dol_fiche_end();
-
+
if (! empty($driver))
{
if ($submit_enabled) {
@@ -243,7 +243,7 @@ if ($mode == 'setup' && $user->admin)
}
if ($mode == 'config' && $user->admin)
{
- dol_fiche_head($head, $mode, $langs->trans("ModuleSetup"), 0, 'technic');
+ dol_fiche_head($head, $mode, $langs->trans("ModuleSetup"), -1, 'technic');
print $langs->trans("PrintingDesc")."
\n";
@@ -265,7 +265,7 @@ if ($mode == 'config' && $user->admin)
$langs->load($driver);
$printer = new $classname($db);
//print '