Summary of L3 architecture (6)

Source: Internet
Author: User

Model type:
Add two constructor values and default values.
Remove the modellist type and use list <model> instead. You can add the list method to the corresponding model.
It is easier to use dataset for related lists.
Dal
For data reading, try {} catch {} is not required {}
You can use a custom exception handling method for database operation problems.
Use partial to separate methods with business logic from common addition, query, deletion, and modification methods
Bll
Add default constructor and corresponding Dal instance
Use partial to separate methods with business logic from common addition, query, deletion, and modification methods
UI
Set folders by module
The outermost layer only leaves public pages, such as login and errorpage.
You can use the same page for adding and editing. You can set the primary key to 0 when adding, and determine the method of calling the Dal in The bll layer.
It is best to use symmetric encryption for transmitted parameters to improve security.

Custom Exception Handling
During this period, some exceptions are thrown and cannot be thrown to the error page for handling. In fact, errors can be recorded during catch.
In this project, if it is post back, an exception occurs, and the ApplicationProgramYou cannot switch back to the error page, so use custom exception handling.

Permission Control
The operation permission and browsing are still divided into two sets of pages. However, there is an idea that the operation button can be used to determine the permissions when initializing the interface to reduce the number of pages.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.