Merge branch 'akaunting:master' into master

This commit is contained in:
Burak Civan 2022-11-02 14:25:29 +03:00 committed by GitHub
commit 3393c84633
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 12 additions and 8 deletions

View File

@ -57,17 +57,17 @@ class Tips extends Component
protected function setTips($tips)
{
if (!empty($tips)) {
if (! empty($tips)) {
$this->tips = $tips;
}
if (!$path = Route::current()->uri()) {
if (! $path = Route::current()->uri()) {
return;
}
$path = Str::replace('{company_id}/', '', $path);
if (!$tips = $this->getTips($path)) {
if (! $tips = $this->getTips($path)) {
return;
}
@ -76,10 +76,14 @@ class Tips extends Component
continue;
}
if (!empty($tip->alias) && $this->moduleIsEnabled($tip->alias)) {
if (! empty($tip->alias) && $this->moduleIsEnabled($tip->alias)) {
continue;
}
if (Str::contains($tip->action, '{company_id}')) {
$tip->action = Str::replace('{company_id}', company_id(), $tip->action);
}
$this->tips->push($tip);
}
}

View File

@ -10,9 +10,9 @@
{{ $item->title }}
</h2>
<p class="text-sm mb-2">
<div class="text-sm mb-2">
{!! $item->description !!}
</p>
</div>
<x-link href="{{ $item->action }}" class="font-light text-sm" override="class" target="_blank">
<x-link.hover>

View File

@ -10,9 +10,9 @@
{{ $item->title }}
</h2>
<p class="text-sm mb-2">
<div class="text-sm mb-2">
{!! $item->description !!}
</p>
</div>
<x-link href="{{ $item->action }}" class="font-light text-sm" override="class" target="_blank">
<x-link.hover>