* code for task #2522,2579.
This commit is contained in:
@@ -3,14 +3,36 @@
|
||||
<?php echo "<span class='prefix'>" . html::icon($lang->icons['usecase']) . '</span><strong>' . $task->name . '</strong>';?>
|
||||
</div>
|
||||
<div class='nav'>
|
||||
<li>
|
||||
<span>
|
||||
<?php
|
||||
echo isset($moduleID) ? $moduleName : $this->lang->tree->all;
|
||||
if(!empty($moduleID))
|
||||
{
|
||||
$removeLink = $browseType == 'bymodule' ? inlink('cases', "taskID=$taskID&browseType=$browseType¶m=0&orderBy=$orderBy&recTotal={$pager->recTotal}&recPerPage={$pager->recPerPage}") : 'javascript:removeCookieByKey("caseModule")';
|
||||
echo ' ' . html::a($removeLink, "<i class='icon icon-remove'></i>") . ' ';
|
||||
}
|
||||
echo " <i class='icon-angle-right'></i> ";
|
||||
?>
|
||||
</span>
|
||||
</li>
|
||||
<?php
|
||||
$hasCasesPriv = common::hasPriv('testtask', 'cases');
|
||||
$hasGroupPriv = common::hasPriv('testtask', 'groupcase');
|
||||
?>
|
||||
<?php foreach($app->customMenu['featurebar'] as $type => $featurebar):?>
|
||||
<?php if($featurebar['status'] == 'hide') continue;?>
|
||||
<?php
|
||||
if(common::hasPriv('testtask', 'cases') and ($type == 'all' or $type == 'assignedtome'))
|
||||
if($hasCasesPriv and strpos($type, 'QUERY') === 0)
|
||||
{
|
||||
$queryID = (int)substr($type, 5);
|
||||
echo "<li id='{$type}Tab'>" . html::a($this->inlink('cases', "taskID=$taskID&browseType=bySearch¶m=$queryID"), $featurebar['link']) . "</li>";
|
||||
}
|
||||
elseif($hasCasesPriv and ($type == 'all' or $type == 'assignedtome'))
|
||||
{
|
||||
echo "<li id='{$type}Tab'>" . html::a($this->inlink('cases', "taskID=$taskID&browseType=$type¶m=0"), $featurebar['link']) . "</li>";
|
||||
}
|
||||
elseif(common::hasPriv('testtask', 'cases') and $type == 'group')
|
||||
elseif($hasGroupPriv and $type == 'group')
|
||||
{
|
||||
echo "<li id='groupTab' class='dropdown'>";
|
||||
$groupBy = isset($groupBy) ? $groupBy : '';
|
||||
|
||||
@@ -14,6 +14,7 @@
|
||||
<?php include '../../common/view/datatable.fix.html.php';?>
|
||||
<?php include './caseheader.html.php';?>
|
||||
<?php js::set('confirmUnlink', $lang->testtask->confirmUnlinkCase)?>
|
||||
<?php js::set('taskCaseBrowseType', ($browseType == 'bymodule' and $this->session->taskCaseBrowseType == 'bysearch') ? 'all' : $this->session->taskCaseBrowseType);?>
|
||||
<script language="Javascript">
|
||||
var browseType = '<?php echo $browseType;?>';
|
||||
var moduleID = '<?php echo $moduleID;?>';
|
||||
@@ -79,4 +80,17 @@ include $useDatatable ? dirname(__FILE__) . '/datatabledata.html.php' : dirname(
|
||||
</table>
|
||||
</form>
|
||||
</div>
|
||||
<script>
|
||||
$('#module' + moduleID).addClass('active');
|
||||
$('#' + taskCaseBrowseType + 'Tab').addClass('active');
|
||||
<?php if($browseType == 'bysearch'):?>
|
||||
$shortcut = $('#QUERY<?php echo (int)$param;?>Tab');
|
||||
if($shortcut.size() > 0)
|
||||
{
|
||||
$shortcut.addClass('active');
|
||||
$('#bysearchTab').removeClass('active');
|
||||
$('#querybox').removeClass('show');
|
||||
}
|
||||
<?php endif;?>
|
||||
</script>
|
||||
<?php include '../../common/view/footer.html.php';?>
|
||||
|
||||
Reference in New Issue
Block a user