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

アーカイブの一覧に戻る

Minahito minah****@users*****
2006年 4月 7日 (金) 17:44:55 JST


Index: xoops2jp/html/modules/base/admin/forms/BlockListForm.class.php
diff -u /dev/null xoops2jp/html/modules/base/admin/forms/BlockListForm.class.php:1.1.2.1
--- /dev/null	Fri Apr  7 17:44:55 2006
+++ xoops2jp/html/modules/base/admin/forms/BlockListForm.class.php	Fri Apr  7 17:44:55 2006
@@ -0,0 +1,50 @@
+<?php
+
+if (!defined('XOOPS_ROOT_PATH')) exit();
+
+require_once XOOPS_ROOT_PATH . "/class/XCube_ActionForm.class.php";
+require_once XOOPS_MODULE_PATH . "/base/class/Legacy_Validator.class.php";
+
+class Legacy_BlockListForm extends XCube_ActionForm
+{
+	function getTokenName()
+	{
+		return "module.base.BlockListForm.TOKEN";
+	}
+
+	function prepare()
+	{
+		//
+		// Set form properties
+		//
+		$this->mFormProperties['weight'] =& new XCube_IntArrayProperty('weight');
+		$this->mFormProperties['side'] =& new XCube_IntArrayProperty('side');
+		$this->mFormProperties['bcachetime'] =& new XCube_IntArrayProperty('bcachetime');
+	
+		//
+		// Set field properties
+		//
+	
+		$this->mFieldProperties['weight'] =& new XCube_FieldProperty($this);
+		$this->mFieldProperties['weight']->setDependsByArray(array('required','intRange'));
+		$this->mFieldProperties['weight']->addMessage('required', _AD_BASE_ERROR_REQUIRED, _AD_BASE_LANG_WEIGHT);
+		$this->mFieldProperties['weight']->addMessage('intRange', _AD_BASE_ERROR_INTRANGE, _AD_BASE_LANG_WEIGHT);
+		$this->mFieldProperties['weight']->addVar('min', '0');
+		$this->mFieldProperties['weight']->addVar('max', '255');
+	
+		$this->mFieldProperties['side'] =& new XCube_FieldProperty($this);
+		$this->mFieldProperties['side']->setDependsByArray(array('required','objectExist'));
+		$this->mFieldProperties['side']->addMessage('required', _AD_BASE_ERROR_REQUIRED, _AD_BASE_LANG_SIDE);
+		$this->mFieldProperties['side']->addMessage('objectExist', _AD_BASE_ERROR_OBJECTEXIST, _AD_BASE_LANG_SIDE);
+		$this->mFieldProperties['side']->addVar('handler', 'columnside');
+		$this->mFieldProperties['side']->addVar('module', 'base');
+	
+		$this->mFieldProperties['bcachetime'] =& new XCube_FieldProperty($this);
+		$this->mFieldProperties['bcachetime']->setDependsByArray(array('required','objectExist'));
+		$this->mFieldProperties['bcachetime']->addMessage('required', _AD_BASE_ERROR_REQUIRED, _AD_BASE_LANG_BCACHETIME);
+		$this->mFieldProperties['bcachetime']->addMessage('objectExist', _AD_BASE_ERROR_OBJECTEXIST, _AD_BASE_LANG_BCACHETIME);
+		$this->mFieldProperties['bcachetime']->addVar('handler', 'cachetime');
+	}
+}
+
+?>


xoops-cvslog メーリングリストの案内
アーカイブの一覧に戻る