View Issue Details
|ID||Project||Category||View Status||Date Submitted||Last Update|
|0006444||OXID eShop (all versions)||4.01. Database handling||public||2016-07-08 16:18||2016-07-08 16:58|
|Product Version||4.10.0 / 5.3.0|
|Target Version||Fixed in Version|
|Summary||0006444: Standard oxList __construct doesn't initialize the sCoreTable breaking containsFieldValue - long field name can't be constructed|
|Description||I tried to see if a certain user group existed in a user and containsFieldValue always returned false, even though I checked in the backend and the database that the user group was correctly assigned.|
Investigating I found that the sCoreTable wasn't correctly set for the oxList that was returned from getUserGroups. Investigating further I've noticed that quite a lot of object lists were initialized by simply using the oxList constructor, which doesn't set the sCoreTable.
Suggesting to either in a localized case adding the sCoreTable setting through init in the getUserGroups function and in a more wide solution trying to recover the sCoreTable from the first element that is set into the oxList if it's not already set? You're the pros, you decide.
|Steps To Reproduce||1. Retrieve a oxUser object|
2. Call getUserGroups on it
3. Call containsFieldValue looking for a specific oxid of a group you know the user has
4. Observe always getting false as a result
|Tags||No tags attached.|