Merge branch '9.0' of git@github.com:Dolibarr/dolibarr.git into develop
This commit is contained in:
commit
434cf2e046
@ -96,6 +96,7 @@ if ($action == 'update')
|
|||||||
$menu->perms=GETPOST('perms','alpha');
|
$menu->perms=GETPOST('perms','alpha');
|
||||||
$menu->target=GETPOST('target','alpha');
|
$menu->target=GETPOST('target','alpha');
|
||||||
$menu->user=GETPOST('user','alpha');
|
$menu->user=GETPOST('user','alpha');
|
||||||
|
$menu->mainmenu=GETPOST('propertymainmenu','alpha');
|
||||||
if (is_numeric(GETPOST('menuIdParent','alpha')))
|
if (is_numeric(GETPOST('menuIdParent','alpha')))
|
||||||
{
|
{
|
||||||
$menu->fk_menu=GETPOST('menuIdParent','alpha');
|
$menu->fk_menu=GETPOST('menuIdParent','alpha');
|
||||||
@ -123,14 +124,11 @@ if ($action == 'update')
|
|||||||
setEventMessages($menu->error, $menu->errors, 'errors');
|
setEventMessages($menu->error, $menu->errors, 'errors');
|
||||||
}
|
}
|
||||||
$action = "edit";
|
$action = "edit";
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
header("Location: ".DOL_URL_ROOT."/admin/menus/index.php?menu_handler=".$menu_handler);
|
header("Location: ".DOL_URL_ROOT."/admin/menus/index.php?menu_handler=".$menu_handler);
|
||||||
exit;
|
exit;
|
||||||
}
|
}
|
||||||
|
else
|
||||||
if ($_GET['return'])
|
|
||||||
{
|
{
|
||||||
header("Location: ".DOL_URL_ROOT."/admin/menus/index.php?menu_handler=".$menu_handler);
|
header("Location: ".DOL_URL_ROOT."/admin/menus/index.php?menu_handler=".$menu_handler);
|
||||||
exit;
|
exit;
|
||||||
@ -215,6 +213,7 @@ if ($action == 'add')
|
|||||||
$menu->perms=GETPOST('perms','alpha');
|
$menu->perms=GETPOST('perms','alpha');
|
||||||
$menu->target=GETPOST('target','alpha');
|
$menu->target=GETPOST('target','alpha');
|
||||||
$menu->user=GETPOST('user','alpha');
|
$menu->user=GETPOST('user','alpha');
|
||||||
|
$menu->mainmenu=GETPOST('propertymainmenu','alpha');
|
||||||
if (is_numeric(GETPOST('menuId','int')))
|
if (is_numeric(GETPOST('menuId','int')))
|
||||||
{
|
{
|
||||||
$menu->fk_menu=GETPOST('menuId','int');
|
$menu->fk_menu=GETPOST('menuId','int');
|
||||||
@ -289,10 +288,13 @@ if ($action == 'create')
|
|||||||
{
|
{
|
||||||
jQuery("#menuId").prop("disabled", true);
|
jQuery("#menuId").prop("disabled", true);
|
||||||
jQuery("#menuId").val(\'\');
|
jQuery("#menuId").val(\'\');
|
||||||
|
jQuery("#propertymainmenu").removeAttr("disabled");
|
||||||
|
jQuery("#propertymainmenu").val(\'\');
|
||||||
}
|
}
|
||||||
else
|
if (jQuery("#topleft").val() == \'left\')
|
||||||
{
|
{
|
||||||
jQuery("#menuId").removeAttr("disabled");
|
jQuery("#menuId").removeAttr("disabled");
|
||||||
|
jQuery("#propertymainmenu").prop("disabled", true);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
init_topleft();
|
init_topleft();
|
||||||
@ -338,7 +340,7 @@ if ($action == 'create')
|
|||||||
print '</td>';
|
print '</td>';
|
||||||
print '<td>'.$langs->trans('DetailMenuHandler').'</td></tr>';
|
print '<td>'.$langs->trans('DetailMenuHandler').'</td></tr>';
|
||||||
|
|
||||||
//User
|
// User
|
||||||
print '<tr><td class="nowrap fieldrequired">'.$langs->trans('MenuForUsers').'</td>';
|
print '<tr><td class="nowrap fieldrequired">'.$langs->trans('MenuForUsers').'</td>';
|
||||||
print '<td><select class="flat" name="user">';
|
print '<td><select class="flat" name="user">';
|
||||||
print '<option value="2" selected>'.$langs->trans("AllMenus").'</option>';
|
print '<option value="2" selected>'.$langs->trans("AllMenus").'</option>';
|
||||||
@ -362,9 +364,15 @@ if ($action == 'create')
|
|||||||
print '<option value="left"'.($_POST["type"] && $_POST["type"]=='left'?' selected':'').'>'.$langs->trans('Left').'</option>';
|
print '<option value="left"'.($_POST["type"] && $_POST["type"]=='left'?' selected':'').'>'.$langs->trans('Left').'</option>';
|
||||||
print '</select>';
|
print '</select>';
|
||||||
}
|
}
|
||||||
// print '<input type="text" size="50" name="type" value="'.$type.'">';
|
|
||||||
print '</td><td>'.$langs->trans('DetailType').'</td></tr>';
|
print '</td><td>'.$langs->trans('DetailType').'</td></tr>';
|
||||||
|
|
||||||
|
// Mainmenu code
|
||||||
|
print '<tr><td class="fieldrequired">'.$langs->trans('MainMenuCode').'</td>';
|
||||||
|
print '<td><input type="text" class="minwidth300" id="propertymainmenu" name="propertymainmenu" value="'.(GETPOST("propertymainmenu", 'alpha')?GETPOST("propertymainmenu", 'alpha'):'').'"></td>';
|
||||||
|
print '<td>';
|
||||||
|
print $langs->trans("Example").': mytopmenukey';
|
||||||
|
print '</td></tr>';
|
||||||
|
|
||||||
// MenuId Parent
|
// MenuId Parent
|
||||||
print '<tr><td class="fieldrequired">'.$langs->trans('MenuIdParent').'</td>';
|
print '<tr><td class="fieldrequired">'.$langs->trans('MenuIdParent').'</td>';
|
||||||
if ($parent_rowid)
|
if ($parent_rowid)
|
||||||
@ -373,23 +381,23 @@ if ($action == 'create')
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
print '<td><input type="text" size="48" id="menuId" name="menuId" value="'.(GETPOST("menuId", 'int')?GETPOST("menuId", 'int'):'').'"></td>';
|
print '<td><input type="text" class="minwidth300" id="menuId" name="menuId" value="'.(GETPOST("menuId", 'int')?GETPOST("menuId", 'int'):'').'"></td>';
|
||||||
}
|
}
|
||||||
print '<td>'.$langs->trans('DetailMenuIdParent');
|
print '<td>'.$langs->trans('DetailMenuIdParent');
|
||||||
print ', '.$langs->trans("Example").': fk_mainmenu=abc&fk_leftmenu=def';
|
print ', '.$langs->trans("Example").': fk_mainmenu=abc&fk_leftmenu=def';
|
||||||
print '</td></tr>';
|
print '</td></tr>';
|
||||||
|
|
||||||
// Title
|
// Title
|
||||||
print '<tr><td class="fieldrequired">'.$langs->trans('Title').'</td><td><input type="text" size="30" name="titre" value="'.dol_escape_htmltag(GETPOST("titre",'alpha')).'"></td><td>'.$langs->trans('DetailTitre').'</td></tr>';
|
print '<tr><td class="fieldrequired">'.$langs->trans('Title').'</td><td><input type="text" class="minwidth300" name="titre" value="'.dol_escape_htmltag(GETPOST("titre",'alpha')).'"></td><td>'.$langs->trans('DetailTitre').'</td></tr>';
|
||||||
|
|
||||||
// URL
|
// URL
|
||||||
print '<tr><td class="fieldrequired">'.$langs->trans('URL').'</td><td><input type="text" size="60" name="url" value="'.GETPOST("url",'alpha').'"></td><td>'.$langs->trans('DetailUrl').'</td></tr>';
|
print '<tr><td class="fieldrequired">'.$langs->trans('URL').'</td><td><input type="text" class="minwidth500" name="url" value="'.GETPOST("url",'alpha').'"></td><td>'.$langs->trans('DetailUrl').'</td></tr>';
|
||||||
|
|
||||||
// Langs
|
// Langs
|
||||||
print '<tr><td>'.$langs->trans('LangFile').'</td><td><input type="text" size="30" name="langs" value="'.$parent_langs.'"></td><td>'.$langs->trans('DetailLangs').'</td></tr>';
|
print '<tr><td>'.$langs->trans('LangFile').'</td><td><input type="text" class="minwidth300" name="langs" value="'.$parent_langs.'"></td><td>'.$langs->trans('DetailLangs').'</td></tr>';
|
||||||
|
|
||||||
// Position
|
// Position
|
||||||
print '<tr><td>'.$langs->trans('Position').'</td><td><input type="text" size="5" name="position" value="'.dol_escape_htmltag(isset($_POST["position"])?$_POST["position"]:100).'"></td><td>'.$langs->trans('DetailPosition').'</td></tr>';
|
print '<tr><td>'.$langs->trans('Position').'</td><td><input type="text" class="width100" name="position" value="'.dol_escape_htmltag(isset($_POST["position"])?$_POST["position"]:100).'"></td><td>'.$langs->trans('DetailPosition').'</td></tr>';
|
||||||
|
|
||||||
// Target
|
// Target
|
||||||
print '<tr><td>'.$langs->trans('Target').'</td><td><select class="flat" name="target">';
|
print '<tr><td>'.$langs->trans('Target').'</td><td><select class="flat" name="target">';
|
||||||
@ -398,10 +406,10 @@ if ($action == 'create')
|
|||||||
print '</select></td></td><td>'.$langs->trans('DetailTarget').'</td></tr>';
|
print '</select></td></td><td>'.$langs->trans('DetailTarget').'</td></tr>';
|
||||||
|
|
||||||
// Enabled
|
// Enabled
|
||||||
print '<tr><td>'.$langs->trans('Enabled').'</td><td><input type="text" size="60" name="enabled" value="'.GETPOST("enabled",'alpha').'"></td><td>'.$langs->trans('DetailEnabled').'</td></tr>';
|
print '<tr><td>'.$langs->trans('Enabled').'</td><td><input type="text" class="minwidth500" name="enabled" value="'.(GETPOSTISSET('enabled')?GETPOST("enabled",'alpha'):'1').'"></td><td>'.$langs->trans('DetailEnabled').'</td></tr>';
|
||||||
|
|
||||||
// Perms
|
// Perms
|
||||||
print '<tr><td>'.$langs->trans('Rights').'</td><td><input type="text" size="60" name="perms" value="'.GETPOST('perms','alpha').'"></td><td>'.$langs->trans('DetailRight').'</td></tr>';
|
print '<tr><td>'.$langs->trans('Rights').'</td><td><input type="text" class="minwidth500" name="perms" value="'.(GETPOSTISSET('perms')?GETPOST('perms','alpha'):'1').'"></td><td>'.$langs->trans('DetailRight').'</td></tr>';
|
||||||
|
|
||||||
print '</table>';
|
print '</table>';
|
||||||
|
|
||||||
@ -455,13 +463,30 @@ elseif ($action == 'edit')
|
|||||||
// Type
|
// Type
|
||||||
print '<tr><td class="fieldrequired">'.$langs->trans('Type').'</td><td>'.$langs->trans(ucfirst($menu->type)).'</td><td>'.$langs->trans('DetailType').'</td></tr>';
|
print '<tr><td class="fieldrequired">'.$langs->trans('Type').'</td><td>'.$langs->trans(ucfirst($menu->type)).'</td><td>'.$langs->trans('DetailType').'</td></tr>';
|
||||||
|
|
||||||
|
// Mainmenu code
|
||||||
|
if ($menu->type == 'top')
|
||||||
|
{
|
||||||
|
print '<tr><td class="fieldrequired">'.$langs->trans('MainMenuCode').'</td>';
|
||||||
|
/*if ($parent_rowid)
|
||||||
|
{
|
||||||
|
print '<td>'.$parent_rowid.'<input type="hidden" name="propertyleftmenu" value="'.$parent_rowid.'"></td>';
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{*/
|
||||||
|
print '<td><input type="text" class="minwidth300" id="propertymainmenu" name="propertymainmenu" value="'.(GETPOST("propertymainmenu", 'alpha')?GETPOST("propertymainmenu", 'alpha'):$menu->mainmenu).'"></td>';
|
||||||
|
//}
|
||||||
|
print '<td>';
|
||||||
|
print $langs->trans("Example").': mytopmenukey';
|
||||||
|
print '</td></tr>';
|
||||||
|
}
|
||||||
|
|
||||||
// MenuId Parent
|
// MenuId Parent
|
||||||
print '<tr><td class="fieldrequired">'.$langs->trans('MenuIdParent');
|
print '<tr><td class="fieldrequired">'.$langs->trans('MenuIdParent');
|
||||||
print '</td>';
|
print '</td>';
|
||||||
$valtouse=$menu->fk_menu;
|
$valtouse=$menu->fk_menu;
|
||||||
if ($menu->fk_mainmenu) $valtouse='fk_mainmenu='.$menu->fk_mainmenu;
|
if ($menu->fk_mainmenu) $valtouse='fk_mainmenu='.$menu->fk_mainmenu;
|
||||||
if ($menu->fk_leftmenu) $valtouse.='&fk_leftmenu='.$menu->fk_leftmenu;
|
if ($menu->fk_leftmenu) $valtouse.='&fk_leftmenu='.$menu->fk_leftmenu;
|
||||||
print '<td><input type="text" name="menuIdParent" value="'.$valtouse.'" size="48"></td>';
|
print '<td><input type="text" name="menuIdParent" value="'.$valtouse.'" class="minwidth300"></td>';
|
||||||
print '<td>'.$langs->trans('DetailMenuIdParent');
|
print '<td>'.$langs->trans('DetailMenuIdParent');
|
||||||
print ', '.$langs->trans("Example").': fk_mainmenu=abc&fk_leftmenu=def';
|
print ', '.$langs->trans("Example").': fk_mainmenu=abc&fk_leftmenu=def';
|
||||||
print '</td></tr>';
|
print '</td></tr>';
|
||||||
@ -470,16 +495,16 @@ elseif ($action == 'edit')
|
|||||||
//print '<tr><td>'.$langs->trans('Level').'</td><td>'.$menu->level.'</td><td>'.$langs->trans('DetailLevel').'</td></tr>';
|
//print '<tr><td>'.$langs->trans('Level').'</td><td>'.$menu->level.'</td><td>'.$langs->trans('DetailLevel').'</td></tr>';
|
||||||
|
|
||||||
// Title
|
// Title
|
||||||
print '<tr><td class="fieldrequired">'.$langs->trans('Title').'</td><td><input type="text" size="30" name="titre" value="'.dol_escape_htmltag($menu->titre).'"></td><td>'.$langs->trans('DetailTitre').'</td></tr>';
|
print '<tr><td class="fieldrequired">'.$langs->trans('Title').'</td><td><input type="text" class="minwidth300" name="titre" value="'.dol_escape_htmltag($menu->titre).'"></td><td>'.$langs->trans('DetailTitre').'</td></tr>';
|
||||||
|
|
||||||
// Url
|
// Url
|
||||||
print '<tr><td class="fieldrequired">'.$langs->trans('URL').'</td><td><input type="text" class="quatrevingtpercent" name="url" value="'.$menu->url.'"></td><td>'.$langs->trans('DetailUrl').'</td></tr>';
|
print '<tr><td class="fieldrequired">'.$langs->trans('URL').'</td><td><input type="text" class="quatrevingtpercent" name="url" value="'.$menu->url.'"></td><td>'.$langs->trans('DetailUrl').'</td></tr>';
|
||||||
|
|
||||||
// Langs
|
// Langs
|
||||||
print '<tr><td>'.$langs->trans('LangFile').'</td><td><input type="text" size="30" name="langs" value="'.dol_escape_htmltag($menu->langs).'"></td><td>'.$langs->trans('DetailLangs').'</td></tr>';
|
print '<tr><td>'.$langs->trans('LangFile').'</td><td><input type="text" class="minwidth300" name="langs" value="'.dol_escape_htmltag($menu->langs).'"></td><td>'.$langs->trans('DetailLangs').'</td></tr>';
|
||||||
|
|
||||||
// Position
|
// Position
|
||||||
print '<tr><td>'.$langs->trans('Position').'</td><td><input type="text" size="5" name="position" value="'.$menu->position.'"></td><td>'.$langs->trans('DetailPosition').'</td></tr>';
|
print '<tr><td>'.$langs->trans('Position').'</td><td><input type="text" class="minwidth100" name="position" value="'.$menu->position.'"></td><td>'.$langs->trans('DetailPosition').'</td></tr>';
|
||||||
|
|
||||||
// Target
|
// Target
|
||||||
print '<tr><td>'.$langs->trans('Target').'</td><td><select class="flat" name="target">';
|
print '<tr><td>'.$langs->trans('Target').'</td><td><select class="flat" name="target">';
|
||||||
@ -488,12 +513,12 @@ elseif ($action == 'edit')
|
|||||||
print '</select></td><td>'.$langs->trans('DetailTarget').'</td></tr>';
|
print '</select></td><td>'.$langs->trans('DetailTarget').'</td></tr>';
|
||||||
|
|
||||||
// Enabled
|
// Enabled
|
||||||
print '<tr><td>'.$langs->trans('Enabled').'</td><td><input type="text" size="60" name="enabled" value="'.dol_escape_htmltag($menu->enabled).'"></td><td>'.$langs->trans('DetailEnabled');
|
print '<tr><td>'.$langs->trans('Enabled').'</td><td><input type="text" class="minwidth500" name="enabled" value="'.dol_escape_htmltag($menu->enabled).'"></td><td>'.$langs->trans('DetailEnabled');
|
||||||
if (! empty($menu->enabled)) print ' ('.$langs->trans("ConditionIsCurrently").': '.yn(dol_eval($menu->enabled,1)).')';
|
if (! empty($menu->enabled)) print ' ('.$langs->trans("ConditionIsCurrently").': '.yn(dol_eval($menu->enabled,1)).')';
|
||||||
print '</td></tr>';
|
print '</td></tr>';
|
||||||
|
|
||||||
// Perms
|
// Perms
|
||||||
print '<tr><td>'.$langs->trans('Rights').'</td><td><input type="text" size="60" name="perms" value="'.dol_escape_htmltag($menu->perms).'"></td><td>'.$langs->trans('DetailRight');
|
print '<tr><td>'.$langs->trans('Rights').'</td><td><input type="text" class="minwidth500" name="perms" value="'.dol_escape_htmltag($menu->perms).'"></td><td>'.$langs->trans('DetailRight');
|
||||||
if (! empty($menu->perms)) print ' ('.$langs->trans("ConditionIsCurrently").': '.yn(dol_eval($menu->perms,1)).')';
|
if (! empty($menu->perms)) print ' ('.$langs->trans("ConditionIsCurrently").': '.yn(dol_eval($menu->perms,1)).')';
|
||||||
print '</td></tr>';
|
print '</td></tr>';
|
||||||
|
|
||||||
|
|||||||
@ -329,14 +329,16 @@ if ($object->fetch($id) >= 0)
|
|||||||
// Si le module mailing est qualifie
|
// Si le module mailing est qualifie
|
||||||
if ($qualified)
|
if ($qualified)
|
||||||
{
|
{
|
||||||
|
$var = ! $var;
|
||||||
|
|
||||||
if ($allowaddtarget)
|
if ($allowaddtarget)
|
||||||
{
|
{
|
||||||
print '<form class="oddeven tagtr" name="'.$modulename.'" action="'.$_SERVER['PHP_SELF'].'?action=add&id='.$object->id.'&module='.$modulename.'" method="POST" enctype="multipart/form-data">';
|
print '<form '.$bctag[$var].' name="'.$modulename.'" action="'.$_SERVER['PHP_SELF'].'?action=add&id='.$object->id.'&module='.$modulename.'" method="POST" enctype="multipart/form-data">';
|
||||||
print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">';
|
print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">';
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
print '<div class="oddeven tagtr">';
|
print '<div '.$bctag[$var].'>';
|
||||||
}
|
}
|
||||||
|
|
||||||
print '<div class="tagtd">';
|
print '<div class="tagtd">';
|
||||||
|
|||||||
@ -76,9 +76,9 @@ class Events // extends CommonObject
|
|||||||
|
|
||||||
// List of all Audit/Security events supported by triggers
|
// List of all Audit/Security events supported by triggers
|
||||||
public $eventstolog=array(
|
public $eventstolog=array(
|
||||||
/*array('id'=>'USER_LOGIN', 'test'=>1),
|
array('id'=>'USER_LOGIN', 'test'=>1),
|
||||||
array('id'=>'USER_LOGIN_FAILED', 'test'=>1),
|
array('id'=>'USER_LOGIN_FAILED', 'test'=>1),
|
||||||
array('id'=>'USER_LOGOUT', 'test'=>1),*/
|
array('id'=>'USER_LOGOUT', 'test'=>1),
|
||||||
array('id'=>'USER_CREATE', 'test'=>1),
|
array('id'=>'USER_CREATE', 'test'=>1),
|
||||||
array('id'=>'USER_MODIFY', 'test'=>1),
|
array('id'=>'USER_MODIFY', 'test'=>1),
|
||||||
array('id'=>'USER_NEW_PASSWORD', 'test'=>1),
|
array('id'=>'USER_NEW_PASSWORD', 'test'=>1),
|
||||||
|
|||||||
@ -334,7 +334,7 @@ class FormProjets
|
|||||||
$out='';
|
$out='';
|
||||||
|
|
||||||
$hideunselectables = false;
|
$hideunselectables = false;
|
||||||
if (! empty($conf->global->CONTRACT_HIDE_UNSELECTABLES)) $hideunselectables = true;
|
if (! empty($conf->global->PROJECT_HIDE_UNSELECTABLES)) $hideunselectables = true;
|
||||||
|
|
||||||
if (empty($projectsListId))
|
if (empty($projectsListId))
|
||||||
{
|
{
|
||||||
@ -346,11 +346,11 @@ class FormProjets
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Search all projects
|
// Search all projects
|
||||||
$sql = 'SELECT t.rowid, t.ref as tref, t.label as tlabel, p.ref, p.title, p.fk_soc, p.fk_statut, p.public,';
|
$sql = 'SELECT t.rowid, t.ref as tref, t.label as tlabel, p.rowid as pid, p.ref, p.title, p.fk_soc, p.fk_statut, p.public,';
|
||||||
$sql.= ' s.nom as name';
|
$sql.= ' s.nom as name';
|
||||||
$sql.= ' FROM '.MAIN_DB_PREFIX .'projet as p';
|
$sql.= ' FROM '.MAIN_DB_PREFIX .'projet as p';
|
||||||
$sql.= ' LEFT JOIN '.MAIN_DB_PREFIX.'societe as s ON s.rowid = p.fk_soc';
|
$sql.= ' LEFT JOIN '.MAIN_DB_PREFIX.'societe as s ON s.rowid = p.fk_soc,';
|
||||||
$sql.= ', '.MAIN_DB_PREFIX.'projet_task as t';
|
$sql.= ' '.MAIN_DB_PREFIX.'projet_task as t';
|
||||||
$sql.= " WHERE p.entity IN (".getEntity('project').")";
|
$sql.= " WHERE p.entity IN (".getEntity('project').")";
|
||||||
$sql.= " AND t.fk_projet = p.rowid";
|
$sql.= " AND t.fk_projet = p.rowid";
|
||||||
if ($projectsListId) $sql.= " AND p.rowid IN (".$projectsListId.")";
|
if ($projectsListId) $sql.= " AND p.rowid IN (".$projectsListId.")";
|
||||||
@ -393,7 +393,7 @@ class FormProjets
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
if ($discard_closed == 1 && $obj->fk_statut == 2)
|
if ($discard_closed == 1 && $obj->fk_statut == Project::STATUS_CLOSED)
|
||||||
{
|
{
|
||||||
$i++;
|
$i++;
|
||||||
continue;
|
continue;
|
||||||
@ -411,12 +411,12 @@ class FormProjets
|
|||||||
if ($obj->name) $labeltoshow.=' ('.$obj->name.')';
|
if ($obj->name) $labeltoshow.=' ('.$obj->name.')';
|
||||||
|
|
||||||
$disabled=0;
|
$disabled=0;
|
||||||
if ($obj->fk_statut == 0)
|
if ($obj->fk_statut == Project::STATUS_DRAFT)
|
||||||
{
|
{
|
||||||
$disabled=1;
|
$disabled=1;
|
||||||
$labeltoshow.=' - '.$langs->trans("Draft");
|
$labeltoshow.=' - '.$langs->trans("Draft");
|
||||||
}
|
}
|
||||||
else if ($obj->fk_statut == 2)
|
else if ($obj->fk_statut == Project::STATUS_CLOSED)
|
||||||
{
|
{
|
||||||
if ($discard_closed == 2) $disabled=1;
|
if ($discard_closed == 2) $disabled=1;
|
||||||
$labeltoshow.=' - '.$langs->trans("Closed");
|
$labeltoshow.=' - '.$langs->trans("Closed");
|
||||||
|
|||||||
@ -589,7 +589,6 @@ class Menubase
|
|||||||
|
|
||||||
$a = 0;
|
$a = 0;
|
||||||
$b = 0;
|
$b = 0;
|
||||||
$oldrowid=0;
|
|
||||||
while ($a < $numa)
|
while ($a < $numa)
|
||||||
{
|
{
|
||||||
//$objm = $this->db->fetch_object($resql);
|
//$objm = $this->db->fetch_object($resql);
|
||||||
|
|||||||
@ -52,9 +52,44 @@ function project_prepare_head($object)
|
|||||||
$head[$h][2] = 'contact';
|
$head[$h][2] = 'contact';
|
||||||
$h++;
|
$h++;
|
||||||
|
|
||||||
|
if (empty($conf->global->PROJECT_HIDE_TASKS))
|
||||||
|
{
|
||||||
|
// Then tab for sub level of projet, i mean tasks
|
||||||
|
$head[$h][0] = DOL_URL_ROOT.'/projet/tasks.php?id='.$object->id;
|
||||||
|
$head[$h][1] = $langs->trans("Tasks");
|
||||||
|
|
||||||
|
require_once DOL_DOCUMENT_ROOT.'/projet/class/task.class.php';
|
||||||
|
$taskstatic=new Task($db);
|
||||||
|
$nbTasks=count($taskstatic->getTasksArray(0, 0, $object->id, 0, 0));
|
||||||
|
if ($nbTasks > 0) $head[$h][1].= ' <span class="badge">'.($nbTasks).'</span>';
|
||||||
|
$head[$h][2] = 'tasks';
|
||||||
|
$h++;
|
||||||
|
|
||||||
|
$nbTimeSpent=0;
|
||||||
|
$sql = "SELECT t.rowid";
|
||||||
|
//$sql .= " FROM ".MAIN_DB_PREFIX."projet_task_time as t, ".MAIN_DB_PREFIX."projet_task as pt, ".MAIN_DB_PREFIX."user as u";
|
||||||
|
//$sql .= " WHERE t.fk_user = u.rowid AND t.fk_task = pt.rowid";
|
||||||
|
$sql .= " FROM ".MAIN_DB_PREFIX."projet_task_time as t, ".MAIN_DB_PREFIX."projet_task as pt";
|
||||||
|
$sql .= " WHERE t.fk_task = pt.rowid";
|
||||||
|
$sql .= " AND pt.fk_projet =".$object->id;
|
||||||
|
$resql = $db->query($sql);
|
||||||
|
if ($resql)
|
||||||
|
{
|
||||||
|
$obj = $db->fetch_object($resql);
|
||||||
|
if ($obj) $nbTimeSpent=1;
|
||||||
|
}
|
||||||
|
else dol_print_error($db);
|
||||||
|
|
||||||
|
$head[$h][0] = DOL_URL_ROOT.'/projet/tasks/time.php?withproject=1&projectid='.$object->id;
|
||||||
|
$head[$h][1] = $langs->trans("TimeSpent");
|
||||||
|
if ($nbTimeSpent > 0) $head[$h][1].= ' <span class="badge">...</span>';
|
||||||
|
$head[$h][2] = 'timespent';
|
||||||
|
$h++;
|
||||||
|
}
|
||||||
|
|
||||||
if (! empty($conf->fournisseur->enabled) || ! empty($conf->propal->enabled) || ! empty($conf->commande->enabled)
|
if (! empty($conf->fournisseur->enabled) || ! empty($conf->propal->enabled) || ! empty($conf->commande->enabled)
|
||||||
|| ! empty($conf->facture->enabled) || ! empty($conf->contrat->enabled)
|
|| ! empty($conf->facture->enabled) || ! empty($conf->contrat->enabled)
|
||||||
|| ! empty($conf->ficheinter->enabled) || ! empty($conf->agenda->enabled) || ! empty($conf->deplacement->enabled))
|
|| ! empty($conf->ficheinter->enabled) || ! empty($conf->agenda->enabled) || ! empty($conf->deplacement->enabled))
|
||||||
{
|
{
|
||||||
$head[$h][0] = DOL_URL_ROOT.'/projet/element.php?id='.$object->id;
|
$head[$h][0] = DOL_URL_ROOT.'/projet/element.php?id='.$object->id;
|
||||||
$head[$h][1] = $langs->trans("ProjectOverview");
|
$head[$h][1] = $langs->trans("ProjectOverview");
|
||||||
@ -92,41 +127,6 @@ function project_prepare_head($object)
|
|||||||
$head[$h][2] = 'document';
|
$head[$h][2] = 'document';
|
||||||
$h++;
|
$h++;
|
||||||
|
|
||||||
if (empty($conf->global->PROJECT_HIDE_TASKS))
|
|
||||||
{
|
|
||||||
// Then tab for sub level of projet, i mean tasks
|
|
||||||
$head[$h][0] = DOL_URL_ROOT.'/projet/tasks.php?id='.$object->id;
|
|
||||||
$head[$h][1] = $langs->trans("Tasks");
|
|
||||||
|
|
||||||
require_once DOL_DOCUMENT_ROOT.'/projet/class/task.class.php';
|
|
||||||
$taskstatic=new Task($db);
|
|
||||||
$nbTasks=count($taskstatic->getTasksArray(0, 0, $object->id, 0, 0));
|
|
||||||
if ($nbTasks > 0) $head[$h][1].= ' <span class="badge">'.($nbTasks).'</span>';
|
|
||||||
$head[$h][2] = 'tasks';
|
|
||||||
$h++;
|
|
||||||
|
|
||||||
$nbTimeSpent=0;
|
|
||||||
$sql = "SELECT t.rowid";
|
|
||||||
//$sql .= " FROM ".MAIN_DB_PREFIX."projet_task_time as t, ".MAIN_DB_PREFIX."projet_task as pt, ".MAIN_DB_PREFIX."user as u";
|
|
||||||
//$sql .= " WHERE t.fk_user = u.rowid AND t.fk_task = pt.rowid";
|
|
||||||
$sql .= " FROM ".MAIN_DB_PREFIX."projet_task_time as t, ".MAIN_DB_PREFIX."projet_task as pt";
|
|
||||||
$sql .= " WHERE t.fk_task = pt.rowid";
|
|
||||||
$sql .= " AND pt.fk_projet =".$object->id;
|
|
||||||
$resql = $db->query($sql);
|
|
||||||
if ($resql)
|
|
||||||
{
|
|
||||||
$obj = $db->fetch_object($resql);
|
|
||||||
if ($obj) $nbTimeSpent=1;
|
|
||||||
}
|
|
||||||
else dol_print_error($db);
|
|
||||||
|
|
||||||
$head[$h][0] = DOL_URL_ROOT.'/projet/tasks/time.php?withproject=1&projectid='.$object->id;
|
|
||||||
$head[$h][1] = $langs->trans("TimeSpent");
|
|
||||||
if ($nbTimeSpent > 0) $head[$h][1].= ' <span class="badge">...</span>';
|
|
||||||
$head[$h][2] = 'timespent';
|
|
||||||
$h++;
|
|
||||||
}
|
|
||||||
|
|
||||||
// Manage discussion
|
// Manage discussion
|
||||||
if (!empty($conf->global->PROJECT_ALLOW_COMMENT_ON_PROJECT))
|
if (!empty($conf->global->PROJECT_ALLOW_COMMENT_ON_PROJECT))
|
||||||
{
|
{
|
||||||
@ -1205,7 +1205,7 @@ function projectLinesPerWeek(&$inc, $firstdaytoshow, $fuser, $parent, $lines, &$
|
|||||||
{
|
{
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Break on a new project
|
// Break on a new project
|
||||||
if ($parent == 0 && $lines[$i]->fk_project != $lastprojectid)
|
if ($parent == 0 && $lines[$i]->fk_project != $lastprojectid)
|
||||||
{
|
{
|
||||||
|
|||||||
@ -468,6 +468,8 @@ function print_left_eldy_menu($db,$menu_array_before,$menu_array_after,&$tabMenu
|
|||||||
{
|
{
|
||||||
global $user,$conf,$langs,$dolibarr_main_db_name,$mysoc;
|
global $user,$conf,$langs,$dolibarr_main_db_name,$mysoc;
|
||||||
|
|
||||||
|
//var_dump($tabMenu);
|
||||||
|
|
||||||
$newmenu = $menu;
|
$newmenu = $menu;
|
||||||
|
|
||||||
$mainmenu=($forcemainmenu?$forcemainmenu:$_SESSION["mainmenu"]);
|
$mainmenu=($forcemainmenu?$forcemainmenu:$_SESSION["mainmenu"]);
|
||||||
@ -523,7 +525,7 @@ function print_left_eldy_menu($db,$menu_array_before,$menu_array_after,&$tabMenu
|
|||||||
* We update newmenu with entries found into database
|
* We update newmenu with entries found into database
|
||||||
* --------------------------------------------------
|
* --------------------------------------------------
|
||||||
*/
|
*/
|
||||||
if ($mainmenu)
|
if ($mainmenu) // If this is empty, loading hard coded menu and loading personalised menu will fail
|
||||||
{
|
{
|
||||||
/*
|
/*
|
||||||
* Menu HOME
|
* Menu HOME
|
||||||
@ -1628,6 +1630,9 @@ function print_left_eldy_menu($db,$menu_array_before,$menu_array_after,&$tabMenu
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
//var_dump($tabMenu); //
|
||||||
|
//var_dump($newmenu->liste);
|
||||||
|
|
||||||
// Build final $menu_array = $menu_array_before +$newmenu->liste + $menu_array_after
|
// Build final $menu_array = $menu_array_before +$newmenu->liste + $menu_array_after
|
||||||
//var_dump($menu_array_before);exit;
|
//var_dump($menu_array_before);exit;
|
||||||
//var_dump($menu_array_after);exit;
|
//var_dump($menu_array_after);exit;
|
||||||
|
|||||||
@ -31,7 +31,7 @@ class MenuManager
|
|||||||
* @var DoliDB Database handler.
|
* @var DoliDB Database handler.
|
||||||
*/
|
*/
|
||||||
public $db;
|
public $db;
|
||||||
|
|
||||||
var $type_user; // Put 0 for internal users, 1 for external users
|
var $type_user; // Put 0 for internal users, 1 for external users
|
||||||
var $atarget=""; // To store default target to use onto links
|
var $atarget=""; // To store default target to use onto links
|
||||||
var $name="eldy";
|
var $name="eldy";
|
||||||
@ -109,6 +109,7 @@ class MenuManager
|
|||||||
$menuArbo = new Menubase($this->db,'eldy');
|
$menuArbo = new Menubase($this->db,'eldy');
|
||||||
$menuArbo->menuLoad($mainmenu, $leftmenu, $this->type_user, 'eldy', $tabMenu);
|
$menuArbo->menuLoad($mainmenu, $leftmenu, $this->type_user, 'eldy', $tabMenu);
|
||||||
$this->tabMenu=$tabMenu;
|
$this->tabMenu=$tabMenu;
|
||||||
|
//var_dump($tabMenu);
|
||||||
|
|
||||||
//if ($forcemainmenu == 'all') { var_dump($this->tabMenu); exit; }
|
//if ($forcemainmenu == 'all') { var_dump($this->tabMenu); exit; }
|
||||||
}
|
}
|
||||||
@ -116,7 +117,7 @@ class MenuManager
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* Show menu.
|
* Show menu.
|
||||||
* Module defined in sql tables are stored into this->tabMenu BEFORE this is called.
|
* Module defined in sql tables were stored into $this->tabMenu BEFORE this is called.
|
||||||
*
|
*
|
||||||
* @param string $mode 'top', 'topnb', 'left', 'jmobile' (used to get full xml ul/li menu)
|
* @param string $mode 'top', 'topnb', 'left', 'jmobile' (used to get full xml ul/li menu)
|
||||||
* @param array $moredata An array with more data to output
|
* @param array $moredata An array with more data to output
|
||||||
@ -126,6 +127,8 @@ class MenuManager
|
|||||||
{
|
{
|
||||||
global $conf, $langs, $user;
|
global $conf, $langs, $user;
|
||||||
|
|
||||||
|
//var_dump($this->tabMenu);
|
||||||
|
|
||||||
require_once DOL_DOCUMENT_ROOT.'/core/menus/standard/eldy.lib.php';
|
require_once DOL_DOCUMENT_ROOT.'/core/menus/standard/eldy.lib.php';
|
||||||
|
|
||||||
if ($this->type_user == 1)
|
if ($this->type_user == 1)
|
||||||
|
|||||||
@ -70,7 +70,7 @@ class InterfaceLogevents extends DolibarrTriggers
|
|||||||
$date = dol_now();
|
$date = dol_now();
|
||||||
|
|
||||||
// Actions
|
// Actions
|
||||||
/*if ($action == 'USER_LOGIN')
|
if ($action == 'USER_LOGIN')
|
||||||
{
|
{
|
||||||
dol_syslog("Trigger '".$this->name."' for action '$action' launched by ".__FILE__.". id=".$object->id);
|
dol_syslog("Trigger '".$this->name."' for action '$action' launched by ".__FILE__.". id=".$object->id);
|
||||||
|
|
||||||
@ -97,7 +97,7 @@ class InterfaceLogevents extends DolibarrTriggers
|
|||||||
// Initialisation donnees (date,duree,texte,desc)
|
// Initialisation donnees (date,duree,texte,desc)
|
||||||
$text="(UserLogoff,".$object->login.")";
|
$text="(UserLogoff,".$object->login.")";
|
||||||
$desc="(UserLogoff,".$object->login.")";
|
$desc="(UserLogoff,".$object->login.")";
|
||||||
}*/
|
}
|
||||||
if ($action == 'USER_CREATE')
|
if ($action == 'USER_CREATE')
|
||||||
{
|
{
|
||||||
dol_syslog("Trigger '".$this->name."' for action '$action' launched by ".__FILE__.". id=".$object->id);
|
dol_syslog("Trigger '".$this->name."' for action '$action' launched by ".__FILE__.". id=".$object->id);
|
||||||
|
|||||||
@ -623,11 +623,11 @@ if ($step == 2 && $datatoexport)
|
|||||||
}
|
}
|
||||||
if (! empty($objexport->array_export_examplevalues[0][$code]))
|
if (! empty($objexport->array_export_examplevalues[0][$code]))
|
||||||
{
|
{
|
||||||
$htmltext.=$langs->trans("SourceExample").': <b>'.$objexport->array_export_examplevalues[0][$code].'</b><br>';
|
$htmltext.='<b>'.$langs->trans("SourceExample").':</b> '.$objexport->array_export_examplevalues[0][$code].'<br>';
|
||||||
}
|
}
|
||||||
if (! empty($objexport->array_export_TypeFields[0][$code]))
|
if (! empty($objexport->array_export_TypeFields[0][$code]))
|
||||||
{
|
{
|
||||||
$htmltext.=$langs->trans("Type").': <b>'.$objexport->array_export_TypeFields[0][$code].'</b><br>';
|
$htmltext.='<b>'.$langs->trans("Type").':</b> '.$objexport->array_export_TypeFields[0][$code].'<br>';
|
||||||
}
|
}
|
||||||
|
|
||||||
if (isset($array_selected[$code]) && $array_selected[$code])
|
if (isset($array_selected[$code]) && $array_selected[$code])
|
||||||
|
|||||||
@ -21,8 +21,9 @@
|
|||||||
* \ingroup externalsite
|
* \ingroup externalsite
|
||||||
* \brief Page that build two frames: One for menu, the other for the target page to show
|
* \brief Page that build two frames: One for menu, the other for the target page to show
|
||||||
* Usage:
|
* Usage:
|
||||||
* mydomain.com/externalsite/frames.php to show URL set into setup
|
* /externalsite/frames.php to show URL set into setup
|
||||||
* mydomain.com/externalsite/frames.php?keyforcontent to show content defined into conf->global->$keyforcontent
|
* /externalsite/frames.php?keyforcontent=EXTERNAL_SITE_CONTENT_abc to show html text defined into $conf->global->EXTERNAL_SITE_CONTENT_abc
|
||||||
|
* /externalsite/frames.php?keyforcontent=EXTERNAL_SITE_URL_abc to show URL defined into $conf->global->EXTERNAL_SITE_URL_abc
|
||||||
*/
|
*/
|
||||||
|
|
||||||
require '../main.inc.php';
|
require '../main.inc.php';
|
||||||
@ -56,19 +57,58 @@ if (! empty($keyforcontent))
|
|||||||
|
|
||||||
print '<div class="framecontent" style="height: '.($_SESSION['dol_screenheight']-90).'px">';
|
print '<div class="framecontent" style="height: '.($_SESSION['dol_screenheight']-90).'px">';
|
||||||
|
|
||||||
if (! preg_match('/EXTERNAL_SITE_CONTENT_/', $keyforcontent))
|
if (! preg_match('/EXTERNAL_SITE_CONTENT_/', $keyforcontent)
|
||||||
|
&& ! preg_match('/EXTERNAL_SITE_URL_/', $keyforcontent))
|
||||||
{
|
{
|
||||||
$langs->load("errors");
|
$langs->load("errors");
|
||||||
print $langs->trans("Variablekeyforcontentmustbenamed", 'EXTERNAL_SITE_CONTENT_');
|
print $langs->trans("ErrorBadSyntaxForParamKeyForContent", 'EXTERNAL_SITE_CONTENT_', 'EXTERNAL_SITE_URL_');
|
||||||
}
|
}
|
||||||
else if (empty($conf->global->$keyforcontent))
|
else if (empty($conf->global->$keyforcontent))
|
||||||
{
|
{
|
||||||
$langs->load("errors");
|
$langs->load("errors");
|
||||||
print $langs->trans("ErrorNoContentDefinedIntoVar", $keyforcontent);
|
print $langs->trans("ErrorVariableKeyForContentMustBeSet", 'EXTERNAL_SITE_CONTENT_'.$keyforcontent, 'EXTERNAL_SITE_URL_'.$keyforcontent);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
print $conf->global->$keyforcontent;
|
if (preg_match('/EXTERNAL_SITE_CONTENT_/', $keyforcontent))
|
||||||
|
{
|
||||||
|
print $conf->global->$keyforcontent;
|
||||||
|
}
|
||||||
|
elseif (preg_match('/EXTERNAL_SITE_URL_/', $keyforcontent))
|
||||||
|
{
|
||||||
|
/*print "
|
||||||
|
<html>
|
||||||
|
<head>
|
||||||
|
<title>Dolibarr frame for external web site</title>
|
||||||
|
</head>
|
||||||
|
|
||||||
|
<frameset ".(empty($conf->global->MAIN_MENU_INVERT)?"rows":"cols")."=\"".$heightforframes.",*\" border=0 framespacing=0 frameborder=0>
|
||||||
|
<frame name=\"barre\" src=\"frametop.php?mainmenu=".$mainmenu."&leftmenu=".$leftmenu."&idmenu=".$idmenu.($theme?'&theme='.$theme:'').($codelang?'&lang='.$codelang:'')."&nobackground=1\" noresize scrolling=\"NO\" noborder>
|
||||||
|
";
|
||||||
|
print '<frame name="main" src="';
|
||||||
|
print $conf->global->$keyforcontent;
|
||||||
|
print '">';
|
||||||
|
print "
|
||||||
|
<noframes>
|
||||||
|
<body>
|
||||||
|
|
||||||
|
</body>
|
||||||
|
</noframes>
|
||||||
|
</frameset>
|
||||||
|
|
||||||
|
<noframes>
|
||||||
|
<body>
|
||||||
|
<br><div class=\"center\">
|
||||||
|
Sorry, your browser is too old or not correctly configured to view this area.<br>
|
||||||
|
Your browser must support frames.<br>
|
||||||
|
</div>
|
||||||
|
</body>
|
||||||
|
</noframes>
|
||||||
|
|
||||||
|
</html>
|
||||||
|
";*/
|
||||||
|
print '<iframe src="'.$conf->global->$keyforcontent.'"></iframe>';
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
print '<div>';
|
print '<div>';
|
||||||
|
|||||||
@ -1844,6 +1844,7 @@ LoadThirdPartyFromNameOrCreate=Load thirdparty from name (create if not found)
|
|||||||
WithDolTrackingID=Dolibarr Tracking ID found
|
WithDolTrackingID=Dolibarr Tracking ID found
|
||||||
WithoutDolTrackingID=Dolibarr Tracking ID not found
|
WithoutDolTrackingID=Dolibarr Tracking ID not found
|
||||||
FormatZip=Zip
|
FormatZip=Zip
|
||||||
|
MainMenuCode=Menu entry code (mainmenu)
|
||||||
##### Resource ####
|
##### Resource ####
|
||||||
ResourceSetup=Configuration du module Resource
|
ResourceSetup=Configuration du module Resource
|
||||||
UseSearchToSelectResource=Use a search form to choose a resource (rather than a drop-down list).
|
UseSearchToSelectResource=Use a search form to choose a resource (rather than a drop-down list).
|
||||||
|
|||||||
@ -213,6 +213,8 @@ ErrorNoteAlsoThatSubProductCantBeFollowedByLot=Note also that using virtual prod
|
|||||||
ErrorDescRequiredForFreeProductLines=Description is mandatory for lines with free product
|
ErrorDescRequiredForFreeProductLines=Description is mandatory for lines with free product
|
||||||
ErrorAPageWithThisNameOrAliasAlreadyExists=The page/container <strong>%s</strong> has the same name or alternative alias that the one your try to use
|
ErrorAPageWithThisNameOrAliasAlreadyExists=The page/container <strong>%s</strong> has the same name or alternative alias that the one your try to use
|
||||||
ErrorDuringChartLoad=Error when loading chart of account. If few accounts were not loaded, you can still enter them manually.
|
ErrorDuringChartLoad=Error when loading chart of account. If few accounts were not loaded, you can still enter them manually.
|
||||||
|
ErrorBadSyntaxForParamKeyForContent=Bad syntax for param keyforcontent. Must have a value starting with %s or %s
|
||||||
|
ErrorVariableKeyForContentMustBeSet=Error, the constant with name %s (with text content to show) or %s (with external url to show) must be set.
|
||||||
# Warnings
|
# Warnings
|
||||||
WarningPasswordSetWithNoAccount=A password was set for this member. However, no user account was created. So this password is stored but can't be used to login to Dolibarr. It may be used by an external module/interface but if you don't need to define any login nor password for a member, you can disable option "Manage a login for each member" from Member module setup. If you need to manage a login but don't need any password, you can keep this field empty to avoid this warning. Note: Email can also be used as a login if the member is linked to a user.
|
WarningPasswordSetWithNoAccount=A password was set for this member. However, no user account was created. So this password is stored but can't be used to login to Dolibarr. It may be used by an external module/interface but if you don't need to define any login nor password for a member, you can disable option "Manage a login for each member" from Member module setup. If you need to manage a login but don't need any password, you can keep this field empty to avoid this warning. Note: Email can also be used as a login if the member is linked to a user.
|
||||||
WarningMandatorySetupNotComplete=Mandatory setup parameters are not yet defined
|
WarningMandatorySetupNotComplete=Mandatory setup parameters are not yet defined
|
||||||
@ -235,3 +237,4 @@ WarningYourLoginWasModifiedPleaseLogin=Your login was modified. For security pur
|
|||||||
WarningAnEntryAlreadyExistForTransKey=An entry already exists for the translation key for this language
|
WarningAnEntryAlreadyExistForTransKey=An entry already exists for the translation key for this language
|
||||||
WarningNumberOfRecipientIsRestrictedInMassAction=Warning, number of different recipient is limited to <b>%s</b> when using the mass actions on lists
|
WarningNumberOfRecipientIsRestrictedInMassAction=Warning, number of different recipient is limited to <b>%s</b> when using the mass actions on lists
|
||||||
WarningDateOfLineMustBeInExpenseReportRange=Warning, the date of line is not in the range of the expense report
|
WarningDateOfLineMustBeInExpenseReportRange=Warning, the date of line is not in the range of the expense report
|
||||||
|
WarningProjectClosed=Project is closed. You must re-open it before.
|
||||||
@ -225,7 +225,7 @@ AllowToLinkFromOtherCompany=Allow to link project from other company<br><br><u>S
|
|||||||
LatestProjects=Latest %s projects
|
LatestProjects=Latest %s projects
|
||||||
LatestModifiedProjects=Latest %s modified projects
|
LatestModifiedProjects=Latest %s modified projects
|
||||||
OtherFilteredTasks=Other filtered tasks
|
OtherFilteredTasks=Other filtered tasks
|
||||||
NoAssignedTasks=No assigned tasks (assign project/tasks the current user from the top select box to enter time on it)
|
NoAssignedTasks=No assigned tasks found (assign project/tasks the current user from the top select box to enter time on it)
|
||||||
# Comments trans
|
# Comments trans
|
||||||
AllowCommentOnTask=Allow user comments on tasks
|
AllowCommentOnTask=Allow user comments on tasks
|
||||||
AllowCommentOnProject=Allow user comments on projects
|
AllowCommentOnProject=Allow user comments on projects
|
||||||
|
|||||||
@ -500,6 +500,17 @@ if (! defined('NOLOGIN'))
|
|||||||
$_SESSION["dol_loginmesg"]=$langs->trans("ErrorBadValueForCode");
|
$_SESSION["dol_loginmesg"]=$langs->trans("ErrorBadValueForCode");
|
||||||
$test=false;
|
$test=false;
|
||||||
|
|
||||||
|
// Call trigger for the "security events" log
|
||||||
|
$user->trigger_mesg='ErrorBadValueForCode - login='.GETPOST("username","alpha",2);
|
||||||
|
// Call of triggers
|
||||||
|
include_once DOL_DOCUMENT_ROOT . '/core/class/interfaces.class.php';
|
||||||
|
$interface=new Interfaces($db);
|
||||||
|
$result=$interface->run_triggers('USER_LOGIN_FAILED',$user,$user,$langs,$conf);
|
||||||
|
if ($result < 0) {
|
||||||
|
$error++;
|
||||||
|
}
|
||||||
|
// End Call of triggers
|
||||||
|
|
||||||
// Hooks on failed login
|
// Hooks on failed login
|
||||||
$action='';
|
$action='';
|
||||||
$hookmanager->initHooks(array('login'));
|
$hookmanager->initHooks(array('login'));
|
||||||
@ -568,6 +579,17 @@ if (! defined('NOLOGIN'))
|
|||||||
// We set a generic message if not defined inside function checkLoginPassEntity or subfunctions
|
// We set a generic message if not defined inside function checkLoginPassEntity or subfunctions
|
||||||
if (empty($_SESSION["dol_loginmesg"])) $_SESSION["dol_loginmesg"]=$langs->trans("ErrorBadLoginPassword");
|
if (empty($_SESSION["dol_loginmesg"])) $_SESSION["dol_loginmesg"]=$langs->trans("ErrorBadLoginPassword");
|
||||||
|
|
||||||
|
// Call trigger for the "security events" log
|
||||||
|
$user->trigger_mesg=$langs->trans("ErrorBadLoginPassword").' - login='.GETPOST("username","alpha",2);
|
||||||
|
// Call of triggers
|
||||||
|
include_once DOL_DOCUMENT_ROOT.'/core/class/interfaces.class.php';
|
||||||
|
$interface=new Interfaces($db);
|
||||||
|
$result=$interface->run_triggers('USER_LOGIN_FAILED',$user,$user,$langs,$conf,GETPOST("username","alpha",2));
|
||||||
|
if ($result < 0) {
|
||||||
|
$error++;
|
||||||
|
}
|
||||||
|
// End Call of triggers
|
||||||
|
|
||||||
// Hooks on failed login
|
// Hooks on failed login
|
||||||
$action='';
|
$action='';
|
||||||
$hookmanager->initHooks(array('login'));
|
$hookmanager->initHooks(array('login'));
|
||||||
@ -604,12 +626,25 @@ if (! defined('NOLOGIN'))
|
|||||||
$langs->loadLangs(array('main', 'errors'));
|
$langs->loadLangs(array('main', 'errors'));
|
||||||
|
|
||||||
$_SESSION["dol_loginmesg"]=$langs->trans("ErrorCantLoadUserFromDolibarrDatabase",$login);
|
$_SESSION["dol_loginmesg"]=$langs->trans("ErrorCantLoadUserFromDolibarrDatabase",$login);
|
||||||
|
|
||||||
|
$user->trigger_mesg='ErrorCantLoadUserFromDolibarrDatabase - login='.$login;
|
||||||
}
|
}
|
||||||
if ($resultFetchUser < 0)
|
if ($resultFetchUser < 0)
|
||||||
{
|
{
|
||||||
$_SESSION["dol_loginmesg"]=$user->error;
|
$_SESSION["dol_loginmesg"]=$user->error;
|
||||||
|
|
||||||
|
$user->trigger_mesg=$user->error;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Call triggers for the "security events" log
|
||||||
|
include_once DOL_DOCUMENT_ROOT . '/core/class/interfaces.class.php';
|
||||||
|
$interface=new Interfaces($db);
|
||||||
|
$result=$interface->run_triggers('USER_LOGIN_FAILED',$user,$user,$langs,$conf);
|
||||||
|
if ($result < 0) {
|
||||||
|
$error++;
|
||||||
|
}
|
||||||
|
// End call triggers
|
||||||
|
|
||||||
// Hooks on failed login
|
// Hooks on failed login
|
||||||
$action='';
|
$action='';
|
||||||
$hookmanager->initHooks(array('login'));
|
$hookmanager->initHooks(array('login'));
|
||||||
@ -648,12 +683,25 @@ if (! defined('NOLOGIN'))
|
|||||||
$langs->loadLangs(array('main', 'errors'));
|
$langs->loadLangs(array('main', 'errors'));
|
||||||
|
|
||||||
$_SESSION["dol_loginmesg"]=$langs->trans("ErrorCantLoadUserFromDolibarrDatabase",$login);
|
$_SESSION["dol_loginmesg"]=$langs->trans("ErrorCantLoadUserFromDolibarrDatabase",$login);
|
||||||
|
|
||||||
|
$user->trigger_mesg='ErrorCantLoadUserFromDolibarrDatabase - login='.$login;
|
||||||
}
|
}
|
||||||
if ($resultFetchUser < 0)
|
if ($resultFetchUser < 0)
|
||||||
{
|
{
|
||||||
$_SESSION["dol_loginmesg"]=$user->error;
|
$_SESSION["dol_loginmesg"]=$user->error;
|
||||||
|
|
||||||
|
$user->trigger_mesg=$user->error;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Call triggers for the "security events" log
|
||||||
|
include_once DOL_DOCUMENT_ROOT . '/core/class/interfaces.class.php';
|
||||||
|
$interface=new Interfaces($db);
|
||||||
|
$result=$interface->run_triggers('USER_LOGIN_FAILED',$user,$user,$langs,$conf);
|
||||||
|
if ($result < 0) {
|
||||||
|
$error++;
|
||||||
|
}
|
||||||
|
// End call triggers
|
||||||
|
|
||||||
// Hooks on failed login
|
// Hooks on failed login
|
||||||
$action='';
|
$action='';
|
||||||
$hookmanager->initHooks(array('login'));
|
$hookmanager->initHooks(array('login'));
|
||||||
@ -741,6 +789,17 @@ if (! defined('NOLOGIN'))
|
|||||||
|
|
||||||
$loginfo = 'TZ='.$_SESSION["dol_tz"].';TZString='.$_SESSION["dol_tz_string"].';Screen='.$_SESSION["dol_screenwidth"].'x'.$_SESSION["dol_screenheight"];
|
$loginfo = 'TZ='.$_SESSION["dol_tz"].';TZString='.$_SESSION["dol_tz_string"].';Screen='.$_SESSION["dol_screenwidth"].'x'.$_SESSION["dol_screenheight"];
|
||||||
|
|
||||||
|
// Call triggers for the "security events" log
|
||||||
|
$user->trigger_mesg = $loginfo;
|
||||||
|
// Call triggers
|
||||||
|
include_once DOL_DOCUMENT_ROOT . '/core/class/interfaces.class.php';
|
||||||
|
$interface=new Interfaces($db);
|
||||||
|
$result=$interface->run_triggers('USER_LOGIN',$user,$user,$langs,$conf);
|
||||||
|
if ($result < 0) {
|
||||||
|
$error++;
|
||||||
|
}
|
||||||
|
// End call triggers
|
||||||
|
|
||||||
// Hooks on successfull login
|
// Hooks on successfull login
|
||||||
$action='';
|
$action='';
|
||||||
$hookmanager->initHooks(array('login'));
|
$hookmanager->initHooks(array('login'));
|
||||||
@ -752,7 +811,7 @@ if (! defined('NOLOGIN'))
|
|||||||
{
|
{
|
||||||
$db->rollback();
|
$db->rollback();
|
||||||
session_destroy();
|
session_destroy();
|
||||||
dol_print_error($db,'Error in some hooks afterLogin');
|
dol_print_error($db,'Error in some triggers USER_LOGIN or in some hooks afterLogin');
|
||||||
exit;
|
exit;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
@ -1015,7 +1074,7 @@ if (! function_exists("llxHeader"))
|
|||||||
|
|
||||||
if (empty($conf->dol_hide_leftmenu))
|
if (empty($conf->dol_hide_leftmenu))
|
||||||
{
|
{
|
||||||
left_menu('', $help_url, '', '', 1, $title, 1);
|
left_menu('', $help_url, '', '', 1, $title, 1); // $menumanager is retreived with a global $menumanager inside this function
|
||||||
}
|
}
|
||||||
|
|
||||||
// main area
|
// main area
|
||||||
|
|||||||
@ -450,108 +450,118 @@ if ($action == 'create' && $user->rights->projet->creer && (empty($object->third
|
|||||||
|
|
||||||
print load_fiche_titre($langs->trans("NewTask"), '', 'title_project');
|
print load_fiche_titre($langs->trans("NewTask"), '', 'title_project');
|
||||||
|
|
||||||
print '<form action="'.$_SERVER['PHP_SELF'].'" method="POST">';
|
if ($object->statut == Project::STATUS_CLOSED)
|
||||||
print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">';
|
|
||||||
print '<input type="hidden" name="action" value="createtask">';
|
|
||||||
print '<input type="hidden" name="backtopage" value="'.$backtopage.'">';
|
|
||||||
if (! empty($object->id)) print '<input type="hidden" name="id" value="'.$object->id.'">';
|
|
||||||
|
|
||||||
dol_fiche_head('');
|
|
||||||
|
|
||||||
print '<table class="border" width="100%">';
|
|
||||||
|
|
||||||
$defaultref='';
|
|
||||||
$obj = empty($conf->global->PROJECT_TASK_ADDON)?'mod_task_simple':$conf->global->PROJECT_TASK_ADDON;
|
|
||||||
if (! empty($conf->global->PROJECT_TASK_ADDON) && is_readable(DOL_DOCUMENT_ROOT ."/core/modules/project/task/".$conf->global->PROJECT_TASK_ADDON.".php"))
|
|
||||||
{
|
{
|
||||||
require_once DOL_DOCUMENT_ROOT ."/core/modules/project/task/".$conf->global->PROJECT_TASK_ADDON.'.php';
|
print '<div class="warning">';
|
||||||
$modTask = new $obj;
|
$langs->load("errors");
|
||||||
$defaultref = $modTask->getNextValue($object->thirdparty,null);
|
print $langs->trans("WarningProjectClosed");
|
||||||
}
|
print '</div>';
|
||||||
|
|
||||||
if (is_numeric($defaultref) && $defaultref <= 0) $defaultref='';
|
|
||||||
|
|
||||||
// Ref
|
|
||||||
print '<tr><td class="titlefieldcreate"><span class="fieldrequired">'.$langs->trans("Ref").'</span></td><td>';
|
|
||||||
if (empty($duplicate_code_error))
|
|
||||||
{
|
|
||||||
print (GETPOSTISSET("ref")?GETPOST("ref",'alpha'):$defaultref);
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
print $defaultref;
|
print '<form action="'.$_SERVER['PHP_SELF'].'" method="POST">';
|
||||||
|
print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">';
|
||||||
|
print '<input type="hidden" name="action" value="createtask">';
|
||||||
|
print '<input type="hidden" name="backtopage" value="'.$backtopage.'">';
|
||||||
|
if (! empty($object->id)) print '<input type="hidden" name="id" value="'.$object->id.'">';
|
||||||
|
|
||||||
|
dol_fiche_head('');
|
||||||
|
|
||||||
|
print '<table class="border" width="100%">';
|
||||||
|
|
||||||
|
$defaultref='';
|
||||||
|
$obj = empty($conf->global->PROJECT_TASK_ADDON)?'mod_task_simple':$conf->global->PROJECT_TASK_ADDON;
|
||||||
|
if (! empty($conf->global->PROJECT_TASK_ADDON) && is_readable(DOL_DOCUMENT_ROOT ."/core/modules/project/task/".$conf->global->PROJECT_TASK_ADDON.".php"))
|
||||||
|
{
|
||||||
|
require_once DOL_DOCUMENT_ROOT ."/core/modules/project/task/".$conf->global->PROJECT_TASK_ADDON.'.php';
|
||||||
|
$modTask = new $obj;
|
||||||
|
$defaultref = $modTask->getNextValue($object->thirdparty,null);
|
||||||
|
}
|
||||||
|
|
||||||
|
if (is_numeric($defaultref) && $defaultref <= 0) $defaultref='';
|
||||||
|
|
||||||
|
// Ref
|
||||||
|
print '<tr><td class="titlefieldcreate"><span class="fieldrequired">'.$langs->trans("Ref").'</span></td><td>';
|
||||||
|
if (empty($duplicate_code_error))
|
||||||
|
{
|
||||||
|
print (GETPOSTISSET("ref")?GETPOST("ref",'alpha'):$defaultref);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
print $defaultref;
|
||||||
|
}
|
||||||
|
print '<input type="hidden" name="taskref" value="'.($_POST["ref"]?$_POST["ref"]:$defaultref).'">';
|
||||||
|
print '</td></tr>';
|
||||||
|
|
||||||
|
print '<tr><td class="fieldrequired">'.$langs->trans("Label").'</td><td>';
|
||||||
|
print '<input type="text" name="label" autofocus class="minwidth500" value="'.$label.'">';
|
||||||
|
print '</td></tr>';
|
||||||
|
|
||||||
|
// List of projects
|
||||||
|
print '<tr><td class="fieldrequired">'.$langs->trans("ChildOfProjectTask").'</td><td>';
|
||||||
|
print $formother->selectProjectTasks(GETPOST('task_parent'), $projectid?$projectid:$object->id, 'task_parent', 0, 0, 1, 1, 0, '0,1', 'maxwidth500');
|
||||||
|
print '</td></tr>';
|
||||||
|
|
||||||
|
print '<tr><td>'.$langs->trans("AffectedTo").'</td><td>';
|
||||||
|
$contactsofproject=(! empty($object->id)?$object->getListContactId('internal'):'');
|
||||||
|
if (is_array($contactsofproject) && count($contactsofproject))
|
||||||
|
{
|
||||||
|
print $form->select_dolusers($user->id, 'userid', 0, '', 0, '', $contactsofproject, 0, 0, 0, '', 0, '', 'maxwidth300');
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
print $langs->trans("NoUserAssignedToTheProject");
|
||||||
|
}
|
||||||
|
print '</td></tr>';
|
||||||
|
|
||||||
|
// Date start
|
||||||
|
print '<tr><td>'.$langs->trans("DateStart").'</td><td>';
|
||||||
|
print $form->selectDate(($date_start?$date_start:''), 'dateo', 1, 1, 0, '', 1, 1);
|
||||||
|
print '</td></tr>';
|
||||||
|
|
||||||
|
// Date end
|
||||||
|
print '<tr><td>'.$langs->trans("DateEnd").'</td><td>';
|
||||||
|
print $form->selectDate(($date_end?$date_end:-1),'datee', -1, 1, 0, '', 1, 1);
|
||||||
|
print '</td></tr>';
|
||||||
|
|
||||||
|
// Planned workload
|
||||||
|
print '<tr><td>'.$langs->trans("PlannedWorkload").'</td><td>';
|
||||||
|
print $form->select_duration('planned_workload', $planned_workload?$planned_workload : 0, 0, 'text');
|
||||||
|
print '</td></tr>';
|
||||||
|
|
||||||
|
// Progress
|
||||||
|
print '<tr><td>'.$langs->trans("ProgressDeclared").'</td><td colspan="3">';
|
||||||
|
print $formother->select_percent($progress,'progress',0,5,0,100,1);
|
||||||
|
print '</td></tr>';
|
||||||
|
|
||||||
|
// Description
|
||||||
|
print '<tr><td class="tdtop">'.$langs->trans("Description").'</td>';
|
||||||
|
print '<td>';
|
||||||
|
print '<textarea name="description" class="quatrevingtpercent" rows="'.ROWS_4.'">'.$description.'</textarea>';
|
||||||
|
print '</td></tr>';
|
||||||
|
|
||||||
|
// Other options
|
||||||
|
$parameters=array();
|
||||||
|
$reshook=$hookmanager->executeHooks('formObjectOptions',$parameters,$taskstatic,$action); // Note that $action and $object may have been modified by hook
|
||||||
|
print $hookmanager->resPrint;
|
||||||
|
|
||||||
|
if (empty($reshook) && ! empty($extrafields_task->attribute_label))
|
||||||
|
{
|
||||||
|
print $taskstatic->showOptionals($extrafields_task,'edit'); // Do not use $object here that is object of project
|
||||||
|
}
|
||||||
|
|
||||||
|
print '</table>';
|
||||||
|
|
||||||
|
dol_fiche_end();
|
||||||
|
|
||||||
|
print '<div align="center">';
|
||||||
|
print '<input type="submit" class="button" name="add" value="'.$langs->trans("Add").'">';
|
||||||
|
print ' ';
|
||||||
|
print '<input type="submit" class="button" name="cancel" value="'.$langs->trans("Cancel").'">';
|
||||||
|
print '</div>';
|
||||||
|
|
||||||
|
print '</form>';
|
||||||
}
|
}
|
||||||
print '<input type="hidden" name="taskref" value="'.($_POST["ref"]?$_POST["ref"]:$defaultref).'">';
|
|
||||||
print '</td></tr>';
|
|
||||||
|
|
||||||
print '<tr><td class="fieldrequired">'.$langs->trans("Label").'</td><td>';
|
|
||||||
print '<input type="text" name="label" autofocus class="minwidth500" value="'.$label.'">';
|
|
||||||
print '</td></tr>';
|
|
||||||
|
|
||||||
// List of projects
|
|
||||||
print '<tr><td class="fieldrequired">'.$langs->trans("ChildOfProjectTask").'</td><td>';
|
|
||||||
print $formother->selectProjectTasks(GETPOST('task_parent'), $projectid?$projectid:$object->id, 'task_parent', 0, 0, 1, 1, 0, '0,1', 'maxwidth500');
|
|
||||||
print '</td></tr>';
|
|
||||||
|
|
||||||
print '<tr><td>'.$langs->trans("AffectedTo").'</td><td>';
|
|
||||||
$contactsofproject=(! empty($object->id)?$object->getListContactId('internal'):'');
|
|
||||||
if (is_array($contactsofproject) && count($contactsofproject))
|
|
||||||
{
|
|
||||||
print $form->select_dolusers($user->id, 'userid', 0, '', 0, '', $contactsofproject, 0, 0, 0, '', 0, '', 'maxwidth300');
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
print $langs->trans("NoUserAssignedToTheProject");
|
|
||||||
}
|
|
||||||
print '</td></tr>';
|
|
||||||
|
|
||||||
// Date start
|
|
||||||
print '<tr><td>'.$langs->trans("DateStart").'</td><td>';
|
|
||||||
print $form->selectDate(($date_start?$date_start:''), 'dateo', 1, 1, 0, '', 1, 1);
|
|
||||||
print '</td></tr>';
|
|
||||||
|
|
||||||
// Date end
|
|
||||||
print '<tr><td>'.$langs->trans("DateEnd").'</td><td>';
|
|
||||||
print $form->selectDate(($date_end?$date_end:-1),'datee', -1, 1, 0, '', 1, 1);
|
|
||||||
print '</td></tr>';
|
|
||||||
|
|
||||||
// Planned workload
|
|
||||||
print '<tr><td>'.$langs->trans("PlannedWorkload").'</td><td>';
|
|
||||||
print $form->select_duration('planned_workload', $planned_workload?$planned_workload : 0, 0, 'text');
|
|
||||||
print '</td></tr>';
|
|
||||||
|
|
||||||
// Progress
|
|
||||||
print '<tr><td>'.$langs->trans("ProgressDeclared").'</td><td colspan="3">';
|
|
||||||
print $formother->select_percent($progress,'progress',0,5,0,100,1);
|
|
||||||
print '</td></tr>';
|
|
||||||
|
|
||||||
// Description
|
|
||||||
print '<tr><td class="tdtop">'.$langs->trans("Description").'</td>';
|
|
||||||
print '<td>';
|
|
||||||
print '<textarea name="description" class="quatrevingtpercent" rows="'.ROWS_4.'">'.$description.'</textarea>';
|
|
||||||
print '</td></tr>';
|
|
||||||
|
|
||||||
// Other options
|
|
||||||
$parameters=array();
|
|
||||||
$reshook=$hookmanager->executeHooks('formObjectOptions',$parameters,$taskstatic,$action); // Note that $action and $object may have been modified by hook
|
|
||||||
print $hookmanager->resPrint;
|
|
||||||
|
|
||||||
if (empty($reshook) && ! empty($extrafields_task->attribute_label))
|
|
||||||
{
|
|
||||||
print $taskstatic->showOptionals($extrafields_task,'edit'); // Do not use $object here that is object of project
|
|
||||||
}
|
|
||||||
|
|
||||||
print '</table>';
|
|
||||||
|
|
||||||
dol_fiche_end();
|
|
||||||
|
|
||||||
print '<div align="center">';
|
|
||||||
print '<input type="submit" class="button" name="add" value="'.$langs->trans("Add").'">';
|
|
||||||
print ' ';
|
|
||||||
print '<input type="submit" class="button" name="cancel" value="'.$langs->trans("Cancel").'">';
|
|
||||||
print '</div>';
|
|
||||||
|
|
||||||
print '</form>';
|
|
||||||
}
|
}
|
||||||
else if ($id > 0 || ! empty($ref))
|
else if ($id > 0 || ! empty($ref))
|
||||||
{
|
{
|
||||||
|
|||||||
@ -326,7 +326,7 @@ if ($id > 0 || ! empty($ref))
|
|||||||
dol_fiche_end();
|
dol_fiche_end();
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Lignes de contacts
|
* Lines of contacts
|
||||||
*/
|
*/
|
||||||
/*
|
/*
|
||||||
// Contacts lines (modules that overwrite templates must declare this into descriptor)
|
// Contacts lines (modules that overwrite templates must declare this into descriptor)
|
||||||
@ -340,16 +340,15 @@ if ($id > 0 || ! empty($ref))
|
|||||||
|
|
||||||
/*
|
/*
|
||||||
* Add a new contact line
|
* Add a new contact line
|
||||||
* Non affiche en mode modification de ligne
|
|
||||||
*/
|
*/
|
||||||
print '<table class="noborder" width="100%">';
|
print '<table class="noborder" width="100%">';
|
||||||
|
|
||||||
if ($action != 'editline' && $user->rights->projet->creer)
|
if ($action != 'editline' && $user->rights->projet->creer)
|
||||||
{
|
{
|
||||||
print '<tr class="liste_titre">';
|
print '<tr class="liste_titre">';
|
||||||
print '<td>'.$langs->trans("Source").'</td>';
|
print '<td>'.$langs->trans("Nature").'</td>';
|
||||||
print '<td>'.$langs->trans("ThirdParty").'</td>';
|
print '<td>'.$langs->trans("ThirdParty").'</td>';
|
||||||
print '<td>'.$langs->trans("TaskContact").'</td>';
|
print '<td>'.$langs->trans("Users").'</td>';
|
||||||
print '<td>'.$langs->trans("ContactType").'</td>';
|
print '<td>'.$langs->trans("ContactType").'</td>';
|
||||||
print '<td colspan="3"> </td>';
|
print '<td colspan="3"> </td>';
|
||||||
print "</tr>\n";
|
print "</tr>\n";
|
||||||
@ -507,7 +506,7 @@ if ($id > 0 || ! empty($ref))
|
|||||||
{
|
{
|
||||||
print ' ';
|
print ' ';
|
||||||
print '<a href="'.$_SERVER["PHP_SELF"].'?id='.$object->id.'&action=deleteline&lineid='.$tab[$i]['rowid'].($withproject?'&withproject=1':'').'">';
|
print '<a href="'.$_SERVER["PHP_SELF"].'?id='.$object->id.'&action=deleteline&lineid='.$tab[$i]['rowid'].($withproject?'&withproject=1':'').'">';
|
||||||
print img_delete();
|
print img_picto($langs->trans('Unlink'), 'unlink');
|
||||||
print '</a>';
|
print '</a>';
|
||||||
}
|
}
|
||||||
print '</td>';
|
print '</td>';
|
||||||
|
|||||||
@ -907,8 +907,9 @@ div.fiche {
|
|||||||
min-width: 150px;
|
min-width: 150px;
|
||||||
}
|
}
|
||||||
.thumbstat150 {
|
.thumbstat150 {
|
||||||
/* min-width: 170px; */
|
min-width: 170px;
|
||||||
width: 170px;
|
max-wdith: 171px;
|
||||||
|
/* width: 170px; If I use with, there is trouble on size of flex boxes solved with min+max that is a little bit higer than min */
|
||||||
}
|
}
|
||||||
.thumbstat, .thumbstat150 {
|
.thumbstat, .thumbstat150 {
|
||||||
<?php if ($conf->browser->name == 'ie') { ?>
|
<?php if ($conf->browser->name == 'ie') { ?>
|
||||||
|
|||||||
@ -41,13 +41,12 @@ if (!empty($_SESSION["dol_authmode"]) && ($_SESSION["dol_authmode"] == 'forceuse
|
|||||||
|
|
||||||
global $conf, $langs, $user;
|
global $conf, $langs, $user;
|
||||||
|
|
||||||
// Appel des triggers
|
// Call triggers for the "security events" log
|
||||||
// TODO @deprecated Remove this. Hook must be used, not this trigger.
|
include_once DOL_DOCUMENT_ROOT . '/core/class/interfaces.class.php';
|
||||||
//include_once DOL_DOCUMENT_ROOT . '/core/class/interfaces.class.php';
|
$interface=new Interfaces($db);
|
||||||
//$interface=new Interfaces($db);
|
$result=$interface->run_triggers('USER_LOGOUT',$user,$user,$langs,$conf);
|
||||||
//$result=$interface->run_triggers('USER_LOGOUT',$user,$user,$langs,$conf);
|
if ($result < 0) { $error++; }
|
||||||
//if ($result < 0) { $error++; }
|
// End call triggers
|
||||||
// Fin appel triggers
|
|
||||||
|
|
||||||
// Hooks on logout
|
// Hooks on logout
|
||||||
$action='';
|
$action='';
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user