Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Payment details for admin #23

Merged
merged 36 commits into from
Oct 2, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
36 commits
Select commit Hold shift + click to select a range
720b64c
Refactor user API route to include pagination and search functionality
Vyshnav001 Oct 1, 2024
9be2bb7
Refactor searchable infinite scroll table component to include pagina…
Vyshnav001 Oct 1, 2024
cae0c99
Refactor searchable infinite scroll table component to include pagina…
Vyshnav001 Oct 1, 2024
4c4d4ed
Refactor package.json to add email dev script and update dependencies
Vyshnav001 Oct 2, 2024
5208592
Refactor email-template.tsx to add email verification functionality
Vyshnav001 Oct 2, 2024
8904e52
Refactor email-template.tsx to add TEDxSJEC Talk registration confirm…
Vyshnav001 Oct 2, 2024
191ce7b
Refactor create-order route to use razorpay library for order creation
Vyshnav001 Oct 2, 2024
f256be5
create api route to verify the order
Vyshnav001 Oct 2, 2024
6072a6a
Add API route to verify order
Vyshnav001 Oct 2, 2024
d342eb7
Refactor HorizontalScrollCarousel component to use TEDxSJEC team data…
Vyshnav001 Oct 2, 2024
13e16c0
Refactor email-template.tsx to remove unused code and update styling
Vyshnav001 Oct 2, 2024
56b1284
Add razorpay.ts to integrate Razorpay payment gateway
Vyshnav001 Oct 2, 2024
1605513
Refactor resend-mailer.ts to use updated EmailTemplate path and remov…
Vyshnav001 Oct 2, 2024
ec361db
Refactor send-registration-email.ts and sendMail.tsx to update email …
Vyshnav001 Oct 2, 2024
29ab34b
Refactor utils.ts to update cn function and add tedxsjecAssetsPrefix …
Vyshnav001 Oct 2, 2024
81040a9
Update package dependencies
Vyshnav001 Oct 2, 2024
328f7cd
Refactor Payment table schema to update column names and constraints
Vyshnav001 Oct 2, 2024
a7f5af2
add admin page to verify the payment
Vyshnav001 Oct 2, 2024
25540de
verify using id
Vyshnav001 Oct 2, 2024
f153e81
Refactor API URL in admin verification page
Vyshnav001 Oct 2, 2024
de0a2f6
feat : send the email after success full registration
Vyshnav001 Oct 2, 2024
37f315d
Refactor authorization check in verify-order route
Vyshnav001 Oct 2, 2024
6436277
Refactor admin navbar to add a "Verify" option
Vyshnav001 Oct 2, 2024
14a8046
Merge branch 'main' of https://github.com/TEDx-SJEC/website into paym…
Vyshnav001 Oct 2, 2024
9333e88
Fix npm install command to force installation of dependencies
Vyshnav001 Oct 2, 2024
792c98f
Update package dependencies
Vyshnav001 Oct 2, 2024
98b17ee
Refactor npm install command to remove the --force flag
Vyshnav001 Oct 2, 2024
441b20b
Refactor QR code scanner to use @yudiel/react-qr-scanner
Vyshnav001 Oct 2, 2024
eb97d38
add route for razorpay
Vyshnav001 Oct 2, 2024
ae2a4ca
to validate the payment using id
Vyshnav001 Oct 2, 2024
79ffa1e
feat : to send the email to the user incase they didn't recive the email
Vyshnav001 Oct 2, 2024
51d7ce4
feat: Add route for sending email to user if they didn't receive the …
Vyshnav001 Oct 2, 2024
4e979a0
Refactor generatedSignature function to be exported for external use
Vyshnav001 Oct 2, 2024
1bf2b46
Refactor generatedSignature import in send-email route
Vyshnav001 Oct 2, 2024
7bca670
Refactor generatedSignature import and export in send-email route
Vyshnav001 Oct 2, 2024
c3bdaec
add generateSignature function
Vyshnav001 Oct 2, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
File renamed without changes.
88 changes: 88 additions & 0 deletions emails/user-registration-email-template.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,88 @@
import { tedxsjecAssetsPrefix } from "@/lib/utils";
import {
Body,
Button,
Container,
Head,
Heading,
Hr,
Html,
Img,
Preview,
Section,
Text,
} from "@react-email/components";
import { Tailwind } from "@react-email/tailwind";

interface TedxRegistrationEmailProps {
name?: string;
registrationLink: string;
}

export const TedxRegistrationEmail = ({ name, registrationLink }: TedxRegistrationEmailProps) => {
const previewText = `TEDxSJEC Talk Registration Successful!`;

return (
<Html>
<Head />
<Preview>{previewText}</Preview>
<Tailwind>
<Body className="bg-white my-auto mx-auto font-sans px-4">
<Container className="border border-solid border-[#eaeaea] rounded my-[40px] mx-auto p-[20px] max-w-[465px]">
{/* Logo Section */}
<Section className="text-center">
<Img
src={`${tedxsjecAssetsPrefix}/logo/tedxsjec-logo.avif`} // Add the logo image URL here
alt="TEDxSJEC Logo"
className="mx-auto w-[150px] h-auto mb-[20px]"
/>
</Section>
{/* Heading Section */}
<Section className="mt-[32px] items-center">
<Heading className="text-black text-[24px] font-bold text-center p-0 my-[30px] mx-0">
<strong>TEDxSJEC Talk Registration Confirmed!</strong>
</Heading>
</Section>
<Text className="text-black text-[14px] leading-[24px]">
Dear {name ?? "Participant"},
</Text>
<Text className="text-black text-[14px] leading-[24px]">
We are excited to confirm your registration for TEDxSJEC Talk. <br />
You are all set to join us for an inspiring day filled with ideas worth sharing.
Please bring this email on the event day for a smooth entry process.
</Text>
{/* QR Code Section */}
<Section className="text-center mt-[32px] mb-[32px]">
<Text className="text-center">
Below is your unique QR code for registration. Kindly keep it accessible on
event day for quick check-in:
</Text>
<Img
className="mx-auto flex items-center justify-center py-4"
src={`https://api.qrserver.com/v1/create-qr-code/?size=200x200&data=${registrationLink}`}
alt="QR Code"
/>
</Section>
<Text className="text-black text-[14px] leading-[24px]">
We look forward to seeing you at TEDxSJEC! <br />
</Text>
<Hr className="border border-solid border-[#eaeaea] my-[26px] mx-0 w-full" />
<Text className="text-[#666666] text-[12px] leading-[24px]">
Thanks & Regards, <br /> TEDxSJEC Team <br />
For any queries, feel free to contact us at: [email protected]
</Text>
<div className="flex flex-col items-center justify-center text-[12px] space-x-4">
<Button href="https://tedxsjec.in/privacy">Privacy Policy</Button>
&nbsp;|&nbsp;
<Button href="https://tedxsjec.in/refund">Refund Policy</Button>
&nbsp;|&nbsp;
<Button href="https://tedxsjec.in/terms">Terms and Conditions</Button>
</div>
</Container>
</Body>
</Tailwind>
</Html>
);
};

export default TedxRegistrationEmail;
Loading
Loading