DynamicConf.php 882 B

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152
  1. <?php
  2. namespace app\models;
  3. use Yii;
  4. /**
  5. * This is the model class for table "conf".
  6. *
  7. * @property integer $id
  8. * @property integer $user_id
  9. * @property string $name
  10. * @property string $conf
  11. * @property integer $level
  12. * @property integer $status
  13. * @property integer $at
  14. */
  15. class DynamicConf extends \yii\db\ActiveRecord
  16. {
  17. const K_ONLINE_VERSION = 'online_version';
  18. /**
  19. * @inheritdoc
  20. */
  21. public static function tableName()
  22. {
  23. return 'dynamic_conf';
  24. }
  25. /**
  26. * @inheritdoc
  27. */
  28. public function rules()
  29. {
  30. return [
  31. [['name', 'value'], 'required'],
  32. [['name', 'value'], 'string', 'max' => 30],
  33. ];
  34. }
  35. /**
  36. * @inheritdoc
  37. */
  38. public function attributeLabels()
  39. {
  40. return [
  41. 'name' => 'Name',
  42. 'value' => 'value',
  43. ];
  44. }
  45. }