This commit is contained in:
wangyidong
2022-12-09 13:20:40 +08:00
parent f1b27ca35a
commit 68973d2a19
2 changed files with 20 additions and 3 deletions
+5
View File
@@ -1951,6 +1951,11 @@ class block extends control
$hasViewPriv['review'] = true;
$count['review'] = count($reviews);
$this->view->reviews = $reviews;
if($this->config->edition == 'max')
{
$this->app->loadLang('approval');
$this->view->flows = $this->dao->select('module,name')->from(TABLE_WORKFLOW)->where('buildin')->eq(0)->fetchPairs('module', 'name');
}
}
$this->view->selfCall = $this->selfCall;
+15 -3
View File
@@ -29,13 +29,21 @@
<?php foreach($reviews as $review):?>
<?php
$type = $review->type;
if($type == 'project') $type = 'review';
if($type == 'projectreview') $type = 'review';
$typeName = $lang->$type->common;
$typeName = '';
if(isset($lang->{$review->type}->common)) $typeName = $lang->{$review->type}->common;
if($type == 'story') $typeName = $lang->my->auditMenu->audit->story;
if($review->type == 'projectreview') $typeName = $lang->project->common;
if(isset($flows[$review->type])) $typeName = $flows[$review->type];
$statusList = $lang->$type->statusList;
$statusList = array();
if(isset($lang->$type->statusList)) $statusList = $lang->$type->statusList;
if($type == 'attend') $statusList = $lang->attend->reviewStatusList;
if(!in_array($type, array('story', 'testcase', 'feedback', 'review')) and strpos(",{$config->my->oaObjectType},", ",$type,") === false)
{
$statusList = $lang->approval->nodeList;
}
?>
<tr>
<td class='c-id'><?php echo $review->id?></td>
@@ -82,6 +90,10 @@
{
common::printLink($module, 'view', $params, $reviewIcon, '', "class='btn' data-toggle='modal' title='{$lang->review->common}'", true, true);
}
elseif(!in_array($module, array('story', 'testcase', 'feedback')))
{
common::printLink($module, 'approvalreview', $params, $reviewIcon, '', "class='btn' data-toggle='modal' title='{$lang->review->common}'", true, true);
}
else
{
common::printLink($module, $method, $params, $reviewIcon, '', "class='btn iframe' title='{$lang->review->common}'", true, true);