Merge branch 'sprint/max43_mayue_task#65893' into 'master'
* Finish task #65893. See merge request easycorp/zentaopms!5089
This commit is contained in:
+10
-7
@@ -1335,28 +1335,31 @@ class commonModel extends model
|
||||
|
||||
$label = $menuItem->text;
|
||||
$dropMenu = '';
|
||||
|
||||
/* Print sub menus. */
|
||||
if(isset($menuItem->dropMenu))
|
||||
{
|
||||
foreach($menuItem->dropMenu as $dropMenuItem)
|
||||
foreach($menuItem->dropMenu as $dropMenuKey => $dropMenuItem)
|
||||
{
|
||||
if($dropMenuItem->hidden) continue;
|
||||
if(isset($dropMenuItem->hidden) and $dropMenuItem->hidden) continue;
|
||||
|
||||
$subActive = '';
|
||||
$subModule = '';
|
||||
$subMethod = '';
|
||||
$subParams = '';
|
||||
$subLabel = $dropMenuItem->text;
|
||||
if(isset($dropMenuItem->link['module'])) $subModule = $dropMenuItem->link['module'];
|
||||
if(isset($dropMenuItem->link['method'])) $subMethod = $dropMenuItem->link['method'];
|
||||
if(isset($dropMenuItem->link['vars'])) $subParams = $dropMenuItem->link['vars'];
|
||||
$subLabel = '';
|
||||
list($dropMenuName, $dropMenuModule, $dropMenuMethod, $dropMenuParams) = explode('|', $dropMenuItem['link']);
|
||||
if(isset($dropMenuModule)) $subModule = $dropMenuModule;
|
||||
if(isset($dropMenuMethod)) $subMethod = $dropMenuMethod;
|
||||
if(isset($dropMenuParams)) $subParams = $dropMenuParams;
|
||||
if(isset($dropMenuName)) $subLabel = $dropMenuName;
|
||||
|
||||
$subLink = helper::createLink($subModule, $subMethod, $subParams);
|
||||
|
||||
if($currentModule == strtolower($subModule) and $currentMethod == strtolower($subMethod)) $subActive = 'active';
|
||||
|
||||
$misc = (isset($lang->navGroup->$subModule) and $tab != $lang->navGroup->$subModule) ? "data-app='$tab'" : '';
|
||||
$dropMenu .= "<li class='$subActive' data-id='$dropMenuItem->name'>" . html::a($subLink, $subLabel, '', $misc) . '</li>';
|
||||
$dropMenu .= "<li class='$subActive' data-id='$dropMenuKey'>" . html::a($subLink, $subLabel, '', $misc) . '</li>';
|
||||
}
|
||||
|
||||
if(empty($dropMenu)) continue;
|
||||
|
||||
@@ -7,9 +7,22 @@ $(function()
|
||||
{
|
||||
var type = $(this).parent().attr('data-id');
|
||||
if(type == 'bysearch') return;
|
||||
if(type == 'more')
|
||||
{
|
||||
$(this).attr('href', '###');
|
||||
return;
|
||||
}
|
||||
|
||||
type = type == 'all' ? type : type.toLowerCase();
|
||||
var href = createLink('design', 'browse', 'projectID=' + projectID + '&productID=' + productID + '&type=' + type);
|
||||
$(this).attr('href', href);
|
||||
});
|
||||
|
||||
if($('#subNavbar .dropdown-menu li[data-id=' + type +']').hasClass('active'))
|
||||
{
|
||||
var typeName = $('#subNavbar li[data-id=' + type +'] > a').html();
|
||||
|
||||
$('#subNavbar').find(".dropdown-hover > a").html(typeName + "<span class='caret'></span>");
|
||||
$("#subNavbar li[data-id='more']").addClass('active');
|
||||
}
|
||||
})
|
||||
|
||||
@@ -37,6 +37,7 @@ $lang->design->createdDate = 'CreatedDate';
|
||||
$lang->design->basicInfo = 'Basic Information';
|
||||
$lang->design->noAssigned = 'Unassigned';
|
||||
$lang->design->comment = 'Comment';
|
||||
$lang->design->more = 'Mehr';
|
||||
|
||||
/* 动作列表. */
|
||||
$lang->design->common = 'Design';
|
||||
|
||||
@@ -37,6 +37,7 @@ $lang->design->createdDate = 'CreatedDate';
|
||||
$lang->design->basicInfo = 'Basic Information';
|
||||
$lang->design->noAssigned = 'Unassigned';
|
||||
$lang->design->comment = 'Comment';
|
||||
$lang->design->more = 'More';
|
||||
|
||||
/* 动作列表. */
|
||||
$lang->design->common = 'Design';
|
||||
|
||||
@@ -37,6 +37,7 @@ $lang->design->createdDate = 'CreatedDate';
|
||||
$lang->design->basicInfo = 'Basic Information';
|
||||
$lang->design->noAssigned = 'Unassigned';
|
||||
$lang->design->comment = 'Comment';
|
||||
$lang->design->more = 'Suite';
|
||||
|
||||
/* 动作列表. */
|
||||
$lang->design->common = 'Design';
|
||||
|
||||
@@ -37,6 +37,7 @@ $lang->design->createdDate = '创建时间';
|
||||
$lang->design->basicInfo = '基本信息';
|
||||
$lang->design->noAssigned = '未指派';
|
||||
$lang->design->comment = '注释';
|
||||
$lang->design->more = '更多';
|
||||
|
||||
/* 动作列表. */
|
||||
$lang->design->common = '设计';
|
||||
|
||||
+11
-1
@@ -406,10 +406,20 @@ class designModel extends model
|
||||
/* Show custom design types. */
|
||||
$this->lang->waterfall->menu->design['subMenu'] = new stdclass();
|
||||
$this->lang->waterfall->menu->design['subMenu']->all = array('link' => "{$this->lang->all}|design|browse|projectID=%s&productID=0&browseType=all");
|
||||
$count = 1;
|
||||
foreach(array_filter($this->lang->design->typeList) as $key => $value)
|
||||
{
|
||||
$key = strtolower($key);
|
||||
$this->lang->waterfall->menu->design['subMenu']->$key = array('link' => "{$value}|design|browse|projectID=%s&productID=0&browseType={$key}");
|
||||
|
||||
if($count <= 4) $this->lang->waterfall->menu->design['subMenu']->$key = array('link' => "{$value}|design|browse|projectID=%s&productID=0&browseType={$key}");
|
||||
if($count == 5)
|
||||
{
|
||||
$this->lang->waterfall->menu->design['subMenu']->more = array('link' => "{$this->lang->design->more}|design|browse|projectID=%s&productID=0&browseType={$key}", 'class' => 'dropdown dropdown-hover');
|
||||
$this->lang->waterfall->menu->design['subMenu']->more['dropMenu'] = new stdclass();
|
||||
}
|
||||
if($count >= 5) $this->lang->waterfall->menu->design['subMenu']->more['dropMenu']->$key = array('link' => "{$value}|design|browse|projectID=%s&productID=0&browseType={$key}");
|
||||
|
||||
$count ++;
|
||||
}
|
||||
|
||||
if($this->app->rawMethod == 'browse') $this->lang->waterfall->menu->design['subMenu']->bysearch = array('link' => '<a href="javascript:;" class="querybox-toggle"><i class="icon-search icon"></i> ' . $this->lang->searchAB . '</a>');
|
||||
|
||||
Reference in New Issue
Block a user