protected function init()
 {
     if (!isset($this->options['formats'])) {
         $this->options['formats'] = array();
     }
     if (!isset($this->options['formats']['js'])) {
         if (isset($this->options['formats']['locale'])) {
             $this->options['formats']['html'] = $this->options['formats']['value'] = $this->options['formats']['js'] = $this->options['formats']['locale'];
         } else {
             $this->options['formats']['html'] = $this->options['formats']['value'] = $this->options['formats']['js'] = new waContactDateLocalFormatter();
         }
     }
     if (!isset($this->options['formats']['locale'])) {
         $this->options['formats']['locale'] = $this->options['formats']['js'];
     }
     parent::init();
 }
 protected function init()
 {
     if (!isset($this->options['formats'])) {
         $this->options['formats'] = array();
     }
     if (!isset($this->options['formats']['html'])) {
         $this->options['formats']['html'] = new waContactBirthdayLocalFormatter(array('prefix' => $this->options['prefix']));
     }
     if (!isset($this->options['formats']['locale'])) {
         $this->options['formats']['locale'] = $this->options['formats']['html'];
     }
     if (!isset($this->options['formats']['list'])) {
         $this->options['formats']['list'] = $this->options['formats']['html'];
     }
     if (empty($this->options['validators'])) {
         $this->options['validators'] = new waDateValidator($this->options, array('required' => _ws('This field is required')));
     }
     parent::init();
 }