"use client"; import { useState } from "react"; import Button from "@mui/material/Button"; import { t } from "i18next"; import { Card, Modal, Typography } from "@mui/material"; import TimesheetInputGrid from "./TimesheetInputGrid"; import { BASE_API_URL } from "@/config/api"; // import { fetchTimesheets } from "@/app/api/timesheets"; interface EnterTimesheetModalProps { isOpen: boolean; onClose: () => void; modalStyle?: any; } const EnterTimesheetModal: React.FC = ({ ...props }) => { const [lockConfirm, setLockConfirm] = useState(false); const columns = [ { id: "projectCode", field: "projectCode", headerName: "Project Code and Name", flex: 1, }, { id: "task", field: "task", headerName: "Task", flex: 1, }, ]; const rows = [ { id: 1, projectCode: "M1001", task: "1.2", }, { id: 2, projectCode: "M1301", task: "1.1", }, ]; const fetchTimesheet = async () => { // fetchTimesheets(); // const res = await fetch(`http://localhost:8090/api/timesheets`, { // // const res = await fetch(`${BASE_API_URL}/timesheets`, { // method: "GET", // mode: 'no-cors', // }); // console.log(res.json); }; return (
{/*
Timesheet Input
*/}
); }; export default EnterTimesheetModal;