Add icon for slider
continuous-integration/drone/push Build is passing
Details
continuous-integration/drone/push Build is passing
Details
This commit is contained in:
parent
1ba46f7532
commit
091a9a5bde
|
@ -23,7 +23,7 @@
|
||||||
{{post.intro}} …
|
{{post.intro}} …
|
||||||
</div>
|
</div>
|
||||||
<div class="flex px-6 py-3 bg-gray-100 items-center border border-t">
|
<div class="flex px-6 py-3 bg-gray-100 items-center border border-t">
|
||||||
{{'facebook-square'|sprite('w-6 h-6 mr-3 fill-current text-primary-500')}}
|
{{post.page.icon|sprite('w-6 h-6 mr-3 fill-current text-primary-500')}}
|
||||||
<span class="text-sm text-gray-600">Beitrag anschauen</span>
|
<span class="text-sm text-gray-600">Beitrag anschauen</span>
|
||||||
</div>
|
</div>
|
||||||
</a>
|
</a>
|
||||||
|
|
|
@ -74,6 +74,11 @@ class Page extends Model
|
||||||
return 'social/'.$this->slug.'/';
|
return 'social/'.$this->slug.'/';
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public function getIconAttribute(): string
|
||||||
|
{
|
||||||
|
return "{$this->type}-slider";
|
||||||
|
}
|
||||||
|
|
||||||
public function beforeDelete() {
|
public function beforeDelete() {
|
||||||
$this->posts->each->delete();
|
$this->posts->each->delete();
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue