// Convert a single-valued array of values to the single-value case,
// and transform from IN() notation to = notation
if (is_array($info['value'
]) &&
count($info['value'
]) == 1
) { $info['value'
] =
array_shift($info['value'
]);
} if (is_array($info['value'
])) { // We use an SA-CORE-2014-005 conformant placeholder for our array
// of values. Also, note that the 'IN' operator is implicit.
// @see https://www.drupal.org/node/2401615.
$operator = !
empty($info['operator'
]) ?
$info['operator'
] : 'IN';
$placeholder = ':views_join_condition_' .
$select_query->
nextPlaceholder() . '[]';
$placeholder_sql = "(
$placeholder )";
} else { // With a single value, the '=' operator is implicit.
$operator = !
empty($info['operator'
]) ?
$info['operator'
] : '=';
$placeholder =
$placeholder_sql = ':views_join_condition_' .
$select_query->
nextPlaceholder();
} // Set 'field' as join table field if available or set 'left field' as
// join table field is not set.
if (isset($info['field'
])) { $join_table_field = "
$join_table$info[field
]";