Skip to content

Commit

Permalink
Fix : missing rights test to display tag create link
Browse files Browse the repository at this point in the history
  • Loading branch information
atm-maxime committed May 31, 2019
1 parent 912e29a commit 9ab2f44
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions htdocs/categories/index.php
Expand Up @@ -65,9 +65,12 @@

llxHeader('',$title,'','',0,0,$arrayofjs,$arrayofcss);

$newcardbutton = '<a class="butActionNew" href="'.DOL_URL_ROOT.'/categories/card.php?action=create&type='.$type.'&backtopage='.urlencode($_SERVER["PHP_SELF"].'?type='.$type).'"><span class="valignmiddle">'.$langs->trans("NewCategory").'</span>';
$newcardbutton.= '<span class="fa fa-plus-circle valignmiddle"></span>';
$newcardbutton.= '</a>';
$newcardbutton='';
if($user->rights->categorie->creer) {
$newcardbutton = '<a class="butActionNew" href="'.DOL_URL_ROOT.'/categories/card.php?action=create&type='.$type.'&backtopage='.urlencode($_SERVER["PHP_SELF"].'?type='.$type).'"><span class="valignmiddle">'.$langs->trans("NewCategory").'</span>';
$newcardbutton.= '<span class="fa fa-plus-circle valignmiddle"></span>';
$newcardbutton.= '</a>';
}

print load_fiche_titre($title, $newcardbutton);

Expand Down

0 comments on commit 9ab2f44

Please sign in to comment.