Closed (works as designed)
Project:
Internationalization
Version:
7.x-1.x-dev
Component:
Blocks
Priority:
Normal
Category:
Support request
Assigned:
Unassigned
Reporter:
Created:
15 Apr 2009 at 01:16 UTC
Updated:
22 Feb 2014 at 18:15 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #1
Lioz commentedsubscribing
i'm using the latest dev version together with translation helpers (drupal 6.10, php5 mysql5)
even if i choose "Treat translation nodes as a single node" when i switch to a language i can only see the original nodes (i see an empty page for the other languages.)
Comment #2
ezra-g commentedCan you clarify where the translated nodes are not appearing? They're not appearing in the View of the queue, or on the queue manipulation page? If the View is giving you the unwanted behavior, can you paste an export of the view here?
Based on the patch to i18n that got applied a long time ago, I would think that displaying the translated node in a view would be handled by i18n's db_rewrite_sql. However, I do notice that the current user's language Views filter adds an "AND (node.language in ('***CURRENT_LANGUAGE***'))" to the query, which won't work if the original node is in one language and the translation language is therefore note stored in node.language.
Once you clarify which problem you're having, we can pursue this further, probably in the i18n issue queue as a support request.
Comment #3
Lioz commentedi don't if this message was for me but i'll try to explain my problem.
i use the latest dev version of the 6x branch together with the latest version of views2 and translation helpers.
the goal is to have a unique queue for all supported language. So in this way i have to add only one node to the queue. when i click on the translation flags the queue has to show that node in the correct language.
I created the queue checking the "Treat translation nodes as a single node" option, then I added 4 nodes to the queue.
I modified the queue through views to display the fields i want, here is my view.
in that page i can only see the nodes that have been added to the queue. When i choose another language i get an empty page with no nodes.
i tried also without the current language filter but without success.
thanks in advance for your help, this is a great module!
Comment #4
h3000 commentedHere is mine as well:
". . . Can you clarify where the translated nodes are not appearing? . . ." - the nodes are not appearing in the view.
Treat translated nodes as single nodes is set in the nodequeue settings.
using Views - 6.x-2.3
Thanks.
Comment #5
niQo commentedSame problem using :
Drupal 6.10
view 6.x-2.5
nodequeue 6.x-2.0
i18n 6.x-1.0
With default nodequeue generated view, translated nodes are not appearing in the view and in the queue manipuliation page.
Only source language nodes are appearing.
Comment #6
pfaocleSame problem here: I create a nodequeue and ensure "Treat translated nodes as single nodes" is set. I add several nodes to the queue (source, English versions). When I look at the queue either via an unaltered, default nodequeue view OR via the /admin/content/nodequeue/x/view page I see the source/English nodes. However, the queue does not change when I switch language (eg go to /fr/admin/content/nodequeue/x/view).
I was hoping nodequeues and corresponding views would handle this stuff, rather than resort to manually adding each translation to the nodequeue, then filtering by user language in the View... any suggestions? Is nodequeue (and the admin/content/nodequeue/x/view page) supposed to deal with selecting the correct translation node to display?
Drupal 6.10, Views 6.x-2.5, Nodequeue 6.x-2.0, i18n 6.x-1.0, Translation Helpers 6.x-1.x-dev
Comment #7
ezra-g commentedShifting this to the i18n queue. Please see my comment in #2. Based on my understanding of how i18n implements views support, this should be beyond the scope of Nodequeue. Am I missing something?
Any guidance here would be greatly appreciated by myself and the folks in this issue (and probably plenty of other people as well).
Comment #8
ekes commentedI'm just working my head round this one as well.
In this case nodequeue just puts the nid of the source in. So obviously without doing anything the only node that will turn up is the one with the nid. When you stick i18n language_negotiation on it will then filter out any that don't meet the WHERE language criteria being used.
So you're going to have to add more nodes into the list to be filtered. Adding a join (relationship) on the translations would seem to be the obvious thing. But I'm yet to construct it so that I get the translated nodes themselves that relate to the original source nid stored in the nodequeue table. I'm not sure if it's possible with options so far.
Comment #9
tomsm commentedI think I have just reported a similar issue with the flag module:
http://drupal.org/node/511178
Comment #10
ekes commented@tomsm
Yes, think it's the same.
http://drupal.org/project/translation_helpers does the job so that only the original node and not its translations are actually in the nodequeue / flag tables.
However, when you then want to make view of this it will only show the the original node, not its translations. If you then add i18n filtering it may remove this as well (depending on mode).
The solution I believe is to make a join on the nodequeue / flag nid's with the translation tnids so they all end up in the view and can then be removed. The alternative is going to be putting all the nid's in the table (but I can see additional problems for nodequeue at least with this - queue length restrictions for a start).
[aside: I have written a solution for nodequeue (and an less working one for flag) for http://drupal.org/project/active_translation (which I intend to clean up and finish at some point). However it's easier there to do the look-up - just an inner join on a dedicated lookup table]
Comment #11
ekes commentedPossibly more accurate, certainly clearer title. But does this belong as a support request in translation_helpers, nodequeue/flag, i18n or views issue queues ;) see my comment above for more.
Comment #12
jose reyero commentedThis is 'query rewriting' working as expected.
We need this one to better handle these issues #364001: Improve query rewriting and content selection: options, parameters, fine tuning
Comment #13
mschneider commentedhi - i ran into the same problem - was their any solution to this problem at the end?
Comment #14
tomsm commentedI fixed a similar problem with the flags module. Maybe the solution for this issue is similar?
Please see: http://drupal.org/node/511178
Comment #15
jasperknops commentedI found the solution for Nodequeue translations with views:
You need to add 2 relationships in your view. The first one is 'Node translation: Source translation'. The second one is 'Nodequeue'. Set the first relationship as a relationship of the second relationship and set the second relationship as Required. Problem Solved!
Check the screenshot for the settings of the second relationship.
Comment #16
mathis commentedThank you Jasperknops for the advice!
Comment #17
danny_joris commentedHello Jasper,
Thank you for your solution! It's very helpful!
This could almost be the solution I need for this issue: #832116: Troubles setting up a multilingual ddblock using nodequeue
I'm using nodequeue to build a ddblock slider.
Before I found your solution I couldn't add translations of a node. They wouldn't show up automatically - only the originals were shown. With your solution all translations are automatically included properly, but only if there is at least 1 translated version of that node. If there is only single node (without translation) in the nodequeue, it won't show up at all.
Any ideas?
Comment #18
danny_joris commentedOk, I think it works great actually. If my nodequeue only allows 6 nodes, I can place 6 nodes in it + I can make as many translation nodes as I want. Great ! :)
Comment #19
netsensei commentedHi,
I'm experiencing the same problems here.
What I want to achieve: editors just add a node to the queue (independent of language: this could be the source node or a translation) It gets registered and on the front end, the correct translation is shown within the view.
I've also the same setup: Views + NodeQueue + Translation Helper + i18n
* Nodequeue is configured to work in the 'Treat all translations as a single node' mode.
* i18n is set to work with Shown current language + language neutral nodes
* Three languages are defined: Dutch, English and French
I've tried to use Jasper Knops' solution but to no avail. I've also tried to change the 'Source Translation' relationship into the 'Node translation: translations' relationship. Just to get all the translations and show them in my view. No luck there.
I've taken the SQL query it generates and ran it manually on my database, it just returns 1 row. I would expect it to return 3 nodes. The original one + the translations. Then, with the 'translation negotation' filters, I would be able to filter out just the relevant nodes. It has probably to do with nodequeue's INNER JOIN throwing all nodes out ot the resultsset which are not part of the nodequeue_nodes table.
I'm in a tight spot here to get this sorted out.
Here's the SQL:
Here's my Nodequeue View:
Comment #20
danny_joris commentedI imported your view to compare to mine. The only difference I could find was that in the Relationship - node translation: Translations - you have a dropdown called 'translation option' which i don't have. Changing the options, didn't make a difference.
When I test your view, it only displays results in the default language.
Comment #21
danny_joris commentedOh ok, I see now: You used 'Node translation: Translations' and I used 'Node translation: Source translation'. If I don't add a language filter, I see all the nodes.
I think I'm confused on what your issue is.
Comment #22
webflo commentedthx. this is awesome.
Comment #23
carn1x commentedThe Source Translation trick sort of worked for me, however if I have nodes that do not have a default-language translation then they still don't show in the View despite adding to the Nodequeue fine.
Comment #24
mattez commentedThe Source Translation trick sort of worked for me too. But it shows only nodes which are already translated. Nodes without translation are not shown.
Example:
Same when I put untranslated node in Spanish to nodequeue. Until I translated it its not shown in nodequeue.
I want to show all nodes in queue and than filter them via views lang filter Content translation: Language (= Current user's language).
I have tried to use "Content translation: Translations" setup to show ALL translations.
It really returns all nodes from my nodequeue, but setting up lang filter did nothing, still shows all translated nodes regardless of filter settings.
What I'm missing? It seems to me useless. I want simple thing: one multilingual limited (Queue size) nodequeue. So Internalization must be setup to "Treat translation nodes as a single node". And then display nodes in queue based on the current user language. It should not be dependent on whether the node is translated or not.
My setup:
Drupal 7.0
Internationalization 7.x-1.0-beta5
Translation helpers 7.x-1.x-dev
Nodequeue 7.x-2.0-alpha1
Comment #25
netsensei commentedI'd suggest you take a look at this module: http://drupal.org/project/smartqueue_language
Comment #26
metakel commentedI have tested the solution as at #15 on my Drupal 7.4. It works only when the node has translations. If the node is set to content neutral, it is not shown at all. Is there any way to display both "translations of current language (with url negotiation, i.e. http://xxx/en/content)" and "content which is language neutral" ?
Comment #27
jasperknops commentedIn hook_nodeapi I add the current nid as tnid on node create, if the node has no tnid yet. This way a node without translation will be displayed.
Comment #28
metakel commentedDear jasperknops (#27), would you tell in more detail how should we "add the current nid as tnid on node create"? Thank you!!!
Comment #29
mattez commented@netsensei Thanx, I'm still looking for solution for Drupal 7 :/
Comment #30
mattez commentedThanx, I'm still looking for solution for Drupal 7 :/
Comment #31
8ballsteve commented#15 Amazing!! - have been searching for a solution for this for a while.
Thanks so much!
Comment #32
Anonymous (not verified) commentedHooray for #15... Working on my first dual-language site, and this thread was extremely helpful.
Comment #33
filburt commentedThanks a lot jasperknops for the very very usefull post!
Comment #34
andes1 commentedI am using Drupal 7.12 and my Nodequeue ( 7.x-2.0-beta1 ) not working with translation inside View.
I create a content in Spanish and added it to nodequeue say 'NodeQ1' and translate this node to English. I have already set "Treat translation nodes as a single node" for nodequeue, so that it automatically use translation for the nodes inside assigned nodequeue.
I want to have a View that generate the result of node list of NodeQ1's nodes as per the User's current language. Inside view - i add relationship for "Nodequeue: Queue" , checked box for "Require this relationship" and select 'NodeQ1' from the queue list. Filter for "Content translation: Language (= Current user's language)"
This should show me the list of my NodeQ1 nodes as per User's Current language. but its not showing up. If I remove the nodequeue and apply the translation that works. Also my node level Translation and adding that to Nodequeue also work.
any idea why this behavior? or its bug in Drupal 7.
Comment #35
jose reyero commentedNot this module, please move to the right one before reopening
Comment #36
daveianoIs there a solution for displaying nodes without translations right now?
I have the same problem that only nodes which have a translation are shown in the view when adding the Source Translation Relationship.