Bug On 4.7.4: Blocks.post.php Adding Certain Configuration Breaks The Block Content Tab

Greetings,

I am currently working on adding a custom block in a website I am working on.

However, I found an issue:

In my addon's schemas/block_manager/blocks.post.php, I added this:

$schema['product_usp_accordion'] = array(
	'content' => array(
		'section_1_title' => array(
			'type' => 'input',
			'default_value' => ''
		),
		'section_1_content' => array(
			'type' => 'text',
			'required' => false,
		),
		'section_2_title' => array(
			'type' => 'input',
			'default_value' => ''
		),
		'section_2_content' => array(
			'type' => 'text',
			'required' => false
		),
		'section_3_title' => array(
			'type' => 'input',
			'default_value' => ''
		),
		'section_3_content' => array(
			'type' => 'text',
			'required' => false
		),
		'section_4_title' => array(
			'type' => 'input',
			'default_value' => ''
		),
		'section_4_content' => array(
			'type' => 'text',
			'required' => false
		),
		'section_5_title' => array(
			'type' => 'input',
			'default_value' => ''
		),
		'section_5_content' => array(
			'type' => 'text',
			'required' => false
		),
	),
	'templates' => 'blocks/product_usp_accordion.tpl',
	'cache' => true,
	'multilanguage' => true,
);

When I tried viewing the block in the admin panel, to my surprise, I got this result in attachment: "result_before_fix":
[attachment=13227:result_before_fix.png]

After I dug a little, found that the output HTML from the block element looked like this (result in attachment "html_output_before_fix"):

[attachment=13228:html_output_before_fix.png]

After applying the fix in this patch file:

[attachment=13229:fix_block_issues.txt]

Everything works as expected.

I did not know where else to report this bug.

I found it in v4.7.4. Not sure about earlier versions

Thank you for fixing it in the next update.

result_before_fix.png

html_output_before_fix.png

fix_block_issues.txt

You can report bugs here https://forum.cs-cart.com/tracker/

Thanks!

Posted it there as well!