If the app exists already, be prepared to spend major time re-architecting it. An offline mode is not something you can easily add after the fact. Google had a browser plugin called Google Gears that helped implement offline web apps, but its development has been halted in favor of some related technologies that are coming in HTML 5.

An alternative might be to ship a desktop app that has an embedded servlet container with the complete web app running inside it. If a network connection was available, it would get its data from the "live" database, and if no connection is available, it would work with a local copy. This would reduce the problem to a data synchronization issue, for the most part.