mirror of https://github.com/pixelfed/pixelfed
You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
26 lines
389 B
PHTML
26 lines
389 B
PHTML
|
8 years ago
|
<?php
|
||
|
|
|
||
|
4 weeks ago
|
namespace App\Models;
|
||
|
8 years ago
|
|
||
|
|
use Illuminate\Database\Eloquent\Model;
|
||
|
|
|
||
|
|
class Page extends Model
|
||
|
|
{
|
||
|
|
const SLUG_ROOT = [
|
||
|
9 months ago
|
'site',
|
||
|
|
'page',
|
||
|
8 years ago
|
];
|
||
|
|
|
||
|
4 weeks ago
|
protected $guarded = [];
|
||
|
8 years ago
|
|
||
|
|
public function url()
|
||
|
|
{
|
||
|
9 months ago
|
return url($this->slug);
|
||
|
8 years ago
|
}
|
||
|
|
|
||
|
|
public function editUrl()
|
||
|
|
{
|
||
|
9 months ago
|
return url('/i/admin/settings/pages/edit?page='.urlencode($this->slug));
|
||
|
8 years ago
|
}
|
||
|
|
}
|