/** * Construct and connect to BTS. * * @param str $type (see tlIssueTracker.class.php $systems property) * @param xml $cfg **/ function __construct($type, $config, $name) { // connect() to DATABASE is done here parent::__construct($type, $config, $name); if (!$this->isConnected()) { return false; } $this->methodOpt['buildViewBugLink'] = array('addSummary' => true, 'colorByStatus' => true); $this->interfaceViaDB = true; $this->support = new jiraCommons(); $this->support->guiCfg = array('use_decoration' => true); // Tables used $this->dbSchema = new stdClass(); $this->dbSchema->issues = 'jiraissue'; $this->dbSchema->status = 'issuestatus'; $this->dbSchema->project = 'project'; $this->getStatuses(); if (property_exists($this->cfg, 'statuscfg')) { $this->setStatusCfg(); } if (!property_exists($this->cfg, 'jiraversion')) { // throw new Exception("jiraversion is MANDATORY - Unable to continue"); $msg = " - Issuetracker {$this->name} - jiraversion is MANDATORY - Unable to continue"; tLog(__METHOD__ . $msg, 'ERROR'); return false; } else { $this->completeCfg(); } $this->defaultResolvedStatus = $this->support->initDefaultResolvedStatus($this->statusDomain); $this->setResolvedStatusCfg(); }
/** * Construct and connect to BTS. * * @param str $type (see tlIssueTracker.class.php $systems property) * @param xml $cfg **/ function __construct($type, $config) { parent::__construct($type, $config); $this->interfaceViaDB = true; $this->guiCfg = array('use_decoration' => true); // add [] on summary $this->methodOpt['buildViewBugLink'] = array('addSummary' => true, 'colorByStatus' => false); }
/** * Construct and connect to BTS. * * @param str $type (see tlIssueTracker.class.php $systems property) * @param xml $cfg **/ function __construct($type, $config, $name) { parent::__construct($type, $config, $name); if ($this->connected) { // For bugzilla status code is not important. // Design Choice make it equal to verbose. Important bugzilla uses UPPERCASE $this->defaultResolvedStatus = array(); $this->defaultResolvedStatus[] = array('code' => 'RESOLVED', 'verbose' => 'RESOLVED'); $this->defaultResolvedStatus[] = array('code' => 'VERIFIED', 'verbose' => 'VERIFIED'); $this->defaultResolvedStatus[] = array('code' => 'CLOSED', 'verbose' => 'CLOSED'); $this->setResolvedStatusCfg(); $this->interfaceViaDB = true; $this->guiCfg = array('use_decoration' => true); // add [] on summary $this->methodOpt['buildViewBugLink'] = array('addSummary' => true, 'colorByStatus' => false); } }
/** * Construct and connect to BTS. * * @param str $type (see tlIssueTracker.class.php $systems property) * @param xml $cfg **/ function __construct($type, $config, $name) { parent::__construct($type, $config, $name); if (!$this->isConnected()) { return false; } $this->interfaceViaDB = true; $this->defaultResolvedStatus = array(); $this->defaultResolvedStatus[] = array('code' => 80, 'verbose' => 'resolved'); $this->defaultResolvedStatus[] = array('code' => 90, 'verbose' => 'closed'); $this->setResolvedStatusCfg(); $this->methodOpt['buildViewBugLink'] = array('addSummary' => true, 'colorByStatus' => true); $this->guiCfg = array('use_decoration' => true); if (property_exists($this->cfg, 'statuscfg')) { $this->setStatusCfg(); } }
function buildViewBugLink($bugID, $addSummary = false) { $linkVerbose = parent::buildViewBugLink($bugID, $addSummary); $status = $this->getBugStatus($bugID); $color = isset($this->status_color[$status]) ? $this->status_color[$status] : 'white'; $title = lang_get('access_to_bts'); return "<div title=\"{$title}\" style=\"display: inline; background: {$color};\">{$linkVerbose}</div>"; }