[xoops-cvslog 2982] CVS update: xoops2jp/html/modules/base/admin/actions

Back to archive index

Minahito minah****@users*****
2006年 5月 10日 (水) 19:25:11 JST


Index: xoops2jp/html/modules/base/admin/actions/ImageListAction.class.php
diff -u /dev/null xoops2jp/html/modules/base/admin/actions/ImageListAction.class.php:1.1.2.1
--- /dev/null	Wed May 10 19:25:10 2006
+++ xoops2jp/html/modules/base/admin/actions/ImageListAction.class.php	Wed May 10 19:25:10 2006
@@ -0,0 +1,36 @@
+<?php
+
+if (!defined('XOOPS_ROOT_PATH')) exit();
+
+require_once XOOPS_MODULE_PATH . "/base/class/PageNavigator.class.php";
+require_once XOOPS_MODULE_PATH . "/base/class/AbstractListAction.class.php";
+require_once XOOPS_MODULE_PATH . "/base/admin/forms/ImageFilterForm.class.php";
+
+class Legacy_ImageListAction extends Legacy_AbstractListAction
+{
+	function &_getHandler()
+	{
+		$handler =& xoops_getmodulehandler('image');
+		return $handler;
+	}
+
+	function &_getFilterForm(&$navi)
+	{
+		$filter =& new Legacy_ImageFilterForm($navi);
+		return $filter;
+	}
+
+	function _getBaseUrl()
+	{
+		return "./index.php?action=ImageList";
+	}
+
+	function executeViewIndex(&$controller, &$xoopsUser, &$render)
+	{
+		$render->setTemplateName("image_list.html");
+		$render->setAttribute("objects", $this->mObjects);
+		$render->setAttribute("pageNavi", $this->mNavi);
+	}
+}
+
+?>
Index: xoops2jp/html/modules/base/admin/actions/ImageDeleteAction.class.php
diff -u /dev/null xoops2jp/html/modules/base/admin/actions/ImageDeleteAction.class.php:1.1.2.1
--- /dev/null	Wed May 10 19:25:10 2006
+++ xoops2jp/html/modules/base/admin/actions/ImageDeleteAction.class.php	Wed May 10 19:25:10 2006
@@ -0,0 +1,46 @@
+<?php
+
+if (!defined('XOOPS_ROOT_PATH')) exit();
+
+require_once XOOPS_MODULE_PATH . "/base/class/AbstractDeleteAction.class.php";
+require_once XOOPS_MODULE_PATH . "/base/admin/forms/ImageAdminDeleteForm.class.php";
+
+class Legacy_ImageDeleteAction extends Legacy_AbstractDeleteAction
+{
+	function _getId()
+	{
+		return isset($_REQUEST['image_id']) ? $_REQUEST['image_id'] : 0;
+	}
+
+	function &_getHandler()
+	{
+		$handler =& xoops_getmodulehandler('image');
+		return $handler;
+	}
+
+	function _setupActionForm()
+	{
+		$this->mActionForm =& new Legacy_ImageAdminDeleteForm();
+		$this->mActionForm->prepare();
+	}
+
+	function executeViewInput(&$controller, &$xoopsUser, &$render)
+	{
+		$render->setTemplateName("image_delete.html");
+		$render->setAttribute('actionForm', $this->mActionForm);
+		#cubson::lazy_load('image', $this->mObject);
+		$render->setAttribute('object', $this->mObject);
+	}
+
+	function executeViewSuccess(&$controller, &$xoopsUser, &$render)
+	{
+		$controller->executeForward("./index.php?action=ImageList&imgcat_id=" . $this->mObject->get('imgcat_id'));
+	}
+
+	function executeViewError(&$controller, &$xoopsUser, &$render)
+	{
+		redirect_header("./index.php?action=ImageList", 1, _AD_BASE_ERROR_DBUPDATE_FAILED);
+	}
+}
+
+?>


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