Suvodip 2025-04-04 19:58:51 +05:30
parent 96a027dafb
commit 4b2656cea6
1 changed files with 4 additions and 4 deletions

View File

@ -28,7 +28,7 @@ interface Message {
user_type: string; user_type: string;
} }
const API_URL = 'http://localhost:2058/host-api/v1/ticket/index.php'; const API_URL = 'http://localhost:2058/host-api/app/v1/ticket/index.php';
function Ticketing() { function Ticketing() {
const [tickets, setTickets] = useState<Ticket[]>([]); const [tickets, setTickets] = useState<Ticket[]>([]);
@ -206,8 +206,8 @@ function Ticketing() {
<thead> <thead>
<tr className="bg-neutral-800 text-white"> <tr className="bg-neutral-800 text-white">
{ {
tableHeaders.map((thead) => ( tableHeaders.map((thead, index) => (
<th className={`p-2 text-center border-[1px] border-[#6d9e37]`}>{thead}</th> <th key={index} className={`p-2 text-center border-[1px] border-[#6d9e37]`}>{thead}</th>
)) ))
} }
</tr> </tr>
@ -217,7 +217,7 @@ function Ticketing() {
<tbody className="[&>tr:nth-child(even)]:bg-[#262626]"> <tbody className="[&>tr:nth-child(even)]:bg-[#262626]">
{ {
tableData.map((data, index) => ( tableData.map((data, index) => (
<tr> <tr key={index}>
<td className="px-2 border-[1px] border-[#6d9e37] font-medium">{data.id}</td> <td className="px-2 border-[1px] border-[#6d9e37] font-medium">{data.id}</td>
<td className="px-2 border-[1px] border-[#6d9e37] font-medium">{data.title}</td> <td className="px-2 border-[1px] border-[#6d9e37] font-medium">{data.title}</td>
<td className="px-2 border-[1px] border-[#6d9e37] font-medium">{data.description}</td> <td className="px-2 border-[1px] border-[#6d9e37] font-medium">{data.description}</td>