Open spl1nes opened 7 months ago
File: phpOMS/DataStorage/Database/Mapper/ReadMapper.php
phpOMS/DataStorage/Database/Mapper/ReadMapper.php
The following mapper get example doesn't return any attributes that have no value/l11n component:
VehicleMapper::get() ->with('attributes') ->with('attributes/type') ->with('attributes/value') ->with('attributes/type/l11n') ->with('attributes/value/l11n') ->where('id', (int) $request->getData('id')) ->where('attributes/type/l11n/language', $response->header->l11n->language) ->where('attributes/value/l11n/language', $response->header->l11n->language) ->execute();
Only some attribute values have a localization but if we perform the above mentioned get we will only get the attributes that have a value with a l11n.
value
l11n
For the type this is no problem since all types have a l11n.
type
File:
phpOMS/DataStorage/Database/Mapper/ReadMapper.php
The following mapper get example doesn't return any attributes that have no value/l11n component:
Only some attribute values have a localization but if we perform the above mentioned get we will only get the attributes that have a
value
with al11n
.For the
type
this is no problem since all types have a l11n.