Hello,

For people who would like to do similar action, my solution is by using the following:

Issue:
========
Send hundreds of emails (since our mail server, wait 50 seconds per 10 emails). Notify users that email action has not completed.


Solution:
==============

1. "Send All" Button:
    <s:submit value="Send All"
              onclick="return confirmSubmit() &&
                       ajax_check_search_table('check_send_all_opr')"
              theme="simple"
              action="send_allProcessAction">
    </s:submit>
    Onclick layer.display in jquery function

2. Action class
   Add: private Boolean     email_finished             = false;

3. jsp page
<div id=".." style="display:none">
   <s:if test="email_finished == false">
      <marquee width=60% behavior=scroll>
      <font color=RED>
      <B>
Please do not leave the page and wait for email sending to be completed...............
      </B>
      </font>
      </marquee>
      <BR/>
   </s:if>
</div>


Emi






On 06/03/2011 10:12 AM, Emi Lu wrote:
Hello,

The "completeStack" should be whatever your normal stack is, I think.

struts.xml
====================
<interceptor name="execAndWait"
class="com.opensymphony.webwork.interceptor.ExecuteAndWaitInterceptor"/>

<action name="*ProcessAction" method="{1}" class="ProcessAction">
<interceptor-ref name="completeStack" />
<interceptor-ref name="execAndWait">
<param name="delay">2000</param>
<param name="delaySleepInterval">500</param>
</interceptor-ref>
<result name="wait">/wait.jsp</result>
<result name="success" type="tiles">browse_action1</result>

Tiles.xml
==================
browse_action1 => point to browse.jsp

Till now, no running exception. But the page always stays "browse.jsp"
while wait.jsp does not show at all.

Emi




---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscr...@struts.apache.org
For additional commands, e-mail: user-h...@struts.apache.org


--
Emi Lu, ENCS, Concordia University, Montreal H3G 1M8
em...@encs.concordia.ca        +1 514 848-2424 x5884

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscr...@struts.apache.org
For additional commands, e-mail: user-h...@struts.apache.org

Reply via email to