Release of v5.0.3-beta3

Fix the missing edit button on fields in the related views. Fix the dashboard display. Place the search option back in the use field of the related views. Fix the namespace issue that broken the linker.
This commit is contained in:
2024-09-20 03:01:45 +02:00
parent 8ebeb56d3e
commit 9256633b37
39 changed files with 302 additions and 143 deletions

View File

@ -17,6 +17,7 @@ use Joomla\CMS\HTML\HTMLHelper as Html;
use Joomla\CMS\Component\ComponentHelper;
use VDM\Component\Componentbuilder\Administrator\Helper\ComponentbuilderHelper;
use VDM\Joomla\Utilities\StringHelper;
use Joomla\CMS\Uri\Uri;
// No direct access to this file
\defined('_JEXEC') or die;
@ -71,7 +72,7 @@ class SnippetsField extends ListField
$ref = '&ref=' . $values['view'] . '&refid=' . $values['id'];
$refJ = '&ref=' . $values['view'] . '&refid=' . $values['id'];
// get the return value.
$_uri = (string) \Joomla\CMS\Uri\Uri::getInstance();
$_uri = (string) Uri::getInstance();
$_return = urlencode(base64_encode($_uri));
// load return value.
$ref .= '&return=' . $_return;
@ -102,12 +103,14 @@ class SnippetsField extends ListField
// build script
$script[] = "
document.addEventListener('DOMContentLoaded', function() {
document.getElementById('jform_".$button_code_name."').addEventListener('change', function(e) {
let ".$button_code_name."Field = document.getElementById('jform_".$button_code_name."');
if (!".$button_code_name."Field) { return; }
".$button_code_name."Field.addEventListener('change', function(e) {
e.preventDefault();
let ".$button_code_name."Value = this.value;
".$button_code_name."Button(".$button_code_name."Value);
});
let ".$button_code_name."Value = document.getElementById('jform_".$button_code_name."').value;
let ".$button_code_name."Value = ".$button_code_name."Field.value;
".$button_code_name."Button(".$button_code_name."Value);
});
function ".$button_code_name."Button(value) {