- Remove unused method and unit test of doc::setFastMenu.
This commit is contained in:
@@ -1889,29 +1889,6 @@ class docModel extends model
|
||||
return $statistic;
|
||||
}
|
||||
|
||||
/**
|
||||
* Set past menu.
|
||||
*
|
||||
* @param string $fastLib
|
||||
* @access public
|
||||
* @return string
|
||||
*/
|
||||
public function setFastMenu($fastLib)
|
||||
{
|
||||
$actions = '';
|
||||
$actions .= '<a class="btn btn-link querybox-toggle" id="bysearchTab"><i class="icon icon-search muted"></i> ' . $this->lang->doc->search . '</a>';
|
||||
$actions .= "<a data-toggle='dropdown' class='btn btn-link' title=$fastLib>" . $fastLib . " <span class='caret'></span></a>";
|
||||
$actions .= "<ul class='dropdown-menu'>";
|
||||
foreach($this->lang->doc->fastMenuList as $key => $fastMenu)
|
||||
{
|
||||
$link = helper::createLink('doc', 'browse', "libID=0&browseType={$key}");
|
||||
$actions .= '<li>' . html::a($link, "<i class='icon {$this->lang->doc->fastMenuIconList[$key]}'></i> {$fastMenu}") . '</li>';
|
||||
}
|
||||
$actions .= '</ul>';
|
||||
|
||||
return $actions;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get toList and ccList.
|
||||
*
|
||||
|
||||
@@ -420,15 +420,6 @@ class docTest
|
||||
return $objects;
|
||||
}
|
||||
|
||||
public function setFastMenuTest($fastLib)
|
||||
{
|
||||
$objects = $this->objectModel->setFastMenu($fastLib);
|
||||
|
||||
if(dao::isError()) return dao::getError();
|
||||
|
||||
return $objects;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get toList and ccList.
|
||||
*
|
||||
|
||||
@@ -1,19 +0,0 @@
|
||||
#!/usr/bin/env php
|
||||
<?php
|
||||
include dirname(__FILE__, 5) . '/test/lib/init.php';
|
||||
include dirname(__FILE__, 2) . '/doc.class.php';
|
||||
su('admin');
|
||||
|
||||
/**
|
||||
|
||||
title=测试 docModel->setFastMenu();
|
||||
cid=1
|
||||
pid=1
|
||||
|
||||
|
||||
|
||||
*/
|
||||
|
||||
$doc = new docTest();
|
||||
|
||||
r($doc->setFastMenuTest()) && p() && e();
|
||||
Reference in New Issue
Block a user