C
C. Watters

Dry Cleaning POS System

MudBlazor POS provides a dry-cleaning point-of-sale layout using MudTable for service lists and MudForm validation for customer input. Includes responsive MudDrawer, order summary card, and a payment MudDialog.

LIVE DEMO
Generated using Instruct UI - An AI for Blazor UI Generation
## What's implemented - Point-of-sale layout with responsive left navigation (MudDrawer) and top app bar (MudAppBar). - Customer search bar and "New Customer" dialog with form validation. - Service list presented as a simple table and Add buttons to build an order. - Current order displayed in a MudTable with quantity controls, item remove, subtotal/tax/total calculation. - Payment confirmation dialog with payment method selection (MudDialog + MudRadioGroup). ## Key components - MudLayout, MudAppBar, MudDrawer, MudNavMenu - MudTextField, MudButton, MudIconButton - MudSimpleTable, MudTable, MudTh, MudTd - MudCard, MudCardHeader, MudCardContent, MudCardActions - MudForm, MudDialog, MudRadioGroup - DialogService injection and use of IMudDialogInstance - Model classes: OrderItemModel, CustomerModel (with DataAnnotations) ## How it works - Services list is a local Dictionary rendered into rows; AddItemToOrder creates or increments OrderItemModel entries and calls CalculateTotals. - Quantity updates and removes mutate the _orderItems list; CalculateTotals recomputes subtotal, tax (10%) and total and calls StateHasChanged. - NewCustomerDialog uses MudForm with @bind-IsValid and a CustomerModel; it validates before returning a DialogResult.Ok(_customer). - PaymentDialog receives Amount via [Parameter], shows radio options, and returns DialogResult.Ok on confirmation. - DialogService (injected) opens dialogs and awaits results; page-level state is in component fields. ## Styling - Uses MudBlazor components and theme variables (CSS references to --mud-palette and --mud-elevation in app.css). - Custom .category-button CSS adds hover transform and elevation for category tiles. - Layout uses MudGrid/MudItem responsive breakpoints (xs/md) and DrawerVariant.Responsive for small-screen behaviour. ## Reuse steps 1. Add MudBlazor NuGet and register Mud services in Program.cs (e.g. builder.Services.AddMudServices()). 2. Import MudBlazor namespaces in _Imports.razor and reference MudBlazor CSS in index.html/_Host. 3. Copy the component .razor files and PosModels.cs into a Pages or Shared folder; include app.css and ensure it loads. 4. Ensure DialogService is available (provided by MudServices) and wire data models or replace in-memory dictionaries with services. 5. Adapt payment dialog to a real payment provider and persist customers/orders through API services. ## Limitations & next steps - This is a single-page demo: no persistence, authentication, user roles, or real payment integration are implemented. - Tax rate and pricing are hard-coded; move to configurable settings or backend. - Error handling, concurrency for order holds, offline/real-time sync, and server-side validation are missing. - Add unit and component tests, accessibility checks, and localization for production use. - Consider wiring a backend API (customers, orders, payments) and secure the DialogService flows when integrating into a larger app.