request list + structure

This commit is contained in:
hamid zarghami
2025-10-20 12:28:48 +03:30
commit dbe37e371e
89 changed files with 9547 additions and 0 deletions
+102
View File
@@ -0,0 +1,102 @@
import Filters from '@/components/Filters'
import Table from '@/components/Table'
import { type FC } from 'react'
const RequestList: FC = () => {
return (
<div className='mt-5'>
<h1 className='text-lg font-light'>درخواست ها</h1>
<div className='mt-8'>
<Filters
fields={[
{
name: 'search',
type: 'input',
placeholder: 'جستجو',
},
{
name: 'status',
type: 'select',
placeholder: 'وضعیت',
options: [
{
label: 'درحال انتظار',
value: 'pending',
},
],
},
{
name: 'date',
type: 'date',
placeholder: 'تاریخ',
}
]}
onChange={() => { }}
/>
</div>
<div className='mt-8'>
<Table
columns={[
{
key: 'id',
title: 'شماره',
},
{
key: 'customer',
title: 'مشتری',
},
{
key: 'creationDate',
title: 'تاریخ ایجاد درخواست',
},
{
key: 'lastApprovalDate',
title: 'آخرین مهلت تایید',
},
{
key: 'itemCount',
title: 'تعداد اقلام',
},
{
key: 'status',
title: 'وضعیت',
render: (item) => {
return (
<div className='h-6 w-fit flex items-center bg-[#FFEDCA] text-[#FF7B00] rounded-full px-2.5 text-xs'>
{item.status}
</div>
)
}
},
{
key: 'actions',
title: '',
},
]}
data={[
{
id: 1,
customer: 'مشتری 1',
creationDate: '2024-01-01',
lastApprovalDate: '2024-01-01',
itemCount: 10,
status: 'درحال انتظار',
},
{
id: 2,
customer: 'مشتری 2',
creationDate: '2024-01-01',
lastApprovalDate: '2024-01-01',
itemCount: 10,
status: 'تایید شده',
},
]}
/>
</div>
</div>
)
}
export default RequestList