<?php

namespace common\models;

use Yii;

/**
 * This is the model class for table "{{%USER_PERF_UPDATE}}".
 *
 * @property string $USER_ID 会员ID
 * @property int $PERIOD_NUM 更新时的期数
 * @property string $P_CALC_MONTH 更新时的结算月
 * @property int $CREATED_AT 创建时间
 */
class UserPerfUpdate extends \common\components\ActiveRecord
{
    /**
     * @inheritdoc
     */
    public static function tableName()
    {
        return '{{%USER_PERF_UPDATE}}';
    }

    /**
     * @inheritdoc
     */
    public function rules()
    {
        return [
            [['USER_ID', 'P_CALC_MONTH', 'CREATED_AT'], 'required'],
            [['PERIOD_NUM', 'CREATED_AT'], 'integer'],
            [['USER_ID'], 'string', 'max' => 32],
            [['USER_ID'], 'unique'],
        ];
    }

    /**
     * @inheritdoc
     */
    public function attributeLabels()
    {
        return [
            'USER_ID' => '会员ID',
            'PERIOD_NUM' => '更新时的期数',
            'P_CALC_MONTH' => '更新时的结算月',
            'CREATED_AT' => '创建时间',
        ];
    }
}
