[xoops-cvslog 4947] CVS update: xoops2jp/html/modules/base/forms

Back to archive index

Minahito minah****@users*****
2006年 10月 12日 (木) 20:03:40 JST


Index: xoops2jp/html/modules/base/forms/SmilesFilterForm.class.php
diff -u xoops2jp/html/modules/base/forms/SmilesFilterForm.class.php:1.1.2.3 xoops2jp/html/modules/base/forms/SmilesFilterForm.class.php:1.1.2.3.2.1
--- xoops2jp/html/modules/base/forms/SmilesFilterForm.class.php:1.1.2.3	Tue Apr 11 15:12:54 2006
+++ xoops2jp/html/modules/base/forms/SmilesFilterForm.class.php	Thu Oct 12 20:03:40 2006
@@ -15,7 +15,6 @@
 
 class Legacy_SmilesFilterForm extends Legacy_AbstractFilterForm
 {
-	var $mSort = 0;
 	var $mSortKeys = array(
 		SMILES_SORT_KEY_ID => 'id',
 		SMILES_SORT_KEY_CODE => 'code',
@@ -23,15 +22,15 @@
 		SMILES_SORT_KEY_EMOTION => 'emotion',
 		SMILES_SORT_KEY_DISPLAY => 'display'
 	);
-	var $_mCriteria = null;
+
+	function getDefaultSortKey()
+	{
+		return SMILES_SORT_KEY_ID;
+	}
 
 	function fetch()
 	{
-		$this->mSort = isset($_REQUEST['sort']) ? intval($_REQUEST['sort']) : 0;
-	
-		if ($this->mSort > SMILES_SORT_KEY_MAXVALUE) {
-			$this->mSort = SMILES_SORT_KEY_DEFAULT;
-		}
+		parent::fetch();
 	
 		if (isset($_REQUEST['id'])) {
 			$this->_mCriteria->add(new Criteria('id', array(XOBJ_DTYPE_INT, xoops_getrequest('id'))));
Index: xoops2jp/html/modules/base/forms/ImageFilterForm.class.php
diff -u xoops2jp/html/modules/base/forms/ImageFilterForm.class.php:1.1.2.1 xoops2jp/html/modules/base/forms/ImageFilterForm.class.php:1.1.2.1.2.1
--- xoops2jp/html/modules/base/forms/ImageFilterForm.class.php:1.1.2.1	Thu May 25 18:31:49 2006
+++ xoops2jp/html/modules/base/forms/ImageFilterForm.class.php	Thu Oct 12 20:03:40 2006
@@ -18,7 +18,6 @@
 
 class Legacy_ImageFilterForm extends Legacy_AbstractFilterForm
 {
-	var $mSort = 0;
 	var $_mSortKeys = array(
 		IMAGE_SORT_KEY_IMAGE_ID => 'image_id',
 		IMAGE_SORT_KEY_IMAGE_NAME => 'image_name',
@@ -29,20 +28,20 @@
 		IMAGE_SORT_KEY_IMAGE_WEIGHT => 'image_weight',
 		IMAGE_SORT_KEY_IMGCAT_ID => 'imgcat_id'
 	);
-	var $_mCriteria = null;
+
+	function getDefaultSortKey()
+	{
+		return IMAGE_SORT_KEY_DEFAULT;
+	}
 
 	function fetch()
 	{
-		$this->mSort = isset($_REQUEST['sort']) ? intval($_REQUEST['sort']) : IMAGE_SORT_KEY_DEFAULT;
-	
-		if ($this->mSort > IMAGE_SORT_KEY_MAXVALUE) {
-			$this->mSort = IMAGE_SORT_KEY_DEFAULT;
-		}
-		
-		$this->_mNavi->addExtra('target', xoops_getrequest('target'));
+		parent::fetch();
+
+		$this->mNavi->addExtra('target', xoops_getrequest('target'));
 	
 		if (isset($_REQUEST['imgcat_id'])) {
-			$this->_mNavi->addExtra('imgcat_id', xoops_getrequest('imgcat_id'));
+			$this->mNavi->addExtra('imgcat_id', xoops_getrequest('imgcat_id'));
 			$this->_mCriteria->add(new Criteria('imgcat_id', array(XOBJ_DTYPE_INT, xoops_getrequest('imgcat_id'))));
 		}
 		else {


xoops-cvslog メーリングリストの案内
Back to archive index