I would like to create an ERP website which can serve with difference companies. The website will have the following functionality
- Product Listing & Product Detail
- Shopping Cart & Online Payment
- Shipping Address & Delivery Tracking Status
- Sales Order, Purchase Order & Invoice Listing
- Login By difference Roles e.g. Sales Representative, Customer and Administrator
It is an ERP website (B2C and B2B) and it is used by difference companies and vendors.
Developed using Angular, ASP.NET Core Web API and SQL Server.
For example, each companies will have slightly difference in the product listing page
Example 1) ProductListing.aspx
contains many if-then-else statement to serve for difference companies in the same pages
if CompanyA then
do something
if CompanyB then
do something
Example 2) Duplicated the codes with difference files, it aims for separate difference business rule and logic
ProductListing_CompanyA.aspx
ProductListing_CompanyB.aspx
ProductListing_CompanyC.aspx
Example 3) ProductListing.aspx
but include/embedded difference components and each components will contains difference business rule and logic of the companies. But if-then-else statement still appear everywhere in the page
Any design patterns and best practices to improve the site to be reusable, readable, sustainable, extendable and maintainable ?
Peter is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.