XF 2.3 Dynamic Entity Relation Conditions

mjda

Well-known member
Is it possible to do a relation where I pass it a dynamic variable to use in the conditions somehow?

PHP:
'VehicleYear' => [
    'entity' => 'CarData:VehicleYear',
    'type' => self::TO_ONE,
    'conditions' => [['vehicle_id', '=', '$vehicle_id'], ['vehicle_year', '=', '$someYear']],
    'primary' => true
],
 
Back
Top Bottom