rules() public method

Declares the validation rules.
public rules ( )
 public function rules()
 {
     return array_merge(parent::rules(), array(array('defaultValue', 'boolean')));
 }
 public function rules()
 {
     return array_merge(parent::rules(), array(array('label', 'type', 'type' => 'string'), array('required', 'type', 'type' => 'boolean'), array('hidden', 'type', 'type' => 'boolean'), array('hiddenValue', 'type', 'type' => 'string')));
 }
 public function rules()
 {
     return array_merge(parent::rules(), array(array('startingStateOrder', 'required'), array('contactStatesData', 'safe'), array('contactStatesData', 'required', 'message' => 'You must have at least one status.'), array('contactStatesData', 'validateContactStatesData'), array('contactStatesLabels', 'safe'), array('contactStatesDataExistingValues', 'safe')));
 }
 public function rules()
 {
     return array_merge(parent::rules(), array(array('defaultValueCalculationType', 'safe')));
 }
 public function rules()
 {
     return array_merge(parent::rules(), array(array('mappingData', 'safe'), array('mappingData', 'validateMappingData')));
 }
 public function rules()
 {
     return array_merge(parent::rules(), array(array('maxLength', 'required'), array('maxLength', 'length', 'min' => 1, 'max' => 3), array('maxLength', 'numerical', 'min' => 1, 'max' => 255), array('maxLength', 'numerical', 'integerOnly' => true), array('defaultValue', 'length', 'max' => $this->maxLength)));
 }
 public function rules()
 {
     return array_merge(parent::rules(), array(array('formula', 'required'), array('formula', 'validateFormula')));
 }
示例#8
0
 public function rules()
 {
     return array_merge(parent::rules(), array(array('customFieldDataData', 'safe'), array('customFieldDataDataExistingValues', 'safe'), array('customFieldDataData', 'required', 'message' => 'You must have at least one pick list item.'), array('customFieldDataData', 'validateCustomFieldDataData'), array('defaultValueOrder', 'safe'), array('attributeName', 'length', 'min' => 3, 'max' => 64), array('customFieldDataLabels', 'safe')));
 }