Akaunting/app/View/Components/Documents/Show/Create.php

36 lines
915 B
PHP
Raw Normal View History

2022-06-01 07:15:55 +00:00
<?php
namespace App\View\Components\Documents\Show;
use App\Abstracts\View\Components\Documents\Show as Component;
2023-10-03 08:06:08 +00:00
use Illuminate\Support\Str;
2022-06-01 07:15:55 +00:00
class Create extends Component
{
public $description;
2023-10-03 08:06:08 +00:00
public $user_name;
public $type_lowercase;
2022-06-01 07:15:55 +00:00
public $created_date;
/**
* Get the view / contents that represent the component.
*
* @return \Illuminate\Contracts\View\View|string
*/
public function render()
{
2023-10-03 08:06:08 +00:00
$this->description = ($this->document->isRecurringDocument()) ? 'documents.slider.create_recurring' : 'documents.slider.create';
$this->user_name = $this->document->owner->name;
$this->type_lowercase = Str::lower(trans_choice($this->textPage, 1));
2022-06-01 07:15:55 +00:00
$this->created_date = '<span class="font-medium">' . company_date($this->document->created_at) . '</span>';
return view('components.documents.show.create');
}
}