Fix: Permission on projects
This commit is contained in:
parent
3e767382e8
commit
7d93be786b
11
.project
11
.project
@ -5,16 +5,6 @@
|
|||||||
<projects>
|
<projects>
|
||||||
</projects>
|
</projects>
|
||||||
<buildSpec>
|
<buildSpec>
|
||||||
<buildCommand>
|
|
||||||
<name>org.eclipse.mylyn.wikitext.ui.wikiTextValidationBuilder</name>
|
|
||||||
<arguments>
|
|
||||||
</arguments>
|
|
||||||
</buildCommand>
|
|
||||||
<buildCommand>
|
|
||||||
<name>org.eclipse.dltk.core.scriptbuilder</name>
|
|
||||||
<arguments>
|
|
||||||
</arguments>
|
|
||||||
</buildCommand>
|
|
||||||
<buildCommand>
|
<buildCommand>
|
||||||
<name>org.eclipse.php.core.PhpIncrementalProjectBuilder</name>
|
<name>org.eclipse.php.core.PhpIncrementalProjectBuilder</name>
|
||||||
<arguments>
|
<arguments>
|
||||||
@ -28,6 +18,5 @@
|
|||||||
</buildSpec>
|
</buildSpec>
|
||||||
<natures>
|
<natures>
|
||||||
<nature>org.eclipse.php.core.PHPNature</nature>
|
<nature>org.eclipse.php.core.PHPNature</nature>
|
||||||
<nature>org.eclipse.mylyn.wikitext.ui.wikiTextNature</nature>
|
|
||||||
</natures>
|
</natures>
|
||||||
</projectDescription>
|
</projectDescription>
|
||||||
|
|||||||
@ -626,7 +626,7 @@ function print_projecttasks_array($db,$mine,$socid,$projectsListId)
|
|||||||
$sql.= " LEFT JOIN ".MAIN_DB_PREFIX."projet_task as t ON p.rowid = t.fk_projet";
|
$sql.= " LEFT JOIN ".MAIN_DB_PREFIX."projet_task as t ON p.rowid = t.fk_projet";
|
||||||
$sql.= " WHERE p.entity = ".$conf->entity;
|
$sql.= " WHERE p.entity = ".$conf->entity;
|
||||||
if ($mine) $sql.= " AND p.rowid IN (".$projectsListId.")";
|
if ($mine) $sql.= " AND p.rowid IN (".$projectsListId.")";
|
||||||
if ($socid) $sql.= " AND p.fk_soc = ".$socid;
|
if ($socid || ! $user->rights->societe->client->voir) $sql.= " AND (p.fk_soc IS NULL OR p.fk_soc = 0 OR p.fk_soc = ".$socid.")";
|
||||||
$sql.= " GROUP BY p.rowid, p.ref, p.title, p.fk_user_creat, p.public, p.fk_statut";
|
$sql.= " GROUP BY p.rowid, p.ref, p.title, p.fk_user_creat, p.public, p.fk_statut";
|
||||||
|
|
||||||
$var=true;
|
$var=true;
|
||||||
|
|||||||
@ -84,7 +84,7 @@ $sql.= " FROM ".MAIN_DB_PREFIX."projet as p";
|
|||||||
$sql.= " LEFT JOIN ".MAIN_DB_PREFIX."societe as s on p.fk_soc = s.rowid";
|
$sql.= " LEFT JOIN ".MAIN_DB_PREFIX."societe as s on p.fk_soc = s.rowid";
|
||||||
$sql.= " WHERE p.entity = ".$conf->entity;
|
$sql.= " WHERE p.entity = ".$conf->entity;
|
||||||
if (! $user->rights->projet->all->lire) $sql.= " AND p.rowid IN (".$projectsListId.")";
|
if (! $user->rights->projet->all->lire) $sql.= " AND p.rowid IN (".$projectsListId.")";
|
||||||
if ($socid) $sql.= " AND s.rowid = ".$socid;
|
if ($socid || ! $user->rights->societe->client->voir) $sql.= " AND (p.fk_soc IS NULL OR p.fk_soc = 0 OR p.fk_soc = ".$socid.")";
|
||||||
$sql.= " GROUP BY s.nom, s.rowid";
|
$sql.= " GROUP BY s.nom, s.rowid";
|
||||||
|
|
||||||
$var=true;
|
$var=true;
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user