Commit Graph

281 Commits

Author SHA1 Message Date
4a96501f73 Revert login layout 2026-03-11 12:03:13 -06:00
3e50172506 Polish login layout 2026-03-11 11:12:01 -06:00
d2b26dc113 Upgrade to JDK 25 2026-03-11 09:26:15 -06:00
520c1db334 Upgrade desktop to JDK 25 2026-03-11 09:26:15 -06:00
33674fc6a6 Fix logo layout 2026-03-11 09:10:48 -06:00
aba24aae49 Smooth logo badge 2026-03-11 09:09:10 -06:00
f36fdff871 Polish logo badges 2026-03-11 09:03:27 -06:00
719fd5e925 Ignore log files 2026-03-11 08:59:47 -06:00
1d8d118650 Fix sidebar scroll 2026-03-11 08:58:35 -06:00
130322d6d8 Fix chart colors 2026-03-11 08:55:21 -06:00
6089d1980c Adjust chart labels 2026-03-11 08:52:37 -06:00
3aab4560f4 Fix analytics fxml 2026-03-11 08:51:04 -06:00
cb92ca6e26 Fix analytics chart 2026-03-11 08:45:01 -06:00
2b5ea87e88 Fix chat assertion 2026-03-11 08:40:58 -06:00
26ba6e3695 Update chat requests 2026-03-11 08:38:48 -06:00
c3a318c6cc Fix refund table 2026-03-10 22:11:50 -06:00
bbc28bef47 Prefill refund dialog 2026-03-10 21:59:48 -06:00
d58801e51f Fix refund loading 2026-03-10 21:50:00 -06:00
7518e15a6b Fix inventory ids 2026-03-10 21:46:31 -06:00
8cb80d8ada Sync dev stack 2026-03-10 21:11:49 -06:00
b4e2d1cd2f Show chat mode 2026-03-10 20:52:07 -06:00
c18ef16ef6 Add chat takeover 2026-03-10 20:52:00 -06:00
e17cde6b87 Add desktop chat 2026-03-10 20:04:32 -06:00
2e401a544f Fix chat auth 2026-03-10 20:04:26 -06:00
84c5f3c7b1 Add chat websocket flow 2026-03-10 18:56:18 -06:00
bdde1d39dc Fix desktop mappings 2026-03-10 18:49:59 -06:00
1a2f551c06 Add auth store info 2026-03-10 18:49:51 -06:00
bd3575ef26 Add avatar fixture 2026-03-10 18:41:28 -06:00
d874dd1af8 Fix postman collection 2026-03-10 18:37:00 -06:00
319293a59d Fix backend validation 2026-03-10 17:15:26 -06:00
a12e23a713 Clean imports 2026-03-10 16:47:09 -06:00
fad80e436f Backend correctness fixes 2026-03-10 16:47:04 -06:00
c56fb9ab00 Backend fixes 2026-03-10 16:05:05 -06:00
89d3accabc Add seed data migration and fix schema NOT NULL constraints 2026-03-10 13:10:52 -06:00
8b10696c84 Fix backend security, validation, and API contracts 2026-03-10 13:03:14 -06:00
93b587cd9c Fix .gitignore to exclude user-specific files
- Remove tracked .idea/vcs.xml (user-specific VCS settings)
- Use whitelist approach for .idea/ directory (consistent with backend)
- Improve log file patterns (*.log)
- Remove redundant .idea/workspace.xml pattern (covered by wildcard)
2026-03-10 00:03:22 -06:00
e6e44f70d8 Fix .gitignore to exclude user-specific files
- Remove tracked .idea/dataSources.xml (user-specific DB config)
- Remove tracked .idea/vcs.xml (user-specific VCS settings)
- Use whitelist approach for .idea/ directory
- Add patterns for temp/backup files (*.backup*, *.py, temp_*.json, etc.)
2026-03-10 00:03:15 -06:00
1c4f13dc75 Ignore log files 2026-03-09 23:59:41 -06:00
Alex
03ce5ca090 add pet profile to pet list 2026-03-09 22:38:56 -06:00
7db2e63b79 Create 3 simple cross-platform run configurations
1. Pet Shop Application - Run Spring Boot (main run config)
2. Database - Start database containers
3. Reset Database - Clean volumes and restart (Maven-based, auto-stops)

All use IntelliJ Docker/Spring Boot/Maven integration (Windows/Mac/Linux).
Reset Database uses exec-maven-plugin to run docker compose down -v.
Stops automatically when complete.
2026-03-09 22:01:42 -06:00
015bb574b8 Add validation tests to detect run configuration drift
- Add spring-boot-starter-test dependency for JUnit Jupiter
- Validate main class exists and matches run config reference
- Validate module name matches pom.xml artifactId
- Validate schema.sql contains active column
- Prevents configuration breakage from refactoring
- Fails with clear messages pointing to which configs need updates

