FIX #7730
This commit is contained in:
parent
0dea2b08c2
commit
0e66d26d06
@ -368,13 +368,12 @@ if ($type == Categorie::TYPE_PRODUCT)
|
|||||||
print '<td class="tdtop">'.$prod->label."</td>\n";
|
print '<td class="tdtop">'.$prod->label."</td>\n";
|
||||||
// Link to delete from category
|
// Link to delete from category
|
||||||
print '<td align="right">';
|
print '<td align="right">';
|
||||||
$typeid=$object->type;
|
|
||||||
$permission=0;
|
$permission=0;
|
||||||
if ($typeid == Categorie::TYPE_PRODUCT) $permission=($user->rights->produit->creer || $user->rights->service->creer);
|
if ($type == Categorie::TYPE_PRODUCT) $permission=($user->rights->produit->creer || $user->rights->service->creer);
|
||||||
if ($typeid == Categorie::TYPE_SUPPLIER) $permission=$user->rights->societe->creer;
|
if ($type == Categorie::TYPE_SUPPLIER) $permission=$user->rights->societe->creer;
|
||||||
if ($typeid == Categorie::TYPE_CUSTOMER) $permission=$user->rights->societe->creer;
|
if ($type == Categorie::TYPE_CUSTOMER) $permission=$user->rights->societe->creer;
|
||||||
if ($typeid == Categorie::TYPE_MEMBER) $permission=$user->rights->adherent->creer;
|
if ($type == Categorie::TYPE_MEMBER) $permission=$user->rights->adherent->creer;
|
||||||
if ($typeid == Categorie::TYPE_PROJECT) $permission=$user->rights->projet->creer;
|
if ($type == Categorie::TYPE_PROJECT) $permission=$user->rights->projet->creer;
|
||||||
if ($permission)
|
if ($permission)
|
||||||
{
|
{
|
||||||
print "<a href= '".$_SERVER['PHP_SELF']."?".(empty($socid)?'id':'socid')."=".$object->id."&type=".$typeid."&removeelem=".$prod->id."'>";
|
print "<a href= '".$_SERVER['PHP_SELF']."?".(empty($socid)?'id':'socid')."=".$object->id."&type=".$typeid."&removeelem=".$prod->id."'>";
|
||||||
@ -416,13 +415,12 @@ if ($type == Categorie::TYPE_SUPPLIER)
|
|||||||
print "</td>\n";
|
print "</td>\n";
|
||||||
// Link to delete from category
|
// Link to delete from category
|
||||||
print '<td align="right">';
|
print '<td align="right">';
|
||||||
$typeid=$object->type;
|
|
||||||
$permission=0;
|
$permission=0;
|
||||||
if ($typeid == Categorie::TYPE_PRODUCT) $permission=($user->rights->produit->creer || $user->rights->service->creer);
|
if ($type == Categorie::TYPE_PRODUCT) $permission=($user->rights->produit->creer || $user->rights->service->creer);
|
||||||
if ($typeid == Categorie::TYPE_SUPPLIER) $permission=$user->rights->societe->creer;
|
if ($type == Categorie::TYPE_SUPPLIER) $permission=$user->rights->societe->creer;
|
||||||
if ($typeid == Categorie::TYPE_CUSTOMER) $permission=$user->rights->societe->creer;
|
if ($type == Categorie::TYPE_CUSTOMER) $permission=$user->rights->societe->creer;
|
||||||
if ($typeid == Categorie::TYPE_MEMBER) $permission=$user->rights->adherent->creer;
|
if ($type == Categorie::TYPE_MEMBER) $permission=$user->rights->adherent->creer;
|
||||||
if ($typeid == Categorie::TYPE_PROJECT) $permission=$user->rights->projet->creer;
|
if ($type == Categorie::TYPE_PROJECT) $permission=$user->rights->projet->creer;
|
||||||
if ($permission)
|
if ($permission)
|
||||||
{
|
{
|
||||||
print "<a href= '".$_SERVER['PHP_SELF']."?".(empty($socid)?'id':'socid')."=".$object->id."&type=".$typeid."&removeelem=".$soc->id."'>";
|
print "<a href= '".$_SERVER['PHP_SELF']."?".(empty($socid)?'id':'socid')."=".$object->id."&type=".$typeid."&removeelem=".$soc->id."'>";
|
||||||
@ -470,13 +468,12 @@ if($type == Categorie::TYPE_CUSTOMER)
|
|||||||
print "</td>\n";
|
print "</td>\n";
|
||||||
// Link to delete from category
|
// Link to delete from category
|
||||||
print '<td align="right">';
|
print '<td align="right">';
|
||||||
$typeid=$object->type;
|
|
||||||
$permission=0;
|
$permission=0;
|
||||||
if ($typeid == Categorie::TYPE_PRODUCT) $permission=($user->rights->produit->creer || $user->rights->service->creer);
|
if ($type == Categorie::TYPE_PRODUCT) $permission=($user->rights->produit->creer || $user->rights->service->creer);
|
||||||
if ($typeid == Categorie::TYPE_SUPPLIER) $permission=$user->rights->societe->creer;
|
if ($type == Categorie::TYPE_SUPPLIER) $permission=$user->rights->societe->creer;
|
||||||
if ($typeid == Categorie::TYPE_CUSTOMER) $permission=$user->rights->societe->creer;
|
if ($type == Categorie::TYPE_CUSTOMER) $permission=$user->rights->societe->creer;
|
||||||
if ($typeid == Categorie::TYPE_MEMBER) $permission=$user->rights->adherent->creer;
|
if ($type == Categorie::TYPE_MEMBER) $permission=$user->rights->adherent->creer;
|
||||||
if ($typeid == Categorie::TYPE_PROJECT) $permission=$user->rights->projet->creer;
|
if ($type == Categorie::TYPE_PROJECT) $permission=$user->rights->projet->creer;
|
||||||
if ($permission)
|
if ($permission)
|
||||||
{
|
{
|
||||||
print "<a href= '".$_SERVER['PHP_SELF']."?".(empty($socid)?'id':'socid')."=".$object->id."&type=".$typeid."&removeelem=".$soc->id."'>";
|
print "<a href= '".$_SERVER['PHP_SELF']."?".(empty($socid)?'id':'socid')."=".$object->id."&type=".$typeid."&removeelem=".$soc->id."'>";
|
||||||
@ -524,13 +521,12 @@ if ($type == Categorie::TYPE_MEMBER)
|
|||||||
print '<td class="tdtop">'.$member->firstname."</td>\n";
|
print '<td class="tdtop">'.$member->firstname."</td>\n";
|
||||||
// Link to delete from category
|
// Link to delete from category
|
||||||
print '<td align="right">';
|
print '<td align="right">';
|
||||||
$typeid=$object->type;
|
|
||||||
$permission=0;
|
$permission=0;
|
||||||
if ($typeid == Categorie::TYPE_PRODUCT) $permission=($user->rights->produit->creer || $user->rights->service->creer);
|
if ($type == Categorie::TYPE_PRODUCT) $permission=($user->rights->produit->creer || $user->rights->service->creer);
|
||||||
if ($typeid == Categorie::TYPE_SUPPLIER) $permission=$user->rights->societe->creer;
|
if ($type == Categorie::TYPE_SUPPLIER) $permission=$user->rights->societe->creer;
|
||||||
if ($typeid == Categorie::TYPE_CUSTOMER) $permission=$user->rights->societe->creer;
|
if ($type == Categorie::TYPE_CUSTOMER) $permission=$user->rights->societe->creer;
|
||||||
if ($typeid == Categorie::TYPE_MEMBER) $permission=$user->rights->adherent->creer;
|
if ($type == Categorie::TYPE_MEMBER) $permission=$user->rights->adherent->creer;
|
||||||
if ($typeid == Categorie::TYPE_PROJECT) $permission=$user->rights->projet->creer;
|
if ($type == Categorie::TYPE_PROJECT) $permission=$user->rights->projet->creer;
|
||||||
if ($permission)
|
if ($permission)
|
||||||
{
|
{
|
||||||
print "<a href= '".$_SERVER['PHP_SELF']."?".(empty($socid)?'id':'socid')."=".$object->id."&type=".$typeid."&removeelem=".$member->id."'>";
|
print "<a href= '".$_SERVER['PHP_SELF']."?".(empty($socid)?'id':'socid')."=".$object->id."&type=".$typeid."&removeelem=".$member->id."'>";
|
||||||
@ -575,14 +571,12 @@ if ($type == Categorie::TYPE_CONTACT)
|
|||||||
print "</td>\n";
|
print "</td>\n";
|
||||||
// Link to delete from category
|
// Link to delete from category
|
||||||
print '<td align="right">';
|
print '<td align="right">';
|
||||||
$typeid=$object->type;
|
|
||||||
$permission=0;
|
$permission=0;
|
||||||
if ($typeid == Categorie::TYPE_PRODUCT) $permission=($user->rights->produit->creer || $user->rights->service->creer);
|
if ($type == Categorie::TYPE_PRODUCT) $permission=($user->rights->produit->creer || $user->rights->service->creer);
|
||||||
if ($typeid == Categorie::TYPE_SUPPLIER) $permission=$user->rights->societe->creer;
|
if ($type == Categorie::TYPE_SUPPLIER) $permission=$user->rights->societe->creer;
|
||||||
if ($typeid == Categorie::TYPE_CUSTOMER) $permission=$user->rights->societe->creer;
|
if ($type == Categorie::TYPE_CUSTOMER) $permission=$user->rights->societe->creer;
|
||||||
if ($typeid == Categorie::TYPE_MEMBER) $permission=$user->rights->adherent->creer;
|
if ($type == Categorie::TYPE_MEMBER) $permission=$user->rights->adherent->creer;
|
||||||
if ($typeid == Categorie::TYPE_CONTACT) $permission=$user->rights->societe->creer;
|
if ($type == Categorie::TYPE_PROJECT) $permission=$user->rights->projet->creer;
|
||||||
if ($typeid == Categorie::TYPE_PROJECT) $permission=$user->rights->projet->creer;
|
|
||||||
if ($permission)
|
if ($permission)
|
||||||
{
|
{
|
||||||
print "<a href= '".$_SERVER['PHP_SELF']."?".(empty($socid)?'id':'socid')."=".$object->id."&type=".$typeid."&removeelem=".$contact->id."'>";
|
print "<a href= '".$_SERVER['PHP_SELF']."?".(empty($socid)?'id':'socid')."=".$object->id."&type=".$typeid."&removeelem=".$contact->id."'>";
|
||||||
@ -629,14 +623,12 @@ if ($type == Categorie::TYPE_ACCOUNT)
|
|||||||
print '<td class="tdtop">'.$account->number."</td>\n";
|
print '<td class="tdtop">'.$account->number."</td>\n";
|
||||||
// Link to delete from category
|
// Link to delete from category
|
||||||
print '<td align="right">';
|
print '<td align="right">';
|
||||||
$typeid=$object->type;
|
|
||||||
$permission=0;
|
$permission=0;
|
||||||
if ($typeid == Categorie::TYPE_PRODUCT) $permission=($user->rights->produit->creer || $user->rights->service->creer);
|
if ($type == Categorie::TYPE_PRODUCT) $permission=($user->rights->produit->creer || $user->rights->service->creer);
|
||||||
if ($typeid == Categorie::TYPE_SUPPLIER) $permission=$user->rights->societe->creer;
|
if ($type == Categorie::TYPE_SUPPLIER) $permission=$user->rights->societe->creer;
|
||||||
if ($typeid == Categorie::TYPE_CUSTOMER) $permission=$user->rights->societe->creer;
|
if ($type == Categorie::TYPE_CUSTOMER) $permission=$user->rights->societe->creer;
|
||||||
if ($typeid == Categorie::TYPE_MEMBER) $permission=$user->rights->adherent->creer;
|
if ($type == Categorie::TYPE_MEMBER) $permission=$user->rights->adherent->creer;
|
||||||
if ($typeid == Categorie::TYPE_ACCOUNT) $permission=$user->rights->banque->configurer;
|
if ($type == Categorie::TYPE_PROJECT) $permission=$user->rights->projet->creer;
|
||||||
if ($typeid == Categorie::TYPE_PROJECT) $permission=$user->rights->projet->creer;
|
|
||||||
if ($permission)
|
if ($permission)
|
||||||
{
|
{
|
||||||
print "<a href= '".$_SERVER['PHP_SELF']."?".(empty($socid)?'id':'socid')."=".$object->id."&type=".$typeid."&removeelem=".$account->id."'>";
|
print "<a href= '".$_SERVER['PHP_SELF']."?".(empty($socid)?'id':'socid')."=".$object->id."&type=".$typeid."&removeelem=".$account->id."'>";
|
||||||
@ -682,14 +674,12 @@ if ($type == Categorie::TYPE_PROJECT)
|
|||||||
print '<td class="tdtop">'.$project->title."</td>\n";
|
print '<td class="tdtop">'.$project->title."</td>\n";
|
||||||
// Link to delete from category
|
// Link to delete from category
|
||||||
print '<td align="right">';
|
print '<td align="right">';
|
||||||
$typeid=$object->type;
|
|
||||||
$permission=0;
|
$permission=0;
|
||||||
if ($typeid == Categorie::TYPE_PRODUCT) $permission=($user->rights->produit->creer || $user->rights->service->creer);
|
if ($type == Categorie::TYPE_PRODUCT) $permission=($user->rights->produit->creer || $user->rights->service->creer);
|
||||||
if ($typeid == Categorie::TYPE_SUPPLIER) $permission=$user->rights->societe->creer;
|
if ($type == Categorie::TYPE_SUPPLIER) $permission=$user->rights->societe->creer;
|
||||||
if ($typeid == Categorie::TYPE_CUSTOMER) $permission=$user->rights->societe->creer;
|
if ($type == Categorie::TYPE_CUSTOMER) $permission=$user->rights->societe->creer;
|
||||||
if ($typeid == Categorie::TYPE_MEMBER) $permission=$user->rights->adherent->creer;
|
if ($type == Categorie::TYPE_MEMBER) $permission=$user->rights->adherent->creer;
|
||||||
if ($typeid == Categorie::TYPE_ACCOUNT) $permission=$user->rights->banque->configurer;
|
if ($type == Categorie::TYPE_PROJECT) $permission=$user->rights->projet->creer;
|
||||||
if ($typeid == Categorie::TYPE_PROJECT) $permission=$user->rights->projet->creer;
|
|
||||||
if ($permission)
|
if ($permission)
|
||||||
{
|
{
|
||||||
print "<a href= '".$_SERVER['PHP_SELF']."?".(empty($socid)?'id':'socid')."=".$object->id."&type=".$typeid."&removeelem=".$project->id."'>";
|
print "<a href= '".$_SERVER['PHP_SELF']."?".(empty($socid)?'id':'socid')."=".$object->id."&type=".$typeid."&removeelem=".$project->id."'>";
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user