Minahito
minah****@users*****
2006年 4月 11日 (火) 15:12:54 JST
Index: xoops2jp/html/modules/base/forms/SmilesFilterForm.class.php diff -u xoops2jp/html/modules/base/forms/SmilesFilterForm.class.php:1.1.2.2 xoops2jp/html/modules/base/forms/SmilesFilterForm.class.php:1.1.2.3 --- xoops2jp/html/modules/base/forms/SmilesFilterForm.class.php:1.1.2.2 Tue Mar 28 22:30:03 2006 +++ xoops2jp/html/modules/base/forms/SmilesFilterForm.class.php Tue Apr 11 15:12:54 2006 @@ -4,7 +4,6 @@ require_once XOOPS_MODULE_PATH . "/base/class/AbstractFilterForm.class.php"; -define('SMILES_SORT_KEY_DEFAULT', 0); define('SMILES_SORT_KEY_ID', 1); define('SMILES_SORT_KEY_CODE', 2); define('SMILES_SORT_KEY_SMILE_URL', 3); @@ -12,11 +11,12 @@ define('SMILES_SORT_KEY_DISPLAY', 5); define('SMILES_SORT_KEY_MAXVALUE', 5); +define('SMILES_SORT_KEY_DEFAULT', SMILES_SORT_KEY_ID); + class Legacy_SmilesFilterForm extends Legacy_AbstractFilterForm { var $mSort = 0; var $mSortKeys = array( - SMILES_SORT_KEY_DEFAULT => 'id', SMILES_SORT_KEY_ID => 'id', SMILES_SORT_KEY_CODE => 'code', SMILES_SORT_KEY_SMILE_URL => 'smile_url', @@ -52,6 +52,8 @@ if (isset($_REQUEST['display'])) { $this->_mCriteria->add(new Criteria('display', array(XOBJ_DTYPE_BOOL, xoops_getrequest('display')))); } + + $this->_mCriteria->addSort($this->getSort(), $this->getOrder()); } } Index: xoops2jp/html/modules/base/forms/OnlineFilterForm.class.php diff -u xoops2jp/html/modules/base/forms/OnlineFilterForm.class.php:1.1.2.2 xoops2jp/html/modules/base/forms/OnlineFilterForm.class.php:1.1.2.3 --- xoops2jp/html/modules/base/forms/OnlineFilterForm.class.php:1.1.2.2 Tue Mar 28 22:30:03 2006 +++ xoops2jp/html/modules/base/forms/OnlineFilterForm.class.php Tue Apr 11 15:12:54 2006 @@ -4,7 +4,6 @@ require_once XOOPS_MODULE_PATH . "/base/class/AbstractFilterForm.class.php"; -define('ONLINE_SORT_KEY_DEFAULT', 1); define('ONLINE_SORT_KEY_ONLINE_UID', 1); define('ONLINE_SORT_KEY_ONLINE_UNAME', 2); define('ONLINE_SORT_KEY_ONLINE_UPDATED', 3); @@ -12,6 +11,8 @@ define('ONLINE_SORT_KEY_ONLINE_IP', 5); define('ONLINE_SORT_KEY_MAXVALUE', 5); +define('ONLINE_SORT_KEY_DEFAULT', ONLINE_SORT_KEY_ONLINE_UID); + class Legacy_OnlineFilterForm extends Legacy_AbstractFilterForm { var $mSort = 0; @@ -51,6 +52,8 @@ if (isset($_REQUEST['online_ip'])) { $this->_mCriteria->add(new Criteria('online_ip', array(XOBJ_DTYPE_STRING, xoops_getrequest('online_ip')))); } + + $this->_mCriteria->addSort($this->getSort(), $this->getOrder()); } }