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

feat/accounts #201

Draft
wants to merge 1 commit into
base: master
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
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
131 changes: 129 additions & 2 deletions app/[locale]/institute/sections/accounts/page.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,11 @@
import { WorkInProgressStatus } from '~/components/status';
import Link from 'next/link';

import { buttonVariants } from '~/components/buttons';
import Heading from '~/components/heading';
import ImageHeader from '~/components/image-header';
import { getTranslations } from '~/i18n/translations';
import { db } from '~/server/db';
import { getS3Url } from '~/server/s3';

export default async function Accounts({
params: { locale },
Expand All @@ -12,6 +17,128 @@ export default async function Accounts({
const section = (await db.query.sections.findFirst({
where: (section, { eq }) => eq(section.urlName, 'accounts'),
}))!;
const bucketUrl = getS3Url() + '/institute/sections/accounts/';
const reports = [13, 14, 15, 16, 17, 18, 19, 21];

const formLinks = [
'https://forms.gle/AA7VR28A6Co9LKLt8',
'https://forms.gle/sd9DTboMUa7TbnaaA',
'Pension-Life-Certificate-27102020.docx',
'New-Microsoft-Office-Word-Document.docx',
'LTC-performa-for-self-certification.pdf',
'Medical-reimbursement-form.pdf',
'NPS-Registration-Form.pdf',
'Nomination-form-for-NPS.pdf',
'Non-refundable-advance-GPF-form.pdf',
'PAN_Aadhaar_Updation_Form.pdf',
'Performa-for-drawl-of-advance.pdf',
'ta-bill.pdf',
'Telephone-Reimbursement.pdf',
];

const quickLinks = [
bucketUrl + 'ESS-EMP-LOGIN.pdf',
'https://smarthubeducation.hdfcbank.com/SmartFees/DirectLoadQuickPay.action?uniqueSessionIdentifier=064635166874637237960123456789&redirectionURL=',
];

return (
<>
<ImageHeader
title={text.title}
src="assets/accounts.png"
headings={[
{ label: text.about, href: '#about' },
{
label: text.reportTitle,
href: '#reports',
},
{
label: text.forms,
href: '#forms',
},
{
label: text.quickLinksTitle,
href: '#quick-links',
},
]}
/>

<article className="container" id="about">
<Heading
text={text.about}
glyphDirection="dual"
heading="h3"
href="#about"
/>
<p>{section?.aboutUs}</p>
</article>

<article className="container" id="reports">
<Heading
href="#reports"
text={text.reportTitle}
glyphDirection="ltr"
heading="h3"
/>
<ul className="list-inside list-disc">
{reports.map((year) => (
<li key={year}>
<Link
href={
bucketUrl +
`institute/sections/accounts/annual-accounts-20${year}-${Number(year) + 1}.pdf`
}
className={buttonVariants({ variant: 'link' })}
target="_blank"
>{`${text.report} ${year}-${Number(year) + 1}`}</Link>
</li>
))}
</ul>
</article>

<article className="container" id="forms">
<Heading
href="#forms"
text={text.forms}
glyphDirection="rtl"
heading="h3"
/>
<ul className="list-inside list-disc">
{formLinks.map((link, i) => (
<li key={link}>
<Link
className={buttonVariants({ variant: 'link' })}
href={link.startsWith('https') ? link : bucketUrl + link}
target="_blank"
>
{text.formsList[i]}
</Link>
</li>
))}
</ul>
</article>

return <WorkInProgressStatus locale={locale} />;
<article className="container" id="quick-links">
<Heading
text={text.quickLinksTitle}
glyphDirection="ltr"
heading="h3"
href="#quick-links"
/>
<ul className="list-inside list-disc">
{text.quickLinks.map((link, i) => (
<li key={link}>
<Link
className={buttonVariants({ variant: 'link' })}
href={quickLinks[i]}
target="_blank"
>
{link}
</Link>
</li>
))}
</ul>
</article>
</>
);
}
26 changes: 25 additions & 1 deletion i18n/en.ts
Original file line number Diff line number Diff line change
Expand Up @@ -216,7 +216,31 @@ const text: Translations = {
about: 'ABOUT',
gallery: 'GALLERY',

Account: {},
Account: {
title: 'Account Section',
about: 'About',
reportTitle: 'Annual Reports',
report: 'Annual Account',
forms: 'Forms',
formsList: [
'Bank Account Details for Vendors',
'Bank Account Details for Employees/Students/Pensioner/Ex-Student',
'Pension Life Certificate',
'Pension disbursement from IDBI Bank Kurukshetra',
'LTC performa for self certification',
'Medical reimbursement form',
'NPS Registration Form',
'Nomination form for NPS',
'Non refundable advance GPF form',
'Refundable advance from GPF Form',
'PAN_Aadhaar_Updation_Form',
'Performa for drawl of advance',
'TA Bill',
'Telephone Reimbursement',
],
quickLinksTitle: 'Quick Links',
quickLinks: ['Introduction to EMS Employee Login', 'Online Fee Payment'],
},
CentralLibrary: {},
CentralWorkshop: {},
CentreOfComputingAndNetworking: {},
Expand Down
27 changes: 26 additions & 1 deletion i18n/hi.ts
Original file line number Diff line number Diff line change
Expand Up @@ -212,7 +212,32 @@ const text: Translations = {
about: 'परिचय',
gallery: 'चित्र',

Account: {},
Account: {
title: 'लेखा खंड',
about: 'Aboutहमारी जानकारी',
reportTitle: 'वार्षिक रिपोर्ट्स',
report: 'वार्षिक खाता',
forms: 'फार्म',
formsList: [
'पेंशन जीवन प्रमाण पत्र',
'आईडीबीआई बैंक कुरुक्षेत्र से पेंशन संवितरण',
'स्व-प्रमाणन के लिए LTC प्रदर्शन',
'चिकित्सा प्रतिपूर्ति प्रपत्र',
'एनपीएस पंजीकरण फॉर्म',
'एनपीएस के लिए नामांकन फॉर्म',
'गैर-वापसी योग्य अग्रिम GPF फ़ॉर्म',
'वापसी योग्य अग्रिम GPF फ़ॉर्म',
'पैन आधार अपडेशन फॉर्म',
'अग्रिम निकासी के लिए प्रोफार्मा',
'टीए बिल',
'टेलीफोन प्रतिपूर्ति',
'विक्रेताओं के लिए बैंक खाता विवरण',
'कर्मचारियों/छात्रों/पेंशनर्स/पूर्व-छात्रों के लिए बैंक खाता विवरण',
],

quickLinksTitle: 'त्वरित लिंक',
quickLinks: ['ईएमएस कर्मचारी लॉगिन परिचय', 'ऑनलाइन शुल्क भुगतान'],
},
CentralLibrary: {},
CentralWorkshop: {},
CentreOfComputingAndNetworking: {},
Expand Down
11 changes: 10 additions & 1 deletion i18n/translations.ts
Original file line number Diff line number Diff line change
Expand Up @@ -200,7 +200,16 @@ export interface Translations {
about: string;
gallery: string;

Account: {};
Account: {
title: string;
about: string;
reportTitle: string;
report: string;
forms: string;
formsList: string[];
quickLinksTitle: string;
quickLinks: string[];
};
CentralLibrary: {};
CentralWorkshop: {};
CentreOfComputingAndNetworking: {};
Expand Down