Skip to content

Commit 11a7c66

Browse files
committed
Block System Fixes
1 parent e70ca58 commit 11a7c66

File tree

2 files changed

+7
-4
lines changed

2 files changed

+7
-4
lines changed

app/Http/Controllers/LinkTypeViewController.php

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -26,12 +26,9 @@ public function getParamForm($typename, $linkId = 0)
2626
$data['button_id'] = $link->button_id;
2727
}
2828

29-
// Check if type_params is not empty and is a valid JSON string
3029
if (!empty($link->type_params) && is_string($link->type_params)) {
31-
// Decode the JSON string into an associative array
3230
$typeParams = json_decode($link->type_params, true);
3331
if (is_array($typeParams)) {
34-
// Merge the associative array into $data
3532
$data = array_merge($data, $typeParams);
3633
}
3734
}
@@ -46,9 +43,11 @@ public function getParamForm($typename, $linkId = 0)
4643
'selected' => ($linkId && isset($link) && $link->button_id == $btn->id),
4744
];
4845
}
49-
return view('components.pageitems.predefined-form', $data);
5046
}
5147

48+
// Set the block asset context before returning the view
49+
setBlockAssetContext($typename);
50+
5251
return view($typename . '.form', $data);
5352
}
5453

resources/views/studio/edit-link.blade.php

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,10 @@
22

33
@section('content')
44

5+
@push('sidebar-stylesheets')
6+
<script src="{{ asset('assets/external-dependencies/fontawesome.js') }}" crossorigin="anonymous"></script>
7+
@endpush
8+
59
<div class="conatiner-fluid content-inner mt-n5 py-0">
610
<div class="row">
711

0 commit comments

Comments
 (0)