It will be more convenient for the
client if he get a popup notification at the time of order completion. We
achieved this using Socket Programming in ADempiere.
In Socket Programming, messages
sends through ports using port number. The message send from the server is
identified by the client port and given to a popup window.
A column named IsNotified added to AD_Session
Table and it’s value is set to 'Y' by default.
When an order is completed, this column value will change to 'N'. Clients with IsNotified value 'N' will get the popup
notification. The popup will open in every minute and elapse automatically
after 10 seconds until the client closes it manually. This time IsNotified
column value will change to 'Y'. So that particular client won’t get any popup
notification further.
The following
classes added to ADempiere:
•
org.compiere.process.Notifier.java
•
org.compiere.process.PopupClient.java
•
org.compiere.process.Popup.java
The following
ADempiere class got changed:
•
org.compiere.util.Login
Here, Notifier
is a process created in ADempiere, and this process is given to an
ADempiere scheduler. Popup Class is called from PopupClient. PopupClient is
called from ADempiere Login class.
Popup notification
format: