icingaweb2/library/Icinga/Web/Form/Element/Number.php

41 lines
789 B
PHP
Raw Normal View History

<?php
// {{{ICINGA_LICENSE_HEADER}}}
// {{{ICINGA_LICENSE_HEADER}}}
namespace Icinga\Web\Form\Element;
use Zend_Form_Element;
2014-04-16 16:41:23 +02:00
/**
* A number input control
*/
class Number extends Zend_Form_Element
{
/**
* Disable default decorators
2014-04-16 16:41:23 +02:00
*
* \Icinga\Web\Form sets default decorators for elements.
*
* @var bool
*
* @see \Icinga\Web\Form::__construct() For default element decorators.
*/
protected $_disableLoadDefaultDecorators = true;
2014-04-16 16:41:23 +02:00
/**
* Form view helper to use for rendering
2014-04-16 16:41:23 +02:00
*
* @var string
2014-04-16 16:41:23 +02:00
*/
public $helper = 'formNumber';
2014-04-16 16:41:23 +02:00
/**
* (non-PHPDoc)
* @see \Zend_Form_Element::init() For the method documentation.
*/
public function init()
{
$this->addValidator('Int');
2014-04-16 16:41:23 +02:00
}
}