added employer column in ready table
This commit was merged in pull request #31.
This commit is contained in:
@@ -0,0 +1,11 @@
|
||||
import {FC} from 'react'
|
||||
|
||||
type Props = {
|
||||
employer_name?: string
|
||||
}
|
||||
|
||||
const EmployerCell: FC<Props> = ({employer_name}) => (
|
||||
<div className='badge badge-light fw-bolder'>{employer_name}</div>
|
||||
)
|
||||
|
||||
export {EmployerCell}
|
||||
@@ -44,7 +44,7 @@ const UserActionsCell: FC<Props> = ({ id }) => {
|
||||
</a>
|
||||
{/* begin::Menu */}
|
||||
<div
|
||||
className="menu menu-sub menu-sub-dropdown menu-column menu-rounded menu-gray-600 menu-state-bg-light-primary fw-bold fs-7 w-125px py-4"
|
||||
className="menu menu-sub menu-sub-dropdown menu-column menu-rounded menu-gray-600 menu-state-bg-light-primary fw-bold fs-7 w-175px py-4"
|
||||
data-kt-menu="true"
|
||||
>
|
||||
{/* begin::Menu item */}
|
||||
@@ -62,7 +62,7 @@ const UserActionsCell: FC<Props> = ({ id }) => {
|
||||
data-kt-users-table-filter="delete_row"
|
||||
onClick={async () => await deleteItem.mutateAsync()}
|
||||
>
|
||||
Delete
|
||||
Resend Verification
|
||||
</a>
|
||||
</div>
|
||||
{/* end::Menu item */}
|
||||
|
||||
@@ -8,6 +8,7 @@ import {UserCustomHeader} from './UserCustomHeader'
|
||||
import {UserSelectionHeader} from './UserSelectionHeader'
|
||||
import {User} from '../../../core/_models'
|
||||
import { AddedCell } from './AddedCell'
|
||||
import { EmployerCell } from './EmployerCell'
|
||||
|
||||
const usersColumns: ReadonlyArray<Column<User>> = [
|
||||
{
|
||||
@@ -20,6 +21,13 @@ const usersColumns: ReadonlyArray<Column<User>> = [
|
||||
id: 'firstname',
|
||||
Cell: ({...props}) => <UserInfoCell user={props.data[props.row.index]} />,
|
||||
},
|
||||
{
|
||||
Header: (props) => (
|
||||
<UserCustomHeader tableProps={props} title='Employer' className='min-w-125px' />
|
||||
),
|
||||
id: 'employer_name',
|
||||
Cell: ({...props}) => <EmployerCell employer_name={props.data[props.row.index].employer_name} />,
|
||||
},
|
||||
{
|
||||
Header: (props) => <UserCustomHeader tableProps={props} title='Amount' className='min-w-125px' />,
|
||||
accessor: 'loan_amount',
|
||||
|
||||
Reference in New Issue
Block a user