<?php

namespace apexl\Io\modules\formbuilder\includes;

use apexl\Io\modules\formbuilder\includes\formField;

class datePickerField extends formField
{
    public function __construct($name, $min = null, $max = null)
    {
        parent::__construct($name, 'input', 'date');
        $this->field->min = $min ?? date('Y/m/d');
        $this->field->min = $max ?? date('Y/m/d', (strtotime('+ 3 years')));
    }
}
