This site has been archived and you can no longer log in or post new messages. For up-to-date community resources please visit ezplatform.com

eZ Community » Forums » Developer » object states and related objects
expandshrink

object states and related objects

object states and related objects

Wednesday 08 August 2012 3:50:29 pm - 2 replies

Hi.

I have added object states to my content class. I also have related some of these objects to my front page. My problem is that the related objects fetch which i perform on the front side , does not seem to respect the object states limitations. 

The goal is for me to be able to add products on the frontpage, but these should only be displayed if the state is set to "visible for all". Currently this is ignored it appears. 

Is this a bug or what?

Thursday 09 August 2012 8:46:11 am

Hi

You can always do check:

{$related_object.can_read}

But I guess you're interested in more detailed knowledge of the matter. Also, I wonder if this is okay.

Perhaps the case is just like the:

{fetch( 'content', 'node', hash( 'node_id', XX ) )}

Cheers.

Saturday 11 August 2012 11:43:31 am

Hi Lars,

What's the code/fetch you're using?  And what version of eZ Publish are you using?

http://projects.ez.no/ezobjectstatesfilter might be useful for handling your fetches.

Cheers,
Geoff 

expandshrink

You must be logged in to post messages in this topic!

36 542 Users on board!

Forums menu

Proudly Developed with from