+16
-12
@@ -32,18 +32,22 @@ const ProductList: FC = () => {
|
||||
<div className='flex justify-between items-center'>
|
||||
<h1 className='text-lg font-light'>محصولات</h1>
|
||||
|
||||
<Link
|
||||
to={Paths.product.create}
|
||||
>
|
||||
<Button
|
||||
className='w-fit px-6'
|
||||
>
|
||||
<div className='flex gap-1.5'>
|
||||
<AddSquare size={18} color='black' />
|
||||
<div className='text-[13px] font-light'>محصول جدید</div>
|
||||
</div>
|
||||
</Button>
|
||||
</Link>
|
||||
<div className='flex gap-3'>
|
||||
<Link to={Paths.product.category.list}>
|
||||
<Button className='w-fit px-6'>
|
||||
<div className='text-[13px] font-light'>دستهبندیها</div>
|
||||
</Button>
|
||||
</Link>
|
||||
|
||||
<Link to={Paths.product.create}>
|
||||
<Button className='w-fit px-6'>
|
||||
<div className='flex gap-1.5'>
|
||||
<AddSquare size={18} color='black' />
|
||||
<div className='text-[13px] font-light'>محصول جدید</div>
|
||||
</div>
|
||||
</Button>
|
||||
</Link>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div className='mt-8'>
|
||||
|
||||
@@ -3,7 +3,8 @@ import { useDeleteCategory, useGetCategory } from '../hooks/useProductData'
|
||||
import Table from '@/components/Table'
|
||||
import type { ColumnType, RowDataType } from '@/components/types/TableTypes'
|
||||
import type { CategoryType } from '../types/Types'
|
||||
import { Edit } from 'iconsax-react'
|
||||
import Button from '@/components/Button'
|
||||
import { AddSquare, Edit } from 'iconsax-react'
|
||||
import TrashWithConfrim from '@/components/TrashWithConfrim'
|
||||
import { toast } from 'react-toastify'
|
||||
import { extractErrorMessage } from '@/config/func'
|
||||
@@ -80,12 +81,25 @@ const CategoryList: FC = () => {
|
||||
|
||||
return (
|
||||
<div className='mt-5'>
|
||||
<h1 className='text-lg font-light'>دسته بندی محصولات</h1>
|
||||
<div className='flex justify-between items-center'>
|
||||
<h1 className='text-lg font-light'>دسته بندی محصولات</h1>
|
||||
|
||||
<Link to={Paths.product.category.create}>
|
||||
<Button className='w-fit px-6'>
|
||||
<div className='flex gap-1.5'>
|
||||
<AddSquare size={18} color='black' />
|
||||
<div className='text-[13px] font-light'>دستهبندی جدید</div>
|
||||
</div>
|
||||
</Button>
|
||||
</Link>
|
||||
</div>
|
||||
|
||||
<div className='mt-8'>
|
||||
<Table<CategoryType & RowDataType>
|
||||
columns={column}
|
||||
data={data?.data || [] as (CategoryType & RowDataType)[]}
|
||||
/>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user