All 5 tests passing.
2026-03-09 22:01:42 -06:00
a1be1a5688 Improve Docker healthcheck to validate schema initialization
- Check for 'users' table existence instead of just mysqladmin ping
- Ensures schema.sql has executed before marking as healthy
- Add 40s start_period for initial schema load
- Prevents Spring Boot from connecting to uninitialized database
2026-03-09 22:01:42 -06:00
56bb4f19e8 Merge branch 'main' of github.com:RecentRunner/group-2-threaded-project-petshop-backend 2026-03-09 20:45:42 -06:00
2521806dea Add database auto-start configuration for development 2026-03-09 20:38:38 -06:00
a93846e2d1 Merge pull request #33 from RecentRunner/api-migration
Api migration
2026-03-09 16:27:30 -06:00
4a2cdbe9c5 Complete desktop DTO integration and controller fixes
**Critical DTO Fixes:**
- ServiceResponse/Request: id → serviceId, price → servicePrice, description → serviceDesc
- SaleItemRequest: productId → prodId, removed unitPrice (backend doesn't require)
- SaleItemResponse: id → saleItemId, added prodId, removed lineTotal (calculated locally)
- TopProduct: added productId, quantitySold Integer → Long, totalRevenue → revenue
- DailySales: date LocalDate → String, totalSales → revenue, added salesCount

**Controller Updates:**
- Updated 17+ controllers and dialog controllers to use renamed DTO fields
- Fixed AnalyticsController to use nested SalesSummary and InventorySummary structures
- Fixed ServiceController/ServiceDialogController to use serviceDuration
- Fixed LoginController CUSTOMER rejection to use lblError instead of missing showError()
- Updated all ProductResponse, SupplierResponse, PetResponse, AdoptionResponse, etc. usages

**Files Changed:**
- 6 DTO classes (service, sale, analytics)
- 17+ controller classes across main and dialog controllers

**Verification:**
- Desktop project compiles successfully with mvn clean compile
- All critical JSON mapping misalignments resolved
- Phase 6, 7, and 8 complete
2026-03-09 11:57:05 -06:00
Alex
2628f63f8c Updated design to look like JavaFX project
- updated the fxml file to have the same theming as desktop project
- removed old unused files to project neatness

TODO:
-hook up backend to application
-complete CRUD for each entity
- change text so it uses String.xml values
-add more info to profile if needed
-give pets their own profile
-fix small bug with status bar color not changing
2026-03-09 04:10:00 -06:00
6f87763a6d Complete final DTO verification and alignment
Changes:
- PetRequest: Fixed all field names to match backend contract
  - species → petSpecies
  - breed → petBreed
  - price → petPrice
  - dateOfBirth/gender/color → petAge (backend uses Integer age)
- PetResponse: Fixed all field names to match backend contract
  - id → petId
  - species → petSpecies
  - breed → petBreed
  - price → petPrice
  - Removed desktop-only fields (dateOfBirth, gender, color)
  - Added backend fields (petAge, createdAt, updatedAt)
- InventoryRequest: Fixed all field names to match backend contract
  - productId → prodId
  - stockQuantity → quantity
  - Removed desktop-only fields (storeId, reorderLevel)
- InventoryResponse: Fixed all field names to match backend contract
  - id → inventoryId
  - stockQuantity → quantity
  - Removed desktop-only fields (storeName, reorderLevel)
  - Added backend fields (prodId, createdAt, updatedAt)

All DTOs now use proper types (BigDecimal for prices, LocalDate/LocalDateTime for dates).
Desktop DTOs are fully aligned with backend contracts.
2026-03-09 01:35:48 -06:00
37327742ae Fix desktop UX and configuration
Changes:
- MainLayoutController: Analytics access restricted to ADMIN only
  - STAFF users default to Sales view instead of Analytics
  - Logo click redirects STAFF to Sales, ADMIN to Analytics
  - Analytics button hidden for STAFF users
- LoginController: Added CUSTOMER login rejection with clear message
  - CUSTOMER role users are now rejected at login with helpful error
  - Directs customers to use web/mobile applications instead
- Configuration cleanup: Removed connectionpetstore.properties from project root
  - Config file remains in src/main/resources for proper packaging
  - ApiConfig already loads from classpath correctly

These changes ensure proper role-based access control and clean configuration management.
2026-03-09 01:32:40 -06:00
90a6d5d464 Fix desktop structural DTO changes
Changes:
- PurchaseOrderResponse: id → purchaseOrderId
- SaleResponse: id → saleId
- DashboardResponse: restructured to use nested SalesSummary and InventorySummary classes matching backend structure
- Added TopProduct and DailySales support
- Inventory DTOs review pending (storeName/reorderLevel fields may need manual UI check)

These changes align desktop response DTOs with backend structural requirements.
2026-03-09 01:30:49 -06:00