diff --git a/apps/cms/package.json b/apps/cms/package.json index b3284bce..1585d165 100644 --- a/apps/cms/package.json +++ b/apps/cms/package.json @@ -21,10 +21,13 @@ "dependencies": { "@aws-sdk/client-s3": "^3.262.0", "@aws-sdk/lib-storage": "^3.535.0", + "@payloadcms/bundler-webpack": "^1.0.7", + "@payloadcms/db-mongodb": "^1.7.2", "@payloadcms/plugin-cloud-storage": "~1.0.19", + "@payloadcms/richtext-slate": "^1.5.2", "dotenv": "^8.2.0", "express": "^4.19.2", - "payload": "^1.8.3", + "payload": "^2.27.0", "querystring-es3": "^0.2.1", "react": "^18.0.0", "tsconfig": "*" diff --git a/apps/cms/src/admin/views/MerchOverview.tsx b/apps/cms/src/admin/views/MerchOverview.tsx index f29b952e..1554edb2 100644 --- a/apps/cms/src/admin/views/MerchOverview.tsx +++ b/apps/cms/src/admin/views/MerchOverview.tsx @@ -1,10 +1,10 @@ import React, { useEffect, useState, ChangeEvent } from "react"; import { Button } from "payload/components/elements"; -import { AdminView } from "payload/config"; +import { AdminViewComponent } from "payload/config"; import ViewTemplate from "./ViewTemplate"; import StoreApi from "../../apis/store.api"; -const MerchOverview: AdminView = ({ user, canAccessAdmin }) => { +const MerchOverview: AdminViewComponent = ({ user, canAccessAdmin }) => { const [displayText, setDisplayText] = useState( "We are currently preparing for the next merch sale. Please look forward to our email!" ); diff --git a/apps/cms/src/admin/views/MerchProducts.tsx b/apps/cms/src/admin/views/MerchProducts.tsx index f9dfea9a..abc5ad09 100644 --- a/apps/cms/src/admin/views/MerchProducts.tsx +++ b/apps/cms/src/admin/views/MerchProducts.tsx @@ -1,6 +1,6 @@ import React, { useEffect, useState } from "react"; import { Button } from "payload/components/elements"; -import { AdminView } from "payload/config"; +import { AdminViewComponent } from "payload/config"; import ViewTemplate from "./ViewTemplate"; import { Column } from "payload/dist/admin/components/elements/Table/types"; import { RenderCellFactory } from "../utils/RenderCellFactory"; @@ -9,7 +9,7 @@ import { Table } from "payload/dist/admin/components/elements/Table"; import { Product } from "types"; import ProductsApi from "../../apis/products.api"; -const MerchProducts: AdminView = ({ user, canAccessAdmin }) => { +const MerchProducts: AdminViewComponent = ({ user, canAccessAdmin }) => { // Get data from API const [data, setData] = useState(null); useEffect(() => { diff --git a/apps/cms/src/admin/views/MerchPromotion.tsx b/apps/cms/src/admin/views/MerchPromotion.tsx index 8c5ef3f6..11ff14bb 100644 --- a/apps/cms/src/admin/views/MerchPromotion.tsx +++ b/apps/cms/src/admin/views/MerchPromotion.tsx @@ -1,6 +1,6 @@ import React, { useEffect, useState } from "react"; import { Button } from "payload/components/elements"; -import { AdminView } from "payload/config"; +import { AdminViewComponent } from "payload/config"; import ViewTemplate from "./ViewTemplate"; import { Column } from "payload/dist/admin/components/elements/Table/types"; import { RenderCellFactory } from "../utils/RenderCellFactory"; @@ -10,7 +10,7 @@ import { Promotion } from "types"; import PromotionsApi from "../../apis/promotions.api"; import './MerchPromotion.scss'; -const MerchPromotion: AdminView = ({ user, canAccessAdmin }) => { +const MerchPromotion: AdminViewComponent = ({ user, canAccessAdmin }) => { // Get data from API const [data, setData] = useState(null); useEffect(() => { @@ -112,7 +112,7 @@ const MerchPromotion: AdminView = ({ user, canAccessAdmin }) => { keywords="" title="Merchandise Promotion" > - +