Skip to content

AutoShare – Major Frontend & Backend Integration#7

Merged
ChamilkaMihiraj2002 merged 83 commits intomainfrom
Dev
Feb 15, 2026
Merged

AutoShare – Major Frontend & Backend Integration#7
ChamilkaMihiraj2002 merged 83 commits intomainfrom
Dev

Conversation

@ChamilkaMihiraj2002
Copy link
Copy Markdown
Owner

📌 Summary

This PR connects major frontend and backend flows for AutoShare, including:

  • Auth & profile improvements
  • Vehicle management
  • Renter booking options
  • Owner booking requests
  • UI/UX polish (loading states, notifications, and currency display)

🔄 What Changed


🖥 Backend

👤 User APIs

  • PATCH /users/me – Profile updates
  • POST /users/me/avatar – Avatar upload
  • GET /users/{uid} – Public profile lookup (for owner booking request name display)

🚗 Vehicle APIs & Schema

  • Vehicle image upload/delete support
  • Multiple vehicle images support (image_urls + legacy compatibility)
  • Added seats (capacity) to vehicle schema and create/update flows
  • Availability updates via existing vehicle patch flow

📦 Rent APIs & Schema

  • Added owner-specific list endpoint:

    • GET /rents/owner
  • Extended rent model with renting options:

    • pickup_option
    • delivery_address
    • insurance_plan
    • child_seat_count
    • note

💻 Frontend


🔐 Auth & Profile

  • Google login/signup integration support
  • Profile details loading fixes after login
  • Full profile editing in renter section (including full name)
  • Avatar upload + navbar/profile image display

🚘 Vehicle Owner Flows

  • Add vehicle with capacity (seats)
  • Vehicle view/edit/delete page connected to backend
  • Vehicle image upload + delete in manage flow
  • Availability toggle from vehicle card settings wheel
  • Loading overlays/screens for owner flows
  • Modal confirmations and toast notifications (replacing browser alerts)

🔎 Public / Renter Vehicle Flows

  • Fixed View Details from public cards and search results
  • Improved details fallback handling when card data is sourced differently
  • Added renter booking options UI after selecting vehicle
  • Connected booking options to backend rent creation payload

📋 Owner Booking Requests

  • Replaced mock data with backend-powered request lists
  • Display renter name instead of renter UID by resolving /users/{uid}
  • Added booking request “View” details modal

🎨 UI Consistency & Improvements

  • Switched displayed pricing to Sri Lankan Rupees (Rs) across key user-facing pages/components
  • Added shared currency formatter utility
  • Improved loading states and UX consistency

📂 Main Files Touched

🖥 Backend

  • users.py
  • vehicles.py
  • rents.py
  • auth.py
  • users_schema.py
  • vehicles_schema.py
  • rents_schema.py
  • __init__.py

💻 Frontend

  • api.ts
  • profile.ts
  • currency.ts
  • BookingRequests.tsx
  • OwnerDashboard.tsx
  • MyVehicles.tsx
  • VehicleManage.tsx
  • UserProfile.tsx
  • UserBookings.tsx
  • VehicleDetails.tsx
  • VehicleBooking.tsx
  • CarCard.tsx
  • Navbar.tsx
  • DashboardNavbar.tsx
  • index.ts

✅ Validation

Frontend

  • npm run build (Client) – ✅ Passes

Backend

  • python3 -m compileall on updated schema/router files – ✅ Passes

📝 Notes

  • This PR includes both feature work and UI/UX improvements.
  • Existing older vehicle/rent records remain compatible via fallback/default handling where applicable.

@ChamilkaMihiraj2002 ChamilkaMihiraj2002 merged commit 0618d0b into main Feb 15, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant