TmpOldNetwork.php 1.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960
  1. <?php
  2. namespace common\models;
  3. use Yii;
  4. /**
  5. * This is the model class for table "{{%TMP_OLD_NETWORK}}".
  6. *
  7. * @property string $ID
  8. * @property string $USER_NAME 编号
  9. * @property string $REAL_NAME 姓名
  10. * @property string $PARENT_USER_NAME 上级编号
  11. * @property string $PARENT_REAL_NAME 上级姓名
  12. * @property string $NET_USER_NAME 安置人编号
  13. * @property string $NET_REAL_NAME 安置人姓名
  14. * @property int $SORT 排序
  15. */
  16. class TmpOldNetwork extends \common\components\ActiveRecord
  17. {
  18. /**
  19. * {@inheritdoc}
  20. */
  21. public static function tableName()
  22. {
  23. return '{{%TMP_OLD_NETWORK}}';
  24. }
  25. /**
  26. * {@inheritdoc}
  27. */
  28. public function rules()
  29. {
  30. return [
  31. [['USER_NAME', 'REAL_NAME', 'PARENT_USER_NAME', 'PARENT_REAL_NAME', 'NET_USER_NAME', 'NET_REAL_NAME'], 'required'],
  32. [['SORT'], 'integer'],
  33. [['ID'], 'string', 'max' => 32],
  34. [['USER_NAME', 'PARENT_USER_NAME', 'NET_USER_NAME'], 'string', 'max' => 16],
  35. [['REAL_NAME', 'PARENT_REAL_NAME', 'NET_REAL_NAME'], 'string', 'max' => 128],
  36. [['ID'], 'unique'],
  37. ];
  38. }
  39. /**
  40. * {@inheritdoc}
  41. */
  42. public function attributeLabels()
  43. {
  44. return [
  45. 'ID' => 'ID',
  46. 'USER_NAME' => '编号',
  47. 'REAL_NAME' => '姓名',
  48. 'PARENT_USER_NAME' => '上级编号',
  49. 'PARENT_REAL_NAME' => '上级姓名',
  50. 'NET_USER_NAME' => '安置人编号',
  51. 'NET_REAL_NAME' => '安置人姓名',
  52. 'SORT' => '排序',
  53. ];
  54. }
  55. }