O'Reilly logo

Agile Enterprise Application Development with Flex by Tony Hillerson

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

PharmaSales Application

Adobe AIR offers a data synchronization solution based on Data Management Services for those who own licenses of LiveCycle Data Service ES 2.6. This solution is described at the InsideRIA blog at http://tinyurl.com/6fa254.

But application developers who use an open source BlazeDS don’t have any generic way of setting such data synchronization process. This section offers a smart component called OfflineDataCollection that’s based on the DataCollection object described in Chapter 6. This component will take care of the data synchronization for you.

OfflineDataCollection is part of the Clear Toolkit’s component library clear.swc. You’ll see how to use it while reviewing a sample PharmaSales application that supports the sales force of a fictitious pharmaceutical company called Acme Pharm.

This application will have two types of users:

  • A salesperson visiting doctors’ offices trying to persuade doctors to use Acme Pharm’s latest drug, Xyzin

  • The Acme Pharm dispatcher who schedules daily routes for each salesperson

The corporate database schema supporting PharmaSales will look like Figure 9-11 (for simplicity, there are no relationships between tables).

The PharmaSales database model

Figure 9-11. The PharmaSales database model

Every morning a salesman starts the PharmaSales application, which connects to the corporate database (MySQL) and automatically loads his visit schedule for the day from the table ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required