Number.php 736 B

123456789101112131415161718192021222324252627282930313233343536
  1. <?php
  2. namespace ThurData\Servers\KerioEmail\Core\UI\Widget\Forms\Fields;
  3. /**
  4. * Number Field controler
  5. *
  6. * @autor ThurData <info@thrudata.ch>
  7. */
  8. class Number extends BaseField
  9. {
  10. protected $id = 'number';
  11. protected $name = 'number';
  12. protected $maxValue = null;
  13. protected $minValue = null;
  14. public function __construct($minValue = null, $maxValue = null)
  15. {
  16. parent::__construct();
  17. $this->minValue = $minValue;
  18. $this->maxValue = $maxValue;
  19. $this->isIntNumberBetween($this->minValue, $this->maxValue);
  20. }
  21. public function getMinValue()
  22. {
  23. return $this->minValue;
  24. }
  25. public function getMaxValue()
  26. {
  27. return $this->maxValue;
  28. }
  29. }