fixed minor issues
This commit is contained in:
@@ -21,7 +21,7 @@ export type NavData = z.infer<typeof navDataSchema>;
|
|||||||
|
|
||||||
export const NAV_DATA: NavData = [
|
export const NAV_DATA: NavData = [
|
||||||
{
|
{
|
||||||
label: "MAIN MENU",
|
label: "",
|
||||||
items: [
|
items: [
|
||||||
{
|
{
|
||||||
title: "Dashboard",
|
title: "Dashboard",
|
||||||
|
|||||||
@@ -1,6 +1,7 @@
|
|||||||
"use client";
|
"use client";
|
||||||
|
|
||||||
import { ExclamationIcon } from "@/assets/icons";
|
import { ExclamationIcon } from "@/assets/icons";
|
||||||
|
import { ShowcaseSection } from "@/components/Layouts/showcase-section";
|
||||||
import {
|
import {
|
||||||
Table,
|
Table,
|
||||||
TableBody,
|
TableBody,
|
||||||
@@ -9,10 +10,10 @@ import {
|
|||||||
TableHeader,
|
TableHeader,
|
||||||
} from "@/components/ui/table";
|
} from "@/components/ui/table";
|
||||||
import TableSkeleton from "@/components/ui/TableSkeleton";
|
import TableSkeleton from "@/components/ui/TableSkeleton";
|
||||||
|
import { cn } from "@/lib/utils";
|
||||||
import { unixToDate } from "@/utils/shared";
|
import { unixToDate } from "@/utils/shared";
|
||||||
import { TableRow } from "../../../ui/table";
|
import { TableRow } from "../../../ui/table";
|
||||||
import useTenderFeedbackPresenter from "./useTenderFeedbackPresenter";
|
import useTenderFeedbackPresenter from "./useTenderFeedbackPresenter";
|
||||||
import { cn } from "@/lib/utils";
|
|
||||||
|
|
||||||
interface IProps {
|
interface IProps {
|
||||||
id: string;
|
id: string;
|
||||||
@@ -22,7 +23,10 @@ const TenderFeedbackTable = ({ id }: IProps) => {
|
|||||||
const { feedback, isLoading, columns, pathName, router } =
|
const { feedback, isLoading, columns, pathName, router } =
|
||||||
useTenderFeedbackPresenter({ id });
|
useTenderFeedbackPresenter({ id });
|
||||||
return (
|
return (
|
||||||
<div className="flex flex-col rounded-[10px] bg-white px-7.5 pb-4 pt-7.5 shadow-1 dark:bg-gray-dark dark:shadow-card">
|
<ShowcaseSection
|
||||||
|
title={!isLoading && `Tender: ${feedback?.[0].tender?.title}`}
|
||||||
|
className="flex flex-col rounded-[10px] bg-white px-7.5 pb-4 pt-7.5 shadow-1 dark:bg-gray-dark dark:shadow-card"
|
||||||
|
>
|
||||||
<Table>
|
<Table>
|
||||||
<TableHeader>
|
<TableHeader>
|
||||||
<TableRow>
|
<TableRow>
|
||||||
@@ -52,9 +56,7 @@ const TenderFeedbackTable = ({ id }: IProps) => {
|
|||||||
<TableCell className="uppercase" colSpan={100}>
|
<TableCell className="uppercase" colSpan={100}>
|
||||||
{unixToDate(item.updated_at)}
|
{unixToDate(item.updated_at)}
|
||||||
</TableCell>
|
</TableCell>
|
||||||
<TableCell className="uppercase" colSpan={100}>
|
|
||||||
{item?.tender?.title ?? "-"}
|
|
||||||
</TableCell>
|
|
||||||
<TableCell className="uppercase" colSpan={100}>
|
<TableCell className="uppercase" colSpan={100}>
|
||||||
{unixToDate(item.created_at)}
|
{unixToDate(item.created_at)}
|
||||||
</TableCell>
|
</TableCell>
|
||||||
@@ -76,7 +78,7 @@ const TenderFeedbackTable = ({ id }: IProps) => {
|
|||||||
)}
|
)}
|
||||||
</TableBody>
|
</TableBody>
|
||||||
</Table>
|
</Table>
|
||||||
</div>
|
</ShowcaseSection>
|
||||||
);
|
);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|||||||
@@ -10,7 +10,7 @@ const useTenderFeedbackPresenter = ({ id }: { id: string }) => {
|
|||||||
"row",
|
"row",
|
||||||
"feedback type",
|
"feedback type",
|
||||||
"updated at",
|
"updated at",
|
||||||
"tender name",
|
|
||||||
"created at",
|
"created at",
|
||||||
"actions",
|
"actions",
|
||||||
];
|
];
|
||||||
|
|||||||
+1
-1
@@ -1,6 +1,6 @@
|
|||||||
import * as moment from "moment";
|
import * as moment from "moment";
|
||||||
export const unixToDate = (unix: number) => {
|
export const unixToDate = (unix: number) => {
|
||||||
return moment.unix(unix).format("YYYY/MM/DD");
|
return moment.unix(unix).format("YYYY/MM/DD HH:MM");
|
||||||
};
|
};
|
||||||
export const msToDate = (ms: number) => {
|
export const msToDate = (ms: number) => {
|
||||||
return moment.default(ms).format("YYYY/MM/DD");
|
return moment.default(ms).format("YYYY/MM/DD");
|
||||||
|
|||||||
Reference in New Issue
Block a user