Custom view and remove objects

Author Message

laurent le cadet

Tuesday 02 October 2007 5:22:56 am

Hi,

I have a custom view (/content/view/my_custom_view/123) for a node which has children listed with a remove checkbox.

If I hit remove, removeobject.tpl asks me to cancel or confirm.
In both action, the redirection is /content/view/full without the destination node_id which should be 123.

I don't understand the "redirection" mechanism for remove action.
Noway by adding a redirectUri to the form.

Any idea?

Laurent

André R.

Tuesday 02 October 2007 6:29:03 am

have you tested 'ViewMode'?
action.php:

else if ( $http->hasPostVariable( 'RemoveButton' ) )
{
    if ( $http->hasPostVariable( 'ViewMode' ) )
    {
        $viewMode = $http->postVariable( 'ViewMode' );
    }
....

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

laurent le cadet

Tuesday 02 October 2007 6:36:05 am

André,

How/where can I test that?
In the removeobject.tpl form?

Laurent

André R.

Tuesday 02 October 2007 7:17:10 am

No, the template calling content/action.

<input type="hidden" name="ViewMode" value="my_custom_view" />

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

laurent le cadet

Tuesday 02 October 2007 7:32:53 am

Perfect (Très très bien).

Laurent

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