Fix style and align when no permission on widget
This commit is contained in:
parent
884c6c674d
commit
58a407d9f1
@ -182,29 +182,29 @@ $formadmin = new FormAdmin($db);
|
|||||||
$wikihelp='EN:Setup|FR:Paramétrage|ES:Configuración';
|
$wikihelp='EN:Setup|FR:Paramétrage|ES:Configuración';
|
||||||
llxHeader('',$langs->trans("Setup"),$wikihelp);
|
llxHeader('',$langs->trans("Setup"),$wikihelp);
|
||||||
|
|
||||||
print load_fiche_titre($langs->trans("DefaultValues"),'','title_setup');
|
$param='&mode='.$mode;
|
||||||
|
|
||||||
print $langs->trans("DefaultValuesDesc")."<br>\n";
|
$enabledisablehtml.= $langs->trans("EnableDefaultValues").' ';
|
||||||
print "<br>\n";
|
|
||||||
|
|
||||||
print $langs->trans("EnableDefaultValues").' ';
|
|
||||||
if (empty($conf->global->MAIN_ENABLE_DEFAULT_VALUES))
|
if (empty($conf->global->MAIN_ENABLE_DEFAULT_VALUES))
|
||||||
{
|
{
|
||||||
// Button off, click to enable
|
// Button off, click to enable
|
||||||
print '<a class="reposition" href="'.$_SERVER["PHP_SELF"].'?action=setMAIN_ENABLE_DEFAULT_VALUES&value=1">';
|
$enabledisablehtml.= '<a class="reposition" href="'.$_SERVER["PHP_SELF"].'?action=setMAIN_ENABLE_DEFAULT_VALUES&value=1'.$param.'">';
|
||||||
print img_picto($langs->trans("Disabled"),'switch_off');
|
$enabledisablehtml.= img_picto($langs->trans("Disabled"),'switch_off');
|
||||||
print '</a>';
|
$enabledisablehtml.= '</a>';
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
// Button on, click to disable
|
// Button on, click to disable
|
||||||
print '<a class="reposition" href="'.$_SERVER["PHP_SELF"].'?action=setMAIN_ENABLE_DEFAULT_VALUES&value=0">';
|
$enabledisablehtml.= '<a class="reposition" href="'.$_SERVER["PHP_SELF"].'?action=setMAIN_ENABLE_DEFAULT_VALUES&value=0'.$param.'">';
|
||||||
print img_picto($langs->trans("Activated"),'switch_on');
|
$enabledisablehtml.= img_picto($langs->trans("Activated"),'switch_on');
|
||||||
print '</a>';
|
$enabledisablehtml.= '</a>';
|
||||||
}
|
}
|
||||||
print "<br><br>\n";
|
|
||||||
|
|
||||||
$param='&mode='.$mode;
|
print load_fiche_titre($langs->trans("DefaultValues"), $enabledisablehtml, 'title_setup');
|
||||||
|
|
||||||
|
print $langs->trans("DefaultValuesDesc")."<br>\n";
|
||||||
|
print "<br>\n";
|
||||||
|
|
||||||
if (! empty($contextpage) && $contextpage != $_SERVER["PHP_SELF"]) $param.='&contextpage='.$contextpage;
|
if (! empty($contextpage) && $contextpage != $_SERVER["PHP_SELF"]) $param.='&contextpage='.$contextpage;
|
||||||
if ($limit > 0 && $limit != $conf->liste_limit) $param.='&limit='.$limit;
|
if ($limit > 0 && $limit != $conf->liste_limit) $param.='&limit='.$limit;
|
||||||
if ($optioncss != '') $param.='&optioncss='.$optioncss;
|
if ($optioncss != '') $param.='&optioncss='.$optioncss;
|
||||||
|
|||||||
@ -100,7 +100,7 @@ $form=new Form($db);
|
|||||||
print '<form method="post" action="'.$_SERVER["PHP_SELF"].'?action=setvalue">';
|
print '<form method="post" action="'.$_SERVER["PHP_SELF"].'?action=setvalue">';
|
||||||
print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">';
|
print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">';
|
||||||
|
|
||||||
dol_fiche_head($head, 'ldap', $langs->trans("LDAPSetup"));
|
dol_fiche_head($head, 'ldap', $langs->trans("LDAPSetup"), -1);
|
||||||
|
|
||||||
print '<table class="noborder" width="100%">';
|
print '<table class="noborder" width="100%">';
|
||||||
|
|
||||||
@ -127,7 +127,7 @@ print '</td></tr>';
|
|||||||
// Synchro contact active
|
// Synchro contact active
|
||||||
if (! empty($conf->societe->enabled))
|
if (! empty($conf->societe->enabled))
|
||||||
{
|
{
|
||||||
|
|
||||||
print '<tr class="oddeven"><td>'.$langs->trans("LDAPDnContactActive").'</td><td>';
|
print '<tr class="oddeven"><td>'.$langs->trans("LDAPDnContactActive").'</td><td>';
|
||||||
$arraylist=array();
|
$arraylist=array();
|
||||||
$arraylist['0']=$langs->trans("No");
|
$arraylist['0']=$langs->trans("No");
|
||||||
@ -139,7 +139,7 @@ if (! empty($conf->societe->enabled))
|
|||||||
// Synchro member active
|
// Synchro member active
|
||||||
if (! empty($conf->adherent->enabled))
|
if (! empty($conf->adherent->enabled))
|
||||||
{
|
{
|
||||||
|
|
||||||
print '<tr class="oddeven"><td>'.$langs->trans("LDAPDnMemberActive").'</td><td>';
|
print '<tr class="oddeven"><td>'.$langs->trans("LDAPDnMemberActive").'</td><td>';
|
||||||
$arraylist=array();
|
$arraylist=array();
|
||||||
$arraylist['0']=$langs->trans("No");
|
$arraylist['0']=$langs->trans("No");
|
||||||
|
|||||||
@ -39,7 +39,7 @@ if (!$user->admin)
|
|||||||
accessforbidden();
|
accessforbidden();
|
||||||
|
|
||||||
$action = GETPOST('action','aZ09');
|
$action = GETPOST('action','aZ09');
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Actions
|
* Actions
|
||||||
*/
|
*/
|
||||||
@ -49,7 +49,7 @@ if ($action == 'setvalue' && $user->admin)
|
|||||||
$error=0;
|
$error=0;
|
||||||
|
|
||||||
$db->begin();
|
$db->begin();
|
||||||
|
|
||||||
if (! dolibarr_set_const($db, 'LDAP_CONTACT_DN',GETPOST("contactdn"),'chaine',0,'',$conf->entity)) $error++;
|
if (! dolibarr_set_const($db, 'LDAP_CONTACT_DN',GETPOST("contactdn"),'chaine',0,'',$conf->entity)) $error++;
|
||||||
if (! dolibarr_set_const($db, 'LDAP_CONTACT_OBJECT_CLASS',GETPOST("objectclass"),'chaine',0,'',$conf->entity)) $error++;
|
if (! dolibarr_set_const($db, 'LDAP_CONTACT_OBJECT_CLASS',GETPOST("objectclass"),'chaine',0,'',$conf->entity)) $error++;
|
||||||
|
|
||||||
@ -73,7 +73,7 @@ if ($action == 'setvalue' && $user->admin)
|
|||||||
$key=GETPOST("key");
|
$key=GETPOST("key");
|
||||||
if ($key) $valkey=$conf->global->$key;
|
if ($key) $valkey=$conf->global->$key;
|
||||||
if (! dolibarr_set_const($db, 'LDAP_KEY_CONTACTS',$valkey,'chaine',0,'',$conf->entity)) $error++;
|
if (! dolibarr_set_const($db, 'LDAP_KEY_CONTACTS',$valkey,'chaine',0,'',$conf->entity)) $error++;
|
||||||
|
|
||||||
if (! $error)
|
if (! $error)
|
||||||
{
|
{
|
||||||
$db->commit();
|
$db->commit();
|
||||||
@ -107,7 +107,7 @@ if (! function_exists("ldap_connect"))
|
|||||||
setEventMessages($langs->trans("LDAPFunctionsNotAvailableOnPHP"), null, 'errors');
|
setEventMessages($langs->trans("LDAPFunctionsNotAvailableOnPHP"), null, 'errors');
|
||||||
}
|
}
|
||||||
|
|
||||||
dol_fiche_head($head, 'contacts', $langs->trans("LDAPSetup"));
|
dol_fiche_head($head, 'contacts', $langs->trans("LDAPSetup"), -1);
|
||||||
|
|
||||||
|
|
||||||
print $langs->trans("LDAPDescContact").'<br>';
|
print $langs->trans("LDAPDescContact").'<br>';
|
||||||
|
|||||||
@ -5,7 +5,7 @@
|
|||||||
* Copyright (C) 2005 Regis Houssin <regis.houssin@capnetworks.com>
|
* Copyright (C) 2005 Regis Houssin <regis.houssin@capnetworks.com>
|
||||||
* Copyright (C) 2006-2011 Laurent Destailleur <eldy@users.sourceforge.net>
|
* Copyright (C) 2006-2011 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||||
* Copyright (C) 2011-2013 Juanjo Menent <jmenent@2byte.es>
|
* Copyright (C) 2011-2013 Juanjo Menent <jmenent@2byte.es>
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify
|
* This program is free software; you can redistribute it and/or modify
|
||||||
* it under the terms of the GNU General Public License as published by
|
* it under the terms of the GNU General Public License as published by
|
||||||
* the Free Software Foundation; either version 3 of the License, or
|
* the Free Software Foundation; either version 3 of the License, or
|
||||||
@ -38,7 +38,7 @@ $langs->load("errors");
|
|||||||
|
|
||||||
if (!$user->admin)
|
if (!$user->admin)
|
||||||
accessforbidden();
|
accessforbidden();
|
||||||
|
|
||||||
$action = GETPOST('action','aZ09');
|
$action = GETPOST('action','aZ09');
|
||||||
|
|
||||||
|
|
||||||
@ -50,7 +50,7 @@ if ($action == 'setvalue' && $user->admin)
|
|||||||
{
|
{
|
||||||
$error=0;
|
$error=0;
|
||||||
$db->begin();
|
$db->begin();
|
||||||
|
|
||||||
if (! dolibarr_set_const($db, 'LDAP_GROUP_DN',GETPOST("group"),'chaine',0,'',$conf->entity)) $error++;
|
if (! dolibarr_set_const($db, 'LDAP_GROUP_DN',GETPOST("group"),'chaine',0,'',$conf->entity)) $error++;
|
||||||
if (! dolibarr_set_const($db, 'LDAP_GROUP_OBJECT_CLASS',GETPOST("objectclass"),'chaine',0,'',$conf->entity)) $error++;
|
if (! dolibarr_set_const($db, 'LDAP_GROUP_OBJECT_CLASS',GETPOST("objectclass"),'chaine',0,'',$conf->entity)) $error++;
|
||||||
|
|
||||||
@ -64,7 +64,7 @@ if ($action == 'setvalue' && $user->admin)
|
|||||||
$key=GETPOST("key");
|
$key=GETPOST("key");
|
||||||
if ($key) $valkey=$conf->global->$key;
|
if ($key) $valkey=$conf->global->$key;
|
||||||
if (! dolibarr_set_const($db, 'LDAP_KEY_GROUPS',$valkey,'chaine',0,'',$conf->entity)) $error++;
|
if (! dolibarr_set_const($db, 'LDAP_KEY_GROUPS',$valkey,'chaine',0,'',$conf->entity)) $error++;
|
||||||
|
|
||||||
if (! $error)
|
if (! $error)
|
||||||
{
|
{
|
||||||
$db->commit();
|
$db->commit();
|
||||||
@ -96,7 +96,7 @@ if (! function_exists("ldap_connect"))
|
|||||||
setEventMessages($langs->trans("LDAPFunctionsNotAvailableOnPHP"), null, 'errors');
|
setEventMessages($langs->trans("LDAPFunctionsNotAvailableOnPHP"), null, 'errors');
|
||||||
}
|
}
|
||||||
|
|
||||||
dol_fiche_head($head, 'groups', $langs->trans("LDAPSetup"));
|
dol_fiche_head($head, 'groups', $langs->trans("LDAPSetup"), -1);
|
||||||
|
|
||||||
|
|
||||||
print $langs->trans("LDAPDescGroups").'<br>';
|
print $langs->trans("LDAPDescGroups").'<br>';
|
||||||
|
|||||||
@ -5,7 +5,7 @@
|
|||||||
* Copyright (C) 2005 Regis Houssin <regis.houssin@capnetworks.com>
|
* Copyright (C) 2005 Regis Houssin <regis.houssin@capnetworks.com>
|
||||||
* Copyright (C) 2006-2008 Laurent Destailleur <eldy@users.sourceforge.net>
|
* Copyright (C) 2006-2008 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||||
* Copyright (C) 2011-2013 Juanjo Menent <jmenent@2byte.es>
|
* Copyright (C) 2011-2013 Juanjo Menent <jmenent@2byte.es>
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify
|
* This program is free software; you can redistribute it and/or modify
|
||||||
* it under the terms of the GNU General Public License as published by
|
* it under the terms of the GNU General Public License as published by
|
||||||
* the Free Software Foundation; either version 3 of the License, or
|
* the Free Software Foundation; either version 3 of the License, or
|
||||||
@ -50,7 +50,7 @@ if ($action == 'setvalue' && $user->admin)
|
|||||||
$error=0;
|
$error=0;
|
||||||
|
|
||||||
$db->begin();
|
$db->begin();
|
||||||
|
|
||||||
if (! dolibarr_set_const($db, 'LDAP_MEMBER_DN',GETPOST("user"),'chaine',0,'',$conf->entity)) $error++;
|
if (! dolibarr_set_const($db, 'LDAP_MEMBER_DN',GETPOST("user"),'chaine',0,'',$conf->entity)) $error++;
|
||||||
if (! dolibarr_set_const($db, 'LDAP_MEMBER_OBJECT_CLASS',GETPOST("objectclass"),'chaine',0,'',$conf->entity)) $error++;
|
if (! dolibarr_set_const($db, 'LDAP_MEMBER_OBJECT_CLASS',GETPOST("objectclass"),'chaine',0,'',$conf->entity)) $error++;
|
||||||
if (! dolibarr_set_const($db, 'LDAP_MEMBER_FILTER',GETPOST("filterconnection"),'chaine',0,'',$conf->entity)) $error++;
|
if (! dolibarr_set_const($db, 'LDAP_MEMBER_FILTER',GETPOST("filterconnection"),'chaine',0,'',$conf->entity)) $error++;
|
||||||
@ -126,7 +126,7 @@ if (! function_exists("ldap_connect"))
|
|||||||
print '<form method="post" action="'.$_SERVER["PHP_SELF"].'?action=setvalue">';
|
print '<form method="post" action="'.$_SERVER["PHP_SELF"].'?action=setvalue">';
|
||||||
print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">';
|
print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">';
|
||||||
|
|
||||||
dol_fiche_head($head, 'members', $langs->trans("LDAPSetup"));
|
dol_fiche_head($head, 'members', $langs->trans("LDAPSetup"), -1);
|
||||||
|
|
||||||
|
|
||||||
print $langs->trans("LDAPDescMembers").'<br>';
|
print $langs->trans("LDAPDescMembers").'<br>';
|
||||||
|
|||||||
@ -113,7 +113,7 @@ print '<form method="post" action="'.$_SERVER["PHP_SELF"].'?action=setvalue">';
|
|||||||
print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">';
|
print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">';
|
||||||
|
|
||||||
|
|
||||||
dol_fiche_head($head, 'users', $langs->trans("LDAPSetup"));
|
dol_fiche_head($head, 'users', $langs->trans("LDAPSetup"), -1);
|
||||||
|
|
||||||
print $langs->trans("LDAPDescUsers").'<br>';
|
print $langs->trans("LDAPDescUsers").'<br>';
|
||||||
print '<br>';
|
print '<br>';
|
||||||
|
|||||||
@ -187,11 +187,11 @@ if ($result)
|
|||||||
|
|
||||||
|
|
||||||
print '<tr class="oddeven">';
|
print '<tr class="oddeven">';
|
||||||
print '<td>'
|
print '<td>';
|
||||||
print img_object('',$picto,'class="pictoobjectwidth"').' '.$objMod->getName();
|
print img_object('',$picto,'class="pictoobjectwidth"').' '.$objMod->getName();
|
||||||
print '<a name="'.$objMod->getName().'"> </a>';
|
print '<a name="'.$objMod->getName().'"> </a>';
|
||||||
print '</td>';
|
print '</td>';
|
||||||
|
|
||||||
$perm_libelle=($conf->global->MAIN_USE_ADVANCED_PERMS && ($langs->trans("PermissionAdvanced".$obj->id)!=("PermissionAdvanced".$obj->id))?$langs->trans("PermissionAdvanced".$obj->id):(($langs->trans("Permission".$obj->id)!=("Permission".$obj->id))?$langs->trans("Permission".$obj->id):$obj->libelle));
|
$perm_libelle=($conf->global->MAIN_USE_ADVANCED_PERMS && ($langs->trans("PermissionAdvanced".$obj->id)!=("PermissionAdvanced".$obj->id))?$langs->trans("PermissionAdvanced".$obj->id):(($langs->trans("Permission".$obj->id)!=("Permission".$obj->id))?$langs->trans("Permission".$obj->id):$obj->libelle));
|
||||||
print '<td>'.$perm_libelle. '</td>';
|
print '<td>'.$perm_libelle. '</td>';
|
||||||
|
|
||||||
|
|||||||
@ -107,7 +107,7 @@ if ($action == 'add' || (GETPOST('add') && $action != 'update'))
|
|||||||
if (! $error)
|
if (! $error)
|
||||||
{
|
{
|
||||||
$db->begin();
|
$db->begin();
|
||||||
|
|
||||||
$sql = "INSERT INTO ".MAIN_DB_PREFIX."overwrite_trans(lang, transkey, transvalue, entity) VALUES ('".$db->escape($langcode)."','".$db->escape($transkey)."','".$db->escape($transvalue)."', ".$db->escape($conf->entity).")";
|
$sql = "INSERT INTO ".MAIN_DB_PREFIX."overwrite_trans(lang, transkey, transvalue, entity) VALUES ('".$db->escape($langcode)."','".$db->escape($transkey)."','".$db->escape($transvalue)."', ".$db->escape($conf->entity).")";
|
||||||
$result = $db->query($sql);
|
$result = $db->query($sql);
|
||||||
if ($result > 0)
|
if ($result > 0)
|
||||||
@ -126,7 +126,7 @@ if ($action == 'add' || (GETPOST('add') && $action != 'update'))
|
|||||||
{
|
{
|
||||||
setEventMessages($langs->trans("WarningAnEntryAlreadyExistForTransKey"), null, 'warnings');
|
setEventMessages($langs->trans("WarningAnEntryAlreadyExistForTransKey"), null, 'warnings');
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
setEventMessages($db->lasterror(), null, 'errors');
|
setEventMessages($db->lasterror(), null, 'errors');
|
||||||
}
|
}
|
||||||
@ -164,7 +164,25 @@ $formadmin = new FormAdmin($db);
|
|||||||
$wikihelp='EN:Setup|FR:Paramétrage|ES:Configuración';
|
$wikihelp='EN:Setup|FR:Paramétrage|ES:Configuración';
|
||||||
llxHeader('',$langs->trans("Setup"),$wikihelp);
|
llxHeader('',$langs->trans("Setup"),$wikihelp);
|
||||||
|
|
||||||
print load_fiche_titre($langs->trans("Translation"),'','title_setup');
|
$param='&mode='.$mode;
|
||||||
|
|
||||||
|
$enabledisablehtml = $langs->trans("EnableOverwriteTranslation").' ';
|
||||||
|
if (empty($conf->global->MAIN_ENABLE_OVERWRITE_TRANSLATION))
|
||||||
|
{
|
||||||
|
// Button off, click to enable
|
||||||
|
$enabledisablehtml.='<a class="reposition" href="'.$_SERVER["PHP_SELF"].'?action=setMAIN_ENABLE_OVERWRITE_TRANSLATION&value=1'.$param.'">';
|
||||||
|
$enabledisablehtml.=img_picto($langs->trans("Disabled"),'switch_off');
|
||||||
|
$enabledisablehtml.='</a>';
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
// Button on, click to disable
|
||||||
|
$enabledisablehtml.='<a class="reposition" href="'.$_SERVER["PHP_SELF"].'?action=setMAIN_ENABLE_OVERWRITE_TRANSLATION&value=0'.$param.'">';
|
||||||
|
$enabledisablehtml.=img_picto($langs->trans("Activated"),'switch_on');
|
||||||
|
$enabledisablehtml.='</a>';
|
||||||
|
}
|
||||||
|
|
||||||
|
print load_fiche_titre($langs->trans("Translation"), $enabledisablehtml, 'title_setup');
|
||||||
|
|
||||||
print $langs->trans("TranslationDesc")."<br>\n";
|
print $langs->trans("TranslationDesc")."<br>\n";
|
||||||
print "<br>\n";
|
print "<br>\n";
|
||||||
@ -175,25 +193,6 @@ print $langs->trans("CurrentUserLanguage").': <strong>'.$s.' '.$current_language
|
|||||||
|
|
||||||
print '<br>';
|
print '<br>';
|
||||||
|
|
||||||
print $langs->trans("EnableOverwriteTranslation").' ';
|
|
||||||
if (empty($conf->global->MAIN_ENABLE_OVERWRITE_TRANSLATION))
|
|
||||||
{
|
|
||||||
// Button off, click to enable
|
|
||||||
print '<a class="reposition" href="'.$_SERVER["PHP_SELF"].'?action=setMAIN_ENABLE_OVERWRITE_TRANSLATION&value=1">';
|
|
||||||
print img_picto($langs->trans("Disabled"),'switch_off');
|
|
||||||
print '</a>';
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
// Button on, click to disable
|
|
||||||
print '<a class="reposition" href="'.$_SERVER["PHP_SELF"].'?action=setMAIN_ENABLE_OVERWRITE_TRANSLATION&value=0">';
|
|
||||||
print img_picto($langs->trans("Activated"),'switch_on');
|
|
||||||
print '</a>';
|
|
||||||
}
|
|
||||||
|
|
||||||
print '<br><br>';
|
|
||||||
|
|
||||||
$param='&mode='.$mode;
|
|
||||||
if (! empty($contextpage) && $contextpage != $_SERVER["PHP_SELF"]) $param.='&contextpage='.$contextpage;
|
if (! empty($contextpage) && $contextpage != $_SERVER["PHP_SELF"]) $param.='&contextpage='.$contextpage;
|
||||||
if ($limit > 0 && $limit != $conf->liste_limit) $param.='&limit='.$limit;
|
if ($limit > 0 && $limit != $conf->liste_limit) $param.='&limit='.$limit;
|
||||||
if ($optioncss != '') $param.='&optioncss='.$optioncss;
|
if ($optioncss != '') $param.='&optioncss='.$optioncss;
|
||||||
@ -225,12 +224,12 @@ if ($mode == 'overwrite')
|
|||||||
print $langs->trans("TranslationOverwriteDesc",$langs->transnoentitiesnoconv("Language"),$langs->transnoentitiesnoconv("Key"),$langs->transnoentitiesnoconv("NewTranslationStringToShow"))."\n";
|
print $langs->trans("TranslationOverwriteDesc",$langs->transnoentitiesnoconv("Language"),$langs->transnoentitiesnoconv("Key"),$langs->transnoentitiesnoconv("NewTranslationStringToShow"))."\n";
|
||||||
print ' ('.$langs->trans("TranslationOverwriteDesc2").').'."<br>\n";
|
print ' ('.$langs->trans("TranslationOverwriteDesc2").').'."<br>\n";
|
||||||
print '<br>';
|
print '<br>';
|
||||||
|
|
||||||
|
|
||||||
print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">';
|
print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">';
|
||||||
print '<input type="hidden" id="action" name="action" value="">';
|
print '<input type="hidden" id="action" name="action" value="">';
|
||||||
print '<input type="hidden" id="mode" name="mode" value="'.$mode.'">';
|
print '<input type="hidden" id="mode" name="mode" value="'.$mode.'">';
|
||||||
|
|
||||||
print '<table class="noborder" width="100%">';
|
print '<table class="noborder" width="100%">';
|
||||||
print '<tr class="liste_titre">';
|
print '<tr class="liste_titre">';
|
||||||
print_liste_field_titre($langs->trans("Language").' (en_US, es_MX, ...)',$_SERVER["PHP_SELF"],'lang,transkey','',$param,'',$sortfield,$sortorder);
|
print_liste_field_titre($langs->trans("Language").' (en_US, es_MX, ...)',$_SERVER["PHP_SELF"],'lang,transkey','',$param,'',$sortfield,$sortorder);
|
||||||
@ -239,11 +238,11 @@ if ($mode == 'overwrite')
|
|||||||
//if (! empty($conf->multicompany->enabled) && !$user->entity) print_liste_field_titre($langs->trans("Entity"),$_SERVER["PHP_SELF"],'entity,transkey','',$param,'',$sortfield,$sortorder);
|
//if (! empty($conf->multicompany->enabled) && !$user->entity) print_liste_field_titre($langs->trans("Entity"),$_SERVER["PHP_SELF"],'entity,transkey','',$param,'',$sortfield,$sortorder);
|
||||||
print '<td align="center"></td>';
|
print '<td align="center"></td>';
|
||||||
print "</tr>\n";
|
print "</tr>\n";
|
||||||
|
|
||||||
|
|
||||||
// Line to add new record
|
// Line to add new record
|
||||||
print "\n";
|
print "\n";
|
||||||
|
|
||||||
print '<tr class="oddeven"><td>';
|
print '<tr class="oddeven"><td>';
|
||||||
print $formadmin->select_language(GETPOST('langcode'), 'langcode', 0, null, 1, 0, 0, 'maxwidthonsmartphone', 1);
|
print $formadmin->select_language(GETPOST('langcode'), 'langcode', 0, null, 1, 0, 0, 'maxwidthonsmartphone', 1);
|
||||||
print '</td>'."\n";
|
print '</td>'."\n";
|
||||||
@ -270,33 +269,33 @@ if ($mode == 'overwrite')
|
|||||||
print '<input type="submit" class="button"'.$disabled.' value="'.$langs->trans("Add").'" name="add">';
|
print '<input type="submit" class="button"'.$disabled.' value="'.$langs->trans("Add").'" name="add">';
|
||||||
print "</td>\n";
|
print "</td>\n";
|
||||||
print '</tr>';
|
print '</tr>';
|
||||||
|
|
||||||
|
|
||||||
// Show constants
|
// Show constants
|
||||||
$sql = "SELECT rowid, entity, lang, transkey, transvalue";
|
$sql = "SELECT rowid, entity, lang, transkey, transvalue";
|
||||||
$sql.= " FROM ".MAIN_DB_PREFIX."overwrite_trans";
|
$sql.= " FROM ".MAIN_DB_PREFIX."overwrite_trans";
|
||||||
$sql.= " WHERE 1 = 1";
|
$sql.= " WHERE 1 = 1";
|
||||||
//$sql.= " AND entity IN (".$user->entity.",".$conf->entity.")";
|
//$sql.= " AND entity IN (".$user->entity.",".$conf->entity.")";
|
||||||
$sql.= $db->order($sortfield, $sortorder);
|
$sql.= $db->order($sortfield, $sortorder);
|
||||||
|
|
||||||
dol_syslog("translation::select from table", LOG_DEBUG);
|
dol_syslog("translation::select from table", LOG_DEBUG);
|
||||||
$result = $db->query($sql);
|
$result = $db->query($sql);
|
||||||
if ($result)
|
if ($result)
|
||||||
{
|
{
|
||||||
$num = $db->num_rows($result);
|
$num = $db->num_rows($result);
|
||||||
$i = 0;
|
$i = 0;
|
||||||
|
|
||||||
while ($i < $num)
|
while ($i < $num)
|
||||||
{
|
{
|
||||||
$obj = $db->fetch_object($result);
|
$obj = $db->fetch_object($result);
|
||||||
|
|
||||||
print "\n";
|
print "\n";
|
||||||
|
|
||||||
print '<tr class="oddeven">';
|
print '<tr class="oddeven">';
|
||||||
|
|
||||||
print '<td>'.$obj->lang.'</td>'."\n";
|
print '<td>'.$obj->lang.'</td>'."\n";
|
||||||
print '<td>'.$obj->transkey.'</td>'."\n";
|
print '<td>'.$obj->transkey.'</td>'."\n";
|
||||||
|
|
||||||
// Value
|
// Value
|
||||||
print '<td>';
|
print '<td>';
|
||||||
/*print '<input type="hidden" name="const['.$i.'][rowid]" value="'.$obj->rowid.'">';
|
/*print '<input type="hidden" name="const['.$i.'][rowid]" value="'.$obj->rowid.'">';
|
||||||
@ -306,18 +305,18 @@ if ($mode == 'overwrite')
|
|||||||
*/
|
*/
|
||||||
print $obj->transvalue;
|
print $obj->transvalue;
|
||||||
print '</td>';
|
print '</td>';
|
||||||
|
|
||||||
print '<td align="center">';
|
print '<td align="center">';
|
||||||
print '<a href="'.$_SERVER['PHP_SELF'].'?rowid='.$obj->rowid.'&entity='.$obj->entity.'&action=delete'.((empty($user->entity) && $debug)?'&debug=1':'').'">'.img_delete().'</a>';
|
print '<a href="'.$_SERVER['PHP_SELF'].'?rowid='.$obj->rowid.'&entity='.$obj->entity.'&action=delete'.((empty($user->entity) && $debug)?'&debug=1':'').'">'.img_delete().'</a>';
|
||||||
print '</td>';
|
print '</td>';
|
||||||
|
|
||||||
print "</tr>\n";
|
print "</tr>\n";
|
||||||
print "\n";
|
print "\n";
|
||||||
$i++;
|
$i++;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
print '</table>';
|
print '</table>';
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -325,15 +324,15 @@ if ($mode == 'overwrite')
|
|||||||
if ($mode == 'searchkey')
|
if ($mode == 'searchkey')
|
||||||
{
|
{
|
||||||
$langcode=GETPOST('langcode')?GETPOST('langcode'):$langs->defaultlang;
|
$langcode=GETPOST('langcode')?GETPOST('langcode'):$langs->defaultlang;
|
||||||
|
|
||||||
$newlang=new Translate('',$conf);
|
$newlang=new Translate('',$conf);
|
||||||
$newlang->setDefaultLang($langcode);
|
$newlang->setDefaultLang($langcode);
|
||||||
|
|
||||||
$newlangfileonly=new Translate('',$conf);
|
$newlangfileonly=new Translate('',$conf);
|
||||||
$newlangfileonly->setDefaultLang($langcode);
|
$newlangfileonly->setDefaultLang($langcode);
|
||||||
|
|
||||||
$recordtoshow=array();
|
$recordtoshow=array();
|
||||||
|
|
||||||
$nbempty=0;
|
$nbempty=0;
|
||||||
/*var_dump($langcode);
|
/*var_dump($langcode);
|
||||||
var_dump($transkey);
|
var_dump($transkey);
|
||||||
@ -353,9 +352,9 @@ if ($mode == 'searchkey')
|
|||||||
// Directory of translation files
|
// Directory of translation files
|
||||||
$dir_lang = $searchdir."/langs/".$langcode;
|
$dir_lang = $searchdir."/langs/".$langcode;
|
||||||
$dir_lang_osencoded=dol_osencode($dir_lang);
|
$dir_lang_osencoded=dol_osencode($dir_lang);
|
||||||
|
|
||||||
$filearray=dol_dir_list($dir_lang_osencoded,'files',0,'','',$sortfield,(strtolower($sortorder)=='asc'?SORT_ASC:SORT_DESC),1);
|
$filearray=dol_dir_list($dir_lang_osencoded,'files',0,'','',$sortfield,(strtolower($sortorder)=='asc'?SORT_ASC:SORT_DESC),1);
|
||||||
|
|
||||||
foreach($filearray as $file)
|
foreach($filearray as $file)
|
||||||
{
|
{
|
||||||
$tmpfile=preg_replace('/.lang/i', '', basename($file['name']));
|
$tmpfile=preg_replace('/.lang/i', '', basename($file['name']));
|
||||||
@ -364,7 +363,7 @@ if ($mode == 'searchkey')
|
|||||||
//print 'After loading lang '.$tmpfile.', newlang has '.count($newlang->tab_translate).' records<br>'."\n";
|
//print 'After loading lang '.$tmpfile.', newlang has '.count($newlang->tab_translate).' records<br>'."\n";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// Now search into translation array
|
// Now search into translation array
|
||||||
foreach($newlang->tab_translate as $key => $val)
|
foreach($newlang->tab_translate as $key => $val)
|
||||||
{
|
{
|
||||||
@ -373,13 +372,13 @@ if ($mode == 'searchkey')
|
|||||||
$recordtoshow[$key]=$val;
|
$recordtoshow[$key]=$val;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
//print '<br>';
|
//print '<br>';
|
||||||
$nbtotalofrecordswithoutfilters = count($newlang->tab_translate);
|
$nbtotalofrecordswithoutfilters = count($newlang->tab_translate);
|
||||||
$nbtotalofrecords = count($recordtoshow);
|
$nbtotalofrecords = count($recordtoshow);
|
||||||
$num = $limit + 1;
|
$num = $limit + 1;
|
||||||
if (($offset + $num) > $nbtotalofrecords) $num = $limit;
|
if (($offset + $num) > $nbtotalofrecords) $num = $limit;
|
||||||
|
|
||||||
//print 'param='.$param.' $_SERVER["PHP_SELF"]='.$_SERVER["PHP_SELF"].' num='.$num.' page='.$page.' nbtotalofrecords='.$nbtotalofrecords." sortfield=".$sortfield." sortorder=".$sortorder;
|
//print 'param='.$param.' $_SERVER["PHP_SELF"]='.$_SERVER["PHP_SELF"].' num='.$num.' page='.$page.' nbtotalofrecords='.$nbtotalofrecords." sortfield=".$sortfield." sortorder=".$sortorder;
|
||||||
$title = $langs->trans("TranslationKeySearch");
|
$title = $langs->trans("TranslationKeySearch");
|
||||||
if ($nbtotalofrecords > 0) $title.=' ('.$nbtotalofrecords.' / '.$nbtotalofrecordswithoutfilters.')';
|
if ($nbtotalofrecords > 0) $title.=' ('.$nbtotalofrecords.' / '.$nbtotalofrecordswithoutfilters.')';
|
||||||
@ -419,19 +418,19 @@ if ($mode == 'searchkey')
|
|||||||
{*/
|
{*/
|
||||||
print '<input type="hidden" name="entitysearch" value="'.$conf->entity.'">';
|
print '<input type="hidden" name="entitysearch" value="'.$conf->entity.'">';
|
||||||
//}
|
//}
|
||||||
print '</td>';
|
print '</td>';
|
||||||
// Action column
|
// Action column
|
||||||
print '<td class="liste_titre nowrap" align="right">';
|
print '<td class="liste_titre nowrap" align="right">';
|
||||||
$searchpicto=$form->showFilterAndCheckAddButtons($massactionbutton?1:0, 'checkforselect', 1);
|
$searchpicto=$form->showFilterAndCheckAddButtons($massactionbutton?1:0, 'checkforselect', 1);
|
||||||
print $searchpicto;
|
print $searchpicto;
|
||||||
print '</td>';
|
print '</td>';
|
||||||
print '</tr>';
|
print '</tr>';
|
||||||
|
|
||||||
if ($sortfield == 'transkey' && strtolower($sortorder) == 'asc') ksort($recordtoshow);
|
if ($sortfield == 'transkey' && strtolower($sortorder) == 'asc') ksort($recordtoshow);
|
||||||
if ($sortfield == 'transkey' && strtolower($sortorder) == 'desc') krsort($recordtoshow);
|
if ($sortfield == 'transkey' && strtolower($sortorder) == 'desc') krsort($recordtoshow);
|
||||||
if ($sortfield == 'transvalue' && strtolower($sortorder) == 'asc') asort($recordtoshow);
|
if ($sortfield == 'transvalue' && strtolower($sortorder) == 'asc') asort($recordtoshow);
|
||||||
if ($sortfield == 'transvalue' && strtolower($sortorder) == 'desc') arsort($recordtoshow);
|
if ($sortfield == 'transvalue' && strtolower($sortorder) == 'desc') arsort($recordtoshow);
|
||||||
|
|
||||||
// Show result
|
// Show result
|
||||||
$i=0;
|
$i=0;
|
||||||
foreach($recordtoshow as $key => $val)
|
foreach($recordtoshow as $key => $val)
|
||||||
@ -444,7 +443,7 @@ if ($mode == 'searchkey')
|
|||||||
print '</td><td align="right">';
|
print '</td><td align="right">';
|
||||||
if (! empty($newlangfileonly->tab_translate[$key]))
|
if (! empty($newlangfileonly->tab_translate[$key]))
|
||||||
{
|
{
|
||||||
if ($val != $newlangfileonly->tab_translate[$key])
|
if ($val != $newlangfileonly->tab_translate[$key])
|
||||||
{
|
{
|
||||||
$htmltext = $langs->trans("OriginalValueWas", $newlangfileonly->tab_translate[$key]);
|
$htmltext = $langs->trans("OriginalValueWas", $newlangfileonly->tab_translate[$key]);
|
||||||
print $form->textwithpicto('', $htmltext, 1, 'info');
|
print $form->textwithpicto('', $htmltext, 1, 'info');
|
||||||
|
|||||||
@ -156,8 +156,8 @@ class box_actions extends ModeleBoxes
|
|||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
$this->info_box_contents[0][0] = array(
|
$this->info_box_contents[0][0] = array(
|
||||||
'align' => 'left',
|
'td' => 'align="left" class="nohover opacitymedium"',
|
||||||
'text' => $langs->trans("ReadPermissionNotAllowed"),
|
'text' => $langs->trans("ReadPermissionNotAllowed")
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -191,7 +191,7 @@ class box_actions extends ModeleBoxes
|
|||||||
// on affiche que les évènement du jours ou passé
|
// on affiche que les évènement du jours ou passé
|
||||||
// qui ne sont pas à 100%
|
// qui ne sont pas à 100%
|
||||||
$actioncejour=true;
|
$actioncejour=true;
|
||||||
|
|
||||||
// TR
|
// TR
|
||||||
$logo=$contents[$line][0]['logo'];
|
$logo=$contents[$line][0]['logo'];
|
||||||
$label=$contents[$line][1]['text'];
|
$label=$contents[$line][1]['text'];
|
||||||
|
|||||||
@ -124,8 +124,8 @@ class box_bookmarks extends ModeleBoxes
|
|||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
$this->info_box_contents[0][0] = array(
|
$this->info_box_contents[0][0] = array(
|
||||||
'align' => 'left',
|
'td' => 'align="left" class="nohover opacitymedium"',
|
||||||
'text' => $langs->trans("ReadPermissionNotAllowed"),
|
'text' => $langs->trans("ReadPermissionNotAllowed")
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -146,8 +146,10 @@ class box_clients extends ModeleBoxes
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
$this->info_box_contents[0][0] = array('align' => 'left',
|
$this->info_box_contents[0][0] = array(
|
||||||
'text' => $langs->trans("ReadPermissionNotAllowed"));
|
'td' => 'align="left" class="nohover opacitymedium"',
|
||||||
|
'text' => $langs->trans("ReadPermissionNotAllowed")
|
||||||
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@ -165,8 +165,8 @@ class box_commandes extends ModeleBoxes
|
|||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
$this->info_box_contents[0][0] = array(
|
$this->info_box_contents[0][0] = array(
|
||||||
'align' => 'left',
|
'td' => 'align="left" class="nohover opacitymedium"',
|
||||||
'text' => $langs->trans("ReadPermissionNotAllowed"),
|
'text' => $langs->trans("ReadPermissionNotAllowed")
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -158,8 +158,8 @@ class box_comptes extends ModeleBoxes
|
|||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
$this->info_box_contents[0][0] = array(
|
$this->info_box_contents[0][0] = array(
|
||||||
'td' => '',
|
'td' => 'align="left" class="nohover opacitymedium"',
|
||||||
'text' => $langs->trans("ReadPermissionNotAllowed"),
|
'text' => $langs->trans("ReadPermissionNotAllowed")
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -151,8 +151,8 @@ class box_contacts extends ModeleBoxes
|
|||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
$this->info_box_contents[0][0] = array(
|
$this->info_box_contents[0][0] = array(
|
||||||
'align' => 'left',
|
'td' => 'align="left" class="nohover opacitymedium"',
|
||||||
'text' => $langs->trans("ReadPermissionNotAllowed"),
|
'text' => $langs->trans("ReadPermissionNotAllowed")
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -134,7 +134,7 @@ class box_contracts extends ModeleBoxes
|
|||||||
|
|
||||||
if ($num==0)
|
if ($num==0)
|
||||||
$this->info_box_contents[$line][0] = array(
|
$this->info_box_contents[$line][0] = array(
|
||||||
'td' => 'align="center"',
|
'td' => 'align="center opacitymedium"',
|
||||||
'text'=>$langs->trans("NoRecordedContracts"),
|
'text'=>$langs->trans("NoRecordedContracts"),
|
||||||
);
|
);
|
||||||
|
|
||||||
@ -148,8 +148,8 @@ class box_contracts extends ModeleBoxes
|
|||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
$this->info_box_contents[0][0] = array(
|
$this->info_box_contents[0][0] = array(
|
||||||
'td' => '',
|
'td' => 'align="left" class="nohover opacitymedium"',
|
||||||
'text' => $langs->trans("ReadPermissionNotAllowed"),
|
'text' => $langs->trans("ReadPermissionNotAllowed")
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -169,8 +169,8 @@ class box_factures extends ModeleBoxes
|
|||||||
|
|
||||||
} else {
|
} else {
|
||||||
$this->info_box_contents[0][0] = array(
|
$this->info_box_contents[0][0] = array(
|
||||||
'td' => '',
|
'td' => 'align="left" class="nohover opacitymedium"',
|
||||||
'text' => $langs->trans("ReadPermissionNotAllowed"),
|
'text' => $langs->trans("ReadPermissionNotAllowed")
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -178,8 +178,8 @@ class box_factures_fourn extends ModeleBoxes
|
|||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
$this->info_box_contents[0][0] = array(
|
$this->info_box_contents[0][0] = array(
|
||||||
'td' => '',
|
'td' => 'align="left" class="nohover opacitymedium"',
|
||||||
'text' => $langs->transnoentities("ReadPermissionNotAllowed"),
|
'text' => $langs->transnoentities("ReadPermissionNotAllowed")
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -168,8 +168,8 @@ class box_factures_fourn_imp extends ModeleBoxes
|
|||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
$this->info_box_contents[0][0] = array(
|
$this->info_box_contents[0][0] = array(
|
||||||
'td' => '',
|
'td' => 'align="left" class="nohover opacitymedium"',
|
||||||
'text' => $langs->trans("ReadPermissionNotAllowed"),
|
'text' => $langs->trans("ReadPermissionNotAllowed")
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -172,8 +172,8 @@ class box_factures_imp extends ModeleBoxes
|
|||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
$this->info_box_contents[0][0] = array(
|
$this->info_box_contents[0][0] = array(
|
||||||
'td' => '',
|
'td' => 'align="left" class="nohover opacitymedium"',
|
||||||
'text' => $langs->trans("ReadPermissionNotAllowed"),
|
'text' => $langs->trans("ReadPermissionNotAllowed")
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -134,8 +134,10 @@ class box_ficheinter extends ModeleBoxes
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
$this->info_box_contents[0][0] = array('td' => '',
|
$this->info_box_contents[0][0] = array(
|
||||||
'text' => $langs->trans("ReadPermissionNotAllowed"));
|
'td' => 'align="left" class="nohover opacitymedium"',
|
||||||
|
'text' => $langs->trans("ReadPermissionNotAllowed")
|
||||||
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -127,8 +127,8 @@ class box_fournisseurs extends ModeleBoxes
|
|||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
$this->info_box_contents[0][0] = array(
|
$this->info_box_contents[0][0] = array(
|
||||||
'td' => '',
|
'td' => 'align="left" class="nohover opacitymedium"',
|
||||||
'text' => $langs->trans("ReadPermissionNotAllowed"),
|
'text' => $langs->trans("ReadPermissionNotAllowed")
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -59,7 +59,7 @@ class box_goodcustomers extends ModeleBoxes
|
|||||||
|
|
||||||
// disable box for such cases
|
// disable box for such cases
|
||||||
if (! empty($conf->global->SOCIETE_DISABLE_CUSTOMERS)) $this->enabled=0; // disabled by this option
|
if (! empty($conf->global->SOCIETE_DISABLE_CUSTOMERS)) $this->enabled=0; // disabled by this option
|
||||||
if (empty($conf->global->MAIN_BOX_ENABLE_BEST_CUSTOMERS)) $this->enabled=0; // not enabled by default. Very slow on large database
|
if (empty($conf->global->MAIN_BOX_ENABLE_BEST_CUSTOMERS)) $this->enabled=0; // not enabled by default. Very slow on large database
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -148,8 +148,10 @@ class box_goodcustomers extends ModeleBoxes
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
$this->info_box_contents[0][0] = array('align' => 'left',
|
$this->info_box_contents[0][0] = array(
|
||||||
'text' => $langs->trans("ReadPermissionNotAllowed"));
|
'td' => 'align="left" class="nohover opacitymedium"',
|
||||||
|
'text' => $langs->trans("ReadPermissionNotAllowed")
|
||||||
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@ -133,7 +133,7 @@ class box_graph_invoices_permonth extends ModeleBoxes
|
|||||||
if (! $mesg)
|
if (! $mesg)
|
||||||
{
|
{
|
||||||
$langs->load("bills");
|
$langs->load("bills");
|
||||||
|
|
||||||
$px1->SetData($data1);
|
$px1->SetData($data1);
|
||||||
unset($data1);
|
unset($data1);
|
||||||
$px1->SetPrecisionY(0);
|
$px1->SetPrecisionY(0);
|
||||||
@ -255,8 +255,10 @@ class box_graph_invoices_permonth extends ModeleBoxes
|
|||||||
|
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
$this->info_box_contents[0][0] = array('td' => '',
|
$this->info_box_contents[0][0] = array(
|
||||||
'text' => $langs->trans("ReadPermissionNotAllowed"));
|
'td' => 'align="left" class="nohover opacitymedium"',
|
||||||
|
'text' => $langs->trans("ReadPermissionNotAllowed")
|
||||||
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -132,7 +132,7 @@ class box_graph_invoices_supplier_permonth extends ModeleBoxes
|
|||||||
if (! $mesg)
|
if (! $mesg)
|
||||||
{
|
{
|
||||||
$langs->load("bills");
|
$langs->load("bills");
|
||||||
|
|
||||||
$px1->SetData($data1);
|
$px1->SetData($data1);
|
||||||
unset($data1);
|
unset($data1);
|
||||||
$px1->SetPrecisionY(0);
|
$px1->SetPrecisionY(0);
|
||||||
@ -254,8 +254,10 @@ class box_graph_invoices_supplier_permonth extends ModeleBoxes
|
|||||||
|
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
$this->info_box_contents[0][0] = array('td' => '',
|
$this->info_box_contents[0][0] = array(
|
||||||
'text' => $langs->trans("ReadPermissionNotAllowed"));
|
'td' => 'align="left" class="nohover opacitymedium"',
|
||||||
|
'text' => $langs->trans("ReadPermissionNotAllowed")
|
||||||
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -253,8 +253,10 @@ class box_graph_orders_permonth extends ModeleBoxes
|
|||||||
|
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
$this->info_box_contents[0][0] = array('td' => '',
|
$this->info_box_contents[0][0] = array(
|
||||||
'text' => $langs->trans("ReadPermissionNotAllowed"));
|
'td' => 'align="left" class="nohover opacitymedium"',
|
||||||
|
'text' => $langs->trans("ReadPermissionNotAllowed")
|
||||||
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -252,8 +252,10 @@ class box_graph_orders_supplier_permonth extends ModeleBoxes
|
|||||||
|
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
$this->info_box_contents[0][0] = array('td' => '',
|
$this->info_box_contents[0][0] = array(
|
||||||
'text' => $langs->trans("ReadPermissionNotAllowed"));
|
'td' => 'align="left" class="nohover opacitymedium"',
|
||||||
|
'text' => $langs->trans("ReadPermissionNotAllowed")
|
||||||
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -99,6 +99,10 @@ class box_graph_product_distribution extends ModeleBoxes
|
|||||||
$nowarray=dol_getdate(dol_now(),true);
|
$nowarray=dol_getdate(dol_now(),true);
|
||||||
if (empty($year)) $year=$nowarray['year'];
|
if (empty($year)) $year=$nowarray['year'];
|
||||||
|
|
||||||
|
$nbofgraph=0;
|
||||||
|
if ($showinvoicenb) $nbofgraph++;
|
||||||
|
if ($showpropalnb) $nbofgraph++;
|
||||||
|
if ($showordernb) $nbofgraph++;
|
||||||
|
|
||||||
$text = $langs->trans("BoxProductDistribution",$max).' - '.$langs->trans("Year").': '.$year;
|
$text = $langs->trans("BoxProductDistribution",$max).' - '.$langs->trans("Year").': '.$year;
|
||||||
$this->info_box_head = array(
|
$this->info_box_head = array(
|
||||||
@ -113,11 +117,6 @@ class box_graph_product_distribution extends ModeleBoxes
|
|||||||
);
|
);
|
||||||
|
|
||||||
|
|
||||||
$nbofgraph=0;
|
|
||||||
if ($showinvoicenb) $nbofgraph++;
|
|
||||||
if ($showpropalnb) $nbofgraph++;
|
|
||||||
if ($showordernb) $nbofgraph++;
|
|
||||||
|
|
||||||
$paramtitle=$langs->transnoentitiesnoconv("Products").'/'.$langs->transnoentitiesnoconv("Services");
|
$paramtitle=$langs->transnoentitiesnoconv("Products").'/'.$langs->transnoentitiesnoconv("Services");
|
||||||
if (empty($conf->produit->enabled)) $paramtitle=$langs->transnoentitiesnoconv("Services");
|
if (empty($conf->produit->enabled)) $paramtitle=$langs->transnoentitiesnoconv("Services");
|
||||||
if (empty($conf->service->enabled)) $paramtitle=$langs->transnoentitiesnoconv("Products");
|
if (empty($conf->service->enabled)) $paramtitle=$langs->transnoentitiesnoconv("Products");
|
||||||
@ -250,7 +249,7 @@ class box_graph_product_distribution extends ModeleBoxes
|
|||||||
if (! empty($conf->commande->enabled) && ! empty($user->rights->commande->lire))
|
if (! empty($conf->commande->enabled) && ! empty($user->rights->commande->lire))
|
||||||
{
|
{
|
||||||
$langs->load("orders");
|
$langs->load("orders");
|
||||||
|
|
||||||
// Build graphic number of object. $data = array(array('Lib',val1,val2,val3),...)
|
// Build graphic number of object. $data = array(array('Lib',val1,val2,val3),...)
|
||||||
if ($showordernb)
|
if ($showordernb)
|
||||||
{
|
{
|
||||||
@ -309,6 +308,11 @@ class box_graph_product_distribution extends ModeleBoxes
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (empty($nbofgraph))
|
||||||
|
{
|
||||||
|
$langs->load("errors");
|
||||||
|
$mesg=$langs->trans("ReadPermissionNotAllowed");
|
||||||
|
}
|
||||||
if (empty($conf->use_javascript_ajax))
|
if (empty($conf->use_javascript_ajax))
|
||||||
{
|
{
|
||||||
$langs->load("errors");
|
$langs->load("errors");
|
||||||
@ -380,9 +384,11 @@ class box_graph_product_distribution extends ModeleBoxes
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
$this->info_box_contents[0][0] = array( 'td' => 'align="left" class="nohover"',
|
$this->info_box_contents[0][0] = array(
|
||||||
'maxlength'=>500,
|
'td' => 'align="left" class="nohover opacitymedium"',
|
||||||
'text' => $mesg);
|
'maxlength'=>500,
|
||||||
|
'text' => $mesg
|
||||||
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@ -254,8 +254,10 @@ class box_graph_propales_permonth extends ModeleBoxes
|
|||||||
|
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
$this->info_box_contents[0][0] = array('td' => '',
|
$this->info_box_contents[0][0] = array(
|
||||||
'text' => $langs->trans("ReadPermissionNotAllowed"));
|
'td' => 'align="left" class="nohover opacitymedium"',
|
||||||
|
'text' => $langs->trans("ReadPermissionNotAllowed")
|
||||||
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -157,8 +157,8 @@ class box_members extends ModeleBoxes
|
|||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
$this->info_box_contents[0][0] = array(
|
$this->info_box_contents[0][0] = array(
|
||||||
'align' => 'left',
|
'td' => 'align="left" class="nohover opacitymedium"',
|
||||||
'text' => $langs->trans("ReadPermissionNotAllowed"),
|
'text' => $langs->trans("ReadPermissionNotAllowed")
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -188,8 +188,8 @@ class box_produits extends ModeleBoxes
|
|||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
$this->info_box_contents[0][0] = array(
|
$this->info_box_contents[0][0] = array(
|
||||||
'td' => '',
|
'td' => 'align="left" class="nohover opacitymedium"',
|
||||||
'text' => $langs->trans("ReadPermissionNotAllowed"),
|
'text' => $langs->trans("ReadPermissionNotAllowed")
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -195,8 +195,8 @@ class box_produits_alerte_stock extends ModeleBoxes
|
|||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
$this->info_box_contents[0][0] = array(
|
$this->info_box_contents[0][0] = array(
|
||||||
'td' => '',
|
'td' => 'align="left" class="nohover opacitymedium"',
|
||||||
'text' => $langs->trans("ReadPermissionNotAllowed"),
|
'text' => $langs->trans("ReadPermissionNotAllowed")
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -155,8 +155,8 @@ class box_propales extends ModeleBoxes
|
|||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
$this->info_box_contents[0][0] = array(
|
$this->info_box_contents[0][0] = array(
|
||||||
'td' => '',
|
'td' => 'align="left" class="nohover opacitymedium"',
|
||||||
'text' => $langs->trans("ReadPermissionNotAllowed"),
|
'text' => $langs->trans("ReadPermissionNotAllowed")
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -156,8 +156,8 @@ class box_prospect extends ModeleBoxes
|
|||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
$this->info_box_contents[0][0] = array(
|
$this->info_box_contents[0][0] = array(
|
||||||
'td' => '',
|
'td' => 'align="left" class="nohover opacitymedium"',
|
||||||
'text' => $langs->trans("ReadPermissionNotAllowed"),
|
'text' => $langs->trans("ReadPermissionNotAllowed")
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -161,8 +161,10 @@ class box_services_contracts extends ModeleBoxes
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
$this->info_box_contents[0][0] = array('td' => '',
|
$this->info_box_contents[0][0] = array(
|
||||||
'text' => $langs->trans("ReadPermissionNotAllowed"));
|
'td' => 'align="left" class="nohover opacitymedium"',
|
||||||
|
'text' => $langs->trans("ReadPermissionNotAllowed")
|
||||||
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@ -84,7 +84,7 @@ class box_services_expired extends ModeleBoxes
|
|||||||
$i = 0;
|
$i = 0;
|
||||||
|
|
||||||
$thirdpartytmp = new Societe($this->db);
|
$thirdpartytmp = new Societe($this->db);
|
||||||
|
|
||||||
while ($i < $num)
|
while ($i < $num)
|
||||||
{
|
{
|
||||||
$late='';
|
$late='';
|
||||||
@ -140,8 +140,10 @@ class box_services_expired extends ModeleBoxes
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
$this->info_box_contents[0][0] = array('td' => '',
|
$this->info_box_contents[0][0] = array(
|
||||||
'text' => $langs->trans("ReadPermissionNotAllowed"));
|
'td' => 'align="left" class="nohover opacitymedium"',
|
||||||
|
'text' => $langs->trans("ReadPermissionNotAllowed")
|
||||||
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -160,8 +160,8 @@ class box_supplier_orders extends ModeleBoxes
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
$this->info_box_contents[0][0] = array(
|
$this->info_box_contents[0][0] = array(
|
||||||
'td' => '',
|
'td' => 'align="left" class="nohover opacitymedium"',
|
||||||
'text' => $langs->trans("ReadPermissionNotAllowed"),
|
'text' => $langs->trans("ReadPermissionNotAllowed")
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -191,7 +191,7 @@ FeatureAvailableOnlyOnStable=Feature only available on official stable versions
|
|||||||
Rights=Permissions
|
Rights=Permissions
|
||||||
BoxesDesc=Widgets are components showing some information that you can add to personalize some pages. You can choose between showing the widget or not by selecting target page and clicking 'Activate', or by clicking the dustbin to disable it.
|
BoxesDesc=Widgets are components showing some information that you can add to personalize some pages. You can choose between showing the widget or not by selecting target page and clicking 'Activate', or by clicking the dustbin to disable it.
|
||||||
OnlyActiveElementsAreShown=Only elements from <a href="%s">enabled modules</a> are shown.
|
OnlyActiveElementsAreShown=Only elements from <a href="%s">enabled modules</a> are shown.
|
||||||
ModulesDesc=Dolibarr modules define which functionality is enabled in software. Some modules require permissions you must grant to users, after enabling module. Click on button on/off to enable a module/feature.
|
ModulesDesc=Dolibarr modules define which application/feature is enabled in software. Some application/modules require permissions you must grant to users, after enabling module. Click on button on/off to enable an application/module.
|
||||||
ModulesMarketPlaceDesc=You can find more modules to download on external websites on the Internet...
|
ModulesMarketPlaceDesc=You can find more modules to download on external websites on the Internet...
|
||||||
ModulesDeployDesc=If permissions on your file system allows it, you can use this tool to deploy an external module. The module wil then be visible on the tab <strong>%s</strong>.
|
ModulesDeployDesc=If permissions on your file system allows it, you can use this tool to deploy an external module. The module wil then be visible on the tab <strong>%s</strong>.
|
||||||
ModulesMarketPlaces=Find external modules...
|
ModulesMarketPlaces=Find external modules...
|
||||||
@ -1107,7 +1107,7 @@ WarningAtLeastKeyOrTranslationRequired=A search criteria is required at least fo
|
|||||||
NewTranslationStringToShow=New translation string to show
|
NewTranslationStringToShow=New translation string to show
|
||||||
OriginalValueWas=The original translation is overwritten. Original value was:<br><br>%s
|
OriginalValueWas=The original translation is overwritten. Original value was:<br><br>%s
|
||||||
TransKeyWithoutOriginalValue=You forced a new translation for the translation key '<strong>%s</strong>' that does not exists in any language files
|
TransKeyWithoutOriginalValue=You forced a new translation for the translation key '<strong>%s</strong>' that does not exists in any language files
|
||||||
TotalNumberOfActivatedModules=Activated feature/modules: <b>%s</b> / <b>%s</b>
|
TotalNumberOfActivatedModules=Activated application/modules: <b>%s</b> / <b>%s</b>
|
||||||
YouMustEnableOneModule=You must at least enable 1 module
|
YouMustEnableOneModule=You must at least enable 1 module
|
||||||
ClassNotFoundIntoPathWarning=Class %s not found into PHP path
|
ClassNotFoundIntoPathWarning=Class %s not found into PHP path
|
||||||
YesInSummer=Yes in summer
|
YesInSummer=Yes in summer
|
||||||
|
|||||||
@ -2245,7 +2245,8 @@ div.tabBar div.border .table-border-row, div.tabBar div.border .table-key-border
|
|||||||
}
|
}
|
||||||
div .tdtop {
|
div .tdtop {
|
||||||
vertical-align: top !important;
|
vertical-align: top !important;
|
||||||
padding-top: 5px !important;
|
padding-top: 8px !important;
|
||||||
|
padding-bottom: 2px !important;
|
||||||
padding-bottom: 0px;
|
padding-bottom: 0px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -2820,7 +2820,7 @@ div.tabBar .noborder {
|
|||||||
div .tdtop {
|
div .tdtop {
|
||||||
vertical-align: top !important;
|
vertical-align: top !important;
|
||||||
padding-top: 5px !important;
|
padding-top: 5px !important;
|
||||||
padding-bottom: 0px;
|
padding-bottom: 0px !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
#tablelines tr.liste_titre td, .paymenttable tr.liste_titre td, .margintable tr.liste_titre td, .tableforservicepart1 tr.liste_titre td {
|
#tablelines tr.liste_titre td, .paymenttable tr.liste_titre td, .margintable tr.liste_titre td, .tableforservicepart1 tr.liste_titre td {
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user