Changes Related with Model Scenarios Yii Framework

Sunday, March 18, 2012

  Removed CModel::safeAttributes(). Safe attributes are now de ned to be those that
are being validated by some rules as de ned in CModel::rules() for the particular
scenario.
Changed CModel::validate(), CModel::beforeValidate() and CModel::afterValidate().
CModel::setAttributes(), CModel::getSafeAttributeNames() The 'scenario' parame-
ter is removed. You should get and set the model scenario via CModel::scenario.
Changed CModel::getValidators() and removed CModel::getValidatorsForAttribute().
CModel::getValidators() now only returns validators applicable to the scenario as
speci ed by the model's scenario property.
Changed CModel::isAttributeRequired() and CModel::getValidatorsForAttribute().
The scenario parameter is removed. The model's scenario property will be used,
instead.
Removed CHtml::scenario. CHtml will use the model's scenario property instead.

No comments:

Post a Comment

Your Comment will be visible after approval. Post Free classified ads at www.pkbazaar.com to increase your traffic

 

Online Earning

Top Online Shopping Websites in Pakistan  earn money online online earning

Most Reading

Tags

Result Analytics

free counter