I am trying to change the behaviour of the right click menu actions (reply and forward etc) so that certain message types are treated differently by redirecting them to a different document (achieved by setting changing the UNID in window.frameElement.src). This works perfectly, but the problem I am facing is with the closeDWAFrame when I attempt to subsequently send the message: sid (the windowframeElement.id is blank and no longer contains the id of the new message (I believe the new current window is s_JSMain). Is there a way to ensure that the sid is correct when closeDWAFrame is invoked or will I have to pass it around on the URL?
Hope this makes sense, thanks!
Marc
Subject: Not clear
Can you provide more details? It’s not clear what you mean by “by redirecting them to a different document”. You mentioned reply and forward. So do you mean you open a different document from the one that is being replied to/forwarded? Or do you mean you use a different reply/forward form instead of the normal one?
Subject: Re:Not Clear (closedwaframe)
Thanks for your reply. In answer to your question, I am opening a different document to the one that is being replied/forwarded to, but using the normal forms (full mode). The way I have done this is to create my own schema by setting the subscene (s_subscene) to I have then defined my own subform (_Init. Within this form I then read the PATH_INFO environment variable and substitute the s_mailParentUnid with the UNID of a different document. I then redirect to this URL via location.href. The content is fine and does exactly what I want. The problem is that when I attempt to send the document, closeDWAFrame tries to close the main window and the sID passed in is blank (normally it is e-iframe-$new). I think the problem may be linked to the panel manager (AAA.Fkb). When I was stepping through the code I noticed that in the case where I do a redirection the following anonymous function is called: return function(){EdF.apply(oBindee, EUW;};}. Without my customizations in place, this does not happen.
Further observations- I have found a hacky workaround to this problem: within closeDWAFrame I noticed that the parent’s parent window also had a closeDWAFrame method on it (and moreover, the parent window corresponded to the e-iframe-$new window).
Calling parent.parent.closeDWAFrame(parent.window.frameElement.id,1) closed the correct window. This implies that the window hierarchy has changed. Since I am only doing a redirection (please see above) why would this happen? Should I find a way to reload the tab to correct the window hierarchy?
Many Thanks,
Marc