diff --git a/include/class.config.php b/include/class.config.php index 7d1a9013656597bd7a3d4575c4f8253737b8c531..5d9301cf82388aa95eb566489771214a185b18f7 100644 --- a/include/class.config.php +++ b/include/class.config.php @@ -296,10 +296,6 @@ class OsticketConfig extends Config { return $this->get('passwd_reset_period'); } - function showRelatedTickets() { - return $this->get('show_related_tickets'); - } - function isHtmlThreadEnabled() { return $this->get('enable_html_thread'); } diff --git a/include/class.nav.php b/include/class.nav.php index 4cdd222fc5dc12a44f8249ecd742a2b388395b53..50cfb3b1eaa0e0d5b21e4c23ca709a9271f135a9 100644 --- a/include/class.nav.php +++ b/include/class.nav.php @@ -282,7 +282,7 @@ class UserNav { $navs['new']=array('desc'=>'Open New Ticket','href'=>'open.php','title'=>''); if($user && $user->isValid()) { - if(!$user->isGuest() && $cfg && $cfg->showRelatedTickets()) { + if(!$user->isGuest()) { $navs['tickets']=array('desc'=>sprintf('Tickets (%d)',$user->getNumTickets()), 'href'=>'tickets.php', 'title'=>'Show all tickets'); diff --git a/include/client/header.inc.php b/include/client/header.inc.php index 707c50241d31795e6015217716ac6e26a2dd5725..7826f442f0350554ff60e5abf3ba5389d7dd4bea 100644 --- a/include/client/header.inc.php +++ b/include/client/header.inc.php @@ -48,11 +48,7 @@ header("Content-Type: text/html; charset=UTF-8\r\n"); echo Format::htmlchars($thisclient->getName()).' |'; ?> <a href="<?php echo ROOT_PATH; ?>account.php">Profile</a> | - <?php - if($cfg->showRelatedTickets()) {?> <a href="<?php echo ROOT_PATH; ?>tickets.php">Tickets <b>(<?php echo $thisclient->getNumTickets(); ?>)</b></a> - - <?php - } ?> <a href="<?php echo ROOT_PATH; ?>logout.php?auth=<?php echo $ost->getLinkToken(); ?>">Log Out</a> <?php }elseif($nav){ ?> diff --git a/include/client/tickets.inc.php b/include/client/tickets.inc.php index 1c227ba4cdec255b7e75607abfeab143e549d305..b355e2265d69e7c6121474edc41f414c4c3cee37 100644 --- a/include/client/tickets.inc.php +++ b/include/client/tickets.inc.php @@ -1,5 +1,5 @@ <?php -if(!defined('OSTCLIENTINC') || !is_object($thisclient) || !$thisclient->isValid() || !$cfg->showRelatedTickets()) die('Access Denied'); +if(!defined('OSTCLIENTINC') || !is_object($thisclient) || !$thisclient->isValid()) die('Access Denied'); $qstr='&'; //Query string collector $status=null; diff --git a/include/staff/settings-tickets.inc.php b/include/staff/settings-tickets.inc.php index c3d204328c300e9f8d3235883cf52b1227a14499..796ffcdd1bca64af46cac9282d991aa2066dbbd5 100644 --- a/include/staff/settings-tickets.inc.php +++ b/include/staff/settings-tickets.inc.php @@ -76,13 +76,6 @@ if(!($maxfileuploads=ini_get('max_file_uploads'))) <em>(Minutes to lock a ticket on activity - enter 0 to disable locking)</em> </td> </tr> - <tr> - <td width="180">Show Related Tickets:</td> - <td> - <input type="checkbox" name="show_related_tickets" value="1" <?php echo $config['show_related_tickets'] ?'checked="checked"':''; ?> > - <em>(Show all related tickets on user login - otherwise access is restricted to one ticket view per login)</em> - </td> - </tr> <tr> <td>Human Verification:</td> <td> diff --git a/include/upgrader/streams/core/f5692e24-4323a6a8.patch.sql b/include/upgrader/streams/core/f5692e24-4323a6a8.patch.sql index 0a31b1a0eaad16672c31707c908dfe224226db87..aa672ccc9349c0a90b2888d8d96361017a7c58e3 100644 --- a/include/upgrader/streams/core/f5692e24-4323a6a8.patch.sql +++ b/include/upgrader/streams/core/f5692e24-4323a6a8.patch.sql @@ -85,6 +85,9 @@ CREATE TABLE `%TABLE_PREFIX%organization` ( PRIMARY KEY (`id`) ) DEFAULT CHARSET=utf8; +DELETE FROM `%TABLE_PREFIX%config` where `namespace`='core' + AND `key` = 'show_related_tickets'; + -- Finished with patch UPDATE `%TABLE_PREFIX%config` SET `value` = '4323a6a81c35efbf7722b7fc4e475440' diff --git a/tickets.php b/tickets.php index 1580119830d1f7d6b11bf40c54589446ca834f37..35bf1a0cfffeed927748c8a60d571502e70766cd 100644 --- a/tickets.php +++ b/tickets.php @@ -102,7 +102,7 @@ if($ticket && $ticket->checkUserAccess($thisclient)) { } else $inc='view.inc.php'; -} elseif($cfg->showRelatedTickets() && $thisclient->getNumTickets()) { +} elseif($thisclient->getNumTickets()) { $inc='tickets.inc.php'; } else { $nav->setActiveNav('new');