mirror of
https://github.com/snipe/snipe-it.git
synced 2024-11-09 23:24:06 -08:00
32 lines
529 B
PHP
32 lines
529 B
PHP
<?php
|
|
|
|
namespace App\Presenters;
|
|
|
|
use App\Helpers\Helper;
|
|
|
|
/**
|
|
* Class CategoryPresenter
|
|
* @package App\Presenters
|
|
*/
|
|
class CategoryPresenter extends Presenter
|
|
{
|
|
|
|
/**
|
|
* Link to this categories name
|
|
* @return string
|
|
*/
|
|
public function nameUrl()
|
|
{
|
|
return (string) link_to_route('categories.show', $this->name, $this->id);
|
|
}
|
|
|
|
/**
|
|
* Url to view this item.
|
|
* @return string
|
|
*/
|
|
public function viewUrl()
|
|
{
|
|
return route('categories.show', $this->id);
|
|
}
|
|
}
|