joomla-cms icon indicating copy to clipboard operation
joomla-cms copied to clipboard

The schemaorg entry is deleted if no data has been received from the form

Open MSGroupFM opened this issue 1 year ago • 1 comments

Steps to reproduce the issue

When saving materials in Joomla 5.1 not through the standard form of the control panel (for example, YOOtheme Pro), the schemaorg is deleted.

Expected result

The schemaorg plugin should ignore form submission without a schema.

Actual result

Schemaorg plugin removes a record from a table _schemaorg

System information (as much as possible)

Joomla 5.1

Additional comments

MSGroupFM avatar May 03 '24 15:05 MSGroupFM

(…) not through the standard form of the control panel (for example, YOOtheme Pro), (…)

So this is a issue of Yootheme?

ghost avatar Oct 10 '24 13:10 ghost

In the onContentAfterSave method of the "plg_system_schemaorg" there is code that clears the contents of the record in the table if the properties of the array with data are empty: if (empty($data['schema']) || empty($data['schema']['schemaType']) || $data['schema']['schemaType'] === 'None') { $this->deleteSchemaOrg($itemId, $context); return; }

It seems to me that this is not a correct check, because if editing Article outside the com_content, for example through YOOtheme Pro builder, then the data is cleared, because there is no standard form for sending data

MSGroupFM avatar Nov 26 '24 13:11 MSGroupFM

This issue fixed with Yootheme Pro 4.4.12+

alex-revo avatar Nov 26 '24 14:11 alex-revo

Please close this as it is not and was not a joomla bug.

brianteeman avatar Nov 26 '24 14:11 brianteeman