diff --git a/src/component/mymedia/MyMedia.js b/src/component/mymedia/MyMedia.js index a86d5f1..34cf520 100644 --- a/src/component/mymedia/MyMedia.js +++ b/src/component/mymedia/MyMedia.js @@ -15,7 +15,7 @@ export default function MyMedia() { const [selectedFile, setSelectedFile] = useState(null); const [message, setMessage] = useState(''); const [imageLink, setImageLink] = useState('') -console.log('imageLink', imageLink) + console.log('imageLink', imageLink) // Function to handle file selection const handleFileChange = (event) => { setSelectedFile(event.target.files[0]); @@ -62,7 +62,7 @@ console.log('imageLink', imageLink) const uploadFileMutation = useMutation({ mutationFn: (fields) => { - if(!fields.file){ + if (!fields.file) { throw({message: 'Please select a file first!'}) } return uploadFile(fields) @@ -80,7 +80,7 @@ console.log('imageLink', imageLink) }) }, onSettled: () => { - setTimeout(()=>{ + setTimeout(() => { uploadFileMutation.reset() }, 3000) } @@ -141,7 +141,8 @@ console.log('imageLink', imageLink)
@@ -169,48 +170,52 @@ console.log('imageLink', imageLink) - {isFetching ? + {isFetching ? <>

Loading...

: isError ? -
-

{error?.message}

-
- : -
- {mediaFileList && mediaFileList?.file_list && mediaFileList?.file_list.map((item, index) => { - const file_url = (mediaFileList?.media_server + "/" + item?.file_group + "/" + item?.file_uid + "/" + item.filename).toLowerCase(); - const avtarImage = - item?.file_type === undefined - ? "icons/01.png" - : "icons/" + item.file_type + ".png"; - return (
-
setImageLink(file_url)} style={{cursor: 'pointer'}}> - {`${item.file_type}`}/ -
-

{item.filename}

+
+

{error?.message}

+
+ : +
+ {mediaFileList && mediaFileList?.file_list && mediaFileList?.file_list.map((item, index) => { + const file_url = (mediaFileList?.media_server + "/" + item?.file_group + "/" + item?.file_uid + "/" + item.filename).toLowerCase(); + const avtarImage = + item?.file_type === undefined + ? "icons/01.png" + : "icons/" + item.file_type + ".png"; + return (
+
setImageLink(file_url)} style={{cursor: 'pointer'}}> + {`${item.file_type}`}/ +
+

{item.filename}

+
+ +
- - -
-
) - }) - } -
+
) + }) + } +
}
@@ -221,17 +226,18 @@ console.log('imageLink', imageLink)

Preview

