1
0
mirror of https://github.com/invoiceninja/invoiceninja.git synced 2024-09-20 08:21:34 +02:00
invoiceninja/app/Models/TaskStatus.php

50 lines
702 B
PHP
Raw Normal View History

2017-12-17 18:54:54 +01:00
<?php
namespace App\Models;
use Illuminate\Database\Eloquent\SoftDeletes;
/**
* Class PaymentTerm.
*/
class TaskStatus extends EntityModel
{
use SoftDeletes;
/**
* @var bool
*/
public $timestamps = true;
2017-12-19 12:25:13 +01:00
2017-12-17 18:54:54 +01:00
/**
* @var array
*/
protected $dates = ['deleted_at'];
2017-12-19 12:25:13 +01:00
/**
* @var array
*/
protected $fillable = [
'name',
'sort_order',
];
2017-12-17 18:54:54 +01:00
/**
* @return mixed
*/
public function getEntityType()
{
return ENTITY_TASK_STATUS;
}
2017-12-19 17:33:41 +01:00
/**
* @return mixed
*/
public function tasks()
{
return $this->hasMany('App\Models\Task')->orderBy('task_status_sort_order');
}
2017-12-17 18:54:54 +01:00
}