mirror of
https://github.com/i701/sarlink-portal.git
synced 2025-07-29 18:00:22 +00:00
feat(verify-user): add link to view user agreement and improve layout for user information
Some checks are pending
Build and Push Docker Images / Build and Push Docker Images (push) Has started running
Some checks are pending
Build and Push Docker Images / Build and Push Docker Images (push) Has started running
This commit is contained in:
@ -1,4 +1,4 @@
|
|||||||
import { FileTextIcon, PencilIcon } from "lucide-react";
|
import { EyeIcon, FileTextIcon, PencilIcon } from "lucide-react";
|
||||||
import Image from "next/image";
|
import Image from "next/image";
|
||||||
import Link from "next/link";
|
import Link from "next/link";
|
||||||
import { redirect } from "next/navigation";
|
import { redirect } from "next/navigation";
|
||||||
@ -41,10 +41,10 @@ export default async function VerifyUserPage({
|
|||||||
|
|
||||||
return (
|
return (
|
||||||
<div>
|
<div>
|
||||||
<div className="flex items-center justify-between text-gray-500 text-2xl font-bold title-bg py-4 px-2 mb-4">
|
<div className="flex flex-wrap gap-2 items-center justify-between text-gray-500 text-2xl font-bold title-bg py-4 px-2 mb-4">
|
||||||
<h3 className="text-sarLinkOrange text-2xl">User Information</h3>
|
<h3 className="text-sarLinkOrange text-2xl">User Information</h3>
|
||||||
|
|
||||||
<div className="flex gap-2">
|
<div className="flex flex-wrap gap-2">
|
||||||
{dbUser && !dbUser?.verified && <UserVerifyDialog user={dbUser} />}
|
{dbUser && !dbUser?.verified && <UserVerifyDialog user={dbUser} />}
|
||||||
{dbUser && !dbUser?.verified && <UserRejectDialog user={dbUser} />}
|
{dbUser && !dbUser?.verified && <UserRejectDialog user={dbUser} />}
|
||||||
<Link href={'update'}>
|
<Link href={'update'}>
|
||||||
@ -59,6 +59,12 @@ export default async function VerifyUserPage({
|
|||||||
Update Agreement
|
Update Agreement
|
||||||
</Button>
|
</Button>
|
||||||
</Link>
|
</Link>
|
||||||
|
<Link href={dbUser?.agreement || "#"} target="_blank" rel="noopener noreferrer">
|
||||||
|
<Button className="hover:cursor-pointer">
|
||||||
|
<EyeIcon />
|
||||||
|
View Agreement
|
||||||
|
</Button>
|
||||||
|
</Link>
|
||||||
{dbUser?.verified && (
|
{dbUser?.verified && (
|
||||||
<Badge variant={"secondary"} className="bg-lime-500">
|
<Badge variant={"secondary"} className="bg-lime-500">
|
||||||
Verified
|
Verified
|
||||||
|
@ -45,6 +45,7 @@ export interface UserProfile {
|
|||||||
address: string;
|
address: string;
|
||||||
acc_no: string;
|
acc_no: string;
|
||||||
id_card: string;
|
id_card: string;
|
||||||
|
agreement: string;
|
||||||
}
|
}
|
||||||
|
|
||||||
export interface Session {
|
export interface Session {
|
||||||
|
Reference in New Issue
Block a user