<?php

namespace common\models;

use Yii;

/**
 * This is the model class for table "affliationsRightColumn".
 *
 * @property integer $id
 * @property string $title
 * @property string $content
 * @property string $image
 */
class AffliationsRightColumn extends \yii\db\ActiveRecord
{
    /**
     * @inheritdoc
     */
    public static function tableName()
    {
        return 'affliationsRightColumn';
    }

    /**
     * @inheritdoc
     */
    public function rules()
    {
        return [
            [['title', 'content', 'image'], 'required'],
            [['content'], 'string'],
			[['image'], 'file', 'extensions'=>'jpg, gif, png'],
			[['image'],  'safe'],
            [['title', 'image'], 'string', 'max' => 500]
        ];
    }

    /**
     * @inheritdoc
     */
    public function attributeLabels()
    {
        return [
            'id' => 'ID',
            'title' => 'Title',
            'content' => 'Content',
            'image' => 'Image',
        ];
    }
}
