diff --git a/.github/workflows/e2e.yml b/.github/workflows/e2e.yml
index 04500210..1c9e9151 100644
--- a/.github/workflows/e2e.yml
+++ b/.github/workflows/e2e.yml
@@ -12,7 +12,13 @@ jobs:
GOOGLE_API_CREDENTIALS: "{}"
# GOOGLE_API_CREDENTIALS: ${{ secrets.CI_GOOGLE_API_CREDENTIALS }}
# CRON_API_KEY: xxx
- # CALENDSO_ENCRYPTION_KEY: xxx
+ CALENDSO_ENCRYPTION_KEY: ${{ secrets.CI_CALENDSO_ENCRYPTION_KEY }}
+ NEXT_PUBLIC_STRIPE_PUBLIC_KEY: ${{ secrets.CI_NEXT_PUBLIC_STRIPE_PUBLIC_KEY }}
+ STRIPE_PRIVATE_KEY: ${{ secrets.CI_STRIPE_PRIVATE_KEY }}
+ STRIPE_CLIENT_ID: ${{ secrets.CI_STRIPE_CLIENT_ID }}
+ STRIPE_WEBHOOK_SECRET: ${{ secrets.CI_STRIPE_WEBHOOK_SECRET }}
+ PAYMENT_FEE_PERCENTAGE: 0.005
+ PAYMENT_FEE_FIXED: 10
# NEXTAUTH_URL: xxx
# EMAIL_FROM: xxx
# EMAIL_SERVER_HOST: xxx
@@ -61,8 +67,6 @@ jobs:
- run: yarn db-seed
- run: yarn test
- run: yarn build
- - run: yarn start &
- - run: npx wait-port 3000 --timeout 10000
- name: Cache playwright binaries
uses: actions/cache@v2
diff --git a/.gitignore b/.gitignore
index 15f20eea..055a53d1 100644
--- a/.gitignore
+++ b/.gitignore
@@ -37,6 +37,7 @@ yarn-error.log*
.env.development.local
.env.test.local
.env.production.local
+.env.*
# vercel
.vercel
diff --git a/components/booking/BookingListItem.tsx b/components/booking/BookingListItem.tsx
index 3f218396..63df6f8a 100644
--- a/components/booking/BookingListItem.tsx
+++ b/components/booking/BookingListItem.tsx
@@ -9,7 +9,7 @@ import { inferQueryOutput, trpc } from "@lib/trpc";
import TableActions, { ActionType } from "@components/ui/TableActions";
-type BookingItem = inferQueryOutput<"viewer.bookings">[number];
+type BookingItem = inferQueryOutput<"viewer.bookings">["bookings"][number];
function BookingListItem(booking: BookingItem) {
const { t, i18n } = useLocale();
@@ -73,20 +73,17 @@ function BookingListItem(booking: BookingItem) {
const startTime = dayjs(booking.startTime).format(isUpcoming ? "ddd, D MMM" : "D MMMM YYYY");
return (
-
{startTime}
{dayjs(booking.startTime).format("HH:mm")} - {dayjs(booking.endTime).format("HH:mm")}
|
-
+ |
- {!booking.confirmed && !booking.rejected && (
-
- {t("unconfirmed")}
-
- )}
+ {!booking.confirmed && !booking.rejected && {t("unconfirmed")}}
+ {!!booking?.eventType?.price && !booking.paid && Pending payment}
{startTime}:{" "}
@@ -94,13 +91,14 @@ function BookingListItem(booking: BookingItem) {
-
+
{booking.eventType?.team && {booking.eventType.team.name}: }
{booking.title}
+ {!!booking?.eventType?.price && !booking.paid && (
+ Pending payment
+ )}
{!booking.confirmed && !booking.rejected && (
-
- {t("unconfirmed")}
-
+ {t("unconfirmed")}
)}
{booking.description && (
@@ -130,4 +128,13 @@ function BookingListItem(booking: BookingItem) {
);
}
+const Tag = ({ children, className = "" }: React.PropsWithChildren<{ className?: string }>) => {
+ return (
+
+ {children}
+
+ );
+};
+
export default BookingListItem;
diff --git a/components/integrations/CalendarListContainer.tsx b/components/integrations/CalendarListContainer.tsx
index 0dbc4802..23e7579a 100644
--- a/components/integrations/CalendarListContainer.tsx
+++ b/components/integrations/CalendarListContainer.tsx
@@ -115,7 +115,7 @@ function ConnectedCalendarsList(props: Props) {
(
- |