trithuc-mvc-react 3.4.3 → 3.4.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -3,7 +3,7 @@ import { useEffect, useMemo, useState } from "react";
3
3
  import TablePaginationCustom from "../table/TablePagination";
4
4
 
5
5
  import { useConfirm } from "material-ui-confirm";
6
- import { useMutation, useQuery, useQueryClient } from "react-query";
6
+ import { useMutation, useQuery, useQueryClient } from "@tanstack/react-query";
7
7
  import { toast } from "react-toastify";
8
8
  import { changeStatusDataToTable, deleteDataFromTable, deleteMultipleDataFromTable, getDatasFromTable } from "../../api";
9
9
  import TableRowsLoader from "../table/TableRowsLoader";
@@ -1,11 +1,26 @@
1
- import { Grid, Table, TableBody, TableCell, TableContainer, TableRow, Typography, useMediaQuery, useTheme } from "@mui/material";
1
+ import {
2
+ Grid,
3
+ Table,
4
+ TableBody,
5
+ TableCell,
6
+ TableContainer,
7
+ TableRow,
8
+ Typography,
9
+ useMediaQuery,
10
+ useTheme
11
+ } from "@mui/material";
2
12
  import { useEffect, useMemo, useState } from "react";
3
13
  import TablePaginationCustom from "../table/TablePagination";
4
14
 
5
15
  import { useConfirm } from "material-ui-confirm";
6
- import { useMutation, useQuery, useQueryClient } from "react-query";
16
+ import { useMutation, useQuery, useQueryClient } from "@tanstack/react-query";
7
17
  import { toast } from "react-toastify";
8
- import { changeStatusDataToTable, deleteDataFromTable, deleteMultipleDataFromTable, getDatasFromTable } from "../../api";
18
+ import {
19
+ changeStatusDataToTable,
20
+ deleteDataFromTable,
21
+ deleteMultipleDataFromTable,
22
+ getDatasFromTable
23
+ } from "../../api";
9
24
  import TableRowsLoader from "../table/TableRowsLoader";
10
25
 
11
26
  import { URL_APPLICATION_API } from "@/constants";
@@ -409,7 +424,12 @@ const DataTableSM = ({ multipleActions = [], page, setPage = () => {}, disableEd
409
424
  />
410
425
  </Grid>
411
426
  </Grid>
412
- <DeleteConfirmationDialog open={openDialog} onClose={handleDialogClose} onConfirm={handleDialogClose} id={deleteId} />
427
+ <DeleteConfirmationDialog
428
+ open={openDialog}
429
+ onClose={handleDialogClose}
430
+ onConfirm={handleDialogClose}
431
+ id={deleteId}
432
+ />
413
433
  <DeleteMultipleConfirmationDialog
414
434
  open={openDeleteMultipleDialog}
415
435
  onClose={handleDeleteMultipleDialogClose}
@@ -8,7 +8,7 @@ import { useEffect } from "react";
8
8
 
9
9
  import { URL_APPLICATION, URL_APPLICATION_API } from "@/constants";
10
10
  import { yupResolver } from "@hookform/resolvers/yup";
11
- import { useMutation, useQueryClient } from "react-query";
11
+ import { useMutation, useQueryClient } from "@tanstack/react-query";
12
12
  import { toast } from "react-toastify";
13
13
  import { saveDataToTable } from "../../api";
14
14
  import FormField from "./FormField";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "trithuc-mvc-react",
3
- "version": "3.4.3",
3
+ "version": "3.4.4",
4
4
  "main": "index.js",
5
5
  "scripts": {
6
6
  "test": "echo \"Error: no test specified\" && exit 1"
@@ -17,6 +17,7 @@
17
17
  "@emotion/styled": "^11.14.0",
18
18
  "@hookform/resolvers": "^5.0.1",
19
19
  "@iconify/react": "^5.2.1",
20
+ "@tanstack/react-query": "^5.90.12",
20
21
  "axios": "^1.8.4",
21
22
  "date-fns": "^4.1.0",
22
23
  "lodash": "^4.17.21",
@@ -47,7 +48,6 @@
47
48
  "react": ">=16",
48
49
  "react-dom": ">=16",
49
50
  "react-hook-form": "^7.55.0",
50
- "react-query": "^3.39.3",
51
51
  "react-toastify": "^11.0.5"
52
52
  }
53
53
  }