-
+
{imageLink && - file-image + file-image }
{imageLink && - <> -

0 x 0 px

-

size: 0 bytes

- + <> +

0 x 0 px

+

size: 0 bytes

+ }
diff --git a/src/component/reports/PaymentReportTable.jsx b/src/component/reports/PaymentReportTable.jsx index 9b12b11..8ca29ba 100644 --- a/src/component/reports/PaymentReportTable.jsx +++ b/src/component/reports/PaymentReportTable.jsx @@ -1,6 +1,6 @@ -import React, { useState } from "react"; -import { useQuery } from "@tanstack/react-query"; -import { getPaymentReports } from "../../services/services"; +import React, {useState} from "react"; +import {useQuery} from "@tanstack/react-query"; +import {getPaymentReports} from "../../services/services"; import queryKeys from "../../services/queryKeys"; export default function PaymentReportTable() { @@ -21,182 +21,63 @@ export default function PaymentReportTable() { console.log('DATA', data?.data) return ( - <> -
-
-
-
-

Payments Report

-
-
-
-
-
- {isFetching ? - <> -
-

Loading...

-
- - : isError ? -
-

{error?.message}

-
- : -
-
-
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NamePositionOfficeAgeStart dateSalary
Tiger NixonSystem ArchitectEdinburgh612011/04/25$320,800
Garrett WintersAccountantTokyo632011/07/25$170,750
Ashton CoxJunior Technical AuthorSan Francisco662009/01/12$86,000
Cedric KellySenior Javascript DeveloperEdinburgh222012/03/29$433,060
Airi SatouAccountantTokyo332008/11/28$162,700
Brielle WilliamsonIntegration SpecialistNew York612012/12/02$372,000
Herrod ChandlerSales AssistantSan Francisco592012/08/06$137,500
Rhona DavidsonIntegration SpecialistTokyo552010/10/14$327,900
Colleen HurstJavascript DeveloperSan Francisco392009/09/15$205,500
Sonya FrostSoftware EngineerEdinburgh232008/12/13$103,600
Jena GainesOffice ManagerLondon302008/12/19$90,560
Quinn FlynnSupport LeadEdinburgh222013/03/03$342,000
Charde MarshallRegional DirectorSan Francisco362008/10/16$470,600
Haley KennedySenior Marketing DesignerLondon432012/12/18$313,500
Tatyana FitzpatrickRegional DirectorLondon192010/03/17$385,750
Michael SilvaMarketing DesignerLondon662012/11/27$198,500
+ <> +
+
+
+
+

Payments Report

- } -
- +
+ {isFetching ? + <> +
+

Loading...

+
+ + : isError ? +
+

{error?.message}

+
+ : +
+
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
AddedNameAmountStatus
Sat, 30 Aug 2025 06:18:31 GMTSTATRTER001 $5.991
Sat, 30 Aug 2025 06:18:31 GMTSTATRTER001 $5.991
+
+
+
+
+ } +
+ ) } \ No newline at end of file diff --git a/src/component/reports/ProductReportTable.jsx b/src/component/reports/ProductReportTable.jsx index 38058f1..a9a5c98 100644 --- a/src/component/reports/ProductReportTable.jsx +++ b/src/component/reports/ProductReportTable.jsx @@ -1,6 +1,6 @@ -import React, { useState } from "react"; -import { useQuery } from "@tanstack/react-query"; -import { getProductReports } from "../../services/services"; +import React, {useState} from "react"; +import {useQuery} from "@tanstack/react-query"; +import {getProductReports} from "../../services/services"; import queryKeys from "../../services/queryKeys"; export default function ProductReportTable() { @@ -22,184 +22,68 @@ export default function ProductReportTable() { console.log('DATA', data?.data) return ( - <> + <> -
-
-
-
-

Products Report

-
-
-
-
- -
- {isFetching ? - <> -
-

Loading...

-
- - : isError ? -
-

{error?.message}

-
- : -
-
-
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NamePositionOfficeAgeStart dateSalary
Tiger NixonSystem ArchitectEdinburgh612011/04/25$320,800
Garrett WintersAccountantTokyo632011/07/25$170,750
Ashton CoxJunior Technical AuthorSan Francisco662009/01/12$86,000
Cedric KellySenior Javascript DeveloperEdinburgh222012/03/29$433,060
Airi SatouAccountantTokyo332008/11/28$162,700
Brielle WilliamsonIntegration SpecialistNew York612012/12/02$372,000
Herrod ChandlerSales AssistantSan Francisco592012/08/06$137,500
Rhona DavidsonIntegration SpecialistTokyo552010/10/14$327,900
Colleen HurstJavascript DeveloperSan Francisco392009/09/15$205,500
Sonya FrostSoftware EngineerEdinburgh232008/12/13$103,600
Jena GainesOffice ManagerLondon302008/12/19$90,560
Quinn FlynnSupport LeadEdinburgh222013/03/03$342,000
Charde MarshallRegional DirectorSan Francisco362008/10/16$470,600
Haley KennedySenior Marketing DesignerLondon432012/12/18$313,500
Tatyana FitzpatrickRegional DirectorLondon192010/03/17$385,750
Michael SilvaMarketing DesignerLondon662012/11/27$198,500
-
+
+
+
+
+

Products Report

- } -
- +
+ +
+ {isFetching ? + <> +
+

Loading...

+
+ + : isError ? +
+

{error?.message}

+
+ : +
+
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + +
IDAddedNameStatus
A000002Sun, 13 Jul 2025 15:02:57 GMTName for - A0000017
A000002Sun, 13 Jul 2025 15:02:57 GMTName for - A0000017
+
+
+
+
+ } +
+ ) } \ No newline at end of file diff --git a/src/component/reports/SystemReportTable.jsx b/src/component/reports/SystemReportTable.jsx index 3bbcd94..e9b14c5 100644 --- a/src/component/reports/SystemReportTable.jsx +++ b/src/component/reports/SystemReportTable.jsx @@ -1,6 +1,6 @@ -import React, { useState } from "react"; -import { useQuery } from "@tanstack/react-query"; -import { getSystemReports } from "../../services/services"; +import React, {useState} from "react"; +import {useQuery} from "@tanstack/react-query"; +import {getSystemReports} from "../../services/services"; import queryKeys from "../../services/queryKeys"; export default function SystemReportTable() { @@ -22,184 +22,64 @@ export default function SystemReportTable() { console.log('DATA', data?.data) return ( - <> + <> -
-
-
-
-

Systems Report

-
-
-
-
- -
- {isFetching ? - <> -
-

Loading...

-
- - : isError ? -
-

{error?.message}

-
- : -
-
-
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NamePositionOfficeAgeStart dateSalary
Tiger NixonSystem ArchitectEdinburgh612011/04/25$320,800
Garrett WintersAccountantTokyo632011/07/25$170,750
Ashton CoxJunior Technical AuthorSan Francisco662009/01/12$86,000
Cedric KellySenior Javascript DeveloperEdinburgh222012/03/29$433,060
Airi SatouAccountantTokyo332008/11/28$162,700
Brielle WilliamsonIntegration SpecialistNew York612012/12/02$372,000
Herrod ChandlerSales AssistantSan Francisco592012/08/06$137,500
Rhona DavidsonIntegration SpecialistTokyo552010/10/14$327,900
Colleen HurstJavascript DeveloperSan Francisco392009/09/15$205,500
Sonya FrostSoftware EngineerEdinburgh232008/12/13$103,600
Jena GainesOffice ManagerLondon302008/12/19$90,560
Quinn FlynnSupport LeadEdinburgh222013/03/03$342,000
Charde MarshallRegional DirectorSan Francisco362008/10/16$470,600
Haley KennedySenior Marketing DesignerLondon432012/12/18$313,500
Tatyana FitzpatrickRegional DirectorLondon192010/03/17$385,750
Michael SilvaMarketing DesignerLondon662012/11/27$198,500
-
+
+
+
+
+

Systems Report

- } -
- +
+ +
+ {isFetching ? + <> +
+

Loading...

+
+ + : isError ? +
+

{error?.message}

+
+ : +
+
+
+
+ + + + + + + + + + + + + + + + + + + + + + + +
AddedAction NameDescriptionUpdated
Sun, 15 Feb 2026 10:52:01 GMTSystems Status ChecksprocessingSun, 15 Feb 2026 09:26:02 GMT
Sun, 15 Feb 2026 10:52:01 GMTSystems Status ChecksprocessingSun, 15 Feb 2026 09:26:02 GMT
+
+
+
+
+ } +
+ ) } \ No newline at end of file