X-Git-Url: http://wagnertech.de/git?a=blobdiff_plain;f=invoice_add.php;h=0e752dca35d6d236329cd4a8be217659ee6ea17b;hb=ad98b13400fdc2fa2299a22c9bd54c4cd27960c3;hp=0efc99eec9b5cdc789e16eb8a372a785b4a1dc7e;hpb=d8baf4e8391fbbe974c58f599fe57059a8cad01c;p=timetracker.git diff --git a/invoice_add.php b/invoice_add.php index 0efc99ee..0e752dca 100644 --- a/invoice_add.php +++ b/invoice_add.php @@ -32,7 +32,7 @@ import('ttTeamHelper'); import('ttInvoiceHelper'); // Access check. -if (!ttAccessCheck(right_manage_team)) { +if (!ttAccessCheck(right_manage_team) || !$user->isPluginEnabled('iv')) { header('Location: access_denied.php'); exit(); } @@ -50,7 +50,7 @@ $form = new Form('invoiceForm'); $form->addInput(array('type'=>'datefield','name'=>'date','size'=>'20','value'=>$cl_date)); // Dropdown for clients if the clients plugin is enabled. -if (in_array('cl', explode(',', $user->plugins))) { +if ($user->isPluginEnabled('cl')) { $clients = ttTeamHelper::getActiveClients($user->team_id); $form->addInput(array('type'=>'combobox','name'=>'client','style'=>'width: 250px;','data'=>$clients,'datakeys'=>array('id','name'),'value'=>$cl_client,'empty'=>array(''=>$i18n->getKey('dropdown.select')))); }