Added detailed documentation: ARCHITECTURE.md, CONVENTIONS.md, GLOSSARY.md, and copilot-instructions.md for Mango.Nop.Core, Data, and Services. Updated/added README.md files for all Mango.Nop libraries and the FruitBank nopCommerce plugin, clarifying structure, key types, and usage. Switched appsettings.json connection string from production to development database. These changes improve developer onboarding and enforce architectural consistency. |
||
|---|---|---|
| .. | ||
| Dtos | ||
| Entities | ||
| Extensions | ||
| Interfaces | ||
| Loggers | ||
| Models | ||
| NopDependencies | ||
| Services | ||
| Utils | ||
| Mango.Nop.Core.csproj | ||
| NopCommonConst.cs | ||
| README.md | ||
README.md
Mango.Nop.Core
Shared domain library containing entities, DTOs, interfaces, and nopCommerce entity mirrors. net9.0.
Folder Structure
| Folder | Purpose |
|---|---|
Dtos/ |
DTO classes shared across consumers: MgOrderDto, MgOrderItemDto, MgProductDto, MgGenericAttributeDto, MgStockQuantityHistoryDto, CustomerDto, ModelDtoBase |
Entities/ |
Custom entities: MgEntityBase, MgStockTaking, MgStockTakingItem |
Extensions/ |
Extension methods for nopCommerce BaseEntity collections and GenericAttribute |
Interfaces/ |
DTO interfaces (IMgOrderDto, IMgProductDto, etc.), soft-delete interfaces, foreign key markers |
Loggers/ |
ILogger / Logger — logging abstraction |
Models/ |
Login request/response models (MgLoginModelRequest, MgLoginModelResponse) |
NopDependencies/ |
Mirror copies of nopCommerce entity classes — BaseEntity, Customer, Order, OrderItem, Product, GenericAttribute, enums (OrderStatus, PaymentStatus, etc.) |
Services/ |
IMgLockService interface |
Utils/ |
CommonHelper2 — utility methods |
Key Types
DTOs (Dtos/)
MgOrderDto— Order DTO used across SignalR communicationMgOrderItemDto— Order item DTOMgProductDto— Product DTO with GenericAttribute-based propertiesMgGenericAttributeDto— GenericAttribute DTOModelDtoBase/IModelDtoBase— base class for all DTOs
nopCommerce Mirrors (NopDependencies/)
Mirror copies of nopCommerce entities so that Mango.Nop.Core can be referenced without pulling in the full nopCommerce dependency chain. Includes:
BaseEntity— root entity baseCustomer,CustomerRole,Order,OrderItem,Product,GenericAttribute,StockQuantityHistory- Enums:
OrderStatus,PaymentStatus,ShippingStatus,ProductType, etc.
Entities (Entities/)
MgEntityBase— base for all custom Mango entitiesMgStockTaking,MgStockTakingItem— stocktaking entities
Dependencies
linq2db— data accessMessagePack— binary serializationMicrosoft.AspNetCore.Mvc.NewtonsoftJson— JSON serialization