How lebaohuflit06/librarymanagement works
Thư viện Sách Việt is an ASP.NET Core MVC library-catalogue and membership app backed by SQLite. Visitors can browse the home page, search and filter books, and view book details; account registration/login enables the separate library-card registration and card-view workflow. Controllers own these operations and use EF Core for persisted data; account actions also establish cookie sessions. The README confirms SQLite and first-run database creation. View links follow MVC conventions, but the view contents were not sampled, so those relationships are shown as unverified.
Main entry points: AppDbContext.cs EF Core context and seed data · BooksController.cs Book search and details · AccountController.cs Account registration and login · HomeController.cs Home summary
Components 21
Web entry
- App startup and routing
Program.cs - Cookie authentication
Catalogue
- Home summary
Controllers/HomeController.cs - Book search and details
Controllers/BooksController.cs - Vietnamese text normalization
Helpers/TextHelper.cs - Home page
Views/Home/Index.cshtml - Book list page
Views/Books/Index.cshtml - Book details page
Views/Books/Details.cshtml
Membership
- Account registration and login
Controllers/AccountController.cs - Library card registration and view
Controllers/LibraryCardController.cs - Login page
Views/Account/Login.cshtml - Account registration page
Views/Account/Register.cshtml - Card page
Views/LibraryCard/Index.cshtml - Card registration page
Views/LibraryCard/Register.cshtml
Data and models
- EF Core context and seed data
Data/AppDbContext.cs - SQLite database
- Book entity
Models/Book.cs - User entity
Models/AppUser.cs - Library card entity
Models/LibraryCard.cs - Workflow view models
Models/ViewModels.cs
Other components
- Visitor
Connections 27
- Visitor → App startup and routing: requests pages
Program.cs - App startup and routing → EF Core context and seed data: configures and initializes
Program.cs - App startup and routing → Cookie authentication: configures
Program.cs - App startup and routing → Home summary: routes requests
Program.cs - Visitor → Home summary: requests home
- Visitor → Book search and details: requests catalogue
- Visitor → Account registration and login: submits credentials
- Home summary → EF Core context and seed data: reads catalogue and counts
Controllers/HomeController.cs - Book search and details → EF Core context and seed data: reads books
Controllers/BooksController.cs - Book search and details → Vietnamese text normalization: normalizes search
Controllers/BooksController.cs - Account registration and login → EF Core context and seed data: reads and writes users
Controllers/AccountController.cs - Account registration and login → Cookie authentication: signs in and out
Controllers/AccountController.cs - Library card registration and view → EF Core context and seed data: reads and writes cards
Controllers/LibraryCardController.cs - EF Core context and seed data → SQLite database: persists data
- EF Core context and seed data → Book entity: maps and seeds
Data/AppDbContext.cs - EF Core context and seed data → User entity: maps users
Data/AppDbContext.cs - EF Core context and seed data → Library card entity: maps cards
Data/AppDbContext.cs - User entity → Library card entity: has optional card
Models/AppUser.cs - Home summary → Workflow view models: builds summary
Controllers/HomeController.cs - Book search and details → Workflow view models: builds book list
Controllers/BooksController.cs - Home summary → Home page: renders
- Book search and details → Book list page: renders
- Book search and details → Book details page: renders
- Account registration and login → Login page: renders
- Account registration and login → Account registration page: renders
- Library card registration and view → Card page: renders
- Library card registration and view → Card registration page: renders