2015-07-13 22:52:56 +02:00
|
|
|
<?php
|
|
|
|
|
|
|
|
namespace Oxbow;
|
|
|
|
|
|
|
|
use Illuminate\Database\Eloquent\Model;
|
|
|
|
|
|
|
|
class Image extends Model
|
|
|
|
{
|
2015-07-14 23:34:31 +02:00
|
|
|
public function getFilePath()
|
|
|
|
{
|
|
|
|
return storage_path() . $this->url;
|
|
|
|
}
|
2015-08-08 22:28:50 +02:00
|
|
|
|
|
|
|
public function createdBy()
|
|
|
|
{
|
|
|
|
return $this->belongsTo('Oxbow\User', 'created_by');
|
|
|
|
}
|
|
|
|
|
|
|
|
public function updatedBy()
|
|
|
|
{
|
|
|
|
return $this->belongsTo('Oxbow\User', 'updated_by');
|
|
|
|
}
|
2015-07-13 22:52:56 +02:00
|
|
|
}
|