Compare commits
2 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 01c1c62bf0 | |||
| db4ecdd55b |
@@ -6,7 +6,8 @@ import BreadcrumbCom from '../breadcrumb/BreadcrumbCom'
|
|||||||
import TablePaginatedWrapper from '../tableWrapper/TablePaginatedWrapper'
|
import TablePaginatedWrapper from '../tableWrapper/TablePaginatedWrapper'
|
||||||
import Icons from '../Icons'
|
import Icons from '../Icons'
|
||||||
import { getUsers } from '../../services/siteServices'
|
import { getUsers } from '../../services/siteServices'
|
||||||
import formatNumber from '../../helpers/formatNumber'
|
import getDateTimeFromDateString from '../../helpers/getDateTimeFromDateString'
|
||||||
|
// import formatNumber from '../../helpers/formatNumber'
|
||||||
// import getDateTimeFromDateString from '../../helpers/getDateTimeFromDateString';
|
// import getDateTimeFromDateString from '../../helpers/getDateTimeFromDateString';
|
||||||
// import formatNumber from '../../helpers/formatNumber'
|
// import formatNumber from '../../helpers/formatNumber'
|
||||||
// import Avatar from '../../assets/user_avatar.jpg'
|
// import Avatar from '../../assets/user_avatar.jpg'
|
||||||
@@ -47,9 +48,9 @@ export default function UsersAdmin() {
|
|||||||
},
|
},
|
||||||
staleTime: 0 //0 mins
|
staleTime: 0 //0 mins
|
||||||
})
|
})
|
||||||
const usersData = data?.data?.payments // BILLINGS LIST
|
const usersData = data?.data?.office_users // USERS LIST
|
||||||
const pagination = data?.data?.pagination
|
const pagination = data?.data?.pagination
|
||||||
// console.log('DATA', data?.data)
|
console.log('DATA', data?.data)
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div className='w-full flex flex-col gap-8'>
|
<div className='w-full flex flex-col gap-8'>
|
||||||
@@ -83,25 +84,22 @@ export default function UsersAdmin() {
|
|||||||
<thead className="py-2 text-sm text-slate-500 text-left">
|
<thead className="py-2 text-sm text-slate-500 text-left">
|
||||||
<tr>
|
<tr>
|
||||||
<th scope="col" className="px-2 py-2">
|
<th scope="col" className="px-2 py-2">
|
||||||
Name
|
ID
|
||||||
</th>
|
</th>
|
||||||
<th scope="col" className="px-2 text-right">
|
<th scope="col" className="px-2">
|
||||||
Interest Rate
|
Added
|
||||||
</th>
|
</th>
|
||||||
<th scope="col" className="px-2 text-right">
|
<th scope="col" className="px-2">
|
||||||
Insurance Rate
|
Firstnane
|
||||||
</th>
|
</th>
|
||||||
<th scope="col" className="px-2 text-right">
|
<th scope="col" className="px-2">
|
||||||
Mgt. Rate
|
Lastname
|
||||||
</th>
|
</th>
|
||||||
<th scope="col" className="px-2 text-right">
|
<th scope="col" className="px-2">
|
||||||
Max/Min Amount
|
Username
|
||||||
</th>
|
</th>
|
||||||
<th scope="col" className="px-2 text-right">
|
<th scope="col" className="px-2">
|
||||||
Tenor
|
Acct. Level
|
||||||
</th>
|
|
||||||
<th scope="col" className="px-2 text-right">
|
|
||||||
Action
|
|
||||||
</th>
|
</th>
|
||||||
</tr>
|
</tr>
|
||||||
</thead>
|
</thead>
|
||||||
@@ -109,52 +107,40 @@ export default function UsersAdmin() {
|
|||||||
{(data && data.length > 0) ? data?.map((item, index) => (
|
{(data && data.length > 0) ? data?.map((item, index) => (
|
||||||
<tr key={index} className="py-2 border-t border-dashed border-slate-300">
|
<tr key={index} className="py-2 border-t border-dashed border-slate-300">
|
||||||
<td className="px-2 py-2">
|
<td className="px-2 py-2">
|
||||||
<div className='w-full min-w-48 flex items-center gap-2 whitespace-nowrap'>
|
<div className="text-left">
|
||||||
{/* <img className="w-10 h-10 rounded-md" src={Avatar} alt="Jese" /> */}
|
<div className="text-base font-semibold">{item?.id}</div>
|
||||||
<div className="text-left">
|
</div>
|
||||||
<div className="text-base font-semibold">{item?.product_id || ''}</div>
|
|
||||||
{/* <div className="font-normal text-gray-500 line-clamp-1">{item?.description}</div> */}
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</td>
|
</td>
|
||||||
<td className="px-2">
|
<td className="px-2">
|
||||||
<div className="text-right">
|
<div className="">
|
||||||
<div className="font-normal text-gray-500">{formatNumber(item?.interest_rate)}</div>
|
<div className="text-base font-semibold">{getDateTimeFromDateString(item?.added)}</div>
|
||||||
</div>
|
</div>
|
||||||
</td>
|
</td>
|
||||||
<td className="px-2">
|
<td className="px-2">
|
||||||
<div className="text-right">
|
<div className="text-left">
|
||||||
<div className="font-normal text-gray-500">{formatNumber(item?.insurance_rate)}</div>
|
<div className="text-base font-semibold">{item?.firstname}</div>
|
||||||
</div>
|
</div>
|
||||||
</td>
|
</td>
|
||||||
<td className="px-2">
|
<td className="px-2">
|
||||||
<div className="text-right">
|
<div className="">
|
||||||
<div className="font-normal text-gray-500">{formatNumber(item?.management_rate)}</div>
|
<div className="text-base font-semibold">{item?.lastname}</div>
|
||||||
</div>
|
</div>
|
||||||
</td>
|
</td>
|
||||||
<td className="px-2">
|
<td className="px-2">
|
||||||
<div className="text-right">
|
<div className="text-left">
|
||||||
<div className="font-normal text-gray-500">{formatNumber(item?.maximum_amount)}</div>
|
<div className="text-base font-semibold">{item?.username}</div>
|
||||||
<div className="font-normal text-gray-500">{formatNumber(item?.minimum_amount)}</div>
|
</div>
|
||||||
</div>
|
|
||||||
</td>
|
</td>
|
||||||
<td className="px-2">
|
<td className="px-2">
|
||||||
<div className="text-right">
|
<div className="text-left">
|
||||||
<div className="font-normal text-gray-500">{item?.tenor}</div>
|
<div className="text-base font-semibold">{item?.acc_level}</div>
|
||||||
</div>
|
</div>
|
||||||
</td>
|
|
||||||
<td className="px-2 text-right">
|
|
||||||
<div className='flex items-center justify-end gap-3 md:gap-4'>
|
|
||||||
<div className='p-2 flex justify-center items-center text-slate-500 bg-white-body dark:text-white-body dark:bg-black-body rounded-md'>
|
|
||||||
<Icons name='eye' />
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
))
|
))
|
||||||
:
|
:
|
||||||
<tr className="py-2 border-t border-dashed border-slate-300">
|
<tr className="py-2 border-t border-dashed border-slate-300">
|
||||||
<td className="px-3 py-2" colSpan={7}>
|
<td className="px-3 py-2" colSpan={6}>
|
||||||
<div className="flex justify-center items-center">
|
<div className="flex justify-center items-center">
|
||||||
No Record Found
|
No Record Found
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
Reference in New Issue
Block a user