function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
arunkarunk 

pop-up alerts possible?

Hi,

 

I am new to salesforce. And am planning to create a hotel management system.

Suppose there are four types of roles: Client, waiters, chefs and managers.

What i want is that whenever a client pays a bill amount greater then a predefines value, a alert should pop-up in front of all logged-in managers. Is this possible? Are there any work arounds for this ?

 

 

I know that email alerts are possible in this scenario. But i would prefer a pop-up alert. 

 

Thanks in advance,

arun. 

Message Edited by arunk on 06-09-2009 05:17 AM
Best Answer chosen by Admin (Salesforce Developers) 
dchasmandchasman
There should be no reason to write any javascript to solve this - take a look at the doc and examples for the apex:actionPoller component which allows you to easily wire up a call to an action method where you can check the status you're looking for and also makes it trivial to perform a partial page update to indicate when things have met your specific criteria etc...

All Answers

Force2b_MikeForce2b_Mike

If you're writing this in VisualForce, you could build in your own validation using JavaScript with the alert() function for pop-ups. I think beyond that you would need to use the standard SalesForce.com validation rules which would display save errors at the top of the page or at the specific field with the error. 

 

Mike 

arunkarunk

Hi Mike,

 

Thanks for the reply.

 

The problem is that i dont want the error on the page where the condition is checked.

I want to alert all "managers" when the condition accurs.

Is this possible? 

metaforcemetaforce

You might want to check out Activity and Remiders feature of Salesforce. Theoretically, whenever the payment happens, check for your condition ion Apex and accordingly create a Task/Event with reminder settings and assign it to appropriate user. This should work, but needs to be explored for exact implementation.

 

Alternatively, you can create a JavaScript residing in the VF pages of your logged on user's that keeps polling on a specific field at regular intervals to check whether such a payment has happened. If yes, then display whatever message you want to your Managers. This has to be an asynchronous call to avoid page refreshes.

 

Hope this helps. Please don't forget to post the exact solution to help the entire community.

 

Best

 

metaforce

 

--------------------------------------------------------------------------------------------------
Mark it as an accepted solution if it works and help the community

dchasmandchasman
There should be no reason to write any javascript to solve this - take a look at the doc and examples for the apex:actionPoller component which allows you to easily wire up a call to an action method where you can check the status you're looking for and also makes it trivial to perform a partial page update to indicate when things have met your specific criteria etc...
This was selected as the best answer