Ejemplo n.º 1
0
 public function to($type)
 {
     if ($type == 'html' && $this->cfg->mode == 'edit') {
         response::getInstance()->addJs('checkboxFields');
     }
     return parent::to($type);
 }
Ejemplo n.º 2
0
 public function to($type)
 {
     $ret = parent::to($type);
     if ($type == 'html' && $this->cfg->mode == 'edit') {
         $ret = '<span id="' . $this->id . 'Container">' . $ret . '</span>';
         $resp = response::getInstance();
         $resp->addJs('jqueryui');
         $resp->addJs('formAutocomplete');
         $prm = $this->cfg->jsPrm;
         $prm['name'] = $this->id . '[]';
         $prm['nameNew'] = $this->id . '[new]';
         $resp->blockJquery('$("#' . $this->id . 'Container").formAutocomplete(' . json_encode($prm) . ');');
     }
     return $ret;
 }