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