Follow up for #1498674: Refactor node properties to multilingual
Problem/Motivation
In 1498674 was the @todo
+ // @todo This should be actually filtering on the desired node status field
+ // language and just fall back to the default language.
On the lines in the patch in comment #303:
125, 884, 1192, 1211, 1228, 3593
The lines of the final patch might change but that info might help to find them.
For example,
function menu_tree_check_access(&$tree, $node_links = array()) {
if ($node_links) {
$nids = array_keys($node_links);
- $select = db_select('node', 'n');
+ $select = db_select('node_field_data', 'n');
$select->addField('n', 'nid');
+ // @todo This should be actually filtering on the desired node status field
+ // language and just fall back to the default language.
$select->condition('n.status', 1);
+
$select->condition('n.nid', $nids, 'IN');
$select->addTag('node_access');
$nids = $select->execute()->fetchCol();
$select->condition('n.status', 1);
is filtering by "1" the default language.
Proposed resolution
Make actually filter on the desired node status field language and just fall back to the default language.
Remaining tasks
- Take one example from the code and show how it would be different to make it actually filter.
- Repeat that for the other places. (good for novice!)
User interface changes
No.
API changes
No.