firefly-iii/app/models/Component.php

21 lines
606 B
PHP
Raw Normal View History

<?php
2014-12-06 05:12:55 -06:00
use Watson\Validating\ValidatingTrait;
2014-12-20 08:00:53 -06:00
use \Illuminate\Database\Eloquent\Model as Eloquent;
2014-12-13 14:59:02 -06:00
/**
* Class Component
*/
2014-12-17 13:47:46 -06:00
class Component extends Eloquent
{
public static $rules
2014-11-18 02:47:50 -06:00
= [
'user_id' => 'exists:users,id|required',
'name' => 'required|between:1,100|alphabasic',
'class' => 'required',
];
2014-12-06 05:12:55 -06:00
protected $dates = ['deleted_at', 'created_at', 'updated_at'];
2014-12-17 13:47:46 -06:00
protected $fillable = ['name', 'user_id','class'];
2014-11-12 15:37:44 -06:00
protected $table = 'components';
2014-12-16 14:41:16 -06:00
use ValidatingTrait;
2015-01-01 23:16:49 -06:00
}