diff --git a/api/v1/entries/user.php b/api/v1/entries/user.php index b3d9f377e8..4899de5f9a 100644 --- a/api/v1/entries/user.php +++ b/api/v1/entries/user.php @@ -298,7 +298,7 @@ class userEntry extends entry $info->issue = array('total' => 0, 'issues' => array()); if(!common::hasPriv('my', 'work')) break; - if($this->config->edition== 'max' or $this->config->edition == 'ipd') + if($this->config->edition == 'max' or $this->config->edition == 'ipd') { global $app; $app->rawMethod = 'work'; @@ -318,7 +318,7 @@ class userEntry extends entry $info->risk = array('total' => 0, 'risks' => array()); if(!common::hasPriv('my', 'work')) break; - if($this->config->edition== 'max' or $this->config->edition == 'ipd') + if($this->config->edition == 'max' or $this->config->edition == 'ipd') { global $app; $app->rawMethod = 'work'; @@ -338,7 +338,7 @@ class userEntry extends entry $info->meeting = array('total' => 0, 'meetings' => array()); if(!common::hasPriv('my', 'work')) break; - if($this->config->edition== 'max' or $this->config->edition == 'ipd') + if($this->config->edition == 'max' or $this->config->edition == 'ipd') { global $app; $app->rawMethod = 'work'; diff --git a/module/action/model.php b/module/action/model.php index 6d6207b209..b234182470 100755 --- a/module/action/model.php +++ b/module/action/model.php @@ -563,7 +563,7 @@ class actionModel extends model $name = $this->dao->select('name')->from(TABLE_TESTSUITE)->where('id')->eq($action->extra)->fetch('name'); if($name) $action->extra = common::hasPriv('caselib', 'browse') ? html::a(helper::createLink('caselib', 'browse', "libID=$action->extra"), $name) : $name; } - elseif(strpos(',importfromstorylib,importfromrisklib,importfromissuelib,importfromopportunitylib,', ",{$actionName},") !== false and $this->config->edition == 'max') + elseif(strpos(',importfromstorylib,importfromrisklib,importfromissuelib,importfromopportunitylib,', ",{$actionName},") !== false and ($this->config->edition == 'max' or $this->config->edition == 'ipd')) { $name = $this->dao->select('name')->from(TABLE_ASSETLIB)->where('id')->eq($action->extra)->fetch('name'); if($name) $action->extra = common::hasPriv('assetlib', $action->objectType) ? html::a(helper::createLink('assetlib', $action->objectType, "libID=$action->extra"), $name) : $name; @@ -939,7 +939,7 @@ class actionModel extends model $this->app->loadLang('mr'); $desc = sprintf($this->lang->mr->$mrAction, $mrDate, $mrActor, $mrLink); } - elseif($this->config->edition == 'max' and strpos($this->config->action->assetType, ",{$action->objectType},") !== false and $action->action == 'approved') + elseif(($this->config->edition == 'max' or $this->config->edition == 'ipd') and strpos($this->config->action->assetType, ",{$action->objectType},") !== false and $action->action == 'approved') { $desc = empty($this->lang->action->approve->{$action->extra}) ? '' : $this->lang->action->approve->{$action->extra}; } @@ -1574,7 +1574,7 @@ class actionModel extends model } } - if($this->config->edition == 'max' and $objectType == 'assetlib') + if(($this->config->edition == 'max' or $this->config->edition == 'ipd') and $objectType == 'assetlib') { $libType = $this->dao->select('type')->from(TABLE_ASSETLIB)->where('id')->eq($objectID)->fetch('type'); if(strpos('story,issue,risk,opportunity,practice,component', $libType) !== false) $actionObjectLabel = $this->lang->action->label->{$libType . 'assetlib'}; @@ -1618,7 +1618,7 @@ class actionModel extends model if($objectDeleted) return $action; } - if($this->config->edition == 'max' + if(($this->config->edition == 'max' or $this->config->edition == 'ipd') and strpos($this->config->action->assetType, ",{$action->objectType},") !== false and empty($action->project) and empty($action->product) and empty($action->execution)) { diff --git a/module/admin/lang/menu.php b/module/admin/lang/menu.php index bf0448e0e7..340c73c0db 100644 --- a/module/admin/lang/menu.php +++ b/module/admin/lang/menu.php @@ -177,7 +177,7 @@ $lang->admin->menuList->dev['menuOrder']['15'] = 'langItem'; $lang->admin->menuList->dev['menuOrder']['20'] = 'editor'; $lang->admin->menuList->dev['menuOrder']['25'] = 'entry'; -if($config->edition != 'max') +if($config->edition != 'max' and $config->edition != 'ipd') { unset($lang->admin->menuList->model['subMenu']['scrum']); unset($lang->admin->menuList->model['subMenu']['agileplus']); @@ -195,7 +195,7 @@ if(!helper::hasFeature('waterfallplus')) unset($lang->admin->menuList->model['subMenu']['waterfallplus']); unset($lang->admin->menuList->model['menuOrder']['25']); } -if($config->edition == 'max') +if($config->edition == 'max' or $config->edition == 'ipd') { if(!helper::hasFeature('scrum_auditplan') and !helper::hasFeature('scrum_process')) unset($lang->admin->menuList->model['subMenu']['scrum'], $lang->admin->menuList->model['menuOrder']['10']); if(!helper::hasFeature('agileplus_auditplan') and !helper::hasFeature('agileplus_process')) unset($lang->admin->menuList->model['subMenu']['agileplus'], $lang->admin->menuList->model['menuOrder']['20']); diff --git a/module/custom/model.php b/module/custom/model.php index cdfbdd7136..3ef210b872 100644 --- a/module/custom/model.php +++ b/module/custom/model.php @@ -889,7 +889,7 @@ class customModel extends model $enabledScrumFeatures = array(); $disabledScrumFeatures = array(); - if($this->config->edition== 'max' or $this->config->edition == 'ipd') + if($this->config->edition == 'max' or $this->config->edition == 'ipd') { foreach($this->config->custom->scrumFeatures as $scrumFeature) { @@ -1048,7 +1048,7 @@ class customModel extends model */ public function hasAssetlibData() { - if($this->config->edition== 'max' or $this->config->edition == 'ipd') return $this->dao->select('*')->from(TABLE_ASSETLIB)->where('deleted')->eq(0)->count(); + if($this->config->edition == 'max' or $this->config->edition == 'ipd') return $this->dao->select('*')->from(TABLE_ASSETLIB)->where('deleted')->eq(0)->count(); return false; } @@ -1060,7 +1060,7 @@ class customModel extends model */ public function hasScrumIssueData() { - if($this->config->edition== 'max' or $this->config->edition == 'ipd') + if($this->config->edition == 'max' or $this->config->edition == 'ipd') { return $this->dao->select('t1.*')->from(TABLE_ISSUE)->alias('t1') ->leftJoin(TABLE_PROJECT)->alias('t2')->on('t1.project = t2.id') @@ -1080,7 +1080,7 @@ class customModel extends model */ public function hasScrumRiskData() { - if($this->config->edition== 'max' or $this->config->edition == 'ipd') + if($this->config->edition == 'max' or $this->config->edition == 'ipd') { return $this->dao->select('t1.*')->from(TABLE_RISK)->alias('t1') ->leftJoin(TABLE_PROJECT)->alias('t2')->on('t1.project = t2.id') @@ -1100,7 +1100,7 @@ class customModel extends model */ public function hasScrumOpportunityData() { - if($this->config->edition== 'max' or $this->config->edition == 'ipd') + if($this->config->edition == 'max' or $this->config->edition == 'ipd') { return $this->dao->select('id')->from(TABLE_OPPORTUNITY)->where('execution')->ne('0')->andWhere('deleted')->eq('0')->count(); } @@ -1115,7 +1115,7 @@ class customModel extends model */ public function hasScrumMeetingData() { - if($this->config->edition== 'max' or $this->config->edition == 'ipd') + if($this->config->edition == 'max' or $this->config->edition == 'ipd') { return $this->dao->select('id')->from(TABLE_PROJECT)->alias('t1') ->leftJoin(TABLE_MEETING)->alias('t2')->on('t1.id = t2.project') @@ -1135,7 +1135,7 @@ class customModel extends model */ public function hasScrumAuditplanData() { - if($this->config->edition== 'max' or $this->config->edition == 'ipd') + if($this->config->edition == 'max' or $this->config->edition == 'ipd') { return $this->dao->select('id')->from(TABLE_PROJECT)->alias('t1') ->leftJoin(TABLE_AUDITPLAN)->alias('t2')->on('t1.id = t2.project') @@ -1155,7 +1155,7 @@ class customModel extends model */ public function hasScrumProcessData() { - if($this->config->edition== 'max' or $this->config->edition == 'ipd') + if($this->config->edition == 'max' or $this->config->edition == 'ipd') { return $this->dao->select('id')->from(TABLE_PROGRAMACTIVITY)->where('execution')->ne('0')->andWhere('deleted')->eq('0')->count(); } diff --git a/module/design/control.php b/module/design/control.php index 9964b82378..ede7129a35 100755 --- a/module/design/control.php +++ b/module/design/control.php @@ -91,7 +91,7 @@ class design extends control /* Print top and right actions. */ $this->lang->TRActions = '
'; - if($this->config->edition == 'max' and common::hasPriv('design', 'submit')) + if(($this->config->edition == 'max' or $this->config->edition == 'ipd') and common::hasPriv('design', 'submit')) { $this->lang->TRActions .= '
'; $this->lang->TRActions .= html::a($this->createLink('design', 'submit', "productID=$productID", '', true), " {$this->lang->design->submit}", '', "class='btn btn-secondary iframe'"); diff --git a/module/doc/model.php b/module/doc/model.php index 11241fe2a9..443cec81c7 100644 --- a/module/doc/model.php +++ b/module/doc/model.php @@ -1912,7 +1912,7 @@ class docModel extends model } elseif($type == 'project') { - if($this->config->edition== 'max' or $this->config->edition == 'ipd') + if($this->config->edition == 'max' or $this->config->edition == 'ipd') { $issueIdList = $this->dao->select('id')->from(TABLE_ISSUE)->where('project')->eq($objectID)->andWhere('deleted')->eq('0')->andWhere('project')->in($this->app->user->view->projects)->get(); $meetingIdList = $this->dao->select('id')->from(TABLE_MEETING)->where('project')->eq($objectID)->andWhere('deleted')->eq('0')->andWhere('project')->in($this->app->user->view->projects)->get(); @@ -3238,7 +3238,7 @@ class docModel extends model if(!common::hasPriv('doc', 'create') or !isset($lib->id)) return null; $objectID = zget($lib, $lib->type, 0); - $templateParam = $this->config->edition == 'max' ? '&from=template' : ''; + $templateParam = ($this->config->edition == 'max' or $this->config->edition == 'ipd') ? '&from=template' : ''; $class = $from == 'list' ? 'btn-info' : 'btn-primary'; $html = " -config->edition== 'max' or $this->config->edition == 'ipd'):?> +edition == 'max' or $config->edition == 'ipd'):?>