fetch content list and always available option

Author Message

Nathalie Grimaud

Wednesday 07 January 2009 3:53:53 am

Hi,
When I do a fetch content list (without any special option on the language) on a node where some children are not translated I always obtain the same result set: all the children are displayed.

Even if I uncheck the "Use the main language if there is no prioritized translation" option the untranslated children are still returned.

Is this a bug (found this in 3.9.2 and 4.0.1) or did I miss something?

Thanks
Nathalie

André R.

Wednesday 07 January 2009 4:14:02 am

Also looked at the class to see if "Default object availability" is enabled?

eZ Online Editor 5: http://projects.ez.no/ezoe || eZJSCore (Ajax): http://projects.ez.no/ezjscore || eZ Publish EE http://ez.no/eZPublish/eZ-Publish-Enterprise-Subscription
@: http://twitter.com/andrerom

Nathalie Grimaud

Wednesday 07 January 2009 4:22:17 am

Hi André,

In the content class the "Default object availability" option is set to "Not available"...

André R.

Wednesday 07 January 2009 4:35:24 am

Whats the language settings for the siteaccess your doing this on?
Post the whole 'RegionalSettings' and 'ContentSettings' settings block from site.ini.append.php in your siteaccess settings.

eZ Online Editor 5: http://projects.ez.no/ezoe || eZJSCore (Ajax): http://projects.ez.no/ezjscore || eZ Publish EE http://ez.no/eZPublish/eZ-Publish-Enterprise-Subscription
@: http://twitter.com/andrerom

Nathalie Grimaud

Wednesday 07 January 2009 5:00:43 am

Here are the settings for the fr siteaccess

[RegionalSettings]
Locale=fre-FR
ContentObjectLocale=fre-FR
SiteLanguageList[]
SiteLanguageList[]=fre-FR
SiteLanguageList[]=eng-GB
TextTranslation=enabled

I did not override the default ContentSettings block

Stéphane Bullier

Thursday 08 January 2009 12:48:17 am

Hello,

I have same parameters in my site.ini file for fr siteaccess.

This is my site.ini file for en siteaccess :

[RegionalSettings]
Locale=eng-GB
ContentObjectLocale=eng-GB
SiteLanguageList[]=eng-GB
ShowUntranslatedObjects=disabled
TextTranslation=disabled

Stéphane

Nathalie Grimaud

Thursday 08 January 2009 2:34:50 am

Hello Stéphane,

Thanks for your contribution ; I have the same settings for my en siteaccess.

I still don't understand why in my fr siteaccess the fetch content list always return all the children nodes whatever the always available option is for an untranslated child.

Stéphane Bullier

Thursday 08 January 2009 3:24:24 am

Have you check your file settings/override/iste.ini.append.php ?

There is nothing about [RegionalSettings] ?

Stéphane

André R.

Thursday 08 January 2009 3:36:15 am

What languages do you have? And what is the 'bug' here, your settings define that both fr and en languages are fetched. And you haven't defined ShowUntranslatedObjects so make sure it is disabled for your front end site access (and overwritten by override/extensions settings).

eZ Online Editor 5: http://projects.ez.no/ezoe || eZJSCore (Ajax): http://projects.ez.no/ezjscore || eZ Publish EE http://ez.no/eZPublish/eZ-Publish-Enterprise-Subscription
@: http://twitter.com/andrerom

Nathalie Grimaud

Friday 09 January 2009 6:46:25 am

Thanks Stéphane and André for your help, I've finally got the solution.
The problem was that I misunderstood the "untranslated" notion.

For me a node was untranslated if it did not exist in the current siteaccess language (fre-FR).
But now I understood that a node is actually untranslated when it does not exist in <b>any</b> of the languages defined in the SiteLanguageList[] setting for the current siteaccess (fre-FR + eng-GB).

In my case all the nodes existed in English so they were always all considered as translated and thereby always displayed whatever the "always available" option value was.

So here is the solution if this can help someone : just remove eng-GB from the SiteLanguageList[] and simply use the "always available" checkbox to display the node or not.

Thanks again,
Nathalie

Powered by eZ Publish™ CMS Open Source Web Content Management. Copyright © 1999-2014 eZ Systems AS (except where otherwise noted). All rights reserved.