* Finish task #36312.

This commit is contained in:
Yagami
2021-03-02 13:17:26 +08:00
parent a4404e6ce8
commit 1742f06368
3 changed files with 15 additions and 17 deletions
+2 -2
View File
@@ -751,11 +751,11 @@ class programModel extends model
* @access public
* @return array
*/
public function getParentPairs($model = '')
public function getParentPairs($model = '', $mode = '')
{
$modules = $this->dao->select('id,name,parent,path,grade')->from(TABLE_PROGRAM)
->where('type')->eq('program')
->andWhere('status')->ne('closed')
->beginIF(strpos($mode, 'noclosed') === false)->andWhere('status')->ne('closed')->fi()
->andWhere('deleted')->eq(0)
->beginIF($model)->andWhere('model')->eq($model)->fi()
->orderBy('grade desc, `order`')