Home Contact Us Feedback About Us

Code Example - Maintain Customer Screen

Step 1) Create the Customer & Address Business Objects




#Note: Both sections of code were already created for Search Customer and can be reused.

Step 2) Create the Customer Maintenance Screen

Step 3) Register the Maintenance Screen with the Business Object

Step 4) Run Application

You now have a fully functioning maintenance screen that allows users to create and update customer details.
Resulting Maintenance Screen in Rich Client Mode (using Swing)
Resulting Maintenance Screen in Web Mode
Features and Functionality of the Maintenance Screen
  • screen layout
    • screen title
    • positioning and type of fields and columns (e.g. checkbox and date field)
    • field/column labels and corresponding float over text
    • data entry validations (format, type, size, etc...)
  • save customer
    • validates the current customer (e.g. mandatory fields and additional business rules)
    • saves the current customer
  • delete customer
    • validates that the customer can be deleted
    • requests user to confirm delete operation
    • deletes the current customer and related information (e.g. addresses)
  • cancel
    • cancels changes and returns to previous screen
  • view previous/next customer ("<<" & ">>" buttons)
    • displays the previous/next customer based on the results displayed in the Search Customer screen
  • new customer
    • saves changes to existing customer (if any) and allows a new customer to be entered
  • view address details
    • displays the Maintain Address screen for the selected address
  • add address ("+" button)
    • allows users to add an address to the customer by using the Maintain Address screen
  • delete address ("–" button)
    • removes the selected address from the customer
  • fields and buttons are visible and/or enabled based on:
    • security rules (permissions based on the current user)
    • business rules (e.g. active customers can not be deleted)
    • interaction rules (e.g. date of birth is enabled if marketing is selected)
#Note: Refer to the tutorial for more detailed information about this code example.