예제 #1
0
 public function __construct(array $data = array())
 {
     $this->_helper = isset($data['helper']) ? $data['helper'] : Mage::helper('Mage_Catalog_Helper_Product');
     $this->_virtual = isset($data['element']) ? $data['element'] : Mage::getModel('Varien_Data_Form_Element_Checkbox');
     $this->_virtual->setId(self::VIRTUAL_FIELD_HTML_ID)->setName('is_virtual')->setLabel($this->_helper->getTypeSwitcherControlLabel());
     parent::__construct($data);
 }
예제 #2
0
 public function __construct($attributes = array())
 {
     parent::__construct($attributes);
     $this->setType('label');
     // Disable target path input when link points to an attachment
     if ($this->getHasAttachment()) {
         $this->setDisabled(true);
     }
 }
 public function __construct($attributes = array())
 {
     if (isset($attributes['autocompleterUrl'])) {
         $this->_url = $attributes['autocompleterUrl'];
     }
     if (isset($attributes['autocompleterValue'])) {
         $this->_value = $attributes['autocompleterValue'];
     }
     parent::__construct($attributes);
 }
예제 #4
0
 public function __construct($attributes = array())
 {
     parent::__construct($attributes);
     $this->addClass('validate-zero-or-greater');
 }
예제 #5
0
 /**
  * Validation classes for weight field which corresponds to DECIMAL(12,4) SQL type
  *
  * @param array $attributes
  */
 public function __construct(array $attributes = array())
 {
     parent::__construct($attributes);
     $this->addClass('validate-number validate-zero-or-greater validate-number-range number-range-0-99999999.9999');
 }
예제 #6
0
 public function __construct($attributes = array())
 {
     parent::__construct($attributes);
 }