Profile.php 599 B

1234567891011121314151617181920212223242526272829303132333435363738
  1. <?php
  2. namespace yiiunit\gii;
  3. use yii\db\ActiveRecord;
  4. class Profile extends ActiveRecord
  5. {
  6. /**
  7. * {@inheritdoc}
  8. */
  9. public static function tableName()
  10. {
  11. return 'profile';
  12. }
  13. /**
  14. * {@inheritdoc}
  15. */
  16. public function rules()
  17. {
  18. return [
  19. [['description'], 'required'],
  20. [['description'], 'string', 'max' => 128]
  21. ];
  22. }
  23. /**
  24. * {@inheritdoc}
  25. */
  26. public function attributeLabels()
  27. {
  28. return [
  29. 'id' => 'ID',
  30. 'description' => 'Description',
  31. ];
  32. }
  33. }