<?php

class Link extends Eloquent
{
    /**
     * The database table used by the model.
     *
     * @var string
     */
    protected $table = 'links';


    /**
     * The rules used for validation.
     *
     * @var array
     */
    public static $rules = [
        'name' => 'required',
        'address' => 'required',
        'place_id' => 'required'
    ];

    /**
     * The relationship with table [places].
     */
    public function place()
    {
        return $this->belongsTo('Place');
    }


}