XCL Web Application Platform 2.5.0
The XoopsCube Legacy Project
Loading...
Searching...
No Matches
CommentAdminDeleteForm.class.php
1<?php
11
12if (!defined('XOOPS_ROOT_PATH')) {
13 exit();
14}
15
16require_once XOOPS_ROOT_PATH . '/core/XCube_ActionForm.class.php';
17
18/***
19 * @internal
20 */
22{
23 public function getTokenName()
24 {
25 return 'module.legacy.XoopscommentsAdminDeleteForm.TOKEN' . $this->get('com_id');
26 }
27
28 public function prepare()
29 {
30 //
31 // Set form properties
32 //
33 $this->mFormProperties['com_id'] =new XCube_IntProperty('com_id');
34 $this->mFormProperties['delete_mode'] =new XCube_StringProperty('delete_mode');
35
36 //
37 // Set field properties
38 //
39 $this->mFieldProperties['com_id'] =new XCube_FieldProperty($this);
40 $this->mFieldProperties['com_id']->setDependsByArray(['required']);
41 $this->mFieldProperties['com_id']->addMessage('required', _MD_LEGACY_ERROR_REQUIRED, _MD_LEGACY_LANG_COM_ID);
42 }
43
44 public function load(&$obj)
45 {
46 $this->setVar('com_id', $obj->get('com_id'));
47 }
48
49 public function update(&$obj)
50 {
51 $obj->setVar('com_id', $this->get('com_id'));
52 }
53}
update(&$obj)
[Abstract] Updates an object with properties values.
getTokenName()
Gets the token name of this actionform's token.
prepare()
[Abstract] Set up form properties and field properties.
load(&$obj)
[Abstract] Initializes properties' values from an object.
[Abstract] Used for validating member property values of XCube_ActionForm.
Represents int property.
Represents string property.