mirror of
https://github.com/BookStackApp/BookStack.git
synced 2025-03-28 02:05:19 +08:00

Improved sidebar and selection styling of image manager. Allowed image manager imageType to be changed on open. Created models for image revisions.
27 lines
566 B
PHP
27 lines
566 B
PHP
<?php
|
|
|
|
namespace BookStack;
|
|
|
|
use Illuminate\Database\Eloquent\Model;
|
|
|
|
class ImageRevision extends Model
|
|
{
|
|
/**
|
|
* Relation for the user that created this entity.
|
|
* @return \Illuminate\Database\Eloquent\Relations\BelongsTo
|
|
*/
|
|
public function createdBy()
|
|
{
|
|
return $this->belongsTo(User::class, 'created_by');
|
|
}
|
|
|
|
/**
|
|
* Get the image that this is a revision of.
|
|
* @return \Illuminate\Database\Eloquent\Relations\BelongsTo
|
|
*/
|
|
public function image()
|
|
{
|
|
return $this->belongsTo(Image::class);
|
|
}
|
|
}
|