Browse Source

Update DynamicModel.php

added note about limitations, i.e. no scenarios -> no safe attributes -> no load().
tags/2.0.11
Carsten Brandt 8 years ago committed by GitHub
parent
commit
4735d4da6b
  1. 4
      framework/base/DynamicModel.php

4
framework/base/DynamicModel.php

@ -50,6 +50,10 @@ use yii\validators\Validator;
* "dynamic attributes". It basically allows an attribute to be defined dynamically through its constructor
* or [[defineAttribute()]].
*
* Note that it does not support the usual validation flow as normal models, i.e. no scenarios are being defined
* and therefor none of the attributes is safe. This means that [[load()]] will not be able to perform massive
* assignment and return `false`. Attributes should be assigned via constructor instead.
*
* @author Qiang Xue <qiang.xue@gmail.com>
* @since 2.0
*/

Loading…
Cancel
Save