XCL Web Application Platform 2.5.0
The XoopsCube Legacy Project
Loading...
Searching...
No Matches
TplfileAdminDeleteForm.class.php
1<?php
2
3if (!defined('XOOPS_ROOT_PATH')) {
4 exit();
5}
6
7require_once XOOPS_ROOT_PATH . '/core/XCube_ActionForm.class.php';
8require_once XOOPS_MODULE_PATH . '/legacy/class/Legacy_Validator.class.php';
9
11{
12 public function getTokenName()
13 {
14 return 'module.legacyRender.TplfileAdminDeleteForm.TOKEN';
15 }
16
17 public function prepare()
18 {
19 //
20 // Set form properties
21 //
22 $this->mFormProperties['tpl_id'] =new XCube_IntProperty('tpl_id');
23
24 //
25 // Set field properties
26 //
27
28 $this->mFieldProperties['tpl_id'] =new XCube_FieldProperty($this);
29 $this->mFieldProperties['tpl_id']->setDependsByArray(['required']);
30 $this->mFieldProperties['tpl_id']->addMessage('required', _AD_LEGACYRENDER_ERROR_REQUIRED, _AD_LEGACYRENDER_LANG_TPL_ID);
31 }
32
33 public function load(&$obj)
34 {
35 $this->set('tpl_id', $obj->get('tpl_id'));
36 }
37
38 public function update(&$obj)
39 {
40 $obj->set('tpl_id', $this->get('tpl_id'));
41 }
42}
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.