Thursday, May 31, 2018

Implementing a 'please wait' page

Hello Guys,

I currently have a process running on my django application which takes about 10-15 minutes to complete.

Currently, the user clicks on a 'submit' button and this process starts. The web page remains in a hung state for the complete time this process takes to run and after say 10-15 mins another 'results' page is displayed.


I want to be able to display a page saying 'please wait for <lenght of time taken to complete process>' after submit button is clicked. Can you please give me any ideas on how to implement this.


Here is a rough representation of my code flow:

Main function ():
-lots of code
-call to sub function() //this is the guy taking 10-15 mins to execute
-if sub function() returns true then proceed else break and exit.
-remaining code of Main function()

As you might have guessed, I want to be able to change the display when this sub function () is hit. Btw, main function () is executed when user clicks on submit button.


Appreciate your help!

Thanks and Have a great day,
Mohammed Noor

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/5CF991C0-FB63-47BA-9A2A-47224E468D0B%40gmail.com.
For more options, visit https://groups.google.com/d/optout.

No comments:

Post a Comment