diff --git a/src/components/collections/PmGridCollection.jsx b/src/components/collections/PmGridCollection.jsx index d6767e9c..6d7738ca 100644 --- a/src/components/collections/PmGridCollection.jsx +++ b/src/components/collections/PmGridCollection.jsx @@ -6,12 +6,18 @@ import { CollectionRepository } from "../../repositories/ColllectionRepository"; const PmGridCollection = ({ selectedProject, fromDate, toDate, isPending }) => { const columns = [ - { key: "invoiceNumber", title: "Invoice Number", className: "text-start" }, + { + key: "invoiceNumber", + title: "Invoice Number", + className: "text-start", + groupable: true, + }, { key: "title", title: "Title", sortable: true, className: "text-start" }, { key: "clientSubmitedDate", title: "Submission Date", className: "text-start", + groupable: true, }, { key: "exceptedPaymentDate", @@ -23,7 +29,6 @@ const PmGridCollection = ({ selectedProject, fromDate, toDate, isPending }) => { { key: "isActive", title: "Status" }, ]; - // --- SERVER SIDE FETCHER (correct) --- const fetcher = async ({ page, pageSize, search }) => { const response = await CollectionRepository.getCollections( selectedProject, @@ -87,6 +92,14 @@ const PmGridCollection = ({ selectedProject, fromDate, toDate, isPending }) => { pinning: true, resizing: true, selection: false, + reorder: true, + columnVisibility: true, + pageSizeSelector: true, + // groupByKey: "clientSubmitedDate", + aggregation: true, + pinning: true, + IsNumbering: true, + grouping: true, }} /> ); diff --git a/src/services/pmsGrid/PmsGrid.jsx b/src/services/pmsGrid/PmsGrid.jsx index a28fe118..8f5c1adf 100644 --- a/src/services/pmsGrid/PmsGrid.jsx +++ b/src/services/pmsGrid/PmsGrid.jsx @@ -38,6 +38,8 @@ export default function PmsGrid({ pageSize, setPage, setPageSize, + setGroupBy +, search, setSearch, selected, @@ -248,7 +250,12 @@ export default function PmsGrid({ className="bg-light-secondary border p-2 bg-light rounded" style={{ position: "sticky", top: 0, zIndex: 10 }} > -