Bugs in meeting fixed
parent
56d519c874
commit
8e627e45fb
|
|
@ -9,5 +9,11 @@ export default function page() {
|
||||||
if (token) {
|
if (token) {
|
||||||
redirect("/RequestStep2");
|
redirect("/RequestStep2");
|
||||||
}
|
}
|
||||||
return <CitizenLogin />;
|
return (
|
||||||
|
<div className="flex justify-center items-center w-full h-[calc(100vh-4rem)] ">
|
||||||
|
<CitizenLogin />
|
||||||
|
|
||||||
|
<div className="w-full h-full bg-left-top bg-repeat bg-[url('/img/login-pattern.png')] absolute top-0 left-0 "></div>
|
||||||
|
</div>
|
||||||
|
);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,12 @@
|
||||||
|
import RequestStep0 from "@/components/RequestStep0";
|
||||||
|
import React from "react";
|
||||||
|
|
||||||
|
export default function page() {
|
||||||
|
return (
|
||||||
|
<div className="flex justify-center items-center w-full h-[calc(100vh-4rem)] ">
|
||||||
|
<RequestStep0 />
|
||||||
|
|
||||||
|
<div className="w-full h-full bg-left-top bg-repeat bg-[url('/img/login-pattern.png')] absolute top-0 left-0 "></div>
|
||||||
|
</div>
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
@ -130,11 +130,13 @@ export default function Landing() {
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div className="3xl:w-[60%] w-[80%] mx-auto max-md:mt-5">
|
<div className="3xl:w-[60%] w-[80%] mx-auto max-md:mt-5">
|
||||||
<div className="flex justify-between gap-6 w-full mx-auto -mt-24 max-md:mt-0 max-sm:flex-wrap max-sm:justify-around ">
|
{/* About Oyoon */}
|
||||||
|
<SubmitRequest />
|
||||||
|
<div className="flex justify-between gap-8 w-full mx-auto -mt-10 max-md:mt-2 max-sm:flex-wrap max-sm:justify-around ">
|
||||||
{boxItems.map((item, index) => {
|
{boxItems.map((item, index) => {
|
||||||
return (
|
return (
|
||||||
<Link
|
<Link
|
||||||
className="group bg-white shadow-md rounded-lg p-10 h-64 w-64 flex items-end justify-center z-10 relative
|
className="group bg-white border shadow-md rounded-lg p-10 h-64 w-1/2 flex items-end justify-center z-10 relative
|
||||||
hover:bg-blue transition-all duration-700 ease-in-out text-center
|
hover:bg-blue transition-all duration-700 ease-in-out text-center
|
||||||
hover:flex-col-reverse hover:justify-evenly hover:items-center hover:cursor-pointer
|
hover:flex-col-reverse hover:justify-evenly hover:items-center hover:cursor-pointer
|
||||||
max-lg:w-52 max-lg:h-52 max-md:w-40 max-md:h-40
|
max-lg:w-52 max-lg:h-52 max-md:w-40 max-md:h-40
|
||||||
|
|
@ -265,7 +267,6 @@ export default function Landing() {
|
||||||
{/* Counter */}
|
{/* Counter */}
|
||||||
{/* <Counter /> */}
|
{/* <Counter /> */}
|
||||||
{/*SubmitRequest */}
|
{/*SubmitRequest */}
|
||||||
<SubmitRequest />
|
|
||||||
{/* Footer */}
|
{/* Footer */}
|
||||||
<Footer />
|
<Footer />
|
||||||
</div>
|
</div>
|
||||||
|
|
|
||||||
|
|
@ -86,6 +86,11 @@
|
||||||
src: url(../fonts/iranyekanwebmediumfanum.ttf);
|
src: url(../fonts/iranyekanwebmediumfanum.ttf);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@font-face {
|
||||||
|
font-family: "yekan-eng";
|
||||||
|
src: url(../fonts/IRANYekanRegular.ttf);
|
||||||
|
}
|
||||||
|
|
||||||
.leaflet-container {
|
.leaflet-container {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
height: 100vh;
|
height: 100vh;
|
||||||
|
|
|
||||||
|
|
@ -8,35 +8,50 @@ import {
|
||||||
DialogTrigger,
|
DialogTrigger,
|
||||||
} from "@/components/ui/dialog";
|
} from "@/components/ui/dialog";
|
||||||
import { X } from "lucide-react";
|
import { X } from "lucide-react";
|
||||||
|
import { Button } from "./ui/button";
|
||||||
export default function AttachmentsDialog({
|
export default function AttachmentsDialog({
|
||||||
children,
|
children,
|
||||||
attachments,
|
attachments,
|
||||||
deleteFile,
|
deleteFile,
|
||||||
|
deleteAllAttachmentsFiles,
|
||||||
}: {
|
}: {
|
||||||
children: React.ReactNode;
|
children: React.ReactNode;
|
||||||
attachments: File[] | [];
|
attachments: File[] | [];
|
||||||
deleteFile: (file: any) => void;
|
deleteFile: (file: any) => void;
|
||||||
|
deleteAllAttachmentsFiles: () => void;
|
||||||
}) {
|
}) {
|
||||||
return (
|
return (
|
||||||
<Dialog>
|
<Dialog>
|
||||||
{children}
|
{children}
|
||||||
<DialogContent>
|
<DialogContent className=" max-h-[95vh] overflow-y-auto max-sm:p-0">
|
||||||
<DialogHeader>
|
<DialogHeader>
|
||||||
<DialogTitle>پیوستها</DialogTitle>
|
<DialogTitle className=" mt-7">پیوستها</DialogTitle>
|
||||||
<DialogDescription>
|
<DialogDescription className="max-md:px-2 py-5 w-full">
|
||||||
|
{attachments.length != 0 && (
|
||||||
|
<Button
|
||||||
|
onClick={() => deleteAllAttachmentsFiles()}
|
||||||
|
className=" mb-2 absolute right-3 top-1 p-1 bg-white hover:bg-white text-red-600 "
|
||||||
|
>
|
||||||
|
حذف همه
|
||||||
|
</Button>
|
||||||
|
)}
|
||||||
|
|
||||||
{attachments.length == 0 ? (
|
{attachments.length == 0 ? (
|
||||||
<div className=" text-center my-5">هیج پیوستی وجود ندارد.</div>
|
<div className=" text-center my-5">هیج پیوستی وجود ندارد.</div>
|
||||||
) : (
|
) : (
|
||||||
<div className=" flex flex-col gap-2 mt-2">
|
<div className=" flex flex-col gap-2 mt-2 h-full mx-2">
|
||||||
{attachments?.map((item,index) => {
|
{attachments?.map((item, index) => {
|
||||||
return (
|
return (
|
||||||
<div key={index} className=" flex gap-2 w-full items-center">
|
<div
|
||||||
|
key={index}
|
||||||
|
className=" flex gap-2 w-full items-center"
|
||||||
|
>
|
||||||
<div className=" p-2 bg-blue w-10 grid place-content-center rounded-lg text-white">
|
<div className=" p-2 bg-blue w-10 grid place-content-center rounded-lg text-white">
|
||||||
{index + 1}
|
{index + 1}
|
||||||
</div>
|
</div>
|
||||||
<div className="bg-gray-200 p-2 rounded-lg max-w-full justify-between flex flex-1">
|
<div className="bg-gray-200 p-2 rounded-lg max-w-full justify-between flex flex-1">
|
||||||
<div className="">
|
<div className="">
|
||||||
<p className=" truncate">{item.name}</p>
|
<p className=" truncate max-w-[16rem]">{item.name}</p>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<X
|
<X
|
||||||
|
|
|
||||||
|
|
@ -74,7 +74,7 @@ export default function Navbar() {
|
||||||
<Link
|
<Link
|
||||||
onClick={() => setOpen((prev) => !prev)}
|
onClick={() => setOpen((prev) => !prev)}
|
||||||
className={`flex items-center justify-between w-full p-3 rounded-xl text-white
|
className={`flex items-center justify-between w-full p-3 rounded-xl text-white
|
||||||
${lastItem === idx ? "bg-yellow" : "bg-blue"} `}
|
bg-blue `}
|
||||||
href={item.href}
|
href={item.href}
|
||||||
>
|
>
|
||||||
<span className="flex gap-1 text-sm">
|
<span className="flex gap-1 text-sm">
|
||||||
|
|
@ -107,7 +107,7 @@ export default function Navbar() {
|
||||||
<Link
|
<Link
|
||||||
onClick={() => setOpen((prev) => !prev)}
|
onClick={() => setOpen((prev) => !prev)}
|
||||||
className={`flex items-center justify-between w-full p-3 rounded-xl text-white
|
className={`flex items-center justify-between w-full p-3 rounded-xl text-white
|
||||||
${lastItem === idx ? "bg-yellow" : "bg-blue"} `}
|
bg-blue `}
|
||||||
href={item.href}
|
href={item.href}
|
||||||
>
|
>
|
||||||
<span className="flex gap-1 text-sm">
|
<span className="flex gap-1 text-sm">
|
||||||
|
|
@ -128,12 +128,12 @@ export default function Navbar() {
|
||||||
<div className=" flex items-center max-md:mr-1 gap-5">
|
<div className=" flex items-center max-md:mr-1 gap-5">
|
||||||
<Link href="/" className="">
|
<Link href="/" className="">
|
||||||
<Image
|
<Image
|
||||||
src="/img/Logo1.png"
|
src="/img/logo2.png"
|
||||||
quality={100}
|
quality={100}
|
||||||
alt="log"
|
alt="log"
|
||||||
width={500}
|
width={2000}
|
||||||
height={500}
|
height={2000}
|
||||||
className="w-28 h-12"
|
className="w-28 h-18"
|
||||||
/>
|
/>
|
||||||
</Link>
|
</Link>
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -37,7 +37,12 @@ export default function NavbarSm() {
|
||||||
sticky top-0
|
sticky top-0
|
||||||
shadow-md`}
|
shadow-md`}
|
||||||
>
|
>
|
||||||
<Hamburger toggled={isOpen} size={20} toggle={setOpen} direction="right"/>
|
<Hamburger
|
||||||
|
toggled={isOpen}
|
||||||
|
size={20}
|
||||||
|
toggle={setOpen}
|
||||||
|
direction="right"
|
||||||
|
/>
|
||||||
{auth && <ProfileDropDown />}
|
{auth && <ProfileDropDown />}
|
||||||
{/* <Link href="/Login">
|
{/* <Link href="/Login">
|
||||||
<Button className=" bg-blue hover:bg-blue/90 rounded-lg text-xs ">
|
<Button className=" bg-blue hover:bg-blue/90 rounded-lg text-xs ">
|
||||||
|
|
@ -77,7 +82,7 @@ export default function NavbarSm() {
|
||||||
<Link
|
<Link
|
||||||
onClick={() => setOpen((prev) => !prev)}
|
onClick={() => setOpen((prev) => !prev)}
|
||||||
className={`flex items-center justify-between w-full p-3 rounded-xl text-white
|
className={`flex items-center justify-between w-full p-3 rounded-xl text-white
|
||||||
${lastItem === idx ? "bg-yellow" : "bg-blue"} `}
|
bg-blue `}
|
||||||
href={item.href}
|
href={item.href}
|
||||||
>
|
>
|
||||||
<span className="flex gap-1 text-sm">{item.name}</span>
|
<span className="flex gap-1 text-sm">{item.name}</span>
|
||||||
|
|
|
||||||
|
|
@ -8,9 +8,9 @@ const PrintButton: React.FC<PrintButtonProps> = ({ handlePrint }) => {
|
||||||
return (
|
return (
|
||||||
<button
|
<button
|
||||||
onClick={handlePrint}
|
onClick={handlePrint}
|
||||||
className="w-full sm:w-fit bg-blue text-white p-2 rounded-xl text-center "
|
className="w-full min-w-[4rem] sm:w-fit bg-blue text-white p-2 rounded-xl text-center "
|
||||||
>
|
>
|
||||||
پرینت
|
چاپ
|
||||||
</button>
|
</button>
|
||||||
);
|
);
|
||||||
};
|
};
|
||||||
|
|
|
||||||
|
|
@ -72,14 +72,15 @@ export default function Result() {
|
||||||
3xl:text-base 3xl:font-bold "
|
3xl:text-base 3xl:font-bold "
|
||||||
>
|
>
|
||||||
کد پیگیری :
|
کد پیگیری :
|
||||||
<span className="text-slate-500 mx-2">{`${trackingNumber}`}</span>
|
<span className="text-slate-500 mx-2 font-bold">{`${trackingNumber}`}</span>
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
<p
|
<p
|
||||||
className="text-sm font-medium leading-6 tracking-wide text-[#7C838A] dark:text-white
|
className="text-sm font-medium leading-6 tracking-wide text-[#7C838A] dark:text-white
|
||||||
3xl:text-base 3xl:font-bold "
|
3xl:text-base 3xl:font-bold "
|
||||||
>
|
>
|
||||||
رمز عبور :<span className="text-slate-500 mx-2">{`${password}`}</span>
|
رمز عبور :
|
||||||
|
<span className="text-slate-500 mx-2 font-mono font-extrabold">{`${password}`}</span>
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
{/* <Image
|
{/* <Image
|
||||||
|
|
@ -89,7 +90,6 @@ export default function Result() {
|
||||||
/> */}
|
/> */}
|
||||||
</div>
|
</div>
|
||||||
<div className=" w-full flex flex-col justify-between items-end mt-2">
|
<div className=" w-full flex flex-col justify-between items-end mt-2">
|
||||||
|
|
||||||
<div className="hidden">
|
<div className="hidden">
|
||||||
<PrintPage
|
<PrintPage
|
||||||
contentRef={contentRef}
|
contentRef={contentRef}
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,69 @@
|
||||||
|
"use client";
|
||||||
|
import { RequestItems, boxItems } from "@/constants";
|
||||||
|
import { cn } from "@/lib/utils";
|
||||||
|
import Image from "next/image";
|
||||||
|
import Link from "next/link";
|
||||||
|
import React from "react";
|
||||||
|
|
||||||
|
export default function RequestStep0() {
|
||||||
|
return (
|
||||||
|
<div className="">
|
||||||
|
<div className="flex justify-between gap-6 w-full mx-auto -mt-10 max-md:mt-2 max-sm:flex-wrap max-sm:justify-around ">
|
||||||
|
{RequestItems.map((item, index) => {
|
||||||
|
return (
|
||||||
|
<Link
|
||||||
|
className="group bg-white border shadow-md rounded-lg p-10 h-64 w-64 flex items-end justify-center z-10 relative
|
||||||
|
hover:bg-blue transition-all duration-700 ease-in-out text-center
|
||||||
|
hover:flex-col-reverse hover:justify-evenly hover:items-center hover:cursor-pointer
|
||||||
|
max-lg:w-52 max-lg:h-52 max-md:w-40 max-md:h-40
|
||||||
|
max-lg:p-8 max-md:p-5 max-sm:p-2 hover:max-lg:p-2
|
||||||
|
max-md:shadow-[0px_0px_8px_0px_#00000040]
|
||||||
|
"
|
||||||
|
key={index}
|
||||||
|
href={item.link}
|
||||||
|
onClick={() => {
|
||||||
|
localStorage.removeItem("Sootzani_Login_State");
|
||||||
|
if (index == 0) {
|
||||||
|
localStorage.setItem("unknown", "true");
|
||||||
|
}
|
||||||
|
if (index == 1) {
|
||||||
|
localStorage.removeItemItem("unknown");
|
||||||
|
}
|
||||||
|
}}
|
||||||
|
>
|
||||||
|
<p className="text-xs text-center font-medium text-gray hidden group-hover:flex group-hover:text-white">
|
||||||
|
{item.description}
|
||||||
|
</p>
|
||||||
|
<p className=" z-10 text-base text-black group-hover:text-white max-md:text-sm">
|
||||||
|
{item.name}
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<Image
|
||||||
|
alt="icon"
|
||||||
|
src={item.icon}
|
||||||
|
width={20}
|
||||||
|
height={20}
|
||||||
|
quality={100}
|
||||||
|
key={index}
|
||||||
|
className={cn(
|
||||||
|
" w-[80%] h-[80%] absolute left-8 top-6 group-hover:hidden max-md:h-[60%] max-md:w-[60%] max-md:left-auto",
|
||||||
|
item.id == 3 && "left-2"
|
||||||
|
)}
|
||||||
|
/>
|
||||||
|
|
||||||
|
<Image
|
||||||
|
alt="icon"
|
||||||
|
src={item.icon2}
|
||||||
|
width={20}
|
||||||
|
height={20}
|
||||||
|
quality={100}
|
||||||
|
key={index}
|
||||||
|
className=" w-[45%] h-[45%] hidden group-hover:flex"
|
||||||
|
/>
|
||||||
|
</Link>
|
||||||
|
);
|
||||||
|
})}
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
@ -95,7 +95,7 @@ export default function RequestStep1() {
|
||||||
<div className="w-full h-full pt-12 sm:w-2/3 md:w-2/4 max-sm:p-8">
|
<div className="w-full h-full pt-12 sm:w-2/3 md:w-2/4 max-sm:p-8">
|
||||||
<div className="flex flex-col justify-center h-full space-y-4 md:space-y-4">
|
<div className="flex flex-col justify-center h-full space-y-4 md:space-y-4">
|
||||||
<p className="text-sm font-bold leading-tight tracking-tight md:text-base text-blue dark:text-white">
|
<p className="text-sm font-bold leading-tight tracking-tight md:text-base text-blue dark:text-white">
|
||||||
لطفا جهت ارسال درخواست فرم زیر را تکمیل نمایید.
|
فرم ثبت درخواست{" "}
|
||||||
</p>
|
</p>
|
||||||
{profileData && (
|
{profileData && (
|
||||||
<Form {...form}>
|
<Form {...form}>
|
||||||
|
|
@ -140,7 +140,6 @@ export default function RequestStep1() {
|
||||||
</FormItem>
|
</FormItem>
|
||||||
)}
|
)}
|
||||||
/>
|
/>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div className="flex justify-center w-full gap-2 mt-8 sm:justify-end">
|
<div className="flex justify-center w-full gap-2 mt-8 sm:justify-end">
|
||||||
|
|
|
||||||
|
|
@ -87,7 +87,7 @@ export default function RequestStep2() {
|
||||||
.min(1, {
|
.min(1, {
|
||||||
message: "لطفا توضیحات خود را بنویسید.",
|
message: "لطفا توضیحات خود را بنویسید.",
|
||||||
})
|
})
|
||||||
.max(1024, {
|
.max(optionsData?.maxTextLength, {
|
||||||
message: "تعداد کاراکترها بیشتر از حد مجاز میباشد.",
|
message: "تعداد کاراکترها بیشتر از حد مجاز میباشد.",
|
||||||
}),
|
}),
|
||||||
uploadFile: z
|
uploadFile: z
|
||||||
|
|
@ -188,6 +188,15 @@ export default function RequestStep2() {
|
||||||
},
|
},
|
||||||
});
|
});
|
||||||
|
|
||||||
|
function handleDescriptionChange(
|
||||||
|
event: React.ChangeEvent<HTMLTextAreaElement>
|
||||||
|
) {
|
||||||
|
const newCharCount = event.target.value.length;
|
||||||
|
// Update charCount only when the user types or removes characters
|
||||||
|
if (newCharCount <= optionsData?.maxTextLength) {
|
||||||
|
setCharCount(newCharCount);
|
||||||
|
}
|
||||||
|
}
|
||||||
// Add the useEffect hook to monitor changes in the description field
|
// Add the useEffect hook to monitor changes in the description field
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
setCharCount(form.watch("description").length);
|
setCharCount(form.watch("description").length);
|
||||||
|
|
@ -235,6 +244,11 @@ export default function RequestStep2() {
|
||||||
form.setValue("uploadFile", filtered);
|
form.setValue("uploadFile", filtered);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
const deleteAllAttachmentsFiles = () => {
|
||||||
|
setFile([]);
|
||||||
|
form.setValue("uploadFile", []);
|
||||||
|
};
|
||||||
|
|
||||||
const allowedExtensions = optionsData?.allowedExtensions;
|
const allowedExtensions = optionsData?.allowedExtensions;
|
||||||
const split = allowedExtensions?.split(",");
|
const split = allowedExtensions?.split(",");
|
||||||
const withDot = split?.map((item: string) => "." + item);
|
const withDot = split?.map((item: string) => "." + item);
|
||||||
|
|
@ -250,8 +264,11 @@ export default function RequestStep2() {
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div className="w-full h-full pt-12 sm:w-2/3 md:w-2/4 max-sm:p-8">
|
<div className="w-full h-full pt-12 sm:w-2/3 md:w-2/4 max-sm:p-8">
|
||||||
<div className="flex flex-col justify-center h-full space-y-3 md:space-y-4">
|
<div className="flex flex-col justify-center h-full space-y-3 md:space-y-3">
|
||||||
<p className="text-sm font-bold leading-tight tracking-tight md:text-base text-blue dark:text-white">
|
<span className="text-sm font-bold leading-tight tracking-tight md:text-base text-blue dark:text-white">
|
||||||
|
ارسال گزارش
|
||||||
|
</span>
|
||||||
|
<p className="text-sm font-bold leading-tight tracking-tight md:text-sm text-[#7C838A] dark:text-white">
|
||||||
لطفا جهت ارسال درخواست فرم زیر را تکمیل نمایید.
|
لطفا جهت ارسال درخواست فرم زیر را تکمیل نمایید.
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
|
|
@ -266,7 +283,7 @@ export default function RequestStep2() {
|
||||||
render={({ field }) => (
|
render={({ field }) => (
|
||||||
<FormItem>
|
<FormItem>
|
||||||
<FormLabel className="text-[#7C838A] text-sm font-medium mt-7">
|
<FormLabel className="text-[#7C838A] text-sm font-medium mt-7">
|
||||||
*موضوع گزارش
|
<span className=" text-red-500">*</span>موضوع گزارش
|
||||||
</FormLabel>
|
</FormLabel>
|
||||||
<FormControl>
|
<FormControl>
|
||||||
<Input
|
<Input
|
||||||
|
|
@ -285,7 +302,7 @@ export default function RequestStep2() {
|
||||||
render={({ field }) => (
|
render={({ field }) => (
|
||||||
<FormItem className=" w-full sm:w-[48%]">
|
<FormItem className=" w-full sm:w-[48%]">
|
||||||
<FormLabel className="text-[#7C838A] text-sm font-medium mt-7">
|
<FormLabel className="text-[#7C838A] text-sm font-medium mt-7">
|
||||||
*واحد مورد گزارش
|
<span className=" text-red-500">*</span>واحد مورد گزارش
|
||||||
</FormLabel>
|
</FormLabel>
|
||||||
<Select
|
<Select
|
||||||
onValueChange={field.onChange}
|
onValueChange={field.onChange}
|
||||||
|
|
@ -346,13 +363,28 @@ export default function RequestStep2() {
|
||||||
render={({ field }) => (
|
render={({ field }) => (
|
||||||
<FormItem>
|
<FormItem>
|
||||||
<FormLabel className="text-[#7C838A] text-sm font-medium mt-7">
|
<FormLabel className="text-[#7C838A] text-sm font-medium mt-7">
|
||||||
توضیحات ({charCount}/1024)
|
توضیحات ({charCount}/{optionsData?.maxTextLength})
|
||||||
</FormLabel>
|
</FormLabel>
|
||||||
<FormControl>
|
<FormControl>
|
||||||
<Textarea
|
<Textarea
|
||||||
placeholder=" توضیحات خود را بنویسید"
|
placeholder=" توضیحات خود را بنویسید"
|
||||||
className="mb-3 resize-none"
|
className="mb-3 resize-none"
|
||||||
{...field}
|
{...field}
|
||||||
|
onChange={(e) => {
|
||||||
|
const currentValue = e.target.value;
|
||||||
|
if (currentValue.length <= optionsData?.maxTextLength) {
|
||||||
|
field.onChange(e);
|
||||||
|
handleDescriptionChange(e);
|
||||||
|
} else {
|
||||||
|
// Truncate the value to the allowed limit
|
||||||
|
field.onChange(
|
||||||
|
currentValue.substring(
|
||||||
|
0,
|
||||||
|
optionsData?.maxTextLength
|
||||||
|
)
|
||||||
|
);
|
||||||
|
}
|
||||||
|
}}
|
||||||
/>
|
/>
|
||||||
</FormControl>
|
</FormControl>
|
||||||
<FormMessage />
|
<FormMessage />
|
||||||
|
|
@ -419,6 +451,7 @@ export default function RequestStep2() {
|
||||||
<AttachmentsDialog
|
<AttachmentsDialog
|
||||||
attachments={file}
|
attachments={file}
|
||||||
deleteFile={(item) => deleteFileFromAttachments(item)}
|
deleteFile={(item) => deleteFileFromAttachments(item)}
|
||||||
|
deleteAllAttachmentsFiles={deleteAllAttachmentsFiles}
|
||||||
>
|
>
|
||||||
<DialogTrigger className=" bg-slate-200 rounded-md h-9 text-xs flex-1 flex gap-2 items-center justify-center">
|
<DialogTrigger className=" bg-slate-200 rounded-md h-9 text-xs flex-1 flex gap-2 items-center justify-center">
|
||||||
<Eye className=" w-4 h-4" />
|
<Eye className=" w-4 h-4" />
|
||||||
|
|
@ -448,6 +481,10 @@ export default function RequestStep2() {
|
||||||
const fileArray1 = Array.from(file);
|
const fileArray1 = Array.from(file);
|
||||||
const fileArray2 = Array.from(e.target.files);
|
const fileArray2 = Array.from(e.target.files);
|
||||||
const mergedArray = fileArray1.concat(fileArray2);
|
const mergedArray = fileArray1.concat(fileArray2);
|
||||||
|
const newMergedArray = mergedArray.filter(
|
||||||
|
(item, index) =>
|
||||||
|
mergedArray.indexOf(item) === index
|
||||||
|
);
|
||||||
setFile(mergedArray);
|
setFile(mergedArray);
|
||||||
field.onChange(mergedArray);
|
field.onChange(mergedArray);
|
||||||
} else if (!file && e.target.files) {
|
} else if (!file && e.target.files) {
|
||||||
|
|
@ -484,7 +521,7 @@ export default function RequestStep2() {
|
||||||
render={({ field }) => (
|
render={({ field }) => (
|
||||||
<FormItem className="w-1/2 ">
|
<FormItem className="w-1/2 ">
|
||||||
<FormLabel className="text-[#7C838A] text-sm font-medium mt-7">
|
<FormLabel className="text-[#7C838A] text-sm font-medium mt-7">
|
||||||
*کد امنیتی
|
<span className=" text-red-500">*</span>کد امنیتی
|
||||||
</FormLabel>
|
</FormLabel>
|
||||||
<FormControl>
|
<FormControl>
|
||||||
<Input
|
<Input
|
||||||
|
|
|
||||||
|
|
@ -9,7 +9,7 @@ import { IoArrowDown } from "react-icons/io5";
|
||||||
|
|
||||||
export default function SubmitRequest() {
|
export default function SubmitRequest() {
|
||||||
return (
|
return (
|
||||||
<div className="3xl:w-[60%] w-[80%] mx-auto pb-24">
|
<div className=" mx-auto pb-24">
|
||||||
<div className=" border my-6 mx-auto py-3 px-4 rounded-lg">
|
<div className=" border my-6 mx-auto py-3 px-4 rounded-lg">
|
||||||
<p className="text-sm font-normal text-right text-black">
|
<p className="text-sm font-normal text-right text-black">
|
||||||
درباره سامانه عیون
|
درباره سامانه عیون
|
||||||
|
|
@ -25,6 +25,9 @@ export default function SubmitRequest() {
|
||||||
</p>
|
</p>
|
||||||
<Link
|
<Link
|
||||||
href="/RequestStep2"
|
href="/RequestStep2"
|
||||||
|
onClick={() => {
|
||||||
|
localStorage.setItem("unknown", "true");
|
||||||
|
}}
|
||||||
className="text-sm font-bold text-blue text-left underline underline-offset-4"
|
className="text-sm font-bold text-blue text-left underline underline-offset-4"
|
||||||
>
|
>
|
||||||
برای شروع ارسال درخواست کلیک کنید.
|
برای شروع ارسال درخواست کلیک کنید.
|
||||||
|
|
|
||||||
|
|
@ -26,21 +26,21 @@ export const sliderItems = [
|
||||||
];
|
];
|
||||||
|
|
||||||
export const boxItems = [
|
export const boxItems = [
|
||||||
{
|
// {
|
||||||
id: 1,
|
// id: 1,
|
||||||
name: " گزارش فساد (ناشناس)",
|
// name: " گزارش فساد (ناشناس)",
|
||||||
icon: "/img/box1.svg",
|
// icon: "/img/box1.svg",
|
||||||
icon2: "/img/box1-hover.svg",
|
// icon2: "/img/box1-hover.svg",
|
||||||
description: "ارسال گزارش بدون احراز هویت",
|
// description: "ارسال گزارش بدون احراز هویت",
|
||||||
link: "/RequestStep2",
|
// link: "/RequestStep2",
|
||||||
},
|
// },
|
||||||
{
|
{
|
||||||
id: 2,
|
id: 2,
|
||||||
name: " گزارش فساد",
|
name: " گزارش فساد",
|
||||||
icon: "/img/box1.svg",
|
icon: "/img/box1.svg",
|
||||||
icon2: "/img/box1-hover.svg",
|
icon2: "/img/box1-hover.svg",
|
||||||
description: "ارسال گزارش با احراز هویت",
|
description: "ارسال گزارش با احراز هویت",
|
||||||
link: "/CitizenLogin",
|
link: "/RequestStep0",
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
id: 3,
|
id: 3,
|
||||||
|
|
@ -50,14 +50,25 @@ export const boxItems = [
|
||||||
description: "پیگیری درخواست ارسال شده",
|
description: "پیگیری درخواست ارسال شده",
|
||||||
link: "/FollowUp",
|
link: "/FollowUp",
|
||||||
},
|
},
|
||||||
// {
|
];
|
||||||
// id: 3,
|
|
||||||
// name: "مشاهده آمار",
|
export const RequestItems = [
|
||||||
// icon: "/img/box3.svg",
|
{
|
||||||
// icon2: "/img/box3-hover.svg",
|
id: 1,
|
||||||
// description: "مشاهده آمار و گزارشات درخواست ها",
|
name: " گزارش فساد (ناشناس)",
|
||||||
// link: "/",
|
icon: "/img/box5.svg",
|
||||||
// },
|
icon2: "/img/box5-hover.svg",
|
||||||
|
description: "ارسال گزارش بدون احراز هویت",
|
||||||
|
link: "/RequestStep2",
|
||||||
|
},
|
||||||
|
{
|
||||||
|
id: 2,
|
||||||
|
name: " گزارش فساد (شناس)",
|
||||||
|
icon: "/img/box4-hover.svg",
|
||||||
|
icon2: "/img/box4.svg",
|
||||||
|
description: "ارسال گزارش با احراز هویت",
|
||||||
|
link: "/CitizenLogin",
|
||||||
|
},
|
||||||
];
|
];
|
||||||
|
|
||||||
export const newsItems = [
|
export const newsItems = [
|
||||||
|
|
|
||||||
Binary file not shown.
|
|
@ -0,0 +1,7 @@
|
||||||
|
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
|
||||||
|
<!-- Uploaded to: SVG Repo, www.svgrepo.com, Transformed by: SVG Repo Mixer Tools -->
|
||||||
|
<svg fill="#c7c6c6" version="1.1" id="Capa_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="800px" height="800px" viewBox="0 0 442.04 442.04" xml:space="preserve">
|
||||||
|
<g id="SVGRepo_bgCarrier" stroke-width="0"/>
|
||||||
|
<g id="SVGRepo_tracerCarrier" stroke-linecap="round" stroke-linejoin="round"/>
|
||||||
|
<g id="SVGRepo_iconCarrier"> <g> <g> <path d="M221.02,341.304c-49.708,0-103.206-19.44-154.71-56.22C27.808,257.59,4.044,230.351,3.051,229.203 c-4.068-4.697-4.068-11.669,0-16.367c0.993-1.146,24.756-28.387,63.259-55.881c51.505-36.777,105.003-56.219,154.71-56.219 c49.708,0,103.207,19.441,154.71,56.219c38.502,27.494,62.266,54.734,63.259,55.881c4.068,4.697,4.068,11.669,0,16.367 c-0.993,1.146-24.756,28.387-63.259,55.881C324.227,321.863,270.729,341.304,221.02,341.304z M29.638,221.021 c9.61,9.799,27.747,27.03,51.694,44.071c32.83,23.361,83.714,51.212,139.688,51.212s106.859-27.851,139.688-51.212 c23.944-17.038,42.082-34.271,51.694-44.071c-9.609-9.799-27.747-27.03-51.694-44.071 c-32.829-23.362-83.714-51.212-139.688-51.212s-106.858,27.85-139.688,51.212C57.388,193.988,39.25,211.219,29.638,221.021z"/> </g> <g> <path d="M221.02,298.521c-42.734,0-77.5-34.767-77.5-77.5c0-42.733,34.766-77.5,77.5-77.5c18.794,0,36.924,6.814,51.048,19.188 c5.193,4.549,5.715,12.446,1.166,17.639c-4.549,5.193-12.447,5.714-17.639,1.166c-9.564-8.379-21.844-12.993-34.576-12.993 c-28.949,0-52.5,23.552-52.5,52.5s23.551,52.5,52.5,52.5c28.95,0,52.5-23.552,52.5-52.5c0-6.903,5.597-12.5,12.5-12.5 s12.5,5.597,12.5,12.5C298.521,263.754,263.754,298.521,221.02,298.521z"/> </g> <g> <path d="M221.02,246.021c-13.785,0-25-11.215-25-25s11.215-25,25-25c13.786,0,25,11.215,25,25S234.806,246.021,221.02,246.021z"/> </g> </g> </g>
|
||||||
|
</svg>
|
||||||
|
After Width: | Height: | Size: 1.9 KiB |
|
|
@ -0,0 +1,27 @@
|
||||||
|
<?xml version="1.0" encoding="iso-8859-1"?>
|
||||||
|
<!-- Uploaded to: SVG Repo, www.svgrepo.com, Generator: SVG Repo Mixer Tools -->
|
||||||
|
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
|
||||||
|
<svg fill="#fff" version="1.1" id="Capa_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"
|
||||||
|
width="800px" height="800px" viewBox="0 0 442.04 442.04"
|
||||||
|
xml:space="preserve">
|
||||||
|
<g>
|
||||||
|
<g>
|
||||||
|
<path d="M221.02,341.304c-49.708,0-103.206-19.44-154.71-56.22C27.808,257.59,4.044,230.351,3.051,229.203
|
||||||
|
c-4.068-4.697-4.068-11.669,0-16.367c0.993-1.146,24.756-28.387,63.259-55.881c51.505-36.777,105.003-56.219,154.71-56.219
|
||||||
|
c49.708,0,103.207,19.441,154.71,56.219c38.502,27.494,62.266,54.734,63.259,55.881c4.068,4.697,4.068,11.669,0,16.367
|
||||||
|
c-0.993,1.146-24.756,28.387-63.259,55.881C324.227,321.863,270.729,341.304,221.02,341.304z M29.638,221.021
|
||||||
|
c9.61,9.799,27.747,27.03,51.694,44.071c32.83,23.361,83.714,51.212,139.688,51.212s106.859-27.851,139.688-51.212
|
||||||
|
c23.944-17.038,42.082-34.271,51.694-44.071c-9.609-9.799-27.747-27.03-51.694-44.071
|
||||||
|
c-32.829-23.362-83.714-51.212-139.688-51.212s-106.858,27.85-139.688,51.212C57.388,193.988,39.25,211.219,29.638,221.021z"/>
|
||||||
|
</g>
|
||||||
|
<g>
|
||||||
|
<path d="M221.02,298.521c-42.734,0-77.5-34.767-77.5-77.5c0-42.733,34.766-77.5,77.5-77.5c18.794,0,36.924,6.814,51.048,19.188
|
||||||
|
c5.193,4.549,5.715,12.446,1.166,17.639c-4.549,5.193-12.447,5.714-17.639,1.166c-9.564-8.379-21.844-12.993-34.576-12.993
|
||||||
|
c-28.949,0-52.5,23.552-52.5,52.5s23.551,52.5,52.5,52.5c28.95,0,52.5-23.552,52.5-52.5c0-6.903,5.597-12.5,12.5-12.5
|
||||||
|
s12.5,5.597,12.5,12.5C298.521,263.754,263.754,298.521,221.02,298.521z"/>
|
||||||
|
</g>
|
||||||
|
<g>
|
||||||
|
<path d="M221.02,246.021c-13.785,0-25-11.215-25-25s11.215-25,25-25c13.786,0,25,11.215,25,25S234.806,246.021,221.02,246.021z"/>
|
||||||
|
</g>
|
||||||
|
</g>
|
||||||
|
</svg>
|
||||||
|
After Width: | Height: | Size: 1.8 KiB |
|
|
@ -0,0 +1,4 @@
|
||||||
|
<?xml version="1.0" encoding="utf-8"?><!-- Uploaded to: SVG Repo, www.svgrepo.com, Generator: SVG Repo Mixer Tools -->
|
||||||
|
<svg width="800px" height="800px" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
|
||||||
|
<path d="M2.21967 2.21967C1.9534 2.48594 1.9292 2.9026 2.14705 3.19621L2.21967 3.28033L6.25424 7.3149C4.33225 8.66437 2.89577 10.6799 2.29888 13.0644C2.1983 13.4662 2.4425 13.8735 2.84431 13.9741C3.24613 14.0746 3.6534 13.8305 3.75399 13.4286C4.28346 11.3135 5.59112 9.53947 7.33416 8.39452L9.14379 10.2043C8.43628 10.9258 8 11.9143 8 13.0046C8 15.2138 9.79086 17.0046 12 17.0046C13.0904 17.0046 14.0788 16.5683 14.8004 15.8608L20.7197 21.7803C21.0126 22.0732 21.4874 22.0732 21.7803 21.7803C22.0466 21.5141 22.0708 21.0974 21.8529 20.8038L21.7803 20.7197L15.6668 14.6055L15.668 14.604L14.4679 13.4061L11.598 10.5368L11.6 10.536L8.71877 7.65782L8.72 7.656L7.58672 6.52549L3.28033 2.21967C2.98744 1.92678 2.51256 1.92678 2.21967 2.21967ZM10.2041 11.2655L13.7392 14.8006C13.2892 15.2364 12.6759 15.5046 12 15.5046C10.6193 15.5046 9.5 14.3853 9.5 13.0046C9.5 12.3287 9.76824 11.7154 10.2041 11.2655ZM12 5.5C10.9997 5.5 10.0291 5.64807 9.11109 5.925L10.3481 7.16119C10.8839 7.05532 11.4364 7 12 7C15.9231 7 19.3099 9.68026 20.2471 13.4332C20.3475 13.835 20.7546 14.0794 21.1565 13.9791C21.5584 13.8787 21.8028 13.4716 21.7024 13.0697C20.5994 8.65272 16.6155 5.5 12 5.5ZM12.1947 9.00928L15.996 12.81C15.8942 10.7531 14.2472 9.10764 12.1947 9.00928Z" fill="#fff"/>
|
||||||
|
</svg>
|
||||||
|
After Width: | Height: | Size: 1.5 KiB |
|
|
@ -0,0 +1,7 @@
|
||||||
|
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
|
||||||
|
<!-- Uploaded to: SVG Repo, www.svgrepo.com, Transformed by: SVG Repo Mixer Tools -->
|
||||||
|
<svg width="800px" height="800px" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
|
||||||
|
<g id="SVGRepo_bgCarrier" stroke-width="0"/>
|
||||||
|
<g id="SVGRepo_tracerCarrier" stroke-linecap="round" stroke-linejoin="round"/>
|
||||||
|
<g id="SVGRepo_iconCarrier"> <path d="M2.21967 2.21967C1.9534 2.48594 1.9292 2.9026 2.14705 3.19621L2.21967 3.28033L6.25424 7.3149C4.33225 8.66437 2.89577 10.6799 2.29888 13.0644C2.1983 13.4662 2.4425 13.8735 2.84431 13.9741C3.24613 14.0746 3.6534 13.8305 3.75399 13.4286C4.28346 11.3135 5.59112 9.53947 7.33416 8.39452L9.14379 10.2043C8.43628 10.9258 8 11.9143 8 13.0046C8 15.2138 9.79086 17.0046 12 17.0046C13.0904 17.0046 14.0788 16.5683 14.8004 15.8608L20.7197 21.7803C21.0126 22.0732 21.4874 22.0732 21.7803 21.7803C22.0466 21.5141 22.0708 21.0974 21.8529 20.8038L21.7803 20.7197L15.6668 14.6055L15.668 14.604L14.4679 13.4061L11.598 10.5368L11.6 10.536L8.71877 7.65782L8.72 7.656L7.58672 6.52549L3.28033 2.21967C2.98744 1.92678 2.51256 1.92678 2.21967 2.21967ZM10.2041 11.2655L13.7392 14.8006C13.2892 15.2364 12.6759 15.5046 12 15.5046C10.6193 15.5046 9.5 14.3853 9.5 13.0046C9.5 12.3287 9.76824 11.7154 10.2041 11.2655ZM12 5.5C10.9997 5.5 10.0291 5.64807 9.11109 5.925L10.3481 7.16119C10.8839 7.05532 11.4364 7 12 7C15.9231 7 19.3099 9.68026 20.2471 13.4332C20.3475 13.835 20.7546 14.0794 21.1565 13.9791C21.5584 13.8787 21.8028 13.4716 21.7024 13.0697C20.5994 8.65272 16.6155 5.5 12 5.5ZM12.1947 9.00928L15.996 12.81C15.8942 10.7531 14.2472 9.10764 12.1947 9.00928Z" fill="#c7c6c6"/> </g>
|
||||||
|
</svg>
|
||||||
|
After Width: | Height: | Size: 1.7 KiB |
Binary file not shown.
|
After Width: | Height: | Size: 34 KiB |
Loading…
Reference in New Issue