The frontend is a static multi-page application in Web/ that consumes the REST API directly from browser-side JavaScript.
Platform Coverage
The client is implemented as a web interface intended for both desktop and mobile usage, matching the project requirement that the user-facing component be available as a web solution across device classes.
Core Scripts
Web/js/app.js: shared navigation, cart interactions, booking/reservation flowWeb/js/auth.js: session persistence (token,user, expiration) in local storageWeb/js/products.js: product list rendering, filtering, sorting, category UI, cart actionsWeb/js/product.js: single product page data fetch and renderingWeb/js/dashboard.js: profile management and user order history
Public Pages
index.html: landing pageabout.html: company and service informationreferences.html: customer/reference contentproducts.html: catalog browsing with filtersproduct.html: details for one productcontact.html: contact and booking form
Authentication Pages
login.html: callsPOST /login, then stores token and user contextregister.html: callsPOST /signupwith form-level validation and consent checkbox
User Pages
cart.html: review and manage cart contentsorder.html: checkout form, order creation, and order item submissiondashboard.html: profile info, username/password update, own order listing/details
Admin Pages
admin.html: dashboard-level admin overviewadmin-products.html: product CRUD and stock operationsadmin-orders.html: order list and status updatesadmin-bookings.html: reservation management viewadmin-contacts.html: contact view scaffold (currently static sample content)
Session and Authorization Model
Client-side auth behavior:
- Successful login stores
tokenand user payload - Auth headers are generated as
Authorization: Bearer <token> - Session expires client-side after configured TTL (default 1 hour)
- Protected pages redirect when token/user context is missing or expired
Server-side enforcement is described in security.