Ealanisln / ready-set

On-demand courier that specializes in delivery for all your needs. We are Food Safety, and HIPPA Certified. Our team can meet all your Bay Area delivery needs.
https://readysetllc.com
MIT License
0 stars 0 forks source link

New driver added does not appear on the "Edit driver asignment" whenever I try to assign it to a new order. #4

Closed fersanz-87 closed 1 month ago

fersanz-87 commented 1 month ago

I recently added a new driver called Mario Conde. After this, I tried to assign him to a new order but on the "Edit driver asignment" list does not appear available. I uploaded two screenshots showing this issue on the web page.

Screenshot 2024-09-23 at 1 06 51 PM Screenshot 2024-09-23 at 1 09 04 PM
Ealanisln commented 1 month ago

Solution:

  1. Removed the disabled prop from PaginationPrevious and PaginationNext components.

  2. Implemented a CSS-based approach to visually disable the pagination buttons:

    • Added a className prop to PaginationPrevious and PaginationNext.
    • Used "pointer-events-none opacity-50" classes to disable the buttons visually when at the first or last page.
  3. Updated the relevant code sections:

<PaginationPrevious
  onClick={() => handlePageChange(Math.max(1, currentPage - 1))}
  className={currentPage === 1 ? "pointer-events-none opacity-50" : ""}
/>

// ... (similar change for PaginationNext)

Can you double check if the issue was fixed?