advanced-object-search icon indicating copy to clipboard operation
advanced-object-search copied to clipboard

[Bug]: Wrong data type for classId in bundle_advancedobjectsearch_update_queue table

Open AndrewKMoses opened this issue 2 years ago • 2 comments

Expected behavior

Expected data type for column classId in table bundle_advancedobjectsearch_update_queue to be varchar as $classDefinition->getId() returns string.

Actual behavior

Data type is int.

Steps to reproduce

This is an issue when you use your own unique identifier on DataObject classes.

image

The issue can for example be seen below where $classDefinition->getId() is a string.

https://github.com/pimcore/advanced-object-search/blob/4.x/src/Service.php#L351

AndrewKMoses avatar Oct 12 '22 07:10 AndrewKMoses

If I want to provide a PR for this, where do I put the migration?

There are migrations under src/Migrations and src/Migrations/PimcoreX but the migration under PimcoreX seems to not do anything?

AndrewKMoses avatar Oct 12 '22 08:10 AndrewKMoses

@AndrewKMoses i would say in both, that change was introduced in https://github.com/pimcore/advanced-object-search/pull/71 for v.3.0.0 which was supporting pimcore <6.5, so by having it in both folder it should be fixing for every version and not specifically for X. Thank you in advance and looking forward for the PR!

kingjia90 avatar Oct 17 '22 15:10 kingjia90