1
0
mirror of https://github.com/invoiceninja/invoiceninja.git synced 2024-11-14 23:22:52 +01:00
invoiceninja/app/Models/TicketRelation.php

37 lines
586 B
PHP
Raw Normal View History

2019-01-30 12:00:26 +01:00
<?php
namespace App\Models;
/**
* Class TicketRelation
* @package App\Models
*/
class TicketRelation extends EntityModel
{
public $timestamps = false;
protected $hidden = [];
/**
* @return mixed
*/
public function getEntityType()
{
return ENTITY_TICKET_RELATION;
}
/**
* @return mixed
*/
public function getEntity()
{
return $this->belongsTo('App\Models\\'.ucfirst($this->entity), 'entity_id', 'id');
}
public function ticket()
{
return $this->belongsTo('App\Models\Ticket');
}
}