Datasheet

6
Chapter 1: A Framework for Enterprise Applications
Chapter 10: The Query Builder Control
As soon as you give users access to reports or views of data, they are going to want to filter it based on a
date, a user, status, and so on. Most of the time users want the same data but filtered in a different way.
This chapter explains how to build a query builder server-side control that uses AJAX to enable users to
dynamically create their own filters, which can be applied to views or any report that was designed in
Chapter 9. This empowers users to extract the data they are interested in and manipulate it in Excel or
simply display it in a PDF file.
Chapter 11: The Dashboard
Dashboards are becoming standard in web applications, and the intrinsic web part controls that come
with Visual Studio make it simple to create a useful home page that can display graphs, alerts, docu-
ments, and more — and put the most important data right in front of the user. This chapter reviews the
web part controls and how they work, and builds a home page with a dashboard for the Paid Time Off
application, including alerts for users when requests are pending approval.
Chapter 12: Auditing
Auditing is important, if not mandatory, in most corporate applications. With the introduction of the
Sarbanes-Oxley Act in 2002 and increasing government regulations in the pharmaceutical industry,
auditing is an important feature that you will likely be asked to implement in your own applications.
This chapter demonstrates a design pattern for developing a field-by-field audit trail with before and
after values and a date\time stamp, and one that captures the user name for any changes to our vaca-
tion request application. You could easily adopt this pattern into your own application and save weeks
of programming time needed to comply with the strict guidelines required by the government or your
own organization.
Chapter 13: Code Generation
A code-generation tool can automatically write the majority of the patterns used in this book. This cus-
tom code-generation tool is written in Visual Studio 2008 and enables the user to point to a database and
a table to generate the stored procedures, data layer classes, and business classes. This will save develop-
ers a tremendous amount of time, as they wont be stuck coding the tedious pieces of the application and
can concentrate on the business rules given to them by the user.
Solution
As stated earlier, this solution uses a three-layered architecture: the user interface (UI), the business logic
layer (BLL), and the data access layer (DAL). When building a solution in Visual Studio, you can include
multiple project types in the same solution, making it easy to manage all three layers in one place. The UI
layer consists of a web application and server-side controls. Essentially, anything that the user interacts
with directly is considered part of the UI layer. UI developers or designers control the overall look and
feel of the site, and typically excel at design, rather than programming. They focus on fonts, colors, and
making sure the application meets the company’s branding requirements.
96865c01.indd 6 12/17/08 2:06:02 PM